]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - drivers/spi/mpc52xx_psc_spi.c
Merge branch 'for-2.6.25' of master.kernel.org:/pub/scm/linux/kernel/git/galak/powerp...
[linux-2.6-omap-h63xx.git] / drivers / spi / mpc52xx_psc_spi.c
index d2a4b2bdb07b6cbae5f2a4b4d51727a813ed2596..d398c93195e6c8cf17f9d3c607f48cd7db090fd7 100644 (file)
@@ -181,7 +181,7 @@ static int mpc52xx_psc_spi_transfer_rxtx(struct spi_device *spi,
                }
 
 
-               /* enable interupts and wait for wake up
+               /* enable interrupts and wait for wake up
                 * if just one byte is expected the Rx FIFO genererates no
                 * FFULL interrupt, so activate the RxRDY interrupt
                 */
@@ -330,6 +330,7 @@ static void mpc52xx_psc_spi_cleanup(struct spi_device *spi)
 
 static int mpc52xx_psc_spi_port_config(int psc_id, struct mpc52xx_psc_spi *mps)
 {
+       struct device_node *np;
        struct mpc52xx_cdm __iomem *cdm;
        struct mpc52xx_gpio __iomem *gpio;
        struct mpc52xx_psc __iomem *psc = mps->psc;
@@ -338,8 +339,12 @@ static int mpc52xx_psc_spi_port_config(int psc_id, struct mpc52xx_psc_spi *mps)
        int ret = 0;
 
 #if defined(CONFIG_PPC_MERGE)
-       cdm = mpc52xx_find_and_map("mpc5200-cdm");
-       gpio = mpc52xx_find_and_map("mpc5200-gpio");
+       np = of_find_compatible_node(NULL, NULL, "mpc5200-cdm");
+       cdm = of_iomap(np, 0);
+       of_node_put(np);
+       np = of_find_compatible_node(NULL, NULL, "mpc5200-gpio");
+       gpio = of_iomap(np, 0);
+       of_node_put(np);
 #else
        cdm = ioremap(MPC52xx_PA(MPC52xx_CDM_OFFSET), MPC52xx_CDM_SIZE);
        gpio = ioremap(MPC52xx_PA(MPC52xx_GPIO_OFFSET), MPC52xx_GPIO_SIZE);
@@ -503,7 +508,7 @@ static int __init mpc52xx_psc_spi_do_probe(struct device *dev, u32 regaddr,
        INIT_LIST_HEAD(&mps->queue);
 
        mps->workqueue = create_singlethread_workqueue(
-               master->cdev.dev->bus_id);
+               master->dev.parent->bus_id);
        if (mps->workqueue == NULL) {
                ret = -EBUSY;
                goto free_irq;