diff options
| author | Linus Torvalds <torvalds@home.transmeta.com> | 2003-02-16 21:25:03 -0800 |
|---|---|---|
| committer | Linus Torvalds <torvalds@home.transmeta.com> | 2003-02-16 21:25:03 -0800 |
| commit | bb89c58c186082eb7918c67e6ef3b98ffdff24dc (patch) | |
| tree | a678df98cea946893713f967bd8d1b28c97609e3 /drivers | |
| parent | 5d4bd9bbb6302254c95305443b70649366ef957e (diff) | |
| parent | c90176df2c76e59abadb187368f15f3cde133dbc (diff) | |
Merge http://linux-sound.bkbits.net/linux-sound
into home.transmeta.com:/home/torvalds/v2.5/linux
Diffstat (limited to 'drivers')
27 files changed, 313 insertions, 330 deletions
diff --git a/drivers/acorn/block/fd1772.c b/drivers/acorn/block/fd1772.c index 9fbd6d828da8..1af34c29bf41 100644 --- a/drivers/acorn/block/fd1772.c +++ b/drivers/acorn/block/fd1772.c @@ -336,7 +336,7 @@ DECLARE_WORK(fd1772_tq, (void *)fd1772_checkint, NULL); */ static int Probing = 0; -/* This flag is set when a dummy seek is necesary to make the WP +/* This flag is set when a dummy seek is necessary to make the WP * status bit accessible. */ static int NeedSeek = 0; diff --git a/drivers/acorn/scsi/acornscsi.c b/drivers/acorn/scsi/acornscsi.c index ff126d11e6ad..ed4f7312b8cd 100644 --- a/drivers/acorn/scsi/acornscsi.c +++ b/drivers/acorn/scsi/acornscsi.c @@ -116,7 +116,7 @@ #ifdef DEBUG_TARGET #define DBG(cmd,xxx...) \ - if (cmd->target == DEBUG_TARGET) { \ + if (cmd->device->id == DEBUG_TARGET) { \ xxx; \ } #else @@ -575,7 +575,7 @@ static char acornscsi_target(AS_Host *host) { if (host->SCpnt) - return '0' + host->SCpnt->target; + return '0' + host->SCpnt->device->id; return 'H'; } @@ -742,7 +742,7 @@ intr_ret_t acornscsi_kick(AS_Host *host) * In this case, we don't want to write to the registers */ if (!(sbic_arm_read(host->scsi.io_port, ASR) & (ASR_INT|ASR_BSY|ASR_CIP))) { - sbic_arm_write(host->scsi.io_port, DESTID, SCpnt->target); + sbic_arm_write(host->scsi.io_port, DESTID, SCpnt->device->id); sbic_arm_write(host->scsi.io_port, CMND, CMND_SELWITHATN); } @@ -759,7 +759,7 @@ intr_ret_t acornscsi_kick(AS_Host *host) #if (DEBUG & (DEBUG_ABORT|DEBUG_CONNECT)) DBG(SCpnt,printk("scsi%d.%c: starting cmd %02X\n", - host->host->host_no, '0' + SCpnt->target, + host->host->host_no, '0' + SCpnt->device->id, SCpnt->cmnd[0])); #endif @@ -775,7 +775,7 @@ intr_ret_t acornscsi_kick(AS_Host *host) SCpnt->tag = SCpnt->device->current_tag; } else #endif - set_bit(SCpnt->target * 8 + SCpnt->lun, host->busyluns); + set_bit(SCpnt->device->id * 8 + SCpnt->device->lun, host->busyluns); host->stats.removes += 1; @@ -868,7 +868,7 @@ void acornscsi_done(AS_Host *host, Scsi_Cmnd **SCpntp, unsigned int result) host->host->host_no, SCpnt->result); print_command(SCpnt->cmnd); acornscsi_dumpdma(host, "done"); - acornscsi_dumplog(host, SCpnt->target); + acornscsi_dumplog(host, SCpnt->device->id); SCpnt->result &= 0xffff; SCpnt->result |= DID_ERROR << 16; } @@ -878,7 +878,7 @@ void acornscsi_done(AS_Host *host, Scsi_Cmnd **SCpntp, unsigned int result) if (!SCpnt->scsi_done) panic("scsi%d.H: null scsi_done function in acornscsi_done", host->host->host_no); - clear_bit(SCpnt->target * 8 + SCpnt->lun, host->busyluns); + clear_bit(SCpnt->device->id * 8 + SCpnt->device->lun, host->busyluns); SCpnt->scsi_done(SCpnt); } else @@ -1035,7 +1035,7 @@ void acornscsi_dma_setup(AS_Host *host, dmadir_t direction) if (direction == DMA_OUT) { #if (DEBUG & DEBUG_NO_WRITE) - if (NO_WRITE & (1 << host->SCpnt->target)) { + if (NO_WRITE & (1 << host->SCpnt->device->id)) { printk(KERN_CRIT "scsi%d.%c: I can't handle DMA_OUT!\n", host->host->host_no, acornscsi_target(host)); return; @@ -1511,7 +1511,7 @@ void acornscsi_message(AS_Host *host) if (host->scsi.phase != PHASE_STATUSIN) { printk(KERN_ERR "scsi%d.%c: command complete following non-status in phase?\n", host->host->host_no, acornscsi_target(host)); - acornscsi_dumplog(host, host->SCpnt->target); + acornscsi_dumplog(host, host->SCpnt->device->id); } host->scsi.phase = PHASE_DONE; host->scsi.SCp.Message = message[0]; @@ -1567,8 +1567,8 @@ void acornscsi_message(AS_Host *host) * transfer. Re-initiate sync transfer negociation now, and if * we got a REJECT in response to SDTR, then it'll be set to DONE. */ - if (host->device[host->SCpnt->target].sync_state == SYNC_SENT_REQUEST) - host->device[host->SCpnt->target].sync_state = SYNC_NEGOCIATE; + if (host->device[host->SCpnt->device->id].sync_state == SYNC_SENT_REQUEST) + host->device[host->SCpnt->device->id].sync_state = SYNC_NEGOCIATE; #endif /* @@ -1591,7 +1591,7 @@ void acornscsi_message(AS_Host *host) printk(KERN_NOTICE "scsi%d.%c: disabling tagged queueing\n", host->host->host_no, acornscsi_target(host)); host->SCpnt->device->tagged_queue = 0; - set_bit(host->SCpnt->target * 8 + host->SCpnt->lun, host->busyluns); + set_bit(host->SCpnt->device->id * 8 + host->SCpnt->device->lun, host->busyluns); break; #endif case EXTENDED_MESSAGE | (EXTENDED_SDTR << 8): @@ -1600,9 +1600,9 @@ void acornscsi_message(AS_Host *host) */ printk(KERN_NOTICE "scsi%d.%c: Using asynchronous transfer\n", host->host->host_no, acornscsi_target(host)); - host->device[host->SCpnt->target].sync_xfer = SYNCHTRANSFER_2DBA; - host->device[host->SCpnt->target].sync_state = SYNC_ASYNCHRONOUS; - sbic_arm_write(host->scsi.io_port, SYNCHTRANSFER, host->device[host->SCpnt->target].sync_xfer); + host->device[host->SCpnt->device->id].sync_xfer = SYNCHTRANSFER_2DBA; + host->device[host->SCpnt->device->id].sync_state = SYNC_ASYNCHRONOUS; + sbic_arm_write(host->scsi.io_port, SYNCHTRANSFER, host->device[host->SCpnt->device->id].sync_xfer); break; default: @@ -1625,18 +1625,18 @@ void acornscsi_message(AS_Host *host) switch (message[2]) { #ifdef CONFIG_SCSI_ACORNSCSI_SYNC case EXTENDED_SDTR: - if (host->device[host->SCpnt->target].sync_state == SYNC_SENT_REQUEST) { + if (host->device[host->SCpnt->device->id].sync_state == SYNC_SENT_REQUEST) { /* * We requested synchronous transfers. This isn't quite right... * We can only say if this succeeded if we proceed on to execute the * command from this message. If we get a MESSAGE PARITY ERROR, * and the target retries fail, then we fallback to asynchronous mode */ - host->device[host->SCpnt->target].sync_state = SYNC_COMPLETED; + host->device[host->SCpnt->device->id].sync_state = SYNC_COMPLETED; printk(KERN_NOTICE "scsi%d.%c: Using synchronous transfer, offset %d, %d ns\n", host->host->host_no, acornscsi_target(host), message[4], message[3] * 4); - host->device[host->SCpnt->target].sync_xfer = + host->device[host->SCpnt->device->id].sync_xfer = calc_sync_xfer(message[3] * 4, message[4]); } else { unsigned char period, length; @@ -1649,10 +1649,10 @@ void acornscsi_message(AS_Host *host) length = min_t(unsigned int, message[4], sdtr_size); msgqueue_addmsg(&host->scsi.msgs, 5, EXTENDED_MESSAGE, 3, EXTENDED_SDTR, period, length); - host->device[host->SCpnt->target].sync_xfer = + host->device[host->SCpnt->device->id].sync_xfer = calc_sync_xfer(period * 4, length); } - sbic_arm_write(host->scsi.io_port, SYNCHTRANSFER, host->device[host->SCpnt->target].sync_xfer); + sbic_arm_write(host->scsi.io_port, SYNCHTRANSFER, host->device[host->SCpnt->device->id].sync_xfer); break; #else /* We do not accept synchronous transfers. Respond with a @@ -1738,8 +1738,8 @@ void acornscsi_buildmessages(AS_Host *host) #endif msgqueue_addmsg(&host->scsi.msgs, 1, - IDENTIFY(host->device[host->SCpnt->target].disconnect_ok, - host->SCpnt->lun)); + IDENTIFY(host->device[host->SCpnt->device->id].disconnect_ok, + host->SCpnt->device->lun)); #if 0 /* does the device need the current command aborted */ @@ -1764,8 +1764,8 @@ void acornscsi_buildmessages(AS_Host *host) #endif #ifdef CONFIG_SCSI_ACORNSCSI_SYNC - if (host->device[host->SCpnt->target].sync_state == SYNC_NEGOCIATE) { - host->device[host->SCpnt->target].sync_state = SYNC_SENT_REQUEST; + if (host->device[host->SCpnt->device->id].sync_state == SYNC_NEGOCIATE) { + host->device[host->SCpnt->device->id].sync_state = SYNC_SENT_REQUEST; msgqueue_addmsg(&host->scsi.msgs, 5, EXTENDED_MESSAGE, 3, EXTENDED_SDTR, sdtr_period / 4, sdtr_size); @@ -1792,7 +1792,7 @@ int acornscsi_starttransfer(AS_Host *host) residual = host->SCpnt->request_bufflen - host->scsi.SCp.scsi_xferred; - sbic_arm_write(host->scsi.io_port, SYNCHTRANSFER, host->device[host->SCpnt->target].sync_xfer); + sbic_arm_write(host->scsi.io_port, SYNCHTRANSFER, host->device[host->SCpnt->device->id].sync_xfer); sbic_arm_writenext(host->scsi.io_port, residual >> 16); sbic_arm_writenext(host->scsi.io_port, residual >> 8); sbic_arm_writenext(host->scsi.io_port, residual); @@ -1828,7 +1828,7 @@ int acornscsi_reconnect(AS_Host *host) if (host->SCpnt && !host->scsi.disconnectable) { printk(KERN_ERR "scsi%d.%d: reconnected while command in " "progress to target %d?\n", - host->host->host_no, target, host->SCpnt->target); + host->host->host_no, target, host->SCpnt->device->id); host->SCpnt = NULL; } @@ -1839,7 +1839,7 @@ int acornscsi_reconnect(AS_Host *host) host->scsi.reconnected.tag = 0; if (host->scsi.disconnectable && host->SCpnt && - host->SCpnt->target == target && host->SCpnt->lun == lun) + host->SCpnt->device->id == target && host->SCpnt->device->lun == lun) ok = 1; if (!ok && queue_probetgtlun(&host->queues.disconnected, target, lun)) @@ -1876,9 +1876,9 @@ int acornscsi_reconnect_finish(AS_Host *host) { if (host->scsi.disconnectable && host->SCpnt) { host->scsi.disconnectable = 0; - if (host->SCpnt->target == host->scsi.reconnected.target && - host->SCpnt->lun == host->scsi.reconnected.lun && - host->SCpnt->tag == host->scsi.reconnected.tag) { + if (host->SCpnt->device->id == host->scsi.reconnected.target && + host->SCpnt->device->lun == host->scsi.reconnected.lun && + host->SCpnt->tag == host->scsi.reconnected.tag) { #if (DEBUG & (DEBUG_QUEUES|DEBUG_DISCON)) DBG(host->SCpnt, printk("scsi%d.%c: reconnected", host->host->host_no, acornscsi_target(host))); @@ -1992,7 +1992,7 @@ intr_ret_t acornscsi_sbicintr(AS_Host *host, int in_irq) ADD_STATUS(8, ssr, host->scsi.phase, in_irq); if (host->SCpnt && !host->scsi.disconnectable) - ADD_STATUS(host->SCpnt->target, ssr, host->scsi.phase, in_irq); + ADD_STATUS(host->SCpnt->device->id, ssr, host->scsi.phase, in_irq); switch (ssr) { case 0x00: /* reset state - not advanced */ @@ -2030,7 +2030,7 @@ intr_ret_t acornscsi_sbicintr(AS_Host *host, int in_irq) break; ssr = sbic_arm_read(host->scsi.io_port, SSR); ADD_STATUS(8, ssr, host->scsi.phase, 1); - ADD_STATUS(host->SCpnt->target, ssr, host->scsi.phase, 1); + ADD_STATUS(host->SCpnt->device->id, ssr, host->scsi.phase, 1); goto connected; case 0x42: /* select timed out */ @@ -2049,7 +2049,7 @@ intr_ret_t acornscsi_sbicintr(AS_Host *host, int in_irq) default: printk(KERN_ERR "scsi%d.%c: PHASE_CONNECTING, SSR %02X?\n", host->host->host_no, acornscsi_target(host), ssr); - acornscsi_dumplog(host, host->SCpnt ? host->SCpnt->target : 8); + acornscsi_dumplog(host, host->SCpnt ? host->SCpnt->device->id : 8); acornscsi_abortcmd(host, host->SCpnt->tag); } return INTR_PROCESSING; @@ -2085,7 +2085,7 @@ intr_ret_t acornscsi_sbicintr(AS_Host *host, int in_irq) default: printk(KERN_ERR "scsi%d.%c: PHASE_CONNECTED, SSR %02X?\n", host->host->host_no, acornscsi_target(host), ssr); - acornscsi_dumplog(host, host->SCpnt ? host->SCpnt->target : 8); + acornscsi_dumplog(host, host->SCpnt ? host->SCpnt->device->id : 8); acornscsi_abortcmd(host, host->SCpnt->tag); } return INTR_PROCESSING; @@ -2123,7 +2123,7 @@ intr_ret_t acornscsi_sbicintr(AS_Host *host, int in_irq) default: printk(KERN_ERR "scsi%d.%c: PHASE_MSGOUT, SSR %02X?\n", host->host->host_no, acornscsi_target(host), ssr); - acornscsi_dumplog(host, host->SCpnt ? host->SCpnt->target : 8); + acornscsi_dumplog(host, host->SCpnt ? host->SCpnt->device->id : 8); } return INTR_PROCESSING; @@ -2168,7 +2168,7 @@ intr_ret_t acornscsi_sbicintr(AS_Host *host, int in_irq) default: printk(KERN_ERR "scsi%d.%c: PHASE_COMMAND, SSR %02X?\n", host->host->host_no, acornscsi_target(host), ssr); - acornscsi_dumplog(host, host->SCpnt ? host->SCpnt->target : 8); + acornscsi_dumplog(host, host->SCpnt ? host->SCpnt->device->id : 8); } return INTR_PROCESSING; @@ -2181,7 +2181,7 @@ intr_ret_t acornscsi_sbicintr(AS_Host *host, int in_irq) } else { printk(KERN_ERR "scsi%d.%c: PHASE_DISCONNECT, SSR %02X instead of disconnect?\n", host->host->host_no, acornscsi_target(host), ssr); - acornscsi_dumplog(host, host->SCpnt ? host->SCpnt->target : 8); + acornscsi_dumplog(host, host->SCpnt ? host->SCpnt->device->id : 8); } return INTR_NEXT_COMMAND; @@ -2191,7 +2191,7 @@ intr_ret_t acornscsi_sbicintr(AS_Host *host, int in_irq) else { printk(KERN_ERR "scsi%d.%c: PHASE_IDLE, SSR %02X while idle?\n", host->host->host_no, acornscsi_target(host), ssr); - acornscsi_dumplog(host, host->SCpnt ? host->SCpnt->target : 8); + acornscsi_dumplog(host, host->SCpnt ? host->SCpnt->device->id : 8); } return INTR_PROCESSING; @@ -2206,7 +2206,7 @@ intr_ret_t acornscsi_sbicintr(AS_Host *host, int in_irq) */ if (ssr != 0x8f && !acornscsi_reconnect_finish(host)) return INTR_IDLE; - ADD_STATUS(host->SCpnt->target, ssr, host->scsi.phase, in_irq); + ADD_STATUS(host->SCpnt->device->id, ssr, host->scsi.phase, in_irq); switch (ssr) { case 0x88: /* data out phase */ /* -> PHASE_DATAOUT */ @@ -2251,7 +2251,7 @@ intr_ret_t acornscsi_sbicintr(AS_Host *host, int in_irq) default: printk(KERN_ERR "scsi%d.%c: PHASE_RECONNECTED, SSR %02X after reconnect?\n", host->host->host_no, acornscsi_target(host), ssr); - acornscsi_dumplog(host, host->SCpnt ? host->SCpnt->target : 8); + acornscsi_dumplog(host, host->SCpnt ? host->SCpnt->device->id : 8); } return INTR_PROCESSING; @@ -2300,7 +2300,7 @@ intr_ret_t acornscsi_sbicintr(AS_Host *host, int in_irq) default: printk(KERN_ERR "scsi%d.%c: PHASE_DATAIN, SSR %02X?\n", host->host->host_no, acornscsi_target(host), ssr); - acornscsi_dumplog(host, host->SCpnt ? host->SCpnt->target : 8); + acornscsi_dumplog(host, host->SCpnt ? host->SCpnt->device->id : 8); } return INTR_PROCESSING; @@ -2352,7 +2352,7 @@ intr_ret_t acornscsi_sbicintr(AS_Host *host, int in_irq) default: printk(KERN_ERR "scsi%d.%c: PHASE_DATAOUT, SSR %02X?\n", host->host->host_no, acornscsi_target(host), ssr); - acornscsi_dumplog(host, host->SCpnt ? host->SCpnt->target : 8); + acornscsi_dumplog(host, host->SCpnt ? host->SCpnt->device->id : 8); } return INTR_PROCESSING; @@ -2373,7 +2373,7 @@ intr_ret_t acornscsi_sbicintr(AS_Host *host, int in_irq) default: printk(KERN_ERR "scsi%d.%c: PHASE_STATUSIN, SSR %02X instead of MESSAGE_IN?\n", host->host->host_no, acornscsi_target(host), ssr); - acornscsi_dumplog(host, host->SCpnt ? host->SCpnt->target : 8); + acornscsi_dumplog(host, host->SCpnt ? host->SCpnt->device->id : 8); } return INTR_PROCESSING; @@ -2396,14 +2396,14 @@ intr_ret_t acornscsi_sbicintr(AS_Host *host, int in_irq) case 0x85: printk("scsi%d.%c: strange message in disconnection\n", host->host->host_no, acornscsi_target(host)); - acornscsi_dumplog(host, host->SCpnt ? host->SCpnt->target : 8); + acornscsi_dumplog(host, host->SCpnt ? host->SCpnt->device->id : 8); acornscsi_done(host, &host->SCpnt, DID_ERROR); break; default: printk(KERN_ERR "scsi%d.%c: PHASE_MSGIN, SSR %02X after message in?\n", host->host->host_no, acornscsi_target(host), ssr); - acornscsi_dumplog(host, host->SCpnt ? host->SCpnt->target : 8); + acornscsi_dumplog(host, host->SCpnt ? host->SCpnt->device->id : 8); } return INTR_PROCESSING; @@ -2421,7 +2421,7 @@ intr_ret_t acornscsi_sbicintr(AS_Host *host, int in_irq) default: printk(KERN_ERR "scsi%d.%c: PHASE_DONE, SSR %02X instead of disconnect?\n", host->host->host_no, acornscsi_target(host), ssr); - acornscsi_dumplog(host, host->SCpnt ? host->SCpnt->target : 8); + acornscsi_dumplog(host, host->SCpnt ? host->SCpnt->device->id : 8); } return INTR_PROCESSING; @@ -2447,14 +2447,14 @@ intr_ret_t acornscsi_sbicintr(AS_Host *host, int in_irq) default: printk(KERN_ERR "scsi%d.%c: PHASE_ABORTED, SSR %02X?\n", host->host->host_no, acornscsi_target(host), ssr); - acornscsi_dumplog(host, host->SCpnt ? host->SCpnt->target : 8); + acornscsi_dumplog(host, host->SCpnt ? host->SCpnt->device->id : 8); } return INTR_PROCESSING; default: printk(KERN_ERR "scsi%d.%c: unknown driver phase %d\n", host->host->host_no, acornscsi_target(host), ssr); - acornscsi_dumplog(host, host->SCpnt ? host->SCpnt->target : 8); + acornscsi_dumplog(host, host->SCpnt ? host->SCpnt->device->id : 8); } return INTR_PROCESSING; } @@ -2531,9 +2531,9 @@ int acornscsi_queuecmd(Scsi_Cmnd *SCpnt, void (*done)(Scsi_Cmnd *)) } #if (DEBUG & DEBUG_NO_WRITE) - if (acornscsi_cmdtype(SCpnt->cmnd[0]) == CMD_WRITE && (NO_WRITE & (1 << SCpnt->target))) { + if (acornscsi_cmdtype(SCpnt->cmnd[0]) == CMD_WRITE && (NO_WRITE & (1 << SCpnt->device->id))) { printk(KERN_CRIT "scsi%d.%c: WRITE attempted with NO_WRITE flag set\n", - SCpnt->host->host_no, '0' + SCpnt->target); + SCpnt->host->host_no, '0' + SCpnt->device->id); SCpnt->result = DID_NO_CONNECT << 16; done(SCpnt); return 0; @@ -2708,7 +2708,7 @@ int acornscsi_abort(Scsi_Cmnd *SCpnt) printk(KERN_WARNING "acornscsi_abort: "); print_sbic_status(asr, ssr, host->scsi.phase); - acornscsi_dumplog(host, SCpnt->target); + acornscsi_dumplog(host, SCpnt->device->id); } #endif @@ -2724,7 +2724,7 @@ int acornscsi_abort(Scsi_Cmnd *SCpnt) //#if (DEBUG & DEBUG_ABORT) printk("clear "); //#endif - clear_bit(SCpnt->target * 8 + SCpnt->lun, host->busyluns); + clear_bit(SCpnt->device->id * 8 + SCpnt->device->lun, host->busyluns); /* * We found the command, and cleared it out. Either @@ -2758,7 +2758,7 @@ int acornscsi_abort(Scsi_Cmnd *SCpnt) */ default: case res_not_running: - acornscsi_dumplog(host, SCpnt->target); + acornscsi_dumplog(host, SCpnt->device->id); #if (DEBUG & DEBUG_ABORT) result = SCSI_ABORT_SNOOZE; #else @@ -2796,7 +2796,7 @@ int acornscsi_reset(Scsi_Cmnd *SCpnt, unsigned int reset_flags) printk(KERN_WARNING "acornscsi_reset: "); print_sbic_status(asr, ssr, host->scsi.phase); - acornscsi_dumplog(host, SCpnt->target); + acornscsi_dumplog(host, SCpnt->device->id); } #endif diff --git a/drivers/acorn/scsi/fas216.c b/drivers/acorn/scsi/fas216.c index 5bdaf3ff9362..978d3d7e1a7f 100644 --- a/drivers/acorn/scsi/fas216.c +++ b/drivers/acorn/scsi/fas216.c @@ -96,6 +96,47 @@ static int level_mask = LOG_ERROR; +static int __init fas216_log_setup(char *str) +{ + char *s; + + level_mask = 0; + + while ((s = strsep(&str, ",")) != NULL) { + switch (s[0]) { + case 'a': + if (strcmp(s, "all") == 0) + level_mask |= -1; + break; + case 'b': + if (strncmp(s, "bus", 3) == 0) + level_mask |= LOG_BUSSERVICE; + if (strncmp(s, "buf", 3) == 0) + level_mask |= LOG_BUFFER; + break; + case 'c': + level_mask |= LOG_CONNECT; + break; + case 'e': + level_mask |= LOG_ERROR; + break; + case 'm': + level_mask |= LOG_MESSAGES; + break; + case 'n': + if (strcmp(s, "none") == 0) + level_mask = 0; + break; + case 's': + level_mask |= LOG_FUNCTIONDONE; + break; + } + } + return 1; +} + +__setup("fas216_logging=", fas216_log_setup); + static inline unsigned char fas216_readb(FAS216_Info *info, unsigned int reg) { unsigned int off = reg << info->scsi.io_shift; @@ -244,7 +285,7 @@ static const char *fas216_drv_phase(FAS216_Info *info) static char fas216_target(FAS216_Info *info) { if (info->SCpnt) - return '0' + info->SCpnt->target; + return '0' + info->SCpnt->device->id; else return 'H'; } @@ -267,7 +308,7 @@ fas216_log_command(FAS216_Info *info, int level, Scsi_Cmnd *SCpnt, char *fmt, .. return; va_start(args, fmt); - fas216_do_log(info, '0' + SCpnt->target, fmt, args); + fas216_do_log(info, '0' + SCpnt->device->id, fmt, args); va_end(args); printk(" CDB: "); @@ -495,7 +536,7 @@ static void fas216_set_sync(FAS216_Info *info, int target) */ static void fas216_handlesync(FAS216_Info *info, char *msg) { - struct fas216_device *dev = &info->device[info->SCpnt->target]; + struct fas216_device *dev = &info->device[info->SCpnt->device->id]; enum { sync, async, none, reject } res = none; #ifdef SCSI2_SYNC @@ -578,7 +619,7 @@ static void fas216_handlesync(FAS216_Info *info, char *msg) dev->period = msg[3]; dev->sof = msg[4]; dev->stp = fas216_syncperiod(info, msg[3] * 4); - fas216_set_sync(info, info->SCpnt->target); + fas216_set_sync(info, info->SCpnt->device->id); break; case reject: @@ -591,7 +632,7 @@ static void fas216_handlesync(FAS216_Info *info, char *msg) dev->period = info->ifcfg.asyncperiod / 4; dev->sof = 0; dev->stp = info->scsi.async_stp; - fas216_set_sync(info, info->SCpnt->target); + fas216_set_sync(info, info->SCpnt->device->id); break; case none: @@ -608,7 +649,7 @@ static void fas216_handlesync(FAS216_Info *info, char *msg) */ static void fas216_handlewide(FAS216_Info *info, char *msg) { - struct fas216_device *dev = &info->device[info->SCpnt->target]; + struct fas216_device *dev = &info->device[info->SCpnt->device->id]; enum { wide, bit8, none, reject } res = none; #ifdef SCSI2_WIDE @@ -725,7 +766,7 @@ static void fas216_updateptrs(FAS216_Info *info, int bytes_transferred) bytes_transferred -= SCp->this_residual; if (!next_SCp(SCp) && bytes_transferred) { printk(KERN_WARNING "scsi%d.%c: out of buffers\n", - info->host->host_no, '0' + info->SCpnt->target); + info->host->host_no, '0' + info->SCpnt->device->id); return; } } @@ -848,7 +889,7 @@ static void fas216_transfer(FAS216_Info *info) * use DMA mode. If we are using asynchronous transfers, we may * use DMA mode or PIO mode. */ - if (info->device[info->SCpnt->target].sof) + if (info->device[info->SCpnt->device->id].sof) dmatype = fasdma_real_all; else dmatype = fasdma_pio; @@ -1023,10 +1064,10 @@ fas216_reselected_intr(FAS216_Info *info) info->origSCpnt = SCpnt; info->SCpnt = NULL; - if (info->device[SCpnt->target].wide_state == neg_inprogress) - info->device[SCpnt->target].wide_state = neg_wait; - if (info->device[SCpnt->target].sync_state == neg_inprogress) - info->device[SCpnt->target].sync_state = neg_wait; + if (info->device[SCpnt->device->id].wide_state == neg_inprogress) + info->device[SCpnt->device->id].wide_state = neg_wait; + if (info->device[SCpnt->device->id].sync_state == neg_inprogress) + info->device[SCpnt->device->id].sync_state = neg_wait; } fas216_log(info, LOG_CONNECT, "reconnect phase=%02X", info->scsi.phase); @@ -1073,7 +1114,7 @@ fas216_reselected_intr(FAS216_Info *info) ok = 0; if (info->scsi.disconnectable && info->SCpnt && - info->SCpnt->target == target && info->SCpnt->lun == identify_msg) + info->SCpnt->device->id == target && info->SCpnt->device->lun == identify_msg) ok = 1; if (!ok && queue_probetgtlun(&info->queues.disconnected, target, identify_msg)) @@ -1118,15 +1159,15 @@ fas216_finish_reconnect(FAS216_Info *info) fas216_checkmagic(info); fas216_log(info, LOG_CONNECT, "Connected: %1x %1x %02x, reconnected: %1x %1x %02x", - info->SCpnt->target, info->SCpnt->lun, info->SCpnt->tag, + info->SCpnt->device->id, info->SCpnt->device->lun, info->SCpnt->tag, info->scsi.reconnected.target, info->scsi.reconnected.lun, info->scsi.reconnected.tag); if (info->scsi.disconnectable && info->SCpnt) { info->scsi.disconnectable = 0; - if (info->SCpnt->target == info->scsi.reconnected.target && - info->SCpnt->lun == info->scsi.reconnected.lun && - info->SCpnt->tag == info->scsi.reconnected.tag) { + if (info->SCpnt->device->id == info->scsi.reconnected.target && + info->SCpnt->device->lun == info->scsi.reconnected.lun && + info->SCpnt->tag == info->scsi.reconnected.tag) { fas216_log(info, LOG_CONNECT, "reconnected"); } else { queue_add_cmd_tail(&info->queues.disconnected, info->SCpnt); @@ -1617,13 +1658,13 @@ static void fas216_busservice_intr(FAS216_Info *info, unsigned int stat, unsigne * set of messages. If we have more than one byte to * send, we need to assert ATN again. */ - if (info->device[info->SCpnt->target].parity_check) { + if (info->device[info->SCpnt->device->id].parity_check) { /* * We were testing... good, the device * supports parity checking. */ - info->device[info->SCpnt->target].parity_check = 0; - info->device[info->SCpnt->target].parity_enabled = 1; + info->device[info->SCpnt->device->id].parity_check = 0; + info->device[info->SCpnt->device->id].parity_enabled = 1; fas216_writeb(info, REG_CNTL1, info->scsi.cfg[0]); } @@ -1831,11 +1872,11 @@ static void __fas216_start_command(FAS216_Info *info, Scsi_Cmnd *SCpnt) fas216_cmd(info, CMD_FLUSHFIFO); /* load bus-id and timeout */ - fas216_writeb(info, REG_SDID, BUSID(SCpnt->target)); + fas216_writeb(info, REG_SDID, BUSID(SCpnt->device->id)); fas216_writeb(info, REG_STIM, info->ifcfg.select_timeout); /* synchronous transfers */ - fas216_set_sync(info, SCpnt->target); + fas216_set_sync(info, SCpnt->device->id); tot_msglen = msgqueue_msglength(&info->scsi.msgs); @@ -1845,7 +1886,7 @@ static void __fas216_start_command(FAS216_Info *info, Scsi_Cmnd *SCpnt) int msgnr = 0, i; printk("scsi%d.%c: message out: ", - info->host->host_no, '0' + SCpnt->target); + info->host->host_no, '0' + SCpnt->device->id); while ((msg = msgqueue_getmsg(&info->scsi.msgs, msgnr++)) != NULL) { printk("{ "); for (i = 0; i < msg->length; i++) @@ -1923,7 +1964,7 @@ static void fas216_start_command(FAS216_Info *info, Scsi_Cmnd *SCpnt) info->SCpnt = SCpnt; info->dma.transfer_type = fasdma_none; - if (parity_test(info, SCpnt->target)) + if (parity_test(info, SCpnt->device->id)) fas216_writeb(info, REG_CNTL1, info->scsi.cfg[0] | CNTL1_PTE); else fas216_writeb(info, REG_CNTL1, info->scsi.cfg[0]); @@ -1932,13 +1973,13 @@ static void fas216_start_command(FAS216_Info *info, Scsi_Cmnd *SCpnt) * Don't allow request sense commands to disconnect. */ disconnect_ok = SCpnt->cmnd[0] != REQUEST_SENSE && - info->device[SCpnt->target].disconnect_ok; + info->device[SCpnt->device->id].disconnect_ok; /* * build outgoing message bytes */ msgqueue_flush(&info->scsi.msgs); - msgqueue_addmsg(&info->scsi.msgs, 1, IDENTIFY(disconnect_ok, SCpnt->lun)); + msgqueue_addmsg(&info->scsi.msgs, 1, IDENTIFY(disconnect_ok, SCpnt->device->lun)); /* * add tag message if required @@ -1948,8 +1989,8 @@ static void fas216_start_command(FAS216_Info *info, Scsi_Cmnd *SCpnt) do { #ifdef SCSI2_WIDE - if (info->device[SCpnt->target].wide_state == neg_wait) { - info->device[SCpnt->target].wide_state = neg_inprogress; + if (info->device[SCpnt->device->id].wide_state == neg_wait) { + info->device[SCpnt->device->id].wide_state = neg_inprogress; msgqueue_addmsg(&info->scsi.msgs, 4, EXTENDED_MESSAGE, 2, EXTENDED_WDTR, info->ifcfg.wide_max_size); @@ -1957,11 +1998,11 @@ static void fas216_start_command(FAS216_Info *info, Scsi_Cmnd *SCpnt) } #endif #ifdef SCSI2_SYNC - if ((info->device[SCpnt->target].sync_state == neg_wait || - info->device[SCpnt->target].sync_state == neg_complete) && + if ((info->device[SCpnt->device->id].sync_state == neg_wait || + info->device[SCpnt->device->id].sync_state == neg_complete) && (SCpnt->cmnd[0] == REQUEST_SENSE || SCpnt->cmnd[0] == INQUIRY)) { - info->device[SCpnt->target].sync_state = neg_inprogress; + info->device[SCpnt->device->id].sync_state = neg_inprogress; msgqueue_addmsg(&info->scsi.msgs, 5, EXTENDED_MESSAGE, 3, EXTENDED_SDTR, 1000 / info->ifcfg.clockrate, @@ -1988,7 +2029,7 @@ static void fas216_allocate_tag(FAS216_Info *info, Scsi_Cmnd *SCpnt) SCpnt->tag = SCpnt->device->current_tag; } else #endif - set_bit(SCpnt->target * 8 + SCpnt->lun, info->busyluns); + set_bit(SCpnt->device->id * 8 + SCpnt->device->lun, info->busyluns); info->stats.removes += 1; switch (SCpnt->cmnd[0]) { @@ -2033,11 +2074,11 @@ static void fas216_do_bus_device_reset(FAS216_Info *info, Scsi_Cmnd *SCpnt) fas216_cmd(info, CMD_FLUSHFIFO); /* load bus-id and timeout */ - fas216_writeb(info, REG_SDID, BUSID(SCpnt->target)); + fas216_writeb(info, REG_SDID, BUSID(SCpnt->device->id)); fas216_writeb(info, REG_STIM, info->ifcfg.select_timeout); /* synchronous transfers */ - fas216_set_sync(info, SCpnt->target); + fas216_set_sync(info, SCpnt->device->id); msg = msgqueue_getmsg(&info->scsi.msgs, 0); @@ -2102,7 +2143,7 @@ static void fas216_kick(FAS216_Info *info) if (info->scsi.disconnectable && info->SCpnt) { fas216_log(info, LOG_CONNECT, "moved command for %d to disconnected queue", - info->SCpnt->target); + info->SCpnt->device->id); queue_add_cmd_tail(&info->queues.disconnected, info->SCpnt); info->scsi.disconnectable = 0; info->SCpnt = NULL; @@ -2155,7 +2196,7 @@ fas216_devicereset_done(FAS216_Info *info, Scsi_Cmnd *SCpnt, unsigned int result static void fas216_rq_sns_done(FAS216_Info *info, Scsi_Cmnd *SCpnt, unsigned int result) { - fas216_log_target(info, LOG_CONNECT, SCpnt->target, + fas216_log_target(info, LOG_CONNECT, SCpnt->device->id, "request sense complete, result=0x%04x%02x%02x", result, SCpnt->SCp.Message, SCpnt->SCp.Status); @@ -2166,7 +2207,7 @@ fas216_rq_sns_done(FAS216_Info *info, Scsi_Cmnd *SCpnt, unsigned int result) * confuse the higher levels. */ memset(SCpnt->sense_buffer, 0, sizeof(SCpnt->sense_buffer)); -//printk("scsi%d.%c: sense buffer: ", info->host->host_no, '0' + SCpnt->target); +//printk("scsi%d.%c: sense buffer: ", info->host->host_no, '0' + SCpnt->device->id); //{ int i; for (i = 0; i < 32; i++) printk("%02x ", SCpnt->sense_buffer[i]); printk("\n"); } /* * Note that we don't set SCpnt->result, since that should @@ -2235,7 +2276,7 @@ fas216_std_done(FAS216_Info *info, Scsi_Cmnd *SCpnt, unsigned int result) default: printk(KERN_ERR "scsi%d.%c: incomplete data transfer " "detected: res=%08X ptr=%p len=%X CDB: ", - info->host->host_no, '0' + SCpnt->target, + info->host->host_no, '0' + SCpnt->device->id, SCpnt->result, info->scsi.SCp.ptr, info->scsi.SCp.this_residual); print_command(SCpnt->cmnd); @@ -2259,11 +2300,11 @@ request_sense: if (SCpnt->cmnd[0] == REQUEST_SENSE) goto done; - fas216_log_target(info, LOG_CONNECT, SCpnt->target, + fas216_log_target(info, LOG_CONNECT, SCpnt->device->id, "requesting sense"); memset(SCpnt->cmnd, 0, sizeof (SCpnt->cmnd)); SCpnt->cmnd[0] = REQUEST_SENSE; - SCpnt->cmnd[1] = SCpnt->lun << 5; + SCpnt->cmnd[1] = SCpnt->device->lun << 5; SCpnt->cmnd[4] = sizeof(SCpnt->sense_buffer); SCpnt->cmd_len = COMMAND_SIZE(SCpnt->cmnd[0]); SCpnt->SCp.buffer = NULL; @@ -2285,7 +2326,7 @@ request_sense: */ if (info->reqSCpnt) printk(KERN_WARNING "scsi%d.%c: loosing request command\n", - info->host->host_no, '0' + SCpnt->target); + info->host->host_no, '0' + SCpnt->device->id); info->reqSCpnt = SCpnt; } @@ -2324,7 +2365,7 @@ static void fas216_done(FAS216_Info *info, unsigned int result) if (info->scsi.SCp.ptr && info->scsi.SCp.this_residual == 0) { printk("scsi%d.%c: zero bytes left to transfer, but " "buffer pointer still valid: ptr=%p len=%08x CDB: ", - info->host->host_no, '0' + SCpnt->target, + info->host->host_no, '0' + SCpnt->device->id, info->scsi.SCp.ptr, info->scsi.SCp.this_residual); info->scsi.SCp.ptr = NULL; print_command(SCpnt->cmnd); @@ -2335,8 +2376,8 @@ static void fas216_done(FAS216_Info *info, unsigned int result) * the sense information, fas216_kick will re-assert the busy * status. */ - info->device[SCpnt->target].parity_check = 0; - clear_bit(SCpnt->target * 8 + SCpnt->lun, info->busyluns); + info->device[SCpnt->device->id].parity_check = 0; + clear_bit(SCpnt->device->id * 8 + SCpnt->device->lun, info->busyluns); fn = (void (*)(FAS216_Info *, Scsi_Cmnd *, unsigned int))SCpnt->host_scribble; fn(info, SCpnt, result); @@ -2365,7 +2406,7 @@ no_command: */ int fas216_queue_command(Scsi_Cmnd *SCpnt, void (*done)(Scsi_Cmnd *)) { - FAS216_Info *info = (FAS216_Info *)SCpnt->host->hostdata; + FAS216_Info *info = (FAS216_Info *)SCpnt->device->host->hostdata; int result; fas216_checkmagic(info); @@ -2412,7 +2453,7 @@ int fas216_queue_command(Scsi_Cmnd *SCpnt, void (*done)(Scsi_Cmnd *)) */ static void fas216_internal_done(Scsi_Cmnd *SCpnt) { - FAS216_Info *info = (FAS216_Info *)SCpnt->host->hostdata; + FAS216_Info *info = (FAS216_Info *)SCpnt->device->host->hostdata; fas216_checkmagic(info); @@ -2429,7 +2470,7 @@ static void fas216_internal_done(Scsi_Cmnd *SCpnt) */ int fas216_command(Scsi_Cmnd *SCpnt) { - FAS216_Info *info = (FAS216_Info *)SCpnt->host->hostdata; + FAS216_Info *info = (FAS216_Info *)SCpnt->device->host->hostdata; fas216_checkmagic(info); @@ -2555,7 +2596,7 @@ static enum res_find fas216_find_command(FAS216_Info *info, Scsi_Cmnd *SCpnt) * been set. */ info->origSCpnt = NULL; - clear_bit(SCpnt->target * 8 + SCpnt->lun, info->busyluns); + clear_bit(SCpnt->device->id * 8 + SCpnt->device->lun, info->busyluns); printk("waiting for execution "); res = res_success; } else @@ -2574,7 +2615,7 @@ static enum res_find fas216_find_command(FAS216_Info *info, Scsi_Cmnd *SCpnt) */ int fas216_eh_abort(Scsi_Cmnd *SCpnt) { - FAS216_Info *info = (FAS216_Info *)SCpnt->host->hostdata; + FAS216_Info *info = (FAS216_Info *)SCpnt->device->host->hostdata; int result = FAILED; fas216_checkmagic(info); @@ -2631,9 +2672,9 @@ int fas216_eh_abort(Scsi_Cmnd *SCpnt) */ int fas216_eh_device_reset(Scsi_Cmnd *SCpnt) { - FAS216_Info *info = (FAS216_Info *)SCpnt->host->hostdata; + FAS216_Info *info = (FAS216_Info *)SCpnt->device->host->hostdata; unsigned long flags; - int i, res = FAILED, target = SCpnt->target; + int i, res = FAILED, target = SCpnt->device->id; fas216_log(info, LOG_ERROR, "device reset for target %d", target); @@ -2647,7 +2688,7 @@ int fas216_eh_device_reset(Scsi_Cmnd *SCpnt) * and we need a bus reset. */ if (info->SCpnt && !info->scsi.disconnectable && - info->SCpnt->target == SCpnt->target) + info->SCpnt->device->id == SCpnt->device->id) break; /* @@ -2658,9 +2699,9 @@ int fas216_eh_device_reset(Scsi_Cmnd *SCpnt) */ queue_remove_all_target(&info->queues.issue, target); queue_remove_all_target(&info->queues.disconnected, target); - if (info->origSCpnt && info->origSCpnt->target == target) + if (info->origSCpnt && info->origSCpnt->device->id == target) info->origSCpnt = NULL; - if (info->reqSCpnt && info->reqSCpnt->target == target) + if (info->reqSCpnt && info->reqSCpnt->device->id == target) info->reqSCpnt = NULL; for (i = 0; i < 8; i++) clear_bit(target * 8 + i, info->busyluns); @@ -2712,7 +2753,7 @@ int fas216_eh_device_reset(Scsi_Cmnd *SCpnt) */ int fas216_eh_bus_reset(Scsi_Cmnd *SCpnt) { - FAS216_Info *info = (FAS216_Info *)SCpnt->host->hostdata; + FAS216_Info *info = (FAS216_Info *)SCpnt->device->host->hostdata; unsigned long flags; Scsi_Device *SDpnt; @@ -2750,9 +2791,9 @@ int fas216_eh_bus_reset(Scsi_Cmnd *SCpnt) queue_remove_all_target(&info->queues.issue, SDpnt->id); queue_remove_all_target(&info->queues.disconnected, SDpnt->id); - if (info->origSCpnt && info->origSCpnt->target == SDpnt->id) + if (info->origSCpnt && info->origSCpnt->device->id == SDpnt->id) info->origSCpnt = NULL; - if (info->reqSCpnt && info->reqSCpnt->target == SDpnt->id) + if (info->reqSCpnt && info->reqSCpnt->device->id == SDpnt->id) info->reqSCpnt = NULL; info->SCpnt = NULL; @@ -2809,12 +2850,12 @@ static void fas216_init_chip(FAS216_Info *info) */ int fas216_eh_host_reset(Scsi_Cmnd *SCpnt) { - FAS216_Info *info = (FAS216_Info *)SCpnt->host->hostdata; + FAS216_Info *info = (FAS216_Info *)SCpnt->device->host->hostdata; fas216_checkmagic(info); printk("scsi%d.%c: %s: resetting host\n", - info->host->host_no, '0' + SCpnt->target, __FUNCTION__); + info->host->host_no, '0' + SCpnt->device->id, __FUNCTION__); /* * Reset the SCSI chip. diff --git a/drivers/acorn/scsi/queue.c b/drivers/acorn/scsi/queue.c index b7e585490122..eae5a8d180df 100644 --- a/drivers/acorn/scsi/queue.c +++ b/drivers/acorn/scsi/queue.c @@ -170,7 +170,7 @@ Scsi_Cmnd *queue_remove_exclude(Queue_t *queue, unsigned long *exclude) spin_lock_irqsave(&queue->queue_lock, flags); list_for_each(l, &queue->head) { QE_t *q = list_entry(l, QE_t, list); - if (!test_bit(q->SCpnt->target * 8 + q->SCpnt->lun, exclude)) { + if (!test_bit(q->SCpnt->device->id * 8 + q->SCpnt->device->lun, exclude)) { SCpnt = __queue_remove(queue, l); break; } @@ -217,7 +217,7 @@ Scsi_Cmnd *queue_remove_tgtluntag (Queue_t *queue, int target, int lun, int tag) spin_lock_irqsave(&queue->queue_lock, flags); list_for_each(l, &queue->head) { QE_t *q = list_entry(l, QE_t, list); - if (q->SCpnt->target == target && q->SCpnt->lun == lun && + if (q->SCpnt->device->id == target && q->SCpnt->device->lun == lun && q->SCpnt->tag == tag) { SCpnt = __queue_remove(queue, l); break; @@ -243,7 +243,7 @@ void queue_remove_all_target(Queue_t *queue, int target) spin_lock_irqsave(&queue->queue_lock, flags); list_for_each(l, &queue->head) { QE_t *q = list_entry(l, QE_t, list); - if (q->SCpnt->target == target) + if (q->SCpnt->device->id == target) __queue_remove(queue, l); } spin_unlock_irqrestore(&queue->queue_lock, flags); @@ -267,7 +267,7 @@ int queue_probetgtlun (Queue_t *queue, int target, int lun) spin_lock_irqsave(&queue->queue_lock, flags); list_for_each(l, &queue->head) { QE_t *q = list_entry(l, QE_t, list); - if (q->SCpnt->target == target && q->SCpnt->lun == lun) { + if (q->SCpnt->device->id == target && q->SCpnt->device->lun == lun) { found = 1; break; } diff --git a/drivers/acorn/scsi/scsi.h b/drivers/acorn/scsi/scsi.h index 0eb2c8a0daae..c3d78d39e470 100644 --- a/drivers/acorn/scsi/scsi.h +++ b/drivers/acorn/scsi/scsi.h @@ -92,8 +92,8 @@ static inline void init_SCp(Scsi_Cmnd *SCpnt) if (SCpnt->request_bufflen != len) printk(KERN_WARNING "scsi%d.%c: bad request buffer " - "length %d, should be %ld\n", SCpnt->host->host_no, - '0' + SCpnt->target, SCpnt->request_bufflen, len); + "length %d, should be %ld\n", SCpnt->device->host->host_no, + '0' + SCpnt->device->id, SCpnt->request_bufflen, len); SCpnt->request_bufflen = len; #endif } else { diff --git a/drivers/acpi/thermal.c b/drivers/acpi/thermal.c index 7f4cac66fb97..c72f8a1594a3 100644 --- a/drivers/acpi/thermal.c +++ b/drivers/acpi/thermal.c @@ -436,7 +436,7 @@ acpi_thermal_call_usermode ( envp[0] = "HOME=/"; envp[1] = "PATH=/sbin:/bin:/usr/sbin:/usr/bin"; - call_usermodehelper(argv[0], argv, envp); + call_usermodehelper(argv[0], argv, envp, 0); return_VALUE(0); } diff --git a/drivers/base/hotplug.c b/drivers/base/hotplug.c index 6c66892b23cb..503522d25906 100644 --- a/drivers/base/hotplug.c +++ b/drivers/base/hotplug.c @@ -114,7 +114,7 @@ static int do_hotplug (struct device *dev, char *argv1, const char *action, pr_debug ("%s: %s %s %s %s %s %s\n", __FUNCTION__, argv [0], argv[1], envp[0], envp[1], envp[2], envp[3]); - retval = call_usermodehelper (argv [0], argv, envp); + retval = call_usermodehelper (argv [0], argv, envp, 0); if (retval) pr_debug ("%s - call_usermodehelper returned %d\n", __FUNCTION__, retval); diff --git a/drivers/block/deadline-iosched.c b/drivers/block/deadline-iosched.c index d49754178f5a..012269836bef 100644 --- a/drivers/block/deadline-iosched.c +++ b/drivers/block/deadline-iosched.c @@ -297,6 +297,9 @@ static void deadline_remove_request(request_queue_t *q, struct request *rq) deadline_del_drq_rb(dd, drq); } + if (q->last_merge == &rq->queuelist) + q->last_merge = NULL; + list_del_init(&rq->queuelist); } @@ -424,12 +427,7 @@ deadline_move_to_dispatch(struct deadline_data *dd, struct deadline_rq *drq) { request_queue_t *q = drq->request->q; - if (q->last_merge == &drq->request->queuelist) - q->last_merge = NULL; - - deadline_del_drq_hash(drq); - deadline_del_drq_rb(dd, drq); - list_del_init(&drq->fifo); + deadline_remove_request(q, drq->request); list_add_tail(&drq->request->queuelist, dd->dispatch); } diff --git a/drivers/block/elevator.c b/drivers/block/elevator.c index 5a1183f014b9..f2986f88282e 100644 --- a/drivers/block/elevator.c +++ b/drivers/block/elevator.c @@ -399,7 +399,7 @@ struct request *elv_former_request(request_queue_t *q, struct request *rq) elevator_t *e = &q->elevator; if (e->elevator_former_req_fn) - return e->elevator_latter_req_fn(q, rq); + return e->elevator_former_req_fn(q, rq); prev = rq->queuelist.prev; if (prev != &q->queue_head && prev != &rq->queuelist) diff --git a/drivers/bluetooth/bt3c_cs.c b/drivers/bluetooth/bt3c_cs.c index de14aeafa20c..b755a362dc11 100644 --- a/drivers/bluetooth/bt3c_cs.c +++ b/drivers/bluetooth/bt3c_cs.c @@ -24,18 +24,14 @@ #include <linux/config.h> #include <linux/module.h> -#define __KERNEL_SYSCALLS__ - #include <linux/kernel.h> #include <linux/kmod.h> #include <linux/init.h> #include <linux/slab.h> #include <linux/types.h> #include <linux/sched.h> -#include <linux/delay.h> #include <linux/timer.h> #include <linux/errno.h> -#include <linux/unistd.h> #include <linux/ptrace.h> #include <linux/ioport.h> #include <linux/spinlock.h> @@ -405,7 +401,6 @@ void bt3c_interrupt(int irq, void *dev_inst, struct pt_regs *regs) - /* ======================== HCI interface ======================== */ @@ -489,65 +484,23 @@ static int bt3c_hci_ioctl(struct hci_dev *hdev, unsigned int cmd, unsigned long #define FW_LOADER "/sbin/bluefw" -static int errno; - - -static int bt3c_fw_loader_exec(void *dev) -{ - char *argv[] = { FW_LOADER, "pccard", dev, NULL }; - char *envp[] = { "HOME=/", "TERM=linux", "PATH=/sbin:/usr/sbin:/bin:/usr/bin", NULL }; - int err; - - err = exec_usermodehelper(FW_LOADER, argv, envp); - if (err) - printk(KERN_WARNING "bt3c_cs: Failed to exec \"%s pccard %s\".\n", FW_LOADER, (char *)dev); - - return err; -} static int bt3c_firmware_load(bt3c_info_t *info) { - sigset_t tmpsig; char dev[16]; - pid_t pid; - int result; + int err; - /* Check if root fs is mounted */ - if (!current->fs->root) { - printk(KERN_WARNING "bt3c_cs: Root filesystem is not mounted.\n"); - return -EPERM; - } + char *argv[] = { FW_LOADER, "pccard", dev, NULL }; + char *envp[] = { "HOME=/", "TERM=linux", "PATH=/sbin:/usr/sbin:/bin:/usr/bin", NULL }; sprintf(dev, "%04x", info->link.io.BasePort1); - pid = kernel_thread(bt3c_fw_loader_exec, (void *)dev, 0); - if (pid < 0) { - printk(KERN_WARNING "bt3c_cs: Forking of kernel thread failed (errno=%d).\n", -pid); - return pid; - } - - /* Block signals, everything but SIGKILL/SIGSTOP */ - spin_lock_irq(¤t->sighand->siglock); - tmpsig = current->blocked; - siginitsetinv(¤t->blocked, sigmask(SIGKILL) | sigmask(SIGSTOP)); - recalc_sigpending(); - spin_unlock_irq(¤t->sighand->siglock); - - result = waitpid(pid, NULL, __WCLONE); - - /* Allow signals again */ - spin_lock_irq(¤t->sighand->siglock); - current->blocked = tmpsig; - recalc_sigpending(); - spin_unlock_irq(¤t->sighand->siglock); - - if (result != pid) { - printk(KERN_WARNING "bt3c_cs: Waiting for pid %d failed (errno=%d).\n", pid, -result); - return -result; - } + err = call_usermodehelper(FW_LOADER, argv, envp, 1); + if (err) + printk(KERN_WARNING "bt3c_cs: Failed to run \"%s pccard %s\" (errno=%d).\n", FW_LOADER, dev, err); - return 0; + return err; } diff --git a/drivers/char/rio/rioboot.c b/drivers/char/rio/rioboot.c index 7bfa59a1ce88..095c674ff9bd 100644 --- a/drivers/char/rio/rioboot.c +++ b/drivers/char/rio/rioboot.c @@ -410,7 +410,7 @@ register struct DownLoad *rbp; ** compatible with the whole Tp family. (lies, damn lies, it'll never ** work in a month of Sundays). ** - ** The nfix nyble is the 1s compliment of the nyble value you + ** The nfix nyble is the 1s complement of the nyble value you ** want to load - in this case we wanted 'F' so we nfix loaded '0'. */ diff --git a/drivers/char/watchdog/wdt285.c b/drivers/char/watchdog/wdt285.c index c9a6fac7404d..4670d3d2d4f6 100644 --- a/drivers/char/watchdog/wdt285.c +++ b/drivers/char/watchdog/wdt285.c @@ -37,18 +37,14 @@ */ #undef ONLY_TESTING -#define TIMER_MARGIN 60 /* (secs) Default is 1 minute */ - -#define FCLK (50*1000*1000) /* 50MHz */ - -static int soft_margin = TIMER_MARGIN; /* in seconds */ -static int timer_alive; +static unsigned int soft_margin = 60; /* in seconds */ +static unsigned int reload; +static unsigned long timer_alive; #ifdef ONLY_TESTING /* * If the timer expires.. */ - static void watchdog_fire(int irq, void *dev_id, struct pt_regs *regs) { printk(KERN_CRIT "Watchdog: Would Reboot.\n"); @@ -57,109 +53,134 @@ static void watchdog_fire(int irq, void *dev_id, struct pt_regs *regs) } #endif +/* + * Refresh the timer. + */ static void watchdog_ping(void) { - /* - * Refresh the timer. - */ - *CSR_TIMER4_LOAD = soft_margin * (FCLK / 256); + *CSR_TIMER4_LOAD = reload; } /* * Allow only one person to hold it open */ - static int watchdog_open(struct inode *inode, struct file *file) { - if(timer_alive) + int ret; + + if (*CSR_SA110_CNTL & (1 << 13)) return -EBUSY; - /* - * Ahead watchdog factor ten, Mr Sulu - */ + + if (test_and_set_bit(1, &timer_alive)) + return -EBUSY; + + reload = soft_margin * (mem_fclk_21285 / 256); + *CSR_TIMER4_CLR = 0; watchdog_ping(); *CSR_TIMER4_CNTL = TIMER_CNTL_ENABLE | TIMER_CNTL_AUTORELOAD | TIMER_CNTL_DIV256; + #ifdef ONLY_TESTING - request_irq(IRQ_TIMER4, watchdog_fire, 0, "watchdog", NULL); + ret = request_irq(IRQ_TIMER4, watchdog_fire, 0, "watchdog", NULL); + if (ret) { + *CSR_TIMER4_CNTL = 0; + clear_bit(1, &timer_alive); + } #else + /* + * Setting this bit is irreversible; once enabled, there is + * no way to disable the watchdog. + */ *CSR_SA110_CNTL |= 1 << 13; - MOD_INC_USE_COUNT; + + ret = 0; #endif - timer_alive = 1; - return 0; + return ret; } +/* + * Shut off the timer. + * Note: if we really have enabled the watchdog, there + * is no way to turn off. + */ static int watchdog_release(struct inode *inode, struct file *file) { #ifdef ONLY_TESTING free_irq(IRQ_TIMER4, NULL); - timer_alive = 0; -#else - /* - * It's irreversible! - */ + clear_bit(1, &timer_alive); #endif return 0; } -static ssize_t watchdog_write(struct file *file, const char *data, size_t len, loff_t *ppos) +static ssize_t +watchdog_write(struct file *file, const char *data, size_t len, loff_t *ppos) { - /* Can't seek (pwrite) on this device */ + /* Can't seek (pwrite) on this device */ if (ppos != &file->f_pos) return -ESPIPE; /* * Refresh the timer. */ - if(len) - { + if (len) watchdog_ping(); - return 1; - } - return 0; + + return len; } -static int watchdog_ioctl(struct inode *inode, struct file *file, - unsigned int cmd, unsigned long arg) +static struct watchdog_info ident = { + .options = WDIOF_SETTIMEOUT, + .identity = "Footbridge Watchdog" +}; + +static int +watchdog_ioctl(struct inode *inode, struct file *file, unsigned int cmd, + unsigned long arg) { - int i, new_margin; - static struct watchdog_info ident= - { - WDIOF_SETTIMEOUT, - 0, - "Footbridge Watchdog" - }; - switch(cmd) - { - default: - return -ENOTTY; - case WDIOC_GETSUPPORT: - if(copy_to_user((struct watchdog_info *)arg, &ident, sizeof(ident))) - return -EFAULT; - return 0; - case WDIOC_GETSTATUS: - case WDIOC_GETBOOTSTATUS: - return put_user(0,(int *)arg); - case WDIOC_KEEPALIVE: - watchdog_ping(); - return 0; - case WDIOC_SETTIMEOUT: - if (get_user(new_margin, (int *)arg)) - return -EFAULT; - /* Arbitrary, can't find the card's limits */ - if ((new_marg < 0) || (new_margin > 60)) - return -EINVAL; - soft_margin = new_margin; - watchdog_ping(); - /* Fall */ - case WDIOC_GETTIMEOUT: - return put_user(soft_margin, (int *)arg); + unsigned int new_margin; + int ret = -ENOIOCTLCMD; + + switch(cmd) { + case WDIOC_GETSUPPORT: + ret = 0; + if (copy_to_user((void *)arg, &ident, sizeof(ident))) + ret = -EFAULT; + break; + + case WDIOC_GETSTATUS: + case WDIOC_GETBOOTSTATUS: + ret = put_user(0,(int *)arg); + break; + + case WDIOC_KEEPALIVE: + watchdog_ping(); + ret = 0; + break; + + case WDIOC_SETTIMEOUT: + ret = get_user(new_margin, (int *)arg); + if (ret) + break; + + /* Arbitrary, can't find the card's limits */ + if (new_margin < 0 || new_margin > 60) { + ret = -EINVAL; + break; + } + + soft_margin = new_margin; + reload = soft_margin * (mem_fclk_21285 / 256); + watchdog_ping(); + /* Fall */ + case WDIOC_GETTIMEOUT: + ret = put_user(soft_margin, (int *)arg); + break; } + return ret; } -static struct file_operations watchdog_fops= -{ +static struct file_operations watchdog_fops = { .owner = THIS_MODULE, .write = watchdog_write, .ioctl = watchdog_ioctl, @@ -167,11 +188,10 @@ static struct file_operations watchdog_fops= .release = watchdog_release, }; -static struct miscdevice watchdog_miscdev= -{ - WATCHDOG_MINOR, - "watchdog", - &watchdog_fops +static struct miscdevice watchdog_miscdev = { + .minor = WATCHDOG_MINOR, + .name = "watchdog", + .fops = &watchdog_fops }; static int __init footbridge_watchdog_init(void) @@ -182,11 +202,12 @@ static int __init footbridge_watchdog_init(void) return -ENODEV; retval = misc_register(&watchdog_miscdev); - if(retval < 0) + if (retval < 0) return retval; printk("Footbridge Watchdog Timer: 0.01, timer margin: %d sec\n", soft_margin); + if (machine_is_cats()) printk("Warning: Watchdog reset may not work on this machine.\n"); return 0; @@ -198,7 +219,7 @@ static void __exit footbridge_watchdog_exit(void) } MODULE_AUTHOR("Phil Blundell <pb@nexus.co.uk>"); -MODULE_DESCRIPTION("21285 watchdog driver"); +MODULE_DESCRIPTION("Footbridge watchdog driver"); MODULE_LICENSE("GPL"); MODULE_PARM(soft_margin,"i"); diff --git a/drivers/char/watchdog/wdt977.c b/drivers/char/watchdog/wdt977.c index 49925dadfe55..80a4a7daebb6 100644 --- a/drivers/char/watchdog/wdt977.c +++ b/drivers/char/watchdog/wdt977.c @@ -58,7 +58,7 @@ MODULE_PARM_DESC(nowayout, "Watchdog cannot be stopped once started (default=CON /* This is kicking the watchdog by simply re-writing the timeout to reg. 0xF2 */ -int kick_wdog(void) +static int kick_wdog(void) { /* * Refresh the timer. @@ -216,21 +216,20 @@ static int wdt977_release(struct inode *inode, struct file *file) static ssize_t wdt977_write(struct file *file, const char *buf, size_t count, loff_t *ppos) { - /* Can't seek (pwrite) on this device */ + /* Can't seek (pwrite) on this device */ if (ppos != &file->f_pos) return -ESPIPE; - if(count) - { + if (count) { if (!nowayout) { size_t i; /* In case it was set long ago */ expect_close = 0; - for (i = 0; i != len; i++) { + for (i = 0; i != count; i++) { char c; - if (get_user(c, data + i)) + if (get_user(c, buf + i)) return -EFAULT; if (c == 'V') expect_close = 1; @@ -238,9 +237,8 @@ static ssize_t wdt977_write(struct file *file, const char *buf, size_t count, lo } kick_wdog(); - return 1; } - return 0; + return count; } /* @@ -254,14 +252,15 @@ static ssize_t wdt977_write(struct file *file, const char *buf, size_t count, lo * according to their available features. */ -static int wdt977_ioctl(struct inode *inode, struct file *file, - unsigned int cmd, unsigned long arg) -{ static struct watchdog_info ident = { - .identity = "Winbond 83977" + .options = WDIOF_SETTIMEOUT, + .identity = "Winbond 83977" }; -int temp; +static int wdt977_ioctl(struct inode *inode, struct file *file, + unsigned int cmd, unsigned long arg) +{ + int temp; switch(cmd) { @@ -337,9 +336,9 @@ static struct file_operations wdt977_fops= static struct miscdevice wdt977_miscdev= { - WATCHDOG_MINOR, - "watchdog", - &wdt977_fops + .minor = WATCHDOG_MINOR, + .name = "watchdog", + .fops = &wdt977_fops }; static int __init nwwatchdog_init(void) @@ -360,4 +359,5 @@ static void __exit nwwatchdog_exit(void) module_init(nwwatchdog_init); module_exit(nwwatchdog_exit); +MODULE_DESCRIPTION("W83977AF Watchdog driver"); MODULE_LICENSE("GPL"); diff --git a/drivers/ide/pci/amd74xx.c b/drivers/ide/pci/amd74xx.c index d837f3a76812..fe4647c6c340 100644 --- a/drivers/ide/pci/amd74xx.c +++ b/drivers/ide/pci/amd74xx.c @@ -311,7 +311,7 @@ unsigned int __init init_chipset_amd74xx(struct pci_dev *dev, const char *name) amd_80w = ((u & 0x3) ? 1 : 0) | ((u & 0xc) ? 2 : 0); for (i = 24; i >= 0; i -= 8) if (((u >> i) & 4) && !(amd_80w & (1 << (1 - (i >> 4))))) { - printk(KERN_WARNING "AMD_IDE: Bios didn't set cable bits corectly. Enabling workaround.\n"); + printk(KERN_WARNING "AMD_IDE: Bios didn't set cable bits correctly. Enabling workaround.\n"); amd_80w |= (1 << (1 - (i >> 4))); } break; diff --git a/drivers/ieee1394/nodemgr.c b/drivers/ieee1394/nodemgr.c index ef8a00dc076e..970aa1e09de6 100644 --- a/drivers/ieee1394/nodemgr.c +++ b/drivers/ieee1394/nodemgr.c @@ -786,7 +786,7 @@ static void nodemgr_call_policy(char *verb, struct unit_directory *ud) #ifdef CONFIG_IEEE1394_VERBOSEDEBUG HPSB_DEBUG("NodeMgr: %s %s %016Lx", argv[0], verb, (long long unsigned)ud->ne->guid); #endif - value = call_usermodehelper(argv[0], argv, envp); + value = call_usermodehelper(argv[0], argv, envp, 0); kfree(buf); kfree(envp); if (value != 0) diff --git a/drivers/input/input.c b/drivers/input/input.c index fdfe4150aafa..30796fc98f74 100644 --- a/drivers/input/input.c +++ b/drivers/input/input.c @@ -383,7 +383,7 @@ static void input_call_hotplug(char *verb, struct input_dev *dev) argv[0], argv[1], envp[0], envp[1], envp[2], envp[3], envp[4]); #endif - value = call_usermodehelper(argv [0], argv, envp); + value = call_usermodehelper(argv [0], argv, envp, 0); kfree(buf); kfree(envp); diff --git a/drivers/input/serio/sa1111ps2.c b/drivers/input/serio/sa1111ps2.c index df3466ca660d..f4c69da7c7bd 100644 --- a/drivers/input/serio/sa1111ps2.c +++ b/drivers/input/serio/sa1111ps2.c @@ -9,6 +9,7 @@ */ #include <linux/module.h> #include <linux/init.h> +#include <linux/input.h> #include <linux/serio.h> #include <linux/errno.h> #include <linux/interrupt.h> @@ -339,6 +340,7 @@ static struct sa1111_driver ps2_driver = { .drv = { .name = "sa1111-ps2", .bus = &sa1111_bus_type, + .devclass = &input_devclass, .probe = ps2_probe, .remove = ps2_remove, .suspend = ps2_suspend, diff --git a/drivers/isdn/hardware/eicon/divasmain.c b/drivers/isdn/hardware/eicon/divasmain.c index bac79a46bd73..7bc8c445c7cf 100644 --- a/drivers/isdn/hardware/eicon/divasmain.c +++ b/drivers/isdn/hardware/eicon/divasmain.c @@ -263,7 +263,7 @@ static void diva_adapter_trapped(void *context) pdpc->card_failed = 0; argv[2] = &adapter[0]; - ret = call_usermodehelper(argv[0], argv, envp); + ret = call_usermodehelper(argv[0], argv, envp, 0); if (ret) { printk(KERN_ERR diff --git a/drivers/isdn/hisax/amd7930_fn.c b/drivers/isdn/hisax/amd7930_fn.c index 40085c40e448..e62bac451ae7 100644 --- a/drivers/isdn/hisax/amd7930_fn.c +++ b/drivers/isdn/hisax/amd7930_fn.c @@ -176,7 +176,7 @@ Amd7930_new_ph(struct IsdnCardState *cs) cs->dc.amd7930.old_state = cs->dc.amd7930.ph_state; - /* abort transmit if nessesary */ + /* abort transmit if necessary */ if ((message & 0xf0) && (cs->tx_skb)) { wByteAMD(cs, 0x21, 0xC2); wByteAMD(cs, 0x21, 0x02); diff --git a/drivers/mtd/chips/jedec.c b/drivers/mtd/chips/jedec.c index 337d0d22bfb0..507b7e513c17 100644 --- a/drivers/mtd/chips/jedec.c +++ b/drivers/mtd/chips/jedec.c @@ -754,7 +754,7 @@ static int flash_write(struct mtd_info *mtd, loff_t start, size_t len, size_t *retlen, const u_char *buf) { /* Does IO to the currently selected chip. It takes the bank addressing - base (which is divisable by the chip size) adds the necesary lower bits + base (which is divisible by the chip size) adds the necessary lower bits of addrshift (interleve index) and then adds the control register index. */ #define flread(x) map->read8(map,base+(off&((1<<chip->addrshift)-1))+((x)<<chip->addrshift)) #define flwrite(v,x) map->write8(map,v,base+(off&((1<<chip->addrshift)-1))+((x)<<chip->addrshift)) diff --git a/drivers/mtd/maps/sa1100-flash.c b/drivers/mtd/maps/sa1100-flash.c index 78e67542fbac..d85f6c42fa23 100644 --- a/drivers/mtd/maps/sa1100-flash.c +++ b/drivers/mtd/maps/sa1100-flash.c @@ -773,14 +773,15 @@ static struct mtd_partition stork_partitions[] = { #ifdef CONFIG_SA1100_TRIZEPS static struct mtd_partition trizeps_partitions[] = { { - .name = "Bootloader & the kernel", - .size = 0x00200000, + .name = "Bootloader", + .size = 0x00100000, .offset = 0, }, { - .name = "Data", - .size = 0x00400000, + .name = "Kernel", + .size = 0x00100000, .offset = MTDPART_OFS_APPEND, }, { + .name = "root", .size = MTDPART_SIZ_FULL, .offset = MTDPART_OFS_APPEND, } @@ -937,7 +938,7 @@ static int __init sa1100_static_partitions(struct mtd_partition **parts) #ifdef CONFIG_SA1100_TRIZEPS if (machine_is_trizeps()) { *parts = trizeps_partitions; - nb_parts = ARRAY_SIZE(trizeps_parititons); + nb_parts = ARRAY_SIZE(trizeps_partitions); } #endif #ifdef CONFIG_SA1100_YOPY diff --git a/drivers/net/8139too.c b/drivers/net/8139too.c index 084ff5219678..a846aa9ea76c 100644 --- a/drivers/net/8139too.c +++ b/drivers/net/8139too.c @@ -1589,7 +1589,7 @@ static int rtl8139_thread (void *data) unsigned long timeout; daemonize("%s", dev->name); - allow_signal(SIGKILL); + allow_signal(SIGTERM); while (1) { timeout = next_tick; diff --git a/drivers/net/hamradio/baycom_epp.c b/drivers/net/hamradio/baycom_epp.c index 93237b2af18a..0842e54df8bd 100644 --- a/drivers/net/hamradio/baycom_epp.c +++ b/drivers/net/hamradio/baycom_epp.c @@ -369,15 +369,14 @@ static char eppconfig_path[256] = "/usr/sbin/eppfpga"; static char *envp[] = { "HOME=/", "TERM=linux", "PATH=/usr/bin:/bin", NULL }; -static int errno; - -static int exec_eppfpga(void *b) +/* eppconfig: called during ifconfig up to configure the modem */ +static int eppconfig(struct baycom_state *bc) { - struct baycom_state *bc = (struct baycom_state *)b; char modearg[256]; char portarg[16]; - char *argv[] = { eppconfig_path, "-s", "-p", portarg, "-m", modearg, NULL}; - int i; + char *argv[] = { eppconfig_path, "-s", "-p", portarg, "-m", modearg, + NULL }; + int ret; /* set up arguments */ sprintf(modearg, "%sclk,%smodem,fclk=%d,bps=%d,divider=%d%s,extstat", @@ -388,39 +387,7 @@ static int exec_eppfpga(void *b) sprintf(portarg, "%ld", bc->pdev->port->base); printk(KERN_DEBUG "%s: %s -s -p %s -m %s\n", bc_drvname, eppconfig_path, portarg, modearg); - i = exec_usermodehelper(eppconfig_path, argv, envp); - if (i < 0) { - printk(KERN_ERR "%s: failed to exec %s -s -p %s -m %s, errno = %d\n", - bc_drvname, eppconfig_path, portarg, modearg, i); - return i; - } - return 0; -} - - -/* eppconfig: called during ifconfig up to configure the modem */ - -static int eppconfig(struct baycom_state *bc) -{ - int i, pid, r; - mm_segment_t fs; - - pid = kernel_thread(exec_eppfpga, bc, CLONE_FS); - if (pid < 0) { - printk(KERN_ERR "%s: fork failed, errno %d\n", bc_drvname, -pid); - return pid; - } - fs = get_fs(); - set_fs(KERNEL_DS); /* Allow i to be in kernel space. */ - r = waitpid(pid, &i, __WCLONE); - set_fs(fs); - if (r != pid) { - printk(KERN_ERR "%s: waitpid(%d) failed, returning %d\n", - bc_drvname, pid, r); - return -1; - } - printk(KERN_DEBUG "%s: eppfpga returned %d\n", bc_drvname, i); - return i; + return call_usermodehelper(eppconfig_path, argv, envp, 1); } /* ---------------------------------------------------------------------- */ diff --git a/drivers/net/shaper.c b/drivers/net/shaper.c index 633d82960e60..ca371597680f 100644 --- a/drivers/net/shaper.c +++ b/drivers/net/shaper.c @@ -681,7 +681,7 @@ static int shapers = 1; #ifdef MODULE MODULE_PARM(shapers, "i"); -MODULE_PARM_DESC(shapers, "Traffic shaper: maximum nuber of shapers"); +MODULE_PARM_DESC(shapers, "Traffic shaper: maximum number of shapers"); #else /* MODULE */ diff --git a/drivers/pnp/pnpbios/core.c b/drivers/pnp/pnpbios/core.c index 82944c33a021..cde17aa6823b 100644 --- a/drivers/pnp/pnpbios/core.c +++ b/drivers/pnp/pnpbios/core.c @@ -602,7 +602,7 @@ static int pnp_dock_event(int dock, struct pnp_docking_station_info *info) info->location_id, info->serial, info->capabilities); envp[i] = 0; - value = call_usermodehelper (argv [0], argv, envp); + value = call_usermodehelper (argv [0], argv, envp, 0); kfree (buf); kfree (envp); return 0; diff --git a/drivers/scsi/aic7xxx/aic79xx.reg b/drivers/scsi/aic7xxx/aic79xx.reg index 0138ca271031..2d22db151c8d 100644 --- a/drivers/scsi/aic7xxx/aic79xx.reg +++ b/drivers/scsi/aic7xxx/aic79xx.reg @@ -3725,7 +3725,7 @@ scratch_ram { /* * The minimum number of commands still outstanding required - * to continue coalessing (2's compliment of value). + * to continue coalessing (2's complement of value). */ INT_COALESSING_MINCMDS { size 1 diff --git a/drivers/usb/image/scanner.c b/drivers/usb/image/scanner.c index 50b62d9f17d8..41c1f21f4221 100644 --- a/drivers/usb/image/scanner.c +++ b/drivers/usb/image/scanner.c @@ -54,7 +54,7 @@ * allocation/registration for linux-2.3.22+. * - Adopted David Brownell's <david-b@pacbell.net> technique for * assigning bulk endpoints. - * - Removed unnessesary #include's + * - Removed unnecessary #include's * - Scanner model now reported via syslog INFO after being detected * *and* configured. * - Added user specified vendor:product USB ID's which can be passed |
