lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <569F9CB4.2010905@semihalf.com>
Date:	Wed, 20 Jan 2016 15:41:56 +0100
From:	Tomasz Nowicki <tn@...ihalf.com>
To:	Lorenzo Pieralisi <lorenzo.pieralisi@....com>, rjw@...ysocki.net
Cc:	bhelgaas@...gle.com, arnd@...db.de, will.deacon@....com,
	catalin.marinas@....com, hanjun.guo@...aro.org,
	okaya@...eaurora.org, jiang.liu@...ux.intel.com,
	Stefano.Stabellini@...citrix.com,
	robert.richter@...iumnetworks.com, mw@...ihalf.com,
	Liviu.Dudau@....com, ddaney@...iumnetworks.com, tglx@...utronix.de,
	wangyijing@...wei.com, Suravee.Suthikulpanit@....com,
	msalter@...hat.com, linux-pci@...r.kernel.org,
	linux-arm-kernel@...ts.infradead.org, linux-acpi@...r.kernel.org,
	linux-kernel@...r.kernel.org, linaro-acpi@...ts.linaro.org,
	jchandra@...adcom.com, jcm@...hat.com
Subject: Re: [PATCH V3 11/21] pci, acpi: Move ACPI host bridge device
 companion assignment to core code.

On 20.01.2016 15:22, Lorenzo Pieralisi wrote:
> On Wed, Jan 20, 2016 at 02:40:08PM +0100, Tomasz Nowicki wrote:
>
> [...]
>
>>>>>> +	/* Root bridge device needs to be sure of parent ACPI type */
>>>>>> +	ACPI_COMPANION_SET(&device->dev, device);
>>>>>
>>>>> I do not understand why the code above is needed, can you elaborate
>>>>> please ?
>>>>>
>>>>
>>>> This makes sure that device->dev can be identified as ACPI device,
>>>> so we can use to_acpi_device_node() and assign companion safely
>>>> below.
>>>
>>> I do not follow. If you refer to the fwnode handle type, that is
>>> already set by ACPI core code (before acpi_pci_root_add() is called,
>>> in acpi_init_device_object()).
>>
>> acpi_init_device_object() sets ACPI fwnode handle type only for
>> "device", but not for "device->dev" which is what is passed as an
>> argument to pci_create_root_bus().
>>
>> Without ACPI_COMPANION_SET(&device->dev, device) here, no one can be
>> sure if we have ACPI device in pci_create_root_bus().
>
> Ok, got it. The question is whether this should be done in ACPI
> core instead (is there a reason why it should *not* be done ?), but I
> now understand your point.
>

I am not able to answer that question, but I see lots of changes in this 
area made by Rafael.

Rafael, can you please shed some light on this?

Thanks,
Tomasz

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ