Re: [PATCH 12/24] PCI, ia64: Register busn_res for root buses

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Feb 28, 2012 at 5:12 PM, Yinghai Lu <yinghai@xxxxxxxxxx> wrote:
> On Tue, Feb 28, 2012 at 4:01 PM, Bjorn Helgaas <bhelgaas@xxxxxxxxxx> wrote:
>> On Tue, Feb 28, 2012 at 3:07 PM, Yinghai Lu <yinghai@xxxxxxxxxx> wrote:
>>> Signed-off-by: Yinghai Lu <yinghai@xxxxxxxxxx>
>>> Cc: Tony Luck <tony.luck@xxxxxxxxx>
>>> Cc: Fenghua Yu <fenghua.yu@xxxxxxxxx>
>>> Cc: linux-ia64@xxxxxxxxxxxxxxx
>>> ---
>>>  arch/ia64/include/asm/pci.h |    1 +
>>>  arch/ia64/pci/pci.c         |    5 +++++
>>>  2 files changed, 6 insertions(+), 0 deletions(-)
>>>
>>> diff --git a/arch/ia64/include/asm/pci.h b/arch/ia64/include/asm/pci.h
>>> index b22e5f5..6e54220 100644
>>> --- a/arch/ia64/include/asm/pci.h
>>> +++ b/arch/ia64/include/asm/pci.h
>>> @@ -94,6 +94,7 @@ struct pci_controller {
>>>
>>>        unsigned int windows;
>>>        struct pci_window *window;
>>> +       struct resource busn;
>>
>> Why do you add a new struct resource here?  Can't you just use the one
>> passed in from acpi_pci_root_add()?
>
> not quite sure about the life cycle for that object.

The struct acpi_pci_root is allocated in acpi_pci_root_add() and freed
in acpi_pci_root_remove(), so it should be safe for PCI to use.

Same thing applies for x86, of course.

Bjorn
--
To unsubscribe from this list: send the line "unsubscribe linux-pci" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [DMA Engine]     [Linux Coverity]     [Linux USB]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Greybus]

  Powered by Linux