Re: [PATCH v3 12/15] scsi: virtio_scsi: Convert to scsi_execute_cmd

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

 



On 12/15/22 2:15 AM, Christoph Hellwig wrote:
> The conversion itself looks good, but how the f**k did we end up with
> a LLDD calling unquiry below the SCSI midlayer?

I don't know how it happened.

It looks like a hack around scsi_scan_host not removing devices.
Going forward, it looks like we can remove the inquiry code by having
scsi_scan_host be able to remove devices that are no longer returned.

However, there's an extra catch because they have that DID_BAD_TARGET
case where qemu returns VIRTIO_SCSI_S_BAD_TARGET if there are no devices
on the host, but other drivers uses that error code for a bunch of
different reasons.

I was thinking to handle the DID_BAD_TARGET use case above and this type
of issue:

https://lore.kernel.org/linux-scsi/CA+PODjqrRzyJnOKoabMOV4EPByNnL1LgTi+QAKENP3NwUq5YCw@xxxxxxxxxxxxxx/

maybe we want to have a driver level BLIST like:

static struct {
        char *driver;
        blist_flags_t flags;
} scsi_static_driver_list[] __initdata = {
        {"virtio_scsi", BLIST_REMOVE_ON_BAD_TARGET},
	{"aacard", BLIST_SHOW_DEV_PQ1},


One other question, can I do this work after the patchset in this email, the
scsi_cmnd retry patches and the actual PR ones? I keep going off track on these
side adventures.



[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