Commit 53e9895e authored by Mathieu Malaterre's avatar Mathieu Malaterre Committed by Kleber Sacilotto de Souza

powerpc/chrp/time: Make some functions static, add missing header include

BugLink: https://bugs.launchpad.net/bugs/1791953

[ Upstream commit b87a358b ]

Add a missing include <platforms/chrp/chrp.h>.

These functions can all be static, make it so. Fix warnings treated as
errors with W=1:

  arch/powerpc/platforms/chrp/time.c:41:13: error: no previous prototype for ‘chrp_time_init’ [-Werror=missing-prototypes]
  arch/powerpc/platforms/chrp/time.c:66:5: error: no previous prototype for ‘chrp_cmos_clock_read’ [-Werror=missing-prototypes]
  arch/powerpc/platforms/chrp/time.c:74:6: error: no previous prototype for ‘chrp_cmos_clock_write’ [-Werror=missing-prototypes]
  arch/powerpc/platforms/chrp/time.c:86:5: error: no previous prototype for ‘chrp_set_rtc_time’ [-Werror=missing-prototypes]
  arch/powerpc/platforms/chrp/time.c:130:6: error: no previous prototype for ‘chrp_get_rtc_time’ [-Werror=missing-prototypes]
Signed-off-by: default avatarMathieu Malaterre <malat@debian.org>
Signed-off-by: default avatarMichael Ellerman <mpe@ellerman.id.au>
Signed-off-by: default avatarSasha Levin <alexander.levin@microsoft.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: default avatarStefan Bader <stefan.bader@canonical.com>
Signed-off-by: default avatarKleber Sacilotto de Souza <kleber.souza@canonical.com>
parent 9d07d7fb
...@@ -27,6 +27,8 @@ ...@@ -27,6 +27,8 @@
#include <asm/sections.h> #include <asm/sections.h>
#include <asm/time.h> #include <asm/time.h>
#include <platforms/chrp/chrp.h>
extern spinlock_t rtc_lock; extern spinlock_t rtc_lock;
#define NVRAM_AS0 0x74 #define NVRAM_AS0 0x74
...@@ -62,7 +64,7 @@ long __init chrp_time_init(void) ...@@ -62,7 +64,7 @@ long __init chrp_time_init(void)
return 0; return 0;
} }
int chrp_cmos_clock_read(int addr) static int chrp_cmos_clock_read(int addr)
{ {
if (nvram_as1 != 0) if (nvram_as1 != 0)
outb(addr>>8, nvram_as1); outb(addr>>8, nvram_as1);
...@@ -70,7 +72,7 @@ int chrp_cmos_clock_read(int addr) ...@@ -70,7 +72,7 @@ int chrp_cmos_clock_read(int addr)
return (inb(nvram_data)); return (inb(nvram_data));
} }
void chrp_cmos_clock_write(unsigned long val, int addr) static void chrp_cmos_clock_write(unsigned long val, int addr)
{ {
if (nvram_as1 != 0) if (nvram_as1 != 0)
outb(addr>>8, nvram_as1); outb(addr>>8, nvram_as1);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment