All of lore.kernel.org
 help / color / mirror / Atom feed
From: Lorenzo Bianconi <lorenzo@kernel.org>
To: Jakub Kicinski <kuba@kernel.org>
Cc: linux-nfs@vger.kernel.org, lorenzo.bianconi@redhat.com,
	neilb@suse.de, netdev@vger.kernel.org, jlayton@kernel.org
Subject: Re: [PATCH v5 2/3] NFSD: convert write_version to netlink command
Date: Thu, 30 Nov 2023 11:32:17 +0100	[thread overview]
Message-ID: <ZWhksS5C6mcvVPEN@lore-desk> (raw)
In-Reply-To: <20231129162832.4b36f96b@kernel.org>

[-- Attachment #1: Type: text/plain, Size: 1064 bytes --]

> On Wed, 29 Nov 2023 18:12:44 +0100 Lorenzo Bianconi wrote:
> > +      -
> > +        name: status
> > +        type: u8
> 
> u8? I guess...

here we need just 0 or 1 I would say. Do you suggest create something like an
enum?

> > +/**
> > + * nfsd_nl_version_get_doit - Handle verion_get dumpit
> 
> doesn't match the function name (do -> dump)

ack, I will fix it.

> 
> > +			/* NFSv{2,3} does not support minor numbers */
> > +			if (i < 4 && j)
> > +				continue;
> > +
> > +			if (i == 4 && !nfsd_minorversion(nn, j, NFSD_TEST))
> > +				continue;
> > +
> > +			hdr = genlmsg_put(skb, NETLINK_CB(cb->skb).portid,
> > +					  cb->nlh->nlmsg_seq, &nfsd_nl_family,
> > +					  0, NFSD_CMD_VERSION_GET);
> 
> Why not iput()?

ack, I will fix it.

Regards,
Lorenzo

> 
> > +			if (!hdr)
> > +				goto out;
> > +
> > +			if (nla_put_u32(skb, NFSD_A_SERVER_VERSION_MAJOR, i) ||
> > +			    nla_put_u32(skb, NFSD_A_SERVER_VERSION_MINOR, j))
> > +				goto out;
> > +
> > +			genlmsg_end(skb, hdr);
> > +		}
> > +	}
> 

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]

  reply	other threads:[~2023-11-30 10:32 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-11-29 17:12 [PATCH v5 0/3] convert write_threads, write_version and write_ports to netlink commands Lorenzo Bianconi
2023-11-29 17:12 ` [PATCH v5 1/3] NFSD: convert write_threads to netlink command Lorenzo Bianconi
2023-11-29 18:13   ` Jeff Layton
2023-11-29 18:31     ` Chuck Lever
2023-11-30  0:32       ` Jakub Kicinski
2023-11-29 17:12 ` [PATCH v5 2/3] NFSD: convert write_version " Lorenzo Bianconi
2023-11-29 18:23   ` Jeff Layton
2023-11-30  9:45     ` Lorenzo Bianconi
2023-11-30 16:17       ` Jeff Layton
2023-11-30 16:11     ` Chuck Lever
2023-11-30 16:25       ` Lorenzo Bianconi
2023-11-30 16:29         ` Chuck Lever
2023-11-30 16:32           ` Lorenzo Bianconi
2023-11-30  0:28   ` Jakub Kicinski
2023-11-30 10:32     ` Lorenzo Bianconi [this message]
2023-12-01  7:28       ` Jakub Kicinski
2023-12-05 20:33   ` Simon Horman
2023-11-29 17:12 ` [PATCH v5 3/3] NFSD: convert write_ports " Lorenzo Bianconi
2023-11-29 18:28   ` Jeff Layton
2023-11-30  9:57     ` Lorenzo Bianconi
2023-11-30 16:22       ` Jeff Layton
2023-11-30 16:55         ` Jeff Layton
2023-11-30 17:39           ` Chuck Lever
2023-11-30 18:01             ` Jeff Layton
2023-11-30 18:34               ` Chuck Lever
2023-12-05 20:37   ` Simon Horman

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=ZWhksS5C6mcvVPEN@lore-desk \
    --to=lorenzo@kernel.org \
    --cc=jlayton@kernel.org \
    --cc=kuba@kernel.org \
    --cc=linux-nfs@vger.kernel.org \
    --cc=lorenzo.bianconi@redhat.com \
    --cc=neilb@suse.de \
    --cc=netdev@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.