forked from ~ljy/RK356X_SDK_RELEASE

hc
2024-01-31 f70575805708cabdedea7498aaa3f710fde4d920
kernel/drivers/phy/hisilicon/phy-histb-combphy.c
....@@ -1,13 +1,10 @@
1
+// SPDX-License-Identifier: GPL-2.0-only
12 /*
23 * COMBPHY driver for HiSilicon STB SoCs
34 *
45 * Copyright (C) 2016-2017 HiSilicon Co., Ltd. http://www.hisilicon.com
56 *
67 * Authors: Jianguo Sun <sunjianguo1@huawei.com>
7
- *
8
- * This program is free software; you can redistribute it and/or modify
9
- * it under the terms of the GNU General Public License version 2 as
10
- * published by the Free Software Foundation.
118 */
129
1310 #include <linux/clk.h>
....@@ -198,7 +195,6 @@
198195 struct histb_combphy_priv *priv;
199196 struct device_node *np = dev->of_node;
200197 struct histb_combphy_mode *mode;
201
- struct resource *res;
202198 u32 vals[3];
203199 int ret;
204200
....@@ -206,8 +202,7 @@
206202 if (!priv)
207203 return -ENOMEM;
208204
209
- res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
210
- priv->mmio = devm_ioremap_resource(dev, res);
205
+ priv->mmio = devm_platform_ioremap_resource(pdev, 0);
211206 if (IS_ERR(priv->mmio)) {
212207 ret = PTR_ERR(priv->mmio);
213208 return ret;