[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20201125163317.05b7e22b@kicinski-fedora-pc1c0hjn.dhcp.thefacebook.com>
Date: Wed, 25 Nov 2020 16:33:17 -0800
From: Jakub Kicinski <kuba@...nel.org>
To: Karsten Graul <kgraul@...ux.ibm.com>
Cc: David Miller <davem@...emloft.net>,
Heiko Carstens <hca@...ux.ibm.com>,
Stefan Raspl <raspl@...ux.ibm.com>, netdev@...r.kernel.org,
linux-s390@...r.kernel.org
Subject: Re: [PATCH net-next v5 12/14] net/smc: Add SMC-D Linkgroup
diagnostic support
On Tue, 24 Nov 2020 18:50:45 +0100 Karsten Graul wrote:
> +static int smc_nl_fill_smcd_lgr(struct smc_link_group *lgr,
> + struct sk_buff *skb,
> + struct netlink_callback *cb)
> +{
> + char smc_host[SMC_MAX_HOSTNAME_LEN + 1];
> + char smc_pnet[SMC_MAX_PNETID_LEN + 1];
> + char smc_eid[SMC_MAX_EID_LEN + 1];
> + struct nlattr *v2_attrs;
> + struct nlattr *attrs;
> + void *nlh;
> +
> + nlh = genlmsg_put(skb, NETLINK_CB(cb->skb).portid, cb->nlh->nlmsg_seq,
> + &smc_gen_nl_family, NLM_F_MULTI,
> + SMC_NETLINK_GET_LGR_SMCD);
> + if (!nlh)
> + return -EMSGSIZE;
In the previous patched you had a goto here. I prefer direct return,
but either way - please be consistent.
Powered by blists - more mailing lists