Commit f8c4e50d authored by Alan Cox's avatar Alan Cox Committed by Linus Torvalds

[PATCH] small scsi compile fixes

This is stuff like next: pointers that are not present rather than
anything bigger
parent ee29d109
......@@ -468,7 +468,6 @@ void tw_unmask_command_interrupt(TW_Device_Extension *tw_dev);
/* Scsi_Host_Template Initializer */
#define TWXXXX { \
next : NULL, \
module : NULL, \
proc_name : "3w-xxxx", \
proc_info : tw_scsi_proc_info, \
......
......@@ -37,18 +37,13 @@ extern const char *atp870u_info(struct Scsi_Host *);
extern int atp870u_proc_info(char *, char **, off_t, int, int, int);
#define ATP870U { \
next: NULL, \
module: NULL, \
proc_info: atp870u_proc_info, \
name: NULL, \
detect: atp870u_detect, \
release: atp870u_release, \
info: atp870u_info, \
command: atp870u_command, \
queuecommand: atp870u_queuecommand, \
eh_strategy_handler: NULL, \
eh_abort_handler: atp870u_abort, \
slave_attach: NULL, \
bios_param: atp870u_biosparam, \
can_queue: qcnt, /* max simultaneous cmds */\
this_id: 7, /* scsi id of host adapter */\
......
......@@ -28,6 +28,7 @@
#include <linux/proc_fs.h>
#include <linux/stat.h>
#include <linux/mca.h>
#include <linux/string.h>
#include <asm/system.h>
#include <linux/spinlock.h>
#include <asm/io.h>
......@@ -504,15 +505,16 @@ static void interrupt_handler (int irq, void *dev_id, struct pt_regs *regs)
unsigned long flags;
Scsi_Cmnd *cmd;
int lastSCSI;
struct Scsi_Host *dev = dev_id;
IBMLOCK(dev_id)
IBMLOCK(dev)
/* search for one adapter-response on shared interrupt */
for (host_index=0;
hosts[host_index] && !(inb(IM_STAT_REG(host_index)) & IM_INTR_REQUEST);
host_index++);
/* return if some other device on this IRQ caused the interrupt */
if (!hosts[host_index]) {
IBMUNLOCK(dev_id)
IBMUNLOCK(dev)
return;
}
......@@ -521,15 +523,16 @@ static void interrupt_handler (int irq, void *dev_id, struct pt_regs *regs)
if ((reset_status(host_index) == IM_RESET_NOT_IN_PROGRESS_NO_INT)||
(reset_status(host_index) == IM_RESET_FINISHED_OK_NO_INT)) {
reset_status(host_index) = IM_RESET_NOT_IN_PROGRESS;
IBMUNLOCK(dev_id)
IBMUNLOCK(dev)
return;
}
/*must wait for attention reg not busy, then send EOI to subsystem */
while (1) {
if (!(inb (IM_STAT_REG(host_index)) & IM_BUSY)) break;
IBMUNLOCK(dev_id) /* cycle interrupt */
IBMLOCK(dev_id)
IBMUNLOCK(dev) /* cycle interrupt */
cpu_relax();
IBMLOCK(dev)
}
ihost_index=host_index;
/*get command result and logical device */
......@@ -539,7 +542,7 @@ static void interrupt_handler (int irq, void *dev_id, struct pt_regs *regs)
/* get the last_scsi_command here */
lastSCSI = last_scsi_command(ihost_index)[ldn];
outb (IM_EOI | ldn, IM_ATTN_REG(ihost_index));
IBMUNLOCK(dev_id)
IBMUNLOCK(dev)
/*these should never happen (hw fails, or a local programming bug) */
if (!global_command_error_excuse) {
switch (cmd_result) {
......@@ -1435,12 +1438,13 @@ void internal_ibmmca_scsi_setup (char *str, int *ints)
return;
}
static int ibmmca_getinfo (char *buf, int slot, void *dev)
static int ibmmca_getinfo (char *buf, int slot, void *dev_id)
{
struct Scsi_Host *shpnt;
int len, speciale, connectore, k;
unsigned int pos[8];
unsigned long flags;
struct Scsi_Host *dev = dev_id;
IBMLOCK(dev)
shpnt = dev; /* assign host-structure to local pointer */
......
......@@ -199,6 +199,8 @@ int imm_detect(Scsi_Host_Template * host)
continue;
}
INIT_WORK(&imm_hosts[i].imm_tq, imm_interrupt, &imm_hosts[i]);
host->can_queue = IMM_CAN_QUEUE;
host->sg_tablesize = imm_sg;
hreg = scsi_register(host, 0);
......
......@@ -24,7 +24,6 @@
#include <linux/blk.h>
#include <linux/proc_fs.h>
#include <linux/stat.h>
#include <linux/tqueue.h>
#include <linux/interrupt.h>
#include <linux/reboot.h>
#include <linux/spinlock.h>
......
......@@ -201,6 +201,8 @@ int ppa_detect(Scsi_Host_Template * host)
default: /* Never gets here */
continue;
}
INIT_WORK(&ppa_hosts[i].ppa_tq, ppa_interrupt, &ppa_hosts[i]);
host->can_queue = PPA_CAN_QUEUE;
host->sg_tablesize = ppa_sg;
......
......@@ -1324,22 +1324,12 @@ void qla1280_setup(char *s, int *dummy);
*/
#define QLA1280_LINUX_TEMPLATE { \
next: NULL, \
module: NULL, \
proc_dir: NULL, \
proc_info: qla1280_proc_info, \
name: "Qlogic ISP 1280/12160", \
detect: qla1280_detect, \
release: qla1280_release, \
info: qla1280_info, \
ioctl: NULL, \
command: NULL, \
queuecommand: qla1280_queuecommand, \
eh_strategy_handler: NULL, \
eh_abort_handler: NULL, \
eh_device_reset_handler: NULL, \
eh_bus_reset_handler: NULL, \
eh_host_reset_handler: NULL, \
/* use_new_eh_code: 0, */ \
abort: qla1280_abort, \
reset: qla1280_reset, \
......
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