浏览代码

drivers/rtc/rtc-nuc900.c: use NULL instead of 0

check_rtc_access_enable() returns pointer, thus NULL should be used
instead of 0 in order to fix the following sparse warning:

  drivers/rtc/rtc-nuc900.c:102:16: warning: Using plain integer as NULL pointer

Signed-off-by: Jingoo Han <jg1.han@samsung.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Jingoo Han 12 年之前
父节点
当前提交
0ebbf43976
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      drivers/rtc/rtc-nuc900.c

+ 1 - 1
drivers/rtc/rtc-nuc900.c

@@ -99,7 +99,7 @@ static int *check_rtc_access_enable(struct nuc900_rtc *nuc900_rtc)
 	if (!timeout)
 	if (!timeout)
 		return ERR_PTR(-EPERM);
 		return ERR_PTR(-EPERM);
 
 
-	return 0;
+	return NULL;
 }
 }
 
 
 static int nuc900_rtc_bcd2bin(unsigned int timereg,
 static int nuc900_rtc_bcd2bin(unsigned int timereg,