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>
Этот коммит содержится в:
@@ -24,7 +24,7 @@ static unsigned long cprc_base;
|
||||
|
||||
static void master_clk_init(struct clk *clk)
|
||||
{
|
||||
int idx = (ctrl_inl(cprc_base + 0x00) >> 6) & 0x0007;
|
||||
int idx = (__raw_readl(cprc_base + 0x00) >> 6) & 0x0007;
|
||||
clk->rate *= ifc_table[idx];
|
||||
}
|
||||
|
||||
@@ -34,7 +34,7 @@ static struct clk_ops sh5_master_clk_ops = {
|
||||
|
||||
static unsigned long module_clk_recalc(struct clk *clk)
|
||||
{
|
||||
int idx = (ctrl_inw(cprc_base) >> 12) & 0x0007;
|
||||
int idx = (__raw_readw(cprc_base) >> 12) & 0x0007;
|
||||
return clk->parent->rate / ifc_table[idx];
|
||||
}
|
||||
|
||||
@@ -44,7 +44,7 @@ static struct clk_ops sh5_module_clk_ops = {
|
||||
|
||||
static unsigned long bus_clk_recalc(struct clk *clk)
|
||||
{
|
||||
int idx = (ctrl_inw(cprc_base) >> 3) & 0x0007;
|
||||
int idx = (__raw_readw(cprc_base) >> 3) & 0x0007;
|
||||
return clk->parent->rate / ifc_table[idx];
|
||||
}
|
||||
|
||||
@@ -54,7 +54,7 @@ static struct clk_ops sh5_bus_clk_ops = {
|
||||
|
||||
static unsigned long cpu_clk_recalc(struct clk *clk)
|
||||
{
|
||||
int idx = (ctrl_inw(cprc_base) & 0x0007);
|
||||
int idx = (__raw_readw(cprc_base) & 0x0007);
|
||||
return clk->parent->rate / ifc_table[idx];
|
||||
}
|
||||
|
||||
|
Ссылка в новой задаче
Block a user