linux-media.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/4] atmel-isi: Remove platform data support
@ 2015-08-01  9:22 Laurent Pinchart
  2015-08-01  9:22 ` [PATCH 1/4] v4l: atmel-isi: Simplify error handling during DT parsing Laurent Pinchart
                   ` (5 more replies)
  0 siblings, 6 replies; 11+ messages in thread
From: Laurent Pinchart @ 2015-08-01  9:22 UTC (permalink / raw)
  To: linux-media; +Cc: Josh Wu

Hello,

While reviewing patches for the atmel-isi I noticed a couple of small issues
with the driver. Here's a patch series to fix them, the main change being the
removal of platform data support now that all users have migrated to DT.

The patches have been compile-tested only. Josh, would you be able to test
them on hardware ?

Laurent Pinchart (4):
  v4l: atmel-isi: Simplify error handling during DT parsing
  v4l: atmel-isi: Remove unused variable
  v4l: atmel-isi: Remove support for platform data
  v4l: atmel-isi: Remove unused platform data fields

 drivers/media/platform/soc_camera/atmel-isi.c |  40 ++------
 drivers/media/platform/soc_camera/atmel-isi.h | 126 +++++++++++++++++++++++++
 include/media/atmel-isi.h                     | 131 --------------------------
 3 files changed, 136 insertions(+), 161 deletions(-)
 create mode 100644 drivers/media/platform/soc_camera/atmel-isi.h
 delete mode 100644 include/media/atmel-isi.h

-- 
Regards,

Laurent Pinchart


^ permalink raw reply	[flat|nested] 11+ messages in thread

* [PATCH 1/4] v4l: atmel-isi: Simplify error handling during DT parsing
  2015-08-01  9:22 [PATCH 0/4] atmel-isi: Remove platform data support Laurent Pinchart
@ 2015-08-01  9:22 ` Laurent Pinchart
  2015-08-01  9:22 ` [PATCH 2/4] v4l: atmel-isi: Remove unused variable Laurent Pinchart
                   ` (4 subsequent siblings)
  5 siblings, 0 replies; 11+ messages in thread
From: Laurent Pinchart @ 2015-08-01  9:22 UTC (permalink / raw)
  To: linux-media; +Cc: Josh Wu

Put the endpoint DT node earlier to avoid the need for goto statements
to a cleanup code block in case of errors.

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
---
 drivers/media/platform/soc_camera/atmel-isi.c | 11 ++++-------
 1 file changed, 4 insertions(+), 7 deletions(-)

diff --git a/drivers/media/platform/soc_camera/atmel-isi.c b/drivers/media/platform/soc_camera/atmel-isi.c
index 90701726a06a..9c900d9569e0 100644
--- a/drivers/media/platform/soc_camera/atmel-isi.c
+++ b/drivers/media/platform/soc_camera/atmel-isi.c
@@ -891,9 +891,10 @@ static int atmel_isi_probe_dt(struct atmel_isi *isi,
 	}
 
 	err = v4l2_of_parse_endpoint(np, &ep);
+	of_node_put(np);
 	if (err) {
 		dev_err(&pdev->dev, "Could not parse the endpoint\n");
-		goto err_probe_dt;
+		return err;
 	}
 
 	switch (ep.bus.parallel.bus_width) {
@@ -907,14 +908,10 @@ static int atmel_isi_probe_dt(struct atmel_isi *isi,
 	default:
 		dev_err(&pdev->dev, "Unsupported bus width: %d\n",
 				ep.bus.parallel.bus_width);
-		err = -EINVAL;
-		goto err_probe_dt;
+		return -EINVAL;
 	}
 
-err_probe_dt:
-	of_node_put(np);
-
-	return err;
+	return 0;
 }
 
 static int atmel_isi_probe(struct platform_device *pdev)
-- 
2.3.6


^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [PATCH 2/4] v4l: atmel-isi: Remove unused variable
  2015-08-01  9:22 [PATCH 0/4] atmel-isi: Remove platform data support Laurent Pinchart
  2015-08-01  9:22 ` [PATCH 1/4] v4l: atmel-isi: Simplify error handling during DT parsing Laurent Pinchart
@ 2015-08-01  9:22 ` Laurent Pinchart
  2015-08-06  8:19   ` Josh Wu
  2015-08-01  9:22 ` [PATCH 3/4] v4l: atmel-isi: Remove support for platform data Laurent Pinchart
                   ` (3 subsequent siblings)
  5 siblings, 1 reply; 11+ messages in thread
From: Laurent Pinchart @ 2015-08-01  9:22 UTC (permalink / raw)
  To: linux-media; +Cc: Josh Wu

Fix a compilation warning by removing an unused local variable in the
probe function.

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
---
 drivers/media/platform/soc_camera/atmel-isi.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/drivers/media/platform/soc_camera/atmel-isi.c b/drivers/media/platform/soc_camera/atmel-isi.c
index 9c900d9569e0..a2e50a734fa3 100644
--- a/drivers/media/platform/soc_camera/atmel-isi.c
+++ b/drivers/media/platform/soc_camera/atmel-isi.c
@@ -920,7 +920,6 @@ static int atmel_isi_probe(struct platform_device *pdev)
 	struct atmel_isi *isi;
 	struct resource *regs;
 	int ret, i;
-	struct device *dev = &pdev->dev;
 	struct soc_camera_host *soc_host;
 	struct isi_platform_data *pdata;
 
-- 
2.3.6


^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [PATCH 3/4] v4l: atmel-isi: Remove support for platform data
  2015-08-01  9:22 [PATCH 0/4] atmel-isi: Remove platform data support Laurent Pinchart
  2015-08-01  9:22 ` [PATCH 1/4] v4l: atmel-isi: Simplify error handling during DT parsing Laurent Pinchart
  2015-08-01  9:22 ` [PATCH 2/4] v4l: atmel-isi: Remove unused variable Laurent Pinchart
@ 2015-08-01  9:22 ` Laurent Pinchart
  2015-08-01  9:22 ` [PATCH 4/4] v4l: atmel-isi: Remove unused platform data fields Laurent Pinchart
                   ` (2 subsequent siblings)
  5 siblings, 0 replies; 11+ messages in thread
From: Laurent Pinchart @ 2015-08-01  9:22 UTC (permalink / raw)
  To: linux-media; +Cc: Josh Wu

All in-tree users have migrated to DT, remove support for platform data.

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
---
 drivers/media/platform/soc_camera/atmel-isi.c |  23 ++---
 drivers/media/platform/soc_camera/atmel-isi.h | 131 ++++++++++++++++++++++++++
 include/media/atmel-isi.h                     | 131 --------------------------
 3 files changed, 137 insertions(+), 148 deletions(-)
 create mode 100644 drivers/media/platform/soc_camera/atmel-isi.h
 delete mode 100644 include/media/atmel-isi.h

diff --git a/drivers/media/platform/soc_camera/atmel-isi.c b/drivers/media/platform/soc_camera/atmel-isi.c
index a2e50a734fa3..de9237e56f84 100644
--- a/drivers/media/platform/soc_camera/atmel-isi.c
+++ b/drivers/media/platform/soc_camera/atmel-isi.c
@@ -23,12 +23,13 @@
 #include <linux/pm_runtime.h>
 #include <linux/slab.h>
 
-#include <media/atmel-isi.h>
 #include <media/soc_camera.h>
 #include <media/soc_mediabus.h>
 #include <media/v4l2-of.h>
 #include <media/videobuf2-dma-contig.h>
 
+#include "atmel-isi.h"
+
 #define MAX_BUFFER_NUM			32
 #define MAX_SUPPORT_WIDTH		2048
 #define MAX_SUPPORT_HEIGHT		2048
@@ -873,7 +874,7 @@ static int atmel_isi_remove(struct platform_device *pdev)
 	return 0;
 }
 
-static int atmel_isi_probe_dt(struct atmel_isi *isi,
+static int atmel_isi_parse_dt(struct atmel_isi *isi,
 			struct platform_device *pdev)
 {
 	struct device_node *np= pdev->dev.of_node;
@@ -921,14 +922,6 @@ static int atmel_isi_probe(struct platform_device *pdev)
 	struct resource *regs;
 	int ret, i;
 	struct soc_camera_host *soc_host;
-	struct isi_platform_data *pdata;
-
-	pdata = dev->platform_data;
-	if ((!pdata || !pdata->data_width_flags) && !pdev->dev.of_node) {
-		dev_err(&pdev->dev,
-			"No config available for Atmel ISI\n");
-		return -EINVAL;
-	}
 
 	isi = devm_kzalloc(&pdev->dev, sizeof(struct atmel_isi), GFP_KERNEL);
 	if (!isi) {
@@ -940,13 +933,9 @@ static int atmel_isi_probe(struct platform_device *pdev)
 	if (IS_ERR(isi->pclk))
 		return PTR_ERR(isi->pclk);
 
-	if (pdata) {
-		memcpy(&isi->pdata, pdata, sizeof(isi->pdata));
-	} else {
-		ret = atmel_isi_probe_dt(isi, pdev);
-		if (ret)
-			return ret;
-	}
+	ret = atmel_isi_parse_dt(isi, pdev);
+	if (ret)
+		return ret;
 
 	isi->active = NULL;
 	spin_lock_init(&isi->lock);
diff --git a/drivers/media/platform/soc_camera/atmel-isi.h b/drivers/media/platform/soc_camera/atmel-isi.h
new file mode 100644
index 000000000000..6008b0985b7b
--- /dev/null
+++ b/drivers/media/platform/soc_camera/atmel-isi.h
@@ -0,0 +1,131 @@
+/*
+ * Register definitions for the Atmel Image Sensor Interface.
+ *
+ * Copyright (C) 2011 Atmel Corporation
+ * Josh Wu, <josh.wu@atmel.com>
+ *
+ * Based on previous work by Lars Haring, <lars.haring@atmel.com>
+ * and Sedji Gaouaou
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation.
+ */
+#ifndef __ATMEL_ISI_H__
+#define __ATMEL_ISI_H__
+
+#include <linux/types.h>
+
+/* ISI_V2 register offsets */
+#define ISI_CFG1				0x0000
+#define ISI_CFG2				0x0004
+#define ISI_PSIZE				0x0008
+#define ISI_PDECF				0x000c
+#define ISI_Y2R_SET0				0x0010
+#define ISI_Y2R_SET1				0x0014
+#define ISI_R2Y_SET0				0x0018
+#define ISI_R2Y_SET1				0x001C
+#define ISI_R2Y_SET2				0x0020
+#define ISI_CTRL				0x0024
+#define ISI_STATUS				0x0028
+#define ISI_INTEN				0x002C
+#define ISI_INTDIS				0x0030
+#define ISI_INTMASK				0x0034
+#define ISI_DMA_CHER				0x0038
+#define ISI_DMA_CHDR				0x003C
+#define ISI_DMA_CHSR				0x0040
+#define ISI_DMA_P_ADDR				0x0044
+#define ISI_DMA_P_CTRL				0x0048
+#define ISI_DMA_P_DSCR				0x004C
+#define ISI_DMA_C_ADDR				0x0050
+#define ISI_DMA_C_CTRL				0x0054
+#define ISI_DMA_C_DSCR				0x0058
+
+/* Bitfields in CFG1 */
+#define ISI_CFG1_HSYNC_POL_ACTIVE_LOW		(1 << 2)
+#define ISI_CFG1_VSYNC_POL_ACTIVE_LOW		(1 << 3)
+#define ISI_CFG1_PIXCLK_POL_ACTIVE_FALLING	(1 << 4)
+#define ISI_CFG1_EMB_SYNC			(1 << 6)
+#define ISI_CFG1_CRC_SYNC			(1 << 7)
+/* Constants for FRATE(ISI_V2) */
+#define		ISI_CFG1_FRATE_CAPTURE_ALL	(0 << 8)
+#define		ISI_CFG1_FRATE_DIV_2		(1 << 8)
+#define		ISI_CFG1_FRATE_DIV_3		(2 << 8)
+#define		ISI_CFG1_FRATE_DIV_4		(3 << 8)
+#define		ISI_CFG1_FRATE_DIV_5		(4 << 8)
+#define		ISI_CFG1_FRATE_DIV_6		(5 << 8)
+#define		ISI_CFG1_FRATE_DIV_7		(6 << 8)
+#define		ISI_CFG1_FRATE_DIV_8		(7 << 8)
+#define		ISI_CFG1_FRATE_DIV_MASK		(7 << 8)
+#define ISI_CFG1_DISCR				(1 << 11)
+#define ISI_CFG1_FULL_MODE			(1 << 12)
+/* Definition for THMASK(ISI_V2) */
+#define		ISI_CFG1_THMASK_BEATS_4		(0 << 13)
+#define		ISI_CFG1_THMASK_BEATS_8		(1 << 13)
+#define		ISI_CFG1_THMASK_BEATS_16	(2 << 13)
+
+/* Bitfields in CFG2 */
+#define ISI_CFG2_GRAYSCALE			(1 << 13)
+/* Constants for YCC_SWAP(ISI_V2) */
+#define		ISI_CFG2_YCC_SWAP_DEFAULT	(0 << 28)
+#define		ISI_CFG2_YCC_SWAP_MODE_1	(1 << 28)
+#define		ISI_CFG2_YCC_SWAP_MODE_2	(2 << 28)
+#define		ISI_CFG2_YCC_SWAP_MODE_3	(3 << 28)
+#define		ISI_CFG2_YCC_SWAP_MODE_MASK	(3 << 28)
+#define ISI_CFG2_IM_VSIZE_OFFSET		0
+#define ISI_CFG2_IM_HSIZE_OFFSET		16
+#define ISI_CFG2_IM_VSIZE_MASK		(0x7FF << ISI_CFG2_IM_VSIZE_OFFSET)
+#define ISI_CFG2_IM_HSIZE_MASK		(0x7FF << ISI_CFG2_IM_HSIZE_OFFSET)
+
+/* Bitfields in CTRL */
+/* Also using in SR(ISI_V2) */
+#define ISI_CTRL_EN				(1 << 0)
+#define ISI_CTRL_CDC				(1 << 8)
+/* Also using in SR/IER/IDR/IMR(ISI_V2) */
+#define ISI_CTRL_DIS				(1 << 1)
+#define ISI_CTRL_SRST				(1 << 2)
+
+/* Bitfields in SR */
+#define ISI_SR_SIP				(1 << 19)
+/* Also using in SR/IER/IDR/IMR */
+#define ISI_SR_VSYNC				(1 << 10)
+#define ISI_SR_PXFR_DONE			(1 << 16)
+#define ISI_SR_CXFR_DONE			(1 << 17)
+#define ISI_SR_P_OVR				(1 << 24)
+#define ISI_SR_C_OVR				(1 << 25)
+#define ISI_SR_CRC_ERR				(1 << 26)
+#define ISI_SR_FR_OVR				(1 << 27)
+
+/* Bitfields in DMA_C_CTRL & in DMA_P_CTRL */
+#define ISI_DMA_CTRL_FETCH			(1 << 0)
+#define ISI_DMA_CTRL_WB				(1 << 1)
+#define ISI_DMA_CTRL_IEN			(1 << 2)
+#define ISI_DMA_CTRL_DONE			(1 << 3)
+
+/* Bitfields in DMA_CHSR/CHER/CHDR */
+#define ISI_DMA_CHSR_P_CH			(1 << 0)
+#define ISI_DMA_CHSR_C_CH			(1 << 1)
+
+/* Definition for isi_platform_data */
+#define ISI_DATAWIDTH_8				0x01
+#define ISI_DATAWIDTH_10			0x02
+
+struct v4l2_async_subdev;
+
+struct isi_platform_data {
+	u8 has_emb_sync;
+	u8 emb_crc_sync;
+	u8 hsync_act_low;
+	u8 vsync_act_low;
+	u8 pclk_act_falling;
+	u8 full_mode;
+	u32 data_width_flags;
+	/* Using for ISI_CFG1 */
+	u32 frate;
+	/* Using for ISI_MCK */
+	u32 mck_hz;
+	struct v4l2_async_subdev **asd;	/* Flat array, arranged in groups */
+	int *asd_sizes;		/* 0-terminated array of asd group sizes */
+};
+
+#endif /* __ATMEL_ISI_H__ */
diff --git a/include/media/atmel-isi.h b/include/media/atmel-isi.h
deleted file mode 100644
index 6008b0985b7b..000000000000
--- a/include/media/atmel-isi.h
+++ /dev/null
@@ -1,131 +0,0 @@
-/*
- * Register definitions for the Atmel Image Sensor Interface.
- *
- * Copyright (C) 2011 Atmel Corporation
- * Josh Wu, <josh.wu@atmel.com>
- *
- * Based on previous work by Lars Haring, <lars.haring@atmel.com>
- * and Sedji Gaouaou
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License version 2 as
- * published by the Free Software Foundation.
- */
-#ifndef __ATMEL_ISI_H__
-#define __ATMEL_ISI_H__
-
-#include <linux/types.h>
-
-/* ISI_V2 register offsets */
-#define ISI_CFG1				0x0000
-#define ISI_CFG2				0x0004
-#define ISI_PSIZE				0x0008
-#define ISI_PDECF				0x000c
-#define ISI_Y2R_SET0				0x0010
-#define ISI_Y2R_SET1				0x0014
-#define ISI_R2Y_SET0				0x0018
-#define ISI_R2Y_SET1				0x001C
-#define ISI_R2Y_SET2				0x0020
-#define ISI_CTRL				0x0024
-#define ISI_STATUS				0x0028
-#define ISI_INTEN				0x002C
-#define ISI_INTDIS				0x0030
-#define ISI_INTMASK				0x0034
-#define ISI_DMA_CHER				0x0038
-#define ISI_DMA_CHDR				0x003C
-#define ISI_DMA_CHSR				0x0040
-#define ISI_DMA_P_ADDR				0x0044
-#define ISI_DMA_P_CTRL				0x0048
-#define ISI_DMA_P_DSCR				0x004C
-#define ISI_DMA_C_ADDR				0x0050
-#define ISI_DMA_C_CTRL				0x0054
-#define ISI_DMA_C_DSCR				0x0058
-
-/* Bitfields in CFG1 */
-#define ISI_CFG1_HSYNC_POL_ACTIVE_LOW		(1 << 2)
-#define ISI_CFG1_VSYNC_POL_ACTIVE_LOW		(1 << 3)
-#define ISI_CFG1_PIXCLK_POL_ACTIVE_FALLING	(1 << 4)
-#define ISI_CFG1_EMB_SYNC			(1 << 6)
-#define ISI_CFG1_CRC_SYNC			(1 << 7)
-/* Constants for FRATE(ISI_V2) */
-#define		ISI_CFG1_FRATE_CAPTURE_ALL	(0 << 8)
-#define		ISI_CFG1_FRATE_DIV_2		(1 << 8)
-#define		ISI_CFG1_FRATE_DIV_3		(2 << 8)
-#define		ISI_CFG1_FRATE_DIV_4		(3 << 8)
-#define		ISI_CFG1_FRATE_DIV_5		(4 << 8)
-#define		ISI_CFG1_FRATE_DIV_6		(5 << 8)
-#define		ISI_CFG1_FRATE_DIV_7		(6 << 8)
-#define		ISI_CFG1_FRATE_DIV_8		(7 << 8)
-#define		ISI_CFG1_FRATE_DIV_MASK		(7 << 8)
-#define ISI_CFG1_DISCR				(1 << 11)
-#define ISI_CFG1_FULL_MODE			(1 << 12)
-/* Definition for THMASK(ISI_V2) */
-#define		ISI_CFG1_THMASK_BEATS_4		(0 << 13)
-#define		ISI_CFG1_THMASK_BEATS_8		(1 << 13)
-#define		ISI_CFG1_THMASK_BEATS_16	(2 << 13)
-
-/* Bitfields in CFG2 */
-#define ISI_CFG2_GRAYSCALE			(1 << 13)
-/* Constants for YCC_SWAP(ISI_V2) */
-#define		ISI_CFG2_YCC_SWAP_DEFAULT	(0 << 28)
-#define		ISI_CFG2_YCC_SWAP_MODE_1	(1 << 28)
-#define		ISI_CFG2_YCC_SWAP_MODE_2	(2 << 28)
-#define		ISI_CFG2_YCC_SWAP_MODE_3	(3 << 28)
-#define		ISI_CFG2_YCC_SWAP_MODE_MASK	(3 << 28)
-#define ISI_CFG2_IM_VSIZE_OFFSET		0
-#define ISI_CFG2_IM_HSIZE_OFFSET		16
-#define ISI_CFG2_IM_VSIZE_MASK		(0x7FF << ISI_CFG2_IM_VSIZE_OFFSET)
-#define ISI_CFG2_IM_HSIZE_MASK		(0x7FF << ISI_CFG2_IM_HSIZE_OFFSET)
-
-/* Bitfields in CTRL */
-/* Also using in SR(ISI_V2) */
-#define ISI_CTRL_EN				(1 << 0)
-#define ISI_CTRL_CDC				(1 << 8)
-/* Also using in SR/IER/IDR/IMR(ISI_V2) */
-#define ISI_CTRL_DIS				(1 << 1)
-#define ISI_CTRL_SRST				(1 << 2)
-
-/* Bitfields in SR */
-#define ISI_SR_SIP				(1 << 19)
-/* Also using in SR/IER/IDR/IMR */
-#define ISI_SR_VSYNC				(1 << 10)
-#define ISI_SR_PXFR_DONE			(1 << 16)
-#define ISI_SR_CXFR_DONE			(1 << 17)
-#define ISI_SR_P_OVR				(1 << 24)
-#define ISI_SR_C_OVR				(1 << 25)
-#define ISI_SR_CRC_ERR				(1 << 26)
-#define ISI_SR_FR_OVR				(1 << 27)
-
-/* Bitfields in DMA_C_CTRL & in DMA_P_CTRL */
-#define ISI_DMA_CTRL_FETCH			(1 << 0)
-#define ISI_DMA_CTRL_WB				(1 << 1)
-#define ISI_DMA_CTRL_IEN			(1 << 2)
-#define ISI_DMA_CTRL_DONE			(1 << 3)
-
-/* Bitfields in DMA_CHSR/CHER/CHDR */
-#define ISI_DMA_CHSR_P_CH			(1 << 0)
-#define ISI_DMA_CHSR_C_CH			(1 << 1)
-
-/* Definition for isi_platform_data */
-#define ISI_DATAWIDTH_8				0x01
-#define ISI_DATAWIDTH_10			0x02
-
-struct v4l2_async_subdev;
-
-struct isi_platform_data {
-	u8 has_emb_sync;
-	u8 emb_crc_sync;
-	u8 hsync_act_low;
-	u8 vsync_act_low;
-	u8 pclk_act_falling;
-	u8 full_mode;
-	u32 data_width_flags;
-	/* Using for ISI_CFG1 */
-	u32 frate;
-	/* Using for ISI_MCK */
-	u32 mck_hz;
-	struct v4l2_async_subdev **asd;	/* Flat array, arranged in groups */
-	int *asd_sizes;		/* 0-terminated array of asd group sizes */
-};
-
-#endif /* __ATMEL_ISI_H__ */
-- 
2.3.6


^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [PATCH 4/4] v4l: atmel-isi: Remove unused platform data fields
  2015-08-01  9:22 [PATCH 0/4] atmel-isi: Remove platform data support Laurent Pinchart
                   ` (2 preceding siblings ...)
  2015-08-01  9:22 ` [PATCH 3/4] v4l: atmel-isi: Remove support for platform data Laurent Pinchart
@ 2015-08-01  9:22 ` Laurent Pinchart
  2015-08-03  2:56 ` [PATCH 0/4] atmel-isi: Remove platform data support Josh Wu
  2015-09-20 15:25 ` Guennadi Liakhovetski
  5 siblings, 0 replies; 11+ messages in thread
From: Laurent Pinchart @ 2015-08-01  9:22 UTC (permalink / raw)
  To: linux-media; +Cc: Josh Wu

The emb_crc_sync, mck_hz, asd and asd_sizes platform data fields are
unused, remove them.

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
---
 drivers/media/platform/soc_camera/atmel-isi.c | 5 -----
 drivers/media/platform/soc_camera/atmel-isi.h | 5 -----
 2 files changed, 10 deletions(-)

diff --git a/drivers/media/platform/soc_camera/atmel-isi.c b/drivers/media/platform/soc_camera/atmel-isi.c
index de9237e56f84..e6ff2a75ea42 100644
--- a/drivers/media/platform/soc_camera/atmel-isi.c
+++ b/drivers/media/platform/soc_camera/atmel-isi.c
@@ -999,11 +999,6 @@ static int atmel_isi_probe(struct platform_device *pdev)
 	pm_suspend_ignore_children(&pdev->dev, true);
 	pm_runtime_enable(&pdev->dev);
 
-	if (isi->pdata.asd_sizes) {
-		soc_host->asd = isi->pdata.asd;
-		soc_host->asd_sizes = isi->pdata.asd_sizes;
-	}
-
 	ret = soc_camera_host_register(soc_host);
 	if (ret) {
 		dev_err(&pdev->dev, "Unable to register soc camera host\n");
diff --git a/drivers/media/platform/soc_camera/atmel-isi.h b/drivers/media/platform/soc_camera/atmel-isi.h
index 6008b0985b7b..83493abd1fa2 100644
--- a/drivers/media/platform/soc_camera/atmel-isi.h
+++ b/drivers/media/platform/soc_camera/atmel-isi.h
@@ -114,7 +114,6 @@ struct v4l2_async_subdev;
 
 struct isi_platform_data {
 	u8 has_emb_sync;
-	u8 emb_crc_sync;
 	u8 hsync_act_low;
 	u8 vsync_act_low;
 	u8 pclk_act_falling;
@@ -122,10 +121,6 @@ struct isi_platform_data {
 	u32 data_width_flags;
 	/* Using for ISI_CFG1 */
 	u32 frate;
-	/* Using for ISI_MCK */
-	u32 mck_hz;
-	struct v4l2_async_subdev **asd;	/* Flat array, arranged in groups */
-	int *asd_sizes;		/* 0-terminated array of asd group sizes */
 };
 
 #endif /* __ATMEL_ISI_H__ */
-- 
2.3.6


^ permalink raw reply related	[flat|nested] 11+ messages in thread

* Re: [PATCH 0/4] atmel-isi: Remove platform data support
  2015-08-01  9:22 [PATCH 0/4] atmel-isi: Remove platform data support Laurent Pinchart
                   ` (3 preceding siblings ...)
  2015-08-01  9:22 ` [PATCH 4/4] v4l: atmel-isi: Remove unused platform data fields Laurent Pinchart
@ 2015-08-03  2:56 ` Josh Wu
  2015-08-04 22:08   ` Laurent Pinchart
  2015-09-20 15:25 ` Guennadi Liakhovetski
  5 siblings, 1 reply; 11+ messages in thread
From: Josh Wu @ 2015-08-03  2:56 UTC (permalink / raw)
  To: Laurent Pinchart, linux-media

Hi, Laurent

On 8/1/2015 5:22 PM, Laurent Pinchart wrote:
> Hello,
>
> While reviewing patches for the atmel-isi I noticed a couple of small issues
> with the driver. Here's a patch series to fix them, the main change being the
> removal of platform data support now that all users have migrated to DT.

Thanks for the patches. It's perfectly make sense.
>
> The patches have been compile-tested only. Josh, would you be able to test
> them on hardware ?

For the whole series, here is my:

Acked-by: Josh Wu <josh.wu@atmel.com>
Tested-by: Josh Wu <josh.wu@atmel.com>

Best Regards,
Josh Wu

>
> Laurent Pinchart (4):
>    v4l: atmel-isi: Simplify error handling during DT parsing
>    v4l: atmel-isi: Remove unused variable
>    v4l: atmel-isi: Remove support for platform data
>    v4l: atmel-isi: Remove unused platform data fields
>
>   drivers/media/platform/soc_camera/atmel-isi.c |  40 ++------
>   drivers/media/platform/soc_camera/atmel-isi.h | 126 +++++++++++++++++++++++++
>   include/media/atmel-isi.h                     | 131 --------------------------
>   3 files changed, 136 insertions(+), 161 deletions(-)
>   create mode 100644 drivers/media/platform/soc_camera/atmel-isi.h
>   delete mode 100644 include/media/atmel-isi.h
>


^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH 0/4] atmel-isi: Remove platform data support
  2015-08-03  2:56 ` [PATCH 0/4] atmel-isi: Remove platform data support Josh Wu
@ 2015-08-04 22:08   ` Laurent Pinchart
  2015-08-05  3:31     ` Josh Wu
  0 siblings, 1 reply; 11+ messages in thread
From: Laurent Pinchart @ 2015-08-04 22:08 UTC (permalink / raw)
  To: Josh Wu; +Cc: linux-media

Hi Josh,

On Monday 03 August 2015 10:56:29 Josh Wu wrote:
> On 8/1/2015 5:22 PM, Laurent Pinchart wrote:
> > Hello,
> > 
> > While reviewing patches for the atmel-isi I noticed a couple of small
> > issues with the driver. Here's a patch series to fix them, the main
> > change being the removal of platform data support now that all users have
> > migrated to DT.
>
> Thanks for the patches. It's perfectly make sense.
> 
> > The patches have been compile-tested only. Josh, would you be able to test
> > them on hardware ?
> 
> For the whole series, here is my:
> 
> Acked-by: Josh Wu <josh.wu@atmel.com>
> Tested-by: Josh Wu <josh.wu@atmel.com>

Thank you.

Do you plan to take those four patches in your tree and include them in your 
next pull request ?

> > Laurent Pinchart (4):
> >    v4l: atmel-isi: Simplify error handling during DT parsing
> >    v4l: atmel-isi: Remove unused variable
> >    v4l: atmel-isi: Remove support for platform data
> >    v4l: atmel-isi: Remove unused platform data fields
> >   
> >   drivers/media/platform/soc_camera/atmel-isi.c |  40 ++------
> >   drivers/media/platform/soc_camera/atmel-isi.h | 126 ++++++++++++++++++++
> >   include/media/atmel-isi.h                     | 131 --------------------
> >   3 files changed, 136 insertions(+), 161 deletions(-)
> >   create mode 100644 drivers/media/platform/soc_camera/atmel-isi.h
> >   delete mode 100644 include/media/atmel-isi.h

-- 
Regards,

Laurent Pinchart


^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH 0/4] atmel-isi: Remove platform data support
  2015-08-04 22:08   ` Laurent Pinchart
@ 2015-08-05  3:31     ` Josh Wu
  0 siblings, 0 replies; 11+ messages in thread
From: Josh Wu @ 2015-08-05  3:31 UTC (permalink / raw)
  To: Laurent Pinchart; +Cc: linux-media

Hi, Laurent

On 8/5/2015 6:08 AM, Laurent Pinchart wrote:
> Hi Josh,
>
> On Monday 03 August 2015 10:56:29 Josh Wu wrote:
>> On 8/1/2015 5:22 PM, Laurent Pinchart wrote:
>>> Hello,
>>>
>>> While reviewing patches for the atmel-isi I noticed a couple of small
>>> issues with the driver. Here's a patch series to fix them, the main
>>> change being the removal of platform data support now that all users have
>>> migrated to DT.
>> Thanks for the patches. It's perfectly make sense.
>>
>>> The patches have been compile-tested only. Josh, would you be able to test
>>> them on hardware ?
>> For the whole series, here is my:
>>
>> Acked-by: Josh Wu <josh.wu@atmel.com>
>> Tested-by: Josh Wu <josh.wu@atmel.com>
> Thank you.
>
> Do you plan to take those four patches in your tree and include them in your
> next pull request ?

yes, I plan to take them with my other patches for atmel-isi (about the 
configure_geometry(), already sent for review).
And I will sent a pull request to Gueannadi.

Best Regards,
Josh Wu

>>> Laurent Pinchart (4):
>>>     v4l: atmel-isi: Simplify error handling during DT parsing
>>>     v4l: atmel-isi: Remove unused variable
>>>     v4l: atmel-isi: Remove support for platform data
>>>     v4l: atmel-isi: Remove unused platform data fields
>>>    
>>>    drivers/media/platform/soc_camera/atmel-isi.c |  40 ++------
>>>    drivers/media/platform/soc_camera/atmel-isi.h | 126 ++++++++++++++++++++
>>>    include/media/atmel-isi.h                     | 131 --------------------
>>>    3 files changed, 136 insertions(+), 161 deletions(-)
>>>    create mode 100644 drivers/media/platform/soc_camera/atmel-isi.h
>>>    delete mode 100644 include/media/atmel-isi.h


^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH 2/4] v4l: atmel-isi: Remove unused variable
  2015-08-01  9:22 ` [PATCH 2/4] v4l: atmel-isi: Remove unused variable Laurent Pinchart
@ 2015-08-06  8:19   ` Josh Wu
  0 siblings, 0 replies; 11+ messages in thread
From: Josh Wu @ 2015-08-06  8:19 UTC (permalink / raw)
  To: Laurent Pinchart, linux-media

Hi, Laurent

On 8/1/2015 5:22 PM, Laurent Pinchart wrote:
> Fix a compilation warning by removing an unused local variable in the
> probe function.
>
> Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
> ---
>   drivers/media/platform/soc_camera/atmel-isi.c | 1 -
>   1 file changed, 1 deletion(-)
>
> diff --git a/drivers/media/platform/soc_camera/atmel-isi.c b/drivers/media/platform/soc_camera/atmel-isi.c
> index 9c900d9569e0..a2e50a734fa3 100644
> --- a/drivers/media/platform/soc_camera/atmel-isi.c
> +++ b/drivers/media/platform/soc_camera/atmel-isi.c
> @@ -920,7 +920,6 @@ static int atmel_isi_probe(struct platform_device *pdev)
>   	struct atmel_isi *isi;
>   	struct resource *regs;
>   	int ret, i;
> -	struct device *dev = &pdev->dev;

After a further check, I find this patch should be squashed with the 
[PATCH 3/4].
Since 'dev' is used by platform data in atmel_isi_probe() function by 
following code:

	pdata = dev->platform_data;
	if ((!pdata || !pdata->data_width_flags) && !pdev->dev.of_node) {
		dev_err(&pdev->dev,
			"No config available for Atmel ISI\n");
		return -EINVAL;
	}

So if you agree with it, I will squash this patch with
     [PATCH 3/4] Remove support for platform data
in my tree. Does it sound ok for you?

Best Regards,
Josh Wu

>   	struct soc_camera_host *soc_host;
>   	struct isi_platform_data *pdata;
>   


^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH 0/4] atmel-isi: Remove platform data support
  2015-08-01  9:22 [PATCH 0/4] atmel-isi: Remove platform data support Laurent Pinchart
                   ` (4 preceding siblings ...)
  2015-08-03  2:56 ` [PATCH 0/4] atmel-isi: Remove platform data support Josh Wu
@ 2015-09-20 15:25 ` Guennadi Liakhovetski
  2015-09-21  1:33   ` Josh Wu
  5 siblings, 1 reply; 11+ messages in thread
From: Guennadi Liakhovetski @ 2015-09-20 15:25 UTC (permalink / raw)
  To: Laurent Pinchart; +Cc: linux-media, Josh Wu

Hi Laurent, Josh,

It's ok not to CC me immediately if it's expected, that patches will be 
further forwarded (by Josh in this case) to me. And it helps, that Josh 
has collected all Atmel ISI patches in a git tree branch - thanks! But, 
please make sure, that all patches also appear in my mailbox at least 
once, especially if they are (even trivially) modified - like in this 
case, where patches 2 and 3 have been merged into 1.

Thanks
Guennadi

On Sat, 1 Aug 2015, Laurent Pinchart wrote:

> Hello,
> 
> While reviewing patches for the atmel-isi I noticed a couple of small issues
> with the driver. Here's a patch series to fix them, the main change being the
> removal of platform data support now that all users have migrated to DT.
> 
> The patches have been compile-tested only. Josh, would you be able to test
> them on hardware ?
> 
> Laurent Pinchart (4):
>   v4l: atmel-isi: Simplify error handling during DT parsing
>   v4l: atmel-isi: Remove unused variable
>   v4l: atmel-isi: Remove support for platform data
>   v4l: atmel-isi: Remove unused platform data fields
> 
>  drivers/media/platform/soc_camera/atmel-isi.c |  40 ++------
>  drivers/media/platform/soc_camera/atmel-isi.h | 126 +++++++++++++++++++++++++
>  include/media/atmel-isi.h                     | 131 --------------------------
>  3 files changed, 136 insertions(+), 161 deletions(-)
>  create mode 100644 drivers/media/platform/soc_camera/atmel-isi.h
>  delete mode 100644 include/media/atmel-isi.h
> 
> -- 
> Regards,
> 
> Laurent Pinchart
> 
> --
> To unsubscribe from this list: send the line "unsubscribe linux-media" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> 

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH 0/4] atmel-isi: Remove platform data support
  2015-09-20 15:25 ` Guennadi Liakhovetski
@ 2015-09-21  1:33   ` Josh Wu
  0 siblings, 0 replies; 11+ messages in thread
From: Josh Wu @ 2015-09-21  1:33 UTC (permalink / raw)
  To: Guennadi Liakhovetski, Laurent Pinchart; +Cc: linux-media

Hi, Guennadi

On 9/20/2015 11:25 PM, Guennadi Liakhovetski wrote:
> Hi Laurent, Josh,
>
> It's ok not to CC me immediately if it's expected, that patches will be
> further forwarded (by Josh in this case) to me. And it helps, that Josh
> has collected all Atmel ISI patches in a git tree branch - thanks! But,
> please make sure, that all patches also appear in my mailbox at least
> once, especially if they are (even trivially) modified - like in this
> case, where patches 2 and 3 have been merged into 1.
yes, got it. I will make sure of that in future. Thanks for the remind.

Best Regards,
Josh Wu
>
> Thanks
> Guennadi
>
> On Sat, 1 Aug 2015, Laurent Pinchart wrote:
>
>> Hello,
>>
>> While reviewing patches for the atmel-isi I noticed a couple of small issues
>> with the driver. Here's a patch series to fix them, the main change being the
>> removal of platform data support now that all users have migrated to DT.
>>
>> The patches have been compile-tested only. Josh, would you be able to test
>> them on hardware ?
>>
>> Laurent Pinchart (4):
>>    v4l: atmel-isi: Simplify error handling during DT parsing
>>    v4l: atmel-isi: Remove unused variable
>>    v4l: atmel-isi: Remove support for platform data
>>    v4l: atmel-isi: Remove unused platform data fields
>>
>>   drivers/media/platform/soc_camera/atmel-isi.c |  40 ++------
>>   drivers/media/platform/soc_camera/atmel-isi.h | 126 +++++++++++++++++++++++++
>>   include/media/atmel-isi.h                     | 131 --------------------------
>>   3 files changed, 136 insertions(+), 161 deletions(-)
>>   create mode 100644 drivers/media/platform/soc_camera/atmel-isi.h
>>   delete mode 100644 include/media/atmel-isi.h
>>
>> -- 
>> Regards,
>>
>> Laurent Pinchart
>>
>> --
>> To unsubscribe from this list: send the line "unsubscribe linux-media" in
>> the body of a message to majordomo@vger.kernel.org
>> More majordomo info at  http://vger.kernel.org/majordomo-info.html
>>


^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2015-09-21  1:33 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-08-01  9:22 [PATCH 0/4] atmel-isi: Remove platform data support Laurent Pinchart
2015-08-01  9:22 ` [PATCH 1/4] v4l: atmel-isi: Simplify error handling during DT parsing Laurent Pinchart
2015-08-01  9:22 ` [PATCH 2/4] v4l: atmel-isi: Remove unused variable Laurent Pinchart
2015-08-06  8:19   ` Josh Wu
2015-08-01  9:22 ` [PATCH 3/4] v4l: atmel-isi: Remove support for platform data Laurent Pinchart
2015-08-01  9:22 ` [PATCH 4/4] v4l: atmel-isi: Remove unused platform data fields Laurent Pinchart
2015-08-03  2:56 ` [PATCH 0/4] atmel-isi: Remove platform data support Josh Wu
2015-08-04 22:08   ` Laurent Pinchart
2015-08-05  3:31     ` Josh Wu
2015-09-20 15:25 ` Guennadi Liakhovetski
2015-09-21  1:33   ` Josh Wu

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).