* [PATCH] media: soc_camera: rcar_vin: Enable VSYNC field toggle mode
@ 2014-10-14 6:25 Yoshihiro Kaneko
2014-10-16 5:25 ` Simon Horman
2014-10-18 15:01 ` Sergei Shtylyov
0 siblings, 2 replies; 6+ messages in thread
From: Yoshihiro Kaneko @ 2014-10-14 6:25 UTC (permalink / raw)
To: linux-media; +Cc: Guennadi Liakhovetski, Simon Horman, Magnus Damm, linux-sh
From: Koji Matsuoka <koji.matsuoka.xm@renesas.com>
By applying this patch, it sets to VSYNC field toggle mode not only
at the time of progressive mode but at the time of an interlace mode.
Signed-off-by: Koji Matsuoka <koji.matsuoka.xm@renesas.com>
Signed-off-by: Yoshihiro Kaneko <ykaneko0929@gmail.com>
---
This patch is against master branch of linuxtv.org/media_tree.git.
drivers/media/platform/soc_camera/rcar_vin.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/media/platform/soc_camera/rcar_vin.c b/drivers/media/platform/soc_camera/rcar_vin.c
index 5196c81..bf97ed6 100644
--- a/drivers/media/platform/soc_camera/rcar_vin.c
+++ b/drivers/media/platform/soc_camera/rcar_vin.c
@@ -108,6 +108,7 @@
#define VNDMR2_VPS (1 << 30)
#define VNDMR2_HPS (1 << 29)
#define VNDMR2_FTEV (1 << 17)
+#define VNDMR2_VLV_1 (1 << 12)
#define VIN_MAX_WIDTH 2048
#define VIN_MAX_HEIGHT 2048
@@ -828,7 +829,7 @@ static int rcar_vin_set_bus_param(struct soc_camera_device *icd)
if (ret < 0 && ret != -ENOIOCTLCMD)
return ret;
- val = priv->field == V4L2_FIELD_NONE ? VNDMR2_FTEV : 0;
+ val = VNDMR2_FTEV | VNDMR2_VLV_1;
if (!(common_flags & V4L2_MBUS_VSYNC_ACTIVE_LOW))
val |= VNDMR2_VPS;
if (!(common_flags & V4L2_MBUS_HSYNC_ACTIVE_LOW))
--
1.9.1
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH] media: soc_camera: rcar_vin: Enable VSYNC field toggle mode
2014-10-14 6:25 [PATCH] media: soc_camera: rcar_vin: Enable VSYNC field toggle mode Yoshihiro Kaneko
@ 2014-10-16 5:25 ` Simon Horman
2014-10-18 15:01 ` Sergei Shtylyov
1 sibling, 0 replies; 6+ messages in thread
From: Simon Horman @ 2014-10-16 5:25 UTC (permalink / raw)
To: Yoshihiro Kaneko
Cc: linux-media, Guennadi Liakhovetski, Magnus Damm, linux-sh,
Mauro Carvalho Chehab
[CC Mauro Carvalho Chehab]
On Tue, Oct 14, 2014 at 03:25:56PM +0900, Yoshihiro Kaneko wrote:
> From: Koji Matsuoka <koji.matsuoka.xm@renesas.com>
>
> By applying this patch, it sets to VSYNC field toggle mode not only
> at the time of progressive mode but at the time of an interlace mode.
>
> Signed-off-by: Koji Matsuoka <koji.matsuoka.xm@renesas.com>
> Signed-off-by: Yoshihiro Kaneko <ykaneko0929@gmail.com>
Acked-by: Simon Horman <horms+renesas@verge.net.au>
If the series needs reposting to a different CC list -
e.g. including Mauro - please let Kaneko-san or myself know.
> ---
>
> This patch is against master branch of linuxtv.org/media_tree.git.
>
> drivers/media/platform/soc_camera/rcar_vin.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/media/platform/soc_camera/rcar_vin.c b/drivers/media/platform/soc_camera/rcar_vin.c
> index 5196c81..bf97ed6 100644
> --- a/drivers/media/platform/soc_camera/rcar_vin.c
> +++ b/drivers/media/platform/soc_camera/rcar_vin.c
> @@ -108,6 +108,7 @@
> #define VNDMR2_VPS (1 << 30)
> #define VNDMR2_HPS (1 << 29)
> #define VNDMR2_FTEV (1 << 17)
> +#define VNDMR2_VLV_1 (1 << 12)
>
> #define VIN_MAX_WIDTH 2048
> #define VIN_MAX_HEIGHT 2048
> @@ -828,7 +829,7 @@ static int rcar_vin_set_bus_param(struct soc_camera_device *icd)
> if (ret < 0 && ret != -ENOIOCTLCMD)
> return ret;
>
> - val = priv->field == V4L2_FIELD_NONE ? VNDMR2_FTEV : 0;
> + val = VNDMR2_FTEV | VNDMR2_VLV_1;
> if (!(common_flags & V4L2_MBUS_VSYNC_ACTIVE_LOW))
> val |= VNDMR2_VPS;
> if (!(common_flags & V4L2_MBUS_HSYNC_ACTIVE_LOW))
> --
> 1.9.1
>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-sh" 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] 6+ messages in thread
* Re: [PATCH] media: soc_camera: rcar_vin: Enable VSYNC field toggle mode
2014-10-14 6:25 [PATCH] media: soc_camera: rcar_vin: Enable VSYNC field toggle mode Yoshihiro Kaneko
2014-10-16 5:25 ` Simon Horman
@ 2014-10-18 15:01 ` Sergei Shtylyov
2014-10-21 3:30 ` Yoshihiro Kaneko
1 sibling, 1 reply; 6+ messages in thread
From: Sergei Shtylyov @ 2014-10-18 15:01 UTC (permalink / raw)
To: Yoshihiro Kaneko, linux-media
Cc: Guennadi Liakhovetski, Simon Horman, Magnus Damm, linux-sh
Hello.
On 10/14/2014 10:25 AM, Yoshihiro Kaneko wrote:
> From: Koji Matsuoka <koji.matsuoka.xm@renesas.com>
> By applying this patch, it sets to VSYNC field toggle mode not only
> at the time of progressive mode but at the time of an interlace mode.
> Signed-off-by: Koji Matsuoka <koji.matsuoka.xm@renesas.com>
> Signed-off-by: Yoshihiro Kaneko <ykaneko0929@gmail.com>
> ---
> This patch is against master branch of linuxtv.org/media_tree.git.
> drivers/media/platform/soc_camera/rcar_vin.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
> diff --git a/drivers/media/platform/soc_camera/rcar_vin.c b/drivers/media/platform/soc_camera/rcar_vin.c
> index 5196c81..bf97ed6 100644
> --- a/drivers/media/platform/soc_camera/rcar_vin.c
> +++ b/drivers/media/platform/soc_camera/rcar_vin.c
> @@ -108,6 +108,7 @@
> #define VNDMR2_VPS (1 << 30)
> #define VNDMR2_HPS (1 << 29)
> #define VNDMR2_FTEV (1 << 17)
> +#define VNDMR2_VLV_1 (1 << 12)
Please instead do:
#define VNDMR2_VLV(n) ((n & 0xf) << 12)
WBR, Sergei
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] media: soc_camera: rcar_vin: Enable VSYNC field toggle mode
2014-10-18 15:01 ` Sergei Shtylyov
@ 2014-10-21 3:30 ` Yoshihiro Kaneko
2014-10-21 7:09 ` Geert Uytterhoeven
0 siblings, 1 reply; 6+ messages in thread
From: Yoshihiro Kaneko @ 2014-10-21 3:30 UTC (permalink / raw)
To: Sergei Shtylyov
Cc: Linux Media Mailing List, Guennadi Liakhovetski, Simon Horman,
Magnus Damm, Linux-sh list
Hello Sergei,
Thank you for your comments.
2014-10-19 0:01 GMT+09:00 Sergei Shtylyov <sergei.shtylyov@cogentembedded.com>:
> Hello.
>
> On 10/14/2014 10:25 AM, Yoshihiro Kaneko wrote:
>
>> From: Koji Matsuoka <koji.matsuoka.xm@renesas.com>
>
>
>> By applying this patch, it sets to VSYNC field toggle mode not only
>> at the time of progressive mode but at the time of an interlace mode.
>
>
>> Signed-off-by: Koji Matsuoka <koji.matsuoka.xm@renesas.com>
>> Signed-off-by: Yoshihiro Kaneko <ykaneko0929@gmail.com>
>> ---
>
>
>> This patch is against master branch of linuxtv.org/media_tree.git.
>
>
>> drivers/media/platform/soc_camera/rcar_vin.c | 3 ++-
>> 1 file changed, 2 insertions(+), 1 deletion(-)
>
>
>> diff --git a/drivers/media/platform/soc_camera/rcar_vin.c
>> b/drivers/media/platform/soc_camera/rcar_vin.c
>> index 5196c81..bf97ed6 100644
>> --- a/drivers/media/platform/soc_camera/rcar_vin.c
>> +++ b/drivers/media/platform/soc_camera/rcar_vin.c
>> @@ -108,6 +108,7 @@
>> #define VNDMR2_VPS (1 << 30)
>> #define VNDMR2_HPS (1 << 29)
>> #define VNDMR2_FTEV (1 << 17)
>> +#define VNDMR2_VLV_1 (1 << 12)
>
>
> Please instead do:
>
> #define VNDMR2_VLV(n) ((n & 0xf) << 12)
It's unclear to me why the style of the new #define should differ
from those of the existing ones.
Thanks,
Kaneko
>
> WBR, Sergei
>
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] media: soc_camera: rcar_vin: Enable VSYNC field toggle mode
2014-10-21 3:30 ` Yoshihiro Kaneko
@ 2014-10-21 7:09 ` Geert Uytterhoeven
2014-10-22 3:17 ` Yoshihiro Kaneko
0 siblings, 1 reply; 6+ messages in thread
From: Geert Uytterhoeven @ 2014-10-21 7:09 UTC (permalink / raw)
To: Yoshihiro Kaneko
Cc: Sergei Shtylyov, Linux Media Mailing List, Guennadi Liakhovetski,
Simon Horman, Magnus Damm, Linux-sh list
Hi Kaneko-san,
On Tue, Oct 21, 2014 at 5:30 AM, Yoshihiro Kaneko <ykaneko0929@gmail.com> wrote:
>>> --- a/drivers/media/platform/soc_camera/rcar_vin.c
>>> +++ b/drivers/media/platform/soc_camera/rcar_vin.c
>>> @@ -108,6 +108,7 @@
>>> #define VNDMR2_VPS (1 << 30)
>>> #define VNDMR2_HPS (1 << 29)
>>> #define VNDMR2_FTEV (1 << 17)
>>> +#define VNDMR2_VLV_1 (1 << 12)
>>
>> Please instead do:
>>
>> #define VNDMR2_VLV(n) ((n & 0xf) << 12)
>
> It's unclear to me why the style of the new #define should differ
> from those of the existing ones.
I think Sergey wants to say that unlike for the other fields, there are
multiple possible values for the VLV field.
By providing the single macro definition
#define VNDMR2_VLV(n) ((n & 0xf) << 12)
you can easily provide a way to set any of VNDMR2_VLV_n.
I hope this explanation makes it clearer.
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org
In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] media: soc_camera: rcar_vin: Enable VSYNC field toggle mode
2014-10-21 7:09 ` Geert Uytterhoeven
@ 2014-10-22 3:17 ` Yoshihiro Kaneko
0 siblings, 0 replies; 6+ messages in thread
From: Yoshihiro Kaneko @ 2014-10-22 3:17 UTC (permalink / raw)
To: Geert Uytterhoeven
Cc: Sergei Shtylyov, Linux Media Mailing List, Guennadi Liakhovetski,
Simon Horman, Magnus Damm, Linux-sh list
Hi Geert-san,
2014-10-21 16:09 GMT+09:00 Geert Uytterhoeven <geert@linux-m68k.org>:
> Hi Kaneko-san,
>
> On Tue, Oct 21, 2014 at 5:30 AM, Yoshihiro Kaneko <ykaneko0929@gmail.com> wrote:
>>>> --- a/drivers/media/platform/soc_camera/rcar_vin.c
>>>> +++ b/drivers/media/platform/soc_camera/rcar_vin.c
>>>> @@ -108,6 +108,7 @@
>>>> #define VNDMR2_VPS (1 << 30)
>>>> #define VNDMR2_HPS (1 << 29)
>>>> #define VNDMR2_FTEV (1 << 17)
>>>> +#define VNDMR2_VLV_1 (1 << 12)
>>>
>>> Please instead do:
>>>
>>> #define VNDMR2_VLV(n) ((n & 0xf) << 12)
>>
>> It's unclear to me why the style of the new #define should differ
>> from those of the existing ones.
>
> I think Sergey wants to say that unlike for the other fields, there are
> multiple possible values for the VLV field.
>
> By providing the single macro definition
>
> #define VNDMR2_VLV(n) ((n & 0xf) << 12)
>
> you can easily provide a way to set any of VNDMR2_VLV_n.
>
> I hope this explanation makes it clearer.
Thank you for the clarification!
I'll update this patch sooner.
Thanks,
Kaneko
>
> Gr{oetje,eeting}s,
>
> Geert
>
> --
> Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org
>
> In personal conversations with technical people, I call myself a hacker. But
> when I'm talking to journalists I just say "programmer" or something like that.
> -- Linus Torvalds
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2014-10-22 3:17 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-10-14 6:25 [PATCH] media: soc_camera: rcar_vin: Enable VSYNC field toggle mode Yoshihiro Kaneko
2014-10-16 5:25 ` Simon Horman
2014-10-18 15:01 ` Sergei Shtylyov
2014-10-21 3:30 ` Yoshihiro Kaneko
2014-10-21 7:09 ` Geert Uytterhoeven
2014-10-22 3:17 ` Yoshihiro Kaneko
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).