[PATCH RESEND v3 1/2] nvme-multipath: introduce service-time iopolicy

Chaitanya Kulkarni chaitanyak at nvidia.com
Thu Nov 14 02:53:03 PST 2024


On 11/14/24 00:49, Guixin Liu wrote:
>   
> +static struct nvme_ns *nvme_service_time_path(struct nvme_ns_head *head)
> +{
> +	struct nvme_ns *opt = NULL, *nonopt = NULL, *ns;
> +	unsigned int min_inflight_nonopt = UINT_MAX;
> +	unsigned int min_inflight_opt = UINT_MAX;
> +	unsigned int inflight;
> +
> +	list_for_each_entry_rcu(ns, &head->list, siblings) {
> +		if (nvme_path_is_disabled(ns))
> +			continue;
> +
> +		inflight = atomic64_read(&ns->ctrl->inflight_size);

atomic64_read has return type s64, is there any particular reason not to use
s64 ? OR

even u64 as it is used in many places in kernel ? OR

conversion from s64 to unsigned int is done intentionally ?

-ck




More information about the Linux-nvme mailing list