Re: [PATCH] 9p: fix privport option setting wrong RDMA field

Eric Sandeen <[email protected]> Fri, 3 Jul 2026 17:07:31 +0200
Newsgroups dev.linux.lists.v9fs,org.kernel.vger.linux-kernel,org.kernel.vger.stable
Message-ID <[email protected]>
On 7/3/26 12:22 PM, Stefano Garzarella wrote:
> From: Stefano Garzarella <[email protected]>
> 
> While reviewing a patch adding vsock transport to 9p, I noticed that
> since commit 1f3e4142c0eb ("9p: convert to the new mount API"), the
> Opt_privport case incorrectly sets rdma_opts->port instead of
> rdma_opts->privport, so mounting with the privport option overwrites
> the RDMA port number instead of enabling privileged port usage.
> 
> Fixes: 1f3e4142c0eb ("9p: convert to the new mount API")
> Cc: [email protected]
> Cc: [email protected]
> Signed-off-by: Stefano Garzarella <[email protected]>

Ugh, sorry about that.

Acked-by: Eric Sandeen <[email protected]>

> ---
>  fs/9p/v9fs.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/fs/9p/v9fs.c b/fs/9p/v9fs.c
> index 274c5157135d..f426cee37414 100644
> --- a/fs/9p/v9fs.c
> +++ b/fs/9p/v9fs.c
> @@ -406,7 +406,7 @@ int v9fs_parse_param(struct fs_context *fc, struct fs_parameter *param)
>  		break;
>  	case Opt_privport:
>  		fd_opts->privport = true;
> -		rdma_opts->port = true;
> +		rdma_opts->privport = true;
>  		break;
>  	}
>