Received: by 2002:ab2:1c04:0:b0:1f7:53ba:1ebe with SMTP id f4csp44598lqg; Fri, 26 Apr 2024 08:20:09 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCVu2pQkN2M2aGl+7JXD3XUWdC/EUH3Q7l+BB0jnXjpGnfYyisagTq6h0QWwC7kto+xVvRNh+FaMgN7dS5Mi2Kq3pzNuNif83R+6VuF1Bg== X-Google-Smtp-Source: AGHT+IHKcXZwjazYs5IzRT5060dIekqoPHXgqeRkQBxuJMyVthweYtOGbNH6Skkx63gEq85GaubR X-Received: by 2002:a50:a45d:0:b0:56e:2433:a0ab with SMTP id v29-20020a50a45d000000b0056e2433a0abmr2462856edb.34.1714144808955; Fri, 26 Apr 2024 08:20:08 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1714144808; cv=pass; d=google.com; s=arc-20160816; b=IC0zkR4I9z5qQZlmEsQBk5x2LGyp4cpl8bDbQtOO3xdd1Kivzb1KFupjBGdd3yzLTK 27y14P8uSYi+2ybUu2WnqjU25DZECSzkIYiQJJOt0Luxt/Qpq78SHeuby5jnGZgaqMrO kTQfXrcCepEqqNdCQFp8tJCFyASXMXsnIy9H0IQ8+AFeGH9Yys8JB9wvnXYQrTAETBJp 9bN7PvOoemAjP28enxqeHaxqm/0FSm9jNaIyeb1HG7h3DoZq5meeqzm4H7vtaSJX2kLN lKtsuM2DEq9/X2fxT+b9Ai+m2H+J15kTad7TfM30W5vmXxL/fwgZnzaB8CTG+bABlrZo CAFQ== ARC-Message-Signature: i=2; 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; bh=u+sCYSlkJJ4cylhcip6SgTzLawcGHn/0w5QFWNi1mIA=; fh=h6mXhuDdWyG413DJqSzWg0fj9yi1ahu7Dgh0yqA04qo=; b=xmDHPYMC6N58MXWgLtQ2IIIDvUmmSg5Yh9Q6gKHtzzsX9YqPhkf0g9Fn9WqWTuPctB CZBHOoOvD6DBwa4zEREf6a8Tk6uLyI4TdAXDLzvPhliZR82aiuGO9wO3aWxChsRGVa8I oOBPJMWYA+e7MLifeBcgBMZXWTyR/u4QbP7BskveBQDxxQQhOhX2dT9HbSOXcKPp3j2s F9iUC+4ORp24KRj7CiUtJTRywK0hsyxjGaWQEAce76pRD80vK5fHE3Z44DruMvvVsdx4 ZQb3qTiQIeiePp78tra8Ud73E0pwgwAOq2oJgz/3uZSSALGc8b2HKByx/gaRigdANZE1 nbvQ==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1); spf=pass (google.com: domain of linux-nfs+bounces-3040-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-nfs+bounces-3040-linux.lists.archive=gmail.com@vger.kernel.org" Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [147.75.80.249]) by mx.google.com with ESMTPS id x9-20020a50d609000000b0056e328bf43dsi11002412edi.382.2024.04.26.08.20.08 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 26 Apr 2024 08:20:08 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-nfs+bounces-3040-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) client-ip=147.75.80.249; Authentication-Results: mx.google.com; arc=pass (i=1); spf=pass (google.com: domain of linux-nfs+bounces-3040-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-nfs+bounces-3040-linux.lists.archive=gmail.com@vger.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 am.mirrors.kernel.org (Postfix) with ESMTPS id F03291F23ED4 for ; Fri, 26 Apr 2024 15:19:24 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id BE7E914AD1A; Fri, 26 Apr 2024 15:14:00 +0000 (UTC) X-Original-To: linux-nfs@vger.kernel.org Received: from us-smtp-delivery-44.mimecast.com (us-smtp-delivery-44.mimecast.com [207.211.30.44]) (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 4D47A14A633 for ; Fri, 26 Apr 2024 15:13:59 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=207.211.30.44 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714144440; cv=none; b=MOAzq9rTdDK/3cs53ObhZXeRqMawySK14mx0lfEvhRFeuMdFLMuCgPrMl40Y7dnKEGUf+PRWpaHh4Vw/KRyVTumpjLNhRc/F0ejWTw11tq6whzVX8pC9ipME53bipUZCwbnmN3YSQy97QJms7phukphAzSOdnIqGZoqLvSaxigo= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714144440; c=relaxed/simple; bh=/5QVirdnw7ZwA7vkg/j+WG0o2OISZH7RAn/4/rQYtJs=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=aitzkc0wCDW5z3wtqdp4+yERr8QYj6ARbBsw99O3jpucF8lQiyIs5LBjUoqQqNbAG4aIoABSip4CN7B4VSAUeGOP4e/rOxqrNOww2vMWKl/lDy75Fn1tQSHORvB7yP6KnXLlOVt7SOyjdYEXkcny3PQqOolFQjyeKsBd8szp0EA= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=queasysnail.net; spf=none smtp.mailfrom=queasysnail.net; arc=none smtp.client-ip=207.211.30.44 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=queasysnail.net Authentication-Results: smtp.subspace.kernel.org; spf=none smtp.mailfrom=queasysnail.net Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-465-w0zvaQ4fM4Wn9feoiW-OqQ-1; Fri, 26 Apr 2024 11:13:48 -0400 X-MC-Unique: w0zvaQ4fM4Wn9feoiW-OqQ-1 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.rdu2.redhat.com [10.11.54.6]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 049EF1049C97; Fri, 26 Apr 2024 15:13:47 +0000 (UTC) Received: from hog (unknown [10.39.193.137]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 4E8DF2166B31; Fri, 26 Apr 2024 15:13:38 +0000 (UTC) Date: Fri, 26 Apr 2024 17:13:37 +0200 From: Sabrina Dubroca To: Joel Granados via B4 Relay Cc: "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Alexander Aring , Stefan Schmidt , Miquel Raynal , David Ahern , Steffen Klassert , Herbert Xu , Matthieu Baerts , Mat Martineau , Geliang Tang , Remi Denis-Courmont , Allison Henderson , David Howells , Marc Dionne , Marcelo Ricardo Leitner , Xin Long , Wenjia Zhang , Jan Karcher , "D. Wythe" , Tony Lu , Wen Gu , Trond Myklebust , Anna Schumaker , Chuck Lever , Jeff Layton , Neil Brown , Olga Kornievskaia , Dai Ngo , Tom Talpey , Jon Maloy , Ying Xue , Martin Schiller , Pablo Neira Ayuso , Jozsef Kadlecsik , Florian Westphal , Roopa Prabhu , Nikolay Aleksandrov , Simon Horman , Julian Anastasov , Joerg Reuter , Luis Chamberlain , Kees Cook , netdev@vger.kernel.org, linux-kernel@vger.kernel.org, dccp@vger.kernel.org, linux-wpan@vger.kernel.org, mptcp@lists.linux.dev, linux-hams@vger.kernel.org, linux-rdma@vger.kernel.org, rds-devel@oss.oracle.com, linux-afs@lists.infradead.org, linux-sctp@vger.kernel.org, linux-s390@vger.kernel.org, linux-nfs@vger.kernel.org, tipc-discussion@lists.sourceforge.net, linux-x25@vger.kernel.org, netfilter-devel@vger.kernel.org, coreteam@netfilter.org, bridge@lists.linux.dev, lvs-devel@vger.kernel.org, Joel Granados Subject: Re: [PATCH v5 5/8] net: Remove ctl_table sentinel elements from several networking subsystems Message-ID: References: <20240426-jag-sysctl_remset_net-v5-0-e3b12f6111a6@samsung.com> <20240426-jag-sysctl_remset_net-v5-5-e3b12f6111a6@samsung.com> Precedence: bulk X-Mailing-List: linux-nfs@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20240426-jag-sysctl_remset_net-v5-5-e3b12f6111a6@samsung.com> X-Scanned-By: MIMEDefang 3.4.1 on 10.11.54.6 2024-04-26, 12:46:57 +0200, Joel Granados via B4 Relay wrote: > diff --git a/net/smc/smc_sysctl.c b/net/smc/smc_sysctl.c > index a5946d1b9d60..bd0b7e2f8824 100644 > --- a/net/smc/smc_sysctl.c > +++ b/net/smc/smc_sysctl.c > @@ -90,7 +90,6 @@ static struct ctl_table smc_table[] = { > .extra1 = &conns_per_lgr_min, > .extra2 = &conns_per_lgr_max, > }, > - { } > }; There's an ARRAY_SIZE(smc_table) - 1 in smc_sysctl_net_init, shouldn't the -1 be removed like you did in other patches? int __net_init smc_sysctl_net_init(struct net *net) { struct ctl_table *table; table = smc_table; if (!net_eq(net, &init_net)) { int i; table = kmemdup(table, sizeof(smc_table), GFP_KERNEL); if (!table) goto err_alloc; for (i = 0; i < ARRAY_SIZE(smc_table) - 1; i++) table[i].data += (void *)net - (void *)&init_net; } net->smc.smc_hdr = register_net_sysctl_sz(net, "net/smc", table, ARRAY_SIZE(smc_table)); [...] -- Sabrina