linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
To: adobriyan@gmail.com
Cc: sfr@canb.auug.org.au, linux-next@vger.kernel.org,
	linux-kernel@vger.kernel.org, David.Woodhouse@intel.com,
	tony.luck@intel.com, fenghua.yu@intel.com, mingo@elte.hu
Subject: Re: linux-next: undefined reference to 'forbid_dac'
Date: Thu, 23 Oct 2008 22:16:39 +0900	[thread overview]
Message-ID: <20081023221703Z.fujita.tomonori@lab.ntt.co.jp> (raw)
In-Reply-To: <20081023122604.GB15805@x200.localdomain>

On Thu, 23 Oct 2008 16:26:04 +0400
Alexey Dobriyan <adobriyan@gmail.com> wrote:

> On i386-allnoconfig:
> 
> arch/x86/kernel/built-in.o: In function `iommu_setup':
> pci-dma.c:(.init.text+0x3491): undefined reference to `forbid_dac'
> pci-dma.c:(.init.text+0x3497): undefined reference to `forbid_dac'
> pci-dma.c:(.init.text+0x34b1): undefined reference to `forbid_dac'
> pci-dma.c:(.init.text+0x34b7): undefined reference to `forbid_dac'
> pci-dma.c:(.init.text+0x34f7): undefined reference to `forbid_dac'

Hmm, the following forbid_dac relocation doesn't look related to
adding VT-d support to IA64...


=
From: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
Subject: [PATCH] x86: fix undefined reference to forbid_dac

The following commit moves forbid_dac from arch/kernel/pci-dma.c to
drivers/pci/quirks.c, which breaks !CONFIG_PCI_QUIRKS:

commit 5b6985ce8ec7127b4d60ad450b64ca8b82748a3b
Author: Fenghua Yu <fenghua.yu@intel.com>
Date:   Thu Oct 16 18:02:32 2008 -0700

    intel-iommu: IA64 support

    The current Intel IOMMU code assumes that both host page size and Intel
    IOMMU page size are 4KiB. The first patch supports variable page size.
    This provides support for IA64 which has multiple page sizes.

    This patch also adds some other code hooks for IA64 platform including
    DMAR_OPERATION_TIMEOUT definition.

    [dwmw2: some cleanup]
    Signed-off-by: Fenghua Yu <fenghua.yu@intel.com>
    Signed-off-by: Tony Luck <tony.luck@intel.com>
    Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>

---
 arch/x86/kernel/pci-dma.c |   16 ++++++++++++++++
 drivers/pci/quirks.c      |   14 --------------
 2 files changed, 16 insertions(+), 14 deletions(-)

diff --git a/arch/x86/kernel/pci-dma.c b/arch/x86/kernel/pci-dma.c
index 1972266..1926248 100644
--- a/arch/x86/kernel/pci-dma.c
+++ b/arch/x86/kernel/pci-dma.c
@@ -9,6 +9,8 @@
 #include <asm/calgary.h>
 #include <asm/amd_iommu.h>
 
+static int forbid_dac __read_mostly;
+
 struct dma_mapping_ops *dma_ops;
 EXPORT_SYMBOL(dma_ops);
 
@@ -291,3 +293,17 @@ void pci_iommu_shutdown(void)
 }
 /* Must execute after PCI subsystem */
 fs_initcall(pci_iommu_init);
+
+#ifdef CONFIG_PCI
+/* Many VIA bridges seem to corrupt data for DAC. Disable it here */
+
+static __devinit void via_no_dac(struct pci_dev *dev)
+{
+	if ((dev->class >> 8) == PCI_CLASS_BRIDGE_PCI && forbid_dac == 0) {
+		printk(KERN_INFO "PCI: VIA PCI bridge detected."
+				 "Disabling DAC.\n");
+		forbid_dac = 1;
+	}
+}
+DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_VIA, PCI_ANY_ID, via_no_dac);
+#endif
diff --git a/drivers/pci/quirks.c b/drivers/pci/quirks.c
index 96cf8ec..bbf66ea 100644
--- a/drivers/pci/quirks.c
+++ b/drivers/pci/quirks.c
@@ -43,20 +43,6 @@ static void __devinit quirk_mellanox_tavor(struct pci_dev *dev)
 DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_MELLANOX,PCI_DEVICE_ID_MELLANOX_TAVOR,quirk_mellanox_tavor);
 DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_MELLANOX,PCI_DEVICE_ID_MELLANOX_TAVOR_BRIDGE,quirk_mellanox_tavor);
 
-/* Many VIA bridges seem to corrupt data for DAC. Disable it here */
-int forbid_dac __read_mostly;
-EXPORT_SYMBOL(forbid_dac);
-
-static __devinit void via_no_dac(struct pci_dev *dev)
-{
-	if ((dev->class >> 8) == PCI_CLASS_BRIDGE_PCI && forbid_dac == 0) {
-		dev_info(&dev->dev,
-			"VIA PCI bridge detected. Disabling DAC.\n");
-		forbid_dac = 1;
-	}
-}
-DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_VIA, PCI_ANY_ID, via_no_dac);
-
 /* Deal with broken BIOS'es that neglect to enable passive release,
    which can cause problems in combination with the 82441FX/PPro MTRRs */
 static void quirk_passive_release(struct pci_dev *dev)
-- 
1.5.5.GIT


  reply	other threads:[~2008-10-23 13:17 UTC|newest]

Thread overview: 53+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-10-23 10:36 linux-next: Tree for October 23 Stephen Rothwell
2008-10-23 12:11 ` linux-next: kernel/trace/trace.c:658: error: Alexey Dobriyan
2008-10-23 12:48   ` Frédéric Weisbecker
2008-10-23 13:15     ` Frédéric Weisbecker
2008-10-23 14:41       ` Frederic Weisbecker
2008-10-23 14:37         ` Geert Uytterhoeven
2008-10-23 14:57           ` Frédéric Weisbecker
2008-10-23 15:30             ` Geert Uytterhoeven
2008-10-23 15:33               ` Frédéric Weisbecker
2008-10-23 17:27               ` [PATCH] tracing: fix a build error on alpha and m68k Frederic Weisbecker
2008-10-23 16:24                 ` Frédéric Weisbecker
2008-10-23 16:34                 ` Alexey Dobriyan
2008-10-23 16:35                   ` Frédéric Weisbecker
2008-10-23 16:38                   ` Ingo Molnar
2008-10-23 16:51                     ` Frédéric Weisbecker
2008-10-23 16:55                       ` Ingo Molnar
2008-10-23 17:06                         ` Frédéric Weisbecker
2008-10-23 17:12                           ` Steven Rostedt
2008-10-23 17:25                             ` Frédéric Weisbecker
2008-10-24 14:16                     ` Frederic Weisbecker
2008-10-24 13:42                       ` [PATCH] ftrace: handle archs that do not support irqs_disabled_flags Steven Rostedt
2008-10-24 13:54                         ` Frédéric Weisbecker
2008-10-25  8:24                         ` Geert Uytterhoeven
2008-10-28  7:25                           ` Greg Ungerer
2008-10-23 17:14                   ` [PATCH] tracing: fix a build error on alpha and m68k Steven Rostedt
2008-10-30 21:49                   ` Alexey Dobriyan
2008-10-30 22:57                     ` Frédéric Weisbecker
2008-10-30 23:03                       ` Ingo Molnar
2008-10-31  8:50                     ` Geert Uytterhoeven
2008-10-31  9:55                       ` Ingo Molnar
2008-11-01 10:16                         ` Geert Uytterhoeven
2008-10-23 16:37                 ` Ingo Molnar
2008-10-23 12:15 ` linux-next: arch/alpha/include/asm/smp.h:48:1: error: "cpu_possible_map" redefined Alexey Dobriyan
2008-10-23 12:16   ` Alexey Dobriyan
2008-10-23 15:10     ` Rusty Russell
2008-10-23 12:22 ` linux-next: include/linux/mmzone.h:288: error: 'CONFIG_NR_CPUS' undeclared here (not in a function) Alexey Dobriyan
2008-10-23 14:38   ` Geert Uytterhoeven
2008-10-23 12:26 ` linux-next: undefined reference to 'forbid_dac' Alexey Dobriyan
2008-10-23 13:16   ` FUJITA Tomonori [this message]
2008-10-23 12:57 ` linux-next: undefined reference to `nop_trace' Alexey Dobriyan
2008-10-23 13:07 ` linux-next: arch/s390/kernel/smp.c:120: error: request for member 'bits' in something not a structure or union Alexey Dobriyan
2008-10-23 14:14 ` linux-next: x86_64 UML broken Alexey Dobriyan
2008-10-23 14:48 ` linux-next: drivers/lguest/page_tables.c:1044: error: invalid initializer Alexey Dobriyan
2008-10-24  2:08   ` Rusty Russell
2008-10-24  0:18 ` linux-next: Tree for October 23 (cx88) Randy Dunlap
2008-10-24  1:04 ` linux-next: Tree for October 23 Randy Dunlap
2008-10-26  7:19   ` [ofa-general] " Or Gerlitz
2008-10-26 18:49     ` Randy Dunlap
2008-10-24  1:14 ` [PATCH] PCI hotplug printk format Randy Dunlap
2008-10-24 17:42   ` Jesse Barnes
2008-10-24 17:49   ` Jesse Barnes
2008-10-24  1:17 ` [PATCH] nfsctl: credentials error Randy Dunlap
2008-10-24  1:17 ` [PATCH] coda: " Randy Dunlap

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20081023221703Z.fujita.tomonori@lab.ntt.co.jp \
    --to=fujita.tomonori@lab.ntt.co.jp \
    --cc=David.Woodhouse@intel.com \
    --cc=adobriyan@gmail.com \
    --cc=fenghua.yu@intel.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-next@vger.kernel.org \
    --cc=mingo@elte.hu \
    --cc=sfr@canb.auug.org.au \
    --cc=tony.luck@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).