aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-prima2
diff options
context:
space:
mode:
authorXianglong Du <Xianglong.Du@csr.com>2014-05-07 03:08:21 -0400
committerBarry Song <Baohua.Song@csr.com>2014-05-12 09:43:48 -0400
commita2a2568311e2207d0c8874e28f578c0bbe3c63b3 (patch)
tree031fad764afb96107c132b023995958f27058038 /arch/arm/mach-prima2
parentd1db0eea852497762cab43b905b879dfcd3b8987 (diff)
ARM: prima2: rstc: fix some minor checkpatch issues
this patch fixes the below minor issues: WARNING: line over 80 characters 39: FILE: arch/arm/mach-prima2/rstc.c:39: + * Writing 1 to this bit resets corresponding block. Writing 0 to this WARNING: line over 80 characters 41: FILE: arch/arm/mach-prima2/rstc.c:41: + * datasheet doesn't require explicit delay between the set and clear WARNING: line over 80 characters 44: FILE: arch/arm/mach-prima2/rstc.c:44: + writel(readl(sirfsoc_rstc_base + (reset_bit / 32) * 4) | (1 << reset_bit), WARNING: msleep < 20ms can sleep for up to 20ms; see Documentation/timers/timers-howto.txt 46: FILE: arch/arm/mach-prima2/rstc.c:46: + msleep(10); WARNING: line over 80 characters 47: FILE: arch/arm/mach-prima2/rstc.c:47: + writel(readl(sirfsoc_rstc_base + (reset_bit / 32) * 4) & ~(1 << reset_bit), WARNING: line over 80 characters 52: FILE: arch/arm/mach-prima2/rstc.c:52: + * Writing 1 to SET register resets corresponding block. Writing 1 to CLEAR WARNING: line over 80 characters 54: FILE: arch/arm/mach-prima2/rstc.c:54: + * datasheet doesn't require explicit delay between the set and clear WARNING: line over 80 characters 57: FILE: arch/arm/mach-prima2/rstc.c:57: + writel(1 << reset_bit, sirfsoc_rstc_base + (reset_bit / 32) * 8); WARNING: msleep < 20ms can sleep for up to 20ms; see Documentation/timers/timers-howto.txt 58: FILE: arch/arm/mach-prima2/rstc.c:58: + msleep(10); WARNING: line over 80 characters 59: FILE: arch/arm/mach-prima2/rstc.c:59: + writel(1 << reset_bit, sirfsoc_rstc_base + (reset_bit / 32) * 8 + 4); total: 0 errors, 10 warnings, 120 lines checked Signed-off-by: Xianglong Du <Xianglong.Du@csr.com> Signed-off-by: Barry Song <Baohua.Song@csr.com>
Diffstat (limited to 'arch/arm/mach-prima2')
-rw-r--r--arch/arm/mach-prima2/rstc.c34
1 files changed, 20 insertions, 14 deletions
diff --git a/arch/arm/mach-prima2/rstc.c b/arch/arm/mach-prima2/rstc.c
index 4887a2a4c698..3dffcb2d714e 100644
--- a/arch/arm/mach-prima2/rstc.c
+++ b/arch/arm/mach-prima2/rstc.c
@@ -36,27 +36,33 @@ static int sirfsoc_reset_module(struct reset_controller_dev *rcdev,
36 36
37 if (of_device_is_compatible(rcdev->of_node, "sirf,prima2-rstc")) { 37 if (of_device_is_compatible(rcdev->of_node, "sirf,prima2-rstc")) {
38 /* 38 /*
39 * Writing 1 to this bit resets corresponding block. Writing 0 to this 39 * Writing 1 to this bit resets corresponding block.
40 * bit de-asserts reset signal of the corresponding block. 40 * Writing 0 to this bit de-asserts reset signal of the
41 * datasheet doesn't require explicit delay between the set and clear 41 * corresponding block. datasheet doesn't require explicit
42 * of reset bit. it could be shorter if tests pass. 42 * delay between the set and clear of reset bit. it could
43 * be shorter if tests pass.
43 */ 44 */
44 writel(readl(sirfsoc_rstc_base + (reset_bit / 32) * 4) | (1 << reset_bit), 45 writel(readl(sirfsoc_rstc_base +
46 (reset_bit / 32) * 4) | (1 << reset_bit),
45 sirfsoc_rstc_base + (reset_bit / 32) * 4); 47 sirfsoc_rstc_base + (reset_bit / 32) * 4);
46 msleep(10); 48 msleep(20);
47 writel(readl(sirfsoc_rstc_base + (reset_bit / 32) * 4) & ~(1 << reset_bit), 49 writel(readl(sirfsoc_rstc_base +
50 (reset_bit / 32) * 4) & ~(1 << reset_bit),
48 sirfsoc_rstc_base + (reset_bit / 32) * 4); 51 sirfsoc_rstc_base + (reset_bit / 32) * 4);
49 } else { 52 } else {
50 /* 53 /*
51 * For MARCO and POLO 54 * For MARCO and POLO
52 * Writing 1 to SET register resets corresponding block. Writing 1 to CLEAR 55 * Writing 1 to SET register resets corresponding block.
53 * register de-asserts reset signal of the corresponding block. 56 * Writing 1 to CLEAR register de-asserts reset signal of the
54 * datasheet doesn't require explicit delay between the set and clear 57 * corresponding block.
55 * of reset bit. it could be shorter if tests pass. 58 * datasheet doesn't require explicit delay between the set and
59 * clear of reset bit. it could be shorter if tests pass.
56 */ 60 */
57 writel(1 << reset_bit, sirfsoc_rstc_base + (reset_bit / 32) * 8); 61 writel(1 << reset_bit,
58 msleep(10); 62 sirfsoc_rstc_base + (reset_bit / 32) * 8);
59 writel(1 << reset_bit, sirfsoc_rstc_base + (reset_bit / 32) * 8 + 4); 63 msleep(20);
64 writel(1 << reset_bit,
65 sirfsoc_rstc_base + (reset_bit / 32) * 8 + 4);
60 } 66 }
61 67
62 mutex_unlock(&rstc_lock); 68 mutex_unlock(&rstc_lock);