All of lore.kernel.org
 help / color / mirror / Atom feed
From: Yinghai Lu <yinghai@kernel.org>
To: Jesse Barnes <jbarnes@virtuousgeek.org>,
	Ingo Molnar <mingo@elte.hu>, "H. Peter Anvin" <hpa@zytor.com>,
	Thomas Gleixner <tglx@linutronix.de>
Cc: Robert Hancock <hancockrwd@gmail.com>,
	Tvrtko Ursulin <tvrtko@ursulin.net>,
	Tvrtko Ursulin <tvrtko.ursulin@sophos.com>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: [PATCH] x86/pci: don't check mmconf again if it is from MSR with amd faml0h
Date: Mon, 14 Dec 2009 18:47:25 -0800	[thread overview]
Message-ID: <4B26F8BD.5070501@kernel.org> (raw)
In-Reply-To: <4B26E4C7.8040100@gmail.com>


for AMD Fam10h, it we read mmconf from MSR early, we should just trust it
because we check it and correct it already.

so skip the reject check there.

Signed-off-by: Yinghai Lu <yinghai@kernel.org>

---
 arch/x86/pci/mmconfig-shared.c |   10 +++++++++-
 1 file changed, 9 insertions(+), 1 deletion(-)

Index: linux-2.6/arch/x86/pci/mmconfig-shared.c
===================================================================
--- linux-2.6.orig/arch/x86/pci/mmconfig-shared.c
+++ linux-2.6/arch/x86/pci/mmconfig-shared.c
@@ -168,6 +168,7 @@ static const char __init *pci_mmcfg_inte
 	return "Intel Corporation 945G/GZ/P/PL Express Memory Controller Hub";
 }
 
+static int __initdata amd_fam10h_mmconf_found_via_hostbridge;
 static const char __init *pci_mmcfg_amd_fam10h(void)
 {
 	u32 low, high, address;
@@ -215,6 +216,8 @@ static const char __init *pci_mmcfg_amd_
 			return NULL;
 		}
 
+	amd_fam10h_mmconf_found_via_hostbridge = 1;
+
 	return "AMD Family 10h NB";
 }
 
@@ -606,7 +609,12 @@ static void __init __pci_mmcfg_init(int
 	if (!known_bridge)
 		acpi_sfi_table_parse(ACPI_SIG_MCFG, pci_parse_mcfg);
 
-	pci_mmcfg_reject_broken(early);
+	/*
+	 * if it is amd fam10h, and that is read from msr,
+	 * we don't need check them again.
+	 */
+	if (!amd_fam10h_mmconf_found_via_hostbridge)
+		pci_mmcfg_reject_broken(early);
 
 	if (list_empty(&pci_mmcfg_list))
 		return;

  parent reply	other threads:[~2009-12-15  2:49 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-12-13  8:07 Are there MTRR settings correct? Tvrtko Ursulin
2009-12-13  8:26 ` Are these " Tvrtko Ursulin
2009-12-13  9:25   ` Yinghai Lu
2009-12-13 17:19     ` Tvrtko Ursulin
2009-12-13 22:56       ` Yinghai Lu
2009-12-14 11:19         ` Tvrtko Ursulin
2009-12-14 11:25           ` Yinghai Lu
2009-12-14 19:34             ` Tvrtko Ursulin
2009-12-14 19:47               ` Yinghai Lu
2009-12-14 20:16                 ` Tvrtko Ursulin
2009-12-14 20:26                   ` Yinghai Lu
2009-12-15  1:22                     ` Robert Hancock
2009-12-15  1:42                       ` Yinghai Lu
2009-12-15 16:55                         ` Bjorn Helgaas
2009-12-15 18:01                           ` Yinghai Lu
2009-12-15 20:50                           ` Robert Hancock
2009-12-15 21:09                             ` Jesse Barnes
2009-12-16  0:14                               ` Robert Hancock
2009-12-16  6:26                             ` Yinghai Lu
2009-12-15  2:47                       ` Yinghai Lu [this message]
2009-12-16 20:06                         ` [PATCH] x86/pci: don't check mmconf again if it is from MSR with amd faml0h Jesse Barnes
2009-12-16 22:18                           ` Yinghai Lu
2009-12-13 20:26     ` Are these MTRR settings correct? Robert Hancock

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=4B26F8BD.5070501@kernel.org \
    --to=yinghai@kernel.org \
    --cc=hancockrwd@gmail.com \
    --cc=hpa@zytor.com \
    --cc=jbarnes@virtuousgeek.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@elte.hu \
    --cc=tglx@linutronix.de \
    --cc=tvrtko.ursulin@sophos.com \
    --cc=tvrtko@ursulin.net \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.