diff options
| author | Laurence Oberman <loberman@redhat.com> | 2026-07-23 12:37:43 -0400 |
|---|---|---|
| committer | Martin K. Petersen (Oracle) <mkp@kernel.org> | 2026-08-07 13:25:48 -0400 |
| commit | 4c84c2e08a36077d288ca28953b8818c4c1c0b79 (patch) | |
| tree | f36227c153b889702953e8c5dcec74fc883e161c /scripts | |
| parent | 8368367590c1f3be3039c78767f3d13129ee7026 (diff) | |
| download | linux-4c84c2e08a36077d288ca28953b8818c4c1c0b79.tar.gz linux-4c84c2e08a36077d288ca28953b8818c4c1c0b79.zip | |
scsi: storvsc: Support manual scans for all Hyper-V targets
The Fibre Channel transport topology created by storvsc exposes only one
dummy remote port per SCSI host. Its scsi_target_id is always zero.
As a result, the FC transport user-scan path looks up the remote port
using target ID 0. It cannot initiate a scan for Target 1 or higher. No
SCSI command is therefore sent to Hyper-V when userspace explicitly
requests a scan of one of these targets.
storvsc itself supports up to STORVSC_FC_MAX_TARGETS and already passes
scmnd->device->id to Hyper-V as vm_srb->target_id. Devices on Target 1
and higher work when initially discovered. They can also be rediscovered
by a full host scan, such as the scan triggered after an FC port bounce.
Provide a storvsc-specific user_scan callback that uses the exported
scsi_scan_target() interface. Iterate over the requested channel and
target ranges so that wildcard and explicitly addressed scans retain the
expected SCSI sysfs scan semantics.
This bypasses the single-rport lookup in fc_user_scan() and allows
userspace to explicitly scan any target supported by storvsc without
requiring one synthetic fc_rport for every Hyper-V target.
Signed-off-by: Laurence Oberman <loberman@redhat.com>
Link: https://patch.msgid.link/20260723163743.1274830-1-loberman@redhat.com
Signed-off-by: Martin K. Petersen (Oracle) <mkp@kernel.org>
Diffstat (limited to 'scripts')
0 files changed, 0 insertions, 0 deletions
