From patchwork Wed Oct 16 01:47:13 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Axel Lin X-Patchwork-Id: 283813 X-Patchwork-Delegate: trini@ti.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from theia.denx.de (theia.denx.de [85.214.87.163]) by ozlabs.org (Postfix) with ESMTP id 1C58F2C0344 for ; Wed, 16 Oct 2013 12:55:18 +1100 (EST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id A22C44A07A; Wed, 16 Oct 2013 03:55:14 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at theia.denx.de Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id AIFmDHafYN1I; Wed, 16 Oct 2013 03:55:14 +0200 (CEST) Received: from theia.denx.de (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 7D7464A09B; Wed, 16 Oct 2013 03:55:09 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id C90604A09B for ; Wed, 16 Oct 2013 03:55:07 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at theia.denx.de Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id C0O7iO+BZmxm for ; Wed, 16 Oct 2013 03:55:00 +0200 (CEST) X-policyd-weight: NOT_IN_SBL_XBL_SPAMHAUS=-1.5 NOT_IN_SPAMCOP=-1.5 BL_NJABL=SKIP(-1.5) (only DNSBL check requested) Received: from mail-pd0-f182.google.com (mail-pd0-f182.google.com [209.85.192.182]) by theia.denx.de (Postfix) with ESMTPS id 70BF54A07A for ; Wed, 16 Oct 2013 03:54:58 +0200 (CEST) Received: by mail-pd0-f182.google.com with SMTP id r10so124537pdi.13 for ; Tue, 15 Oct 2013 18:54:56 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:message-id:subject:from:to:cc:date:in-reply-to :references:content-type:mime-version:content-transfer-encoding; bh=daAFTtF6sIyW8vOzeBsUdgYPxAfURbWNSi8Hc4cfdGU=; b=bfnzrtKkR7OBcwK11jGcYNVvPW7id4Zwfp//Sx04VYuhTvkaVV0xGbVkXExoWHs5iL S25NiEQL6cP4SZ6Rb8m3nQ2LMSjkq/I428BGdkl++7aOXe9iyZvxLJW1U3sX7x3Jy2bH +0Vt+YOxR31lFTBwTrLtM9Ib8v/otmogap9WgOd1ky2ntl8NFF+6De/BsXKbr5nt3Jtz nMzjayw2OopbMp35pCtpMDXYJmHJupEh3thQl1egB1AdfRl26ptKtJoq6Jdq8ZnYNf6R AiOGL/Wbna5DRuQfBIdQPOmwNnaIA3MIkglbTaaaAG8gIaPCTKqXjr9T6i0G5sgMRkEW CiQQ== X-Gm-Message-State: ALoCoQnAOg5Ru2SvN97qfEU89Na8ppTaOx35uc/XhIACVmVd2SVc5cYSWrzgBPNwSQgkrZzS61fR X-Received: by 10.66.66.42 with SMTP id c10mr866758pat.98.1381888038691; Tue, 15 Oct 2013 18:47:18 -0700 (PDT) Received: from [218.164.132.175] (218-164-132-175.dynamic.hinet.net. [218.164.132.175]) by mx.google.com with ESMTPSA id qn1sm87488437pbc.34.1969.12.31.16.00.00 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 15 Oct 2013 18:47:17 -0700 (PDT) Message-ID: <1381888033.9895.8.camel@phoenix> From: Axel Lin To: Marek Vasut Date: Wed, 16 Oct 2013 09:47:13 +0800 In-Reply-To: <1381887956.9895.6.camel@phoenix> References: <1381887956.9895.6.camel@phoenix> X-Mailer: Evolution 3.6.4-0ubuntu1 Mime-Version: 1.0 Cc: u-boot@lists.denx.de, Rajeshwari Shinde Subject: [U-Boot] [PATCH v2 2/2] serial: s5p: Staticize local functions X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.11 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: u-boot-bounces@lists.denx.de Errors-To: u-boot-bounces@lists.denx.de Staticize local functions in s5p serial driver. Signed-off-by: Axel Lin Acked-by: Minkyu Kang --- v2: Also staticize s5p_serial##port##_* functions drivers/serial/serial_s5p.c | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/drivers/serial/serial_s5p.c b/drivers/serial/serial_s5p.c index f98b422..cc20d2d 100644 --- a/drivers/serial/serial_s5p.c +++ b/drivers/serial/serial_s5p.c @@ -65,7 +65,7 @@ static const int udivslot[] = { 0xffdf, }; -void serial_setbrg_dev(const int dev_index) +static void serial_setbrg_dev(const int dev_index) { struct s5p_uart *const uart = s5p_get_base_uart(dev_index); u32 uclk = get_uart_clk(dev_index); @@ -96,7 +96,7 @@ void serial_setbrg_dev(const int dev_index) * Initialise the serial port with the given baudrate. The settings * are always 8 data bits, no parity, 1 stop bit, no start bits. */ -int serial_init_dev(const int dev_index) +static int serial_init_dev(const int dev_index) { struct s5p_uart *const uart = s5p_get_base_uart(dev_index); @@ -138,7 +138,7 @@ static int serial_err_check(const int dev_index, int op) * otherwise. When the function is succesfull, the character read is * written into its argument c. */ -int serial_getc_dev(const int dev_index) +static int serial_getc_dev(const int dev_index) { struct s5p_uart *const uart = s5p_get_base_uart(dev_index); @@ -158,7 +158,7 @@ int serial_getc_dev(const int dev_index) /* * Output a single byte to the serial port. */ -void serial_putc_dev(const char c, const int dev_index) +static void serial_putc_dev(const char c, const int dev_index) { struct s5p_uart *const uart = s5p_get_base_uart(dev_index); @@ -181,7 +181,7 @@ void serial_putc_dev(const char c, const int dev_index) /* * Test whether a character is in the RX buffer */ -int serial_tstc_dev(const int dev_index) +static int serial_tstc_dev(const int dev_index) { struct s5p_uart *const uart = s5p_get_base_uart(dev_index); @@ -191,7 +191,7 @@ int serial_tstc_dev(const int dev_index) return (int)(readl(&uart->utrstat) & 0x1); } -void serial_puts_dev(const char *s, const int dev_index) +static void serial_puts_dev(const char *s, const int dev_index) { while (*s) serial_putc_dev(*s++, dev_index); @@ -199,12 +199,12 @@ void serial_puts_dev(const char *s, const int dev_index) /* Multi serial device functions */ #define DECLARE_S5P_SERIAL_FUNCTIONS(port) \ -int s5p_serial##port##_init(void) { return serial_init_dev(port); } \ -void s5p_serial##port##_setbrg(void) { serial_setbrg_dev(port); } \ -int s5p_serial##port##_getc(void) { return serial_getc_dev(port); } \ -int s5p_serial##port##_tstc(void) { return serial_tstc_dev(port); } \ -void s5p_serial##port##_putc(const char c) { serial_putc_dev(c, port); } \ -void s5p_serial##port##_puts(const char *s) { serial_puts_dev(s, port); } +static int s5p_serial##port##_init(void) { return serial_init_dev(port); } \ +static void s5p_serial##port##_setbrg(void) { serial_setbrg_dev(port); } \ +static int s5p_serial##port##_getc(void) { return serial_getc_dev(port); } \ +static int s5p_serial##port##_tstc(void) { return serial_tstc_dev(port); } \ +static void s5p_serial##port##_putc(const char c) { serial_putc_dev(c, port); } \ +static void s5p_serial##port##_puts(const char *s) { serial_puts_dev(s, port); } #define INIT_S5P_SERIAL_STRUCTURE(port, __name) { \ .name = __name, \