sh: Mass ctrl_in/outX to __raw_read/writeX conversion.
The old ctrl in/out routines are non-portable and unsuitable for cross-platform use. While drivers/sh has already been sanitized, there is still quite a lot of code that is not. This converts the arch/sh/ bits over, which permits us to flag the routines as deprecated whilst still building with -Werror for the architecture code, and to ensure that future users are not added. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
This commit is contained in:
@@ -35,7 +35,7 @@ static struct clk_ops sh7757_master_clk_ops = {
|
||||
|
||||
static void module_clk_recalc(struct clk *clk)
|
||||
{
|
||||
int idx = ctrl_inl(FRQCR) & 0x0000000f;
|
||||
int idx = __raw_readl(FRQCR) & 0x0000000f;
|
||||
clk->rate = clk->parent->rate / p1fc_divisors[idx];
|
||||
}
|
||||
|
||||
@@ -45,7 +45,7 @@ static struct clk_ops sh7757_module_clk_ops = {
|
||||
|
||||
static void bus_clk_recalc(struct clk *clk)
|
||||
{
|
||||
int idx = (ctrl_inl(FRQCR) >> 8) & 0x0000000f;
|
||||
int idx = (__raw_readl(FRQCR) >> 8) & 0x0000000f;
|
||||
clk->rate = clk->parent->rate / bfc_divisors[idx];
|
||||
}
|
||||
|
||||
@@ -55,7 +55,7 @@ static struct clk_ops sh7757_bus_clk_ops = {
|
||||
|
||||
static void cpu_clk_recalc(struct clk *clk)
|
||||
{
|
||||
int idx = (ctrl_inl(FRQCR) >> 20) & 0x0000000f;
|
||||
int idx = (__raw_readl(FRQCR) >> 20) & 0x0000000f;
|
||||
clk->rate = clk->parent->rate / ifc_divisors[idx];
|
||||
}
|
||||
|
||||
@@ -78,7 +78,7 @@ void __init arch_init_clk_ops(struct clk_ops **ops, int idx)
|
||||
|
||||
static void shyway_clk_recalc(struct clk *clk)
|
||||
{
|
||||
int idx = (ctrl_inl(FRQCR) >> 12) & 0x0000000f;
|
||||
int idx = (__raw_readl(FRQCR) >> 12) & 0x0000000f;
|
||||
clk->rate = clk->parent->rate / sfc_divisors[idx];
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user