Skip to contentSkip to conversation

s5p-fimc driver updates

GIT PULL Sylwester Nawrocki 3 participants 10 messages May 4, 2012 – May 20, 2012 Media (V4L/DVB)

lore
Share & tools
lore
#0 lore raw

Hi Mauro,

The following changes since commit 34b2debaa62bfa384ef91b61cf2c40c48e86a5e2:

s5p-fimc: Correct memory allocation for VIDIOC_CREATE_BUFS (2012-05-04 17:07:24 +0200)

are available in the git repository at:

git://git.infradead.org/users/kmpark/linux-samsung v4l-fimc-exynos4x12

for you to fetch changes up to bab96b068afa07105139be09d3830cc9ed580382:

s5p-fimc: Use selection API in place of crop operations (2012-05-04 17:18:38 +0200)

----------------------------------------------------------------
Sylwester Nawrocki (14):
V4L: Extend V4L2_CID_COLORFX with more image effects
s5p-fimc: Avoid crash with null platform_data
s5p-fimc: Move m2m node driver into separate file
s5p-fimc: Use v4l2_subdev internal ops to register video nodes
s5p-fimc: Refactor the register interface functions
s5p-fimc: Add FIMC-LITE register definitions
s5p-fimc: Rework the video pipeline control functions
s5p-fimc: Prefix format enumerations with FIMC_FMT_
s5p-fimc: Minor cleanups
s5p-fimc: Make sure an interrupt is properly requested
s5p-fimc: Add support for Exynos4x12 FIMC-LITE
s5p-fimc: Update copyright notices
s5p-fimc: Add color effect control
s5p-fimc: Use selection API in place of crop operations

 Documentation/DocBook/media/v4l/compat.xml   |   13 +
 Documentation/DocBook/media/v4l/controls.xml |   98 ++-
 Documentation/DocBook/media/v4l/v4l2.xml     |    5 +-
 drivers/media/video/Kconfig                  |   24 +-
 drivers/media/video/s5p-fimc/Kconfig         |   48 ++
 drivers/media/video/s5p-fimc/Makefile        |    6 +-
 drivers/media/video/s5p-fimc/fimc-capture.c  |  473 ++++++++-----
 drivers/media/video/s5p-fimc/fimc-core.c     | 1096 +++++-----------------------
 drivers/media/video/s5p-fimc/fimc-core.h     |  254 ++-----
 drivers/media/video/s5p-fimc/fimc-lite-reg.c |  300 ++++++++
 drivers/media/video/s5p-fimc/fimc-lite-reg.h |  150 ++++
 drivers/media/video/s5p-fimc/fimc-lite.c     | 1576 +++++++++++++++++++++++++++++++++++++++++
 drivers/media/video/s5p-fimc/fimc-lite.h     |  213 ++++++
 drivers/media/video/s5p-fimc/fimc-m2m.c      |  820 +++++++++++++++++++++
 drivers/media/video/s5p-fimc/fimc-mdevice.c  |  407 +++++++----
 drivers/media/video/s5p-fimc/fimc-mdevice.h  |   18 +-
 drivers/media/video/s5p-fimc/fimc-reg.c      |  613 ++++++++--------
 drivers/media/video/s5p-fimc/fimc-reg.h      |  326 +++++++++
 drivers/media/video/s5p-fimc/regs-fimc.h     |  301 --------
 drivers/media/video/v4l2-ctrls.c             |    7 +
 include/linux/videodev2.h                    |   29 +-
 include/media/s5p_fimc.h                     |   16 +
 22 files changed, 4734 insertions(+), 2059 deletions(-)
 create mode 100644 drivers/media/video/s5p-fimc/Kconfig
 create mode 100644 drivers/media/video/s5p-fimc/fimc-lite-reg.c
 create mode 100644 drivers/media/video/s5p-fimc/fimc-lite-reg.h
 create mode 100644 drivers/media/video/s5p-fimc/fimc-lite.c
 create mode 100644 drivers/media/video/s5p-fimc/fimc-lite.h
 create mode 100644 drivers/media/video/s5p-fimc/fimc-m2m.c
 create mode 100644 drivers/media/video/s5p-fimc/fimc-reg.h
 delete mode 100644 drivers/media/video/s5p-fimc/regs-fimc.h

I have added following 2 patches, from my previous pull request for 3.4-rc
(http://patchwork.linuxtv.org/patch/10888/), on top of staging/for_v3.5 as a base for this patch set:

34b2deb s5p-fimc: Correct memory allocation for VIDIOC_CREATE_BUFS 157495a s5p-fimc: Fix locking in subdev set_crop op

Regards

Signature · 2 lines
Sylwester Nawrocki
Samsung Poland R&D Center
#1 lore raw
Quoted 6 lines · Sylwester Nawrocki

Hi Mauro,

The following changes since commit 34b2debaa62bfa384ef91b61cf2c40c48e86a5e2:

s5p-fimc: Correct memory allocation for VIDIOC_CREATE_BUFS (2012-05-04 17:07:24 +0200)

Quoted 7 lines

are available in the git repository at:

git://git.infradead.org/users/kmpark/linux-samsung v4l-fimc-exynos4x12

for you to fetch changes up to bab96b068afa07105139be09d3830cc9ed580382:

s5p-fimc: Use selection API in place of crop operations (2012-05-04 17:18:38 +0200)

Mauro,

I've found a few issues in this series afterwards and re-edited 3 commits there. Here is an updated pull request:

The following changes since commit ae45d3e9aea0ab951dbbca2238fbfbf3993f1e7f:

s5p-fimc: Correct memory allocation for VIDIOC_CREATE_BUFS (2012-05-09 16:07:49 +0200)

are available in the git repository at:

git://git.infradead.org/users/kmpark/linux-samsung v4l-fimc-exynos4x12

for you to fetch changes up to 5feefe6656583de6fd4ef1d53b19031dd5efeec1:

s5p-fimc: Use selection API in place of crop operations (2012-05-09 16:11:29 +0200)

----------------------------------------------------------------
Sylwester Nawrocki (14):
V4L: Extend V4L2_CID_COLORFX with more image effects
s5p-fimc: Avoid crash with null platform_data
s5p-fimc: Move m2m node driver into separate file
s5p-fimc: Use v4l2_subdev internal ops to register video nodes
s5p-fimc: Refactor the register interface functions
s5p-fimc: Add FIMC-LITE register definitions
s5p-fimc: Rework the video pipeline control functions
s5p-fimc: Prefix format enumerations with FIMC_FMT_
s5p-fimc: Minor cleanups
s5p-fimc: Make sure an interrupt is properly requested
s5p-fimc: Add support for Exynos4x12 FIMC-LITE
s5p-fimc: Update copyright notices
s5p-fimc: Add color effect control
s5p-fimc: Use selection API in place of crop operations

 Documentation/DocBook/media/v4l/compat.xml   |   13 +
 Documentation/DocBook/media/v4l/controls.xml |   98 ++++++-
 Documentation/DocBook/media/v4l/v4l2.xml     |    5 +-
 drivers/media/video/Kconfig                  |   24 +-
 drivers/media/video/s5p-fimc/Kconfig         |   48 +++
 drivers/media/video/s5p-fimc/Makefile        |    6 +-
 drivers/media/video/s5p-fimc/fimc-capture.c  |  469 +++++++++++++++++++-----------
 drivers/media/video/s5p-fimc/fimc-core.c     | 1101 +++++++++++----------------------------------------------------------
 drivers/media/video/s5p-fimc/fimc-core.h     |  254 +++++-----------
 drivers/media/video/s5p-fimc/fimc-lite-reg.c |  300 +++++++++++++++++++
 drivers/media/video/s5p-fimc/fimc-lite-reg.h |  150 ++++++++++
 drivers/media/video/s5p-fimc/fimc-lite.c     | 1576 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 drivers/media/video/s5p-fimc/fimc-lite.h     |  213 ++++++++++++++
 drivers/media/video/s5p-fimc/fimc-m2m.c      |  820 +++++++++++++++++++++++++++++++++++++++++++++++++++
 drivers/media/video/s5p-fimc/fimc-mdevice.c  |  407 +++++++++++++++++---------
 drivers/media/video/s5p-fimc/fimc-mdevice.h  |   18 +-
 drivers/media/video/s5p-fimc/fimc-reg.c      |  613 +++++++++++++++++++++------------------
 drivers/media/video/s5p-fimc/fimc-reg.h      |  326 +++++++++++++++++++++
 drivers/media/video/s5p-fimc/regs-fimc.h     |  301 -------------------
 drivers/media/video/v4l2-ctrls.c             |    7 +
 include/linux/videodev2.h                    |   29 +-
 include/media/s5p_fimc.h                     |   16 +
 22 files changed, 4735 insertions(+), 2059 deletions(-)
 create mode 100644 drivers/media/video/s5p-fimc/Kconfig
 create mode 100644 drivers/media/video/s5p-fimc/fimc-lite-reg.c
 create mode 100644 drivers/media/video/s5p-fimc/fimc-lite-reg.h
 create mode 100644 drivers/media/video/s5p-fimc/fimc-lite.c
 create mode 100644 drivers/media/video/s5p-fimc/fimc-lite.h
 create mode 100644 drivers/media/video/s5p-fimc/fimc-m2m.c
 create mode 100644 drivers/media/video/s5p-fimc/fimc-reg.h
 delete mode 100644 drivers/media/video/s5p-fimc/regs-fimc.h

Sorry for the noise.

--

Thanks,
Sylwester

#2 lore raw
Quoted 30 lines · Sylwester Nawrocki
Quoted 6 lines · Sylwester Nawrocki

Hi Mauro,

The following changes since commit 34b2debaa62bfa384ef91b61cf2c40c48e86a5e2:

   s5p-fimc: Correct memory allocation for VIDIOC_CREATE_BUFS (2012-05-04 17:07:24 +0200)
Quoted 7 lines

are available in the git repository at:

git://git.infradead.org/users/kmpark/linux-samsung v4l-fimc-exynos4x12

for you to fetch changes up to bab96b068afa07105139be09d3830cc9ed580382:

s5p-fimc: Use selection API in place of crop operations (2012-05-04 17:18:38 +0200)

Mauro,

I've found a few issues in this series afterwards and re-edited 3 commits there. Here is an updated pull request:

The following changes since commit ae45d3e9aea0ab951dbbca2238fbfbf3993f1e7f:

   s5p-fimc: Correct memory allocation for VIDIOC_CREATE_BUFS (2012-05-09 16:07:49 +0200)

are available in the git repository at:

git://git.infradead.org/users/kmpark/linux-samsung v4l-fimc-exynos4x12

for you to fetch changes up to 5feefe6656583de6fd4ef1d53b19031dd5efeec1:

Quoted 7 lines

s5p-fimc: Use selection API in place of crop operations (2012-05-09 16:11:29 +0200)

----------------------------------------------------------------
Sylwester Nawrocki (14):
V4L: Extend V4L2_CID_COLORFX with more image effects
s5p-fimc: Avoid crash with null platform_data
s5p-fimc: Move m2m node driver into separate file

It seems there is a conflict now with this patch:
http://git.linuxtv.org/media_tree.git/commit/5126f2590bee412e3053de851cb07f531e4be36a

Attached are updated versions of the two conflicting patches, the others don't need touching.

I could provide rebased version of the whole change set tomorrow - if needed.

Kind regards,
Sylwester

Quoted 4 lines

s5p-fimc: Use v4l2_subdev internal ops to register video nodes
s5p-fimc: Refactor the register interface functions
s5p-fimc: Add FIMC-LITE register definitions
s5p-fimc: Rework the video pipeline control functions

Quoted 8 lines

s5p-fimc: Prefix format enumerations with FIMC_FMT_
s5p-fimc: Minor cleanups
s5p-fimc: Make sure an interrupt is properly requested
s5p-fimc: Add support for Exynos4x12 FIMC-LITE
s5p-fimc: Update copyright notices
s5p-fimc: Add color effect control
s5p-fimc: Use selection API in place of crop operations
From c962fb892bebe91e05f2b9f5348e8a390afe5f27 Mon Sep 17 00:00:00 2001

From: Sylwester Nawrocki <[email protected]>
Date: Mon, 14 May 2012 23:10:49 +0200
Subject: [PATCH 1/2] s5p-fimc: Move m2m node driver into separate file

Virtually no functional changes, just code reordering. This let us to clearly separate all logical functions available in the driver: fimc capture, mem-to-mem, and later fimc-lite capture, ISP features, etc.

---
 drivers/media/video/s5p-fimc/Makefile       |    2 +-
 drivers/media/video/s5p-fimc/fimc-capture.c |   68 ++-
 drivers/media/video/s5p-fimc/fimc-core.c    |  859 +--------------------------
 drivers/media/video/s5p-fimc/fimc-core.h    |   10 +-
 drivers/media/video/s5p-fimc/fimc-m2m.c     |  813 +++++++++++++++++++++++++
 5 files changed, 895 insertions(+), 857 deletions(-)
 create mode 100644 drivers/media/video/s5p-fimc/fimc-m2m.c
drivers/media/video/s5p-fimc/Makefile +1 -1
index 33dec7f..1da3c6a 100644
@@ -1,4 +1,4 @@
-s5p-fimc-objs := fimc-core.o fimc-reg.o fimc-capture.o fimc-mdevice.o
+s5p-fimc-objs := fimc-core.o fimc-reg.o fimc-m2m.o fimc-capture.o fimc-mdevice.o
 s5p-csis-objs := mipi-csis.o
 
 obj-$(CONFIG_VIDEO_S5P_MIPI_CSIS)	+= s5p-csis.o
drivers/media/video/s5p-fimc/fimc-capture.c +66 -2

86 lines not on this page · raw message

drivers/media/video/s5p-fimc/fimc-core.c +9 -850

909 lines not on this page · raw message

drivers/media/video/s5p-fimc/fimc-core.h +6 -4
index 7afabb0..288631a 100644
@@ -712,6 +712,7 @@ void fimc_adjust_mplane_format(struct fimc_fmt *fmt, u32 width, u32 height,
 			       struct v4l2_pix_format_mplane *pix);
 struct fimc_fmt *fimc_find_format(const u32 *pixelformat, const u32 *mbus_code,
 				  unsigned int mask, int index);
+struct fimc_fmt *fimc_get_format(unsigned int index);
 
 int fimc_check_scaler_ratio(struct fimc_ctx *ctx, int sw, int sh,
 			    int dw, int dh, int rotation);
@@ -722,7 +723,7 @@ int fimc_prepare_addr(struct fimc_ctx *ctx, struct vb2_buffer *vb,
 void fimc_prepare_dma_offset(struct fimc_ctx *ctx, struct fimc_frame *f);
 void fimc_set_yuv_order(struct fimc_ctx *ctx);
 void fimc_fill_frame(struct fimc_frame *frame, struct v4l2_format *f);
-void fimc_capture_irq_handler(struct fimc_dev *fimc, bool done);
+void fimc_capture_irq_handler(struct fimc_dev *fimc, int deq_buf);
 
 int fimc_register_m2m_device(struct fimc_dev *fimc,
 			     struct v4l2_device *v4l2_dev);
@@ -731,18 +732,19 @@ int fimc_register_driver(void);
 void fimc_unregister_driver(void);
 
 /* -----------------------------------------------------*/
+/* fimc-m2m.c */
+void fimc_m2m_job_finish(struct fimc_ctx *ctx, int vb_state);
+
+/* -----------------------------------------------------*/
 /* fimc-capture.c					*/
 int fimc_register_capture_device(struct fimc_dev *fimc,
 				 struct v4l2_device *v4l2_dev);
 void fimc_unregister_capture_device(struct fimc_dev *fimc);
 int fimc_capture_ctrls_create(struct fimc_dev *fimc);
-int fimc_vid_cap_buf_queue(struct fimc_dev *fimc,
-			     struct fimc_vid_buffer *fimc_vb);
 void fimc_sensor_notify(struct v4l2_subdev *sd, unsigned int notification,
 			void *arg);
 int fimc_capture_suspend(struct fimc_dev *fimc);
 int fimc_capture_resume(struct fimc_dev *fimc);
-int fimc_capture_config_update(struct fimc_ctx *ctx);
 
 /* Locking: the caller holds fimc->slock */
 static inline void fimc_activate_capture(struct fimc_ctx *ctx)
drivers/media/video/s5p-fimc/fimc-m2m.c new file +813 -0

813 lines not on this page · raw message

Signature · 1 line
1.7.4.1
Quoted 1 line

From 610f467a3cb02ca34ce48bb8d6cc3f2409571f93 Mon Sep 17 00:00:00 2001

From: Sylwester Nawrocki <[email protected]>
Date: Mon, 14 May 2012 23:15:21 +0200
Subject: [PATCH 2/2] s5p-fimc: Use v4l2_subdev internal ops to register video nodes

In order to be able to select only FIMC-LITE support, which is added with subsequent patches, the regular FIMC support is now contained only in fimc-core.c, fimc-m2m.c and fimc-capture.c files. The graph and pipeline management is now solely handled in fimc-mdevice.[ch]. This means the FIMC driver can now be excluded with Kconfig option, leaving only FIMC-LITE and allowing this driver to be reused in SoCs that have only FIMC-LITE and no regular FIMC IP.

---
 drivers/media/video/s5p-fimc/fimc-capture.c |  142 +++++++++++++++------------
 drivers/media/video/s5p-fimc/fimc-core.c    |   13 ++-
 drivers/media/video/s5p-fimc/fimc-core.h    |    7 +-
 drivers/media/video/s5p-fimc/fimc-m2m.c     |   18 +++-
 drivers/media/video/s5p-fimc/fimc-mdevice.c |   89 +++++++----------
 drivers/media/video/s5p-fimc/fimc-mdevice.h |    1 +
 6 files changed, 139 insertions(+), 131 deletions(-)
drivers/media/video/s5p-fimc/fimc-capture.c +77 -65

194 lines not on this page · raw message

drivers/media/video/s5p-fimc/fimc-core.c +9 -4
index 749db4d..add24cd 100644
@@ -842,8 +842,6 @@ static int fimc_probe(struct platform_device *pdev)
 	clk_set_rate(fimc->clock[CLK_BUS], drv_data->lclk_frequency);
 	clk_enable(fimc->clock[CLK_BUS]);
 
-	platform_set_drvdata(pdev, fimc);
-
 	ret = devm_request_irq(&pdev->dev, res->start, fimc_irq_handler,
 			       0, pdev->name, fimc);
 	if (ret) {
@@ -851,10 +849,15 @@ static int fimc_probe(struct platform_device *pdev)
 		goto err_clk;
 	}
 
+	ret = fimc_initialize_capture_subdev(fimc);
+	if (ret)
+		goto err_clk;
+
+	platform_set_drvdata(pdev, fimc);
 	pm_runtime_enable(&pdev->dev);
 	ret = pm_runtime_get_sync(&pdev->dev);
 	if (ret < 0)
-		goto err_clk;
+		goto err_sd;
 	/* Initialize contiguous memory allocator */
 	fimc->alloc_ctx = vb2_dma_contig_init_ctx(&pdev->dev);
 	if (IS_ERR(fimc->alloc_ctx)) {
@@ -866,9 +869,10 @@ static int fimc_probe(struct platform_device *pdev)
 
 	pm_runtime_put(&pdev->dev);
 	return 0;
-
 err_pm:
 	pm_runtime_put(&pdev->dev);
+err_sd:
+	fimc_unregister_capture_subdev(fimc);
 err_clk:
 	fimc_clk_put(fimc);
 	return ret;
@@ -953,6 +957,7 @@ static int __devexit fimc_remove(struct platform_device *pdev)
 	pm_runtime_disable(&pdev->dev);
 	pm_runtime_set_suspended(&pdev->dev);
 
+	fimc_unregister_capture_subdev(fimc);
 	vb2_dma_contig_cleanup_ctx(fimc->alloc_ctx);
 
 	clk_disable(fimc->clock[CLK_BUS]);
drivers/media/video/s5p-fimc/fimc-core.h +3 -4
index 288631a..ef7c6a2 100644
@@ -331,7 +331,7 @@ struct fimc_vid_cap {
 	struct fimc_ctx			*ctx;
 	struct vb2_alloc_ctx		*alloc_ctx;
 	struct video_device		*vfd;
-	struct v4l2_subdev		*subdev;
+	struct v4l2_subdev		subdev;
 	struct media_pad		vd_pad;
 	struct v4l2_mbus_framefmt	mf;
 	struct media_pad		sd_pads[FIMC_SD_PADS_NUM];
@@ -737,9 +737,8 @@ void fimc_m2m_job_finish(struct fimc_ctx *ctx, int vb_state);
 
 /* -----------------------------------------------------*/
 /* fimc-capture.c					*/
-int fimc_register_capture_device(struct fimc_dev *fimc,
-				 struct v4l2_device *v4l2_dev);
-void fimc_unregister_capture_device(struct fimc_dev *fimc);
+int fimc_initialize_capture_subdev(struct fimc_dev *fimc);
+void fimc_unregister_capture_subdev(struct fimc_dev *fimc);
 int fimc_capture_ctrls_create(struct fimc_dev *fimc);
 void fimc_sensor_notify(struct v4l2_subdev *sd, unsigned int notification,
 			void *arg);
drivers/media/video/s5p-fimc/fimc-m2m.c +15 -3
index 4a755ff..bb81126 100644
@@ -777,7 +777,8 @@ int fimc_register_m2m_device(struct fimc_dev *fimc,
 	 * This driver needs auditing so that this flag can be removed.
 	 */
 	set_bit(V4L2_FL_LOCK_ALL_FOPS, &vfd->flags);
-	snprintf(vfd->name, sizeof(vfd->name), "%s.m2m", dev_name(&pdev->dev));
+
+	snprintf(vfd->name, sizeof(vfd->name), "fimc.%d.m2m", fimc->id);
 	video_set_drvdata(vfd, fimc);
 
 	fimc->m2m.vfd = vfd;
@@ -789,9 +790,20 @@ int fimc_register_m2m_device(struct fimc_dev *fimc,
 	}
 
 	ret = media_entity_init(&vfd->entity, 0, NULL, 0);
-	if (!ret)
-		return 0;
+	if (ret)
+		goto err_me;
+
+	ret = video_register_device(vfd, VFL_TYPE_GRABBER, -1);
+	if (ret)
+		goto err_vd;
+
+	v4l2_info(v4l2_dev, "Registered %s as /dev/%s\n",
+		  vfd->name, video_device_node_name(vfd));
+	return 0;
 
+err_vd:
+	media_entity_cleanup(&vfd->entity);
+err_me:
 	v4l2_m2m_release(fimc->m2m.m2m_dev);
 err_init:
 	video_device_release(fimc->m2m.vfd);
drivers/media/video/s5p-fimc/fimc-mdevice.c +34 -55

153 lines not on this page · raw message

drivers/media/video/s5p-fimc/fimc-mdevice.h +1 -0
index da37808..4f3b69c 100644
@@ -24,6 +24,7 @@
 #define SENSOR_GROUP_ID		(1 << 8)
 #define CSIS_GROUP_ID		(1 << 9)
 #define WRITEBACK_GROUP_ID	(1 << 10)
+#define FIMC_GROUP_ID		(1 << 11)
 
 #define FIMC_MAX_SENSORS	8
 #define FIMC_MAX_CAMCLKS	2
Signature · 1 line
1.7.4.1
#3 lore raw

Hi Mauro,

Quoted 2 lines · Sylwester Nawrocki
Quoted 1 line · Sylwester Nawrocki

On 05/04/2012 05:31 PM, Sylwester Nawrocki wrote:

...

Quoted 23 lines
Quoted 15 lines

Mauro,

I've found a few issues in this series afterwards and re-edited 3 commits there. Here is an updated pull request:

The following changes since commit ae45d3e9aea0ab951dbbca2238fbfbf3993f1e7f:

   s5p-fimc: Correct memory allocation for VIDIOC_CREATE_BUFS (2012-05-09 16:07:49 +0200)

are available in the git repository at:

git://git.infradead.org/users/kmpark/linux-samsung v4l-fimc-exynos4x12

for you to fetch changes up to 5feefe6656583de6fd4ef1d53b19031dd5efeec1:

Quoted 7 lines

s5p-fimc: Use selection API in place of crop operations (2012-05-09 16:11:29 +0200)

----------------------------------------------------------------
Sylwester Nawrocki (14):
V4L: Extend V4L2_CID_COLORFX with more image effects
s5p-fimc: Avoid crash with null platform_data
s5p-fimc: Move m2m node driver into separate file

Quoted 7 lines

It seems there is a conflict now with this patch:
http://git.linuxtv.org/media_tree.git/commit/5126f2590bee412e3053de851cb07f531e4be36a

Attached are updated versions of the two conflicting patches, the others don't need touching.

I could provide rebased version of the whole change set tomorrow - if needed.

Here comes the updated change set:

The following changes since commit 152a3a7320d1582009db85d8be365ce430d079af:

[media] v4l2-dev: rename two functions (2012-05-14 15:06:50 -0300)

are available in the git repository at:

git://git.infradead.org/users/kmpark/linux-samsung v4l-fimc-exynos4x12

for you to fetch changes up to 7df337fdecb908d6b7762b0b6d9160a911d0cafe:

s5p-fimc: Use selection API in place of crop operations (2012-05-15 11:02:53
+0200)

----------------------------------------------------------------
Sylwester Nawrocki (14):
s5p-fimc: Correct memory allocation for VIDIOC_CREATE_BUFS
s5p-fimc: Avoid crash with null platform_data
s5p-fimc: Move m2m node driver into separate file
s5p-fimc: Use v4l2_subdev internal ops to register video nodes
s5p-fimc: Refactor the register interface functions
s5p-fimc: Add FIMC-LITE register definitions
s5p-fimc: Rework the video pipeline control functions
s5p-fimc: Prefix format enumerations with FIMC_FMT_
s5p-fimc: Minor cleanups
s5p-fimc: Make sure an interrupt is properly requested
s5p-fimc: Add support for Exynos4x12 FIMC-LITE
s5p-fimc: Update copyright notices
s5p-fimc: Add color effect control
s5p-fimc: Use selection API in place of crop operations

 drivers/media/video/Kconfig                  |   24 +-
 drivers/media/video/s5p-fimc/Kconfig         |   48 +++
 drivers/media/video/s5p-fimc/Makefile        |    6 +-
 drivers/media/video/s5p-fimc/fimc-capture.c  |  500
++++++++++++++++++++------------
 drivers/media/video/s5p-fimc/fimc-core.c     | 1109
+++++++++++----------------------------------------------------------
 drivers/media/video/s5p-fimc/fimc-core.h     |  256 +++++-----------
 drivers/media/video/s5p-fimc/fimc-lite-reg.c |  300 +++++++++++++++++++
 drivers/media/video/s5p-fimc/fimc-lite-reg.h |  150 ++++++++++
 drivers/media/video/s5p-fimc/fimc-lite.c     | 1576
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 drivers/media/video/s5p-fimc/fimc-lite.h     |  213 ++++++++++++++
 drivers/media/video/s5p-fimc/fimc-m2m.c      |  824
++++++++++++++++++++++++++++++++++++++++++++++++++++
 drivers/media/video/s5p-fimc/fimc-mdevice.c  |  407 +++++++++++++++++---------
 drivers/media/video/s5p-fimc/fimc-mdevice.h  |   18 +-
 drivers/media/video/s5p-fimc/fimc-reg.c      |  613
+++++++++++++++++++++------------------
 drivers/media/video/s5p-fimc/fimc-reg.h      |  326 +++++++++++++++++++++
 drivers/media/video/s5p-fimc/regs-fimc.h     |  301 -------------------
 include/media/s5p_fimc.h                     |   16 +
 17 files changed, 4635 insertions(+), 2052 deletions(-)
 create mode 100644 drivers/media/video/s5p-fimc/Kconfig
 create mode 100644 drivers/media/video/s5p-fimc/fimc-lite-reg.c
 create mode 100644 drivers/media/video/s5p-fimc/fimc-lite-reg.h
 create mode 100644 drivers/media/video/s5p-fimc/fimc-lite.c
 create mode 100644 drivers/media/video/s5p-fimc/fimc-lite.h
 create mode 100644 drivers/media/video/s5p-fimc/fimc-m2m.c
 create mode 100644 drivers/media/video/s5p-fimc/fimc-reg.h
 delete mode 100644 drivers/media/video/s5p-fimc/regs-fimc.h

--
Regards,
Sylwester

#4 lore raw
In reply to Sylwester Nawrocki

Em 14-05-2012 18:39, Sylwester Nawrocki escreveu:

Quoted 39 lines · Sylwester Nawrocki
Quoted 30 lines · Sylwester Nawrocki
Quoted 6 lines

Hi Mauro,

The following changes since commit 34b2debaa62bfa384ef91b61cf2c40c48e86a5e2:

   s5p-fimc: Correct memory allocation for VIDIOC_CREATE_BUFS (2012-05-04 17:07:24 +0200)
Quoted 7 lines

are available in the git repository at:

git://git.infradead.org/users/kmpark/linux-samsung v4l-fimc-exynos4x12

for you to fetch changes up to bab96b068afa07105139be09d3830cc9ed580382:

s5p-fimc: Use selection API in place of crop operations (2012-05-04 17:18:38 +0200)

Mauro,

I've found a few issues in this series afterwards and re-edited 3 commits there. Here is an updated pull request:

The following changes since commit ae45d3e9aea0ab951dbbca2238fbfbf3993f1e7f:

   s5p-fimc: Correct memory allocation for VIDIOC_CREATE_BUFS (2012-05-09 16:07:49 +0200)

are available in the git repository at:

git://git.infradead.org/users/kmpark/linux-samsung v4l-fimc-exynos4x12

for you to fetch changes up to 5feefe6656583de6fd4ef1d53b19031dd5efeec1:

Quoted 7 lines

s5p-fimc: Use selection API in place of crop operations (2012-05-09 16:11:29 +0200)

----------------------------------------------------------------
Sylwester Nawrocki (14):
V4L: Extend V4L2_CID_COLORFX with more image effects
s5p-fimc: Avoid crash with null platform_data
s5p-fimc: Move m2m node driver into separate file

Quoted 7 lines

It seems there is a conflict now with this patch:
http://git.linuxtv.org/media_tree.git/commit/5126f2590bee412e3053de851cb07f531e4be36a

Attached are updated versions of the two conflicting patches, the others don't need touching.

I could provide rebased version of the whole change set tomorrow - if needed.

Please do that, as this patch doesn't apply as-is.

Regards,
Mauro

$ quilt push
Applying patch patches/lmml_11243_git_pull_for_3_5_s5p_fimc_driver_updates.patch
patching file drivers/media/video/s5p-fimc/fimc-capture.c
Hunk #1 FAILED at 993.
Hunk #2 FAILED at 1489.
Hunk #3 FAILED at 1554.
Hunk #4 FAILED at 1572.
Hunk #5 FAILED at 1580.
Hunk #6 FAILED at 1616.
Hunk #7 FAILED at 1636.
7 out of 7 hunks FAILED -- rejects in file drivers/media/video/s5p-fimc/fimc-capture.c
patching file drivers/media/video/s5p-fimc/fimc-core.c
Hunk #1 FAILED at 842.
Hunk #2 FAILED at 851.
Hunk #3 FAILED at 866.
Hunk #4 FAILED at 953.
4 out of 4 hunks FAILED -- rejects in file drivers/media/video/s5p-fimc/fimc-core.c
patching file drivers/media/video/s5p-fimc/fimc-core.h
Hunk #1 FAILED at 331.
Hunk #2 FAILED at 737.
2 out of 2 hunks FAILED -- rejects in file drivers/media/video/s5p-fimc/fimc-core.h
patching file drivers/media/video/s5p-fimc/fimc-m2m.c
Hunk #1 FAILED at 777.
Hunk #2 FAILED at 789.
2 out of 2 hunks FAILED -- rejects in file drivers/media/video/s5p-fimc/fimc-m2m.c
patching file drivers/media/video/s5p-fimc/fimc-mdevice.c
Hunk #1 FAILED at 304.
Hunk #2 FAILED at 313.
Hunk #3 FAILED at 401.
Hunk #4 FAILED at 420.
Hunk #5 FAILED at 479.
Hunk #6 FAILED at 588.
Hunk #7 FAILED at 817.
7 out of 7 hunks FAILED -- rejects in file drivers/media/video/s5p-fimc/fimc-mdevice.c
patching file drivers/media/video/s5p-fimc/fimc-mdevice.h
Hunk #1 FAILED at 24.
1 out of 1 hunk FAILED -- rejects in file drivers/media/video/s5p-fimc/fimc-mdevice.h
#5 lore raw
Quoted 3 lines · Mauro Carvalho Chehab

Em 14-05-2012 18:39, Sylwester Nawrocki escreveu:

Quoted 2 lines · Sylwester Nawrocki
Quoted 1 line · Sylwester Nawrocki

...

Quoted 21 lines
Quoted 21 lines
Quoted 10 lines

The following changes since commit ae45d3e9aea0ab951dbbca2238fbfbf3993f1e7f:

    s5p-fimc: Correct memory allocation for VIDIOC_CREATE_BUFS (2012-05-09 16:07:49 +0200)

are available in the git repository at:

git://git.infradead.org/users/kmpark/linux-samsung v4l-fimc-exynos4x12

for you to fetch changes up to 5feefe6656583de6fd4ef1d53b19031dd5efeec1:

Quoted 7 lines
    s5p-fimc: Use selection API in place of crop operations (2012-05-09 16:11:29 +0200)

----------------------------------------------------------------
Sylwester Nawrocki (14):
V4L: Extend V4L2_CID_COLORFX with more image effects
s5p-fimc: Avoid crash with null platform_data
s5p-fimc: Move m2m node driver into separate file

It seems there is a conflict now with this patch:
http://git.linuxtv.org/media_tree.git/commit/5126f2590bee412e3053de851cb07f531e4be36a

Quoted 6 lines
Quoted 4 lines

Attached are updated versions of the two conflicting patches, the others don't need touching.

I could provide rebased version of the whole change set tomorrow - if needed.

Please do that, as this patch doesn't apply as-is.

I guess there is no intervention from my side needed, since you already applied those updated patches to the media tree (since I pushed the rebased patch to git.infradead.org a few days ago already) ?

However, there is going to be conflicts now with my patch from Sakari's pull
request: http://patchwork.linuxtv.org/patch/11336.

As we talked in #v4l IRC, even if the API is experimental, any changes to it must not cause build breaks. I didn't discuss that yet with Sakari. I have now reworked the renaming patch, so it now includes backward compatibility definitions like this:

#define V4L2_SEL_TGT_CROP_ACTIVE V4L2_SEL_TGT_CROP
#define V4L2_SEL_TGT_COMPOSE_ACTIVE V4L2_SEL_TGT_COMPOSE

I would then make a patch for Documentation/feature-removal-schedule.txt to indicate those aliases will be removed after two kernel releases.

Does it sound like a right thing to do ?

Regards,
Sylwester

#6 lore raw

Em 20-05-2012 11:05, Sylwester Nawrocki escreveu:

Quoted 31 lines · Mauro Carvalho Chehab
Quoted 3 lines

Em 14-05-2012 18:39, Sylwester Nawrocki escreveu:

Quoted 2 lines · Sylwester Nawrocki
Quoted 1 line · Sylwester Nawrocki

...

Quoted 26 lines
Quoted 25 lines
Quoted 10 lines

The following changes since commit ae45d3e9aea0ab951dbbca2238fbfbf3993f1e7f:

    s5p-fimc: Correct memory allocation for VIDIOC_CREATE_BUFS (2012-05-09 16:07:49 +0200)

are available in the git repository at:

git://git.infradead.org/users/kmpark/linux-samsung v4l-fimc-exynos4x12

for you to fetch changes up to 5feefe6656583de6fd4ef1d53b19031dd5efeec1:

Quoted 7 lines
    s5p-fimc: Use selection API in place of crop operations (2012-05-09 16:11:29 +0200)

----------------------------------------------------------------
Sylwester Nawrocki (14):
V4L: Extend V4L2_CID_COLORFX with more image effects
s5p-fimc: Avoid crash with null platform_data
s5p-fimc: Move m2m node driver into separate file

It seems there is a conflict now with this patch:
http://git.linuxtv.org/media_tree.git/commit/5126f2590bee412e3053de851cb07f531e4be36a

Attached are updated versions of the two conflicting patches, the others don't need touching.

I could provide rebased version of the whole change set tomorrow - if needed.

Quoted 8 lines
Quoted 1 line

Please do that, as this patch doesn't apply as-is.

I guess there is no intervention from my side needed, since you already applied those updated patches to the media tree (since I pushed the rebased patch to git.infradead.org a few days ago already) ?

However, there is going to be conflicts now with my patch from Sakari's pull
request: http://patchwork.linuxtv.org/patch/11336.

Yes. I didn't apply that patch. It needs rework.

Quoted 6 lines

As we talked in #v4l IRC, even if the API is experimental, any changes to it must not cause build breaks. I didn't discuss that yet with Sakari. I have now reworked the renaming patch, so it now includes backward compatibility definitions like this:

Quoted 7 lines

#define V4L2_SEL_TGT_CROP_ACTIVE V4L2_SEL_TGT_CROP
#define V4L2_SEL_TGT_COMPOSE_ACTIVE V4L2_SEL_TGT_COMPOSE

I would then make a patch for Documentation/feature-removal-schedule.txt to indicate those aliases will be removed after two kernel releases.

Does it sound like a right thing to do ?

_If_ 3.5 is the first kernel with the selection API, we can fix it without a backward compat, but I think that the selection API went into 3.4 kernel series.

Regards,
Mauro

#7 lore raw
Quoted 52 lines · Mauro Carvalho Chehab

Em 20-05-2012 11:05, Sylwester Nawrocki escreveu:

Quoted 31 lines · Mauro Carvalho Chehab
Quoted 3 lines

Em 14-05-2012 18:39, Sylwester Nawrocki escreveu:

Quoted 2 lines · Sylwester Nawrocki
Quoted 1 line · Sylwester Nawrocki

...

Quoted 26 lines
Quoted 25 lines
Quoted 10 lines

The following changes since commit ae45d3e9aea0ab951dbbca2238fbfbf3993f1e7f:

     s5p-fimc: Correct memory allocation for VIDIOC_CREATE_BUFS (2012-05-09 16:07:49 +0200)

are available in the git repository at:

git://git.infradead.org/users/kmpark/linux-samsung v4l-fimc-exynos4x12

for you to fetch changes up to 5feefe6656583de6fd4ef1d53b19031dd5efeec1:

Quoted 7 lines
     s5p-fimc: Use selection API in place of crop operations (2012-05-09 16:11:29 +0200)

----------------------------------------------------------------
Sylwester Nawrocki (14):
V4L: Extend V4L2_CID_COLORFX with more image effects
s5p-fimc: Avoid crash with null platform_data
s5p-fimc: Move m2m node driver into separate file

It seems there is a conflict now with this patch:
http://git.linuxtv.org/media_tree.git/commit/5126f2590bee412e3053de851cb07f531e4be36a

Attached are updated versions of the two conflicting patches, the others don't need touching.

I could provide rebased version of the whole change set tomorrow - if needed.

Quoted 8 lines
Quoted 1 line

Please do that, as this patch doesn't apply as-is.

I guess there is no intervention from my side needed, since you already applied those updated patches to the media tree (since I pushed the rebased patch to git.infradead.org a few days ago already) ?

However, there is going to be conflicts now with my patch from Sakari's pull
request: http://patchwork.linuxtv.org/patch/11336.

Yes. I didn't apply that patch. It needs rework.

Quoted 9 lines

As we talked in #v4l IRC, even if the API is experimental, any changes to it must not cause build breaks. I didn't discuss that yet with Sakari. I have now reworked the renaming patch, so it now includes backward compatibility definitions like this:

#define V4L2_SEL_TGT_CROP_ACTIVE V4L2_SEL_TGT_CROP
#define V4L2_SEL_TGT_COMPOSE_ACTIVE V4L2_SEL_TGT_COMPOSE

Quoted 8 lines
Quoted 4 lines

I would then make a patch for Documentation/feature-removal-schedule.txt to indicate those aliases will be removed after two kernel releases.

Does it sound like a right thing to do ?

_If_ 3.5 is the first kernel with the selection API, we can fix it without a backward compat, but I think that the selection API went into 3.4 kernel series.

Yeah, only the selection API for subdevs is first appearing in kernel 3.5, and it's been already two stable kernel releases since the selection API was introduced:

$ git log --oneline v3.0..v3.3 -- Documentation/DocBook/media/v4l/vidioc-g-selection.xml
8af4922 [media] doc: v4l: add documentation for selection API 

So some backward compatibility code seems to be needed. It's not really a big deal and would saved users headaches.

--
Regards,
Sylwester

#8 lore raw
In reply to Sylwester Nawrocki

Em 04-05-2012 12:31, Sylwester Nawrocki escreveu:

Quoted 9 lines

Hi Mauro,

The following changes since commit 34b2debaa62bfa384ef91b61cf2c40c48e86a5e2:

s5p-fimc: Correct memory allocation for VIDIOC_CREATE_BUFS (2012-05-04 17:07:24 +0200)

are available in the git repository at:

git://git.infradead.org/users/kmpark/linux-samsung v4l-fimc-exynos4x12

It seems that there are something wrong with this tree:

git pull git://git.infradead.org/users/kmpark/linux-samsung v4l-fimc-exynos4x12
warning: no common commits
Counting objects: 1793460

Regards,
Mauro

#9 lore raw

Em 14-05-2012 10:04, Mauro Carvalho Chehab escreveu:

Quoted 9 lines

Em 04-05-2012 12:31, Sylwester Nawrocki escreveu:

Quoted 8 lines

Hi Mauro,

The following changes since commit 34b2debaa62bfa384ef91b61cf2c40c48e86a5e2:

s5p-fimc: Correct memory allocation for VIDIOC_CREATE_BUFS (2012-05-04 17:07:24 +0200)

are available in the git repository at:

Quoted 7 lines
Quoted 1 line

git://git.infradead.org/users/kmpark/linux-samsung v4l-fimc-exynos4x12

It seems that there are something wrong with this tree:

git pull git://git.infradead.org/users/kmpark/linux-samsung v4l-fimc-exynos4x12
warning: no common commits
Counting objects: 1793460

Please discard this comment. I was at the wrong directory.

Regards,
Mauro

Quoted 3 lines

Regards,
Mauro