On Fri, Sep 27, 2024 at 02:59:42PM +0800, duanqiangwen@xxxxxxxxxxxxx wrote: > > -----Original Message----- > > From: 'Greg Kroah-Hartman' <gregkh@xxxxxxxxxxxxxxxxxxx> > > Sent: 2024年9月27日 14:53 > > To: duanqiangwen@xxxxxxxxxxxxx > > Cc: stable@xxxxxxxxxxxxxxx; patches@xxxxxxxxxxxxxxx; 'David S. Miller' > > <davem@xxxxxxxxxxxxx>; 'Sasha Levin' <sashal@xxxxxxxxxx> > > Subject: Re: [PATCH 6.6 044/186] net: libwx: fix alloc msix vectors failed > > > > On Fri, Sep 27, 2024 at 10:02:14AM +0800, duanqiangwen@xxxxxxxxxxxxx > > wrote: > > > > -----Original Message----- > > > > From: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx> > > > > Sent: 2024年4月30日 18:38 > > > > To: stable@xxxxxxxxxxxxxxx > > > > Cc: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx>; > > > > patches@xxxxxxxxxxxxxxx; Duanqiang Wen <duanqiangwen@net- > > swift.com>; > > > > David S. Miller <davem@xxxxxxxxxxxxx>; Sasha Levin > > > > <sashal@xxxxxxxxxx> > > > > Subject: [PATCH 6.6 044/186] net: libwx: fix alloc msix vectors > > > > failed > > > > > > > > 6.6-stable review patch. If anyone has any objections, please let > > > > me > > > know. > > > > > > > > ------------------ > > > > > > > > From: Duanqiang Wen <duanqiangwen@xxxxxxxxxxxxx> > > > > > > > > [ Upstream commit 69197dfc64007b5292cc960581548f41ccd44828 ] > > > > > > > > driver needs queue msix vectors and one misc irq vector, but only > > > > queue vectors need irq affinity. > > > > when num_online_cpus is less than chip max msix vectors, driver will > > > acquire > > > > (num_online_cpus + 1) vecotrs, and call > > > > pci_alloc_irq_vectors_affinity functions with affinity params > > > > without setting pre_vectors or > > > post_vectors, it > > > > will cause return error code -ENOSPC. > > > > Misc irq vector is vector 0, driver need to set affinity params > > > .pre_vectors = 1. > > > > > > > > Fixes: 3f703186113f ("net: libwx: Add irq flow functions") > > > > Signed-off-by: Duanqiang Wen <duanqiangwen@xxxxxxxxxxxxx> > > > > Signed-off-by: David S. Miller <davem@xxxxxxxxxxxxx> > > > > Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx> > > > > --- > > > > drivers/net/ethernet/wangxun/libwx/wx_lib.c | 2 +- > > > > 1 file changed, 1 insertion(+), 1 deletion(-) > > > > > > > > diff --git a/drivers/net/ethernet/wangxun/libwx/wx_lib.c > > > > b/drivers/net/ethernet/wangxun/libwx/wx_lib.c > > > > index e078f4071dc23..be434c833c69c 100644 > > > > --- a/drivers/net/ethernet/wangxun/libwx/wx_lib.c > > > > +++ b/drivers/net/ethernet/wangxun/libwx/wx_lib.c > > > > @@ -1585,7 +1585,7 @@ static void wx_set_num_queues(struct wx *wx) > > > > */ > > > > static int wx_acquire_msix_vectors(struct wx *wx) { > > > > - struct irq_affinity affd = {0, }; > > > > + struct irq_affinity affd = { .pre_vectors = 1 }; > > > > int nvecs, i; > > > > > > > > nvecs = min_t(int, num_online_cpus(), wx->mac.max_msix_vectors); > > > > -- > > > > 2.43.0 > > > > > > > This patch in kernel-6.6 and kernel 6.7 will cause problems. In > > > kernel-6.6 and kernel 6.7, Wangxun txgbe & ngbe driver adjust misc irq > > > to vector 0 not yet. How to revert it in > > > kernel-6.6 and kernel-6.7 stable?> > > > > Please send a revert. > > > > thanks, > > > > greg k-h > > > Should I send revert to stable/master repo? I only wan't to revert it in 6.6.y and 6.7.y. 6.7 is no longer being maintained, please see the front page of kernel.org for the listed versions that are. > How maintainer recognize this revert should be applied in different tags? Explain in the changelog why this is only relevant for one branch and not all the others. thanks, greg k-h