Received: by 2002:ab2:6816:0:b0:1f9:5764:f03e with SMTP id t22csp143838lqo; Thu, 16 May 2024 01:44:01 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCWW9Guq+6O6GkDPk6vnYjLaOl9n6LdpxZJnATiO9lxNRvzlPdB7aGRNLiGx0y7XOYC87n3gqqw6HES8kqBT40a5m9ShFf0cYHgSaacn4Q== X-Google-Smtp-Source: AGHT+IEDj4xqedbYDsP2vgHPf4CQUDpTa7z4/9MCGhxnOdoNKARtHHf+t7Ow+MjKPUbrpoxygKVh X-Received: by 2002:ac8:5846:0:b0:43e:2639:a987 with SMTP id d75a77b69052e-43e2639acfbmr121714951cf.59.1715849041629; Thu, 16 May 2024 01:44:01 -0700 (PDT) Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [2604:1380:45d1:ec00::1]) by mx.google.com with ESMTPS id d75a77b69052e-43e10788b66si104037811cf.152.2024.05.16.01.44.01 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 16 May 2024 01:44:01 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-180788-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) client-ip=2604:1380:45d1:ec00::1; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@kernel.org header.s=k20201202 header.b=pkg4pDxZ; arc=fail (body hash mismatch); spf=pass (google.com: domain of linux-kernel+bounces-180788-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-180788-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id 5AC9B1C22325 for ; Thu, 16 May 2024 08:44:01 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id ECC4F142E90; Thu, 16 May 2024 08:43:53 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="pkg4pDxZ" Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 22D8A6BFBF; Thu, 16 May 2024 08:43:52 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715849033; cv=none; b=A0V97csrOAzeGu1ixcOkQ+nOk3+LSUys3PE1zJZK5Y51yKwa+Ok9U7NYLdWzUBkZl3grQvYkM54HZ7AL4X70kzz/GQjQlg8RT+ekTYcm+dnvyQhPrzmyjyPaonzTwh4h8/02VtyPd1yTW2MhMCa5VwekyfWYjDz+nl2Qwgld8hI= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715849033; c=relaxed/simple; bh=7eowNZsP0z/IUYzGQw3TrUkJcTIY48766X+Sspo9t44=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=DQKwG2r+lUnih4Ljog+smyJP8nyTS4L0nxoEXjU5EGLD2ESRQwsRc7SJX43MIPfX6Pnjsf6hImrS83V58xAMVMOq6uhEUPPG1Ect7Urp4cJcQBXwHohtbxZIjOLfypBgCdG6f5tRu3scaXQITv2fIksFj1+RCpHKzO0WrDlQ5/c= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=pkg4pDxZ; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id B46C1C32781; Thu, 16 May 2024 08:43:50 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1715849032; bh=7eowNZsP0z/IUYzGQw3TrUkJcTIY48766X+Sspo9t44=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=pkg4pDxZ1kyNT3gWta5QQ1ZLtC/xQUwyvpn1l27JH2A8G3uR767HFOTFDgDiKwfeV SaANF+IDO1eZVTDEN3IKoTZVQCT2KLPJvxE7QeF8p8L6h2pQtyEBYe2fDpEfFUL529 iLZHYrSZNKHGR1SZCok/X/4GCOxcsnGD54B66dxe2o0mJkl42PBGERX6sFlDoIQFRN D5pAVChuwKIIzBd/84TFPrZNFWx8hziSSTv9B27D+UBfo0uptOUyjpu8hLh0FyOEEO 49ocJz7XPoPLlcEYQlAJ3tOBRmhgFItbecA0+jXEVsLX2ch5+RRHhsvZGzBk1pBYxa Xgb0sguWwoocA== Date: Thu, 16 May 2024 09:43:48 +0100 From: Simon Horman To: Ryosuke Yasuoka Cc: krzk@kernel.org, davem@davemloft.net, edumazet@google.com, kuba@kernel.org, pabeni@redhat.com, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, syoshida@redhat.com Subject: Re: [PATCH net] nfc: nci: Fix handling of zero-length payload packets in nci_rx_work() Message-ID: <20240516084348.GF179178@kernel.org> References: <20240515151757.457353-1-ryasuoka@redhat.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20240515151757.457353-1-ryasuoka@redhat.com> Hi Yasuoka-san, On Thu, May 16, 2024 at 12:17:07AM +0900, Ryosuke Yasuoka wrote: > When nci_rx_work() receives a zero-length payload packet, it should > discard the packet without exiting the loop. Instead, it should continue > processing subsequent packets. nit: I think it would be clearer to say: .. it should not discard the packet and exit the loop. Instead, ... > > Fixes: d24b03535e5e ("nfc: nci: Fix uninit-value in nci_dev_up and nci_ntf_packet") > Closes: https://lore.kernel.org/lkml/20240428134525.GW516117@kernel.org/T/ nit: I'm not sure this Closes link is adding much, there are more changes coming, right? > Reported-by: Ryosuke Yasuoka > Signed-off-by: Ryosuke Yasuoka > --- > net/nfc/nci/core.c | 3 +-- > 1 file changed, 1 insertion(+), 2 deletions(-) > > diff --git a/net/nfc/nci/core.c b/net/nfc/nci/core.c > index b133dc55304c..f2ae8b0d81b9 100644 > --- a/net/nfc/nci/core.c > +++ b/net/nfc/nci/core.c > @@ -1518,8 +1518,7 @@ static void nci_rx_work(struct work_struct *work) > > if (!nci_plen(skb->data)) { > kfree_skb(skb); > - kcov_remote_stop(); > - break; > + continue; > } > > /* Process frame */ > -- > 2.44.0 > >