]> rtime.felk.cvut.cz Git - lisovros/linux_canprio.git/commitdiff
Blackfin: boards: fix num_chipselect values for on-chip SPI buses
authorMike Frysinger <vapier@gentoo.org>
Wed, 16 Jun 2010 19:29:51 +0000 (19:29 +0000)
committerMike Frysinger <vapier@gentoo.org>
Fri, 22 Oct 2010 07:48:52 +0000 (03:48 -0400)
The num_chipselect field for on-chip Blackfin SPI buses is supposed to
be 1 larger than the number of actual CSs available.  This is because
the hardware starts counting at 1 and not 0.  There is a field for "CS0",
but it is marked as "reserved" everywhere.

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
arch/blackfin/mach-bf518/boards/ezbrd.c
arch/blackfin/mach-bf518/boards/tcm-bf518.c
arch/blackfin/mach-bf538/boards/ezkit.c
arch/blackfin/mach-bf548/boards/cm_bf548.c
arch/blackfin/mach-bf548/boards/ezkit.c

index 44d6d5299022dbba305e8b83b8fa21c5c664dfd7..46cb5d410b621e590e805165632a0da5ddc88c4f 100644 (file)
@@ -312,7 +312,7 @@ static struct spi_board_info bfin_spi_board_info[] __initdata = {
 #if defined(CONFIG_SPI_BFIN) || defined(CONFIG_SPI_BFIN_MODULE)
 /* SPI (0) */
 static struct bfin5xx_spi_master bfin_spi0_info = {
-       .num_chipselect = 5,
+       .num_chipselect = 6,
        .enable_dma = 1,  /* master has the ability to do dma transfer */
        .pin_req = {P_SPI0_SCK, P_SPI0_MISO, P_SPI0_MOSI, 0},
 };
@@ -347,7 +347,7 @@ static struct platform_device bfin_spi0_device = {
 
 /* SPI (1) */
 static struct bfin5xx_spi_master bfin_spi1_info = {
-       .num_chipselect = 5,
+       .num_chipselect = 6,
        .enable_dma = 1,  /* master has the ability to do dma transfer */
        .pin_req = {P_SPI1_SCK, P_SPI1_MISO, P_SPI1_MOSI, 0},
 };
index 9b72e5cb21fe6c1905913e37e27ffec613ee10ff..bead810a6546d1172270a5988e7494788246a3fa 100644 (file)
@@ -291,7 +291,7 @@ static struct platform_device bfin_spi0_device = {
 
 /* SPI (1) */
 static struct bfin5xx_spi_master bfin_spi1_info = {
-       .num_chipselect = 5,
+       .num_chipselect = 6,
        .enable_dma = 1,  /* master has the ability to do dma transfer */
        .pin_req = {P_SPI1_SCK, P_SPI1_MISO, P_SPI1_MOSI, 0},
 };
index 1a1f65855b033843530b441979eaae90a1490e85..c6fb0a52f8492b8725f809d4a2631e691b16c230 100644 (file)
@@ -695,7 +695,7 @@ static struct platform_device bf538_spi_master0 = {
 };
 
 static struct bfin5xx_spi_master bf538_spi_master_info1 = {
-       .num_chipselect = 8,
+       .num_chipselect = 2,
        .enable_dma = 1,  /* master has the ability to do dma transfer */
        .pin_req = {P_SPI1_SCK, P_SPI1_MISO, P_SPI1_MOSI, 0},
 };
@@ -711,7 +711,7 @@ static struct platform_device bf538_spi_master1 = {
 };
 
 static struct bfin5xx_spi_master bf538_spi_master_info2 = {
-       .num_chipselect = 8,
+       .num_chipselect = 2,
        .enable_dma = 1,  /* master has the ability to do dma transfer */
        .pin_req = {P_SPI2_SCK, P_SPI2_MISO, P_SPI2_MOSI, 0},
 };
index 6162833167e9a712952182cd7f313c6937187230..f0c0eef95ba85b82093c7d0d1c48ace6debd1d71 100644 (file)
@@ -966,7 +966,7 @@ static struct resource bfin_spi1_resource[] = {
 
 /* SPI controller data */
 static struct bfin5xx_spi_master bf54x_spi_master_info0 = {
-       .num_chipselect = 3,
+       .num_chipselect = 4,
        .enable_dma = 1,  /* master has the ability to do dma transfer */
        .pin_req = {P_SPI0_SCK, P_SPI0_MISO, P_SPI0_MOSI, 0},
 };
@@ -982,7 +982,7 @@ static struct platform_device bf54x_spi_master0 = {
 };
 
 static struct bfin5xx_spi_master bf54x_spi_master_info1 = {
-       .num_chipselect = 3,
+       .num_chipselect = 4,
        .enable_dma = 1,  /* master has the ability to do dma transfer */
        .pin_req = {P_SPI1_SCK, P_SPI1_MISO, P_SPI1_MOSI, 0},
 };
index 176d56394f1b4ba44b07fe9cb4776e67c0c50ec3..f4885418ac8f3aa5bd6d17032ca9f364eb30c385 100644 (file)
@@ -1107,7 +1107,7 @@ static struct resource bfin_spi1_resource[] = {
 
 /* SPI controller data */
 static struct bfin5xx_spi_master bf54x_spi_master_info0 = {
-       .num_chipselect = 3,
+       .num_chipselect = 4,
        .enable_dma = 1,  /* master has the ability to do dma transfer */
        .pin_req = {P_SPI0_SCK, P_SPI0_MISO, P_SPI0_MOSI, 0},
 };
@@ -1123,7 +1123,7 @@ static struct platform_device bf54x_spi_master0 = {
 };
 
 static struct bfin5xx_spi_master bf54x_spi_master_info1 = {
-       .num_chipselect = 3,
+       .num_chipselect = 4,
        .enable_dma = 1,  /* master has the ability to do dma transfer */
        .pin_req = {P_SPI1_SCK, P_SPI1_MISO, P_SPI1_MOSI, 0},
 };