scsi/isp/isp_linux.c | 18 +++++++++--------- scsi/isp/isp_pci.c | 16 +++++++++++++--- 2 files changed, 22 insertions(+), 12 deletions(-) diff -puN drivers/scsi/isp/isp_linux.c~isp-update-1 drivers/scsi/isp/isp_linux.c --- 25/drivers/scsi/isp/isp_linux.c~isp-update-1 2003-02-18 13:19:18.000000000 -0800 +++ 25-akpm/drivers/scsi/isp/isp_linux.c 2003-02-18 13:19:18.000000000 -0800 @@ -944,7 +944,7 @@ isplinux_abort(Scsi_Cmnd *Cmnd) NewCmnd = isplinux_remove_from_doneq(Cmnd); wqfnd++; } - ISP_UNLKU_SOFTC(isp); + ISP_UNLK_SOFTC(isp); isp_prt(isp, ISP_LOGINFO, "isplinux_abort: found %d:%p for non-running cmd for %d.%d.%d", wqfnd, NewCmnd, XS_CHANNEL(Cmnd), XS_TGT(Cmnd), XS_LUN(Cmnd)); @@ -954,14 +954,14 @@ isplinux_abort(Scsi_Cmnd *Cmnd) } } else { if (isp_control(isp, ISPCTL_ABORT_CMD, Cmnd)) { - ISP_UNLKU_SOFTC(isp); + ISP_UNLK_SOFTC(isp); ISP_DRIVER_EXIT_LOCK(isp); return (FAILED); } if (isp->isp_nactive > 0) isp->isp_nactive--; isp_destroy_handle(isp, handle); - ISP_UNLKU_SOFTC(isp); + ISP_UNLK_SOFTC(isp); ISP_DRIVER_EXIT_LOCK(isp); isp_prt(isp, ISP_LOGINFO, "isplinux_abort: aborted running cmd (handle 0x%x) for %d.%d.%d", @@ -989,9 +989,9 @@ isplinux_bdr(Scsi_Cmnd *Cmnd) isp = XS_ISP(Cmnd); arg = XS_CHANNEL(Cmnd) << 16 | XS_TGT(Cmnd); ISP_DRIVER_ENTRY_LOCK(isp); - ISP_LOCKU_SOFTC(isp); + ISP_LOCK_SOFTC(isp); arg = isp_control(isp, ISPCTL_RESET_DEV, &arg); - ISP_UNLKU_SOFTC(isp); + ISP_UNLK_SOFTC(isp); ISP_DRIVER_EXIT_LOCK(isp); isp_prt(isp, ISP_LOGINFO, "Bus Device Reset %succesfully sent to %d.%d.%d", arg == 0? "s" : "uns", XS_CHANNEL(Cmnd), XS_TGT(Cmnd), XS_LUN(Cmnd)); @@ -1013,9 +1013,9 @@ isplinux_sreset(Scsi_Cmnd *Cmnd) isp = XS_ISP(Cmnd); arg = XS_CHANNEL(Cmnd); ISP_DRIVER_ENTRY_LOCK(isp); - ISP_LOCKU_SOFTC(isp); + ISP_LOCK_SOFTC(isp); arg = isp_control(isp, ISPCTL_RESET_BUS, &arg); - ISP_UNLKU_SOFTC(isp); + ISP_UNLK_SOFTC(isp); ISP_DRIVER_EXIT_LOCK(isp); isp_prt(isp, ISP_LOGINFO, "SCSI Bus Reset on Channel %d %succesful", XS_CHANNEL(Cmnd), arg == 0? "s" : "uns"); @@ -1041,7 +1041,7 @@ isplinux_hreset(Scsi_Cmnd *Cmnd) isp_prt(isp, ISP_LOGINFO, "Resetting Host Adapter"); ISP_DRIVER_ENTRY_LOCK(isp); - ISP_LOCKU_SOFTC(isp); + ISP_LOCK_SOFTC(isp); /* * Save pending, running, and completed commands. @@ -1069,7 +1069,7 @@ isplinux_hreset(Scsi_Cmnd *Cmnd) isplinux_reinit(isp); - ISP_UNLKU_SOFTC(isp); + ISP_UNLK_SOFTC(isp); ISP_DRIVER_EXIT_LOCK(isp); /* diff -puN drivers/scsi/isp/isp_pci.c~isp-update-1 drivers/scsi/isp/isp_pci.c --- 25/drivers/scsi/isp/isp_pci.c~isp-update-1 2003-02-18 13:19:18.000000000 -0800 +++ 25-akpm/drivers/scsi/isp/isp_pci.c 2003-02-18 13:20:11.000000000 -0800 @@ -377,12 +377,17 @@ isplinux_pci_addhost(Scsi_Host_Template isp->isp_next = isplist; isplist = isp; #if LINUX_VERSION_CODE >= KERNEL_VERSION(2,4,4) +#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,5,61) scsi_set_device(host, &pci_isp->pci_dev->dev); +#else + scsi_set_pci_device(host, pci_isp->pci_dev); +#endif #endif return (pci_isp); } -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,4,18) +#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,4,18) && \ + LINUX_VERSION_CODE < KERNEL_VERSION(2,5,0) #include static int isp_notify_reboot(struct notifier_block *ispnb, unsigned long Event, void *b) @@ -513,7 +518,11 @@ isplinux_pci_detect(Scsi_Host_Template * } } #endif -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,4,18) + /* + * Don't do reboot notifier stuff for 2.5.X yet + */ +#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,4,18) && \ + LINUX_VERSION_CODE < KERNEL_VERSION(2,5,0) if (isp_nfound) { register_reboot_notifier(&isp_notifier); } @@ -551,7 +560,8 @@ isplinux_pci_release(struct Scsi_Host *h RlsPages(FCPARAM(isp)->isp_scratch, 1); } #endif -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,4,18) +#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,4,18) && \ + LINUX_VERSION_CODE < KERNEL_VERSION(2,5,0) if (--isp_nfound <= 0) { unregister_reboot_notifier(&isp_notifier); } _