diff options
author | LABBE Corentin <clabbe.montjoie@gmail.com> | 2016-08-16 12:50:20 +0300 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2016-08-16 14:26:59 +0300 |
commit | 94b968b5a3e282edbdf21735edbeb93a5a1fa119 (patch) | |
tree | 8dd141a56bb02370363ba2c9328aa19ed92ae04f /drivers/spi/spi-fsl-dspi.c | |
parent | 29b4817d4018df78086157ea3a55c1d9424a7cfc (diff) | |
download | linux-94b968b5a3e282edbdf21735edbeb93a5a1fa119.tar.xz |
spi: spi-fsl-dspi: constify devtype_data
of_id->data is const, so instead of casting the pointer to drop its
const status, this patch constify the devtype_data pointer.
Signed-off-by: LABBE Corentin <clabbe.montjoie@gmail.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'drivers/spi/spi-fsl-dspi.c')
-rw-r--r-- | drivers/spi/spi-fsl-dspi.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/spi/spi-fsl-dspi.c b/drivers/spi/spi-fsl-dspi.c index 9e9dadb52b3d..ab6b9e1f79a3 100644 --- a/drivers/spi/spi-fsl-dspi.c +++ b/drivers/spi/spi-fsl-dspi.c @@ -159,7 +159,7 @@ struct fsl_dspi { u8 cs; u16 void_write_data; u32 cs_change; - struct fsl_dspi_devtype_data *devtype_data; + const struct fsl_dspi_devtype_data *devtype_data; wait_queue_head_t waitq; u32 waitflags; @@ -686,7 +686,7 @@ static int dspi_probe(struct platform_device *pdev) } master->bus_num = bus_num; - dspi->devtype_data = (struct fsl_dspi_devtype_data *)of_id->data; + dspi->devtype_data = of_id->data; if (!dspi->devtype_data) { dev_err(&pdev->dev, "can't get devtype_data\n"); ret = -EFAULT; |