All of lore.kernel.org
 help / color / mirror / Atom feed
From: Borislav Petkov <bp@suse.de>
To: Aravind Gopalakrishnan <aravind.gopalakrishnan@amd.com>
Cc: Ingo Molnar <mingo@kernel.org>,
	tglx@linutronix.de, mingo@redhat.com, hpa@zytor.com,
	x86@kernel.org, bhelgaas@google.com,
	linux-kernel@vger.kernel.org, Suravee.Suthikulpanit@amd.com,
	joro@8bytes.org
Subject: Re: [PATCH] x86, aperture: Check for GART before accessing GART registers
Date: Tue, 7 Apr 2015 14:34:57 +0200	[thread overview]
Message-ID: <20150407123457.GA3681@pd.tnic> (raw)
In-Reply-To: <5523125E.2010605@amd.com>

On Mon, Apr 06, 2015 at 06:10:22PM -0500, Aravind Gopalakrishnan wrote:
> >So what happens if !early_pci_allowed() but the GART is present? We'll
> >set amd_northbridges.flags |= AMD_NB_GART, but won't run any of the
> >setup code in aperture_64.c, right? Is that a valid setup?
> 
> It might be a valid setup. But it would work correctly only if BIOS did the
> right thing with setting up aperture space.
> 
> If !early_pci_allowed() and BIOS did not setup aperture correctly, that
> would have caused problems already.
> But it has not been an issue so far right?

I think the right question to ask is:

What are we doing when there's no GART?

So what you probably want to do is:

	if (!amd_gart_present())
		return -ENODEV;

*before* the compound check.

Now, if we have detected a GART, i.e., amd_gart_present() is TRUE, the
code will behave as it used to behave before.

This should be the least intrusive change going forward IMHO.

-- 
Regards/Gruss,
    Boris.

ECO tip #101: Trim your mails when you reply.
--

  reply	other threads:[~2015-04-07 12:37 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-04-01 14:32 [PATCH] x86, aperture: Check for GART before accessing GART registers Aravind Gopalakrishnan
2015-04-02  6:59 ` Borislav Petkov
2015-04-02 10:01 ` Ingo Molnar
2015-04-02 15:54   ` Aravind Gopalakrishnan
2015-04-02 16:06     ` Ingo Molnar
2015-04-02 16:23       ` Aravind Gopalakrishnan
2015-04-02 16:53         ` Borislav Petkov
2015-04-02 17:04           ` Aravind Gopalakrishnan
2015-04-02 17:17             ` Borislav Petkov
2015-04-02 18:19               ` Ingo Molnar
2015-04-06 23:10                 ` Aravind Gopalakrishnan
2015-04-07 12:34                   ` Borislav Petkov [this message]
2015-04-07 14:46                     ` Aravind Gopalakrishnan
2015-04-07 14:57                       ` Borislav Petkov
2015-04-07 20:34                         ` Aravind Gopalakrishnan
2015-04-08  7:25                           ` Borislav Petkov
2015-04-14 11:15               ` Jörg-Volker Peetz
2015-04-14 11:33                 ` Borislav Petkov
2015-04-14 18:22                   ` Jörg-Volker Peetz
2015-04-14 18:36                     ` Borislav Petkov
2015-05-04 11:11                       ` Joerg Roedel

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=20150407123457.GA3681@pd.tnic \
    --to=bp@suse.de \
    --cc=Suravee.Suthikulpanit@amd.com \
    --cc=aravind.gopalakrishnan@amd.com \
    --cc=bhelgaas@google.com \
    --cc=hpa@zytor.com \
    --cc=joro@8bytes.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@kernel.org \
    --cc=mingo@redhat.com \
    --cc=tglx@linutronix.de \
    --cc=x86@kernel.org \
    /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.