Re: [PATCH] nvme-fc: fix the fc_appid_store return value

Chaitanya Kulkarni
2022-08-07T09:21:54Z

On 8/6/22 01:32, Christoph Hellwig wrote:
> "nvme-fc: fold t fc_update_appid into fc_appid_store" accidentally
> changed the userspace interface for the appid attribute, because the code
> that decrements "count" to remove a trailing '\n' in the parsing results
> in the decremented value being incorrectly be returned from the sysfs
> write. Fix this by keeping an orig_count variable for the full length
> of the write.
>
> Fixes: c814153c83a8 ("nvme-fc: fold t fc_update_appid into fc_appid_store")
> Signed-off-by: Christoph Hellwig <hch@lst.de>
> Reviewed-by: Ewan D. Milne <emilne@redhat.com>
> Reviewed-by: James Smart <jsmart2021@gmail.com>
> Tested-by: Muneendra Kumar M <muneendra.kumar@broadcom.com>
> ---

Looks good.

Reviewed-by: Chaitanya Kulkarni <kch@nvidia.com>

-ck