hc
2023-12-11 d2ccde1c8e90d38cee87a1b0309ad2827f3fd30d
kernel/drivers/cpufreq/s3c2410-cpufreq.c
....@@ -1,13 +1,10 @@
1
+// SPDX-License-Identifier: GPL-2.0-only
12 /*
23 * Copyright (c) 2006-2008 Simtec Electronics
34 * http://armlinux.simtec.co.uk/
45 * Ben Dooks <ben@simtec.co.uk>
56 *
67 * S3C2410 CPU Frequency scaling
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/init.h>
....@@ -19,14 +16,14 @@
1916 #include <linux/clk.h>
2017 #include <linux/err.h>
2118 #include <linux/io.h>
19
+#include <linux/soc/samsung/s3c-cpufreq-core.h>
20
+#include <linux/soc/samsung/s3c-pm.h>
2221
2322 #include <asm/mach/arch.h>
2423 #include <asm/mach/map.h>
2524
26
-#include <mach/regs-clock.h>
27
-
28
-#include <plat/cpu.h>
29
-#include <plat/cpu-freq-core.h>
25
+#define S3C2410_CLKDIVN_PDIVN (1<<0)
26
+#define S3C2410_CLKDIVN_HDIVN (1<<1)
3027
3128 /* Note, 2410A has an extra mode for 1:4:4 ratio, bit 2 of CLKDIV */
3229
....@@ -40,7 +37,7 @@
4037 if (cfg->divs.p_divisor != cfg->divs.h_divisor)
4138 clkdiv |= S3C2410_CLKDIVN_PDIVN;
4239
43
- __raw_writel(clkdiv, S3C2410_CLKDIVN);
40
+ s3c24xx_write_clkdivn(clkdiv);
4441 }
4542
4643 static int s3c2410_cpufreq_calcdivs(struct s3c_cpufreq_config *cfg)