* [PATCH 0/4] Miscellaneous omap3-isp patches
@ 2011-11-16 20:06 Laurent Pinchart
2011-11-16 20:06 ` [PATCH 1/4] omap3isp: preview: Rename max output sizes defines Laurent Pinchart
` (4 more replies)
0 siblings, 5 replies; 6+ messages in thread
From: Laurent Pinchart @ 2011-11-16 20:06 UTC (permalink / raw)
To: linux-media; +Cc: sakari.ailus
Hi everybody,
The subject says it all. Two of the patches fix crashes, while the other two
are minor modifications with no impact on the compiled code. I'll push them
for v3.3.
Laurent Pinchart (4):
omap3isp: preview: Rename max output sizes defines
omap3isp: ccdc: Fix crash in HS/VS interrupt handler
omap3isp: Fix crash caused by subdevs now having a pointer to
devnodes
omap3isp: Clarify the clk_pol field in platform data
drivers/media/video/omap3isp/ispccdc.c | 5 ++---
drivers/media/video/omap3isp/isppreview.c | 16 ++++++++--------
drivers/media/video/omap3isp/ispstat.c | 2 +-
include/media/omap3isp.h | 2 +-
4 files changed, 12 insertions(+), 13 deletions(-)
--
Regards,
Laurent Pinchart
^ permalink raw reply [flat|nested] 6+ messages in thread
* [PATCH 1/4] omap3isp: preview: Rename max output sizes defines
2011-11-16 20:06 [PATCH 0/4] Miscellaneous omap3-isp patches Laurent Pinchart
@ 2011-11-16 20:06 ` Laurent Pinchart
2011-11-16 20:06 ` [PATCH 2/4] omap3isp: ccdc: Fix crash in HS/VS interrupt handler Laurent Pinchart
` (3 subsequent siblings)
4 siblings, 0 replies; 6+ messages in thread
From: Laurent Pinchart @ 2011-11-16 20:06 UTC (permalink / raw)
To: linux-media; +Cc: sakari.ailus
The maximum preview engine output size depends on the ISP revision, not
the OMAP revision. Rename the macros accordingly.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
---
drivers/media/video/omap3isp/isppreview.c | 16 ++++++++--------
1 files changed, 8 insertions(+), 8 deletions(-)
diff --git a/drivers/media/video/omap3isp/isppreview.c b/drivers/media/video/omap3isp/isppreview.c
index ccb876f..28a1232 100644
--- a/drivers/media/video/omap3isp/isppreview.c
+++ b/drivers/media/video/omap3isp/isppreview.c
@@ -116,11 +116,11 @@ static struct omap3isp_prev_csc flr_prev_csc = {
#define PREV_MIN_IN_HEIGHT 8
#define PREV_MAX_IN_HEIGHT 16384
-#define PREV_MIN_OUT_WIDTH 0
-#define PREV_MIN_OUT_HEIGHT 0
-#define PREV_MAX_OUT_WIDTH 1280
-#define PREV_MAX_OUT_WIDTH_ES2 3300
-#define PREV_MAX_OUT_WIDTH_3630 4096
+#define PREV_MIN_OUT_WIDTH 0
+#define PREV_MIN_OUT_HEIGHT 0
+#define PREV_MAX_OUT_WIDTH_REV_1 1280
+#define PREV_MAX_OUT_WIDTH_REV_2 3300
+#define PREV_MAX_OUT_WIDTH_REV_15 4096
/*
* Coeficient Tables for the submodules in Preview.
@@ -1306,14 +1306,14 @@ static unsigned int preview_max_out_width(struct isp_prev_device *prev)
switch (isp->revision) {
case ISP_REVISION_1_0:
- return PREV_MAX_OUT_WIDTH;
+ return PREV_MAX_OUT_WIDTH_REV_1;
case ISP_REVISION_2_0:
default:
- return PREV_MAX_OUT_WIDTH_ES2;
+ return PREV_MAX_OUT_WIDTH_REV_2;
case ISP_REVISION_15_0:
- return PREV_MAX_OUT_WIDTH_3630;
+ return PREV_MAX_OUT_WIDTH_REV_15;
}
}
--
1.7.3.4
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [PATCH 2/4] omap3isp: ccdc: Fix crash in HS/VS interrupt handler
2011-11-16 20:06 [PATCH 0/4] Miscellaneous omap3-isp patches Laurent Pinchart
2011-11-16 20:06 ` [PATCH 1/4] omap3isp: preview: Rename max output sizes defines Laurent Pinchart
@ 2011-11-16 20:06 ` Laurent Pinchart
2011-11-16 20:06 ` [PATCH 3/4] omap3isp: Fix crash caused by subdevs now having a pointer to devnodes Laurent Pinchart
` (2 subsequent siblings)
4 siblings, 0 replies; 6+ messages in thread
From: Laurent Pinchart @ 2011-11-16 20:06 UTC (permalink / raw)
To: linux-media; +Cc: sakari.ailus
The HS/VS interrupt handler needs to access the pipeline object. It
erronously tries to get it from the CCDC output video node, which isn't
necessarily included in the pipeline. This leads to a NULL pointer
dereference.
Fix the bug by getting the pipeline object from the CCDC subdev entity.
Reported-by: Gary Thomas <gary@mlbassoc.com>
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
---
drivers/media/video/omap3isp/ispccdc.c | 3 +--
1 files changed, 1 insertions(+), 2 deletions(-)
diff --git a/drivers/media/video/omap3isp/ispccdc.c b/drivers/media/video/omap3isp/ispccdc.c
index b0b0fa5..9012b57 100644
--- a/drivers/media/video/omap3isp/ispccdc.c
+++ b/drivers/media/video/omap3isp/ispccdc.c
@@ -1406,8 +1406,7 @@ static int __ccdc_handle_stopping(struct isp_ccdc_device *ccdc, u32 event)
static void ccdc_hs_vs_isr(struct isp_ccdc_device *ccdc)
{
- struct isp_pipeline *pipe =
- to_isp_pipeline(&ccdc->video_out.video.entity);
+ struct isp_pipeline *pipe = to_isp_pipeline(&ccdc->subdev.entity);
struct video_device *vdev = &ccdc->subdev.devnode;
struct v4l2_event event;
--
1.7.3.4
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [PATCH 3/4] omap3isp: Fix crash caused by subdevs now having a pointer to devnodes
2011-11-16 20:06 [PATCH 0/4] Miscellaneous omap3-isp patches Laurent Pinchart
2011-11-16 20:06 ` [PATCH 1/4] omap3isp: preview: Rename max output sizes defines Laurent Pinchart
2011-11-16 20:06 ` [PATCH 2/4] omap3isp: ccdc: Fix crash in HS/VS interrupt handler Laurent Pinchart
@ 2011-11-16 20:06 ` Laurent Pinchart
2011-11-16 20:06 ` [PATCH 4/4] omap3isp: Clarify the clk_pol field in platform data Laurent Pinchart
2011-11-16 20:13 ` [PATCH 0/4] Miscellaneous omap3-isp patches Sakari Ailus
4 siblings, 0 replies; 6+ messages in thread
From: Laurent Pinchart @ 2011-11-16 20:06 UTC (permalink / raw)
To: linux-media; +Cc: sakari.ailus
Commit 3e0ec41c5c5ee14e27f65e28d4a616de34f59a97 ("V4L: dynamically
allocate video_device nodes in subdevices") makes the
v4l2_subdev::devnode field a pointer to a struct video_device instead of
embedding video_device directly.
Fix accesses to the devnode accordingly.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
---
drivers/media/video/omap3isp/ispccdc.c | 2 +-
drivers/media/video/omap3isp/ispstat.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/media/video/omap3isp/ispccdc.c b/drivers/media/video/omap3isp/ispccdc.c
index 9012b57..a319281 100644
--- a/drivers/media/video/omap3isp/ispccdc.c
+++ b/drivers/media/video/omap3isp/ispccdc.c
@@ -1407,7 +1407,7 @@ static int __ccdc_handle_stopping(struct isp_ccdc_device *ccdc, u32 event)
static void ccdc_hs_vs_isr(struct isp_ccdc_device *ccdc)
{
struct isp_pipeline *pipe = to_isp_pipeline(&ccdc->subdev.entity);
- struct video_device *vdev = &ccdc->subdev.devnode;
+ struct video_device *vdev = ccdc->subdev.devnode;
struct v4l2_event event;
memset(&event, 0, sizeof(event));
diff --git a/drivers/media/video/omap3isp/ispstat.c b/drivers/media/video/omap3isp/ispstat.c
index 68d5394..bc0b2c7 100644
--- a/drivers/media/video/omap3isp/ispstat.c
+++ b/drivers/media/video/omap3isp/ispstat.c
@@ -496,7 +496,7 @@ static int isp_stat_bufs_alloc(struct ispstat *stat, u32 size)
static void isp_stat_queue_event(struct ispstat *stat, int err)
{
- struct video_device *vdev = &stat->subdev.devnode;
+ struct video_device *vdev = stat->subdev.devnode;
struct v4l2_event event;
struct omap3isp_stat_event_status *status = (void *)event.u.data;
--
1.7.3.4
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [PATCH 4/4] omap3isp: Clarify the clk_pol field in platform data
2011-11-16 20:06 [PATCH 0/4] Miscellaneous omap3-isp patches Laurent Pinchart
` (2 preceding siblings ...)
2011-11-16 20:06 ` [PATCH 3/4] omap3isp: Fix crash caused by subdevs now having a pointer to devnodes Laurent Pinchart
@ 2011-11-16 20:06 ` Laurent Pinchart
2011-11-16 20:13 ` [PATCH 0/4] Miscellaneous omap3-isp patches Sakari Ailus
4 siblings, 0 replies; 6+ messages in thread
From: Laurent Pinchart @ 2011-11-16 20:06 UTC (permalink / raw)
To: linux-media; +Cc: sakari.ailus
The field is used to select the polarity of the pixel clock signal.
"Inverted" and "non inverted" are bad descriptions, specify instead on
which clock edge the signals are sampled.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
---
include/media/omap3isp.h | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/include/media/omap3isp.h b/include/media/omap3isp.h
index e917b1d..042849a 100644
--- a/include/media/omap3isp.h
+++ b/include/media/omap3isp.h
@@ -58,7 +58,7 @@ enum {
* ISP_LANE_SHIFT_4 - CAMEXT[13:4] -> CAM[9:0]
* ISP_LANE_SHIFT_6 - CAMEXT[13:6] -> CAM[7:0]
* @clk_pol: Pixel clock polarity
- * 0 - Non Inverted, 1 - Inverted
+ * 0 - Sample on rising edge, 1 - Sample on falling edge
* @hs_pol: Horizontal synchronization polarity
* 0 - Active high, 1 - Active low
* @vs_pol: Vertical synchronization polarity
--
1.7.3.4
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH 0/4] Miscellaneous omap3-isp patches
2011-11-16 20:06 [PATCH 0/4] Miscellaneous omap3-isp patches Laurent Pinchart
` (3 preceding siblings ...)
2011-11-16 20:06 ` [PATCH 4/4] omap3isp: Clarify the clk_pol field in platform data Laurent Pinchart
@ 2011-11-16 20:13 ` Sakari Ailus
4 siblings, 0 replies; 6+ messages in thread
From: Sakari Ailus @ 2011-11-16 20:13 UTC (permalink / raw)
To: Laurent Pinchart; +Cc: linux-media
Laurent Pinchart wrote:
> Hi everybody,
>
> The subject says it all. Two of the patches fix crashes, while the other two
> are minor modifications with no impact on the compiled code. I'll push them
> for v3.3.
>
> Laurent Pinchart (4):
> omap3isp: preview: Rename max output sizes defines
> omap3isp: ccdc: Fix crash in HS/VS interrupt handler
> omap3isp: Fix crash caused by subdevs now having a pointer to
> devnodes
> omap3isp: Clarify the clk_pol field in platform data
>
> drivers/media/video/omap3isp/ispccdc.c | 5 ++---
> drivers/media/video/omap3isp/isppreview.c | 16 ++++++++--------
> drivers/media/video/omap3isp/ispstat.c | 2 +-
> include/media/omap3isp.h | 2 +-
> 4 files changed, 12 insertions(+), 13 deletions(-)
Thanks, Laurent!
Acked-by: Sakari Ailus <sakari.ailus@iki.fi>
--
Sakari Ailus
sakari.ailus@iki.fi
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2011-11-16 20:13 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-11-16 20:06 [PATCH 0/4] Miscellaneous omap3-isp patches Laurent Pinchart
2011-11-16 20:06 ` [PATCH 1/4] omap3isp: preview: Rename max output sizes defines Laurent Pinchart
2011-11-16 20:06 ` [PATCH 2/4] omap3isp: ccdc: Fix crash in HS/VS interrupt handler Laurent Pinchart
2011-11-16 20:06 ` [PATCH 3/4] omap3isp: Fix crash caused by subdevs now having a pointer to devnodes Laurent Pinchart
2011-11-16 20:06 ` [PATCH 4/4] omap3isp: Clarify the clk_pol field in platform data Laurent Pinchart
2011-11-16 20:13 ` [PATCH 0/4] Miscellaneous omap3-isp patches Sakari Ailus
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox