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=-3.9 required=3.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS autolearn=no 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 9E167C83000 for ; Tue, 28 Apr 2020 15:57:25 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 4B64E206C0 for ; Tue, 28 Apr 2020 15:57:25 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=cerno.tech header.i=@cerno.tech header.b="RLk9EM1C"; dkim=pass (2048-bit key) header.d=messagingengine.com header.i=@messagingengine.com header.b="hgDtuLch" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728112AbgD1P5Y (ORCPT ); Tue, 28 Apr 2020 11:57:24 -0400 Received: from wnew2-smtp.messagingengine.com ([64.147.123.27]:60067 "EHLO wnew2-smtp.messagingengine.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727775AbgD1P5Y (ORCPT ); Tue, 28 Apr 2020 11:57:24 -0400 Received: from compute4.internal (compute4.nyi.internal [10.202.2.44]) by mailnew.west.internal (Postfix) with ESMTP id 59D541C2; Tue, 28 Apr 2020 11:57:22 -0400 (EDT) Received: from mailfrontend1 ([10.202.2.162]) by compute4.internal (MEProxy); Tue, 28 Apr 2020 11:57:23 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cerno.tech; h= date:from:to:cc:subject:message-id:references:mime-version :content-type:in-reply-to; s=fm2; bh=UeapUTooUsi8NUN5twL9bPAz6Yg /DJgy7xJgqDr5Y6c=; b=RLk9EM1C9TJEvZCAU5DJZ0cCSNanK5z1+QD4E7Ut9d4 +iLj2VcNxVMWt0IJGCua/Ffy2XMG65Cr0smcaCNQ6MfefND1JC0eaQv3v6t+ene8 vIbhO6SStety36zyW+DYBAOxRJk3ZNdbNDjUh2TVPJbvjSNnsy9x0e0xu1c2M8wf jc173DzSwV6rhtL7J6GPBJWzAYYYmxaq+88t2FREtl6AsvVKpYLpeb8N8g5ZpOoB iMh+V5KaT9jpgHvadzvQUNW494RbSEbKw9iWkBglIbr+KvkYquNwqq6F3Plrq3wJ Ks0h3MR/LSe0I+LjgNooNj8NJ/LvKOxkPJ1GFb+8mTg== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-proxy :x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm2; bh=UeapUT ooUsi8NUN5twL9bPAz6Yg/DJgy7xJgqDr5Y6c=; b=hgDtuLchjXMz1TEkEUCBHw bUfyNf/9vo+YS+uAIhVpeb8q7R3LMXDl/lb40k0Yt35l9djrIarWIMJXKgBcn/qf 67PtECtSJghbPBtG/65qpIsI9X0MMxzmVRqiXYulD3S9L4yq9qeZ280l5EbUpnjD Y1ouItmn4dfEKTg3de42m3Ovn7cu1dN7C6Vv3Mc7vcmI/zjP7kxiLTlAwqCW2/c8 o6wX7AjobJ5utOh6qX4GU94rb6jyg1tbHjjI7USQF8COu5oNZ9sMumCVrrV+4zZF SbWZ91JdnCT7dKWMkFvd/Y04TiIBeuXSDtbI/cQAYEzaXjPjej4ziGKLpI4KW8Zg == X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeduhedriedugdelgecutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfghnecu uegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenuc fjughrpeffhffvuffkfhggtggujgesghdtreertddtudenucfhrhhomhepofgrgihimhgv ucftihhprghrugcuoehmrgigihhmvgestggvrhhnohdrthgvtghhqeenucfkphepledtrd ekledrieekrdejieenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhl fhhrohhmpehmrgigihhmvgestggvrhhnohdrthgvtghh X-ME-Proxy: Received: from localhost (lfbn-tou-1-1502-76.w90-89.abo.wanadoo.fr [90.89.68.76]) by mail.messagingengine.com (Postfix) with ESMTPA id 124523280068; Tue, 28 Apr 2020 11:57:17 -0400 (EDT) Date: Tue, 28 Apr 2020 17:57:11 +0200 From: Maxime Ripard To: Stefan Wahren Cc: Nicolas Saenz Julienne , Eric Anholt , Tim Gover , Dave Stevenson , linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, bcm-kernel-feedback-list@broadcom.com, linux-rpi-kernel@lists.infradead.org, Phil Elwell , linux-arm-kernel@lists.infradead.org Subject: Re: [PATCH v2 79/91] drm/vc4: hdmi: Deal with multiple debugfs files Message-ID: <20200428155711.efpq6vbqcq52gjk5@gilmour.lan> References: <4cd617827cc28875ef36f3632122a83cff2ea4a7.1587742492.git-series.maxime@cerno.tech> <63f9e71a-1beb-7a67-ea48-dbc579fa3161@i2se.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="6nlx63qexjyyiyf5" Content-Disposition: inline In-Reply-To: <63f9e71a-1beb-7a67-ea48-dbc579fa3161@i2se.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --6nlx63qexjyyiyf5 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Hi Stefan, On Sat, Apr 25, 2020 at 11:26:31PM +0200, Stefan Wahren wrote: > Am 24.04.20 um 17:35 schrieb Maxime Ripard: > > The HDMI driver was registering a single debugfs file so far with the n= ame > > hdmi_regs. > > > > Obviously, this is not going to work anymore when will have multiple HD= MI > > controllers since we will end up trying to register two files with the = same > > name. > > > > Let's use the ID to avoid that name conflict. >=20 > even with this patch there is a name conflict in debugfs using Linux > 5.7-rc1. Dave Stevenson addressed this by using different card names > [1]. Since this patch won't apply anymore here is my suggestion: >=20 > diff --git a/drivers/gpu/drm/vc4/vc4_hdmi.c b/drivers/gpu/drm/vc4/vc4_hdm= i.c > index 29287ab..7209397 100644 > --- a/drivers/gpu/drm/vc4/vc4_hdmi.c > +++ b/drivers/gpu/drm/vc4/vc4_hdmi.c > @@ -1181,9 +1181,14 @@ static int vc4_hdmi_audio_init(struct vc4_hdmi > *vc4_hdmi) > =A0 > =A0=A0=A0=A0 card->dai_link =3D dai_link; > =A0=A0=A0=A0 card->num_links =3D 1; > -=A0=A0=A0 card->name =3D "vc4-hdmi"; > =A0=A0=A0=A0 card->dev =3D dev; > =A0 > +=A0=A0=A0 if (vc4_hdmi->variant->encoder_type =3D=3D VC4_ENCODER_TYPE_HD= MI1) { > +=A0=A0=A0 =A0=A0=A0 card->name =3D "vc4-hdmi1"; > +=A0=A0=A0 } else { > +=A0=A0=A0 =A0=A0=A0 card->name =3D "vc4-hdmi"; > +=A0=A0=A0 } > + Thinking about this some more, we don't really need VC4_ENCODER_TYPE_HDMI0 = and HDMI1, and it can all work with the same encoder type for both, so I'll drop them. To address this issue though, we can add a card name string to the variant,= like I did for debugfs. Is that alright for you? Maxime --6nlx63qexjyyiyf5 Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHUEABYIAB0WIQRcEzekXsqa64kGDp7j7w1vZxhRxQUCXqhSVwAKCRDj7w1vZxhR xXjUAP4soMkyOTFFSXXn/qMZXtJpGyIJR6qHlIruzu9KCXFNogEAqHA7EpmVcFbT +9FFfp7tSgB32/xDKpblWqG4wa8yaAY= =nBTY -----END PGP SIGNATURE----- --6nlx63qexjyyiyf5-- 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=-3.8 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=no 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 2DDF5C83001 for ; Tue, 28 Apr 2020 15:57:33 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id F0ECE206D7 for ; Tue, 28 Apr 2020 15:57:32 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="FmAQZcTV"; dkim=fail reason="signature verification failed" (2048-bit key) header.d=cerno.tech header.i=@cerno.tech header.b="RLk9EM1C"; dkim=fail reason="signature verification failed" (2048-bit key) header.d=messagingengine.com header.i=@messagingengine.com header.b="hgDtuLch" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org F0ECE206D7 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=cerno.tech Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender:Content-Type:Cc: List-Subscribe:List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id: In-Reply-To:MIME-Version:References:Message-ID:Subject:To:From:Date:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=pyOZg+tVy7U6BAt4yFG+7aVW8uqfUvPOcV0V1G2f59s=; b=FmAQZcTVuBzpARQwDs5WR1Zv4 uqxHRguWE8VnH3AOO2TgJny0tHmgoZDI65w/2aaopC8YNDCiI0todNUzGxaEcHLpBMAYk8JgjE1m6 engx3h8d3KW7B3uN1b/bDeeofy5wsErOKrWNPmHqWNereIksaZc6HlrxKqLZJqUS8xM+ImRg1VdbD fGRpIlH5pgqSrTWAdNPpIgmUK6gnAQeP9K9Z7xICYgjKWEJbkowmvFlXdJAoP7QJNUNUXKHGZ7FbX Qh6+cufdBqyx8A76+0+fNv7jX56y9AkFV1nxrsvIvXQIrgHchm2Vp7Jl0WAvPATPMWMHH5bI0SGVm uqfmLGhjg==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1jTSbx-0003Y4-IH; Tue, 28 Apr 2020 15:57:29 +0000 Received: from wnew2-smtp.messagingengine.com ([64.147.123.27]) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1jTSbu-0003W3-Fm; Tue, 28 Apr 2020 15:57:28 +0000 Received: from compute4.internal (compute4.nyi.internal [10.202.2.44]) by mailnew.west.internal (Postfix) with ESMTP id 59D541C2; Tue, 28 Apr 2020 11:57:22 -0400 (EDT) Received: from mailfrontend1 ([10.202.2.162]) by compute4.internal (MEProxy); Tue, 28 Apr 2020 11:57:23 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cerno.tech; h= date:from:to:cc:subject:message-id:references:mime-version :content-type:in-reply-to; s=fm2; bh=UeapUTooUsi8NUN5twL9bPAz6Yg /DJgy7xJgqDr5Y6c=; b=RLk9EM1C9TJEvZCAU5DJZ0cCSNanK5z1+QD4E7Ut9d4 +iLj2VcNxVMWt0IJGCua/Ffy2XMG65Cr0smcaCNQ6MfefND1JC0eaQv3v6t+ene8 vIbhO6SStety36zyW+DYBAOxRJk3ZNdbNDjUh2TVPJbvjSNnsy9x0e0xu1c2M8wf jc173DzSwV6rhtL7J6GPBJWzAYYYmxaq+88t2FREtl6AsvVKpYLpeb8N8g5ZpOoB iMh+V5KaT9jpgHvadzvQUNW494RbSEbKw9iWkBglIbr+KvkYquNwqq6F3Plrq3wJ Ks0h3MR/LSe0I+LjgNooNj8NJ/LvKOxkPJ1GFb+8mTg== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-proxy :x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm2; bh=UeapUT ooUsi8NUN5twL9bPAz6Yg/DJgy7xJgqDr5Y6c=; b=hgDtuLchjXMz1TEkEUCBHw bUfyNf/9vo+YS+uAIhVpeb8q7R3LMXDl/lb40k0Yt35l9djrIarWIMJXKgBcn/qf 67PtECtSJghbPBtG/65qpIsI9X0MMxzmVRqiXYulD3S9L4yq9qeZ280l5EbUpnjD Y1ouItmn4dfEKTg3de42m3Ovn7cu1dN7C6Vv3Mc7vcmI/zjP7kxiLTlAwqCW2/c8 o6wX7AjobJ5utOh6qX4GU94rb6jyg1tbHjjI7USQF8COu5oNZ9sMumCVrrV+4zZF SbWZ91JdnCT7dKWMkFvd/Y04TiIBeuXSDtbI/cQAYEzaXjPjej4ziGKLpI4KW8Zg == X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeduhedriedugdelgecutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfghnecu uegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenuc fjughrpeffhffvuffkfhggtggujgesghdtreertddtudenucfhrhhomhepofgrgihimhgv ucftihhprghrugcuoehmrgigihhmvgestggvrhhnohdrthgvtghhqeenucfkphepledtrd ekledrieekrdejieenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhl fhhrohhmpehmrgigihhmvgestggvrhhnohdrthgvtghh X-ME-Proxy: Received: from localhost (lfbn-tou-1-1502-76.w90-89.abo.wanadoo.fr [90.89.68.76]) by mail.messagingengine.com (Postfix) with ESMTPA id 124523280068; Tue, 28 Apr 2020 11:57:17 -0400 (EDT) Date: Tue, 28 Apr 2020 17:57:11 +0200 From: Maxime Ripard To: Stefan Wahren Subject: Re: [PATCH v2 79/91] drm/vc4: hdmi: Deal with multiple debugfs files Message-ID: <20200428155711.efpq6vbqcq52gjk5@gilmour.lan> References: <4cd617827cc28875ef36f3632122a83cff2ea4a7.1587742492.git-series.maxime@cerno.tech> <63f9e71a-1beb-7a67-ea48-dbc579fa3161@i2se.com> MIME-Version: 1.0 In-Reply-To: <63f9e71a-1beb-7a67-ea48-dbc579fa3161@i2se.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20200428_085726_782785_C2B270A4 X-CRM114-Status: GOOD ( 14.59 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linux-arm-kernel@lists.infradead.org, Tim Gover , Dave Stevenson , linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, Eric Anholt , bcm-kernel-feedback-list@broadcom.com, linux-rpi-kernel@lists.infradead.org, Phil Elwell , Nicolas Saenz Julienne Content-Type: multipart/mixed; boundary="===============3048463841235700224==" Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org --===============3048463841235700224== Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="6nlx63qexjyyiyf5" Content-Disposition: inline --6nlx63qexjyyiyf5 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Hi Stefan, On Sat, Apr 25, 2020 at 11:26:31PM +0200, Stefan Wahren wrote: > Am 24.04.20 um 17:35 schrieb Maxime Ripard: > > The HDMI driver was registering a single debugfs file so far with the n= ame > > hdmi_regs. > > > > Obviously, this is not going to work anymore when will have multiple HD= MI > > controllers since we will end up trying to register two files with the = same > > name. > > > > Let's use the ID to avoid that name conflict. >=20 > even with this patch there is a name conflict in debugfs using Linux > 5.7-rc1. Dave Stevenson addressed this by using different card names > [1]. Since this patch won't apply anymore here is my suggestion: >=20 > diff --git a/drivers/gpu/drm/vc4/vc4_hdmi.c b/drivers/gpu/drm/vc4/vc4_hdm= i.c > index 29287ab..7209397 100644 > --- a/drivers/gpu/drm/vc4/vc4_hdmi.c > +++ b/drivers/gpu/drm/vc4/vc4_hdmi.c > @@ -1181,9 +1181,14 @@ static int vc4_hdmi_audio_init(struct vc4_hdmi > *vc4_hdmi) > =A0 > =A0=A0=A0=A0 card->dai_link =3D dai_link; > =A0=A0=A0=A0 card->num_links =3D 1; > -=A0=A0=A0 card->name =3D "vc4-hdmi"; > =A0=A0=A0=A0 card->dev =3D dev; > =A0 > +=A0=A0=A0 if (vc4_hdmi->variant->encoder_type =3D=3D VC4_ENCODER_TYPE_HD= MI1) { > +=A0=A0=A0 =A0=A0=A0 card->name =3D "vc4-hdmi1"; > +=A0=A0=A0 } else { > +=A0=A0=A0 =A0=A0=A0 card->name =3D "vc4-hdmi"; > +=A0=A0=A0 } > + Thinking about this some more, we don't really need VC4_ENCODER_TYPE_HDMI0 = and HDMI1, and it can all work with the same encoder type for both, so I'll drop them. To address this issue though, we can add a card name string to the variant,= like I did for debugfs. Is that alright for you? Maxime --6nlx63qexjyyiyf5 Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHUEABYIAB0WIQRcEzekXsqa64kGDp7j7w1vZxhRxQUCXqhSVwAKCRDj7w1vZxhR xXjUAP4soMkyOTFFSXXn/qMZXtJpGyIJR6qHlIruzu9KCXFNogEAqHA7EpmVcFbT +9FFfp7tSgB32/xDKpblWqG4wa8yaAY= =nBTY -----END PGP SIGNATURE----- --6nlx63qexjyyiyf5-- --===============3048463841235700224== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel --===============3048463841235700224==-- 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=-3.5 required=3.0 tests=DKIM_INVALID,DKIM_SIGNED, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS,URIBL_BLOCKED autolearn=no 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 47248C8300D for ; Wed, 29 Apr 2020 06:45:27 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 19E90206D6 for ; Wed, 29 Apr 2020 06:45:27 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=cerno.tech header.i=@cerno.tech header.b="RLk9EM1C"; dkim=fail reason="signature verification failed" (2048-bit key) header.d=messagingengine.com header.i=@messagingengine.com header.b="hgDtuLch" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 19E90206D6 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=cerno.tech Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=dri-devel-bounces@lists.freedesktop.org Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id CCC7A6EC9F; Wed, 29 Apr 2020 06:45:02 +0000 (UTC) Received: from wnew2-smtp.messagingengine.com (wnew2-smtp.messagingengine.com [64.147.123.27]) by gabe.freedesktop.org (Postfix) with ESMTPS id 35BDD6E822 for ; Tue, 28 Apr 2020 15:57:25 +0000 (UTC) Received: from compute4.internal (compute4.nyi.internal [10.202.2.44]) by mailnew.west.internal (Postfix) with ESMTP id 59D541C2; Tue, 28 Apr 2020 11:57:22 -0400 (EDT) Received: from mailfrontend1 ([10.202.2.162]) by compute4.internal (MEProxy); Tue, 28 Apr 2020 11:57:23 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cerno.tech; h= date:from:to:cc:subject:message-id:references:mime-version :content-type:in-reply-to; s=fm2; bh=UeapUTooUsi8NUN5twL9bPAz6Yg /DJgy7xJgqDr5Y6c=; b=RLk9EM1C9TJEvZCAU5DJZ0cCSNanK5z1+QD4E7Ut9d4 +iLj2VcNxVMWt0IJGCua/Ffy2XMG65Cr0smcaCNQ6MfefND1JC0eaQv3v6t+ene8 vIbhO6SStety36zyW+DYBAOxRJk3ZNdbNDjUh2TVPJbvjSNnsy9x0e0xu1c2M8wf jc173DzSwV6rhtL7J6GPBJWzAYYYmxaq+88t2FREtl6AsvVKpYLpeb8N8g5ZpOoB iMh+V5KaT9jpgHvadzvQUNW494RbSEbKw9iWkBglIbr+KvkYquNwqq6F3Plrq3wJ Ks0h3MR/LSe0I+LjgNooNj8NJ/LvKOxkPJ1GFb+8mTg== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-proxy :x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm2; bh=UeapUT ooUsi8NUN5twL9bPAz6Yg/DJgy7xJgqDr5Y6c=; b=hgDtuLchjXMz1TEkEUCBHw bUfyNf/9vo+YS+uAIhVpeb8q7R3LMXDl/lb40k0Yt35l9djrIarWIMJXKgBcn/qf 67PtECtSJghbPBtG/65qpIsI9X0MMxzmVRqiXYulD3S9L4yq9qeZ280l5EbUpnjD Y1ouItmn4dfEKTg3de42m3Ovn7cu1dN7C6Vv3Mc7vcmI/zjP7kxiLTlAwqCW2/c8 o6wX7AjobJ5utOh6qX4GU94rb6jyg1tbHjjI7USQF8COu5oNZ9sMumCVrrV+4zZF SbWZ91JdnCT7dKWMkFvd/Y04TiIBeuXSDtbI/cQAYEzaXjPjej4ziGKLpI4KW8Zg == X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeduhedriedugdelgecutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfghnecu uegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenuc fjughrpeffhffvuffkfhggtggujgesghdtreertddtudenucfhrhhomhepofgrgihimhgv ucftihhprghrugcuoehmrgigihhmvgestggvrhhnohdrthgvtghhqeenucfkphepledtrd ekledrieekrdejieenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhl fhhrohhmpehmrgigihhmvgestggvrhhnohdrthgvtghh X-ME-Proxy: Received: from localhost (lfbn-tou-1-1502-76.w90-89.abo.wanadoo.fr [90.89.68.76]) by mail.messagingengine.com (Postfix) with ESMTPA id 124523280068; Tue, 28 Apr 2020 11:57:17 -0400 (EDT) Date: Tue, 28 Apr 2020 17:57:11 +0200 From: Maxime Ripard To: Stefan Wahren Subject: Re: [PATCH v2 79/91] drm/vc4: hdmi: Deal with multiple debugfs files Message-ID: <20200428155711.efpq6vbqcq52gjk5@gilmour.lan> References: <4cd617827cc28875ef36f3632122a83cff2ea4a7.1587742492.git-series.maxime@cerno.tech> <63f9e71a-1beb-7a67-ea48-dbc579fa3161@i2se.com> MIME-Version: 1.0 In-Reply-To: <63f9e71a-1beb-7a67-ea48-dbc579fa3161@i2se.com> X-Mailman-Approved-At: Wed, 29 Apr 2020 06:45:00 +0000 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linux-arm-kernel@lists.infradead.org, Tim Gover , Dave Stevenson , linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, bcm-kernel-feedback-list@broadcom.com, linux-rpi-kernel@lists.infradead.org, Phil Elwell , Nicolas Saenz Julienne Content-Type: multipart/mixed; boundary="===============0971393589==" Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" --===============0971393589== Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="6nlx63qexjyyiyf5" Content-Disposition: inline --6nlx63qexjyyiyf5 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Hi Stefan, On Sat, Apr 25, 2020 at 11:26:31PM +0200, Stefan Wahren wrote: > Am 24.04.20 um 17:35 schrieb Maxime Ripard: > > The HDMI driver was registering a single debugfs file so far with the n= ame > > hdmi_regs. > > > > Obviously, this is not going to work anymore when will have multiple HD= MI > > controllers since we will end up trying to register two files with the = same > > name. > > > > Let's use the ID to avoid that name conflict. >=20 > even with this patch there is a name conflict in debugfs using Linux > 5.7-rc1. Dave Stevenson addressed this by using different card names > [1]. Since this patch won't apply anymore here is my suggestion: >=20 > diff --git a/drivers/gpu/drm/vc4/vc4_hdmi.c b/drivers/gpu/drm/vc4/vc4_hdm= i.c > index 29287ab..7209397 100644 > --- a/drivers/gpu/drm/vc4/vc4_hdmi.c > +++ b/drivers/gpu/drm/vc4/vc4_hdmi.c > @@ -1181,9 +1181,14 @@ static int vc4_hdmi_audio_init(struct vc4_hdmi > *vc4_hdmi) > =A0 > =A0=A0=A0=A0 card->dai_link =3D dai_link; > =A0=A0=A0=A0 card->num_links =3D 1; > -=A0=A0=A0 card->name =3D "vc4-hdmi"; > =A0=A0=A0=A0 card->dev =3D dev; > =A0 > +=A0=A0=A0 if (vc4_hdmi->variant->encoder_type =3D=3D VC4_ENCODER_TYPE_HD= MI1) { > +=A0=A0=A0 =A0=A0=A0 card->name =3D "vc4-hdmi1"; > +=A0=A0=A0 } else { > +=A0=A0=A0 =A0=A0=A0 card->name =3D "vc4-hdmi"; > +=A0=A0=A0 } > + Thinking about this some more, we don't really need VC4_ENCODER_TYPE_HDMI0 = and HDMI1, and it can all work with the same encoder type for both, so I'll drop them. To address this issue though, we can add a card name string to the variant,= like I did for debugfs. Is that alright for you? Maxime --6nlx63qexjyyiyf5 Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHUEABYIAB0WIQRcEzekXsqa64kGDp7j7w1vZxhRxQUCXqhSVwAKCRDj7w1vZxhR xXjUAP4soMkyOTFFSXXn/qMZXtJpGyIJR6qHlIruzu9KCXFNogEAqHA7EpmVcFbT +9FFfp7tSgB32/xDKpblWqG4wa8yaAY= =nBTY -----END PGP SIGNATURE----- --6nlx63qexjyyiyf5-- --===============0971393589== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ dri-devel mailing list dri-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/dri-devel --===============0971393589==--