@@ -294,6 +294,10 @@ MODULE_PARM_DESC(aif_timeout, "The duration of time in seconds to wait for"
294
294
"deregistering them. This is typically adjusted for heavily burdened"
295
295
" systems." );
296
296
297
+ int aac_fib_dump ;
298
+ module_param (aac_fib_dump , int , 0644 );
299
+ MODULE_PARM_DESC (aac_fib_dump , "Dump controller fibs prior to IOP_RESET 0=off, 1=on" );
300
+
297
301
int numacb = -1 ;
298
302
module_param (numacb , int , S_IRUGO |S_IWUSR );
299
303
MODULE_PARM_DESC (numacb , "Request a limit to the number of adapter control"
@@ -311,7 +315,7 @@ module_param(update_interval, int, S_IRUGO|S_IWUSR);
311
315
MODULE_PARM_DESC (update_interval , "Interval in seconds between time sync"
312
316
" updates issued to adapter." );
313
317
314
- int check_interval = 24 * 60 * 60 ;
318
+ int check_interval = 60 ;
315
319
module_param (check_interval , int , S_IRUGO |S_IWUSR );
316
320
MODULE_PARM_DESC (check_interval , "Interval in seconds between adapter health"
317
321
" checks." );
@@ -483,7 +487,7 @@ int aac_get_containers(struct aac_dev *dev)
483
487
if (status >= 0 ) {
484
488
dresp = (struct aac_get_container_count_resp * )fib_data (fibptr );
485
489
maximum_num_containers = le32_to_cpu (dresp -> ContainerSwitchEntries );
486
- if (fibptr -> dev -> supplement_adapter_info .SupportedOptions2 &
490
+ if (fibptr -> dev -> supplement_adapter_info .supported_options2 &
487
491
AAC_OPTION_SUPPORTED_240_VOLUMES ) {
488
492
maximum_num_containers =
489
493
le32_to_cpu (dresp -> MaxSimpleVolumes );
@@ -639,13 +643,16 @@ static void _aac_probe_container2(void * context, struct fib * fibptr)
639
643
fsa_dev_ptr = fibptr -> dev -> fsa_dev ;
640
644
if (fsa_dev_ptr ) {
641
645
struct aac_mount * dresp = (struct aac_mount * ) fib_data (fibptr );
646
+ __le32 sup_options2 ;
647
+
642
648
fsa_dev_ptr += scmd_id (scsicmd );
649
+ sup_options2 =
650
+ fibptr -> dev -> supplement_adapter_info .supported_options2 ;
643
651
644
652
if ((le32_to_cpu (dresp -> status ) == ST_OK ) &&
645
653
(le32_to_cpu (dresp -> mnt [0 ].vol ) != CT_NONE ) &&
646
654
(le32_to_cpu (dresp -> mnt [0 ].state ) != FSCS_HIDDEN )) {
647
- if (!(fibptr -> dev -> supplement_adapter_info .SupportedOptions2 &
648
- AAC_OPTION_VARIABLE_BLOCK_SIZE )) {
655
+ if (!(sup_options2 & AAC_OPTION_VARIABLE_BLOCK_SIZE )) {
649
656
dresp -> mnt [0 ].fileinfo .bdevinfo .block_size = 0x200 ;
650
657
fsa_dev_ptr -> block_size = 0x200 ;
651
658
} else {
@@ -688,7 +695,7 @@ static void _aac_probe_container1(void * context, struct fib * fibptr)
688
695
int status ;
689
696
690
697
dresp = (struct aac_mount * ) fib_data (fibptr );
691
- if (!(fibptr -> dev -> supplement_adapter_info .SupportedOptions2 &
698
+ if (!(fibptr -> dev -> supplement_adapter_info .supported_options2 &
692
699
AAC_OPTION_VARIABLE_BLOCK_SIZE ))
693
700
dresp -> mnt [0 ].capacityhigh = 0 ;
694
701
if ((le32_to_cpu (dresp -> status ) != ST_OK ) ||
@@ -705,7 +712,7 @@ static void _aac_probe_container1(void * context, struct fib * fibptr)
705
712
706
713
dinfo = (struct aac_query_mount * )fib_data (fibptr );
707
714
708
- if (fibptr -> dev -> supplement_adapter_info .SupportedOptions2 &
715
+ if (fibptr -> dev -> supplement_adapter_info .supported_options2 &
709
716
AAC_OPTION_VARIABLE_BLOCK_SIZE )
710
717
dinfo -> command = cpu_to_le32 (VM_NameServeAllBlk );
711
718
else
@@ -745,7 +752,7 @@ static int _aac_probe_container(struct scsi_cmnd * scsicmd, int (*callback)(stru
745
752
746
753
dinfo = (struct aac_query_mount * )fib_data (fibptr );
747
754
748
- if (fibptr -> dev -> supplement_adapter_info .SupportedOptions2 &
755
+ if (fibptr -> dev -> supplement_adapter_info .supported_options2 &
749
756
AAC_OPTION_VARIABLE_BLOCK_SIZE )
750
757
dinfo -> command = cpu_to_le32 (VM_NameServeAllBlk );
751
758
else
@@ -896,12 +903,14 @@ char * get_container_type(unsigned tindex)
896
903
static void setinqstr (struct aac_dev * dev , void * data , int tindex )
897
904
{
898
905
struct scsi_inq * str ;
906
+ struct aac_supplement_adapter_info * sup_adap_info ;
899
907
908
+ sup_adap_info = & dev -> supplement_adapter_info ;
900
909
str = (struct scsi_inq * )(data ); /* cast data to scsi inq block */
901
910
memset (str , ' ' , sizeof (* str ));
902
911
903
- if (dev -> supplement_adapter_info . AdapterTypeText [0 ]) {
904
- char * cp = dev -> supplement_adapter_info . AdapterTypeText ;
912
+ if (sup_adap_info -> adapter_type_text [0 ]) {
913
+ char * cp = sup_adap_info -> adapter_type_text ;
905
914
int c ;
906
915
if ((cp [0 ] == 'A' ) && (cp [1 ] == 'O' ) && (cp [2 ] == 'C' ))
907
916
inqstrcpy ("SMC" , str -> vid );
@@ -911,8 +920,7 @@ static void setinqstr(struct aac_dev *dev, void *data, int tindex)
911
920
++ cp ;
912
921
c = * cp ;
913
922
* cp = '\0' ;
914
- inqstrcpy (dev -> supplement_adapter_info .AdapterTypeText ,
915
- str -> vid );
923
+ inqstrcpy (sup_adap_info -> adapter_type_text , str -> vid );
916
924
* cp = c ;
917
925
while (* cp && * cp != ' ' )
918
926
++ cp ;
@@ -1675,8 +1683,8 @@ int aac_issue_bmic_identify(struct aac_dev *dev, u32 bus, u32 target)
1675
1683
if (!identify_resp )
1676
1684
goto fib_free_ptr ;
1677
1685
1678
- vbus = (u32 )le16_to_cpu (dev -> supplement_adapter_info .VirtDeviceBus );
1679
- vid = (u32 )le16_to_cpu (dev -> supplement_adapter_info .VirtDeviceTarget );
1686
+ vbus = (u32 )le16_to_cpu (dev -> supplement_adapter_info .virt_device_bus );
1687
+ vid = (u32 )le16_to_cpu (dev -> supplement_adapter_info .virt_device_target );
1680
1688
1681
1689
aac_fib_init (fibptr );
1682
1690
@@ -1815,9 +1823,9 @@ int aac_report_phys_luns(struct aac_dev *dev, struct fib *fibptr, int rescan)
1815
1823
}
1816
1824
1817
1825
vbus = (u32 ) le16_to_cpu (
1818
- dev -> supplement_adapter_info .VirtDeviceBus );
1826
+ dev -> supplement_adapter_info .virt_device_bus );
1819
1827
vid = (u32 ) le16_to_cpu (
1820
- dev -> supplement_adapter_info .VirtDeviceTarget );
1828
+ dev -> supplement_adapter_info .virt_device_target );
1821
1829
1822
1830
aac_fib_init (fibptr );
1823
1831
@@ -1893,7 +1901,7 @@ int aac_get_adapter_info(struct aac_dev* dev)
1893
1901
}
1894
1902
memcpy (& dev -> adapter_info , info , sizeof (* info ));
1895
1903
1896
- dev -> supplement_adapter_info .VirtDeviceBus = 0xffff ;
1904
+ dev -> supplement_adapter_info .virt_device_bus = 0xffff ;
1897
1905
if (dev -> adapter_info .options & AAC_OPT_SUPPLEMENT_ADAPTER_INFO ) {
1898
1906
struct aac_supplement_adapter_info * sinfo ;
1899
1907
@@ -1961,7 +1969,7 @@ int aac_get_adapter_info(struct aac_dev* dev)
1961
1969
}
1962
1970
1963
1971
if (!dev -> sync_mode && dev -> sa_firmware &&
1964
- dev -> supplement_adapter_info .VirtDeviceBus != 0xffff ) {
1972
+ dev -> supplement_adapter_info .virt_device_bus != 0xffff ) {
1965
1973
/* Thor SA Firmware -> CISS_REPORT_PHYSICAL_LUNS */
1966
1974
rcode = aac_report_phys_luns (dev , fibptr , AAC_INIT );
1967
1975
}
@@ -1976,8 +1984,8 @@ int aac_get_adapter_info(struct aac_dev* dev)
1976
1984
(tmp >>16 )& 0xff ,
1977
1985
tmp & 0xff ,
1978
1986
le32_to_cpu (dev -> adapter_info .kernelbuild ),
1979
- (int )sizeof (dev -> supplement_adapter_info .BuildDate ),
1980
- dev -> supplement_adapter_info .BuildDate );
1987
+ (int )sizeof (dev -> supplement_adapter_info .build_date ),
1988
+ dev -> supplement_adapter_info .build_date );
1981
1989
tmp = le32_to_cpu (dev -> adapter_info .monitorrev );
1982
1990
printk (KERN_INFO "%s%d: monitor %d.%d-%d[%d]\n" ,
1983
1991
dev -> name , dev -> id ,
@@ -1993,22 +2001,23 @@ int aac_get_adapter_info(struct aac_dev* dev)
1993
2001
shost_to_class (dev -> scsi_host_ptr ), buffer ))
1994
2002
printk (KERN_INFO "%s%d: serial %s" ,
1995
2003
dev -> name , dev -> id , buffer );
1996
- if (dev -> supplement_adapter_info .VpdInfo . Tsid [0 ]) {
2004
+ if (dev -> supplement_adapter_info .vpd_info . tsid [0 ]) {
1997
2005
printk (KERN_INFO "%s%d: TSID %.*s\n" ,
1998
2006
dev -> name , dev -> id ,
1999
- (int )sizeof (dev -> supplement_adapter_info .VpdInfo .Tsid ),
2000
- dev -> supplement_adapter_info .VpdInfo .Tsid );
2007
+ (int )sizeof (dev -> supplement_adapter_info
2008
+ .vpd_info .tsid ),
2009
+ dev -> supplement_adapter_info .vpd_info .tsid );
2001
2010
}
2002
2011
if (!aac_check_reset || ((aac_check_reset == 1 ) &&
2003
- (dev -> supplement_adapter_info .SupportedOptions2 &
2012
+ (dev -> supplement_adapter_info .supported_options2 &
2004
2013
AAC_OPTION_IGNORE_RESET ))) {
2005
2014
printk (KERN_INFO "%s%d: Reset Adapter Ignored\n" ,
2006
2015
dev -> name , dev -> id );
2007
2016
}
2008
2017
}
2009
2018
2010
2019
dev -> cache_protected = 0 ;
2011
- dev -> jbod = ((dev -> supplement_adapter_info .FeatureBits &
2020
+ dev -> jbod = ((dev -> supplement_adapter_info .feature_bits &
2012
2021
AAC_FEATURE_JBOD ) != 0 );
2013
2022
dev -> nondasd_support = 0 ;
2014
2023
dev -> raid_scsi_mode = 0 ;
@@ -2631,7 +2640,7 @@ static int aac_start_stop(struct scsi_cmnd *scsicmd)
2631
2640
struct scsi_device * sdev = scsicmd -> device ;
2632
2641
struct aac_dev * aac = (struct aac_dev * )sdev -> host -> hostdata ;
2633
2642
2634
- if (!(aac -> supplement_adapter_info .SupportedOptions2 &
2643
+ if (!(aac -> supplement_adapter_info .supported_options2 &
2635
2644
AAC_OPTION_POWER_MANAGEMENT )) {
2636
2645
scsicmd -> result = DID_OK << 16 | COMMAND_COMPLETE << 8 |
2637
2646
SAM_STAT_GOOD ;
0 commit comments