public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Jens Axboe <jens.axboe@oracle.com>
To: Kenji Kaneshige <kaneshige.kenji@jp.fujitsu.com>
Cc: Linux Kernel <linux-kernel@vger.kernel.org>,
	jbarnes@virtuousgeek.org, linux-pci@vger.kernel.org
Subject: Re: pci-express hotplug
Date: Tue, 13 Oct 2009 13:25:26 +0200	[thread overview]
Message-ID: <20091013112525.GX9228@kernel.dk> (raw)
In-Reply-To: <4AD45B1B.8000609@jp.fujitsu.com>

On Tue, Oct 13 2009, Kenji Kaneshige wrote:
> Jens Axboe wrote:
>> On Tue, Oct 13 2009, Kenji Kaneshige wrote:
>>> Jens Axboe wrote:
>>>> Hi,
>>>>
>>>> I'm trying to get pci-express hotplug working in a box here. I don't
>>>> really care about the hotplug aspect, I just want the darn pci-e slots
>>>> that are designated hotplug slots to actually WORK. When I load pciehp,
>>>> I get:
>>>>
>>>> Firmware did not grant requested _OSC control
>>>> Firmware did not grant requested _OSC control
>>>> Firmware did not grant requested _OSC control
>>>> Firmware did not grant requested _OSC control
>>>> pciehp 0000:00:05.0:pcie04: HPC vendor_id 8086 device_id 340c ss_vid 0 ss_did 0
>>>> pciehp 0000:00:05.0:pcie04: service driver pciehp loaded
>>>> Firmware did not grant requested _OSC control
>>>> pciehp 0000:00:07.0:pcie04: HPC vendor_id 8086 device_id 340e ss_vid 0 ss_did 0
>>>> pciehp 0000:00:07.0:pcie04: service driver pciehp loaded
>>>> Firmware did not grant requested _OSC control
>>>> pciehp 0000:80:07.0:pcie04: HPC vendor_id 8086 device_id 340e ss_vid 0 ss_did 0
>>>> pciehp 0000:80:07.0:pcie04: service driver pciehp loaded
>>>> pciehp 0000:80:09.0:pcie04: HPC vendor_id 8086 device_id 3410 ss_vid 0 ss_did 0
>>>> pciehp 0000:80:09.0:pcie04: service driver pciehp loaded
>>>> pciehp: PCI Express Hot Plug Controller Driver version: 0.4
>>>>
>>>> and the devices in the hotplug slots stay off. Is this an ACPI/bios
>>>> issue? How can I debug this?
>>>>
>>> Could you give me the result of "ls -lR /sys/bus/pci/slots/"
>>> after loading pciehp?
>>
>> I have attached the result of that ls prior to loading pciehp/acpiphp
>> (pre-load), after loading pciehp (pciehp-load), and with acpiphp loaded
>> only as well (acpiphp-load).
>>
>
> Thank you for the info. From the information, I confirmed that hotplug
> slots are detected by pciehp even though _OSC evaluation failed. There
> are two ways to take control from the firmware through ACPI control
> method. One is _OSC control method, and the other is OSHP control method.
> I guess your ACPI fimware has both _OSC and OSHP on DSDT (ACPI Namespace),
> and pciehp assumes that it took control through OSHP after the _OSC
> evaluation failure. I think this pciehp's behavior is wrong because of
> the following reasons and I think pciehp driver mis-detected the hotplug
> slots on your environment because of this.
>
> - According to the PCI firmware specification, pciehp driver must use the
>  result of _OSC, if the platform implements both _OSC and OSHP.
> - OSHP control method seems only for SHPC, not for PCI Express native hot-
>  plug. So pciehp must not evaluate OSHP to take control from firmware.
>
> To confirm this, could you send me the dmesg output after loading pciehp
> with 'debug_acpi' of pci_hotplug (PCI hotplug core driver) enabled?
> For example,
>
>    $ su
>    # echo Y > /sys/module/pci_hotplug/parameters/debug_acpi
>    # modprobe pciehp
>    # dmesg

See below.

> And if it is possible, could you send me DSDT of your platform?

Not sure I can do that, I'll check.

> Anyway, my recommendation is using acpiphp on your environment because
> your firmware didn't grant control over hotplug control through _OSC.
> From the information, acpiphp also detects the hotplug slots successfully.
> Please try "echo 1 > /sys/bus/pci/slots/<slot#>/power". It would turn on
> the slot and initialize adapter card on the slot.

It does find the 4 slots correctly. But if I try to turn on the power,
nothing happens and 'power' stays at 0. If I do the same with pciehp, I
get the same hang as described when using pciehp with pciehp_force=1.
But apparently this machine is getting a board replacement very soon, so
it may solve itself. Unless you think it should work and there's
something I can try to check, then lets just leave this issue until I
get it upgraded and return from kernel summit / JLS.


acpi_pcihp: acpi_get_hp_hw_control_from_firmware: Trying to get hotplug control for \_SB_.IOH0
Firmware did not grant requested _OSC control
acpi_pcihp: acpi_get_hp_hw_control_from_firmware: Trying to get hotplug control for \_SB_.IOH0.MRP5 
acpi_pcihp: acpi_get_hp_hw_control_from_firmware: Gained control for hotplug HW for pci 0000:00:05.0 (\_SB_.IOH0.MRP5)
acpi_pcihp: acpi_get_hp_hw_control_from_firmware: Trying to get hotplug control for \_SB_.IOH0
Firmware did not grant requested _OSC control
acpi_pcihp: acpi_get_hp_hw_control_from_firmware: Trying to get hotplug control for \_SB_.IOH0.MRP7 
acpi_pcihp: acpi_get_hp_hw_control_from_firmware: Gained control for hotplug HW for pci 0000:00:07.0 (\_SB_.IOH0.MRP7)
acpi_pcihp: acpi_get_hp_hw_control_from_firmware: Trying to get hotplug control for \_SB_.IOH0
Firmware did not grant requested _OSC control
acpi_pcihp: acpi_get_hp_hw_control_from_firmware: Trying to get hotplug control for \_SB_.IOH0.PEX0 
acpi_pcihp: acpi_run_oshp: acpi_run_oshp:\_SB_.IOH0.PEX0 OSHP not found
acpi_pcihp: acpi_get_hp_hw_control_from_firmware: Trying to get hotplug control for \_SB_.IOH0 
acpi_pcihp: acpi_run_oshp: acpi_run_oshp:\_SB_.IOH0 OSHP not found
acpi_pcihp: acpi_get_hp_hw_control_from_firmware: Cannot get control of hotplug hardware for pci 0000:00:1c.0
acpi_pcihp: acpi_get_hp_hw_control_from_firmware: Trying to get hotplug control for \_SB_.IOH1
acpi_pcihp: acpi_get_hp_hw_control_from_firmware: Trying to get hotplug control for \_SB_.IOH1.MRPI 
acpi_pcihp: acpi_get_hp_hw_control_from_firmware: Gained control for hotplug HW for pci 0000:80:07.0 (\_SB_.IOH1.MRPI)
acpi_pcihp: acpi_get_hp_hw_control_from_firmware: Trying to get hotplug control for \_SB_.IOH1
acpi_pcihp: acpi_get_hp_hw_control_from_firmware: Trying to get hotplug control for \_SB_.IOH1.MRPK 
acpi_pcihp: acpi_get_hp_hw_control_from_firmware: Gained control for hotplug HW for pci 0000:80:09.0 (\_SB_.IOH1.MRPK)
acpi_pcihp: acpi_get_hp_hw_control_from_firmware: Trying to get hotplug control for \_SB_.IOH0
Firmware did not grant requested _OSC control
acpi_pcihp: acpi_get_hp_hw_control_from_firmware: Trying to get hotplug control for \_SB_.IOH0.MRP5 
acpi_pcihp: acpi_get_hp_hw_control_from_firmware: Gained control for hotplug HW for pci 0000:00:05.0 (\_SB_.IOH0.MRP5)
pciehp 0000:00:05.0:pcie04: HPC vendor_id 8086 device_id 340c ss_vid 0 ss_did 0
pciehp 0000:00:05.0:pcie04: service driver pciehp loaded
acpi_pcihp: acpi_get_hp_hw_control_from_firmware: Trying to get hotplug control for \_SB_.IOH0
Firmware did not grant requested _OSC control
acpi_pcihp: acpi_get_hp_hw_control_from_firmware: Trying to get hotplug control for \_SB_.IOH0.MRP7 
acpi_pcihp: acpi_get_hp_hw_control_from_firmware: Gained control for hotplug HW for pci 0000:00:07.0 (\_SB_.IOH0.MRP7)
pciehp 0000:00:07.0:pcie04: HPC vendor_id 8086 device_id 340e ss_vid 0 ss_did 0
pciehp 0000:00:07.0:pcie04: service driver pciehp loaded
acpi_pcihp: acpi_get_hp_hw_control_from_firmware: Trying to get hotplug control for \_SB_.IOH0
Firmware did not grant requested _OSC control
acpi_pcihp: acpi_get_hp_hw_control_from_firmware: Trying to get hotplug control for \_SB_.IOH0.PEX0 
acpi_pcihp: acpi_run_oshp: acpi_run_oshp:\_SB_.IOH0.PEX0 OSHP not found
acpi_pcihp: acpi_get_hp_hw_control_from_firmware: Trying to get hotplug control for \_SB_.IOH0 
acpi_pcihp: acpi_run_oshp: acpi_run_oshp:\_SB_.IOH0 OSHP not found
acpi_pcihp: acpi_get_hp_hw_control_from_firmware: Cannot get control of hotplug hardware for pci 0000:00:1c.0
acpi_pcihp: acpi_get_hp_hw_control_from_firmware: Trying to get hotplug control for \_SB_.IOH1
acpi_pcihp: acpi_get_hp_hw_control_from_firmware: Trying to get hotplug control for \_SB_.IOH1.MRPI 
acpi_pcihp: acpi_get_hp_hw_control_from_firmware: Gained control for hotplug HW for pci 0000:80:07.0 (\_SB_.IOH1.MRPI)
pciehp 0000:80:07.0:pcie04: HPC vendor_id 8086 device_id 340e ss_vid 0 ss_did 0
pciehp 0000:80:07.0:pcie04: service driver pciehp loaded
acpi_pcihp: acpi_get_hp_hw_control_from_firmware: Trying to get hotplug control for \_SB_.IOH1
acpi_pcihp: acpi_get_hp_hw_control_from_firmware: Trying to get hotplug control for \_SB_.IOH1.MRPK 
acpi_pcihp: acpi_get_hp_hw_control_from_firmware: Gained control for hotplug HW for pci 0000:80:09.0 (\_SB_.IOH1.MRPK)
pciehp 0000:80:09.0:pcie04: HPC vendor_id 8086 device_id 3410 ss_vid 0 ss_did 0
pciehp 0000:80:09.0:pcie04: service driver pciehp loaded
pciehp: PCI Express Hot Plug Controller Driver version: 0.4

-- 
Jens Axboe


  reply	other threads:[~2009-10-13 11:26 UTC|newest]

Thread overview: 40+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-10-12 12:06 pci-express hotplug Jens Axboe
2009-10-12 14:52 ` Greg KH
2009-10-12 14:57   ` Jens Axboe
2009-10-12 15:00     ` Mark Lord
2009-10-12 15:06       ` Jens Axboe
2009-10-12 21:48         ` Alex Chiang
2009-10-13  8:29           ` Jens Axboe
2009-10-13 17:27             ` Alex Chiang
2009-10-14  8:13               ` Jens Axboe
2009-10-20 19:07                 ` Alex Chiang
2009-10-26 10:54                   ` Jens Axboe
2009-10-27  2:48                     ` Alex Chiang
2009-10-27  8:26                       ` Jens Axboe
2009-10-27  8:34                         ` Jens Axboe
2009-10-27 15:15                           ` Alex Chiang
2009-10-28  9:18                             ` Jens Axboe
2009-10-28 19:55                               ` Alex Chiang
2009-10-29 18:55                                 ` Jens Axboe
2009-10-28 20:46                         ` Alex Chiang
2009-10-28 21:39                         ` Alex Chiang
2009-10-29  8:57                           ` Jens Axboe
2009-10-27  6:31                     ` Kenji Kaneshige
2009-10-27  8:27                       ` Jens Axboe
2009-10-27  8:36                         ` Jens Axboe
2009-10-27  8:46                         ` Kenji Kaneshige
2009-10-28  6:15                         ` Kenji Kaneshige
2009-10-28  9:23                           ` Jens Axboe
2009-10-29  7:44                             ` Kenji Kaneshige
2009-10-29  8:58                               ` Jens Axboe
2009-10-29  9:23                                 ` Kenji Kaneshige
2009-10-29  9:24                                   ` Jens Axboe
2009-11-02  5:27                                     ` Kenji Kaneshige
2009-10-13  3:19 ` Kenji Kaneshige
2009-10-13  8:31   ` Jens Axboe
2009-10-13 10:48     ` Kenji Kaneshige
2009-10-13 11:25       ` Jens Axboe [this message]
2009-10-14  5:26         ` Kenji Kaneshige
2009-10-14  8:47           ` Jens Axboe
2009-10-15  5:41             ` Kenji Kaneshige
2009-10-15  9:42               ` Jens Axboe

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=20091013112525.GX9228@kernel.dk \
    --to=jens.axboe@oracle.com \
    --cc=jbarnes@virtuousgeek.org \
    --cc=kaneshige.kenji@jp.fujitsu.com \
    --cc=linux-kernel@vger.kernel.org \
    --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