Re: scsi_debug driver puzzle

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 03/31/2014 06:32 PM, Laurence Oberman wrote:
>   File         Line
> 0 scsi_debug.c 3551 int scsi_debug_queuecommand_lck(struct scsi_cmnd
> *SCpnt, done_funct_t done)
> 1 scsi_debug.c 3900 static DEF_SCSI_QCMD(scsi_debug_queuecommand)
> 2 scsi_debug.c 3912 .queuecommand =  scsi_debug_queuecommand,

Magical scsi_host.h macro as part of the effort to push host_lock down.
The macro creates a function named as its argument which takes and drops
the shost->host_lock around a call to the real queuecommand function:

        spin_lock_irqsave(shost->host_lock, irq_flags);
        scsi_cmd_get_serial(shost, cmd);
        rc = func_name##_lck (cmd,cmd->scsi_done);
        spin_unlock_irqrestore(shost->host_lock, irq_flags);

http://fpaste.org/90345/88875139/

Cheers,
Bryn.
--
To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [SCSI Target Devel]     [Linux SCSI Target Infrastructure]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Samba]     [Device Mapper]
  Powered by Linux