mirror of
https://github.com/torvalds/linux.git
synced 2026-07-28 01:55:51 +02:00
wifi: mt76: mt7925: add MT7927 PCIe support
Add the missing MT7927 device support in the mt7925 PCI path. This ensures MT7927 is identified correctly and uses the proper initialization flow. Co-developed-by: Javier Tia <floss@jetm.me> Signed-off-by: Javier Tia <floss@jetm.me> Signed-off-by: Sean Wang <sean.wang@mediatek.com> Link: https://patch.msgid.link/20260425195011.790265-21-sean.wang@kernel.org Signed-off-by: Felix Fietkau <nbd@nbd.name>
This commit is contained in:
parent
298efd8f9f
commit
35a5dcc717
|
|
@ -16,6 +16,12 @@ static const struct pci_device_id mt7925_pci_device_table[] = {
|
|||
.driver_data = (kernel_ulong_t)MT7925_FIRMWARE_WM },
|
||||
{ PCI_DEVICE(PCI_VENDOR_ID_MEDIATEK, 0x0717),
|
||||
.driver_data = (kernel_ulong_t)MT7925_FIRMWARE_WM },
|
||||
{ PCI_DEVICE(PCI_VENDOR_ID_MEDIATEK, 0x7927),
|
||||
.driver_data = (kernel_ulong_t)MT7927_FIRMWARE_WM },
|
||||
{ PCI_DEVICE(PCI_VENDOR_ID_MEDIATEK, 0x6639),
|
||||
.driver_data = (kernel_ulong_t)MT7927_FIRMWARE_WM },
|
||||
{ PCI_DEVICE(PCI_VENDOR_ID_MEDIATEK, 0x0738),
|
||||
.driver_data = (kernel_ulong_t)MT7927_FIRMWARE_WM },
|
||||
{ },
|
||||
};
|
||||
|
||||
|
|
@ -376,7 +382,8 @@ static int mt7925_pci_probe(struct pci_dev *pdev,
|
|||
if (ret)
|
||||
goto err_free_pci_vec;
|
||||
|
||||
is_mt7927_hw = (pdev->device == 0x6639 || pdev->device == 0x7927);
|
||||
is_mt7927_hw = (pdev->device == 0x6639 || pdev->device == 0x7927 ||
|
||||
pdev->device == 0x0738);
|
||||
|
||||
/* MT7927: ASPM L1 causes unreliable WFDMA register access */
|
||||
if (mt7925_disable_aspm || is_mt7927_hw)
|
||||
|
|
@ -436,6 +443,13 @@ static int mt7925_pci_probe(struct pci_dev *pdev,
|
|||
|
||||
dev_info(mdev->dev, "ASIC revision: %04x\n", mdev->rev);
|
||||
|
||||
if (is_mt7927_hw && mt76_chip(mdev) != 0x7927) {
|
||||
dev_info(mdev->dev,
|
||||
"MT7927 raw CHIPID=0x%04x, forcing chip=0x7927\n",
|
||||
mt76_chip(mdev));
|
||||
mdev->rev = (0x7927 << 16) | (mdev->rev & 0xff);
|
||||
}
|
||||
|
||||
mt76_rmw_field(dev, MT_HW_EMI_CTL, MT_HW_EMI_CTL_SLPPROT_EN, 1);
|
||||
|
||||
ret = mt792x_wfsys_reset(dev);
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user