Re: [PATCH 07/13] scsi: alua: Add scsi_alua_stpg_run()
From: John Garry
Date: Mon Mar 23 2026 - 10:38:59 EST
On 18/03/2026 09:24, Hannes Reinecke wrote:
Gnaa. Misread that one (blame lack of coffee).
It's not so nice to have the functionality spread out. The way I see it is that drivers/scsi/scsi_alua.c is mostly a library, but also has functionality to "drive" ALUA for native SCSI multipathing.
Anyway, can you confirm which of the following do you think from this series should be in scsi_dh_alua.c:
- scsi_alua_stpg_run()
- scsi_alua_stpg()
- submit_stpg()
You already said scsi_alua_stpg_run() should be.
stpg should be handled in scsi_dh_alua. Arguable
we could move the utility functions (submit_stpg
and maybe scsi_alua_stpg) in the core alua code,
but scsi_alua_stpg_run() should be kept in
scsi_dh_alua.
If that makes sense ...
scsi_alua_stpg_run() hardly does anything - scsi_alua_stpg() has the bulk of the functionality. I think that it's nicer to co-locate this functionality (with the rtpg code), as when we separate we have different code read/writing alua_data structure.
However, I have been hearing that SCSI core code only needs implicit support, so I can try that (which is keep everything STPG in scsi_dh_alua.c)
Thanks,
John