summaryrefslogtreecommitdiff
path: root/drivers/rtc
diff options
context:
space:
mode:
authorMasahiro Yamada <yamada.masahiro@socionext.com>2016-09-06 22:17:39 +0900
committerTom Rini <trini@konsulko.com>2016-09-23 17:53:54 -0400
commita4ca3799c2edf2b805f804a07d234a9e5eaae60f (patch)
treedb22263ba5173bafedd9cca35307e1d99ef96df2 /drivers/rtc
parent63a7578e4e7dc906e75b0bec5a2f3fe41c3720f4 (diff)
drivers: squash lines for immediate return
Remove unneeded variables and assignments. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Diffstat (limited to 'drivers/rtc')
-rw-r--r--drivers/rtc/m48t35ax.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/rtc/m48t35ax.c b/drivers/rtc/m48t35ax.c
index 021b91f7313..36011a5b884 100644
--- a/drivers/rtc/m48t35ax.c
+++ b/drivers/rtc/m48t35ax.c
@@ -127,10 +127,8 @@ void rtc_reset (void)
static uchar rtc_read (uchar reg)
{
- uchar val;
- val = *(unsigned char *)
+ return *(unsigned char *)
((CONFIG_SYS_NVRAM_BASE_ADDR + CONFIG_SYS_NVRAM_SIZE - 8) + reg);
- return val;
}
static void rtc_write (uchar reg, uchar val)