• Andy Lutomirski's avatar
    platform/x86: wmi: Track wmi devices per ACPI device · b0e86302
    Andy Lutomirski authored
    Currently we free all devices when we detach from any ACPI node.
    Instead, keep track of which node WMI devices are attached to and
    free them only as needed. While we are at it, match up notifications
    with the device they came from correctly.
    This will make our behavior more straightforward on systems with
    more than one WMI node in the ACPI tables (e.g. the Dell XPS 13
    This also adds a warning when GUIDs are not unique.
    NB: The guid_string parameter in guid_already_parsed was a
    little-endian binary GUID, not a string.
    Signed-off-by: default avatarAndy Lutomirski <luto@kernel.org>
    Cc: Andy Lutomirski <luto@amacapital.net>
    Cc: Mario Limonciello <mario_limonciello@dell.com>
    Cc: Pali Rohár <pali.rohar@gmail.com>
    Cc: linux-kernel@vger.kernel.org
    Cc: platform-driver-x86@vger.kernel.org
    Cc: linux-acpi@vger.kernel.org
    Acked-by: default avatarRafael J. Wysocki <rafael.j.wysocki@intel.com>
    Signed-off-by: default avatarDarren Hart (VMware) <dvhart@infradead.org>