forked from ~ljy/RK356X_SDK_RELEASE

hc
2024-05-10 9999e48639b3cecb08ffb37358bcba3b48161b29
kernel/arch/arm/mach-imx/mach-imx7d.c
....@@ -1,9 +1,6 @@
1
+// SPDX-License-Identifier: GPL-2.0-only
12 /*
23 * Copyright (C) 2015 Freescale Semiconductor, Inc.
3
- *
4
- * This program is free software; you can redistribute it and/or modify
5
- * it under the terms of the GNU General Public License version 2 as
6
- * published by the Free Software Foundation.
74 */
85 #include <linux/irqchip.h>
96 #include <linux/mfd/syscon.h>
....@@ -32,12 +29,6 @@
3229 val = phy_read(dev, 0xe);
3330 val &= ~(0x1 << 8);
3431 phy_write(dev, 0xe, val);
35
-
36
- /* introduce tx clock delay */
37
- phy_write(dev, 0x1d, 0x5);
38
- val = phy_read(dev, 0x1e);
39
- val |= 0x0100;
40
- phy_write(dev, 0x1e, val);
4132
4233 return 0;
4334 }
....@@ -87,14 +78,14 @@
8778
8879 static void __init imx7d_init_machine(void)
8980 {
90
- struct device *parent;
91
-
92
- parent = imx_soc_device_init();
93
- if (parent == NULL)
94
- pr_warn("failed to initialize soc device\n");
95
-
9681 imx_anatop_init();
9782 imx7d_enet_init();
83
+}
84
+
85
+static void __init imx7d_init_late(void)
86
+{
87
+ if (IS_ENABLED(CONFIG_ARM_IMX_CPUFREQ_DT))
88
+ platform_device_register_simple("imx-cpufreq-dt", -1, NULL, 0);
9889 }
9990
10091 static void __init imx7d_init_irq(void)
....@@ -113,5 +104,6 @@
113104 DT_MACHINE_START(IMX7D, "Freescale i.MX7 Dual (Device Tree)")
114105 .init_irq = imx7d_init_irq,
115106 .init_machine = imx7d_init_machine,
107
+ .init_late = imx7d_init_late,
116108 .dt_compat = imx7d_dt_compat,
117109 MACHINE_END