diff options
Diffstat (limited to 'drivers/net/wireless/intel/iwlwifi/fw/acpi.c')
-rw-r--r-- | drivers/net/wireless/intel/iwlwifi/fw/acpi.c | 28 |
1 files changed, 19 insertions, 9 deletions
diff --git a/drivers/net/wireless/intel/iwlwifi/fw/acpi.c b/drivers/net/wireless/intel/iwlwifi/fw/acpi.c index 6aa0dbfa3b6c..82a4f7e8ba54 100644 --- a/drivers/net/wireless/intel/iwlwifi/fw/acpi.c +++ b/drivers/net/wireless/intel/iwlwifi/fw/acpi.c @@ -9,9 +9,15 @@ #include "acpi.h" #include "fw/runtime.h" -static const guid_t intel_wifi_guid = GUID_INIT(0xF21202BF, 0x8F78, 0x4DC6, - 0xA5, 0xB3, 0x1F, 0x73, - 0x8E, 0x28, 0x5A, 0xDE); +const guid_t iwl_guid = GUID_INIT(0xF21202BF, 0x8F78, 0x4DC6, + 0xA5, 0xB3, 0x1F, 0x73, + 0x8E, 0x28, 0x5A, 0xDE); +IWL_EXPORT_SYMBOL(iwl_guid); + +const guid_t iwl_rfi_guid = GUID_INIT(0x7266172C, 0x220B, 0x4B29, + 0x81, 0x4F, 0x75, 0xE4, + 0xDD, 0x26, 0xB5, 0xFD); +IWL_EXPORT_SYMBOL(iwl_rfi_guid); static int iwl_acpi_get_handle(struct device *dev, acpi_string method, acpi_handle *ret_handle) @@ -64,11 +70,12 @@ IWL_EXPORT_SYMBOL(iwl_acpi_get_object); * function. */ static void *iwl_acpi_get_dsm_object(struct device *dev, int rev, int func, - union acpi_object *args) + union acpi_object *args, + const guid_t *guid) { union acpi_object *obj; - obj = acpi_evaluate_dsm(ACPI_HANDLE(dev), &intel_wifi_guid, rev, func, + obj = acpi_evaluate_dsm(ACPI_HANDLE(dev), guid, rev, func, args); if (!obj) { IWL_DEBUG_DEV_RADIO(dev, @@ -87,12 +94,13 @@ static void *iwl_acpi_get_dsm_object(struct device *dev, int rev, int func, * return 0 in success and the appropriate errno otherwise. */ static int iwl_acpi_get_dsm_integer(struct device *dev, int rev, int func, - u64 *value, size_t expected_size) + const guid_t *guid, u64 *value, + size_t expected_size) { union acpi_object *obj; int ret = 0; - obj = iwl_acpi_get_dsm_object(dev, rev, func, NULL); + obj = iwl_acpi_get_dsm_object(dev, rev, func, NULL, guid); if (IS_ERR(obj)) { IWL_DEBUG_DEV_RADIO(dev, "Failed to get DSM object. func= %d\n", @@ -137,12 +145,14 @@ out: /* * Evaluate a DSM with no arguments and a u8 return value, */ -int iwl_acpi_get_dsm_u8(struct device *dev, int rev, int func, u8 *value) +int iwl_acpi_get_dsm_u8(struct device *dev, int rev, int func, + const guid_t *guid, u8 *value) { int ret; u64 val; - ret = iwl_acpi_get_dsm_integer(dev, rev, func, &val, sizeof(u8)); + ret = iwl_acpi_get_dsm_integer(dev, rev, func, + guid, &val, sizeof(u8)); if (ret < 0) return ret; |