watchdog: intel-mid_wdt: Get platform data via dev_get_platdata()

Access to platform data via dev_get_platdata() getter to make code cleaner.

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Reviewed-by: Guenter Roeck <linux@roeck-us.net>
Link: https://lore.kernel.org/r/20240305165306.1366823-4-andriy.shevchenko@linux.intel.com
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Signed-off-by: Wim Van Sebroeck <wim@linux-watchdog.org>
This commit is contained in:
Andy Shevchenko 2024-03-05 18:52:20 +02:00 committed by Wim Van Sebroeck
parent e295eb8235
commit 6fe5aabf7f

View File

@ -127,7 +127,7 @@ static int mid_wdt_probe(struct platform_device *pdev)
{
struct device *dev = &pdev->dev;
struct watchdog_device *wdt_dev;
struct intel_mid_wdt_pdata *pdata = dev->platform_data;
struct intel_mid_wdt_pdata *pdata = dev_get_platdata(dev);
struct mid_wdt *mid;
int ret;