summaryrefslogtreecommitdiff
path: root/multitech/recipes/linux/linux-2.6.39-at91
diff options
context:
space:
mode:
Diffstat (limited to 'multitech/recipes/linux/linux-2.6.39-at91')
-rw-r--r--multitech/recipes/linux/linux-2.6.39-at91/mtocgd2/defconfig (renamed from multitech/recipes/linux/linux-2.6.39-at91/mtocgd3/defconfig)0
-rw-r--r--multitech/recipes/linux/linux-2.6.39-at91/mtocgd2/linux-2.6.39.4-macb-force-link.patch (renamed from multitech/recipes/linux/linux-2.6.39-at91/mtocgd3/linux-2.6.39.4-macb-force-link.patch)0
-rw-r--r--multitech/recipes/linux/linux-2.6.39-at91/mtocgd2/linux-2.6.39.4-mach-at91-mtocgd2.patch (renamed from multitech/recipes/linux/linux-2.6.39-at91/mtocgd3/linux-2.6.39.4-mach-at91-mtocgd3.patch)118
3 files changed, 75 insertions, 43 deletions
diff --git a/multitech/recipes/linux/linux-2.6.39-at91/mtocgd3/defconfig b/multitech/recipes/linux/linux-2.6.39-at91/mtocgd2/defconfig
index 04fb2d9..04fb2d9 100644
--- a/multitech/recipes/linux/linux-2.6.39-at91/mtocgd3/defconfig
+++ b/multitech/recipes/linux/linux-2.6.39-at91/mtocgd2/defconfig
diff --git a/multitech/recipes/linux/linux-2.6.39-at91/mtocgd3/linux-2.6.39.4-macb-force-link.patch b/multitech/recipes/linux/linux-2.6.39-at91/mtocgd2/linux-2.6.39.4-macb-force-link.patch
index 2ef39a9..2ef39a9 100644
--- a/multitech/recipes/linux/linux-2.6.39-at91/mtocgd3/linux-2.6.39.4-macb-force-link.patch
+++ b/multitech/recipes/linux/linux-2.6.39-at91/mtocgd2/linux-2.6.39.4-macb-force-link.patch
diff --git a/multitech/recipes/linux/linux-2.6.39-at91/mtocgd3/linux-2.6.39.4-mach-at91-mtocgd3.patch b/multitech/recipes/linux/linux-2.6.39-at91/mtocgd2/linux-2.6.39.4-mach-at91-mtocgd2.patch
index 4e35e85..c61237e 100644
--- a/multitech/recipes/linux/linux-2.6.39-at91/mtocgd3/linux-2.6.39.4-mach-at91-mtocgd3.patch
+++ b/multitech/recipes/linux/linux-2.6.39-at91/mtocgd2/linux-2.6.39.4-mach-at91-mtocgd2.patch
@@ -1,7 +1,7 @@
Index: git/arch/arm/mach-at91/board-sam9x5cm.c
===================================================================
---- git.orig/arch/arm/mach-at91/board-sam9x5cm.c 2013-04-17 17:15:13.000000000 -0500
-+++ git/arch/arm/mach-at91/board-sam9x5cm.c 2013-11-05 17:25:46.511692620 -0600
+--- git.orig/arch/arm/mach-at91/board-sam9x5cm.c 2013-12-27 14:27:13.000000000 -0600
++++ git/arch/arm/mach-at91/board-sam9x5cm.c 2014-02-06 16:31:32.817405456 -0600
@@ -18,6 +18,9 @@
#include <linux/platform_device.h>
#include <linux/spi/flash.h>
@@ -26,18 +26,18 @@ Index: git/arch/arm/mach-at91/board-sam9x5cm.c
+ .chip_select = 1,
+ .bus_num = 1,
+ },
-+ { /* SPI1_NCS3 to daughter card */
-+ .modalias = "spidev",
++ { /* SPI1_NCS3 to daughter card analog inputs */
++ .modalias = "mts-io-dc-adc",
+ .chip_select = 2,
+ .bus_num = 1,
+ },
-+ { /* SPI1_NCS4 to daughter card */
-+ .modalias = "spidev",
++ { /* SPI1_NCS4 to daughter card digital inputs */
++ .modalias = "mts-io-dc-din",
+ .chip_select = 3,
+ .bus_num = 1,
+ },
-+ { /* SPI1_NCS5 to daughter card */
-+ .modalias = "spidev",
++ { /* SPI1_NCS5 to daughter card digital outputs */
++ .modalias = "mts-io-dc-dout",
+ .chip_select = 4,
+ .bus_num = 1,
+ },
@@ -68,10 +68,8 @@ Index: git/arch/arm/mach-at91/board-sam9x5cm.c
+ .name = "UBoot Config",
+ .offset = 768*1024,
+ .size = 640*1024,
- },
- {
-- .name = "Partition 2",
-- .offset = MTDPART_OFS_NXTBLK,
++ },
++ {
+ .name = "UBoot Redundant Config",
+ .offset = 1408*1024,
+ .size = 640*1024,
@@ -90,8 +88,10 @@ Index: git/arch/arm/mach-at91/board-sam9x5cm.c
+ .name = "Oem Config",
+ .offset = 16*1024*1024,
+ .size = 8*1024*1024,
-+ },
-+ {
+ },
+ {
+- .name = "Partition 2",
+- .offset = MTDPART_OFS_NXTBLK,
+ .name = "Rootfs",
+ .offset = 24*1024*1024,
.size = MTDPART_SIZ_FULL,
@@ -102,7 +102,7 @@ Index: git/arch/arm/mach-at91/board-sam9x5cm.c
.ecc_mode = NAND_ECC_HW,
.has_pmecc = 1,
- .pmecc_corr_cap = 2,
-+// MTOCGD3: 4-bit PMECC
++// MTOCGD2: 4-bit PMECC
+ .pmecc_corr_cap = 4,
.pmecc_sector_size = 512,
.pmecc_lookup_table_offset = 0x8000,
@@ -111,11 +111,11 @@ Index: git/arch/arm/mach-at91/board-sam9x5cm.c
else
cm_nand_smc_config.mode |= AT91_SMC_DBW_8;
-+ // MTOCGD3 Rev B
++ // MTOCGD2 Rev B
+ cm_nand_data.bus_on_d0 = 0;
+ cm_nand_data.rdy_pin = AT91_PIN_PC31;
+
-+ // MTOCGD3: disable
++ // MTOCGD2: disable
/* revision of board modify NAND wiring */
+ /*
if (cm_is_revA()) {
@@ -129,7 +129,7 @@ Index: git/arch/arm/mach-at91/board-sam9x5cm.c
/* configure chip-select 3 (NAND) */
sam9_smc_configure(3, &cm_nand_smc_config);
-@@ -189,17 +260,62 @@
+@@ -189,17 +260,90 @@
* LEDs
*/
static struct gpio_led cm_leds[] = {
@@ -156,7 +156,7 @@ Index: git/arch/arm/mach-at91/board-sam9x5cm.c
+ .name = "led-c",
+ .gpio = AT91_PIN_PA25,
+ .active_low = 1
- },
++ },
+ {
+ .name = "led-d",
+ .gpio = AT91_PIN_PA26,
@@ -166,7 +166,7 @@ Index: git/arch/arm/mach-at91/board-sam9x5cm.c
+ .name = "led-e",
+ .gpio = AT91_PIN_PA27,
+ .active_low = 1
-+ },
+ },
+ {
+ .name = "led-f",
+ .gpio = AT91_PIN_PA28,
@@ -176,9 +176,14 @@ Index: git/arch/arm/mach-at91/board-sam9x5cm.c
+
+
+uint8_t mts_id_eeprom[512];
++uint8_t mts_dc_eeprom[512];
+
+EXPORT_SYMBOL(mts_id_eeprom);
++EXPORT_SYMBOL(mts_dc_eeprom);
+
++/*
++ * On-board EEPROM
++ */
+static void mts_id_eeprom_load(struct memory_accessor *macc, void *context)
+{
+ int tmp;
@@ -197,26 +202,53 @@ Index: git/arch/arm/mach-at91/board-sam9x5cm.c
+ .byte_len = SZ_4K / 8,
+ .page_size = 16,
+ .setup = mts_id_eeprom_load,
++};
++
++/*
++ * Daughter card EEPROM
++ */
++static void mts_dc_eeprom_load(struct memory_accessor *macc, void *context)
++{
++ int tmp;
++
++ memset(mts_dc_eeprom, 0, sizeof(mts_id_eeprom));
++
++ tmp = macc->read(macc, mts_dc_eeprom, 0, sizeof(mts_dc_eeprom));
++ if (tmp != sizeof(mts_dc_eeprom)) {
++ printk(KERN_INFO "sam9x5: dc eeprom read failed: %d\n", tmp);
++ } else {
++ printk(KERN_INFO "sam9x5: read %d bytes from dc eeprom\n", tmp);
++ }
++}
++
++static struct at24_platform_data dc_data = {
++ .byte_len = SZ_4K / 8,
++ .page_size = 16,
++ .setup = mts_dc_eeprom_load,
};
/*
-@@ -207,7 +323,8 @@
+@@ -207,7 +351,12 @@
*/
static struct i2c_board_info __initdata cm_i2c_devices[] = {
{
- I2C_BOARD_INFO("24c512", 0x50)
+ I2C_BOARD_INFO("24c04", 0x56),
+ .platform_data = &at24c04_data,
++ },
++ {
++ I2C_BOARD_INFO("24c04", 0x50),
++ .platform_data = &dc_data,
},
};
-@@ -234,8 +351,12 @@
+@@ -234,8 +383,12 @@
/* LEDs */
at91_gpio_leds(cm_leds, ARRAY_SIZE(cm_leds));
-+ printk(KERN_CRIT "AT91: MTOCGD3 board\n");
++ printk(KERN_CRIT "AT91: MTOCGD2 board\n");
+
-+ /* MTOCGD3: disable
++ /* MTOCGD2: disable
if (cm_is_revA())
printk(KERN_CRIT "AT91: CM rev A\n");
else
@@ -225,8 +257,8 @@ Index: git/arch/arm/mach-at91/board-sam9x5cm.c
}
Index: git/arch/arm/mach-at91/board-sam9x5ek.c
===================================================================
---- git.orig/arch/arm/mach-at91/board-sam9x5ek.c 2013-04-17 17:15:13.000000000 -0500
-+++ git/arch/arm/mach-at91/board-sam9x5ek.c 2013-11-01 12:16:09.080917828 -0500
+--- git.orig/arch/arm/mach-at91/board-sam9x5ek.c 2013-12-27 14:27:13.000000000 -0600
++++ git/arch/arm/mach-at91/board-sam9x5ek.c 2014-02-06 15:18:45.409321681 -0600
@@ -23,6 +23,7 @@
#include <linux/leds.h>
#include <linux/clk.h>
@@ -245,9 +277,9 @@ Index: git/arch/arm/mach-at91/board-sam9x5ek.c
- at91_register_uart(AT91SAM9X5_ID_USART1, 2, 0);
- /* USART2 on ttyS3. (Rx, Tx) */
- at91_register_uart(AT91SAM9X5_ID_USART2, 3, 0);
-+ // MTOCGD3: GPS on UART0 as ttyS1 with Rx/Tx only
++ // MTOCGD2: GPS on UART0 as ttyS1 with Rx/Tx only
+ at91_register_uart(AT91SAM9X5_ID_UART0, 1, 0);
-+ // MTOCGD3 Rev A: Daughter card serial on USART1 as ttyS2 with RTS/CTS
++ // MTOCGD2 Rev A: Daughter card serial on USART1 as ttyS2 with RTS/CTS
+ at91_register_uart(AT91SAM9X5_ID_USART1, 2, ATMEL_UART_CTS | ATMEL_UART_RTS);
}
@@ -261,7 +293,7 @@ Index: git/arch/arm/mach-at91/board-sam9x5ek.c
+ .phy_irq_pin = 0,
};
-+/* MTOCGD3: no macb1
++/* MTOCGD2: no macb1
static struct at91_eth_data __initdata ek_macb1_data = {
.phy_irq_pin = AT91_PIN_PC26,
.is_rmii = 1,
@@ -273,7 +305,7 @@ Index: git/arch/arm/mach-at91/board-sam9x5ek.c
* MCI (SD/MMC)
*/
-/* mci0 detect_pin is revision dependent */
-+// MTOCGD3: MCI0 is BT/Wifi
++// MTOCGD2: MCI0 is BT/Wifi
static struct mci_platform_data __initdata mci0_data = {
.slot[0] = {
.bus_width = 4,
@@ -282,7 +314,7 @@ Index: git/arch/arm/mach-at91/board-sam9x5ek.c
},
};
-+// MTOCGD3: MCI1 is SD card slot
++// MTOCGD2: MCI1 is SD card slot
static struct mci_platform_data __initdata mci1_data = {
.slot[0] = {
.bus_width = 4,
@@ -339,7 +371,7 @@ Index: git/arch/arm/mach-at91/board-sam9x5ek.c
cm_board_init(&cm_config);
- ek_board_configure_pins();
-+ // MTOCGD3: disable
++ // MTOCGD2: disable
+ //ek_board_configure_pins();
/* Serial */
at91_add_device_serial();
@@ -347,16 +379,16 @@ Index: git/arch/arm/mach-at91/board-sam9x5ek.c
at91_add_device_usbh_ohci(&ek_usbh_fs_data);
at91_add_device_usbh_ehci(&ek_usbh_hs_data);
/* USB HS Device */
-+ // MTOCGD3: set usb device vcc pin
++ // MTOCGD2: set usb device vcc pin
+ ek_usba_udc_data.vbus_pin = AT91_PIN_PC7;
at91_add_device_usba(&ek_usba_udc_data);
/* Ethernet */
at91_add_device_eth(0, &ek_macb0_data);
-+ /* MTOCGD3: no macb1
++ /* MTOCGD2: no macb1
at91_add_device_eth(1, &ek_macb1_data);
+ */
/* MMC0 */
-+ // MTOCGD3: MCI0 for BT/Wifi
++ // MTOCGD2: MCI0 for BT/Wifi
at91_add_device_mci(0, &mci0_data);
/* I2C */
if (cm_config & CM_CONFIG_I2C0_ENABLE)
@@ -364,14 +396,14 @@ Index: git/arch/arm/mach-at91/board-sam9x5ek.c
at91_add_device_i2c(0,
ek_i2c_devices, ARRAY_SIZE(ek_i2c_devices));
-+ // MTOCGD3: Wi-fi
++ // MTOCGD2: Wi-fi
+ at91_set_gpio_input(mtr_wlan_data.irq, 0);
+ at91_set_deglitch(mtr_wlan_data.irq, 1);
+
+ if (wl12xx_set_platform_data(&mtr_wlan_data))
+ pr_err("error setting wl12xx data\n");
+
-+/* MTOCGD3: no LCD */
++/* MTOCGD2: no LCD */
+#if 0
if (cpu_is_at91sam9g25()) {
/* ISI */
@@ -388,7 +420,7 @@ Index: git/arch/arm/mach-at91/board-sam9x5ek.c
- */
- if (!(cm_config & CM_CONFIG_SPI0_ENABLE) && !config_isi_enabled)
- at91_add_device_mci(1, &mci1_data);
-+ // MTOCGD3: MCI1 to SD Card
++ // MTOCGD2: MCI1 to SD Card
+ at91_add_device_mci(1, &mci1_data);
#if 0
@@ -397,7 +429,7 @@ Index: git/arch/arm/mach-at91/board-sam9x5ek.c
at91_add_device_can(0, NULL);
#endif
-+/* MTOCGD3: disable things we don't have */
++/* MTOCGD2: disable things we don't have */
+#if 0
if (cpu_is_at91sam9x25() || cpu_is_at91sam9x35())
/* this conflicts with usart.1 */
@@ -408,14 +440,14 @@ Index: git/arch/arm/mach-at91/board-sam9x5ek.c
"AT91: ISI conficts with MCI1, disable MCI1\n");
+#endif
+
-+ printk(KERN_CRIT "AT91: MTOCGD3 board EK init\n");
++ printk(KERN_CRIT "AT91: MTOCGD2 board EK init\n");
}
MACHINE_START(AT91SAM9X5EK, "Atmel AT91SAM9X5-EK")
Index: git/arch/arm/mach-at91/at91sam9x5_devices.c
===================================================================
---- git.orig/arch/arm/mach-at91/at91sam9x5_devices.c 2013-04-17 17:15:13.000000000 -0500
-+++ git/arch/arm/mach-at91/at91sam9x5_devices.c 2013-11-01 12:16:09.080917828 -0500
+--- git.orig/arch/arm/mach-at91/at91sam9x5_devices.c 2013-12-27 14:27:13.000000000 -0600
++++ git/arch/arm/mach-at91/at91sam9x5_devices.c 2014-02-06 15:18:45.409321681 -0600
@@ -543,11 +543,11 @@
#endif
@@ -435,7 +467,7 @@ Index: git/arch/arm/mach-at91/at91sam9x5_devices.c
};
-static const unsigned spi1_standard_cs[4] = { AT91_PIN_PA8, AT91_PIN_PA0, AT91_PIN_PA31, AT91_PIN_PA30 };
-+// MTOCGD3: SPI1 chip selects on pins SPI1_NCS1 to SPI1_NCS5
++// MTOCGD2: SPI1 chip selects on pins SPI1_NCS1 to SPI1_NCS5
+static const unsigned spi1_standard_cs[5] = { AT91_PIN_PC15, AT91_PIN_PC16, AT91_PIN_PC17, AT91_PIN_PC18, AT91_PIN_PC19 };
void __init at91_add_device_spi(struct spi_board_info *devices, int nr_devices)