diff options
Diffstat (limited to 'drivers/media/platform/exynos4-is')
-rw-r--r-- | drivers/media/platform/exynos4-is/Kconfig | 5 | ||||
-rw-r--r-- | drivers/media/platform/exynos4-is/fimc-is-errno.c | 4 | ||||
-rw-r--r-- | drivers/media/platform/exynos4-is/fimc-is-errno.h | 4 | ||||
-rw-r--r-- | drivers/media/platform/exynos4-is/fimc-is-param.c | 2 | ||||
-rw-r--r-- | drivers/media/platform/exynos4-is/fimc-is.c | 10 | ||||
-rw-r--r-- | drivers/media/platform/exynos4-is/fimc-isp-video.c | 9 | ||||
-rw-r--r-- | drivers/media/platform/exynos4-is/media-dev.c | 4 | ||||
-rw-r--r-- | drivers/media/platform/exynos4-is/mipi-csis.c | 3 |
8 files changed, 22 insertions, 19 deletions
diff --git a/drivers/media/platform/exynos4-is/Kconfig b/drivers/media/platform/exynos4-is/Kconfig index 5dcaa0a..77c9512 100644 --- a/drivers/media/platform/exynos4-is/Kconfig +++ b/drivers/media/platform/exynos4-is/Kconfig @@ -2,7 +2,7 @@ config VIDEO_SAMSUNG_EXYNOS4_IS bool "Samsung S5P/EXYNOS4 SoC series Camera Subsystem driver" depends on VIDEO_V4L2 && VIDEO_V4L2_SUBDEV_API - depends on (PLAT_S5P || ARCH_EXYNOS) + depends on (PLAT_S5P || ARCH_EXYNOS || COMPILE_TEST) depends on OF && COMMON_CLK help Say Y here to enable camera host interface devices for @@ -16,6 +16,7 @@ config VIDEO_EXYNOS4_IS_COMMON config VIDEO_S5P_FIMC tristate "S5P/EXYNOS4 FIMC/CAMIF camera interface driver" depends on I2C + depends on HAS_DMA select VIDEOBUF2_DMA_CONTIG select V4L2_MEM2MEM_DEV select MFD_SYSCON @@ -43,6 +44,7 @@ if SOC_EXYNOS4212 || SOC_EXYNOS4412 || SOC_EXYNOS5250 config VIDEO_EXYNOS_FIMC_LITE tristate "EXYNOS FIMC-LITE camera interface driver" depends on I2C + depends on HAS_DMA select VIDEOBUF2_DMA_CONTIG select VIDEO_EXYNOS4_IS_COMMON help @@ -55,6 +57,7 @@ endif config VIDEO_EXYNOS4_FIMC_IS tristate "EXYNOS4x12 FIMC-IS (Imaging Subsystem) driver" + depends on HAS_DMA select VIDEOBUF2_DMA_CONTIG depends on OF select FW_LOADER diff --git a/drivers/media/platform/exynos4-is/fimc-is-errno.c b/drivers/media/platform/exynos4-is/fimc-is-errno.c index e8519e1..e050e63 100644 --- a/drivers/media/platform/exynos4-is/fimc-is-errno.c +++ b/drivers/media/platform/exynos4-is/fimc-is-errno.c @@ -15,7 +15,7 @@ #include "fimc-is-errno.h" -const char * const fimc_is_param_strerr(unsigned int error) +const char *fimc_is_param_strerr(unsigned int error) { switch (error) { case ERROR_COMMON_CMD: @@ -146,7 +146,7 @@ const char * const fimc_is_param_strerr(unsigned int error) } } -const char * const fimc_is_strerr(unsigned int error) +const char *fimc_is_strerr(unsigned int error) { error &= ~IS_ERROR_TIME_OUT_FLAG; diff --git a/drivers/media/platform/exynos4-is/fimc-is-errno.h b/drivers/media/platform/exynos4-is/fimc-is-errno.h index 3de6f6d..ef981e7 100644 --- a/drivers/media/platform/exynos4-is/fimc-is-errno.h +++ b/drivers/media/platform/exynos4-is/fimc-is-errno.h @@ -242,7 +242,7 @@ enum fimc_is_error { ERROR_SCALER_FLIP = 521, }; -const char * const fimc_is_strerr(unsigned int error); -const char * const fimc_is_param_strerr(unsigned int error); +const char *fimc_is_strerr(unsigned int error); +const char *fimc_is_param_strerr(unsigned int error); #endif /* FIMC_IS_ERR_H_ */ diff --git a/drivers/media/platform/exynos4-is/fimc-is-param.c b/drivers/media/platform/exynos4-is/fimc-is-param.c index bf1465d..72b9b43 100644 --- a/drivers/media/platform/exynos4-is/fimc-is-param.c +++ b/drivers/media/platform/exynos4-is/fimc-is-param.c @@ -667,7 +667,6 @@ void __is_set_fd_config_orientation_val(struct fimc_is *is, u32 val) void fimc_is_set_initial_params(struct fimc_is *is) { struct global_param *global; - struct sensor_param *sensor; struct isp_param *isp; struct drc_param *drc; struct fd_param *fd; @@ -676,7 +675,6 @@ void fimc_is_set_initial_params(struct fimc_is *is) index = is->config_index; global = &is->config[index].global; - sensor = &is->config[index].sensor; isp = &is->config[index].isp; drc = &is->config[index].drc; fd = &is->config[index].fd; diff --git a/drivers/media/platform/exynos4-is/fimc-is.c b/drivers/media/platform/exynos4-is/fimc-is.c index 5476dce..22162b2 100644 --- a/drivers/media/platform/exynos4-is/fimc-is.c +++ b/drivers/media/platform/exynos4-is/fimc-is.c @@ -388,7 +388,7 @@ static void fimc_is_load_firmware(const struct firmware *fw, void *context) mutex_lock(&is->lock); if (fw->size < FIMC_IS_FW_SIZE_MIN || fw->size > FIMC_IS_FW_SIZE_MAX) { - dev_err(dev, "wrong firmware size: %d\n", fw->size); + dev_err(dev, "wrong firmware size: %zu\n", fw->size); goto done; } @@ -416,7 +416,7 @@ static void fimc_is_load_firmware(const struct firmware *fw, void *context) dev_info(dev, "loaded firmware: %s, rev. %s\n", is->fw.info, is->fw.version); - dev_dbg(dev, "FW size: %d, paddr: %#x\n", fw->size, is->memory.paddr); + dev_dbg(dev, "FW size: %zu, paddr: %pad\n", fw->size, &is->memory.paddr); is->is_shared_region->chip_id = 0xe4412; is->is_shared_region->chip_rev_no = 1; @@ -693,9 +693,9 @@ int fimc_is_hw_initialize(struct fimc_is *is) return -EIO; } - pr_debug("shared region: %#x, parameter region: %#x\n", - is->memory.paddr + FIMC_IS_SHARED_REGION_OFFSET, - is->is_dma_p_region); + pr_debug("shared region: %pad, parameter region: %pad\n", + &is->memory.paddr + FIMC_IS_SHARED_REGION_OFFSET, + &is->is_dma_p_region); is->setfile.sub_index = 0; diff --git a/drivers/media/platform/exynos4-is/fimc-isp-video.c b/drivers/media/platform/exynos4-is/fimc-isp-video.c index 93f9cf2..76b6b4d 100644 --- a/drivers/media/platform/exynos4-is/fimc-isp-video.c +++ b/drivers/media/platform/exynos4-is/fimc-isp-video.c @@ -219,9 +219,9 @@ static void isp_video_capture_buffer_queue(struct vb2_buffer *vb) ivb->dma_addr[i]; isp_dbg(2, &video->ve.vdev, - "dma_buf %d (%d/%d/%d) addr: %#x\n", - buf_index, ivb->index, i, vb->v4l2_buf.index, - ivb->dma_addr[i]); + "dma_buf %pad (%d/%d/%d) addr: %pad\n", + &buf_index, ivb->index, i, vb->v4l2_buf.index, + &ivb->dma_addr[i]); } if (++video->buf_count < video->reqbufs_count) @@ -313,7 +313,6 @@ static int isp_video_release(struct file *file) struct fimc_is_video *ivc = &isp->video_capture; struct media_entity *entity = &ivc->ve.vdev.entity; struct media_device *mdev = entity->parent; - int ret = 0; mutex_lock(&isp->video_lock); @@ -335,7 +334,7 @@ static int isp_video_release(struct file *file) pm_runtime_put(&isp->pdev->dev); mutex_unlock(&isp->video_lock); - return ret; + return 0; } static const struct v4l2_file_operations isp_video_fops = { diff --git a/drivers/media/platform/exynos4-is/media-dev.c b/drivers/media/platform/exynos4-is/media-dev.c index 344718d..54c49d5 100644 --- a/drivers/media/platform/exynos4-is/media-dev.c +++ b/drivers/media/platform/exynos4-is/media-dev.c @@ -1098,8 +1098,10 @@ static int fimc_md_link_notify(struct media_link *link, unsigned int flags, if (notification == MEDIA_DEV_NOTIFY_PRE_LINK_CH) { if (!(flags & MEDIA_LNK_FL_ENABLED)) ret = __fimc_md_modify_pipelines(sink, false); +#if 0 else - ; /* TODO: Link state change validation */ + /* TODO: Link state change validation */ +#endif /* After link activation */ } else if (notification == MEDIA_DEV_NOTIFY_POST_LINK_CH && (link->flags & MEDIA_LNK_FL_ENABLED)) { diff --git a/drivers/media/platform/exynos4-is/mipi-csis.c b/drivers/media/platform/exynos4-is/mipi-csis.c index ae54ef5..db6fd14 100644 --- a/drivers/media/platform/exynos4-is/mipi-csis.c +++ b/drivers/media/platform/exynos4-is/mipi-csis.c @@ -25,6 +25,7 @@ #include <linux/platform_device.h> #include <linux/pm_runtime.h> #include <linux/regulator/consumer.h> +#include <linux/sizes.h> #include <linux/slab.h> #include <linux/spinlock.h> #include <linux/videodev2.h> @@ -752,7 +753,7 @@ static int s5pcsis_parse_dt(struct platform_device *pdev, v4l2_of_parse_endpoint(node, &endpoint); state->index = endpoint.base.port - FIMC_INPUT_MIPI_CSI2_0; - if (state->index < 0 || state->index >= CSIS_MAX_ENTITIES) + if (state->index >= CSIS_MAX_ENTITIES) return -ENXIO; /* Get MIPI CSI-2 bus configration from the endpoint node. */ |