lkml.org 
[lkml]   [2015]   [Apr]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [Update][PATCH] ACPI / scan: Add a scan handler for PRP0001
On Fri, Apr 24, 2015 at 02:15:22AM +0200, Rafael Wysocki wrote:
> From: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
>
> If the special PRP0001 device ID is present in the given device's list
> of ACPI/PNP IDs and the device has a valid "compatible" property in
> the _DSD, it should be enumerated using the default mechanism,
> unless some scan handlers match the IDs preceding PRP0001 in the
> device's list of ACPI/PNP IDs. In addition to that, no scan handlers
> matching the IDs following PRP0001 in that list should be attached
> to the device.
>
> To make that happen, define a scan handler that will match PRP0001
> and trigger the default enumeration for the matching devices if the
> "compatible" property is present for them.
>
> Since that requires the check for platform_id and device->handler
> to be removed from acpi_default_enumeration(), move the fallback
> invocation of acpi_default_enumeration() to acpi_bus_attach()
> (after it's checked if there's a matching ACPI driver for the
> device), which is a better place to call it, and do the platform_id
> check in there too (device->handler is guaranteed to be unset at
> the point where the function is looking for a matching ACPI driver).
>
> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
> Acked-by: Darren Hart <dvhart@linux.intel.com>
> ---
>
> The change from the original patch is to change the scan handler
> behavior to make it return 1 also if the "compatible" property is
> not present, in which case the additional scan handlers should not
> trigger too *and* the default enumeration should not trigger either
> (as there's no ID to match to), which will allow things like
> auxiliary nodes (think GPIO buttons/LEDs etc) to be easily represented.


This should probably be spelled out in the commit message itself as it's a fairly
unique condition.


> Darren, I've tentatively added your Acked-by tag to this one, please
> let me know if that's not appropriate.

Spent a bit more time on it this time, so:

Reviewed-by: Darren Hart <dvhart@linux.intel.com>

Thanks,

--
Darren Hart
Intel Open Source Technology Center


\
 
 \ /
  Last update: 2015-04-25 01:01    [W:0.083 / U:1.168 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site