[Armadeus-commitlog] armadeus branch, master, updated. release-3.4-31-g0bec233
Brought to you by:
sszy
|
From: Julien B a. A. <ar...@us...> - 2011-04-05 21:11:41
|
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "armadeus".
The branch, master has been updated
via 0bec233eff1b77d606cfd6650304d36b00d94726 (commit)
from ffaec3b5562ffa7fba9863033ba1a75c0f726c2a (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 0bec233eff1b77d606cfd6650304d36b00d94726
Author: Julien Boibessot <jul...@ar...>
Date: Tue Apr 5 23:09:04 2011 +0200
[LINUX] 2.6.38: Makes temporary fix to have working WiFi on APF51Dev board
-----------------------------------------------------------------------
Summary of changes:
.../408-armadeus-add_apf51-dev_baseboard.patch | 19 +++--
.../420-armadeus-esdhc-add_gpio_SD_detection.patch | 87 +++++++++++---------
..._possibility_to_deactivate_SDIO_interrupt.patch | 56 +++++++++++++
3 files changed, 114 insertions(+), 48 deletions(-)
create mode 100644 buildroot/target/device/armadeus/linux/kernel-patches/2.6.38/427-armadeus-esdhc-imx-add_possibility_to_deactivate_SDIO_interrupt.patch
diff --git a/buildroot/target/device/armadeus/linux/kernel-patches/2.6.38/408-armadeus-add_apf51-dev_baseboard.patch b/buildroot/target/device/armadeus/linux/kernel-patches/2.6.38/408-armadeus-add_apf51-dev_baseboard.patch
index f9c6b5a..5c8869f 100644
--- a/buildroot/target/device/armadeus/linux/kernel-patches/2.6.38/408-armadeus-add_apf51-dev_baseboard.patch
+++ b/buildroot/target/device/armadeus/linux/kernel-patches/2.6.38/408-armadeus-add_apf51-dev_baseboard.patch
@@ -4,8 +4,8 @@ Signed-off-by: Julien Boibessot <jul...@ar...>
Index: linux-2.6.38.1/arch/arm/mach-mx5/Kconfig
===================================================================
---- linux-2.6.38.1.orig/arch/arm/mach-mx5/Kconfig 2011-03-30 18:01:24.000000000 +0200
-+++ linux-2.6.38.1/arch/arm/mach-mx5/Kconfig 2011-03-30 18:33:48.000000000 +0200
+--- linux-2.6.38.1.orig/arch/arm/mach-mx5/Kconfig 2011-04-05 18:28:35.000000000 +0200
++++ linux-2.6.38.1/arch/arm/mach-mx5/Kconfig 2011-04-05 22:56:58.000000000 +0200
@@ -167,12 +167,32 @@
select SOC_IMX51
select IMX_HAVE_PLATFORM_IMX_UART
@@ -43,8 +43,8 @@ Index: linux-2.6.38.1/arch/arm/mach-mx5/Kconfig
endif
Index: linux-2.6.38.1/arch/arm/mach-mx5/Makefile
===================================================================
---- linux-2.6.38.1.orig/arch/arm/mach-mx5/Makefile 2011-03-30 18:01:24.000000000 +0200
-+++ linux-2.6.38.1/arch/arm/mach-mx5/Makefile 2011-03-30 18:33:48.000000000 +0200
+--- linux-2.6.38.1.orig/arch/arm/mach-mx5/Makefile 2011-04-05 18:28:35.000000000 +0200
++++ linux-2.6.38.1/arch/arm/mach-mx5/Makefile 2011-04-05 22:56:58.000000000 +0200
@@ -8,6 +8,7 @@
obj-$(CONFIG_CPU_FREQ_IMX) += cpu_op-mx51.o
@@ -56,8 +56,8 @@ Index: linux-2.6.38.1/arch/arm/mach-mx5/Makefile
Index: linux-2.6.38.1/arch/arm/mach-mx5/apf51dev-baseboard.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
-+++ linux-2.6.38.1/arch/arm/mach-mx5/apf51dev-baseboard.c 2011-03-30 18:33:36.000000000 +0200
-@@ -0,0 +1,478 @@
++++ linux-2.6.38.1/arch/arm/mach-mx5/apf51dev-baseboard.c 2011-04-05 23:04:25.000000000 +0200
+@@ -0,0 +1,481 @@
+ /*
+ * Support for APF51's official development baseboard (APF51Dev)
+ *
@@ -385,10 +385,13 @@ Index: linux-2.6.38.1/arch/arm/mach-mx5/apf51dev-baseboard.c
+
+#define ESDHC_CARD_DETECT (GPIO_PORTB | 29)
+static struct esdhc_platform_data edshc0_pdata = {
-+ .wp_gpio = 0, /* write protect pin */
+ .cd_gpio = ESDHC_CARD_DETECT, /* card detect pin */
+};
+
++static struct esdhc_platform_data edshc1_pdata = {
++ .no_sdio_irq = 1, /* Temporary ! (for Wi2Wi) */
++};
++
+static int init_gpio(void)
+{
+#define USER_LED_GPIO (GPIO_PORTA | 2)
@@ -502,7 +505,7 @@ Index: linux-2.6.38.1/arch/arm/mach-mx5/apf51dev-baseboard.c
+ init_gpio();
+
+ imx51_add_sdhci_esdhc_imx(0, &edshc0_pdata);
-+ imx51_add_sdhci_esdhc_imx(1, NULL);
++ imx51_add_sdhci_esdhc_imx(1, &edshc1_pdata);
+
+ spi_register_board_info(apf51dev_spi1_board_info,
+ ARRAY_SIZE(apf51dev_spi1_board_info));
diff --git a/buildroot/target/device/armadeus/linux/kernel-patches/2.6.38/420-armadeus-esdhc-add_gpio_SD_detection.patch b/buildroot/target/device/armadeus/linux/kernel-patches/2.6.38/420-armadeus-esdhc-add_gpio_SD_detection.patch
index 1cef100..d33c384 100644
--- a/buildroot/target/device/armadeus/linux/kernel-patches/2.6.38/420-armadeus-esdhc-add_gpio_SD_detection.patch
+++ b/buildroot/target/device/armadeus/linux/kernel-patches/2.6.38/420-armadeus-esdhc-add_gpio_SD_detection.patch
@@ -2,11 +2,11 @@ Add support for GPIO SD detection
Signed-off-by: Nicolas Colombain <nic...@ar...>
-Index: linux-2.6.38-rc3/drivers/mmc/host/sdhci-esdhc-imx.c
+Index: linux-2.6.38.1/drivers/mmc/host/sdhci-esdhc-imx.c
===================================================================
---- linux-2.6.38-rc3.orig/drivers/mmc/host/sdhci-esdhc-imx.c 2011-02-08 14:49:41.000000000 +0100
-+++ linux-2.6.38-rc3/drivers/mmc/host/sdhci-esdhc-imx.c 2011-02-08 15:09:30.000000000 +0100
-@@ -15,13 +15,40 @@
+--- linux-2.6.38.1.orig/drivers/mmc/host/sdhci-esdhc-imx.c 2011-03-30 18:33:47.000000000 +0200
++++ linux-2.6.38.1/drivers/mmc/host/sdhci-esdhc-imx.c 2011-04-05 18:11:27.000000000 +0200
+@@ -15,13 +15,41 @@
#include <linux/delay.h>
#include <linux/err.h>
#include <linux/clk.h>
@@ -14,6 +14,7 @@ Index: linux-2.6.38-rc3/drivers/mmc/host/sdhci-esdhc-imx.c
#include <linux/mmc/host.h>
#include <linux/mmc/sdhci-pltfm.h>
+#include <linux/platform_device.h>
++#include <linux/slab.h>
+#include <mach/esdhc.h>
#include <mach/hardware.h>
#include "sdhci.h"
@@ -47,7 +48,7 @@ Index: linux-2.6.38-rc3/drivers/mmc/host/sdhci-esdhc-imx.c
static inline void esdhc_clrset_le(struct sdhci_host *host, u32 mask, u32 val, int reg)
{
void __iomem *base = host->ioaddr + (reg & ~0x3);
-@@ -86,6 +113,13 @@ static void esdhc_writeb_le(struct sdhci
+@@ -86,6 +114,13 @@
esdhc_clrset_le(host, 0xff, val, reg);
}
@@ -61,54 +62,60 @@ Index: linux-2.6.38-rc3/drivers/mmc/host/sdhci-esdhc-imx.c
static unsigned int esdhc_pltfm_get_max_clock(struct sdhci_host *host)
{
struct sdhci_pltfm_host *pltfm_host = sdhci_priv(host);
-@@ -103,7 +137,39 @@ static unsigned int esdhc_pltfm_get_min_
+@@ -103,7 +138,42 @@
static int esdhc_pltfm_init(struct sdhci_host *host, struct sdhci_pltfm_data *pdata)
{
struct sdhci_pltfm_host *pltfm_host = sdhci_priv(host);
+ struct platform_device *pdev = to_platform_device(mmc_dev(host->mmc));
struct clk *clk;
-+ struct esdhc_platform_data *plat;
++ struct esdhc_platform_data *pdat;
+ int rc;
++ char *irq_name;
+
-+ plat = pdev->dev.platform_data;
++ pdat = pdev->dev.platform_data;
+
-+ if ((plat != NULL) && gpio_is_valid(plat->cd_gpio)) {
-+ host->quirks &= ~SDHCI_QUIRK_BROKEN_CARD_DETECTION;
++ if (pdat != NULL) {
++ if (pdat->cd_gpio && gpio_is_valid(pdat->cd_gpio)) {
++ rc = gpio_request(pdat->cd_gpio, "sdhci_cd");
++ if (rc) {
++ dev_err(mmc_dev(host->mmc),
++ "failed to allocate cd gpio\n");
++ goto out;
++ }
++ gpio_direction_input(pdat->cd_gpio);
+
-+ rc = gpio_request(plat->cd_gpio, "sdhci_cd");
-+ if (rc) {
-+ dev_err(mmc_dev(host->mmc),
-+ "failed to allocate cd gpio\n");
-+ goto out;
-+ }
-+ gpio_direction_input(plat->cd_gpio);
++ irq_name = kzalloc(16, GFP_KERNEL);
++ if (!irq_name) {
++ rc = -ENOMEM;
++ goto out_gpio;
++ }
++ snprintf(irq_name, 16, "%s-cd", mmc_hostname(host->mmc));
++ rc = request_irq(gpio_to_irq(pdat->cd_gpio), carddetect_irq,
++ IRQF_TRIGGER_FALLING | IRQF_TRIGGER_RISING,
++ irq_name, host);
+
-+ rc = request_irq(gpio_to_irq(plat->cd_gpio), carddetect_irq,
-+ IRQF_TRIGGER_FALLING | IRQF_TRIGGER_RISING,
-+ mmc_hostname(host->mmc), host);
++ if (rc) {
++ dev_err(mmc_dev(host->mmc), "request irq error\n");
++ goto out_alloc;
++ }
+
-+ if (rc) {
-+ dev_err(mmc_dev(host->mmc), "request irq error\n");
-+ goto out_cd;
-+ }
-+ }
-+ else {
-+ if (plat != NULL) {
-+ dev_err(mmc_dev(host->mmc), "wrong cd gpio in platform data\n");
-+ return -ENXIO;
++ host->quirks &= ~SDHCI_QUIRK_BROKEN_CARD_DETECTION;
+ }
+ }
clk = clk_get(mmc_dev(host->mmc), NULL);
if (IS_ERR(clk)) {
-@@ -121,17 +187,33 @@ static int esdhc_pltfm_init(struct sdhci
+@@ -121,17 +191,36 @@
host->quirks |= SDHCI_QUIRK_NO_MULTIBLOCK;
return 0;
+
-+out_cd:
-+ if (gpio_is_valid(plat->cd_gpio))
-+ gpio_free(plat->cd_gpio);
++out_alloc:
++ kfree(irq_name);
++
++out_gpio:
++ if (gpio_is_valid(pdat->cd_gpio))
++ gpio_free(pdat->cd_gpio);
+
+out:
+ return rc;
@@ -118,12 +125,12 @@ Index: linux-2.6.38-rc3/drivers/mmc/host/sdhci-esdhc-imx.c
{
struct sdhci_pltfm_host *pltfm_host = sdhci_priv(host);
+ struct platform_device *pdev = to_platform_device(mmc_dev(host->mmc));
-+ struct esdhc_platform_data *plat;
++ struct esdhc_platform_data *pdat;
+
-+ plat = pdev->dev.platform_data;
++ pdat = pdev->dev.platform_data;
+
-+ if (gpio_is_valid(plat->cd_gpio))
-+ gpio_free(plat->cd_gpio);
++ if (gpio_is_valid(pdat->cd_gpio))
++ gpio_free(pdat->cd_gpio);
clk_disable(pltfm_host->clk);
clk_put(pltfm_host->clk);
@@ -135,10 +142,10 @@ Index: linux-2.6.38-rc3/drivers/mmc/host/sdhci-esdhc-imx.c
.read_w = esdhc_readw_le,
.write_w = esdhc_writew_le,
.write_b = esdhc_writeb_le,
-Index: linux-2.6.38-rc3/drivers/mmc/host/sdhci-esdhc-imx.c
+Index: linux-2.6.38.1/arch/arm/plat-mxc/include/mach/esdhc.h
===================================================================
---- linux-2.6.38-rc3.orig/arch/arm/plat-mxc/include/mach/esdhc.h 2011-02-08 14:49:41.000000000 +0100
-+++ linux-2.6.38-rc3/arch/arm/plat-mxc/include/mach/esdhc.h 2011-02-08 15:09:30.000000000 +0100
+--- linux-2.6.38.1.orig/arch/arm/plat-mxc/include/mach/esdhc.h 2011-03-30 18:33:47.000000000 +0200
++++ linux-2.6.38.1/arch/arm/plat-mxc/include/mach/esdhc.h 2011-04-05 18:09:34.000000000 +0200
@@ -12,5 +12,6 @@
struct esdhc_platform_data {
diff --git a/buildroot/target/device/armadeus/linux/kernel-patches/2.6.38/427-armadeus-esdhc-imx-add_possibility_to_deactivate_SDIO_interrupt.patch b/buildroot/target/device/armadeus/linux/kernel-patches/2.6.38/427-armadeus-esdhc-imx-add_possibility_to_deactivate_SDIO_interrupt.patch
new file mode 100644
index 0000000..1102f8a
--- /dev/null
+++ b/buildroot/target/device/armadeus/linux/kernel-patches/2.6.38/427-armadeus-esdhc-imx-add_possibility_to_deactivate_SDIO_interrupt.patch
@@ -0,0 +1,56 @@
+Allows to deactivate SDIO interrupt usage.
+
+Signed-off-by: Julien Boibessot <jul...@ar...>
+
+Index: linux-2.6.38.1/include/linux/mmc/sdhci.h
+===================================================================
+--- linux-2.6.38.1.orig/include/linux/mmc/sdhci.h 2011-04-05 15:18:40.000000000 +0200
++++ linux-2.6.38.1/include/linux/mmc/sdhci.h 2011-04-05 15:19:26.000000000 +0200
+@@ -85,6 +85,8 @@
+ #define SDHCI_QUIRK_NO_HISPD_BIT (1<<29)
+ /* Controller treats ADMA descriptors with length 0000h incorrectly */
+ #define SDHCI_QUIRK_BROKEN_ADMA_ZEROLEN_DESC (1<<30)
++/* Controller do not handle SDIO interrupts correctly */
++#define SDHCI_QUIRK_NO_SDIO_IRQ (1<<31)
+
+ int irq; /* Device IRQ */
+ void __iomem *ioaddr; /* Mapped address */
+Index: linux-2.6.38.1/arch/arm/plat-mxc/include/mach/esdhc.h
+===================================================================
+--- linux-2.6.38.1.orig/arch/arm/plat-mxc/include/mach/esdhc.h 2011-04-05 15:18:40.000000000 +0200
++++ linux-2.6.38.1/arch/arm/plat-mxc/include/mach/esdhc.h 2011-04-05 15:19:26.000000000 +0200
+@@ -13,5 +13,6 @@
+ struct esdhc_platform_data {
+ unsigned int wp_gpio; /* write protect pin */
+ unsigned int cd_gpio; /* card detect pin */
++ unsigned int no_sdio_irq;
+ };
+ #endif /* __ASM_ARCH_IMX_ESDHC_H */
+Index: linux-2.6.38.1/drivers/mmc/host/sdhci-esdhc-imx.c
+===================================================================
+--- linux-2.6.38.1.orig/drivers/mmc/host/sdhci-esdhc-imx.c 2011-04-05 15:22:09.000000000 +0200
++++ linux-2.6.38.1/drivers/mmc/host/sdhci-esdhc-imx.c 2011-04-05 15:23:48.000000000 +0200
+@@ -165,6 +165,9 @@
+
+ host->quirks &= ~SDHCI_QUIRK_BROKEN_CARD_DETECTION;
+ }
++
++ if (pdat->no_sdio_irq)
++ host->quirks |= SDHCI_QUIRK_NO_SDIO_IRQ;
+ }
+
+ clk = clk_get(mmc_dev(host->mmc), NULL);
+Index: linux-2.6.38.1/drivers/mmc/host/sdhci.c
+===================================================================
+--- linux-2.6.38.1.orig/drivers/mmc/host/sdhci.c 2011-04-05 15:24:22.000000000 +0200
++++ linux-2.6.38.1/drivers/mmc/host/sdhci.c 2011-04-05 15:26:07.000000000 +0200
+@@ -1879,7 +1879,8 @@
+ mmc->f_min = host->max_clk / SDHCI_MAX_DIV_SPEC_200;
+
+ mmc->f_max = host->max_clk;
+- mmc->caps |= MMC_CAP_SDIO_IRQ;
++ if (!(host->quirks & SDHCI_QUIRK_NO_SDIO_IRQ))
++ mmc->caps |= MMC_CAP_SDIO_IRQ;
+
+ /*
+ * A controller may support 8-bit width, but the board itself
hooks/post-receive
--
armadeus
|