unicore32: pwm: Properly remap memory-mapped registers
authorThierry Reding <thierry.reding@avionic-design.de>
Fri, 14 Sep 2012 08:14:25 +0000 (16:14 +0800)
committerThierry Reding <thierry.reding@avionic-design.de>
Fri, 5 Oct 2012 18:56:39 +0000 (20:56 +0200)
commitd1b6886502160eb771aefe21c1f891597138ddfe
treeeee4f1aade9c3b34878ba849301a196532a9fdd0
parent60ce70285b4d3b933eea15e494a9b35fe85b19b7
unicore32: pwm: Properly remap memory-mapped registers

Instead of writing to the timer controller registers by dereferencing a
pointer to the memory location, properly remap the memory region with a
call to ioremap_nocache() and access the registers using writel().

Signed-off-by: Thierry Reding <thierry.reding@avionic-design.de>
Signed-off-by: Guan Xuetao <gxt@mprc.pku.edu.cn>
Tested-by: Qin Rui <qinrui@mprc.pku.edu.cn>
arch/unicore32/include/mach/regs-ost.h
arch/unicore32/kernel/pwm.c