Commit 395e5df7 authored by Raghava Aditya Renukunta's avatar Raghava Aditya Renukunta Committed by Martin K. Petersen

scsi: aacraid: Remove reference to Series-9

Remove reference to Series-9 HBA and created arc ctrl check function.
Signed-off-by: default avatarPrasad B Munirathnam <prasad.munirathnam@microsemi.com>
Signed-off-by: default avatarRaghava Aditya Renukunta <RaghavaAditya.Renukunta@microsemi.com>
Reviewed-by: default avatarDavid Carroll <david.carroll@microsemi.com>
Signed-off-by: default avatarMartin K. Petersen <martin.petersen@oracle.com>
parent 4a76be0d
...@@ -424,7 +424,6 @@ struct aac_ciss_identify_pd { ...@@ -424,7 +424,6 @@ struct aac_ciss_identify_pd {
#define PMC_DEVICE_S6 0x28b #define PMC_DEVICE_S6 0x28b
#define PMC_DEVICE_S7 0x28c #define PMC_DEVICE_S7 0x28c
#define PMC_DEVICE_S8 0x28d #define PMC_DEVICE_S8 0x28d
#define PMC_DEVICE_S9 0x28f
#define aac_phys_to_logical(x) ((x)+1) #define aac_phys_to_logical(x) ((x)+1)
#define aac_logical_to_phys(x) ((x)?(x)-1:0) #define aac_logical_to_phys(x) ((x)?(x)-1:0)
...@@ -2689,6 +2688,18 @@ int aac_probe_container(struct aac_dev *dev, int cid); ...@@ -2689,6 +2688,18 @@ int aac_probe_container(struct aac_dev *dev, int cid);
int _aac_rx_init(struct aac_dev *dev); int _aac_rx_init(struct aac_dev *dev);
int aac_rx_select_comm(struct aac_dev *dev, int comm); int aac_rx_select_comm(struct aac_dev *dev, int comm);
int aac_rx_deliver_producer(struct fib * fib); int aac_rx_deliver_producer(struct fib * fib);
static inline int aac_is_src(struct aac_dev *dev)
{
u16 device = dev->pdev->device;
if (device == PMC_DEVICE_S6 ||
device == PMC_DEVICE_S7 ||
device == PMC_DEVICE_S8)
return 1;
return 0;
}
char * get_container_type(unsigned type); char * get_container_type(unsigned type);
extern int numacb; extern int numacb;
extern char aac_driver_version[]; extern char aac_driver_version[];
......
...@@ -53,11 +53,8 @@ static inline int aac_is_msix_mode(struct aac_dev *dev) ...@@ -53,11 +53,8 @@ static inline int aac_is_msix_mode(struct aac_dev *dev)
{ {
u32 status = 0; u32 status = 0;
if (dev->pdev->device == PMC_DEVICE_S6 || if (aac_is_src(dev))
dev->pdev->device == PMC_DEVICE_S7 ||
dev->pdev->device == PMC_DEVICE_S8) {
status = src_readl(dev, MUnit.OMR); status = src_readl(dev, MUnit.OMR);
}
return (status & AAC_INT_MODE_MSIX); return (status & AAC_INT_MODE_MSIX);
} }
...@@ -325,9 +322,7 @@ int aac_send_shutdown(struct aac_dev * dev) ...@@ -325,9 +322,7 @@ int aac_send_shutdown(struct aac_dev * dev)
/* FIB should be freed only after getting the response from the F/W */ /* FIB should be freed only after getting the response from the F/W */
if (status != -ERESTARTSYS) if (status != -ERESTARTSYS)
aac_fib_free(fibctx); aac_fib_free(fibctx);
if ((dev->pdev->device == PMC_DEVICE_S7 || if (aac_is_src(dev) &&
dev->pdev->device == PMC_DEVICE_S8 ||
dev->pdev->device == PMC_DEVICE_S9) &&
dev->msi_enabled) dev->msi_enabled)
aac_set_intx_mode(dev); aac_set_intx_mode(dev);
return status; return status;
...@@ -583,9 +578,7 @@ struct aac_dev *aac_init_adapter(struct aac_dev *dev) ...@@ -583,9 +578,7 @@ struct aac_dev *aac_init_adapter(struct aac_dev *dev)
dev->max_fib_size = status[1] & 0xFFE0; dev->max_fib_size = status[1] & 0xFFE0;
host->sg_tablesize = status[2] >> 16; host->sg_tablesize = status[2] >> 16;
dev->sg_tablesize = status[2] & 0xFFFF; dev->sg_tablesize = status[2] & 0xFFFF;
if (dev->pdev->device == PMC_DEVICE_S7 || if (aac_is_src(dev)) {
dev->pdev->device == PMC_DEVICE_S8 ||
dev->pdev->device == PMC_DEVICE_S9) {
if (host->can_queue > (status[3] >> 16) - if (host->can_queue > (status[3] >> 16) -
AAC_NUM_MGT_FIB) AAC_NUM_MGT_FIB)
host->can_queue = (status[3] >> 16) - host->can_queue = (status[3] >> 16) -
...@@ -604,10 +597,7 @@ struct aac_dev *aac_init_adapter(struct aac_dev *dev) ...@@ -604,10 +597,7 @@ struct aac_dev *aac_init_adapter(struct aac_dev *dev)
pr_warn("numacb=%d ignored\n", numacb); pr_warn("numacb=%d ignored\n", numacb);
} }
if (dev->pdev->device == PMC_DEVICE_S6 || if (aac_is_src(dev))
dev->pdev->device == PMC_DEVICE_S7 ||
dev->pdev->device == PMC_DEVICE_S8 ||
dev->pdev->device == PMC_DEVICE_S9)
aac_define_int_mode(dev); aac_define_int_mode(dev);
/* /*
* Ok now init the communication subsystem * Ok now init the communication subsystem
......
...@@ -2591,10 +2591,7 @@ void aac_free_irq(struct aac_dev *dev) ...@@ -2591,10 +2591,7 @@ void aac_free_irq(struct aac_dev *dev)
int cpu; int cpu;
cpu = cpumask_first(cpu_online_mask); cpu = cpumask_first(cpu_online_mask);
if (dev->pdev->device == PMC_DEVICE_S6 || if (aac_is_src(dev)) {
dev->pdev->device == PMC_DEVICE_S7 ||
dev->pdev->device == PMC_DEVICE_S8 ||
dev->pdev->device == PMC_DEVICE_S9) {
if (dev->max_msix > 1) { if (dev->max_msix > 1) {
for (i = 0; i < dev->max_msix; i++) for (i = 0; i < dev->max_msix; i++)
free_irq(pci_irq_vector(dev->pdev, i), free_irq(pci_irq_vector(dev->pdev, i),
......
...@@ -1416,10 +1416,7 @@ static void __aac_shutdown(struct aac_dev * aac) ...@@ -1416,10 +1416,7 @@ static void __aac_shutdown(struct aac_dev * aac)
kthread_stop(aac->thread); kthread_stop(aac->thread);
} }
aac_adapter_disable_int(aac); aac_adapter_disable_int(aac);
if (aac->pdev->device == PMC_DEVICE_S6 || if (aac_is_src(aac)) {
aac->pdev->device == PMC_DEVICE_S7 ||
aac->pdev->device == PMC_DEVICE_S8 ||
aac->pdev->device == PMC_DEVICE_S9) {
if (aac->max_msix > 1) { if (aac->max_msix > 1) {
for (i = 0; i < aac->max_msix; i++) { for (i = 0; i < aac->max_msix; i++) {
free_irq(pci_irq_vector(aac->pdev, i), free_irq(pci_irq_vector(aac->pdev, i),
...@@ -1684,9 +1681,7 @@ static int aac_acquire_resources(struct aac_dev *dev) ...@@ -1684,9 +1681,7 @@ static int aac_acquire_resources(struct aac_dev *dev)
aac_adapter_enable_int(dev); aac_adapter_enable_int(dev);
if ((dev->pdev->device == PMC_DEVICE_S7 || if (aac_is_src(dev))
dev->pdev->device == PMC_DEVICE_S8 ||
dev->pdev->device == PMC_DEVICE_S9))
aac_define_int_mode(dev); aac_define_int_mode(dev);
if (dev->msi_enabled) if (dev->msi_enabled)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment