From patchwork Sun Jun 3 18:48:18 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sebastian Andrzej Siewior X-Patchwork-Id: 162592 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by ozlabs.org (Postfix) with ESMTP id EB418B6FA9 for ; Mon, 4 Jun 2012 05:26:49 +1000 (EST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754278Ab2FCT0t (ORCPT ); Sun, 3 Jun 2012 15:26:49 -0400 Received: from Chamillionaire.breakpoint.cc ([80.244.247.6]:47047 "EHLO Chamillionaire.breakpoint.cc" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754217Ab2FCT0s (ORCPT ); Sun, 3 Jun 2012 15:26:48 -0400 Received: from localhost ([127.0.0.1] helo=bazinga.HH.breakpoint.cc ident=410d493183e3c5611c03d88e6b900be8) by Chamillionaire.breakpoint.cc with esmtp (Exim 4.72) (envelope-from ) id 1SbFqp-0002L8-J5; Sun, 03 Jun 2012 20:48:31 +0200 From: Sebastian Andrzej Siewior To: linux-pci@vger.kernel.org Cc: linux-kbuild@vger.kernel.org, Bjorn Helgaas , Michal Marek , Sebastian Andrzej Siewior , x86@kernel.org Subject: [PATCH 2/9] x86/quirks: move PCI fixup hooks from __init to __devinit Date: Sun, 3 Jun 2012 20:48:18 +0200 Message-Id: <1338749305-22558-3-git-send-email-sebastian@breakpoint.cc> X-Mailer: git-send-email 1.7.10 In-Reply-To: <1338749305-22558-1-git-send-email-sebastian@breakpoint.cc> References: <1338749305-22558-1-git-send-email-sebastian@breakpoint.cc> X-Breakpoint-Spam-Score: -1.0 X-Breakpoint-Spam-Level: - X-Breakpoint-Spam-Status: No , -1.0 points, 5.0 required, ALL_TRUSTED=-1 Sender: linux-pci-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pci@vger.kernel.org The fixups are executed once the pci-device is found which is during boot process so __init seems fine as long as the platform does not support hotplug. However it is possible to remove the PCI bus at run time and have it rediscovered again via "echo 1 > /sys/bus/pci/rescan" and this will call the fixups again. Cc: x86@kernel.org Signed-off-by: Sebastian Andrzej Siewior --- arch/x86/kernel/quirks.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/x86/kernel/quirks.c b/arch/x86/kernel/quirks.c index 03920a1..1b27de5 100644 --- a/arch/x86/kernel/quirks.c +++ b/arch/x86/kernel/quirks.c @@ -512,7 +512,7 @@ DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_ATI, PCI_DEVICE_ID_ATI_SBX00_SMBUS, #if defined(CONFIG_PCI) && defined(CONFIG_NUMA) /* Set correct numa_node information for AMD NB functions */ -static void __init quirk_amd_nb_node(struct pci_dev *dev) +static void __devinit quirk_amd_nb_node(struct pci_dev *dev) { struct pci_dev *nb_ht; unsigned int devfn;