From patchwork Wed Oct 16 01:45:56 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Axel Lin X-Patchwork-Id: 283811 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 6A24B2C0344 for ; Wed, 16 Oct 2013 12:46:17 +1100 (EST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 32DFC4A09F; Wed, 16 Oct 2013 03:46:15 +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 s1Di9lS9WrxN; Wed, 16 Oct 2013 03:46:15 +0200 (CEST) Received: from theia.denx.de (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 5C2F14A092; Wed, 16 Oct 2013 03:46:13 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id CAE7D4A092 for ; Wed, 16 Oct 2013 03:46:11 +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 o8xDEWNgRmCK for ; Wed, 16 Oct 2013 03:46:05 +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-pb0-f51.google.com (mail-pb0-f51.google.com [209.85.160.51]) by theia.denx.de (Postfix) with ESMTPS id 923304A07A for ; Wed, 16 Oct 2013 03:46:03 +0200 (CEST) Received: by mail-pb0-f51.google.com with SMTP id jt11so102580pbb.10 for ; Tue, 15 Oct 2013 18:46:02 -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:content-type :mime-version:content-transfer-encoding; bh=6Fde/SbHGUUfJmoYR1HvWvHL76Hd8gWJMN8iLTgx494=; b=JH7RIXV2RjcHjlxnNdBSQ+9TYAmUuXMSw+TSiE2BpRCDHWrmJHeXGE66vUOKLWuon3 uyp2pYc0KT9Gr6XQJ6q1H3GQrjidYfvwbjmN6nBF8f/AfAUQE9yXKkTzZ33LLAV1iT+6 oIJKFrGnBDMwOIXsojrRGuD8TISb+DFYrcXXi7/0O3QhNjmFjmnasNgHLNkqD4/T/EsW Gi8uMqruKBHN9e1IN8tbU2236eQcaQsQ0U7MTjxminmEKBDHE10KrtADQnY4pCZ879/Y puE+ew27tUTFcMxdiwCbqJ1OsyeztYXZLMX6tZvePs1DbAoffNQn8FVCguFsJ/+Ne/IM L4pg== X-Gm-Message-State: ALoCoQmBtfu746uI5Q0wa1B4qwXvGPmBh+G4wAGuRMB7HtAeVPoua8rqIM/ZqFGljpZ1XA+4yM8T X-Received: by 10.66.7.68 with SMTP id h4mr956968paa.0.1381887962514; Tue, 15 Oct 2013 18:46:02 -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 yh1sm87507085pbc.21.1969.12.31.16.00.00 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 15 Oct 2013 18:46:01 -0700 (PDT) Message-ID: <1381887956.9895.6.camel@phoenix> From: Axel Lin To: Marek Vasut Date: Wed, 16 Oct 2013 09:45:56 +0800 X-Mailer: Evolution 3.6.4-0ubuntu1 Mime-Version: 1.0 Cc: u-boot@lists.denx.de, Stefan Roese Subject: [U-Boot] [PATCH v2 1/2] serial: xuartlite: 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 xuartlite driver. Signed-off-by: Axel Lin Acked-by: Stefan Roese Tested-by: Michal Simek --- v2: Also staticize userial##port##_* functions drivers/serial/serial_xuartlite.c | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/drivers/serial/serial_xuartlite.c b/drivers/serial/serial_xuartlite.c index 9c1d025..e613994 100644 --- a/drivers/serial/serial_xuartlite.c +++ b/drivers/serial/serial_xuartlite.c @@ -39,7 +39,7 @@ static struct uartlite *userial_ports[4] = { #endif }; -void uartlite_serial_putc(const char c, const int port) +static void uartlite_serial_putc(const char c, const int port) { struct uartlite *regs = userial_ports[port]; @@ -51,13 +51,13 @@ void uartlite_serial_putc(const char c, const int port) out_be32(®s->tx_fifo, c & 0xff); } -void uartlite_serial_puts(const char *s, const int port) +static void uartlite_serial_puts(const char *s, const int port) { while (*s) uartlite_serial_putc(*s++, port); } -int uartlite_serial_getc(const int port) +static int uartlite_serial_getc(const int port) { struct uartlite *regs = userial_ports[port]; @@ -66,7 +66,7 @@ int uartlite_serial_getc(const int port) return in_be32(®s->rx_fifo) & 0xff; } -int uartlite_serial_tstc(const int port) +static int uartlite_serial_tstc(const int port) { struct uartlite *regs = userial_ports[port]; @@ -82,16 +82,16 @@ static int uartlite_serial_init(const int port) /* Multi serial device functions */ #define DECLARE_ESERIAL_FUNCTIONS(port) \ - int userial##port##_init(void) \ + static int userial##port##_init(void) \ { return uartlite_serial_init(port); } \ - void userial##port##_setbrg(void) {} \ - int userial##port##_getc(void) \ + static void userial##port##_setbrg(void) {} \ + static int userial##port##_getc(void) \ { return uartlite_serial_getc(port); } \ - int userial##port##_tstc(void) \ + static int userial##port##_tstc(void) \ { return uartlite_serial_tstc(port); } \ - void userial##port##_putc(const char c) \ + static void userial##port##_putc(const char c) \ { uartlite_serial_putc(c, port); } \ - void userial##port##_puts(const char *s) \ + static void userial##port##_puts(const char *s) \ { uartlite_serial_puts(s, port); } /* Serial device descriptor */