diff options
author | Andy Shevchenko <andriy.shevchenko@linux.intel.com> | 2023-11-24 22:31:25 +0300 |
---|---|---|
committer | Lee Jones <lee@kernel.org> | 2023-12-07 16:50:29 +0300 |
commit | 9ffe4c1089f6c3097cb9184a36e912e2eeb66f4b (patch) | |
tree | a742a6e2c777a846d66cb0db4f31c805df1f1c24 /drivers/mfd/intel-lpss-pci.c | |
parent | 3b6dba220e67eda42f1263403fbbba64992da3ae (diff) | |
download | linux-9ffe4c1089f6c3097cb9184a36e912e2eeb66f4b.tar.xz |
mfd: intel-lpss: Use device_get_match_data()
Use preferred device_get_match_data() instead of acpi_match_device() to
get the driver match data. With this, adjust the includes to explicitly
include the correct headers.
Introduce a temporary variable in PCI glue driver to be consistent with
ACPI one on the same matter.
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://lore.kernel.org/r/20231124200258.3682979-3-andriy.shevchenko@linux.intel.com
Signed-off-by: Lee Jones <lee@kernel.org>
Diffstat (limited to 'drivers/mfd/intel-lpss-pci.c')
-rw-r--r-- | drivers/mfd/intel-lpss-pci.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/mfd/intel-lpss-pci.c b/drivers/mfd/intel-lpss-pci.c index 709b0fb4419d..94042bfe7dbf 100644 --- a/drivers/mfd/intel-lpss-pci.c +++ b/drivers/mfd/intel-lpss-pci.c @@ -30,6 +30,7 @@ static const struct pci_device_id ignore_resource_conflicts_ids[] = { static int intel_lpss_pci_probe(struct pci_dev *pdev, const struct pci_device_id *id) { + const struct intel_lpss_platform_info *data = (void *)id->driver_data; struct intel_lpss_platform_info *info; int ret; @@ -41,8 +42,7 @@ static int intel_lpss_pci_probe(struct pci_dev *pdev, if (ret) return ret; - info = devm_kmemdup(&pdev->dev, (void *)id->driver_data, sizeof(*info), - GFP_KERNEL); + info = devm_kmemdup(&pdev->dev, data, sizeof(*info), GFP_KERNEL); if (!info) return -ENOMEM; |