[PATCH libnvme 3/1] fabrics: add notify_rediscover parameter

Sagi Grimberg sagi at grimberg.me
Mon Sep 12 05:33:15 PDT 2022


>> @@ -481,6 +482,8 @@ static int build_options(nvme_host_t h, nvme_ctrl_t c, char **argstr)
>>   	    (hostid && add_argument(argstr, "hostid", hostid)) ||
>>   	    (discover && !discovery_nqn &&
>>   	     add_bool_argument(argstr, "discovery", true)) ||
>> +	     add_bool_argument(argstr, "notify_rediscover",
>> +			       cfg->notify_rediscover) ||
> 
> If notify_rediscover is not supported by the kernel, wouldn't this end
> up with an EINVAL when we try to connect? I thought we need to make this
> conditional.

The check is done by the callers, which check support for it. If it
is not supported and still passed, its a bug in the caller.



More information about the Linux-nvme mailing list