From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-0.8 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id E6377C2D0FA for ; Wed, 13 May 2020 13:46:10 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 240DD20794 for ; Wed, 13 May 2020 13:46:10 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2388095AbgEMNqK (ORCPT ); Wed, 13 May 2020 09:46:10 -0400 Received: from out01.mta.xmission.com ([166.70.13.231]:49832 "EHLO out01.mta.xmission.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2387751AbgEMNqI (ORCPT ); Wed, 13 May 2020 09:46:08 -0400 Received: from in02.mta.xmission.com ([166.70.13.52]) by out01.mta.xmission.com with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jYri1-0007Yh-74; Wed, 13 May 2020 07:46:05 -0600 Received: from ip68-227-160-95.om.om.cox.net ([68.227.160.95] helo=x220.xmission.com) by in02.mta.xmission.com with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.87) (envelope-from ) id 1jYri0-0006Pz-3e; Wed, 13 May 2020 07:46:05 -0600 From: ebiederm@xmission.com (Eric W. Biederman) To: Luis Chamberlain Cc: Xiaoming Ni , Al Viro , Kees Cook , Stephen Rothwell , Helge Deller , Parisc List , yzaikin@google.com, linux-fsdevel@vger.kernel.org, Linux Next Mailing List , Linux Kernel Mailing List , Christoph Hellwig References: <20200511111123.68ccbaa3@canb.auug.org.au> <99095805-8cbe-d140-e2f1-0c5a3e84d7e7@huawei.com> <20200512003305.GX11244@42.do-not-panic.com> <87y2pxs73w.fsf@x220.int.ebiederm.org> <20200512172413.GC11244@42.do-not-panic.com> <87k11hrqzc.fsf@x220.int.ebiederm.org> <20200512220341.GE11244@42.do-not-panic.com> Date: Wed, 13 May 2020 08:42:30 -0500 In-Reply-To: <20200512220341.GE11244@42.do-not-panic.com> (Luis Chamberlain's message of "Tue, 12 May 2020 22:03:41 +0000") Message-ID: <87d078oss9.fsf@x220.int.ebiederm.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-XM-SPF: eid=1jYri0-0006Pz-3e;;;mid=<87d078oss9.fsf@x220.int.ebiederm.org>;;;hst=in02.mta.xmission.com;;;ip=68.227.160.95;;;frm=ebiederm@xmission.com;;;spf=neutral X-XM-AID: U2FsdGVkX18vmS02bGQubPKIl5qUYavG96RWvX+2dVI= X-SA-Exim-Connect-IP: 68.227.160.95 X-SA-Exim-Mail-From: ebiederm@xmission.com Subject: Re: linux-next: manual merge of the vfs tree with the parisc-hd tree X-SA-Exim-Version: 4.2.1 (built Thu, 05 May 2016 13:38:54 -0600) X-SA-Exim-Scanned: Yes (on in02.mta.xmission.com) Sender: linux-parisc-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-parisc@vger.kernel.org Luis Chamberlain writes: > On Tue, May 12, 2020 at 12:40:55PM -0500, Eric W. Biederman wrote: >> Luis Chamberlain writes: >> >> > On Tue, May 12, 2020 at 06:52:35AM -0500, Eric W. Biederman wrote: >> >> Luis Chamberlain writes: >> >> >> >> > +static struct ctl_table fs_base_table[] = { >> >> > + { >> >> > + .procname = "fs", >> >> > + .mode = 0555, >> >> > + .child = fs_table, >> >> > + }, >> >> > + { } >> >> > +}; >> >> ^^^^^^^^^^^^^^^^^^^^^^^^ You don't need this at all. >> >> > > +static int __init fs_procsys_init(void) >> >> > +{ >> >> > + struct ctl_table_header *hdr; >> >> > + >> >> > + hdr = register_sysctl_table(fs_base_table); >> >> ^^^^^^^^^^^^^^^^^^^^^ Please use register_sysctl instead. >> >> AKA >> >> hdr = register_sysctl("fs", fs_table); >> > >> > Ah, much cleaner thanks! >> >> It is my hope you we can get rid of register_sysctl_table one of these >> days. It was the original interface but today it is just a >> compatibility wrapper. >> >> I unfortunately ran out of steam last time before I finished converting >> everything over. > > Let's give it one more go. I'll start with the fs stuff. Just to be clear moving the tables out of kernel/sysctl.c is a related but slightly different problem. Today it looks like there are 35 calls of register_sysctl_table and 9 calls of register_sysctl_paths. Among them is lib/sysctl_test.c and check-sysctl-docs. Meanwhile I can only find 5 calls to register_sysctl in the tree so it looks like I didn't get very far converting things over. Eric