From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-9.8 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI, SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 25E77C2D0DA for ; Sun, 29 Dec 2019 18:07:21 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id EAEDF20722 for ; Sun, 29 Dec 2019 18:07:20 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1577642841; bh=hlMo9Vcth0ZJuThRx5iZu8uM6IQ1F5KDDRqAfx2LPQQ=; h=From:To:Cc:Subject:Date:In-Reply-To:References:List-ID:From; b=0Wu7VpF+joMZb/eb/IyKZkkPlg5Z99HSzrKpyFB+UbxGkQHIEjXX5k6HPrm6wcOoZ MW7CkxXT5FlxcsbGoIEHKikfZ+03ZJL8H39kqtFknv+kyVfCqIH9UEsxaYm8ZRE2Mh l0xVy7SKqwAdeI8I1fOwS7Sh3nBM1ED799CJ6z0M= Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731468AbfL2Rs3 (ORCPT ); Sun, 29 Dec 2019 12:48:29 -0500 Received: from mail.kernel.org ([198.145.29.99]:59778 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727238AbfL2Rs3 (ORCPT ); Sun, 29 Dec 2019 12:48:29 -0500 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 2FE57206DB; Sun, 29 Dec 2019 17:48:28 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1577641708; bh=hlMo9Vcth0ZJuThRx5iZu8uM6IQ1F5KDDRqAfx2LPQQ=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=YDUsUUW2lQ55ueDOOULG9I9gmfgxp+kzvvr4W7rwPPegmUI6cSXi2H6exk/nakveP JWXgiVAIWmaN3rdyHSCaARM2YvQ5nPmt4r1WDsnnUZG7YlcbLo45YXcCNcQ6+yLEOP IOiyJwDa6JPrLfFVH4ym+6z32ro8dG41utnJIpFU= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Ricardo Ribalda Delgado , Pavel Machek , Laurent Pinchart , Sakari Ailus , Mauro Carvalho Chehab , Sasha Levin Subject: [PATCH 5.4 177/434] media: ad5820: Define entity function Date: Sun, 29 Dec 2019 18:23:50 +0100 Message-Id: <20191229172713.568820265@linuxfoundation.org> X-Mailer: git-send-email 2.24.1 In-Reply-To: <20191229172702.393141737@linuxfoundation.org> References: <20191229172702.393141737@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: stable-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: stable@vger.kernel.org From: Ricardo Ribalda Delgado [ Upstream commit 801ef7c4919efba6b96b5aed1e72844ca69e26d3 ] Without this patch, media_device_register_entity throws a warning: dev_warn(mdev->dev, "Entity type for entity %s was not initialized!\n", entity->name); Signed-off-by: Ricardo Ribalda Delgado Acked-by: Pavel Machek Reviewed-by: Laurent Pinchart Signed-off-by: Sakari Ailus Signed-off-by: Mauro Carvalho Chehab Signed-off-by: Sasha Levin --- drivers/media/i2c/ad5820.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/media/i2c/ad5820.c b/drivers/media/i2c/ad5820.c index 925c171e7797..7a49651f4d1f 100644 --- a/drivers/media/i2c/ad5820.c +++ b/drivers/media/i2c/ad5820.c @@ -309,6 +309,7 @@ static int ad5820_probe(struct i2c_client *client, v4l2_i2c_subdev_init(&coil->subdev, client, &ad5820_ops); coil->subdev.flags |= V4L2_SUBDEV_FL_HAS_DEVNODE; coil->subdev.internal_ops = &ad5820_internal_ops; + coil->subdev.entity.function = MEDIA_ENT_F_LENS; strscpy(coil->subdev.name, "ad5820 focus", sizeof(coil->subdev.name)); ret = media_entity_pads_init(&coil->subdev.entity, 0, NULL); -- 2.20.1