Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp1955263pxj; Wed, 19 May 2021 18:51:51 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxanz+yTBbU8VzqNlvBzoqP4d9bLjT3TLSdFzUP4BJp9emroUX75Xz4IK9dQsCsS9dstLM5 X-Received: by 2002:a17:907:77c7:: with SMTP id kz7mr2279000ejc.54.1621475511728; Wed, 19 May 2021 18:51:51 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1621475511; cv=none; d=google.com; s=arc-20160816; b=FQ7Vo5YbhVmijeT/IdQ1yBBPYDSdzYy4bdhdjmjc8hqXg7aU0u+HKa9XEdhQke+Udc S33YMMIlOm70nDymeNzTSsgoY5fk7TAFf+XsnQsGgIK1l2PNlNXYN9E4YDgKfqb+Qhi0 K9ns4lDyT97T+Rw8kLGeD8QZvNbDw7oJkRZQ7QSIcj/VkUHzJzrmHZ3NsR9O72YPoxOH OIum+cUt7YcLqNeuHb/eOEfoOOa8leWWlVEZA2HguoqaaK9sHnTIYCt1vPA7i89+Rg7i dI1CSUbwv4T+MJBayL8zfZqBLTcgVDh3yLSB8egi0YKj65cQG72leyaqkHT2hfex4ObR P2XQ== 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 :message-id:date:subject:cc:to:from:dkim-signature; bh=ir1Dpg3bgUq0v/H9js0abZRsZHQ5PmTY8mx+eB1aHs0=; b=EsfK1wXRPLPkAb9UeJY7MTSEAirv8n9xZyTUKfN4Zbwl2QJqtzZENkUc1ZP2vhfBEj vk2bEX4VaITAGZUm8SCA2tKO/jnt4v+FSFQVYu6PYhROz6r/0ZjxK8/zaFIDL5AQ2xE8 pu6BbVnjqg72lkxo01HCDzIQjPVfk+mCwon0excGfe/6Zb1iqdvpKseW+DSyRBJ/jIhB 9QuRzjznN7R1dysaws1b3ChCejfZlxIWPY0QPnz0GXctVNAfDeNoatZ5qamzdL0jD5pn HlyEpgc1Hh6I5L//ixR0iNexfXdTBoJ8Q67jhf0IriaR5ZLrdIyNy01cm7ACKsx/h8W/ 7+cQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=PtufKgnm; 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=chromium.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id k22si1025635edv.285.2021.05.19.18.51.28; Wed, 19 May 2021 18:51:51 -0700 (PDT) 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=@chromium.org header.s=google header.b=PtufKgnm; 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=chromium.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229498AbhETBtb (ORCPT + 99 others); Wed, 19 May 2021 21:49:31 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54296 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230137AbhETBt3 (ORCPT ); Wed, 19 May 2021 21:49:29 -0400 Received: from mail-pl1-x62b.google.com (mail-pl1-x62b.google.com [IPv6:2607:f8b0:4864:20::62b]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4E071C061574 for ; Wed, 19 May 2021 18:48:09 -0700 (PDT) Received: by mail-pl1-x62b.google.com with SMTP id z4so5906419plg.8 for ; Wed, 19 May 2021 18:48:09 -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:mime-version :content-transfer-encoding; bh=ir1Dpg3bgUq0v/H9js0abZRsZHQ5PmTY8mx+eB1aHs0=; b=PtufKgnmd6DXX0n+Vuz+quN0FhXP/QXYDqTuIbfCCrI+RpSi1wz08zBNGC8LZKvZfr 6Rarw7f4CMCfDB3Z2FRqJgd7rRYjBj34A/6TGR/0TmJOlrfC53kLnN2c1X4JGAAPqSTW l5i/oyLhU1BOH2qUsvcGKVwx7q62nSJljlteI= 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:mime-version :content-transfer-encoding; bh=ir1Dpg3bgUq0v/H9js0abZRsZHQ5PmTY8mx+eB1aHs0=; b=uN5Ej/8WxKobgB9qFjtUww4ZitsrYwBuA/BgwpTc2nmF7EQXD3j2G2ZPZkplXOvmTe pXrP30tCAdFvDOCD7i5n0ss2A+v+fT0pml9EQrv4RmixWUNwEIXSkjCRTRes5UYqQ9zX Miu5ZyN2YLYyWWK8t/HQzdNfxwxKqHemJ8Zl8CzES43/dxQpfBhANKOd+os6j+v8K9+n ZrPRVJ1bSBVPfrC40zcs/5H47EFPd2ASfrulvOzYkJ2qs4x5fqxxUVEI3XFiWwGADAXZ BwlY7l9pZ9+ZajG1aOaBuQnqIL9Is91mkgfU5pRq4GLLBB4ZHGt5l/kctKAdoZbrob32 uqoQ== X-Gm-Message-State: AOAM530tckdu/XYJBK5bxc9K64sEUBoq+ZYV8rCQJQeGjeep7olcg+VA HdAq+Znl6EVJ0TulBAnWtb33kA== X-Received: by 2002:a17:902:f291:b029:f0:ba5b:5c47 with SMTP id k17-20020a170902f291b02900f0ba5b5c47mr2963239plc.41.1621475288909; Wed, 19 May 2021 18:48:08 -0700 (PDT) Received: from smtp.gmail.com ([2620:15c:202:201:200b:db75:4e6c:8b96]) by smtp.gmail.com with ESMTPSA id v14sm490668pfi.25.2021.05.19.18.48.07 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 19 May 2021 18:48:08 -0700 (PDT) From: Stephen Boyd To: Mark Brown Cc: linux-kernel@vger.kernel.org, alsa-devel@alsa-project.org, linux-arm-msm@vger.kernel.org, Srinivas Kandagatla , Banajit Goswami Subject: [PATCH] ASoC: qcom: lpass-cpu: Use optional clk APIs Date: Wed, 19 May 2021 18:48:07 -0700 Message-Id: <20210520014807.3749797-1-swboyd@chromium.org> X-Mailer: git-send-email 2.31.1.751.gd2f1c929bd-goog MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org This driver spits out a warning for me at boot: sc7180-lpass-cpu 62f00000.lpass: asoc_qcom_lpass_cpu_platform_probe() error getting optional null: -2 but it looks like it is all an optional clk. Use the optional clk APIs here so that we don't see this message and everything else is the same. Cc: Srinivas Kandagatla Cc: Banajit Goswami Fixes: 3e53ac8230c1 ("ASoC: qcom: make osr clock optional") Signed-off-by: Stephen Boyd --- sound/soc/qcom/lpass-cpu.c | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) diff --git a/sound/soc/qcom/lpass-cpu.c b/sound/soc/qcom/lpass-cpu.c index c62d2612e8f5..28c7497344e3 100644 --- a/sound/soc/qcom/lpass-cpu.c +++ b/sound/soc/qcom/lpass-cpu.c @@ -835,18 +835,8 @@ int asoc_qcom_lpass_cpu_platform_probe(struct platform_device *pdev) if (dai_id == LPASS_DP_RX) continue; - drvdata->mi2s_osr_clk[dai_id] = devm_clk_get(dev, + drvdata->mi2s_osr_clk[dai_id] = devm_clk_get_optional(dev, variant->dai_osr_clk_names[i]); - if (IS_ERR(drvdata->mi2s_osr_clk[dai_id])) { - dev_warn(dev, - "%s() error getting optional %s: %ld\n", - __func__, - variant->dai_osr_clk_names[i], - PTR_ERR(drvdata->mi2s_osr_clk[dai_id])); - - drvdata->mi2s_osr_clk[dai_id] = NULL; - } - drvdata->mi2s_bit_clk[dai_id] = devm_clk_get(dev, variant->dai_bit_clk_names[i]); if (IS_ERR(drvdata->mi2s_bit_clk[dai_id])) { base-commit: 6efb943b8616ec53a5e444193dccf1af9ad627b5 -- https://chromeos.dev