Re: [PATCH 1/3] [media] tc358743: Correct clock mode reported in g_mbus_config

2017-09-21 Thread Philipp Zabel
On Tue, 2017-09-19 at 14:08 +0100, Dave Stevenson wrote:
> Support for non-continuous clock had previously been added via
> device tree, but a comment and the value reported by g_mbus_config
> still stated that it wasn't supported.
> Remove the comment, and return the correct value in g_mbus_config.
> 
> Signed-off-by: Dave Stevenson 
> ---
>  drivers/media/i2c/tc358743.c | 5 +++--
>  1 file changed, 3 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/media/i2c/tc358743.c
> b/drivers/media/i2c/tc358743.c
> index e6f5c36..6b0fd07 100644
> --- a/drivers/media/i2c/tc358743.c
> +++ b/drivers/media/i2c/tc358743.c
> @@ -1461,8 +1461,9 @@ static int tc358743_g_mbus_config(struct
> v4l2_subdev *sd,
>  
>   cfg->type = V4L2_MBUS_CSI2;
>  
> - /* Support for non-continuous CSI-2 clock is missing in the
> driver */
> - cfg->flags = V4L2_MBUS_CSI2_CONTINUOUS_CLOCK;
> + cfg->flags = state->bus.flags &
> + (V4L2_MBUS_CSI2_CONTINUOUS_CLOCK |
> +  V4L2_MBUS_CSI2_NONCONTINUOUS_CLOCK);

Acked-by: Philipp Zabel 

regards
Philipp


[PATCH 1/3] [media] tc358743: Correct clock mode reported in g_mbus_config

2017-09-19 Thread Dave Stevenson
Support for non-continuous clock had previously been added via
device tree, but a comment and the value reported by g_mbus_config
still stated that it wasn't supported.
Remove the comment, and return the correct value in g_mbus_config.

Signed-off-by: Dave Stevenson 
---
 drivers/media/i2c/tc358743.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/drivers/media/i2c/tc358743.c b/drivers/media/i2c/tc358743.c
index e6f5c36..6b0fd07 100644
--- a/drivers/media/i2c/tc358743.c
+++ b/drivers/media/i2c/tc358743.c
@@ -1461,8 +1461,9 @@ static int tc358743_g_mbus_config(struct v4l2_subdev *sd,
 
cfg->type = V4L2_MBUS_CSI2;
 
-   /* Support for non-continuous CSI-2 clock is missing in the driver */
-   cfg->flags = V4L2_MBUS_CSI2_CONTINUOUS_CLOCK;
+   cfg->flags = state->bus.flags &
+   (V4L2_MBUS_CSI2_CONTINUOUS_CLOCK |
+V4L2_MBUS_CSI2_NONCONTINUOUS_CLOCK);
 
switch (state->csi_lanes_in_use) {
case 1:
-- 
2.7.4