Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp9394708pxu; Mon, 28 Dec 2020 15:04:49 -0800 (PST) X-Google-Smtp-Source: ABdhPJwt8vfiOfDdAOfxghkg4FbSetjatB+TtWqv3AgxheO7O0HrMVTsRHSSfW6NOCYsqzd8LWRT X-Received: by 2002:a17:906:1a01:: with SMTP id i1mr44336037ejf.315.1609196689206; Mon, 28 Dec 2020 15:04:49 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1609196689; cv=none; d=google.com; s=arc-20160816; b=kdrtnjQVzFFoXQHfqHuVzWHoAK/d38FzVysTN5aDZ250MNazOVitcfAOBEn6bDnBkt 51Cdvay7/tKcppfNJyERIii/dAUuYxvVhUPbzRLgaUgHDlqX0O5yYdq3LLji37nxBRG/ 3DbBPwwoGVEHkYuJGK/GZFtwHScOWRd7kbVgzQTi8FQ0T2mqI7NHqzq4eeXe09I9h9D8 FcFL/nPbn0TfX9gLofFgt2ZqcP/LNsVyvtRW7A8fnUdIfLS6vQhQtPd7HB7I4nO2/sQd dY1KNSnrVAoAZa6NdiSKVx5ll2cynceXpL6kmUQwnMEvAjBNEKeNlH6SewhgF9XmDMqz DnsA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=7bqAGY7Sm95s6pTkUe1MvZ6m4Say8EXNtTgGa1+Zjtw=; b=R3NBQw3kswr9WwI8Xub6RNfT+yynGu1dzUL4/03csdTcQwOxX9LIesbdl6RyLgVanv uylu4iW+0R/KhHrv02r5zwcRBKzb0lgx6Z1WQdqgPm9h8trCYBMypkuXVglpxoY2Wcsd WJbTR9SIzil1a4oaknVi2nHmXLuGjZr9PuJWIMRTdC7xmqAb4xMLKUbpOpNvZDkXsdMo IU7X4VHXsHt21d5FaTHkTLIPn7JHew+ZSenAaJyCd9I77jMMfMtboTzwTIkqI59vyYMD MKfdMljXl0PVxqmzgYL2Dfui327xM4/4jgEsxVGJuJN7zHXah+AHbTc6fb/Ka5LoxfuU +XKw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b="Yc/EiS+Q"; 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=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id r3si21487434edy.595.2020.12.28.15.04.27; Mon, 28 Dec 2020 15:04:49 -0800 (PST) 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=@linuxfoundation.org header.s=korg header.b="Yc/EiS+Q"; 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=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2437527AbgL1OE7 (ORCPT + 99 others); Mon, 28 Dec 2020 09:04:59 -0500 Received: from mail.kernel.org ([198.145.29.99]:38474 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2437490AbgL1OEw (ORCPT ); Mon, 28 Dec 2020 09:04:52 -0500 Received: by mail.kernel.org (Postfix) with ESMTPSA id F3B7E20791; Mon, 28 Dec 2020 14:04:35 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1609164276; bh=fcTGQsbOKU98j4qnnkh2AgeW1TZ0qxxbGM/aLZGpP74=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Yc/EiS+Q9WrXslcJ5nFClTLKF4wP3J/ALeYUHheWCtTnQozZvKfe5Ypq13eXMF3ro +IDa7mbkIOhE56jb3+vMgz/R0IbR4ylx7UTZQuielVLNVMGfdcT0xnqk6BrCkR1vfG M3Zb1DumyJ7zCgvtvRiU3ck+8qR+kicx/yYXIiSY= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Sakari Ailus , =?UTF-8?q?Niklas=20S=C3=B6derlund?= , Laurent Pinchart , Mauro Carvalho Chehab , Sasha Levin Subject: [PATCH 5.10 124/717] media: v4l2-fwnode: v4l2_fwnode_endpoint_parse caller must init vep argument Date: Mon, 28 Dec 2020 13:42:02 +0100 Message-Id: <20201228125026.888806937@linuxfoundation.org> X-Mailer: git-send-email 2.29.2 In-Reply-To: <20201228125020.963311703@linuxfoundation.org> References: <20201228125020.963311703@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Sakari Ailus [ Upstream commit b3cc73d2bf14e7c6e0376fa9433e708349e9ddfc ] Document that the caller of v4l2_fwnode_endpoint_parse() must init the fields of struct v4l2_fwnode_endpoint (vep argument) fields. It used to be that the fields were zeroed by v4l2_fwnode_endpoint_parse when bus type was set to V4L2_MBUS_UNKNOWN but with recent changes (Fixes: line below) that no longer makes sense. Fixes: bb4bba9232fc ("media: v4l2-fwnode: Make bus configuration a struct") Signed-off-by: Sakari Ailus Reviewed-by: Niklas Söderlund Reviewed-by: Laurent Pinchart Signed-off-by: Mauro Carvalho Chehab Signed-off-by: Sasha Levin --- include/media/v4l2-fwnode.h | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/include/media/v4l2-fwnode.h b/include/media/v4l2-fwnode.h index c090742765431..ed0840f3d5dff 100644 --- a/include/media/v4l2-fwnode.h +++ b/include/media/v4l2-fwnode.h @@ -231,6 +231,9 @@ struct v4l2_fwnode_connector { * guessing @vep.bus_type between CSI-2 D-PHY, parallel and BT.656 busses is * supported. NEVER RELY ON GUESSING @vep.bus_type IN NEW DRIVERS! * + * The caller is required to initialise all fields of @vep, either with + * explicitly values, or by zeroing them. + * * The function does not change the V4L2 fwnode endpoint state if it fails. * * NOTE: This function does not parse properties the size of which is variable @@ -273,6 +276,9 @@ void v4l2_fwnode_endpoint_free(struct v4l2_fwnode_endpoint *vep); * guessing @vep.bus_type between CSI-2 D-PHY, parallel and BT.656 busses is * supported. NEVER RELY ON GUESSING @vep.bus_type IN NEW DRIVERS! * + * The caller is required to initialise all fields of @vep, either with + * explicitly values, or by zeroing them. + * * The function does not change the V4L2 fwnode endpoint state if it fails. * * v4l2_fwnode_endpoint_alloc_parse() has two important differences to -- 2.27.0