Path: csiph.com!news.freedyn.net!open-news-network.org!aioe.org!bofh.it!news.nic.it!robomod From: Geert Uytterhoeven Newsgroups: linux.kernel Subject: Re: [PATCH] kconfig: always use user input symbols Date: Fri, 19 May 2017 19:30:02 +0200 Message-ID: References: Dkim-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to:cc; bh=DdZ6svd9CQXEoQ7UC/SKs+4Crrg27Qp+YeWNSHJuruQ=; b=D1zLXjpa6+9lEyMW0dPxIlQOHmh38QW3g2z7BFOkxv7/CTauO16tx61ErLinp/UmPc /GKUAV8+CDCHDpZw8iowSXoqVY9XeiJ+Pz8R9HEwG9VfVfOTFsJTkUNdJihTc1Hdxukv UhPB03G0bco8HOXzeP4n8jF/6wA5wPX6CXVvUtGVLDrNHS1LHfRZzjyjzef6CnD5tpIB 47HgMlkRXurABS/WoCozasXp82/ZA23VfYau7S0Fr6vNPT8VheHhOYSWroIdX1VhNS4b Jt5RnKoQMUKZIIl0GpUphmhQyBpNAt2VJC1+YDdASQ4BMLC3xcPP0YYhlK2o47362Yvq aQgg== X-Google-Dkim-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:sender:in-reply-to:references:from :date:message-id:subject:to:cc; bh=DdZ6svd9CQXEoQ7UC/SKs+4Crrg27Qp+YeWNSHJuruQ=; b=GIHqFCG+mnoVpByWLlghapRwaKr/zXZX0DSyKWFrRUMQC95uSPe4ANjfOfBOB6ufPQ rTbsWvleZzGr/hHxLInMz+38pPaZC+sR+WuZYn0DActwBbbCjjPg0elAqrFRq/XfvWLn z6AnmSKJoPH2RzSDZ33EoCPwjimqzlPAmrKeuVtuOKO15Le4wicXgUfccavDPSh/LMJe TdPK1y7V4nnu7mkxPBj2MohMBHyGw2FHswuWIfWpo5Ie5wV1BWlfU2nIayT8iQs4e94r yjg+pmKylmCPCduv4rbebBG83wyqqnrwkskJzKPkdrAqpUtmm8DfCGHZwld2EJrfo1+G 6gUA== X-Gm-Message-State: AODbwcD318evo6e3GaUyZ7A21WOh8mAtSRM86aoAM5pjiF/Z0xd2k2Ij FpMiaXhdZMyBnXC8FedOSP/wmvFG0g== X-Received: by 10.36.73.214 with SMTP id e83mr11404020itd.48.1495214946388; Fri, 19 May 2017 10:29:06 -0700 (PDT) MIME-Version: 1.0 X-Google-Sender-Auth: ureKba3457SkObiak_CdW-Rsl3I Content-Type: text/plain; charset="UTF-8" Sender: robomod@news.nic.it List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Approved: robomod@news.nic.it Lines: 41 Organization: linux.* mail to news gateway X-Original-Cc: "Yann E . MORIN" , linux-kbuild , "linux-kernel@vger.kernel.org" , Roman Zippel X-Original-Date: Fri, 19 May 2017 19:29:05 +0200 X-Original-Message-ID: X-Original-References: <20170519150813.27845-1-tycho@docker.com> X-Original-Sender: linux-kernel-owner@vger.kernel.org Xref: csiph.com linux.kernel:1645780 Hi Tycho, On Fri, May 19, 2017 at 5:08 PM, Tycho Andersen wrote: > ...regardless of visibility. > > When a symbol that is not visible by default (e.g. PNFS_FLEXFILE_LAYOUT) > has a default value, it is impossible to set the value to something not the > default: > > ~/packages/linux render-symbol-inputs grep FLEXFILE .config > CONFIG_PNFS_FLEXFILE_LAYOUT=y > ~/packages/linux render-symbol-inputs make oldconfig > scripts/kconfig/conf --oldconfig Kconfig > ~/packages/linux render-symbol-inputs grep FLEXFILE .config > CONFIG_PNFS_FLEXFILE_LAYOUT=m > > There are two reasons for this: the symbol's user input value is only > considered when it is visible (hunks 2 and 3), and the user values are > explicitly ignored (hunk 1) if the symbols are not visible. > > It's not clear to me why hunk 1 exists. I'm sure it solve some problem, but > I'm not sure why we would ever want to discard user input values, and > causes a problem exactly as the comment describes. This is intentional. If a symbol is not visible, it's not meant to be changed by the user, as doing so may break things (at build or runtime). E.g. running "make oldconfig" after a kernel upgrade may retain the old state of a variable, which is now invalid. Ignoring invisible symbols avoids this. Gr{oetje,eeting}s, Geert -- Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org In personal conversations with technical people, I call myself a hacker. But when I'm talking to journalists I just say "programmer" or something like that. -- Linus Torvalds