1 ; https://lkml.org/lkml/2019/7/10/244
2 diff -ur linux-5.3/drivers/scsi/aacraid.org/aacraid.h linux-5.3/drivers/scsi/aacraid/aacraid.h
3 --- linux-5.3/drivers/scsi/aacraid.org/aacraid.h 2019-11-01 22:42:37.011469816 +0100
4 +++ linux-5.3/drivers/scsi/aacraid/aacraid.h 2019-11-04 09:29:51.321486211 +0100
6 int aac_rx_deliver_producer(struct fib * fib);
7 void aac_reinit_aif(struct aac_dev *aac, unsigned int index);
9 -static inline int aac_is_src(struct aac_dev *dev)
11 - u16 device = dev->pdev->device;
13 - if (device == PMC_DEVICE_S6 ||
14 - device == PMC_DEVICE_S7 ||
15 - device == PMC_DEVICE_S8)
20 static inline int aac_supports_2T(struct aac_dev *dev)
22 return (dev->adapter_info.options & AAC_OPT_NEW_COMM_64);
23 diff -ur linux-5.3/drivers/scsi/aacraid.org/comminit.c linux-5.3/drivers/scsi/aacraid/comminit.c
24 --- linux-5.3/drivers/scsi/aacraid.org/comminit.c 2019-11-01 22:42:37.014803249 +0100
25 +++ linux-5.3/drivers/scsi/aacraid/comminit.c 2019-11-04 09:29:51.321486211 +0100
30 - if (aac_is_src(dev))
31 + if (dev->pdev->device == PMC_DEVICE_S6 ||
32 + dev->pdev->device == PMC_DEVICE_S7 ||
33 + dev->pdev->device == PMC_DEVICE_S8) {
34 status = src_readl(dev, MUnit.OMR);
36 return (status & AAC_INT_MODE_MSIX);
40 /* FIB should be freed only after getting the response from the F/W */
41 if (status != -ERESTARTSYS)
43 - if (aac_is_src(dev) &&
44 + if ((dev->pdev->device == PMC_DEVICE_S7 ||
45 + dev->pdev->device == PMC_DEVICE_S8) &&
47 aac_set_intx_mode(dev);
50 dev->max_fib_size = status[1] & 0xFFE0;
51 host->sg_tablesize = status[2] >> 16;
52 dev->sg_tablesize = status[2] & 0xFFFF;
53 - if (aac_is_src(dev)) {
54 + if (dev->pdev->device == PMC_DEVICE_S7 ||
55 + dev->pdev->device == PMC_DEVICE_S8) {
56 if (host->can_queue > (status[3] >> 16) -
58 host->can_queue = (status[3] >> 16) -
60 pr_warn("numacb=%d ignored\n", numacb);
63 - if (aac_is_src(dev))
64 + if (dev->pdev->device == PMC_DEVICE_S6 ||
65 + dev->pdev->device == PMC_DEVICE_S7 ||
66 + dev->pdev->device == PMC_DEVICE_S8)
67 aac_define_int_mode(dev);
69 * Ok now init the communication subsystem
70 diff -ur linux-5.3/drivers/scsi/aacraid.org/commsup.c linux-5.3/drivers/scsi/aacraid/commsup.c
71 --- linux-5.3/drivers/scsi/aacraid.org/commsup.c 2019-11-01 22:42:37.014803249 +0100
72 +++ linux-5.3/drivers/scsi/aacraid/commsup.c 2019-11-04 09:29:51.321486211 +0100
77 - if (aac_is_src(dev)) {
78 + if (dev->pdev->device == PMC_DEVICE_S6 ||
79 + dev->pdev->device == PMC_DEVICE_S7 ||
80 + dev->pdev->device == PMC_DEVICE_S8) {
81 if (dev->max_msix > 1) {
82 for (i = 0; i < dev->max_msix; i++)
83 free_irq(pci_irq_vector(dev->pdev, i),
84 diff -ur linux-5.3/drivers/scsi/aacraid.org/linit.c linux-5.3/drivers/scsi/aacraid/linit.c
85 --- linux-5.3/drivers/scsi/aacraid.org/linit.c 2019-11-01 22:42:37.011469816 +0100
86 +++ linux-5.3/drivers/scsi/aacraid/linit.c 2019-11-04 09:29:51.321486211 +0100
88 aac_send_shutdown(aac);
90 aac_adapter_disable_int(aac);
92 - if (aac_is_src(aac)) {
93 + if (aac->pdev->device == PMC_DEVICE_S6 ||
94 + aac->pdev->device == PMC_DEVICE_S7 ||
95 + aac->pdev->device == PMC_DEVICE_S8) {
96 if (aac->max_msix > 1) {
97 for (i = 0; i < aac->max_msix; i++) {
98 free_irq(pci_irq_vector(aac->pdev, i),
100 aac_adapter_enable_int(dev);
103 - if (aac_is_src(dev))
104 + if (dev->pdev->device == PMC_DEVICE_S7 ||
105 + dev->pdev->device == PMC_DEVICE_S8)
106 aac_define_int_mode(dev);
108 if (dev->msi_enabled)