Merge remote-tracking branches 'spi/topic/devprop', 'spi/topic/fsl', 'spi/topic/fsl...
[sfrench/cifs-2.6.git] / include / linux / spi / spi.h
index 75c6bd0ac605b2024509985214cdc3d451c6ab53..805878d61a8f0e77e8a34332e2093d1144420d24 100644 (file)
@@ -23,6 +23,7 @@
 #include <linux/scatterlist.h>
 
 struct dma_chan;
+struct property_entry;
 struct spi_master;
 struct spi_transfer;
 struct spi_flash_read_message;
@@ -891,7 +892,7 @@ static inline struct spi_message *spi_message_alloc(unsigned ntrans, gfp_t flags
                unsigned i;
                struct spi_transfer *t = (struct spi_transfer *)(m + 1);
 
-               INIT_LIST_HEAD(&m->transfers);
+               spi_message_init_no_memset(m);
                for (i = 0; i < ntrans; i++, t++)
                        spi_message_add_tail(t, m);
        }
@@ -1209,6 +1210,7 @@ int spi_flash_read(struct spi_device *spi,
  * @modalias: Initializes spi_device.modalias; identifies the driver.
  * @platform_data: Initializes spi_device.platform_data; the particular
  *     data stored there is driver-specific.
+ * @properties: Additional device properties for the device.
  * @controller_data: Initializes spi_device.controller_data; some
  *     controllers need hints about hardware setup, e.g. for DMA.
  * @irq: Initializes spi_device.irq; depends on how the board is wired.
@@ -1241,10 +1243,12 @@ struct spi_board_info {
         *
         * platform_data goes to spi_device.dev.platform_data,
         * controller_data goes to spi_device.controller_data,
+        * device properties are copied and attached to spi_device,
         * irq is copied too
         */
        char            modalias[SPI_NAME_SIZE];
        const void      *platform_data;
+       const struct property_entry *properties;
        void            *controller_data;
        int             irq;