[SCSI] aic7xxx: remove usage of obsolete typedefs

Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>

authored by Christoph Hellwig and committed by James Bottomley 013791ee 7dfa0f26

+38 -51
+18 -34
drivers/scsi/aic7xxx/aic7xxx_osm.c
··· 426 426 struct ahc_linux_device *, 427 427 struct scb *); 428 428 static void ahc_linux_queue_cmd_complete(struct ahc_softc *ahc, 429 - Scsi_Cmnd *cmd); 429 + struct scsi_cmnd *cmd); 430 430 static void ahc_linux_sem_timeout(u_long arg); 431 431 static void ahc_linux_freeze_simq(struct ahc_softc *ahc); 432 432 static void ahc_linux_release_simq(u_long arg); 433 433 static void ahc_linux_dev_timed_unfreeze(u_long arg); 434 - static int ahc_linux_queue_recovery_cmd(Scsi_Cmnd *cmd, scb_flag flag); 434 + static int ahc_linux_queue_recovery_cmd(struct scsi_cmnd *cmd, scb_flag flag); 435 435 static void ahc_linux_initialize_scsi_bus(struct ahc_softc *ahc); 436 436 static void ahc_linux_thread_run_complete_queue(struct ahc_softc *ahc); 437 437 static u_int ahc_linux_user_tagdepth(struct ahc_softc *ahc, ··· 512 512 513 513 with_errors = 0; 514 514 while ((acmd = TAILQ_FIRST(&ahc->platform_data->completeq)) != NULL) { 515 - Scsi_Cmnd *cmd; 515 + struct scsi_cmnd *cmd; 516 516 517 517 if (with_errors > AHC_LINUX_MAX_RETURNED_ERRORS) { 518 518 /* ··· 542 542 static __inline void 543 543 ahc_linux_unmap_scb(struct ahc_softc *ahc, struct scb *scb) 544 544 { 545 - Scsi_Cmnd *cmd; 545 + struct scsi_cmnd *cmd; 546 546 547 547 cmd = scb->io_ctx; 548 548 ahc_sync_sglist(ahc, scb, BUS_DMASYNC_POSTWRITE); ··· 582 582 return (consumed); 583 583 } 584 584 585 - /************************ Host template entry points *************************/ 586 - static int ahc_linux_detect(Scsi_Host_Template *); 587 - static int ahc_linux_queue(Scsi_Cmnd *, void (*)(Scsi_Cmnd *)); 588 - static const char *ahc_linux_info(struct Scsi_Host *); 589 - static int ahc_linux_slave_alloc(Scsi_Device *); 590 - static int ahc_linux_slave_configure(Scsi_Device *); 591 - static void ahc_linux_slave_destroy(Scsi_Device *); 592 - #if defined(__i386__) 593 - static int ahc_linux_biosparam(struct scsi_device*, 594 - struct block_device*, 595 - sector_t, int[]); 596 - #endif 597 - static int ahc_linux_bus_reset(Scsi_Cmnd *); 598 - static int ahc_linux_dev_reset(Scsi_Cmnd *); 599 - static int ahc_linux_abort(Scsi_Cmnd *); 600 - 601 585 /* 602 586 * Try to detect an Adaptec 7XXX controller. 603 587 */ 604 588 static int 605 - ahc_linux_detect(Scsi_Host_Template *template) 589 + ahc_linux_detect(struct scsi_host_template *template) 606 590 { 607 591 struct ahc_softc *ahc; 608 592 int found = 0; ··· 667 683 * Queue an SCB to the controller. 668 684 */ 669 685 static int 670 - ahc_linux_queue(Scsi_Cmnd * cmd, void (*scsi_done) (Scsi_Cmnd *)) 686 + ahc_linux_queue(struct scsi_cmnd * cmd, void (*scsi_done) (struct scsi_cmnd *)) 671 687 { 672 688 struct ahc_softc *ahc; 673 689 struct ahc_linux_device *dev; ··· 698 714 } 699 715 700 716 static int 701 - ahc_linux_slave_alloc(Scsi_Device *device) 717 + ahc_linux_slave_alloc(struct scsi_device *device) 702 718 { 703 719 struct ahc_softc *ahc; 704 720 ··· 709 725 } 710 726 711 727 static int 712 - ahc_linux_slave_configure(Scsi_Device *device) 728 + ahc_linux_slave_configure(struct scsi_device *device) 713 729 { 714 730 struct ahc_softc *ahc; 715 731 struct ahc_linux_device *dev; ··· 739 755 } 740 756 741 757 static void 742 - ahc_linux_slave_destroy(Scsi_Device *device) 758 + ahc_linux_slave_destroy(struct scsi_device *device) 743 759 { 744 760 struct ahc_softc *ahc; 745 761 struct ahc_linux_device *dev; ··· 820 836 * Abort the current SCSI command(s). 821 837 */ 822 838 static int 823 - ahc_linux_abort(Scsi_Cmnd *cmd) 839 + ahc_linux_abort(struct scsi_cmnd *cmd) 824 840 { 825 841 int error; 826 842 ··· 834 850 * Attempt to send a target reset message to the device that timed out. 835 851 */ 836 852 static int 837 - ahc_linux_dev_reset(Scsi_Cmnd *cmd) 853 + ahc_linux_dev_reset(struct scsi_cmnd *cmd) 838 854 { 839 855 int error; 840 856 ··· 848 864 * Reset the SCSI bus. 849 865 */ 850 866 static int 851 - ahc_linux_bus_reset(Scsi_Cmnd *cmd) 867 + ahc_linux_bus_reset(struct scsi_cmnd *cmd) 852 868 { 853 869 struct ahc_softc *ahc; 854 870 int found; ··· 865 881 return SUCCESS; 866 882 } 867 883 868 - Scsi_Host_Template aic7xxx_driver_template = { 884 + struct scsi_host_template aic7xxx_driver_template = { 869 885 .module = THIS_MODULE, 870 886 .name = "aic7xxx", 871 887 .proc_info = ahc_linux_proc_info, ··· 1173 1189 uint32_t aic7xxx_verbose; 1174 1190 1175 1191 int 1176 - ahc_linux_register_host(struct ahc_softc *ahc, Scsi_Host_Template *template) 1192 + ahc_linux_register_host(struct ahc_softc *ahc, struct scsi_host_template *template) 1177 1193 { 1178 1194 char buf[80]; 1179 1195 struct Scsi_Host *host; ··· 2001 2017 void 2002 2018 ahc_done(struct ahc_softc *ahc, struct scb *scb) 2003 2019 { 2004 - Scsi_Cmnd *cmd; 2020 + struct scsi_cmnd *cmd; 2005 2021 struct ahc_linux_device *dev; 2006 2022 2007 2023 LIST_REMOVE(scb, pending_links); ··· 2155 2171 case SCSI_STATUS_CHECK_COND: 2156 2172 case SCSI_STATUS_CMD_TERMINATED: 2157 2173 { 2158 - Scsi_Cmnd *cmd; 2174 + struct scsi_cmnd *cmd; 2159 2175 2160 2176 /* 2161 2177 * Copy sense information to the OS's cmd ··· 2277 2293 } 2278 2294 2279 2295 static void 2280 - ahc_linux_queue_cmd_complete(struct ahc_softc *ahc, Scsi_Cmnd *cmd) 2296 + ahc_linux_queue_cmd_complete(struct ahc_softc *ahc, struct scsi_cmnd *cmd) 2281 2297 { 2282 2298 /* 2283 2299 * Typically, the complete queue has very few entries ··· 2466 2482 } 2467 2483 2468 2484 static int 2469 - ahc_linux_queue_recovery_cmd(Scsi_Cmnd *cmd, scb_flag flag) 2485 + ahc_linux_queue_recovery_cmd(struct scsi_cmnd *cmd, scb_flag flag) 2470 2486 { 2471 2487 struct ahc_softc *ahc; 2472 2488 struct ahc_linux_device *dev;
+20 -16
drivers/scsi/aic7xxx/aic7xxx_osm.h
··· 59 59 #ifndef _AIC7XXX_LINUX_H_ 60 60 #define _AIC7XXX_LINUX_H_ 61 61 62 + #include <linux/config.h> 62 63 #include <linux/types.h> 63 64 #include <linux/blkdev.h> 64 65 #include <linux/delay.h> ··· 69 68 #include <linux/version.h> 70 69 #include <linux/interrupt.h> 71 70 #include <linux/module.h> 71 + #include <linux/slab.h> 72 72 #include <asm/byteorder.h> 73 73 #include <asm/io.h> 74 74 75 - #include <linux/config.h> 76 - #include <linux/slab.h> 75 + #include <scsi/scsi.h> 76 + #include <scsi/scsi_cmnd.h> 77 + #include <scsi/scsi_eh.h> 78 + #include <scsi/scsi_device.h> 79 + #include <scsi/scsi_host.h> 80 + #include <scsi/scsi_tcq.h> 77 81 78 82 /* Core SCSI definitions */ 79 83 #define AIC_LIB_PREFIX ahc 80 - #include "scsi.h" 81 - #include <scsi/scsi_host.h> 82 84 83 85 /* Name space conflict with BSD queue macros */ 84 86 #ifdef LIST_HEAD ··· 110 106 /************************* Forward Declarations *******************************/ 111 107 struct ahc_softc; 112 108 typedef struct pci_dev *ahc_dev_softc_t; 113 - typedef Scsi_Cmnd *ahc_io_ctx_t; 109 + typedef struct scsi_cmnd *ahc_io_ctx_t; 114 110 115 111 /******************************* Byte Order ***********************************/ 116 112 #define ahc_htobe16(x) cpu_to_be16(x) ··· 148 144 extern u_int aic7xxx_no_probe; 149 145 extern u_int aic7xxx_allow_memio; 150 146 extern int aic7xxx_detect_complete; 151 - extern Scsi_Host_Template aic7xxx_driver_template; 147 + extern struct scsi_host_template aic7xxx_driver_template; 152 148 153 149 /***************************** Bus Space/DMA **********************************/ 154 150 ··· 412 408 #define AHC_OTAG_THRESH 500 413 409 414 410 int lun; 415 - Scsi_Device *scsi_device; 411 + struct scsi_device *scsi_device; 416 412 struct ahc_linux_target *target; 417 413 }; 418 414 ··· 568 564 569 565 /**************************** Initialization **********************************/ 570 566 int ahc_linux_register_host(struct ahc_softc *, 571 - Scsi_Host_Template *); 567 + struct scsi_host_template *); 572 568 573 569 uint64_t ahc_linux_get_memsize(void); 574 570 ··· 799 795 800 796 /*************************** Domain Validation ********************************/ 801 797 /*********************** Transaction Access Wrappers *************************/ 802 - static __inline void ahc_cmd_set_transaction_status(Scsi_Cmnd *, uint32_t); 798 + static __inline void ahc_cmd_set_transaction_status(struct scsi_cmnd *, uint32_t); 803 799 static __inline void ahc_set_transaction_status(struct scb *, uint32_t); 804 - static __inline void ahc_cmd_set_scsi_status(Scsi_Cmnd *, uint32_t); 800 + static __inline void ahc_cmd_set_scsi_status(struct scsi_cmnd *, uint32_t); 805 801 static __inline void ahc_set_scsi_status(struct scb *, uint32_t); 806 - static __inline uint32_t ahc_cmd_get_transaction_status(Scsi_Cmnd *cmd); 802 + static __inline uint32_t ahc_cmd_get_transaction_status(struct scsi_cmnd *cmd); 807 803 static __inline uint32_t ahc_get_transaction_status(struct scb *); 808 - static __inline uint32_t ahc_cmd_get_scsi_status(Scsi_Cmnd *cmd); 804 + static __inline uint32_t ahc_cmd_get_scsi_status(struct scsi_cmnd *cmd); 809 805 static __inline uint32_t ahc_get_scsi_status(struct scb *); 810 806 static __inline void ahc_set_transaction_tag(struct scb *, int, u_int); 811 807 static __inline u_long ahc_get_transfer_length(struct scb *); ··· 824 820 static __inline void ahc_freeze_scb(struct scb *scb); 825 821 826 822 static __inline 827 - void ahc_cmd_set_transaction_status(Scsi_Cmnd *cmd, uint32_t status) 823 + void ahc_cmd_set_transaction_status(struct scsi_cmnd *cmd, uint32_t status) 828 824 { 829 825 cmd->result &= ~(CAM_STATUS_MASK << 16); 830 826 cmd->result |= status << 16; ··· 837 833 } 838 834 839 835 static __inline 840 - void ahc_cmd_set_scsi_status(Scsi_Cmnd *cmd, uint32_t status) 836 + void ahc_cmd_set_scsi_status(struct scsi_cmnd *cmd, uint32_t status) 841 837 { 842 838 cmd->result &= ~0xFFFF; 843 839 cmd->result |= status; ··· 850 846 } 851 847 852 848 static __inline 853 - uint32_t ahc_cmd_get_transaction_status(Scsi_Cmnd *cmd) 849 + uint32_t ahc_cmd_get_transaction_status(struct scsi_cmnd *cmd) 854 850 { 855 851 return ((cmd->result >> 16) & CAM_STATUS_MASK); 856 852 } ··· 862 858 } 863 859 864 860 static __inline 865 - uint32_t ahc_cmd_get_scsi_status(Scsi_Cmnd *cmd) 861 + uint32_t ahc_cmd_get_scsi_status(struct scsi_cmnd *cmd) 866 862 { 867 863 return (cmd->result & 0xFFFF); 868 864 }
-1
drivers/scsi/aic7xxx/aiclib.c
··· 35 35 #include <linux/version.h> 36 36 37 37 /* Core SCSI definitions */ 38 - #include "scsi.h" 39 38 #include <scsi/scsi_host.h> 40 39 #include "aiclib.h" 41 40 #include "cam.h"