From patchwork Wed Sep 18 08:24:58 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Cheng-yi Chiang X-Patchwork-Id: 11149881 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 27455912 for ; Wed, 18 Sep 2019 08:26:18 +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 04A9B20578 for ; Wed, 18 Sep 2019 08:26:18 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="QvlRyjNk"; dkim=fail reason="signature verification failed" (1024-bit key) header.d=chromium.org header.i=@chromium.org header.b="PEfuM16P" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 04A9B20578 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=chromium.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-rockchip-bounces+patchwork-linux-rockchip=patchwork.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-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=KF+UxnSqdGDaSEcgkBrT8GuMSz32PKLDkdvxSrz3gwc=; b=QvlRyjNksNxusj cIyOIwP0LNCOoKVD7rNr1DkbDP5jExPsxI4eGbzCgBn7uLvCtaTcvb/QbXYWI7Ro4YPI8vwH3Oi1D PhNtsNRICxqSf8GUUvb/yERTnkRPWOSZreCdqA6EC6C3i6Mw1cj/YD3qQYVcz4AIsUD4TFNilcY8e LN4tdfIDWfobMPQZlnVsNaOC/JuzAFA99JSSvRmkTJ3qxDM8lmn3Yar4KH/5et1jFJhzSIBuVfgFK 0/3gkTWj3N9r7ixztBTwqtcPegNi8P7ESnSFqs7Na7qpC6DrApecK5vpcipcNzEuM0hH6PEv71IRP OYMm5pSqqalDG3uUlbsg==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.2 #3 (Red Hat Linux)) id 1iAVHy-0005hy-Th; Wed, 18 Sep 2019 08:26:15 +0000 Received: from mail-pl1-x644.google.com ([2607:f8b0:4864:20::644]) by bombadil.infradead.org with esmtps (Exim 4.92.2 #3 (Red Hat Linux)) id 1iAVHO-000544-5c for linux-rockchip@lists.infradead.org; Wed, 18 Sep 2019 08:25:39 +0000 Received: by mail-pl1-x644.google.com with SMTP id b10so2789425plr.4 for ; Wed, 18 Sep 2019 01:25:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=2Eb5XL2gtr4lJ5rnXLq6hKn2qsGsu9ixzGW23+oXREM=; b=PEfuM16PUwPuQWzTuJ9LxpdpmgZ6yikA7V4SMd2igAchZPFDw/qlLw/9mjo+liS0Ey 0SEbcZEIRPFhPz4OACoNmUiypiHYUEK8SIZ1LvINDI/mYFIxaGWYG4hPXg2ev+B/kh+j kMMjde0JRZO+y1mz50zH/LklJuMwbFR6Kbb48= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=2Eb5XL2gtr4lJ5rnXLq6hKn2qsGsu9ixzGW23+oXREM=; b=spvdE2QTdouhrpGk/b+y/At4dvrFw/K2WjoGyy78I1riY4F8QZ5e46dWnwFLknH4p4 DrvE9WC1W9XfOyY6fIeB7UW3FxFvfBsaaHukFq4zbD3F9NahVeXQ5aRcQN8yG8zCURRo FW9Vt1DnAhkSZkPYMrZZ5G/a+n5Fc7VkkrKYgdlVe3Bo66mulUVpZrSb7FHC+8n45vBI Jvarw92f+pxY3JWKGGQrGlQaANs7Oqeki0aIF45/HllYpuGbs0/5cec/8mEzPXSooXN0 X6qOyJpVsIkctFeyKiy+gE/iPYp/hqnTs3Y7Al4UqnfP/dnQruWU1PEG2+/XEofwLEn7 jlOw== X-Gm-Message-State: APjAAAXzp7QUF5b+mp9/Uv0FVtQ1z9EI+0EMEBurIr8HwpBZ2CckdKmz 1d2rN6PK/XsO1/xTgod9LfTe8w== X-Google-Smtp-Source: APXvYqzM/TpxahPcIuKv23Rn/8JiC6t53IiqwM74LdqF2XoFPdEjyVMQG3RRSMyebhB7yKmN9BcEww== X-Received: by 2002:a17:902:8645:: with SMTP id y5mr2925331plt.191.1568795137579; Wed, 18 Sep 2019 01:25:37 -0700 (PDT) Received: from localhost ([2401:fa00:1:10:79b4:bd83:e4a5:a720]) by smtp.gmail.com with ESMTPSA id w6sm8942501pfj.17.2019.09.18.01.25.33 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 18 Sep 2019 01:25:36 -0700 (PDT) From: Cheng-Yi Chiang To: linux-kernel@vger.kernel.org Subject: [PATCH v6 2/4] drm: dw-hdmi-i2s: Use fixed id for codec device Date: Wed, 18 Sep 2019 16:24:58 +0800 Message-Id: <20190918082500.209281-3-cychiang@chromium.org> X-Mailer: git-send-email 2.23.0.237.gc6a4ce50a0-goog In-Reply-To: <20190918082500.209281-1-cychiang@chromium.org> References: <20190918082500.209281-1-cychiang@chromium.org> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20190918_012538_319344_B60C3D66 X-CRM114-Status: GOOD ( 12.67 ) X-Spam-Score: -0.2 (/) X-Spam-Report: SpamAssassin version 3.4.2 on bombadil.infradead.org summary: Content analysis details: (-0.2 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at https://www.dnswl.org/, no trust [2607:f8b0:4864:20:0:0:0:644 listed in] [list.dnswl.org] 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record -0.0 SPF_PASS SPF: sender matches SPF record -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature -0.1 DKIM_VALID_AU Message has a valid DKIM or DK signature from author's domain -0.1 DKIM_VALID_EF Message has a valid DKIM or DK signature from envelope-from domain 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid -0.0 DKIMWL_WL_HIGH DKIMwl.org - Whitelisted High sender X-BeenThere: linux-rockchip@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Upstream kernel work for Rockchip platforms List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: alsa-devel@alsa-project.org, Heiko Stuebner , Neil Armstrong , David Airlie , dri-devel@lists.freedesktop.org, Liam Girdwood , Hans Verkuil , Andrzej Hajda , Laurent Pinchart , Jerome Brunet , Takashi Iwai , linux-rockchip@lists.infradead.org, dgreid@chromium.org, Cheng-Yi Chiang , tzungbi@chromium.org, Jonas Karlman , Russell King , Mark Brown , Jaroslav Kysela , linux-arm-kernel@lists.infradead.org, Jernej Skrabec , dianders@chromium.org, Daniel Vetter Sender: "Linux-rockchip" Errors-To: linux-rockchip-bounces+patchwork-linux-rockchip=patchwork.kernel.org@lists.infradead.org The problem of using auto ID is that the device name will be like hdmi-audio-codec..auto. The number might be changed when there are other platform devices being created before hdmi-audio-codec device. Use a fixed name so machine driver can set codec name on the DAI link. Using the fixed name should be fine because there will only be one hdmi-audio-codec device. Fix the codec name in rockchip rk3288_hdmi_analog machine driver. Signed-off-by: Cheng-Yi Chiang --- drivers/gpu/drm/bridge/synopsys/dw-hdmi-i2s-audio.c | 2 +- sound/soc/rockchip/rk3288_hdmi_analog.c | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/bridge/synopsys/dw-hdmi-i2s-audio.c b/drivers/gpu/drm/bridge/synopsys/dw-hdmi-i2s-audio.c index d7e65c869415..86bd482b9f94 100644 --- a/drivers/gpu/drm/bridge/synopsys/dw-hdmi-i2s-audio.c +++ b/drivers/gpu/drm/bridge/synopsys/dw-hdmi-i2s-audio.c @@ -193,7 +193,7 @@ static int snd_dw_hdmi_probe(struct platform_device *pdev) memset(&pdevinfo, 0, sizeof(pdevinfo)); pdevinfo.parent = pdev->dev.parent; - pdevinfo.id = PLATFORM_DEVID_AUTO; + pdevinfo.id = PLATFORM_DEVID_NONE; pdevinfo.name = HDMI_CODEC_DRV_NAME; pdevinfo.data = &pdata; pdevinfo.size_data = sizeof(pdata); diff --git a/sound/soc/rockchip/rk3288_hdmi_analog.c b/sound/soc/rockchip/rk3288_hdmi_analog.c index 767700c34ee2..8286025a8747 100644 --- a/sound/soc/rockchip/rk3288_hdmi_analog.c +++ b/sound/soc/rockchip/rk3288_hdmi_analog.c @@ -15,6 +15,7 @@ #include #include #include +#include #include #include #include @@ -142,7 +143,7 @@ static const struct snd_soc_ops rk_ops = { SND_SOC_DAILINK_DEFS(audio, DAILINK_COMP_ARRAY(COMP_EMPTY()), DAILINK_COMP_ARRAY(COMP_CODEC(NULL, NULL), - COMP_CODEC("hdmi-audio-codec.2.auto", "i2s-hifi")), + COMP_CODEC(HDMI_CODEC_DRV_NAME, "i2s-hifi")), DAILINK_COMP_ARRAY(COMP_EMPTY())); static struct snd_soc_dai_link rk_dailink = {