spi: Use SPI_BPW_MASK macro at appropriate places
authorAxel Lin <axel.lin@ingics.com>
Wed, 5 Feb 2014 13:59:18 +0000 (21:59 +0800)
committerMark Brown <broonie@linaro.org>
Fri, 7 Feb 2014 12:21:28 +0000 (12:21 +0000)
Signed-off-by: Axel Lin <axel.lin@ingics.com>
Signed-off-by: Mark Brown <broonie@linaro.org>
drivers/spi/spi-bfin-v3.c
drivers/spi/spi-ti-qspi.c

index 8f8598834b30d0831ed08e6711a3528994f6df58..4089d0e0d84ee62deee2ed25d5d2f12b5ba65687 100644 (file)
@@ -822,7 +822,8 @@ static int bfin_spi_probe(struct platform_device *pdev)
        master->cleanup = bfin_spi_cleanup;
        master->setup = bfin_spi_setup;
        master->transfer_one_message = bfin_spi_transfer_one_message;
-       master->bits_per_word_mask = BIT(32 - 1) | BIT(16 - 1) | BIT(8 - 1);
+       master->bits_per_word_mask = SPI_BPW_MASK(32) | SPI_BPW_MASK(16) |
+                                    SPI_BPW_MASK(8);
 
        drv_data = spi_master_get_devdata(master);
        drv_data->master = master;
index 3d09265b51335e2cefdf3d098ce177826b150674..7eb2cef739b6fa81324b1385e4646707d0c2a1b8 100644 (file)
@@ -435,7 +435,8 @@ static int ti_qspi_probe(struct platform_device *pdev)
        master->auto_runtime_pm = true;
        master->transfer_one_message = ti_qspi_start_transfer_one;
        master->dev.of_node = pdev->dev.of_node;
-       master->bits_per_word_mask = BIT(32 - 1) | BIT(16 - 1) | BIT(8 - 1);
+       master->bits_per_word_mask = SPI_BPW_MASK(32) | SPI_BPW_MASK(16) |
+                                    SPI_BPW_MASK(8);
 
        if (!of_property_read_u32(np, "num-cs", &num_cs))
                master->num_chipselect = num_cs;