Received: by 2002:a25:c593:0:0:0:0:0 with SMTP id v141csp1116748ybe; Fri, 6 Sep 2019 12:06:35 -0700 (PDT) X-Google-Smtp-Source: APXvYqxiJOH4V9tdzpbTos5F0SlQkn3vk9ZQvtsMTQJXdxbeHtnjUXaV5o+p7ni2JQjm8q1csbcU X-Received: by 2002:a17:902:7047:: with SMTP id h7mr10132544plt.275.1567796795830; Fri, 06 Sep 2019 12:06:35 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1567796795; cv=none; d=google.com; s=arc-20160816; b=Z+6U8NHfkmLn+0YcvRh010JeifwaTHQg9ZNwn17rwhzxkx5VFSw/QKQNBzgWTTVTWH QYYv20HHTOBsVwvxU7A90Low2PjomEOqSJRFBRbLNV7RDu+kfhXNrQeKRaxQJp17tnSf Ojon5aq3IcsLy/k8ZnQS3KOoyYdGOc67Pd6dfRgQdypLRFyYGAoH1jb6+BylHdI0TX39 PDEIsYVuKfj1HTufV+bM8CBfYiK6HC2RennpjMuF5Gbik8M1FZfQZiR4ZpbWfTP1YzB8 LHatMJCQHbNI7hvPSRzDXkbufS3Zfrn0Tz0A8MviVeXPOKFbetjKQTG/NKQbDXx8o2ru Oa8Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=FaX5AmFw9s4ywZuvRRhWdJMy5mE8nAOc1vfI91D3/+s=; b=u/sLzZ+3Oshk4DFIpyfYphz7mdoxvD7pBDZkbIp+ku7ERyuPQTLaE4cfKAg0PUYtp0 ckPrOB+aNO+wuKwqBhtHNiyuPX4c//+7hB0abwPmywdmrqN/0UkrIeHoCbV3ys34AhyN 2eNqDX20Zp3m4G7LZWwyZBkO8cMNzokbMjEvm6eDwYZ9YLKKccSNx5FXiPfTpMGFnDwG wk/1A+tDAgcaJ046RMjvWl98INXWZwPGSJtMeTDn7QT83Qi7gYI1UER7QiTlwSVJaamu F2DzvOeJqAfNge7urRU8TmMvn4o7BxSU0eICgFacYNfLpHzkL4bRxJUpGZMLjWyHoLqN huYg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id r10si5200887pgs.474.2019.09.06.12.06.19; Fri, 06 Sep 2019 12:06:35 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2393925AbfIFOCC (ORCPT + 99 others); Fri, 6 Sep 2019 10:02:02 -0400 Received: from nautica.notk.org ([91.121.71.147]:53183 "EHLO nautica.notk.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2388583AbfIFOCC (ORCPT ); Fri, 6 Sep 2019 10:02:02 -0400 Received: by nautica.notk.org (Postfix, from userid 1001) id 74656C009; Fri, 6 Sep 2019 16:02:00 +0200 (CEST) Date: Fri, 6 Sep 2019 16:01:45 +0200 From: Dominique Martinet To: Colin King Cc: Eric Van Hensbergen , Latchesar Ionkov , v9fs-developer@lists.sourceforge.net, kernel-janitors@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] 9p: make two arrays static const, makes object smaller Message-ID: <20190906140145.GA16910@nautica> References: <20190906133812.17196-1-colin.king@canonical.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20190906133812.17196-1-colin.king@canonical.com> User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Colin King wrote on Fri, Sep 06, 2019: > From: Colin Ian King > > Don't populate the arrays on the stack but instead make them > static const. Makes the object code smaller by 386 bytes. > > Before: > text data bss dec hex filename > 17443 2076 0 19519 4c3f fs/9p/vfs_inode_dotl.o > > After: > text data bss dec hex filename > 16897 2236 0 19133 4abd fs/9p/vfs_inode_dotl.o > > (gcc version 9.2.1, amd64) > > Signed-off-by: Colin Ian King Fine with me, I'll pick it up for the next cycle. There are a couple of static structs in net/9p that aren't const (but could be); I guess the static is all that matters here? (I'll try to go through and make the rest const when I have time though, no harm there) Thanks, -- Dominique