powerpc: Fix build of some FSL platforms
authorBenjamin Herrenschmidt <benh@kernel.crashing.org>
Tue, 24 Nov 2009 05:06:48 +0000 (16:06 +1100)
committerBenjamin Herrenschmidt <benh@kernel.crashing.org>
Tue, 24 Nov 2009 06:00:27 +0000 (17:00 +1100)
Commit 87ec0e98cfdd8b68da6a7f9e70142ffc0e404fbb in kumar's next branch
broke one of my test configs since it looks like Anton forgot about
that mpc832x_rdb platform which still uses the old style probing for
the SPI stuff.

I'll let them do a cleaner fix that probably involves changing the
probing method and getting rid of the platform device but for now
this will do to fix it.

Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
arch/powerpc/platforms/83xx/mpc832x_rdb.c
drivers/spi/spi_mpc8xxx.c
include/linux/fsl_devices.h

index 567ded7..17f9974 100644 (file)
@@ -74,7 +74,7 @@ static int __init of_fsl_spi_probe(char *type, char *compatible, u32 sysclk,
 
                prop = of_get_property(np, "mode", NULL);
                if (prop && !strcmp(prop, "cpu-qe"))
-                       pdata.qe_mode = 1;
+                       pdata.flags = SPI_QE_CPU_MODE;
 
                for (j = 0; j < num_board_infos; j++) {
                        if (board_infos[j].bus_num == pdata.bus_num)
index 394b658..930135d 100644 (file)
@@ -163,11 +163,6 @@ struct mpc8xxx_spi {
        u32 tx_shift;           /* TX data reg shift when in qe mode */
 
        unsigned int flags;
-#define SPI_QE_CPU_MODE                (1 << 0) /* QE CPU ("PIO") mode */
-#define SPI_CPM_MODE           (1 << 1) /* CPM/QE ("DMA") mode */
-#define SPI_CPM1               (1 << 2) /* SPI unit is in CPM1 block */
-#define SPI_CPM2               (1 << 3) /* SPI unit is in CPM2 block */
-#define SPI_QE                 (1 << 4) /* SPI unit is in QE block */
 
        struct workqueue_struct *workqueue;
        struct work_struct work;
index 47188d5..28e33fe 100644 (file)
@@ -75,6 +75,11 @@ struct fsl_spi_platform_data {
        u32     initial_spmode; /* initial SPMODE value */
        s16     bus_num;
        unsigned int flags;
+#define SPI_QE_CPU_MODE                (1 << 0) /* QE CPU ("PIO") mode */
+#define SPI_CPM_MODE           (1 << 1) /* CPM/QE ("DMA") mode */
+#define SPI_CPM1               (1 << 2) /* SPI unit is in CPM1 block */
+#define SPI_CPM2               (1 << 3) /* SPI unit is in CPM2 block */
+#define SPI_QE                 (1 << 4) /* SPI unit is in QE block */
        /* board specific information */
        u16     max_chipselect;
        void    (*cs_control)(struct spi_device *spi, bool on);