[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <A6AD88C3F2289247BE726C37303E1EB8B0216BF5@orsmsx505.amr.corp.intel.com>
Date: Thu, 25 Jun 2009 14:56:19 -0700
From: "Yu, Fenghua" <fenghua.yu@...el.com>
To: 'David Woodhouse' <dwmw2@...radead.org>,
'FUJITA Tomonori' <fujita.tomonori@....ntt.co.jp>
CC: "'chrisw@...hat.com'" <chrisw@...hat.com>,
"'torvalds@...ux-foundation.org'" <torvalds@...ux-foundation.org>,
"'akpm@...ux-foundation.org'" <akpm@...ux-foundation.org>,
"Luck, Tony" <tony.luck@...el.com>,
"'linux-kernel@...r.kernel.org'" <linux-kernel@...r.kernel.org>,
"'iommu@...ts.linux-foundation.org'"
<iommu@...ts.linux-foundation.org>,
"'linux-ia64@...r.kernel.org'" <linux-ia64@...r.kernel.org>
Subject: RE: [PATCH v2] IA64 Compilation Error Fix for Intel IOMMU Identity
Mapping Support
>-----Original Message-----
>From: David Woodhouse [mailto:dwmw2@...radead.org]
>Sent: Thursday, June 25, 2009 2:52 PM
>To: FUJITA Tomonori
>Cc: Yu, Fenghua; chrisw@...hat.com; torvalds@...ux-foundation.org;
>akpm@...ux-foundation.org; Luck, Tony; linux-kernel@...r.kernel.org;
>iommu@...ts.linux-foundation.org; linux-ia64@...r.kernel.org
>Subject: Re: [PATCH v2] IA64 Compilation Error Fix for Intel IOMMU Identity
>Mapping Support
>
>On Thu, 2009-06-25 at 08:11 +0100, David Woodhouse wrote:
>> It raises the question: Why are we using firmware-specific interfaces to
>> list the available memory -- can't we get that from somewhere _generic_?
>>
>> The less we tie our code to these crappy BIOS, EFI and ACPI interfaces,
>> the better off we'll be.
>
>Does this work everywhere... ?
>
>(Fenghua, why are we doing the whole setup per pci dev anyway -- why not
>set up the page tables once and point all devices at the same page
>tables?)
>
That's what the ia64 fix patch does...the first pci device set up the page table. Then all following pci devices use that page table by setting up the context mapping.
+ if (first_pdev) {
+ /*
+ * first pdev sets up the whole page table for
+ * si_domain.
+ */
+ first_pdev = 0;
+ ret = iommu_setup_identity_map(pdev);
+ if (ret)
+ return ret;
+ } else {
+ /*
+ * following pdev's just use the page table.
+ */
+ printk(KERN_INFO "IOMMU: identity mapping for device %s\n",
+ pci_name(pdev));
+ ret = domain_context_mapping(si_domain, pdev,
+ CONTEXT_TT_MULTI_LEVEL);
+ if (ret)
Thanks.
-Fenghua
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists