Bug 7145 - Incorrect handling PCI-Express Root Bridge _HID
Summary: Incorrect handling PCI-Express Root Bridge _HID
Status: CLOSED CODE_FIX
Alias: None
Product: ACPI
Classification: Unclassified
Component: Config-Tables (show other bugs)
Hardware: i386 Linux
: P2 high
Assignee: Robert Moore
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-09-11 02:49 UTC by Eiichiro Oiwa
Modified: 2007-01-04 10:44 UTC (History)
1 user (show)

See Also:
Kernel Version: 2.6.17.13
Subsystem:
Regression: ---
Bisected commit-id:


Attachments

Description Eiichiro Oiwa 2006-09-11 02:49:09 UTC
Most recent kernel where this bug did not occur:
 In most recent kernel, this bug occurs.

Hardware Environment:

PCI Bus Topology:

[CPU] [CPU]        [CPU]  [CPU]
  |      |BUS        |     |   BUS
--+--+---+---      --+--+--+------   
     |                  |
 [Root Bridge]*1-----[Root Bridge]*1
     |      |           \        \
 [Bridge]   |        [PCI-e slot] [PCI-e slot]
    | |    [PCI-e slot]
    | \
    | [PCI-e slot]
    |  
    |            
 [PCI Bridge]
    |     \
    |      [PCI-X slot]
    |
 [PCI-X slot]

*1: PCI Express Root Bridge.

Problem Description:
 I could not get correct PCI Express BUS number from the structure of
acpi_object_extra. I always get zero as BUS number regardless of BUS location. I
found that there is incorrect comparison with _HID (PNP0A08) in
acpi/events/evrgnini.c and PCI Express _BBN method always fail. Therefore, we
get always get zero as PCI Express bus number.

I suggest the following patch.
--- linux-2.6.17.13.org/drivers/acpi/events/evrgnini.c  2006-09-09
12:23:25.000000000 +0900
+++ linux-2.6.17.13/drivers/acpi/events/evrgnini.c      2006-09-11
11:34:16.625000000 +0900
@@ -213,12 +213,12 @@ acpi_ev_pci_config_region_setup(acpi_han
                                if (!
                                    (ACPI_STRNCMP
                                     (object_hID.value, PCI_ROOT_HID_STRING,
-                                     sizeof(PCI_ROOT_HID_STRING))
+                                     sizeof(PCI_ROOT_HID_STRING)))
                                     ||
                                     !(ACPI_STRNCMP
                                       (object_hID.value,
                                        PCI_EXPRESS_ROOT_HID_STRING,
-                                       sizeof(PCI_EXPRESS_ROOT_HID_STRING)))))
+                                       sizeof(PCI_EXPRESS_ROOT_HID_STRING))))
                                {
                                        /* Install a handler for this PCI root
bridge */
Comment 1 Robert Moore 2006-09-11 11:45:31 UTC
Your patch looks correct and will be integrated into the next release of 
ACPICA.
Comment 2 Eiichiro Oiwa 2006-09-12 02:35:51 UTC
It is good. Thank you.
Comment 3 Robert Moore 2006-09-12 14:13:04 UTC
Integrated and released in ACPICA version 20060912
Comment 4 Eiichiro Oiwa 2006-09-12 19:17:29 UTC
Thank you.
Comment 5 Len Brown 2007-01-04 10:44:52 UTC
this patch shipped in Linux-2.6.19.
closed.

Note You need to log in before you can comment on or make changes to this bug.