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>
此提交包含在:
@@ -134,8 +134,8 @@ static int sh4202_read_vcr(unsigned long base, struct superhyway_vcr_info *vcr)
|
||||
*
|
||||
* Do not trust the documentation, for it is evil.
|
||||
*/
|
||||
vcrh = ctrl_inl(base);
|
||||
vcrl = ctrl_inl(base + sizeof(u32));
|
||||
vcrh = __raw_readl(base);
|
||||
vcrl = __raw_readl(base + sizeof(u32));
|
||||
|
||||
tmp = ((u64)vcrh << 32) | vcrl;
|
||||
memcpy(vcr, &tmp, sizeof(u64));
|
||||
@@ -147,8 +147,8 @@ static int sh4202_write_vcr(unsigned long base, struct superhyway_vcr_info vcr)
|
||||
{
|
||||
u64 tmp = *(u64 *)&vcr;
|
||||
|
||||
ctrl_outl((tmp >> 32) & 0xffffffff, base);
|
||||
ctrl_outl(tmp & 0xffffffff, base + sizeof(u32));
|
||||
__raw_writel((tmp >> 32) & 0xffffffff, base);
|
||||
__raw_writel(tmp & 0xffffffff, base + sizeof(u32));
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
新增問題並參考
封鎖使用者