linux-pci.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Adrian-Ken Rueegsegger <ken@codelabs.ch>
To: linux-pci@vger.kernel.org
Cc: ken@codelabs.ch
Subject: PCI support check in pcibios_init()
Date: Wed, 23 Mar 2016 11:34:28 +0100	[thread overview]
Message-ID: <1458729269-9440-1-git-send-email-ken@codelabs.ch> (raw)

Hi,

We are running Linux as a VM on top of the Muen Separation Kernel [1], where
we only allow PCI config space access of pass-through devices via MMCONFIG. In
this use case the PCI support check in pcibios_init() fails as raw_pci_ops is
not set:

int __init pcibios_init(void)
{
    if (!raw_pci_ops) {
        printk(KERN_WARNING "PCI: System does not support PCI\n");
        return 0;
    }
	...
}

As a consequence device resources are not allocated since the following call to
pcibios_resource_survey() is skipped. Extending the check to also consider
raw_pci_ext_ops (see patch) leads to the proper resource allocation in our use
case.

Is the described change the correct solution or is there a particular reason to
only check raw_pci_ops in pcibios_init()?

Regards,
Adrian

[1] - https://muen.codelabs.ch/


             reply	other threads:[~2016-03-23 10:44 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-03-23 10:34 Adrian-Ken Rueegsegger [this message]
2016-03-23 10:34 ` [RFC PATCH] x86/PCI: Refine PCI support check in pcibios_init() Adrian-Ken Rueegsegger
2016-04-12  4:47   ` Bjorn Helgaas

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=1458729269-9440-1-git-send-email-ken@codelabs.ch \
    --to=ken@codelabs.ch \
    --cc=linux-pci@vger.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 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).