From patchwork Tue May 21 13:39:04 2013
Content-Type: text/plain; charset="utf-8"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
X-Patchwork-Submitter: Piotr Wilczek
X-Patchwork-Id: 245311
X-Patchwork-Delegate: promsoft@gmail.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 E765D2C00C1
for ;
Tue, 21 May 2013 23:39:56 +1000 (EST)
Received: from localhost (localhost [127.0.0.1])
by theia.denx.de (Postfix) with ESMTP id 8CFFA4A235;
Tue, 21 May 2013 15:39:53 +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 E0srb1CeramP; Tue, 21 May 2013 15:39:53 +0200 (CEST)
Received: from theia.denx.de (localhost [127.0.0.1])
by theia.denx.de (Postfix) with ESMTP id 3AC8E4A23B;
Tue, 21 May 2013 15:39:48 +0200 (CEST)
Received: from localhost (localhost [127.0.0.1])
by theia.denx.de (Postfix) with ESMTP id 6A29F4A23B
for ; Tue, 21 May 2013 15:39:41 +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 WbHER04tSsJh for ;
Tue, 21 May 2013 15:39:35 +0200 (CEST)
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 mailout4.samsung.com (mailout4.samsung.com [203.254.224.34])
by theia.denx.de (Postfix) with ESMTP id 60D874A235
for ; Tue, 21 May 2013 15:39:29 +0200 (CEST)
Received: from epcpsbgm2.samsung.com (epcpsbgm2 [203.254.230.27])
by mailout4.samsung.com
(Oracle Communications Messaging Server 7u4-24.01(7.0.4.24.0) 64bit
(built Nov
17 2011)) with ESMTP id <0MN50040CHWTWTD0@mailout4.samsung.com> for
u-boot@lists.denx.de; Tue, 21 May 2013 22:39:25 +0900 (KST)
X-AuditID: cbfee61b-b7f0d6d00000450a-5f-519b790df8bf
Received: from epmmp2 ( [203.254.227.17]) by epcpsbgm2.samsung.com (EPCPMTA)
with SMTP id A2.12.17674.D097B915;
Tue, 21 May 2013 22:39:25 +0900 (KST)
Received: from mcdsrvbld02.digital.local ([106.116.37.23])
by mmp2.samsung.com (Oracle Communications Messaging Server 7u4-24.01
(7.0.4.24.0) 64bit (built Nov 17 2011))
with ESMTPA id <0MN500IIVHXCIC70@mmp2.samsung.com>; Tue,
21 May 2013 22:39:25 +0900 (KST)
From: Piotr Wilczek
To: u-boot@lists.denx.de
Date: Tue, 21 May 2013 15:39:04 +0200
Message-id: <1369143544-29213-1-git-send-email-p.wilczek@samsung.com>
X-Mailer: git-send-email 1.7.10
X-Brightmail-Tracker:
H4sIAAAAAAAAA+NgFnrCJMWRmVeSWpSXmKPExsVy+t9jQV3eytmBBv/3CFmcbXrDbvHm4WZG
i44jLYwW656sZbV4u7eT3YHV4+ydHYwefVtWMQYwRXHZpKTmZJalFunbJXBlzPu9k7lgP2fF
hqb7rA2MD9i7GDk4JARMJHbfM+ti5AQyxSQu3FvP1sXIxSEkMJ1Rom1lPxOE08UkMfnCZyaQ
KjYBbYnlb94wgtgiAhISv/qvMoIUMQssY5RoaPjNDpIQFnCT6F78AMxmEVCVeLFgFlgDr4Cr
xIZ/P5gg1slLPL3fxzaBkXsBI8MqRtHUguSC4qT0XCO94sTc4tK8dL3k/NxNjGC/P5Pewbiq
weIQowAHoxIPr4DhrEAh1sSy4srcQ4wSHMxKIrzznWYHCvGmJFZWpRblxxeV5qQWH2KU5mBR
Euc92GodKCSQnliSmp2aWpBaBJNl4uCUamA0Y7vsu3Ta7KSQXXb2P0KvdUsu0Ta7PDMhRV9l
/Y350nczpe4FxOfoCDcW/VfYPC36V3PJ2/qzE2Ym/3oh1CJV27NUf4HURi029nK/hdrxITOn
ivwN+Jaz+GW1aMZ8jS/fTnpWcG+vtatc78ceaZDSVDLh+9+3Hd7hfwI+tcf3uxqkNFoBHchS
nJFoqMVcVJwIAFLpPz73AQAA
Cc: Piotr Wilczek ,
Kyungmin Park
Subject: [U-Boot] [PATCH] arm:exynos:gpio: fix s5p_gpio_part_max for
exynos4x12
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
This patch fix wrong value returned by 's5p_gpio_part_max' function
for Exynos4412.
Signed-off-by: Piotr Wilczek
Signed-off-by: Kyungmin Park
CC: Minkyu Kang
---
arch/arm/include/asm/arch-exynos/gpio.h | 17 +++++++++++++----
1 file changed, 13 insertions(+), 4 deletions(-)
diff --git a/arch/arm/include/asm/arch-exynos/gpio.h b/arch/arm/include/asm/arch-exynos/gpio.h
index cfe1024..20a4e3f 100644
--- a/arch/arm/include/asm/arch-exynos/gpio.h
+++ b/arch/arm/include/asm/arch-exynos/gpio.h
@@ -303,10 +303,19 @@ static inline unsigned int s5p_gpio_part_max(int nr)
return EXYNOS5_GPIO_PART2_MAX;
} else if (cpu_is_exynos4()) {
- if (nr < EXYNOS4_GPIO_PART1_MAX)
- return 0;
- else
- return EXYNOS4_GPIO_PART1_MAX;
+ if (proid_is_exynos4412()) {
+ if (nr < EXYNOS4X12_GPIO_PART1_MAX)
+ return 0;
+ else if (nr < EXYNOS4X12_GPIO_PART2_MAX)
+ return EXYNOS4X12_GPIO_PART1_MAX;
+ else
+ return EXYNOS4X12_GPIO_PART2_MAX;
+ } else {
+ if (nr < EXYNOS4_GPIO_PART1_MAX)
+ return 0;
+ else
+ return EXYNOS4_GPIO_PART1_MAX;
+ }
}
return 0;