of: Always use 'struct device.of_node' to get device node pointer.
[safe/jmp/linux-2.6] / drivers / spi / xilinx_spi_of.c
index 151aa13..748d33a 100644 (file)
@@ -27,6 +27,7 @@
 #include <linux/init.h>
 #include <linux/interrupt.h>
 #include <linux/io.h>
+#include <linux/slab.h>
 
 #include <linux/of_platform.h>
 #include <linux/of_device.h>
@@ -72,6 +73,7 @@ static int __devinit xilinx_spi_of_probe(struct of_device *ofdev,
                return -EINVAL;
        }
        pdata->num_chipselect = *prop;
+       pdata->bits_per_word = 8;
        master = xilinx_spi_init(&ofdev->dev, &r_mem, r_irq.start, -1);
        if (!master)
                return -ENODEV;
@@ -98,7 +100,7 @@ static int __exit xilinx_spi_of_remove(struct of_device *op)
        return xilinx_spi_remove(op);
 }
 
-static struct of_device_id xilinx_spi_of_match[] = {
+static const struct of_device_id xilinx_spi_of_match[] = {
        { .compatible = "xlnx,xps-spi-2.00.a", },
        { .compatible = "xlnx,xps-spi-2.00.b", },
        {}