hc
2024-02-20 102a0743326a03cd1a1202ceda21e175b7d3575c
kernel/drivers/rtc/rtc-ds1216.c
....@@ -1,3 +1,4 @@
1
+// SPDX-License-Identifier: GPL-2.0-only
12 /*
23 * Dallas DS1216 RTC driver
34 *
....@@ -136,7 +137,6 @@
136137
137138 static int __init ds1216_rtc_probe(struct platform_device *pdev)
138139 {
139
- struct resource *res;
140140 struct ds1216_priv *priv;
141141 u8 dummy[8];
142142
....@@ -146,8 +146,7 @@
146146
147147 platform_set_drvdata(pdev, priv);
148148
149
- res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
150
- priv->ioaddr = devm_ioremap_resource(&pdev->dev, res);
149
+ priv->ioaddr = devm_platform_ioremap_resource(pdev, 0);
151150 if (IS_ERR(priv->ioaddr))
152151 return PTR_ERR(priv->ioaddr);
153152