* Re: [PATCH] net/smc: fix wrong comparation in smc_pnet_add_pnetid [not found] <20241011061916.26310-1-lirongqing@baidu.com> @ 2024-10-12 7:49 ` Wen Gu 2024-10-14 5:41 ` D. Wythe 1 sibling, 0 replies; 4+ messages in thread From: Wen Gu @ 2024-10-12 7:49 UTC (permalink / raw) To: Li RongQing, wenjia, jaka, alibuda, tonylu, davem, edumazet, kuba, pabeni, ubraun, kgraul, linux-s390, netdev On 2024/10/11 14:19, Li RongQing wrote: > pnetid of pi (not newly allocated pe) should be compared > > Fixes: e888a2e8337c ("net/smc: introduce list of pnetids for Ethernet devices") > Signed-off-by: Li RongQing <lirongqing@baidu.com> > --- > net/smc/smc_pnet.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/net/smc/smc_pnet.c b/net/smc/smc_pnet.c > index 1dd3623..a04aa0e 100644 > --- a/net/smc/smc_pnet.c > +++ b/net/smc/smc_pnet.c > @@ -753,7 +753,7 @@ static int smc_pnet_add_pnetid(struct net *net, u8 *pnetid) > > write_lock(&sn->pnetids_ndev.lock); > list_for_each_entry(pi, &sn->pnetids_ndev.list, list) { > - if (smc_pnet_match(pnetid, pe->pnetid)) { > + if (smc_pnet_match(pnetid, pi->pnetid)) { > refcount_inc(&pi->refcnt); > kfree(pe); > goto unlock; Good catch, thanks! Reviewed-by: Wen Gu <guwen@linux.alibaba.com> ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] net/smc: fix wrong comparation in smc_pnet_add_pnetid [not found] <20241011061916.26310-1-lirongqing@baidu.com> 2024-10-12 7:49 ` [PATCH] net/smc: fix wrong comparation in smc_pnet_add_pnetid Wen Gu @ 2024-10-14 5:41 ` D. Wythe 2024-10-14 6:43 ` Gerd Bayer 1 sibling, 1 reply; 4+ messages in thread From: D. Wythe @ 2024-10-14 5:41 UTC (permalink / raw) To: Li RongQing, wenjia, jaka, tonylu, guwen, davem, edumazet, kuba, pabeni, ubraun, kgraul, linux-s390, netdev On 10/11/24 2:19 PM, Li RongQing wrote: > pnetid of pi (not newly allocated pe) should be compared > > Fixes: e888a2e8337c ("net/smc: introduce list of pnetids for Ethernet devices") > Signed-off-by: Li RongQing <lirongqing@baidu.com> > --- > net/smc/smc_pnet.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/net/smc/smc_pnet.c b/net/smc/smc_pnet.c > index 1dd3623..a04aa0e 100644 > --- a/net/smc/smc_pnet.c > +++ b/net/smc/smc_pnet.c > @@ -753,7 +753,7 @@ static int smc_pnet_add_pnetid(struct net *net, u8 *pnetid) > > write_lock(&sn->pnetids_ndev.lock); > list_for_each_entry(pi, &sn->pnetids_ndev.list, list) { > - if (smc_pnet_match(pnetid, pe->pnetid)) { > + if (smc_pnet_match(pnetid, pi->pnetid)) { > refcount_inc(&pi->refcnt); > kfree(pe); > goto unlock; Reviewed-by: D. Wythe <alibuda@linux.alibaba.com> Thanks, D. Wythe ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] net/smc: fix wrong comparation in smc_pnet_add_pnetid 2024-10-14 5:41 ` D. Wythe @ 2024-10-14 6:43 ` Gerd Bayer 2024-10-14 7:16 ` Gerd Bayer 0 siblings, 1 reply; 4+ messages in thread From: Gerd Bayer @ 2024-10-14 6:43 UTC (permalink / raw) To: D. Wythe, Li RongQing, wenjia, jaka, tonylu, guwen, davem, edumazet, kuba, pabeni, ubraun, kgraul, linux-s390, netdev Hi Li RongQing, On Mon, 2024-10-14 at 13:41 +0800, D. Wythe wrote: > On 10/11/24 2:19 PM, Li RongQing wrote: > > pnetid of pi (not newly allocated pe) should be compared > > > > Fixes: e888a2e8337c ("net/smc: introduce list of pnetids for > > Ethernet devices") > > Signed-off-by: Li RongQing <lirongqing@baidu.com> > > --- > > net/smc/smc_pnet.c | 2 +- > > 1 file changed, 1 insertion(+), 1 deletion(-) > > > > diff --git a/net/smc/smc_pnet.c b/net/smc/smc_pnet.c > > index 1dd3623..a04aa0e 100644 > > --- a/net/smc/smc_pnet.c > > +++ b/net/smc/smc_pnet.c > > @@ -753,7 +753,7 @@ static int smc_pnet_add_pnetid(struct net *net, > > u8 *pnetid) > > > > write_lock(&sn->pnetids_ndev.lock); > > list_for_each_entry(pi, &sn->pnetids_ndev.list, list) { > > - if (smc_pnet_match(pnetid, pe->pnetid)) { > > + if (smc_pnet_match(pnetid, pi->pnetid)) { > > refcount_inc(&pi->refcnt); > > kfree(pe); > > goto unlock; > > Reviewed-by: D. Wythe <alibuda@linux.alibaba.com> > > Thanks, > D. Wythe > Good catch, indeed! Is this intentionally discussed off-list? For consideration by netdev maintainers this will have to be re- submitted with a [PATCH net] prefix to the netdev mailing list. Also, I'd prefer, if you could find a more descriptive subject. How about: "Fix search in list of known pnetids"? However, if you want to keep the subject please replace "comparation" with "comparison" Thank you, Gerd Bayer ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] net/smc: fix wrong comparation in smc_pnet_add_pnetid 2024-10-14 6:43 ` Gerd Bayer @ 2024-10-14 7:16 ` Gerd Bayer 0 siblings, 0 replies; 4+ messages in thread From: Gerd Bayer @ 2024-10-14 7:16 UTC (permalink / raw) To: D. Wythe, Li RongQing, wenjia, jaka, tonylu, guwen, davem, edumazet, kuba, pabeni, ubraun, kgraul, linux-s390, netdev On Mon, 2024-10-14 at 08:43 +0200, Gerd Bayer wrote: > Hi Li RongQing, > > On Mon, 2024-10-14 at 13:41 +0800, D. Wythe wrote: > > On 10/11/24 2:19 PM, Li RongQing wrote: > > > pnetid of pi (not newly allocated pe) should be compared > > > > > > Fixes: e888a2e8337c ("net/smc: introduce list of pnetids for > > > Ethernet devices") > > > Signed-off-by: Li RongQing <lirongqing@baidu.com> > > > --- > > > net/smc/smc_pnet.c | 2 +- > > > 1 file changed, 1 insertion(+), 1 deletion(-) > > > > > > diff --git a/net/smc/smc_pnet.c b/net/smc/smc_pnet.c > > > index 1dd3623..a04aa0e 100644 > > > --- a/net/smc/smc_pnet.c > > > +++ b/net/smc/smc_pnet.c > > > @@ -753,7 +753,7 @@ static int smc_pnet_add_pnetid(struct net > > > *net, > > > u8 *pnetid) > > > > > > write_lock(&sn->pnetids_ndev.lock); > > > list_for_each_entry(pi, &sn->pnetids_ndev.list, list) { > > > - if (smc_pnet_match(pnetid, pe->pnetid)) { > > > + if (smc_pnet_match(pnetid, pi->pnetid)) { > > > refcount_inc(&pi->refcnt); > > > kfree(pe); > > > goto unlock; > > > > Reviewed-by: D. Wythe <alibuda@linux.alibaba.com> > > > > Thanks, > > D. Wythe > > > > Good catch, indeed! > > Is this intentionally discussed off-list? Oops - didn't read the entire To: list... > For consideration by netdev maintainers this will have to be re- > submitted with a [PATCH net] prefix to the netdev mailing list. > > Also, I'd prefer, if you could find a more descriptive subject. How > about: "Fix search in list of known pnetids"? However, if you want to > keep the subject please replace "comparation" with "comparison" > > Thank you, > Gerd Bayer > ^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2024-10-14 7:16 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <20241011061916.26310-1-lirongqing@baidu.com>
2024-10-12 7:49 ` [PATCH] net/smc: fix wrong comparation in smc_pnet_add_pnetid Wen Gu
2024-10-14 5:41 ` D. Wythe
2024-10-14 6:43 ` Gerd Bayer
2024-10-14 7:16 ` Gerd Bayer
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox