summaryrefslogtreecommitdiff
path: root/multitech/recipes/linux
diff options
context:
space:
mode:
authorJesse Gilles <jgilles@multitech.com>2013-12-17 17:03:06 -0600
committerJesse Gilles <jgilles@multitech.com>2013-12-17 17:03:06 -0600
commite0f9f9f613468d12e7db37986c1bffec9f1bd8ea (patch)
treec06c0d55005623f7d873a7cfde48080858f2da46 /multitech/recipes/linux
parent692de808a4bc2d857b37b9e44154931de44fa810 (diff)
linux-2.6.39.4: mt100eocg-pcie-dk: add spidev devices
Diffstat (limited to 'multitech/recipes/linux')
-rw-r--r--multitech/recipes/linux/linux-2.6.39.4/mt100eocg-pcie-dk/defconfig2
-rw-r--r--multitech/recipes/linux/linux-2.6.39.4/mt100eocg-pcie-dk/linux-2.6.39.4-mach-at91-mt100eocg-pcie-dk.patch59
2 files changed, 39 insertions, 22 deletions
diff --git a/multitech/recipes/linux/linux-2.6.39.4/mt100eocg-pcie-dk/defconfig b/multitech/recipes/linux/linux-2.6.39.4/mt100eocg-pcie-dk/defconfig
index a3e1956..cab6b8f 100644
--- a/multitech/recipes/linux/linux-2.6.39.4/mt100eocg-pcie-dk/defconfig
+++ b/multitech/recipes/linux/linux-2.6.39.4/mt100eocg-pcie-dk/defconfig
@@ -1232,7 +1232,7 @@ CONFIG_SPI_ATMEL=y
#
# SPI Protocol Masters
#
-# CONFIG_SPI_SPIDEV is not set
+CONFIG_SPI_SPIDEV=m
# CONFIG_SPI_TLE62X0 is not set
#
diff --git a/multitech/recipes/linux/linux-2.6.39.4/mt100eocg-pcie-dk/linux-2.6.39.4-mach-at91-mt100eocg-pcie-dk.patch b/multitech/recipes/linux/linux-2.6.39.4/mt100eocg-pcie-dk/linux-2.6.39.4-mach-at91-mt100eocg-pcie-dk.patch
index 470c5be..710a331 100644
--- a/multitech/recipes/linux/linux-2.6.39.4/mt100eocg-pcie-dk/linux-2.6.39.4-mach-at91-mt100eocg-pcie-dk.patch
+++ b/multitech/recipes/linux/linux-2.6.39.4/mt100eocg-pcie-dk/linux-2.6.39.4-mach-at91-mt100eocg-pcie-dk.patch
@@ -1,7 +1,7 @@
Index: linux-2.6.39.4/arch/arm/mach-at91/at91sam9260_devices.c
===================================================================
--- linux-2.6.39.4.orig/arch/arm/mach-at91/at91sam9260_devices.c 2011-08-03 14:43:28.000000000 -0500
-+++ linux-2.6.39.4/arch/arm/mach-at91/at91sam9260_devices.c 2013-04-19 14:31:55.273588327 -0500
++++ linux-2.6.39.4/arch/arm/mach-at91/at91sam9260_devices.c 2013-12-16 12:04:12.888446547 -0600
@@ -183,9 +183,9 @@
at91_set_B_periph(AT91_PIN_PA25, 0); /* ERX2 */
at91_set_B_periph(AT91_PIN_PA26, 0); /* ERX3 */
@@ -35,7 +35,7 @@ Index: linux-2.6.39.4/arch/arm/mach-at91/at91sam9260_devices.c
Index: linux-2.6.39.4/arch/arm/mach-at91/board-sam9g20ek.c
===================================================================
--- linux-2.6.39.4.orig/arch/arm/mach-at91/board-sam9g20ek.c 2011-08-03 14:43:28.000000000 -0500
-+++ linux-2.6.39.4/arch/arm/mach-at91/board-sam9g20ek.c 2013-04-19 16:49:59.147306517 -0500
++++ linux-2.6.39.4/arch/arm/mach-at91/board-sam9g20ek.c 2013-12-17 15:17:39.304626743 -0600
@@ -30,6 +30,12 @@
#include <linux/regulator/machine.h>
#include <linux/regulator/fixed.h>
@@ -120,7 +120,7 @@ Index: linux-2.6.39.4/arch/arm/mach-at91/board-sam9g20ek.c
at91sam9260_init_interrupts(NULL);
}
-@@ -97,10 +151,37 @@
+@@ -97,11 +151,38 @@
* USB Device port
*/
static struct at91_udc_data __initdata ek_udc_data = {
@@ -128,9 +128,9 @@ Index: linux-2.6.39.4/arch/arm/mach-at91/board-sam9g20ek.c
- .pullup_pin = 0, /* pull-up driven by UDC */
+ .vbus_pin = AT91_PIN_PC12,
+ .pullup_pin = 0, /* pull-up driven by UDC */
-+};
-+
-+
+ };
+
+
+#define MTS_EXT_AT25_TEST 0
+#if MTS_EXT_AT25_TEST
+static struct spi_eeprom at25040b = {
@@ -149,27 +149,23 @@ Index: linux-2.6.39.4/arch/arm/mach-at91/board-sam9g20ek.c
+ .offset = 0x00000000,
+ .size = MTDPART_SIZ_FULL,
+ },
- };
-
++};
++
+static struct flash_platform_data m25_spi_flash_data = {
+ .type = "sst25vf080b",
+ .nr_parts = ARRAY_SIZE(m25_partitions),
+ .parts = m25_partitions,
+};
+#endif
-
++
/*
* SPI devices.
-@@ -122,6 +203,54 @@
+ */
+@@ -122,6 +203,70 @@
},
#endif
#endif
+ {
-+ .modalias = "mts-io-sout",
-+ .chip_select = 0,
-+ .bus_num = 1,
-+ },
-+ {
+ .modalias = "mts-io-board-temp",
+ .chip_select = 2,
+ .bus_num = 1,
@@ -184,6 +180,27 @@ Index: linux-2.6.39.4/arch/arm/mach-at91/board-sam9g20ek.c
+ .chip_select = 4,
+ .bus_num = 1,
+ },
++ /* max_speed_hz = 0 means as slow as possible
++ * for OCG, this means approx 520kHz
++ */
++ { /* SPI_CS5 to board-to-board connector */
++ .modalias = "spidev",
++ .chip_select = 5,
++ .max_speed_hz = 0,
++ .bus_num = 1,
++ },
++ { /* SPI_CS6 to board-to-board connector */
++ .modalias = "spidev",
++ .chip_select = 6,
++ .max_speed_hz = 0,
++ .bus_num = 1,
++ },
++ { /* SPI_CS7 to board-to-board connector (chip select 0 in board code) */
++ .modalias = "spidev",
++ .chip_select = 0,
++ .max_speed_hz = 0,
++ .bus_num = 1,
++ },
+#if MTS_EXT_AT25_TEST
+ {
+ .modalias = "at25",
@@ -215,7 +232,7 @@ Index: linux-2.6.39.4/arch/arm/mach-at91/board-sam9g20ek.c
};
-@@ -130,7 +259,7 @@
+@@ -130,7 +275,7 @@
*/
static struct at91_eth_data __initdata ek_macb_data = {
.phy_irq_pin = AT91_PIN_PA7,
@@ -224,7 +241,7 @@ Index: linux-2.6.39.4/arch/arm/mach-at91/board-sam9g20ek.c
};
static void __init ek_add_device_macb(void)
-@@ -146,18 +275,48 @@
+@@ -146,18 +291,48 @@
*/
static struct mtd_partition __initdata ek_nand_partition[] = {
{
@@ -281,7 +298,7 @@ Index: linux-2.6.39.4/arch/arm/mach-at91/board-sam9g20ek.c
.size = MTDPART_SIZ_FULL,
},
};
-@@ -228,10 +387,10 @@
+@@ -228,10 +403,10 @@
};
#else
@@ -293,7 +310,7 @@ Index: linux-2.6.39.4/arch/arm/mach-at91/board-sam9g20ek.c
};
#endif
-@@ -252,15 +411,10 @@
+@@ -252,15 +427,10 @@
* LEDs
*/
static struct gpio_led ek_leds[] = {
@@ -312,7 +329,7 @@ Index: linux-2.6.39.4/arch/arm/mach-at91/board-sam9g20ek.c
.default_trigger = "heartbeat",
}
};
-@@ -363,16 +517,60 @@
+@@ -363,16 +533,60 @@
static void __init ek_add_regulators(void) {}
#endif
@@ -379,7 +396,7 @@ Index: linux-2.6.39.4/arch/arm/mach-at91/board-sam9g20ek.c
static void __init ek_board_init(void)
{
-@@ -401,7 +599,22 @@
+@@ -401,7 +615,22 @@
/* PCK0 provides MCLK to the WM8731 */
at91_set_B_periph(AT91_PIN_PC1, 0);
/* SSC (for WM8731) */