Hi,

Rob Herring <[email protected]> writes:
> On Thu, Apr 21, 2016 at 6:20 AM, Felipe Balbi
> <[email protected]> wrote:
>>
>> Hi,
>>
>> Heikki Krogerus <[email protected]> writes:
>>> @@ -197,7 +196,7 @@ static int xhci_plat_probe(struct platform_device *pdev)
>>>       }
>>>
>>>       xhci = hcd_to_xhci(hcd);
>>> -     match = of_match_node(usb_xhci_of_match, node);
>>> +     match = of_match_node(usb_xhci_of_match, pdev->dev.of_node);
>>
>> Rob, it's weird that OF-based drivers have to redo the same matching
>> which was already done by drivers/base/platform.c::platform_match() just
>> to get match->data. If we know we matched, couldn't we just cache a
>> pointer to match->data in struct device_node.data ? Something like
>> below? (completely untested)
>
> Yes, it is. AIUI, there is some sort of race condition in doing what
> you suggest though. IIRC, Grant did that and reverted it if you look
> at the git history.

looking at drivers/base/platform.c I can't find anything along these
lines. Adding Grant.

Grant, any memory left of this race ?

-- 
balbi

Attachment: signature.asc
Description: PGP signature

Reply via email to