Skip to contentSkip to conversation

arm:exynos:gpio: fix s5p_gpio_part_max for exynos4x12

PATCH New Piotr Wilczek 2 participants 4 messages May 21, 2013 – Aug 6, 2013

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 arm:exynos:gpio: fix s5p_gpio_part_max for exynos4x12

This patch fix wrong value returned by 's5p_gpio_part_max' function for Exynos4412.

---
 arch/arm/include/asm/arch-exynos/gpio.h |   17 +++++++++++++----
 1 file changed, 13 insertions(+), 4 deletions(-)
arch/arm/include/asm/arch-exynos/gpio.h +13 -4
index cfe1024..20a4e3f 100644
@@ -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;
Signature · 1 line
1.7.9.5
#1 lore raw

PATCH 1/1 arm:exynos:gpio: fix s5p_gpio_part_max for exynos4x12

Dear Minkyu Kang,

Could you please review this patch?

Best regards,
Piotr Wilczek

--
Samsung R&D Institute Poland
Samsung Electronics

Quoted 39 lines · Piotr Wilczek

This patch fix wrong value returned by 's5p_gpio_part_max' function for Exynos4412.

---
  arch/arm/include/asm/arch-exynos/gpio.h |   17 +++++++++++++----
  1 file changed, 13 insertions(+), 4 deletions(-)
arch/arm/include/asm/arch-exynos/gpio.h +13 -4
index cfe1024..20a4e3f 100644
@@ -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;
#2 lore raw

PATCH 1/1 arm:exynos:gpio: fix s5p_gpio_part_max for exynos4x12

Quoted 3 lines · Piotr Wilczek

Dear Minkyu Kang,

Could you please review this patch?

Please don't top posting.
And your patches will be merged after release.

Quoted 8 lines

Best regards,
Piotr Wilczek

Signature · 2 lines
Samsung R&D Institute Poland
Samsung Electronics

Thanks,
Minkyu Kang.

#3 lore raw

PATCH 1/1 arm:exynos:gpio: fix s5p_gpio_part_max for exynos4x12

In reply to Piotr Wilczek
Quoted 29 lines · Piotr Wilczek

This patch fix wrong value returned by 's5p_gpio_part_max' function for Exynos4412.

---
 arch/arm/include/asm/arch-exynos/gpio.h |   17 +++++++++++++----
 1 file changed, 13 insertions(+), 4 deletions(-)
arch/arm/include/asm/arch-exynos/gpio.h +6 -4
index cfe1024..20a4e3f 100644
@@ -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

arch/arm/include/asm/arch-exynos/gpio.h static inline unsigned int s5p_gpio_part_max(int nr) · line 321

Quoted 10 lines
arch/arm/include/asm/arch-exynos/gpio.h +7 -0
+				return EXYNOS4X12_GPIO_PART2_MAX;
+		} else {
+			if (nr < EXYNOS4_GPIO_PART1_MAX)
+				return 0;
+			else
+				return EXYNOS4_GPIO_PART1_MAX;
+		}
 	}
 
 	return 0;

applied to u-boot-samsung.

Thanks,
Minkyu Kang.