From patchwork Mon Sep 9 11:04:07 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Masahiro Yamada X-Patchwork-Id: 173371 Delivered-To: patch@linaro.org Received: by 2002:a05:6e02:ce:0:0:0:0 with SMTP id r14csp4197994ilq; Mon, 9 Sep 2019 04:04:23 -0700 (PDT) X-Google-Smtp-Source: APXvYqwvYCZUCP/dznJRGmv8QhOH8LOdWUFf8F37e+t+OrQXgpiSElAdBga+ZLPqqpK3HjpuEUsF X-Received: by 2002:a50:d758:: with SMTP id i24mr23398196edj.246.1568027063821; Mon, 09 Sep 2019 04:04:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1568027063; cv=none; d=google.com; s=arc-20160816; b=D6MYM4dbfvNqy6Ynvx3EnwqbU5XUoqFRuyb2C/jo36CDmJ/5+T1fie1JlScj3RRwBL z6q83/uNzxqky62LgI/qIy8H4oGEy7cdyxauhoeTZCLcjgIXsqIEdslXZSfW/58HWBGv v1+l8dRraQDh1nDVyQIgs0MKYuV5ixJ9zRJMtniTmjXgBzcQRlp/35pfMfwA91c9CDRL unP1UpYrQYFm5ucol8IIcNKB5M7RFwyzTPOBQgU3hkcyJA9BxccwfSZ5TCyCs6XMYW8r rvLeH/HdJom8I2Wn+PpP4ytXFOam+uGUVXD7oj7rP1U+Df+iJ2XhTW6H0MplSN+xtV9S /5Tg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :dkim-signature:dkim-filter; bh=P3E0voZLBRNhBPs4jkIYDedlz8ZAEmB2TiQnO9CqZgo=; b=b+vPcmXVn0qygTWAzB4Q2+ZJh265cCrGObum72/DgtyrPoL+KOhAPg5CnZL3/k+AQ0 JfwR5euPy7MUgxiZucyN3IIwRNTayPErB5W6DjyJn6He5dnwxxQn1gC3erq5Y2tEh+Kp txO/0GPxi83QTv0Sdil8e6NSb7o1AIJ1eGa78F6Q+H8HC1dW6Tbapf36bn9ZtS/GrHTS FHykmvK1FF74GEizyJUvRhrFSj3BqUDrzXRcW+cYxZ+FlqLNbPbt6m4kVfdcF9vxf0RD EIp1rq6+cDOdi8lOPRQwOreT/q2cJZcVH3FChRZm0lmJw8xtMjBTU6oJrvep36oKiOgq Tuxw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@nifty.com header.s=dec2015msa header.b=lczMtMDH; 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 g20si9603284edc.191.2019.09.09.04.04.22; Mon, 09 Sep 2019 04:04:23 -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; dkim=pass header.i=@nifty.com header.s=dec2015msa header.b=lczMtMDH; 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 S2391011AbfIILEU (ORCPT + 28 others); Mon, 9 Sep 2019 07:04:20 -0400 Received: from conuserg-07.nifty.com ([210.131.2.74]:59912 "EHLO conuserg-07.nifty.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729106AbfIILEU (ORCPT ); Mon, 9 Sep 2019 07:04:20 -0400 Received: from localhost.localdomain (p14092-ipngnfx01kyoto.kyoto.ocn.ne.jp [153.142.97.92]) (authenticated) by conuserg-07.nifty.com with ESMTP id x89B4CjM031800; Mon, 9 Sep 2019 20:04:13 +0900 DKIM-Filter: OpenDKIM Filter v2.10.3 conuserg-07.nifty.com x89B4CjM031800 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nifty.com; s=dec2015msa; t=1568027053; bh=P3E0voZLBRNhBPs4jkIYDedlz8ZAEmB2TiQnO9CqZgo=; h=From:To:Cc:Subject:Date:From; b=lczMtMDHf1vv6d+PWh3dPjM1dhs7VxFW2MwYeA5IXKRuKXHOcUFqd43AVtr8zsSD9 SemjxaIymis38wDJsp1VQKsKMjWAH2sJVtqXUc4yfl5hBwx2pPh4l8KrGJaUMXJPOA od8mfZEJZOlW4XIOeAuzL/5IA/bp850IEVkgEj2e36wz71p8P1cft7tgHBexJEOUfA yZ8n9BMtBRNS4yIO6hFhL37TcBOzmvIf2yp9JqgBMNCcd+ArIIoNg9WukNH19xIVfe rhF2grerYJIpOQ5qkH+hlh0NBRAHK+pUNJttuNHCXA629OK9A4n8DNVcy8CkxDnjsq 4+if6chVMZD4g== X-Nifty-SrcIP: [153.142.97.92] From: Masahiro Yamada To: Jessica Yu Cc: Masahiro Yamada , linux-kernel@vger.kernel.org Subject: [PATCH 1/2] module: remove redundant 'depends on MODULES' Date: Mon, 9 Sep 2019 20:04:07 +0900 Message-Id: <20190909110408.21832-1-yamada.masahiro@socionext.com> X-Mailer: git-send-email 2.17.1 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org These are located in the 'if MODULES' ... 'endif' block. Remove the redundant dependencies. Signed-off-by: Masahiro Yamada --- init/Kconfig | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) -- 2.17.1 Acked-by: Jessica Yu diff --git a/init/Kconfig b/init/Kconfig index bd7d650d4a99..9e72cc6071f5 100644 --- a/init/Kconfig +++ b/init/Kconfig @@ -2006,7 +2006,6 @@ config MODULE_SRCVERSION_ALL config MODULE_SIG bool "Module signature verification" - depends on MODULES select SYSTEM_DATA_VERIFICATION help Check modules for valid signatures upon load: the signature @@ -2083,7 +2082,6 @@ config MODULE_SIG_HASH config MODULE_COMPRESS bool "Compress modules on installation" - depends on MODULES help Compresses kernel modules when 'make modules_install' is run; gzip or @@ -2121,7 +2119,7 @@ endchoice config TRIM_UNUSED_KSYMS bool "Trim unused exported kernel symbols" - depends on MODULES && !UNUSED_SYMBOLS + depends on !UNUSED_SYMBOLS help The kernel and some modules make many symbols available for other modules to use via EXPORT_SYMBOL() and variants. Depending From patchwork Mon Sep 9 11:04:08 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Masahiro Yamada X-Patchwork-Id: 173372 Delivered-To: patch@linaro.org Received: by 2002:a05:6e02:ce:0:0:0:0 with SMTP id r14csp4198075ilq; Mon, 9 Sep 2019 04:04:27 -0700 (PDT) X-Google-Smtp-Source: APXvYqybFx8WPbC0CXbkSpsH6hmiz/Et9+segSI4Yrob5ICJsxh1I4+Lj/TQ9gqfp1C4gCkdvpAy X-Received: by 2002:a17:906:308a:: with SMTP id 10mr15355668ejv.277.1568027067488; Mon, 09 Sep 2019 04:04:27 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1568027067; cv=none; d=google.com; s=arc-20160816; b=iyl8la69GyQFk9i6ickVs8b3zVDGmN14+tU3sRdMUaHUZ8nDMBgbsTDUz3JRMoNS2o 2cQNBNsiMK0ULINRc6FOvBZS47mUiVhwCVCtpbVDt0t/fi80JTCkrrO5B578Ssg0dKYJ 1voPEpZZ7tmWFYNHRUG2IBOdGdkHX3LKqg/uPz0x8VNxCOEG57nt0sbkPmIHFmLxTYpJ 3gk1EsWT6fHUyeFbGrMLcvflRnLwDR+/mGBFTOC3NyDGy90XL9OcRHt3iKwnky9QnKX1 Zd8YNIT+Lk9oV22i3FwHuOCuFnQrVi2ae5m/xnezeDVHyvX1EOXXWfD//5rUqzU1tOkH FOoA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature:dkim-filter; bh=AwcsD3ZLJ2Q2Scpzs7plI5pMSM3Ocr2iFmXNa65/pNI=; b=nuYJUq+yYszXWy0jFi31IVmDc/dydpk3RGuV0jwqKNt3EfruhFVDXGua2U53r0nVQk ++/F96ghbcY0spXccFNOqnrGPxni9SunwwUsJsyf7ZSlebbqYZqPzMmwqxr47F0SZqLV GV1TMe2Gj9h+JbU0BGhw14h9pCEN/3Hmq7caE301jL8srR1de0XTnK1tgzTpxbgGT4Yl 2ezyy8xLgk9ZygWd40WZbdjvhqkRcP+B7DO/I23ccKM2+yW88dmxw4fq/FElkGnpzS9e TkwercEtJHDN6fTAG1BbYWdrK8/nQjUGykVOrT75wsZY68bM+oOZWKyt8kH5Ix+Vu6x/ F3Ng== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@nifty.com header.s=dec2015msa header.b=kxwvyHu3; 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 g8si9069473edb.335.2019.09.09.04.04.26; Mon, 09 Sep 2019 04:04:27 -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; dkim=pass header.i=@nifty.com header.s=dec2015msa header.b=kxwvyHu3; 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 S1730671AbfIILEY (ORCPT + 28 others); Mon, 9 Sep 2019 07:04:24 -0400 Received: from conuserg-07.nifty.com ([210.131.2.74]:59911 "EHLO conuserg-07.nifty.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728818AbfIILEV (ORCPT ); Mon, 9 Sep 2019 07:04:21 -0400 Received: from localhost.localdomain (p14092-ipngnfx01kyoto.kyoto.ocn.ne.jp [153.142.97.92]) (authenticated) by conuserg-07.nifty.com with ESMTP id x89B4CjN031800; Mon, 9 Sep 2019 20:04:13 +0900 DKIM-Filter: OpenDKIM Filter v2.10.3 conuserg-07.nifty.com x89B4CjN031800 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nifty.com; s=dec2015msa; t=1568027053; bh=AwcsD3ZLJ2Q2Scpzs7plI5pMSM3Ocr2iFmXNa65/pNI=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=kxwvyHu3BnCwEdbW0Qb5X1GnY64B8T9gRbB9fxOp7JraPaF2kxvsNO1Nt4CLZE1xh AbOnW26f+TQGQnRlIIZ71msSX3jU+FR3MDliwJFeAfwITkp/vQIPrGhsE3Vf95ptvB ekKCQ3Dr/k+7LTyBGOOamGD3GScz7bDi9bG2RZtfEjw0yB3tCkh6VvqdfnuBKqj6i4 FNTUUWNfZQwEzm462OzkiKhtx9a7vPjaaQiARU2Bah0zaoznzYMbBE/wwiIt2PNeIt 1ySkoQZNT6IUwAHRgYxWKCio30hi0wFdGcv5yql7GQVC25RoMIL8rJvOjXaayZwM/o +MZb92uSXb7mg== X-Nifty-SrcIP: [153.142.97.92] From: Masahiro Yamada To: Jessica Yu Cc: Masahiro Yamada , linux-kernel@vger.kernel.org Subject: [PATCH 2/2] module: move CONFIG_UNUSED_SYMBOLS to the sub-menu of MODULES Date: Mon, 9 Sep 2019 20:04:08 +0900 Message-Id: <20190909110408.21832-2-yamada.masahiro@socionext.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20190909110408.21832-1-yamada.masahiro@socionext.com> References: <20190909110408.21832-1-yamada.masahiro@socionext.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org When CONFIG_MODULES is disabled, CONFIG_UNUSED_SYMBOLS is pointless, thus it should be invisible. Instead of adding "depends on MODULES", I moved it to the sub-menu "Enable loadable module support", which is a better fit. I put it close to TRIM_UNUSED_KSYMS because it depends on !UNUSED_SYMBOLS. Signed-off-by: Masahiro Yamada --- init/Kconfig | 16 ++++++++++++++++ lib/Kconfig.debug | 16 ---------------- 2 files changed, 16 insertions(+), 16 deletions(-) -- 2.17.1 Acked-by: Jessica Yu diff --git a/init/Kconfig b/init/Kconfig index 9e72cc6071f5..b3100aa3138f 100644 --- a/init/Kconfig +++ b/init/Kconfig @@ -2117,6 +2117,22 @@ config MODULE_COMPRESS_XZ endchoice +config UNUSED_SYMBOLS + bool "Enable unused/obsolete exported symbols" + default y if X86 + help + Unused but exported symbols make the kernel needlessly bigger. For + that reason most of these unused exports will soon be removed. This + option is provided temporarily to provide a transition period in case + some external kernel module needs one of these symbols anyway. If you + encounter such a case in your module, consider if you are actually + using the right API. (rationale: since nobody in the kernel is using + this in a module, there is a pretty good chance it's actually the + wrong interface to use). If you really need the symbol, please send a + mail to the linux kernel mailing list mentioning the symbol and why + you really need it, and what the merge plan to the mainline kernel for + your module is. + config TRIM_UNUSED_KSYMS bool "Trim unused exported kernel symbols" depends on !UNUSED_SYMBOLS diff --git a/lib/Kconfig.debug b/lib/Kconfig.debug index 5960e2980a8a..e0e14780a13d 100644 --- a/lib/Kconfig.debug +++ b/lib/Kconfig.debug @@ -277,22 +277,6 @@ config READABLE_ASM to keep kernel developers who have to stare a lot at assembler listings sane. -config UNUSED_SYMBOLS - bool "Enable unused/obsolete exported symbols" - default y if X86 - help - Unused but exported symbols make the kernel needlessly bigger. For - that reason most of these unused exports will soon be removed. This - option is provided temporarily to provide a transition period in case - some external kernel module needs one of these symbols anyway. If you - encounter such a case in your module, consider if you are actually - using the right API. (rationale: since nobody in the kernel is using - this in a module, there is a pretty good chance it's actually the - wrong interface to use). If you really need the symbol, please send a - mail to the linux kernel mailing list mentioning the symbol and why - you really need it, and what the merge plan to the mainline kernel for - your module is. - config DEBUG_FS bool "Debug Filesystem" help