Received: by 2002:a05:7412:b995:b0:f9:9502:5bb8 with SMTP id it21csp1412105rdb; Sat, 23 Dec 2023 05:58:46 -0800 (PST) X-Google-Smtp-Source: AGHT+IEOQXkiYpOR3Ot6G/O0XzxTNH04jEX5RmnVZYZLgq2iwom5CnU5U97bY51aY5s+1Fp+hvNp X-Received: by 2002:a17:902:650f:b0:1d4:1956:80d4 with SMTP id b15-20020a170902650f00b001d4195680d4mr1557357plk.47.1703339926155; Sat, 23 Dec 2023 05:58:46 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703339926; cv=none; d=google.com; s=arc-20160816; b=h6LbHiT+ZXYe9NIR5Lcqm8NKxopBJ6RqPLsywaSCuxrGFcQmveedGWVuyK16x2zh1p 5+LAzO0Cid+rYZdt1UGO18+8PkSMXAnj8lR4lB8qPAK2pnt1udca+6toOPqWymRoCUSU a8Jv9joLwxYhJYXYrXc02TSMbPx9JTp9B/1yvdvduc7wNakUw3dXCFemLjLkeTIQcBrp dz8xKWf/FGNLkZMCOb0nUIH2hrmBpaD2dKksr1qOIdCFhJUZQRu3q4bcBKzS7RgnMx+a commzQzPHUcjbQJq51UBXuJc8U6Znz8GCi+JVkI+GImq4lKWG0NtZuBSDrkQe8ipVU3a EkQA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-disposition:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:message-id:subject:cc :to:from:date:dkim-signature; bh=wROcCIauPSXCYGLLMVw0Cn8JMfaBI8hv9GhTA+6i7xg=; fh=spGDM7QdFtKEkLiI6UiHFaFM3kEM4k3bJSyV7vBhKbg=; b=ZWpMO7vFL6bzYOGJRIm5PX6Ouwv9wWYC2A0wLpfiAoIh3fyg3KutqixTYO87BbSrEn 0aMTRMMfkdcUZz5tKF08dTgq/+dXhi3m0LTGymTEfkD02q3sKKbDxOCRlg7L7Z7LKHWB OVXar4ao6na6ZD1xJaVpgvAhy+wgCt5MbcKqXIMbIJAp3XrkQ0PD4fCg0ppUAMTspHVv UlU+Vc2UFfiyQ8YZAjfkvO2jJD2jRGsRSdKcSU4YBPBjbi5r42O+958FjRbjEFmTZ0F4 RB3TlNSPCuNynalQwMYg0Bdg2ZoO3QPJT+QUISrmY0uyEHbEiDYBBijMv1TuUJ9x7goQ sVPw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=PX3jLz4N; spf=pass (google.com: domain of linux-kernel+bounces-10436-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-10436-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id w5-20020a170902e88500b001d3b22f5784si387383plg.438.2023.12.23.05.58.45 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 23 Dec 2023 05:58:46 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-10436-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=PX3jLz4N; spf=pass (google.com: domain of linux-kernel+bounces-10436-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-10436-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 sv.mirrors.kernel.org (Postfix) with ESMTPS id CC6F1283AB4 for ; Sat, 23 Dec 2023 13:58:45 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 0E0DDDDC4; Sat, 23 Dec 2023 13:58:33 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="PX3jLz4N" X-Original-To: linux-kernel@vger.kernel.org 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 36369D51A; Sat, 23 Dec 2023 13:58:31 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 141ACC433C7; Sat, 23 Dec 2023 13:58:28 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1703339911; bh=gvrM5vr0NZj7qhhuIEVRbaoqCKOSx1zd+UHnL57kz8A=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=PX3jLz4Nf5VuCIOmVOMP5LOV0AQfsOxkhW2sNETgVCZw24rttTWrGKJONr7X+r47a n+ZCiBYlJCdzW7Lrb2ishzFSA26r+JRhmr35o/uwlP8PT/BKD/pO9Gm+HbHQdQSJ0p 7osxh8U1Cv2ban38B36h5+qoz50gbIpvd/EV3ajU4240hP9tx0L409nAaQ5PMd6r1v Q1XbftrtYxPXL58NXtIQkFgn8CRm9SuPBhlX++2+VSFVOMkJsuoT9rVfgJQBKIkEsI zBVXo4Yrm4/72bfOq48vveuZ/MlRoMdd5f8XVL/SxahpdU7EY2jq0W7/o0QquCZ0El uSk6WA+5qQ2Yg== Date: Sat, 23 Dec 2023 13:58:25 +0000 From: Simon Horman To: Sarannya S Cc: quic_bjorande@quicinc.com, andersson@kernel.org, quic_clew@quicinc.com, mathieu.poirier@linaro.org, linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-remoteproc@vger.kernel.org, Manivannan Sadhasivam , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , "open list:NETWORKING [GENERAL]" Subject: Re: [PATCH V1] net: qrtr: ns: Return 0 if server port is not present Message-ID: <20231223135757.GB201037@kernel.org> References: <1703153211-3717-1-git-send-email-quic_sarannya@quicinc.com> <1703153211-3717-2-git-send-email-quic_sarannya@quicinc.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: <1703153211-3717-2-git-send-email-quic_sarannya@quicinc.com> [Dropped bjorn.andersson@kernel.org, as the correct address seems to be andersson@kernel.org, which is already in the CC list. kernel.org rejected sending this email without that update.] On Thu, Dec 21, 2023 at 03:36:51PM +0530, Sarannya S wrote: > When a 'DEL_CLIENT' message is received from the remote, the corresponding > server port gets deleted. A DEL_SERVER message is then announced for this > server. As part of handling the subsequent DEL_SERVER message, the name- > server attempts to delete the server port which results in a '-ENOENT' error. > The return value from server_del() is then propagated back to qrtr_ns_worker, > causing excessive error prints. > To address this, return 0 from control_cmd_del_server() without checking the > return value of server_del(), since the above scenario is not an error case > and hence server_del() doesn't have any other error return value. > > Signed-off-by: Sarannya Sasikumar Thanks, I have a suggestion below. But that notwithstanding this change looks good to me. Reviewed-by: Simon Horman > --- > net/qrtr/ns.c | 4 +++- > 1 file changed, 3 insertions(+), 1 deletion(-) > > diff --git a/net/qrtr/ns.c b/net/qrtr/ns.c > index b1db0b5..abb0c70 100644 > --- a/net/qrtr/ns.c > +++ b/net/qrtr/ns.c > @@ -512,7 +512,9 @@ static int ctrl_cmd_del_server(struct sockaddr_qrtr *from, > if (!node) > return -ENOENT; > > - return server_del(node, port, true); > + server_del(node, port, true); > + > + return 0; > } With this change the return value of server_del() now seems to be ignored by all callers. Perhaps it would make sense to update it to return void? > > static int ctrl_cmd_new_lookup(struct sockaddr_qrtr *from, > -- > 2.7.4 > >