diff options
author | 2021-04-13 12:57:13 +0200 | |
---|---|---|
committer | 2021-06-08 13:06:41 +0200 | |
commit | d51470069eb169d54f2b14d07d613b69f62615b8 (patch) | |
tree | a9d2123545d99007eae9c13652aaf1d71836c60e /drivers/media/platform/atmel/atmel-sama5d2-isc.c | |
parent | media: atmel: atmel-isc: add DMA to register offsets (diff) | |
download | linux-dev-d51470069eb169d54f2b14d07d613b69f62615b8.tar.xz linux-dev-d51470069eb169d54f2b14d07d613b69f62615b8.zip |
media: atmel: atmel-isc: add support for version register
Add support for version register and print it at probe time.
Signed-off-by: Eugen Hristev <eugen.hristev@microchip.com>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Diffstat (limited to 'drivers/media/platform/atmel/atmel-sama5d2-isc.c')
-rw-r--r-- | drivers/media/platform/atmel/atmel-sama5d2-isc.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/media/platform/atmel/atmel-sama5d2-isc.c b/drivers/media/platform/atmel/atmel-sama5d2-isc.c index 0b31dcf1443b..059dc5d3c664 100644 --- a/drivers/media/platform/atmel/atmel-sama5d2-isc.c +++ b/drivers/media/platform/atmel/atmel-sama5d2-isc.c @@ -189,6 +189,7 @@ static int atmel_isc_probe(struct platform_device *pdev) struct isc_subdev_entity *subdev_entity; int irq; int ret; + u32 ver; isc = devm_kzalloc(dev, sizeof(*isc), GFP_KERNEL); if (!isc) @@ -237,6 +238,7 @@ static int atmel_isc_probe(struct platform_device *pdev) isc->offsets.rlp = ISC_SAMA5D2_RLP_OFFSET; isc->offsets.his = ISC_SAMA5D2_HIS_OFFSET; isc->offsets.dma = ISC_SAMA5D2_DMA_OFFSET; + isc->offsets.version = ISC_SAMA5D2_VERSION_OFFSET; /* sama5d2-isc - 8 bits per beat */ isc->dcfg = ISC_DCFG_YMBSIZE_BEATS8 | ISC_DCFG_CMBSIZE_BEATS8; @@ -332,6 +334,9 @@ static int atmel_isc_probe(struct platform_device *pdev) pm_runtime_enable(dev); pm_request_idle(dev); + regmap_read(isc->regmap, ISC_VERSION + isc->offsets.version, &ver); + dev_info(dev, "Microchip ISC version %x\n", ver); + return 0; cleanup_subdev: |