Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp1975137pxk; Mon, 14 Sep 2020 00:58:07 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzCYNlfonc8WT0rygAzBVKgPm5pawd8khS48hn8uHhKGG3U0UBGv5wixbUJLOevsoPUYM3h X-Received: by 2002:a17:906:4c89:: with SMTP id q9mr14005218eju.290.1600070287293; Mon, 14 Sep 2020 00:58:07 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1600070287; cv=none; d=google.com; s=arc-20160816; b=fUKPRdqw4Bn7vq/y6NkqGdrMjz3Dqlhs0COhQr+rU9LQJKP1TTIOPQ0vvYc/oYWvQi uBEklsNIh20MLJTZGlijBDEV3GGYdcIfVnKAKQ0OdLsgatiS+Eg+DVE0O4rMXicNVxNh HWur3QyIz2UAh006n3CLIZ9MW+R9T0keIcVz3fG9S5CDo84hgcylbqOZ0Cx9CKSpirhG aZYhGZRVLjVAfTZZX3Olz07ZwVEXP8HquHmPHc1J4NTeSH3jpKJN1C9Nq6Ts9OgbpfJQ 0VTHxJRo5nP/yyx3lJ9GhC3t8+BCHj2WGrM5E//oyTLP2lKci0TMadvGG+bACDuB0gFU wkyA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:organization:from:references:cc:to:subject :dkim-signature; bh=OLKPHbtOt8z8JIW1cBDEqkvkofIIPjEN7iRAGXlScGQ=; b=H1nApdpDYUlGoAPGLauOb0tEARBmuyarvJ1MR6g6JAUZXek6m3YtgIH8ACQMRcMC8Q HXCaKf5h59BN9E4yCflrZDkeXlwHD3E7bjal5rCHUhBSkEeNh+7YNSTqg0Q6UaXs5PyL EoEVUHdvzZZGwtkQYn/1LNOIlIdqkEvzqrqNP1LMOGfpwnBhbJyN6pXvTHacUgC/jEV3 hCqPqOilP1G5qRS3sPgIy5Wvs8o0Zm2ypjbNVeWn2TqdwEKwvb8sosTkGNc+AgUFAFle eH1OiuVJ5+RwYVQlSQR4/xxkpSw5TTiWCV7SxYh7BH9zeN5zGCTwHEBvePOuorPrD0dR Je5Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=UNTubtzZ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id ec15si6753437ejb.236.2020.09.14.00.57.44; Mon, 14 Sep 2020 00:58:07 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=UNTubtzZ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726137AbgINH4C (ORCPT + 99 others); Mon, 14 Sep 2020 03:56:02 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33294 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726046AbgINHzy (ORCPT ); Mon, 14 Sep 2020 03:55:54 -0400 Received: from mail-lj1-x243.google.com (mail-lj1-x243.google.com [IPv6:2a00:1450:4864:20::243]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A2132C06174A; Mon, 14 Sep 2020 00:55:53 -0700 (PDT) Received: by mail-lj1-x243.google.com with SMTP id c2so17754171ljj.12; Mon, 14 Sep 2020 00:55:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:to:cc:references:from:organization:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=OLKPHbtOt8z8JIW1cBDEqkvkofIIPjEN7iRAGXlScGQ=; b=UNTubtzZLEL8oapWyD53tB8szukUP0AsmWl7SbBE//kxC0c5XMcjBS6sLBATSDVR0L IuE5QOsKg8Z7ySquYugpz11Rnpjcczw6WLt23YwjdbPhYhE+s8AtwAKd0lmVypuaKUAm WnDbCLuYROjkokJMWl5HQTzaEkHHorc236gPnmWlDu89LOHv4fdV47LNV35Eh/7MHzch GkB/RCzN7Df7uAt3kYFACzQ4EXUcvAGS9JkEOzpuYFOo+ClyR4eO8b2SWveMCzIPTS4t XSGpah8zxJIgzICSppIZO7ur7/HHngsoldfPVNV2D/LXWaQBtOVIiv05AjerqOXxiZ5N paKg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:organization :message-id:date:user-agent:mime-version:in-reply-to :content-language:content-transfer-encoding; bh=OLKPHbtOt8z8JIW1cBDEqkvkofIIPjEN7iRAGXlScGQ=; b=lAAWy+dWcKcACWSDGUafjQ3FVLOvcF9uEpKyMpvfcvjW1omlx74sKZz62Kwm+9wXKm ty9nWizsl8yukUQ+pbGH0nwWtfolZRoYE5zQrKwwortS04gq/7nJuXhnF9gHIlNYuQfu l9R1sJoX0i79vYWIVsqGAqGrI5gyJ1PYft8uN18XiAL5EaGISYfghcP1RWOOtImvP0Qy y4Y4jEH2rlEUBy0wGebqi5YcudIqGvmjmo7iiXd/Eogbm9dNh6OrsbrfNX04o7Ou4KNI 6vtmygbQEJP0zZ1/yUxeVa6s2qZYnFwfsqH2/eQNhW/9lb/VvmpnNc2HYBFS9SDPEl91 mlaQ== X-Gm-Message-State: AOAM533EpOUyU2WbEOMAE/WioWA6lJpf0Wp7LUip66EUtHGUlzOQY/of 1wzqPubIBtoRdDYH40N6a1f2i6OJ8gE7mw== X-Received: by 2002:a2e:92cd:: with SMTP id k13mr4455424ljh.138.1600070152066; Mon, 14 Sep 2020 00:55:52 -0700 (PDT) Received: from ?IPv6:2a00:1fa0:239:d1e4:b56b:9cf2:d12e:444? ([2a00:1fa0:239:d1e4:b56b:9cf2:d12e:444]) by smtp.gmail.com with ESMTPSA id h16sm3577107lfc.63.2020.09.14.00.55.50 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 14 Sep 2020 00:55:51 -0700 (PDT) Subject: Re: [PATCH v4 2/3] media: i2c: ov772x: Add support for BT656 mode To: Lad Prabhakar , Jacopo Mondi , Sakari Ailus , Laurent Pinchart , Mauro Carvalho Chehab Cc: linux-media@vger.kernel.org, linux-kernel@vger.kernel.org, linux-renesas-soc@vger.kernel.org, Biju Das , Prabhakar References: <20200913184247.618-1-prabhakar.mahadev-lad.rj@bp.renesas.com> <20200913184247.618-3-prabhakar.mahadev-lad.rj@bp.renesas.com> From: Sergei Shtylyov Organization: Brain-dead Software Message-ID: Date: Mon, 14 Sep 2020 10:55:48 +0300 User-Agent: Mozilla/5.0 (Windows NT 6.3; WOW64; rv:68.0) Gecko/20100101 Thunderbird/68.12.0 MIME-Version: 1.0 In-Reply-To: <20200913184247.618-3-prabhakar.mahadev-lad.rj@bp.renesas.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hello! On 13.09.2020 21:42, Lad Prabhakar wrote: > Add support to read the bus-type for V4L2_MBUS_BT656 and > enable BT656 mode in the sensor if needed. Isn't it called BT.656? > Signed-off-by: Lad Prabhakar > Reviewed-by: Biju Das > --- > drivers/media/i2c/ov772x.c | 27 +++++++++++++++++++++------ > 1 file changed, 21 insertions(+), 6 deletions(-) > > diff --git a/drivers/media/i2c/ov772x.c b/drivers/media/i2c/ov772x.c > index 551082aa7026..edd7c4c22225 100644 > --- a/drivers/media/i2c/ov772x.c > +++ b/drivers/media/i2c/ov772x.c [...] > @@ -1427,16 +1434,24 @@ static int ov772x_probe(struct i2c_client *client) > goto error_clk_put; > } > > - bus_cfg.bus_type = V4L2_MBUS_PARALLEL; > + bus_cfg = (struct v4l2_fwnode_endpoint) > + { .bus_type = V4L2_MBUS_BT656 }; > ret = v4l2_fwnode_endpoint_alloc_parse(ep, &bus_cfg); > priv->bus_type = bus_cfg.bus_type; > v4l2_fwnode_endpoint_free(&bus_cfg); > if (ret) { > - /* For backward compatibility with the existing DT where > - * bus-type isnt specified fallback to V4L2_MBUS_PARALLEL > - */ > - priv->bus_type = V4L2_MBUS_PARALLEL; > - dev_notice(&client->dev, "Falling back to V4L2_MBUS_PARALLEL mode\n"); > + bus_cfg.bus_type = V4L2_MBUS_PARALLEL; > + ret = v4l2_fwnode_endpoint_alloc_parse(ep, &bus_cfg); > + priv->bus_type = bus_cfg.bus_type; > + v4l2_fwnode_endpoint_free(&bus_cfg); > + if (ret) { > + /* For backward compatibility with the existing DT where > + * bus-type isnt specified fallback to V4L2_MBUS_PARALLEL ^^^^ isn't Could be fixed, while at it? > + */ > + priv->bus_type = V4L2_MBUS_PARALLEL; > + dev_notice(&client->dev, > + "Falling back to V4L2_MBUS_PARALLEL mode\n"); > + } > } > > ret = ov772x_video_probe(priv); MBR, Sergei