Skip to content

Commit 0f8a206

Browse files
nathanchanceVasily Gorbik
authored andcommitted
s390/time: Fix clk type in get_tod_clock
Clang warns: In file included from ../arch/s390/boot/startup.c:3: In file included from ../include/linux/elf.h:5: In file included from ../arch/s390/include/asm/elf.h:132: In file included from ../include/linux/compat.h:10: In file included from ../include/linux/time.h:74: In file included from ../include/linux/time32.h:13: In file included from ../include/linux/timex.h:65: ../arch/s390/include/asm/timex.h:160:20: warning: passing 'unsigned char [16]' to parameter of type 'char *' converts between pointers to integer types with different sign [-Wpointer-sign] get_tod_clock_ext(clk); ^~~ ../arch/s390/include/asm/timex.h:149:44: note: passing argument to parameter 'clk' here static inline void get_tod_clock_ext(char *clk) ^ Change clk's type to just be char so that it matches what happens in get_tod_clock_ext. Fixes: 57b28f6 ("[S390] s390_hypfs: Add new attributes") Link: ClangBuiltLinux#861 Link: http://lkml.kernel.org/r/[email protected] Reviewed-by: Nick Desaulniers <[email protected]> Signed-off-by: Nathan Chancellor <[email protected]> Signed-off-by: Vasily Gorbik <[email protected]>
1 parent 27dc070 commit 0f8a206

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

arch/s390/include/asm/timex.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,7 @@ static inline void get_tod_clock_ext(char *clk)
155155

156156
static inline unsigned long long get_tod_clock(void)
157157
{
158-
unsigned char clk[STORE_CLOCK_EXT_SIZE];
158+
char clk[STORE_CLOCK_EXT_SIZE];
159159

160160
get_tod_clock_ext(clk);
161161
return *((unsigned long long *)&clk[1]);

0 commit comments

Comments
 (0)