From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751997AbcGNSpN (ORCPT ); Thu, 14 Jul 2016 14:45:13 -0400 Received: from terminus.zytor.com ([198.137.202.10]:34592 "EHLO terminus.zytor.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751279AbcGNSpJ (ORCPT ); Thu, 14 Jul 2016 14:45:09 -0400 Date: Thu, 14 Jul 2016 11:44:39 -0700 From: tip-bot for Paul Gortmaker Message-ID: Cc: torvalds@linux-foundation.org, tglx@linutronix.de, peterz@infradead.org, hpa@zytor.com, linux-kernel@vger.kernel.org, paul.gortmaker@windriver.com, mingo@kernel.org Reply-To: paul.gortmaker@windriver.com, linux-kernel@vger.kernel.org, tglx@linutronix.de, torvalds@linux-foundation.org, hpa@zytor.com, peterz@infradead.org, mingo@kernel.org In-Reply-To: <20160714001901.31603-6-paul.gortmaker@windriver.com> References: <20160714001901.31603-6-paul.gortmaker@windriver.com> To: linux-tip-commits@vger.kernel.org Subject: [tip:x86/headers] x86/platform: Audit and remove any unnecessary uses of module.h Git-Commit-ID: cc3ae7b0af27118994c1e491382b253be3b762bf X-Mailer: tip-git-log-daemon Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset=UTF-8 Content-Disposition: inline Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Commit-ID: cc3ae7b0af27118994c1e491382b253be3b762bf Gitweb: http://git.kernel.org/tip/cc3ae7b0af27118994c1e491382b253be3b762bf Author: Paul Gortmaker AuthorDate: Wed, 13 Jul 2016 20:18:58 -0400 Committer: Ingo Molnar CommitDate: Thu, 14 Jul 2016 15:06:59 +0200 x86/platform: Audit and remove any unnecessary uses of module.h Historically a lot of these existed because we did not have a distinction between what was modular code and what was providing support to modules via EXPORT_SYMBOL and friends. That changed when we forked out support for the latter into the export.h file. This means we should be able to reduce the usage of module.h in code that is obj-y Makefile or bool Kconfig. The advantage in doing so is that module.h itself sources about 15 other headers; adding significantly to what we feed cpp, and it can obscure what headers we are effectively using. Since module.h was the source for init.h (for __init) and for export.h (for EXPORT_SYMBOL) we consider each obj-y/bool instance for the presence of either and replace as needed. One module.h was converted to moduleparam.h since the file had multiple module_param() in it, and another file had an instance of MODULE_DEVICE_TABLE deleted, since that is a no-op when builtin. Finally, the 32 bit build coverage of olpc_ofw revealed a couple implicit includes, which were pretty self evident to fix based on what gcc was complaining about. Signed-off-by: Paul Gortmaker Cc: Linus Torvalds Cc: Peter Zijlstra Cc: Thomas Gleixner Link: http://lkml.kernel.org/r/20160714001901.31603-6-paul.gortmaker@windriver.com Signed-off-by: Ingo Molnar --- arch/x86/platform/ce4100/ce4100.c | 2 +- arch/x86/platform/efi/efi_64.c | 2 +- arch/x86/platform/intel-mid/intel-mid.c | 2 +- arch/x86/platform/intel-mid/pwr.c | 4 +--- arch/x86/platform/intel-mid/sfi.c | 2 +- arch/x86/platform/olpc/olpc.c | 2 +- arch/x86/platform/olpc/olpc_ofw.c | 5 ++++- arch/x86/platform/ts5500/ts5500.c | 2 +- arch/x86/platform/uv/uv_irq.c | 2 +- arch/x86/platform/uv/uv_nmi.c | 2 +- 10 files changed, 13 insertions(+), 12 deletions(-) diff --git a/arch/x86/platform/ce4100/ce4100.c b/arch/x86/platform/ce4100/ce4100.c index 701fd58..7ab4d3f 100644 --- a/arch/x86/platform/ce4100/ce4100.c +++ b/arch/x86/platform/ce4100/ce4100.c @@ -11,7 +11,7 @@ #include #include #include -#include +#include #include #include #include diff --git a/arch/x86/platform/efi/efi_64.c b/arch/x86/platform/efi/efi_64.c index b226b3f..2f98445 100644 --- a/arch/x86/platform/efi/efi_64.c +++ b/arch/x86/platform/efi/efi_64.c @@ -24,7 +24,7 @@ #include #include #include -#include +#include #include #include #include diff --git a/arch/x86/platform/intel-mid/intel-mid.c b/arch/x86/platform/intel-mid/intel-mid.c index abbf49c..ce119d2 100644 --- a/arch/x86/platform/intel-mid/intel-mid.c +++ b/arch/x86/platform/intel-mid/intel-mid.c @@ -20,7 +20,7 @@ #include #include #include -#include +#include #include #include diff --git a/arch/x86/platform/intel-mid/pwr.c b/arch/x86/platform/intel-mid/pwr.c index 5bc90dd..c901a34 100644 --- a/arch/x86/platform/intel-mid/pwr.c +++ b/arch/x86/platform/intel-mid/pwr.c @@ -21,10 +21,9 @@ #include #include -#include #include #include -#include +#include #include #include @@ -407,7 +406,6 @@ static const struct pci_device_id mid_pwr_pci_ids[] = { { PCI_VDEVICE(INTEL, PCI_DEVICE_ID_TANGIER), (kernel_ulong_t)&mid_info }, {} }; -MODULE_DEVICE_TABLE(pci, mid_pwr_pci_ids); static struct pci_driver mid_pwr_pci_driver = { .name = "intel_mid_pwr", diff --git a/arch/x86/platform/intel-mid/sfi.c b/arch/x86/platform/intel-mid/sfi.c index 1555672..051d264 100644 --- a/arch/x86/platform/intel-mid/sfi.c +++ b/arch/x86/platform/intel-mid/sfi.c @@ -24,7 +24,7 @@ #include #include #include -#include +#include #include #include #include diff --git a/arch/x86/platform/olpc/olpc.c b/arch/x86/platform/olpc/olpc.c index 2737608..7c3077e 100644 --- a/arch/x86/platform/olpc/olpc.c +++ b/arch/x86/platform/olpc/olpc.c @@ -12,7 +12,7 @@ #include #include -#include +#include #include #include #include diff --git a/arch/x86/platform/olpc/olpc_ofw.c b/arch/x86/platform/olpc/olpc_ofw.c index e7604f6..f1aab8c 100644 --- a/arch/x86/platform/olpc/olpc_ofw.c +++ b/arch/x86/platform/olpc/olpc_ofw.c @@ -1,9 +1,12 @@ #include -#include +#include +#include #include #include #include #include +#include +#include #include #include diff --git a/arch/x86/platform/ts5500/ts5500.c b/arch/x86/platform/ts5500/ts5500.c index baf16e7..952191b 100644 --- a/arch/x86/platform/ts5500/ts5500.c +++ b/arch/x86/platform/ts5500/ts5500.c @@ -23,7 +23,7 @@ #include #include #include -#include +#include #include #include #include diff --git a/arch/x86/platform/uv/uv_irq.c b/arch/x86/platform/uv/uv_irq.c index e1c2463..776c659 100644 --- a/arch/x86/platform/uv/uv_irq.c +++ b/arch/x86/platform/uv/uv_irq.c @@ -8,7 +8,7 @@ * Copyright (C) 2008 Silicon Graphics, Inc. All rights reserved. */ -#include +#include #include #include #include diff --git a/arch/x86/platform/uv/uv_nmi.c b/arch/x86/platform/uv/uv_nmi.c index 8dd8005..cd5173a 100644 --- a/arch/x86/platform/uv/uv_nmi.c +++ b/arch/x86/platform/uv/uv_nmi.c @@ -24,7 +24,7 @@ #include #include #include -#include +#include #include #include #include