On 6/11/25 2:50 AM, Stefano Garzarella wrote: > On Tue, Jun 10, 2025 at 11:30:58AM -0500, michael.chris...@oracle.com wrote: >> On 6/10/25 9:18 AM, Stefano Garzarella wrote: >>> On Sat, Jun 07, 2025 at 12:18:15PM -0500, Mike Christie wrote: >>>> As part of the normal initiator side scanning the guest's scsi layer >>>> will loop over all possible targets and send an inquiry. Since the >>>> max number of targets for virtio-scsi is 256, this results in 255 >>>> error messages about targets not existing. When there's more than 1 >>>> vhost-scsi device, then you get N * 255 log messages. >>>> >>>> It looks like the log message was added by accident in: >>>> >>>> commit 09d7583294aa ("vhost/scsi: Use common handling code in request >>>> queue handler") >>> >>> IIUC that commit just moved the code, but it looks like it was added by >>> commit 3f8ca2e115e5 ("vhost/scsi: Extract common handling code from >>> control queue handler") >> >> I saw that and was not 100% sure what patch to blame. >> >> Your commit adds the new vhost_scsi_get_req function which adds the >> vq_err call. It also hooks the control queue handler into it (control == >> SCSI task management like LUN_RESET). With just this patch we don't see >> a problem yet because the normal SCSI command handler is not using it yet. >> >> My commit hooks the normal SCSI command handler into the new >> vhost_scsi_get_req function. The SCSI command handler calling the new >> function is what hits the problem because it's the SCSI INQUIRY command >> going through this path during scanning that hits the problem. >> > > I see, thanks for the details. If you want, I'd expand the commit description > with part of this details, mentioning commit 3f8ca2e115e5, but keeping your > Fixes tag.
I'll fix it because the wording in my commit is wrong.