aboutsummaryrefslogtreecommitdiff
path: root/external
diff options
context:
space:
mode:
authorStewart Smith <stewart@linux.vnet.ibm.com>2017-07-17 17:23:39 +1000
committerStewart Smith <stewart@linux.vnet.ibm.com>2017-07-19 15:49:39 +1000
commit9880e148c2ea2d7a6f24a025799e59ac1a18cf92 (patch)
tree778607574858ae293edd002264caa1c139dc5eb8 /external
parentf2c87a3d2f6df0886124636239d9950ef0abcab0 (diff)
downloadskiboot-9880e148c2ea2d7a6f24a025799e59ac1a18cf92.zip
skiboot-9880e148c2ea2d7a6f24a025799e59ac1a18cf92.tar.gz
skiboot-9880e148c2ea2d7a6f24a025799e59ac1a18cf92.tar.bz2
pflash: build with skiboot HOSTCFLAGS warnings
mostly missing prototypes and unused parameters. Reviewed-by: Cyril Bur <cyril.bur@au1.ibm.com> Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
Diffstat (limited to 'external')
-rw-r--r--external/common/arch_flash_common.c12
-rw-r--r--external/common/arch_flash_x86.c1
-rw-r--r--external/pflash/pflash.c2
-rw-r--r--external/pflash/progress.c1
4 files changed, 12 insertions, 4 deletions
diff --git a/external/common/arch_flash_common.c b/external/common/arch_flash_common.c
index 5b7f9ea..6bce7e1 100644
--- a/external/common/arch_flash_common.c
+++ b/external/common/arch_flash_common.c
@@ -40,17 +40,23 @@ int __attribute__((weak)) arch_flash_erase_chip(struct blocklevel_device *bl)
return blocklevel_erase(bl, 0, total_size);
}
-int __attribute__((weak)) arch_flash_4b_mode(struct blocklevel_device *bl, int set_4b)
+int __attribute__((weak,const)) arch_flash_4b_mode(struct blocklevel_device *bl, int set_4b)
{
+ (void)bl;
+ (void)set_4b;
return -1;
}
-enum flash_access __attribute__((weak)) arch_flash_access(struct blocklevel_device *bl, enum flash_access access)
+enum flash_access __attribute__((weak,const)) arch_flash_access(struct blocklevel_device *bl, enum flash_access access)
{
+ (void)bl;
+ (void)access;
return ACCESS_INVAL;
}
-int __attribute__((weak)) arch_flash_set_wrprotect(struct blocklevel_device *bl, int set)
+int __attribute__((weak,const)) arch_flash_set_wrprotect(struct blocklevel_device *bl, int set)
{
+ (void)bl;
+ (void)set;
return -1;
}
diff --git a/external/common/arch_flash_x86.c b/external/common/arch_flash_x86.c
index 0146243..3638d73 100644
--- a/external/common/arch_flash_x86.c
+++ b/external/common/arch_flash_x86.c
@@ -49,5 +49,6 @@ int arch_flash_init(struct blocklevel_device **r_bl, const char *file, bool keep
void arch_flash_close(struct blocklevel_device *bl, const char *file)
{
+ (void)file;
file_exit_close(bl);
}
diff --git a/external/pflash/pflash.c b/external/pflash/pflash.c
index 3d172d7..7e1d47f 100644
--- a/external/pflash/pflash.c
+++ b/external/pflash/pflash.c
@@ -595,7 +595,7 @@ static void print_help(const char *pname)
printf("\t\tThis message.\n\n");
}
-void exiting(void)
+static void exiting(void)
{
if (need_relock)
arch_flash_set_wrprotect(bl, 1);
diff --git a/external/pflash/progress.c b/external/pflash/progress.c
index 4012020..f4406a7 100644
--- a/external/pflash/progress.c
+++ b/external/pflash/progress.c
@@ -3,6 +3,7 @@
#include <string.h>
#include <limits.h>
#include <time.h>
+#include "progress.h"
static unsigned long progress_max;
static unsigned int progress_pcent;