From patchwork Sat Feb 9 16:10:04 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Daniel Schwierzeck X-Patchwork-Id: 219400 X-Patchwork-Delegate: daniel.schwierzeck@googlemail.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 3F0612C0089 for ; Sun, 10 Feb 2013 03:10:17 +1100 (EST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 930494A0AB; Sat, 9 Feb 2013 17:10:15 +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 JxtB8e9v9p+A; Sat, 9 Feb 2013 17:10:15 +0100 (CET) Received: from theia.denx.de (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id A7DAC4A09E; Sat, 9 Feb 2013 17:10:13 +0100 (CET) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id D277D4A09E for ; Sat, 9 Feb 2013 17:10:11 +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 YwjWP6CUVKVT for ; Sat, 9 Feb 2013 17:10:10 +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-bk0-f54.google.com (mail-bk0-f54.google.com [209.85.214.54]) by theia.denx.de (Postfix) with ESMTPS id 6C1C24A098 for ; Sat, 9 Feb 2013 17:10:09 +0100 (CET) Received: by mail-bk0-f54.google.com with SMTP id w5so2095316bku.13 for ; Sat, 09 Feb 2013 08:10:08 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:from:to:cc:subject:date:message-id:x-mailer; bh=MAyrG4bQN1kZUMSrFcHo261qmRBoQzF7kRqFg5vi3FQ=; b=SndHrVBLLX7qeJav9F4lS1cx/dgAY6LWsIeixn33dO4AkC+c+dI9armRp4gEsqcZYS SA3I4iVUdCSAUFHsqq38/t/+Yl9o3paC8HNw1/g4ybzUJbOOo0HuW4zVagxjDb2ROtIg jzg/HJgxEZXK/Yx5w8zglS0uRGwR06Ti9UgMzvSxO7cnqAW2BCbSQ1N6Xy+rF7C2zfoS d8KOEyXbJ7Vk0PDINVKuAY17Z3YAzd74PC+mGx6Br/GCCJUF1aVRtG5ofRdwKjsHJEug s/g/fC9TVYb3A3W4xb7P042mQ/YwZAh9a2evcCiWp8tcO4JuSg1RkzEyOuRaiQeZqZ+t SEzQ== X-Received: by 10.204.9.21 with SMTP id j21mr2467751bkj.32.1360426208364; Sat, 09 Feb 2013 08:10:08 -0800 (PST) Received: from workstation.sas.sys.sphairon.com (dslb-094-222-038-034.pools.arcor-ip.net. [94.222.38.34]) by mx.google.com with ESMTPS id r17sm11254125bkw.21.2013.02.09.08.10.06 (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Sat, 09 Feb 2013 08:10:07 -0800 (PST) From: daniel.schwierzeck@gmail.com To: u-boot@lists.denx.de Date: Sat, 9 Feb 2013 17:10:04 +0100 Message-Id: <1360426204-2186-1-git-send-email-daniel.schwierzeck@gmail.com> X-Mailer: git-send-email 1.8.1.1 Subject: [U-Boot] [PATCH] MIPS: xburst: fix broken access to global_data 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 From: Daniel Schwierzeck Fix access to global_data which is broken since commits: commit 035cbe99cd2fd4adf9d7fd95aeebb5f814e37eb9 Author: Simon Glass Date: Thu Dec 13 20:49:08 2012 +0000 mips: Move per_clk and dev_clk to arch_global_data Move these field into arch_global_data and tidy up. The other CONFIG_JZSOC fields are used by various architectures, so just remove the #ifdef bracketing for these. Signed-off-by: Simon Glass commit 582601da2f90b1850aa19f7820b1623c79b3dac6 Author: Simon Glass Date: Thu Dec 13 20:48:35 2012 +0000 arm: Move lastinc to arch_global_data Move this field into arch_global_data and tidy up. Signed-off-by: Simon Glass commit 66ee69234795c0596f84b25f06b7fbc2e8ed214c Author: Simon Glass Date: Thu Dec 13 20:48:34 2012 +0000 arm: Move tbl to arch_global_data Move this field into arch_global_data and tidy up. Signed-off-by: Simon Glass Signed-off-by: Daniel Schwierzeck Cc: Xiangfu Liu --- arch/mips/cpu/xburst/jz4740.c | 6 +++--- arch/mips/include/asm/global_data.h | 3 +++ 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/arch/mips/cpu/xburst/jz4740.c b/arch/mips/cpu/xburst/jz4740.c index c0b9817..b2d8f4d 100644 --- a/arch/mips/cpu/xburst/jz4740.c +++ b/arch/mips/cpu/xburst/jz4740.c @@ -201,10 +201,10 @@ void calc_clocks(void) pllout = __cpm_get_pllout(); gd->cpu_clk = pllout / div[__cpm_get_cdiv()]; - gd->sys_clk = pllout / div[__cpm_get_hdiv()]; - gd->per_clk = pllout / div[__cpm_get_pdiv()]; + gd->arch.sys_clk = pllout / div[__cpm_get_hdiv()]; + gd->arch.per_clk = pllout / div[__cpm_get_pdiv()]; gd->mem_clk = pllout / div[__cpm_get_mdiv()]; - gd->dev_clk = CONFIG_SYS_EXTAL; + gd->arch.dev_clk = CONFIG_SYS_EXTAL; } void rtc_init(void) diff --git a/arch/mips/include/asm/global_data.h b/arch/mips/include/asm/global_data.h index b39737f..f912428 100644 --- a/arch/mips/include/asm/global_data.h +++ b/arch/mips/include/asm/global_data.h @@ -32,6 +32,9 @@ struct arch_global_data { /* There are other clocks in the jz4740 */ unsigned long per_clk; /* Peripheral bus clock */ unsigned long dev_clk; /* Device clock */ + unsigned long sys_clk; + unsigned long tbl; + unsigned long lastinc; #endif };