[PATCH blktests v2 04/13] nvme: introduce wwnn/wwpn helper functions
Hannes Reinecke
hare at suse.de
Wed Oct 30 00:21:04 PDT 2024
On 10/30/24 07:51, Shin'ichiro Kawasaki wrote:
> Commit "nvme: sanitize transport parameter in _create_nvmet_port()"
> modified the wwnn and wwpn names for fc transport to calculate from the
> port ID. It also moved the timing to set the global variable
> def_host_traddr based on the wwnn and wwpn from _setup_nvmet() to
> _create_nvmet_port(). This move made _nvme_connect_subsys() fail
> to refer to the def_host_traddr variable, and caused nvme/003 test case
> failure.
>
> To avoid the failure, do the wwnn and wwpn calculations both in
> _create_nvmet_port() and _nvme_connect_subsys(). Introduce helper
> functions to calculate wwnn and wwpn.
>
> Reviewed-by: Daniel Wagner <dwagner at suse.de>
> Signed-off-by: Shin'ichiro Kawasaki <shinichiro.kawasaki at wdc.com>
> ---
> common/nvme | 63 +++++++++++++++++++++++++++++++++++++----------------
> 1 file changed, 44 insertions(+), 19 deletions(-)
>
Hmm. This was not what my patchset did.
In my patchset I changed the 'logical' FC port setup in using _always_
the same local wwpn/wwnn, and only have the remote wwpn/wwnn modified
with the port id.
That way the host_traddr can be kept global throughout the code, and
we can calculate the remote wwpn/wwnn when creating the FC ports.
Cheers,
Hannes
--
Dr. Hannes Reinecke Kernel Storage Architect
hare at suse.de +49 911 74053 688
SUSE Software Solutions GmbH, Frankenstr. 146, 90461 Nürnberg
HRB 36809 (AG Nürnberg), GF: I. Totev, A. McDonald, W. Knoblich
More information about the Linux-nvme
mailing list