Article View: linux.kernel.netdev
Article #14525Re: [PATCH] vhost/net: Fix receive queue test in busy poll
From: Björn Töpel
Date: Wed, 11 Nov 2026 11:58
Date: Wed, 11 Nov 2026 11:58
25 lines
8575 bytes
8575 bytes
raoxu <raoxu@uniontech.com> writes: > From: Xu Rao <raoxu@uniontech.com> > > sock_has_rx_data() returns a positive result when receive data is > available. Socket implementations with a peek_len() callback follow > that convention, but the fallback for sockets without one returns > skb_queue_empty(), which has the opposite meaning. > > This makes busy polling stop when a raw packet socket has no queued data > and fail to recognize queued data through the fallback path. Return the > negated queue-empty result so the fallback matches the callback and its > callers. > > Signed-off-by: Xu Rao <raoxu@uniontech.com> This fix is valid, but you need to carry a Fixes: tag. You should also state what netdev tree you're targeting. Please see Documentation/process/maintainer-netdev.rst Could the changelog also state how the bug was found and confirmed, and how the fix was tested? Björn
Technical Details
Message-ID:
<87tslna8c7.fsf@all.your.base.are.belong.to.us>Path:
mbox-mo1.pugleaf.net!news-lax.pugleaf.net!srl.newsdeef.eu!news.mb-net.net!open-news-network.org!news.nntp4.net!nntp.xenet.de!news.neodome.net!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-361041-linux-kernel-netdev=dewy.ruReferences:
<005FA5F7354482C7+20261110051642.249640-1-raoxu@uniontech.com>Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!news-lax.pugleaf.net!srl.newsdeef.eu!news.mb-net.net!open-news-network.org!news.nntp4.net!nntp.xenet.de!news.neodome.net!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-361041-linux-kernel-netdev=dewy.ru From: bjorn@kernel.org (Björn Töpel) Newsgroups: linux.kernel.netdev Subject: Re: [PATCH] vhost/net: Fix receive queue test in busy poll Date: Wed, 11 Nov 2026 03:58:00 -0800 Organization: Usenet Network Message-ID: <87tslna8c7.fsf@all.your.base.are.belong.to.us> References: <005FA5F7354482C7+20261110051642.249640-1-raoxu@uniontech.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: usenet.network; logging-data="844707"; mail-complaints-to="abuse@usenet.network" Cancel-Lock: sha1:MQeoVPHCjiRHX4UUr/sWK91BRIk= sha256:IZPw1mFawmfwgPz+zQG3bjvZl6e+rppd5hIusmBOUOw= sha1:PwCi4iYz40rS+uWrjmHcOi7rEqQ= sha256:mf72R3i4p23Htby19HW7pYExzvLVWLjkRtw/pXMy6/0= List-ID: <netdev.vger.kernel.org> X-Mailpost-Empty-Hdrs: X-Spam-Level X-Received: from localhost (localhost [127.0.0.1]) by mail.dewy.ru (Postfix) with ESMTP id E2E83113ED3; Wed, 11 Nov 2026 15:02:32 +0300 (MSK) X-Virus-Scanned: Debian amavisd-new at usenet.network X-Spam-Flag: NO X-Spam-Score: -3.401 X-Spam-Status: No, score=-3.401 tagged_above=-9999 required=6.31 tests=[DCC_REPUT_70_89=0.1, DKIMWL_WL_HIGH=-0.001, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, MAILING_LIST_MULTI=-1, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001, SPF_PASS=-0.001] autolearn=ham autolearn_force=no X-Authentication-Results: mail.dewy.ru (amavisd-new); dkim=pass (2048-bit key) header.d=kernel.org X-Received: from mail.dewy.ru ([127.0.0.1]) by localhost (mail.dewy.ru [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id w_ohnhMPM6ed; Wed, 11 Nov 2026 15:02:29 +0300 (MSK) X-Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=172.105.105.114; helo=tor.lore.kernel.org; envelope-from=netdev+bounces-361041-linux-kernel-netdev=dewy.ru@vger.kernel.org; receiver=<UNKNOWN> X-Authentication-Results: OpenDMARC; dmarc=pass (p=quarantine dis=none) header.from=kernel.org X-Received: from tor.lore.kernel.org (tor.lore.kernel.org [172.105.105.114]) by mail.dewy.ru (Postfix) with ESMTPS id 7E2B1113ED0; Wed, 11 Nov 2026 15:02:21 +0300 (MSK) X-Received: from smtp.subspace.kernel.org (conduit.subspace.kernel.org [100.77.114.92]) by tor.lore.kernel.org (Postfix) with ESMTP id B3C9D453F6; Wed, 11 Nov 2026 11:58:16 +0000 (UTC) X-Authentication-Results: smtp.subspace.kernel.org; arc=pass header.oldest-pass=0 smtp.remote-ip=127.0.0.1 X-ARC-Seal: i=2; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=pass; t=1794398286; b=bFFQPdJ6haFP9wuioUfapCWOBNWyPuyKsIWw5tUUla9ALJqa4r6YDjdJ/aUzQ81IKENM MTEoEn8zhbGsjoHYKNm4/x81liJdAfcHPFJ5M8lo8sm5hU0P3DRJlH00k8cGeYn41vT8S a+b6sF2BvY5UzHe5GmsZC9QSSgl7hlbLGWW4G3drxBudBYtcIk7aKR3xqyZa0S0r3ZJ0j QtBTZmYf5TrO5fE8EX8ihWc0tMg2ivlzPvfFU2TQsXtzBMSxwuiuZgANLUVp+fnc5HHon MYIzsPZhpPod++UgnrZBah77ARCwtZaWBXvO3NTMr4sR+kylg5yP2Z//Es6KI/31L+Q== X-ARC-Message-Signature: i=2; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1794398286; h=X-Original-To:Received:Received:DKIM-Signature:From:To:Cc:Subject: In-Reply-To:References:Date:Message-ID:X-Mailing-List:List-Id: List-Post:List-Help:List-Subscribe:List-Unsubscribe:List-Owner: Precedence:MIME-Version:Content-Type:Content-Transfer-Encoding; bh=QAtpX+mYswT5tfILpPnNE2GO/1nDfiulyO5xnYGFX+Y=; b=X89wMyX8VMHcCJwY5BBzsHLY2Y+PZ2MqX/3BsAS8WP2oksmp2UcybG+QtuDyJeCbmZjM cyRbNQ1j6Z7TjyNzl9ch+c3MTjLixbgwXMbkSTjEuf/8xQQDcJHLXlSBz8rZEWmSwZby3 bSdOqLfy/zHBvpqWqPOD6vIiicHN/3RxS6B8IXA/JOumlouv0NFJBG12SmgMqB2OJajlP TmdUozlCZZ2jKw+cV0gGQDT/ph5W0sMeaCMXYIK9pbMBTwTF9XxjSGv7px2pGrGkld5TI hwfYpSqoRboO09ecZ53wEvwldLZQ9VHlpgoi8mn1J8LDUYQfnqZXpaMmYNnXJZjizgQ== X-ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dkim=pass header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=CZZZt+iD; arc=pass header.oldest-pass=0 smtp.remote-ip=127.0.0.1 X-Received: from localhost.localdomain (localhost [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 3971C606A332; Wed, 11 Nov 2026 11:58:06 +0000 (UTC) X-Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=CZZZt+iD X-Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=100.103.45.18 X-ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1794398285; b=t/cZbQRkVPBrBDlAfx6FxSOqIZlZF579EOln8t1Qn5hl0wcUHAVESit3ZwOIzTzaqFUy ov6zR1ZY10lihNPuAJPAJaZIpuNDL1iH/gydwag5EU1karo4UWjyZpozoFRyEwiDZgQWy MORlMxvPLmcAwyR52N5oOeQwXyKzGUDXq9UcU8dW/CBvua177Lz8ujAShAAKaw+g9x8nM nj4a5jWr1qoUbdeUkUoTKZY7i4vWV2ap0/r49JvOHYyWongqxQ/2WUTfPlg+eWRVlwqeP MQllA0xY/01KGiJ1CIiE3IzUtMoNOjTvCAsfDDFzZh9DkIHSM07QePJ2Me8bTSdpdCQ== X-ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1794398285; h=Received:DKIM-Signature:From:To:Cc:Subject:In-Reply-To:References: Date:Message-ID:MIME-Version:Content-Type:Content-Transfer-Encoding; bh=QAtpX+mYswT5tfILpPnNE2GO/1nDfiulyO5xnYGFX+Y=; b=nVxh9rfwnv9qOZ9RYN84DGvMFVPZIb+RAy/nQp0d8ePesVEQfBNK3HqUjYCV+klD+ZOU kece3TtqyDNH2c/zAXdh5NazjUEMMEEw9NoOWYvLDsFHtjS+2fvRB5d5vvpD/55HcmPwN r8FBM5BqnX9h1f4qYnDEeVyzslZCYIoAPpbVrnnwycUhkZ/XnDVgVk/evSTuk8UiaafOR wf62umuaG1uAs692dfd+tSO87g+4nax9gdZkNypM1Ih7Icu5VG/E+bDQfMVIULv4B+Oz+ 26N50jBFtNe4KhiXBIzBUPdV2J87VfWHtDdANzq7LoBKuosQ5+4RdJ+tl56KnJdAWEQ== X-ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=CZZZt+iD; arc=none smtp.remote-ip=100.103.45.18 X-Received: from smtp.kernel.org (quasi.space.kernel.org [100.103.45.18]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 52A6D606A324; Wed, 11 Nov 2026 11:58:05 +0000 (UTC) X-Received: by smtp.kernel.org (Postfix) with ESMTPSA id 578831F00A05; Wed, 11 Nov 2026 11:58:04 +0000 (UTC) X-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.org; s=k20260515; t=1794398284; bh=QAtpX+mYswT5tfILpPnNE2GO/1nDfiulyO5xnYGFX+Y=; h=From:To:Cc:Subject:In-Reply-To:References:Date; b=CZZZt+iDaXV26+WhMHROR42F2LIOSWiP08Yj50yMgautwfxUqBPhYZhBoclbGVxne yRzQeLwPX0eG0h+9Yna4HkzNVKJI4bEc3LL0ssL70JgtaP3pnKmWupe1yyF7BiILaO 6x3cRKxoQtLNkIWsX5g2uKno0nXbMORIfO3ZV1EcYwKZ6tJCp5whTbJPbW153lxl04 aLJ7llyakMlfSNeLi5UV5ou50l1lLYLmyF6F2nO3+Lu8+qXe9uIfag4b3Q06VBzgU+ Tq1T58X5vncislAwYcO8PSP/IYsi+H6iHzgk+o72oCsf5RWzWpkcW0pj/TI2OawL33 CCCmL82f2301Q== X-Cc: jasowangio@gmail.com, eperezma@redhat.com, kvm@vger.kernel.org, virtualization@lists.linux.dev, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, raoxu@uniontech.com X-In-Reply-To: <005FA5F7354482C7+20261110051642.249640-1-raoxu@uniontech.com> X-Mailing-List: netdev@vger.kernel.org X-List-Post: <mailto:netdev@vger.kernel.org> X-List-Help: <mailto:netdev+help@vger.kernel.org> X-List-Subscribe: <mailto:netdev+subscribe@vger.kernel.org> X-List-Unsubscribe: <mailto:netdev+unsubscribe@vger.kernel.org> X-List-Owner: <mailto:netdev+owner@vger.kernel.org> X-Precedence: list