From: Sascha Hauer <s.hauer@pengutronix.de>
To: Barebox List <barebox@lists.infradead.org>
Subject: [PATCH 12/20] ARM: boards: kontron-samx6i: Add include file to provide prototype
Date: Thu, 18 Oct 2018 08:58:19 +0200 [thread overview]
Message-ID: <20181018065827.19973-13-s.hauer@pengutronix.de> (raw)
In-Reply-To: <20181018065827.19973-1-s.hauer@pengutronix.de>
samx6i_get_size() is declared and used in two different C files.
Provide a header file for the prototype instead.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
---
arch/arm/boards/kontron-samx6i/board.c | 2 +-
arch/arm/boards/kontron-samx6i/lowlevel.c | 2 +-
arch/arm/boards/kontron-samx6i/mem.c | 2 ++
arch/arm/boards/kontron-samx6i/mem.h | 6 ++++++
4 files changed, 10 insertions(+), 2 deletions(-)
create mode 100644 arch/arm/boards/kontron-samx6i/mem.h
diff --git a/arch/arm/boards/kontron-samx6i/board.c b/arch/arm/boards/kontron-samx6i/board.c
index 01826b67d2..b4b0eac824 100644
--- a/arch/arm/boards/kontron-samx6i/board.c
+++ b/arch/arm/boards/kontron-samx6i/board.c
@@ -23,7 +23,7 @@
#include <asm/armlinux.h>
-resource_size_t samx6i_get_size(void);
+#include "mem.h"
/*
* On this board the SDRAM size is always configured by pin selection.
diff --git a/arch/arm/boards/kontron-samx6i/lowlevel.c b/arch/arm/boards/kontron-samx6i/lowlevel.c
index 5c35007040..9742469e20 100644
--- a/arch/arm/boards/kontron-samx6i/lowlevel.c
+++ b/arch/arm/boards/kontron-samx6i/lowlevel.c
@@ -20,7 +20,7 @@
#include <mach/imx6.h>
#include <mach/esdctl.h>
-resource_size_t samx6i_get_size(void);
+#include "mem.h"
static inline void setup_uart(void)
{
diff --git a/arch/arm/boards/kontron-samx6i/mem.c b/arch/arm/boards/kontron-samx6i/mem.c
index ab9969e32c..3b9fbd464a 100644
--- a/arch/arm/boards/kontron-samx6i/mem.c
+++ b/arch/arm/boards/kontron-samx6i/mem.c
@@ -15,6 +15,8 @@
#include <mach/imx-gpio.h>
#include <mach/imx6.h>
+#include "mem.h"
+
#define PCBVERSION_PIN IMX_GPIO_NR(2, 2)
#define PCBID0_PIN IMX_GPIO_NR(6, 7)
#define PCBID1_PIN IMX_GPIO_NR(6, 9)
diff --git a/arch/arm/boards/kontron-samx6i/mem.h b/arch/arm/boards/kontron-samx6i/mem.h
new file mode 100644
index 0000000000..252b82621d
--- /dev/null
+++ b/arch/arm/boards/kontron-samx6i/mem.h
@@ -0,0 +1,6 @@
+#ifndef __BOARD_KONTRON_SAMX6I_MEM_H
+#define __BOARD_KONTRON_SAMX6I_MEM_H
+
+resource_size_t samx6i_get_size(void);
+
+#endif /* __BOARD_KONTRON_SAMX6I_MEM_H */
\ No newline at end of file
--
2.19.0
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
next prev parent reply other threads:[~2018-10-18 6:59 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-10-18 6:58 [PATCH 00/20] Fixes for -Wmissing-prototypes warnings Sascha Hauer
2018-10-18 6:58 ` [PATCH 01/20] ARM: Fix missing prototype warning Sascha Hauer
2018-10-18 6:58 ` [PATCH 02/20] mtd: nand: mxs: make locally used functions static Sascha Hauer
2018-10-18 6:58 ` [PATCH 03/20] video: imx-ipu-v3: Make locally used function static Sascha Hauer
2018-10-18 6:58 ` [PATCH 04/20] ARM: mmu: rename dma_alloc Sascha Hauer
2018-10-18 6:58 ` [PATCH 05/20] dma: Add missing re-inclusion protector Sascha Hauer
2018-10-18 15:31 ` Sam Ravnborg
2018-10-18 6:58 ` [PATCH 06/20] ARM: mmu: include dma.h Sascha Hauer
2018-10-18 6:58 ` [PATCH 07/20] fs: Make locally used functions static Sascha Hauer
2018-10-18 6:58 ` [PATCH 08/20] ARM: cache: include mmu.h Sascha Hauer
2018-10-18 6:58 ` [PATCH 09/20] ARM: boards: GuF Vincell: Make locally used function static Sascha Hauer
2018-10-18 6:58 ` [PATCH 10/20] ARM: boards: karo-tx6x: " Sascha Hauer
2018-10-18 6:58 ` [PATCH 11/20] ARM: boards: kindle mx50: " Sascha Hauer
2018-10-18 6:58 ` Sascha Hauer [this message]
2018-10-18 15:33 ` [PATCH 12/20] ARM: boards: kontron-samx6i: Add include file to provide prototype Sam Ravnborg
2018-10-18 6:58 ` [PATCH 13/20] ARM: boards: phytec-som-imx6: Make locally used function static Sascha Hauer
2018-10-18 6:58 ` [PATCH 14/20] ARM: legacy Linux support: Make locally used functions static Sascha Hauer
2018-10-18 6:58 ` [PATCH 15/20] drivers: clk: imx5: " Sascha Hauer
2018-10-18 6:58 ` [PATCH 16/20] usb: ulpi: " Sascha Hauer
2018-10-18 6:58 ` [PATCH 17/20] ARM: unwind: Provide prototypes for exported functions Sascha Hauer
2018-10-18 6:58 ` [PATCH 18/20] ARM: unwind: Make locally used function static Sascha Hauer
2018-10-18 6:58 ` [PATCH 19/20] ARM: i.MX: Add missing include Sascha Hauer
2018-10-18 15:35 ` Sam Ravnborg
2018-10-19 11:51 ` Sascha Hauer
2018-10-18 6:58 ` [PATCH 20/20] nvmem: i.MX ocotp: Make locally used functions static Sascha Hauer
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20181018065827.19973-13-s.hauer@pengutronix.de \
--to=s.hauer@pengutronix.de \
--cc=barebox@lists.infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox