Merge branches 'acpi-utils', 'acpi-video', 'acpi-soc' and 'acpi-button'
* acpi-utils: gpio: merrifield: Fix build err without CONFIG_ACPI ACPI / utils: Remove deprecated function since no user left ASoC: Intel: cht_bsw_rt5672: Convert to use acpi_dev_get_first_match_dev() ASoC: Intel: cht_bsw_rt5645: Convert to use acpi_dev_get_first_match_dev() ASoC: Intel: bytcr_rt5651: Convert to use acpi_dev_get_first_match_dev() ASoC: Intel: bytcr_rt5640: Convert to use acpi_dev_get_first_match_dev() ASoC: Intel: bytcht_es8316: Convert to use acpi_dev_get_first_match_dev() ASoC: Intel: bytcht_da7213: Convert to use acpi_dev_get_first_match_dev() gpio: merrifield: Convert to use acpi_dev_get_first_match_dev() extcon: axp288: Convert to use acpi_dev_get_first_match_dev() ACPI / utils: Introduce acpi_dev_get_first_match_dev() helper * acpi-video: ACPI: video: Use vendor backlight on Sony VPCEH3U1E * acpi-soc: ACPI / LPSS: Use acpi_lpss_* instead of acpi_subsys_* functions for hibernate * acpi-button: ACPI: button: reinitialize button state upon resume
This commit is contained in:
@ -1142,8 +1142,8 @@ static struct dev_pm_domain acpi_lpss_pm_domain = {
|
||||
.thaw_noirq = acpi_subsys_thaw_noirq,
|
||||
.poweroff = acpi_subsys_suspend,
|
||||
.poweroff_late = acpi_lpss_suspend_late,
|
||||
.poweroff_noirq = acpi_subsys_suspend_noirq,
|
||||
.restore_noirq = acpi_subsys_resume_noirq,
|
||||
.poweroff_noirq = acpi_lpss_suspend_noirq,
|
||||
.restore_noirq = acpi_lpss_resume_noirq,
|
||||
.restore_early = acpi_lpss_resume_early,
|
||||
#endif
|
||||
.runtime_suspend = acpi_lpss_runtime_suspend,
|
||||
|
@ -456,8 +456,11 @@ static int acpi_button_resume(struct device *dev)
|
||||
struct acpi_button *button = acpi_driver_data(device);
|
||||
|
||||
button->suspended = false;
|
||||
if (button->type == ACPI_BUTTON_TYPE_LID && button->input->users)
|
||||
if (button->type == ACPI_BUTTON_TYPE_LID && button->input->users) {
|
||||
button->last_state = !!acpi_lid_evaluate_state(device);
|
||||
button->last_time = ktime_get();
|
||||
acpi_lid_initialize_state(device);
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
#endif
|
||||
|
@ -739,6 +739,7 @@ EXPORT_SYMBOL(acpi_dev_found);
|
||||
|
||||
struct acpi_dev_match_info {
|
||||
const char *dev_name;
|
||||
struct acpi_device *adev;
|
||||
struct acpi_device_id hid[2];
|
||||
const char *uid;
|
||||
s64 hrv;
|
||||
@ -759,6 +760,7 @@ static int acpi_dev_match_cb(struct device *dev, void *data)
|
||||
return 0;
|
||||
|
||||
match->dev_name = acpi_dev_name(adev);
|
||||
match->adev = adev;
|
||||
|
||||
if (match->hrv == -1)
|
||||
return 1;
|
||||
@ -806,18 +808,20 @@ bool acpi_dev_present(const char *hid, const char *uid, s64 hrv)
|
||||
EXPORT_SYMBOL(acpi_dev_present);
|
||||
|
||||
/**
|
||||
* acpi_dev_get_first_match_name - Return name of first match of ACPI device
|
||||
* acpi_dev_get_first_match_dev - Return the first match of ACPI device
|
||||
* @hid: Hardware ID of the device.
|
||||
* @uid: Unique ID of the device, pass NULL to not check _UID
|
||||
* @hrv: Hardware Revision of the device, pass -1 to not check _HRV
|
||||
*
|
||||
* Return device name if a matching device was present
|
||||
* Return the first match of ACPI device if a matching device was present
|
||||
* at the moment of invocation, or NULL otherwise.
|
||||
*
|
||||
* The caller is responsible to call put_device() on the returned device.
|
||||
*
|
||||
* See additional information in acpi_dev_present() as well.
|
||||
*/
|
||||
const char *
|
||||
acpi_dev_get_first_match_name(const char *hid, const char *uid, s64 hrv)
|
||||
struct acpi_device *
|
||||
acpi_dev_get_first_match_dev(const char *hid, const char *uid, s64 hrv)
|
||||
{
|
||||
struct acpi_dev_match_info match = {};
|
||||
struct device *dev;
|
||||
@ -827,9 +831,9 @@ acpi_dev_get_first_match_name(const char *hid, const char *uid, s64 hrv)
|
||||
match.hrv = hrv;
|
||||
|
||||
dev = bus_find_device(&acpi_bus_type, NULL, &match, acpi_dev_match_cb);
|
||||
return dev ? match.dev_name : NULL;
|
||||
return dev ? match.adev : NULL;
|
||||
}
|
||||
EXPORT_SYMBOL(acpi_dev_get_first_match_name);
|
||||
EXPORT_SYMBOL(acpi_dev_get_first_match_dev);
|
||||
|
||||
/*
|
||||
* acpi_backlight= handling, this is done here rather then in video_detect.c
|
||||
|
@ -141,6 +141,14 @@ static const struct dmi_system_id video_detect_dmi_table[] = {
|
||||
DMI_MATCH(DMI_PRODUCT_NAME, "UL30A"),
|
||||
},
|
||||
},
|
||||
{
|
||||
.callback = video_detect_force_vendor,
|
||||
.ident = "Sony VPCEH3U1E",
|
||||
.matches = {
|
||||
DMI_MATCH(DMI_SYS_VENDOR, "Sony Corporation"),
|
||||
DMI_MATCH(DMI_PRODUCT_NAME, "VPCEH3U1E"),
|
||||
},
|
||||
},
|
||||
|
||||
/*
|
||||
* These models have a working acpi_video backlight control, and using
|
||||
|
Reference in New Issue
Block a user