From patchwork Wed Mar 6 00:40:04 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 225226 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 2E1492C02A8 for ; Wed, 6 Mar 2013 11:44:50 +1100 (EST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 5920F4A250; Wed, 6 Mar 2013 01:43:51 +0100 (CET) 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 YMX83efRlj2g; Wed, 6 Mar 2013 01:43:51 +0100 (CET) Received: from theia.denx.de (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 8C5704A251; Wed, 6 Mar 2013 01:41:54 +0100 (CET) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 7B3404A20D for ; Wed, 6 Mar 2013 01:41:25 +0100 (CET) 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 t6TUkdHXU03a for ; Wed, 6 Mar 2013 01:41:24 +0100 (CET) X-policyd-weight: NOT_IN_SBL_XBL_SPAMHAUS=-1.5 NOT_IN_SPAMCOP=-1.5 NOT_IN_BL_NJABL=-1.5 (only DNSBL check requested) Received: from mail-ye0-f202.google.com (mail-ye0-f202.google.com [209.85.213.202]) by theia.denx.de (Postfix) with ESMTPS id D8BD74A1E4 for ; Wed, 6 Mar 2013 01:41:04 +0100 (CET) Received: by mail-ye0-f202.google.com with SMTP id q5so807024yen.5 for ; Tue, 05 Mar 2013 16:41:03 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-received:from:to:cc:subject:date:message-id:x-mailer:in-reply-to :references:x-gm-message-state; bh=1xUMXZinEux8rEr5KSP1tWPJFsPuHuDrlEVlugNYwR4=; b=Ef3Zqsto1W306fC4NaB1k8fMPqmxdB0R1lDtscPw8q8yHWGcUA8CA4241QaaDZI+ce m2JQ6EZEq2wcXdEXlUjOs8hnJaFjuRs6BbpDw9CMGMm10p3fEqvmKUuzH3hmctoCb8nk 1VScsGB6+uIKXV1epcAYN+/1WyWpANL+yXTJfq2LWOZXinTKttTQ4OEg9T7H/sGJFGWc xda9AmrE57YfZ+QU/XUzoiY4ygV1P29pDa/UyM6ysWefQK1sU15Dw1ID6l8Zswk/U7Iz V5fhJ+1Bsn80Cl3izwFzfHszAI1GabvAPnEmD+W00LUccsineqvJDmXNT+uY8zPM/yUe AcbA== X-Received: by 10.236.114.161 with SMTP id c21mr15842443yhh.52.1362530463694; Tue, 05 Mar 2013 16:41:03 -0800 (PST) Received: from corp2gmr1-2.hot.corp.google.com (corp2gmr1-2.hot.corp.google.com [172.24.189.93]) by gmr-mx.google.com with ESMTPS id t30si444719yhi.6.2013.03.05.16.41.03 (version=TLSv1.1 cipher=AES128-SHA bits=128/128); Tue, 05 Mar 2013 16:41:03 -0800 (PST) Received: from kaka.mtv.corp.google.com (kaka.mtv.corp.google.com [172.22.73.79]) by corp2gmr1-2.hot.corp.google.com (Postfix) with ESMTP id 86D635A4213; Tue, 5 Mar 2013 16:41:03 -0800 (PST) Received: by kaka.mtv.corp.google.com (Postfix, from userid 121222) id 476AB1607C8; Tue, 5 Mar 2013 16:41:03 -0800 (PST) From: Simon Glass To: U-Boot Mailing List Date: Tue, 5 Mar 2013 16:40:04 -0800 Message-Id: <1362530405-10824-31-git-send-email-sjg@chromium.org> X-Mailer: git-send-email 1.8.1.3 In-Reply-To: <1362530405-10824-1-git-send-email-sjg@chromium.org> References: <1362530405-10824-1-git-send-email-sjg@chromium.org> X-Gm-Message-State: ALoCoQkeUZfLzwbrUbtq0hB9+XNMyrgJcZMKJi/KeMRL2DeHDwTYiuO+ep7OBU53mLQtElgFbUc0gVBt6I4kVQ41pSX6KyKMJjQjNsJrjmZv0BsV9p944jp+nUPzyEpZY4udJYoZwwMuexlLFvsQqTBGYLR9suu8MS0ToTP2idRmPMlL2g/WxOzVssW3hYswOKnSNM3zYIYJ Cc: Graeme Russ , Tom Rini , Vadim Bendebury Subject: [U-Boot] [PATCH v6 30/31] sparc: Fix build warnings in serial.c 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: , MIME-Version: 1.0 Sender: u-boot-bounces@lists.denx.de Errors-To: u-boot-bounces@lists.denx.de These macros are already defined in io.h so should not be declared in serial.c. serial.c:38:0: warning: "READ_BYTE" redefined /home/sjg/c/src/third_party/u-boot/files/include/asm/io.h:36:0: note: this is the location of the previous definition serial.c:39:0: warning: "READ_HWORD" redefined /home/sjg/c/src/third_party/u-boot/files/include/asm/io.h:37:0: note: this is the location of the previous definition serial.c:40:0: warning: "READ_WORD" redefined /home/sjg/c/src/third_party/u-boot/files/include/asm/io.h:38:0: note: this is the location of the previous definition serial.c:41:0: warning: "READ_DWORD" redefined /home/sjg/c/src/third_party/u-boot/files/include/asm/io.h:39:0: note: this is the location of the previous definition Signed-off-by: Simon Glass Signed-off-by: Simon Glass --- Changes in v6: - Add new patch to fix warnings in sparc's serial.c Changes in v5: None Changes in v4: None Changes in v3: None Changes in v2: None arch/sparc/cpu/leon2/serial.c | 10 ---------- arch/sparc/cpu/leon3/serial.c | 10 ---------- 2 files changed, 20 deletions(-) diff --git a/arch/sparc/cpu/leon2/serial.c b/arch/sparc/cpu/leon2/serial.c index 40d5b01..b41ee01 100644 --- a/arch/sparc/cpu/leon2/serial.c +++ b/arch/sparc/cpu/leon2/serial.c @@ -31,16 +31,6 @@ DECLARE_GLOBAL_DATA_PTR; -/* Force cache miss each time a serial controller reg is read */ -#define CACHE_BYPASS 1 - -#ifdef CACHE_BYPASS -#define READ_BYTE(var) SPARC_NOCACHE_READ_BYTE((unsigned int)&(var)) -#define READ_HWORD(var) SPARC_NOCACHE_READ_HWORD((unsigned int)&(var)) -#define READ_WORD(var) SPARC_NOCACHE_READ((unsigned int)&(var)) -#define READ_DWORD(var) SPARC_NOCACHE_READ_DWORD((unsigned int)&(var)) -#endif - static int leon2_serial_init(void) { LEON2_regs *leon2 = (LEON2_regs *) LEON2_PREGS; diff --git a/arch/sparc/cpu/leon3/serial.c b/arch/sparc/cpu/leon3/serial.c index 838d451..af9ce55 100644 --- a/arch/sparc/cpu/leon3/serial.c +++ b/arch/sparc/cpu/leon3/serial.c @@ -32,16 +32,6 @@ DECLARE_GLOBAL_DATA_PTR; -/* Force cache miss each time a serial controller reg is read */ -#define CACHE_BYPASS 1 - -#ifdef CACHE_BYPASS -#define READ_BYTE(var) SPARC_NOCACHE_READ_BYTE((unsigned int)&(var)) -#define READ_HWORD(var) SPARC_NOCACHE_READ_HWORD((unsigned int)&(var)) -#define READ_WORD(var) SPARC_NOCACHE_READ((unsigned int)&(var)) -#define READ_DWORD(var) SPARC_NOCACHE_READ_DWORD((unsigned int)&(var)) -#endif - ambapp_dev_apbuart *leon3_apbuart = NULL; static int leon3_serial_init(void)