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: 11149893 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 6C73816B1 for ; Wed, 18 Sep 2019 08:27:59 +0000 (UTC) Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) (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 F3F9120640 for ; Wed, 18 Sep 2019 08:27:58 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=alsa-project.org header.i=@alsa-project.org header.b="qOx1L35R"; 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 F3F9120640 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=chromium.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=alsa-devel-bounces@alsa-project.org Received: from alsa1.perex.cz (alsa1.perex.cz [207.180.221.201]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by alsa0.perex.cz (Postfix) with ESMTPS id 3C9B81685; Wed, 18 Sep 2019 10:27:07 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz 3C9B81685 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1568795277; bh=3gjBbl4tKuyq4TuQoOKQwmRpARUxY7Xwr6IA2PwK3HQ=; h=From:To:Date:In-Reply-To:References:Cc:Subject:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From; b=qOx1L35RXyH+WDA3An2Zaaq9WVysZmwwK4s6EqZxASpk8vAyGOMhuuMa99Tdrl1Qs wSO9taVfCtXUxvd5hHzXGapBd2oE+uHlwUUo7u5L/F+oBkVJe1px34CcIJzaS4rtAH TwzRDftGdPPitkA2ijdZ1DFjBOHMMeRzy0tKdh0Q= Received: from alsa1.perex.cz (localhost.localdomain [127.0.0.1]) by alsa1.perex.cz (Postfix) with ESMTP id 5207AF805FA; Wed, 18 Sep 2019 10:25:43 +0200 (CEST) X-Original-To: alsa-devel@alsa-project.org Delivered-To: alsa-devel@alsa-project.org Received: by alsa1.perex.cz (Postfix, from userid 50401) id 4696DF805F7; Wed, 18 Sep 2019 10:25:42 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on alsa1.perex.cz X-Spam-Level: X-Spam-Status: No, score=-0.1 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=disabled version=3.4.0 Received: from mail-pl1-x642.google.com (mail-pl1-x642.google.com [IPv6:2607:f8b0:4864:20::642]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id 9A3B1F805F7 for ; Wed, 18 Sep 2019 10:25:38 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz 9A3B1F805F7 Authentication-Results: alsa1.perex.cz; dkim=pass (1024-bit key) header.d=chromium.org header.i=@chromium.org header.b="PEfuM16P" Received: by mail-pl1-x642.google.com with SMTP id x6so1286886plv.6 for ; Wed, 18 Sep 2019 01:25:38 -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=kzw1/KJiNK36GkScSsiJYm6iqAnOVppOpH0hd7Nps3ywgw/VmozXFuvpO2aLhKr1f7 I2mSJQTSslVhE+Mphv+bgZMe91gkMquzw6l3klcssacuefPlcn26ty3WiSQjBIFq30sg kFDfgGePWV6KldLiFRC5bDu14l9fA9O+g/2pGwhGENVYHhtdVxx/dnc26LAXCmW9P+Yl /j+IyQzZkJYVXHCvZmtRDciyQNLWV0eUqkxAx8gapheQ8hg+bNSwgfRvTqTaIpWsUjOw 4Val4Etl5K4I2joe0LaP0GtKlcOdFCYExG6iJkywCspfLvvu6pNYBVgW2QunqYYb6p/B YIoA== X-Gm-Message-State: APjAAAXUjVBwzlcdfG0n4AdMMZicisVkop+LfDW6UgHmzJBsc4Ggo4kC RF6RkBO4xou1q5u6WoY9LLBrzQ== 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 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 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 , linux-arm-kernel@lists.infradead.org, Jernej Skrabec , dianders@chromium.org, Daniel Vetter Subject: [alsa-devel] [PATCH v6 2/4] drm: dw-hdmi-i2s: Use fixed id for codec device X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: alsa-devel-bounces@alsa-project.org Sender: "Alsa-devel" 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 = {