diff options
author | Todd Poynor <toddpoynor@google.com> | 2018-07-28 01:21:57 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2018-07-28 03:24:10 -0400 |
commit | f390d08d8b872a0f71db45bc970a238475679fac (patch) | |
tree | 6f74f1176463d145349e0ef399679e0ca1112f23 | |
parent | e7cffa03b34265e17de55d5ef8983c91482643a0 (diff) |
staging: gasket: apex: fixup undefined PCI class
Apex chips with class 0 (PCI_CLASS_NOT_DEFINED) fixed up to
PCI_CLASS_SYSTEM_OTHER to enable PCI resource assignments.
Signed-off-by: Todd Poynor <toddpoynor@google.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r-- | drivers/staging/gasket/apex_driver.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/staging/gasket/apex_driver.c b/drivers/staging/gasket/apex_driver.c index 73fc2683a834..ab466d49608a 100644 --- a/drivers/staging/gasket/apex_driver.c +++ b/drivers/staging/gasket/apex_driver.c | |||
@@ -739,3 +739,10 @@ static ssize_t sysfs_show( | |||
739 | gasket_sysfs_put_device_data(device, gasket_dev); | 739 | gasket_sysfs_put_device_data(device, gasket_dev); |
740 | return ret; | 740 | return ret; |
741 | } | 741 | } |
742 | |||
743 | static void apex_pci_fixup_class(struct pci_dev *pdev) | ||
744 | { | ||
745 | pdev->class = (PCI_CLASS_SYSTEM_OTHER << 8) | pdev->class; | ||
746 | } | ||
747 | DECLARE_PCI_FIXUP_CLASS_HEADER(APEX_PCI_VENDOR_ID, APEX_PCI_DEVICE_ID, | ||
748 | PCI_CLASS_NOT_DEFINED, 8, apex_pci_fixup_class); | ||