From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-pf1-f175.google.com (mail-pf1-f175.google.com [209.85.210.175]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id B26073B47D5 for ; Wed, 15 Jul 2026 05:12:03 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.210.175 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1784092324; cv=none; b=BQOGYkr8Zp2edX0oGb9aNzcAVdgVVlcPo+32TQ/tglhti6cdq+pF4M1GCHfPfkKtlFZPyNBGhzjfrsdou7jspxs2wUTOTusQvcjUXbM98CcvS38cCgV8551pFw9+C9CwVKBcNUVu7zeo03SccckPc+wAQ8xUb159cBFIxSi9TRQ= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1784092324; c=relaxed/simple; bh=JPBdZyzURlk1+bQObNjx1u7L1CoI0zKQeh16Th7K6Bk=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=Wvx3Miio9dwqFRBLxXruQvyivOAFLrdwt2Yqv8xnkiDdH+wyBjuF1O+En2xLocB+2S0x2k+D/JRWZCXVrPvNhnS9WX9iMs2rDyI6wnqnuMO2LkHYOkxpWOO2mNhiPHATGvJrSnMxHBkftfU3iSLzXgDVRiGBaEcDOeyUtOnwUeQ= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=dAIj8UDR; arc=none smtp.client-ip=209.85.210.175 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="dAIj8UDR" Received: by mail-pf1-f175.google.com with SMTP id d2e1a72fcca58-84874b52eabso2327369b3a.0 for ; Tue, 14 Jul 2026 22:12:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1784092323; x=1784697123; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to:content-type; bh=T3PRPoMPx+OET/WGMVQSkA8IuTp6F1i04Nbb1oO1IQs=; b=dAIj8UDRRMr8y+FQI+vFcwdOIx/WCErIDc+ydPmROxrCJoydr3vFLETtRh0WLriijJ 5C283A1JxcBEf5MaiyPbhgVLoIzr9GnzQfvI9z8gdB22IbUyATqiwtQ1wJksWD6oR0sn NNB7YvCtK5Wt/kmyjqfyEp8stg+YqSV4pxZcUOMmcnSQB/taGQNOIDcxn3JHvMFpCjhe E5/nSKQLpbuLWPUm7S2Y/1mVTXmtS5uprUQ4V7Uu+PpF0VnakgA0zswodhYgKgOxZrEZ US2MdrEpa7f0YbAPLw2fVh+ZvFSIOZ1TMhB/gim8W4Q8+gwWhqsQNs4n3EoXP12aklxx Z/EQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1784092323; x=1784697123; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to:content-type; bh=T3PRPoMPx+OET/WGMVQSkA8IuTp6F1i04Nbb1oO1IQs=; b=CCmDDzGVLjYzsf3s0JJ6+yRT1oEtVLtdrRdF6mhxbicn/yA83j7rEN/2OmiWeIECDe JdfhtfOiV16hBcizqqnSVdr6Xi4BBgRhpUB97i/zjCgeOZ/KFOHIUuTFRKcxg+AWET1Y hNHj10oF1IKpiW6wRcMu9BJ4TSj3OM8Koa3ehvqcVJclpQh8zKxuydlEOD1AoHUuvmyM phyVuLFCgboYZksUTmW822RIRMskQweFibueYza0FHk9q8dyH9yHI4BfEfKCS8z+urMd KIKMyuNWlh+04XGusNU7MVPQ1SYRlGcWCzc/R/DVjlYXq/QpXYC2fQRx71sIkpCfroYj B1aw== X-Forwarded-Encrypted: i=1; AHgh+RpW8p1Ywwy+4lOcVsu6Bf9WBBTqGphtRs8u5Zbi7mV/GeT3BqZqdUJDTzbaKKeADh4221JrFR/71LDH+cg=@vger.kernel.org X-Gm-Message-State: AOJu0YzOGdIVMP5n+d+1Ru3mgWZSnJwHNg6jxp+chlqMPTAcbB1xU6bF LFPJzJK6NMt1OL6nd69vTjCZDlGADbVcUClZrdVS8Y9JeSYQwX16XELR X-Gm-Gg: AfdE7clrvwgbSA2opHvVG+9JxcLaE+ARR5ycuOyNMMOt1modpgtae6TwQ8kJL6PS031 lMf9y3+NEyAe461/i3B4egjWWlWuxqGMyn9JTAujHl6aP2fs82Ys3DDkIZB1xNC04PF241Rx4YP 76Gub1O/8wI7DE/MYhmL3dHv+UkA80xehBt2U9JxS2QXCHPHFD7lYFQtvwHxKTjxexbpyR3yolx G7zIZN4YelmSSjoLoS6GxTsjZDewNbUtiF2IeI6tX522PL8/LyYvtDbj4OihOnjgO+c2+Gv1/1l NmC78yXbaGsEhH1uz0knnlFtvMTidWjJgTmWb/Ay2sbARJACTDXTeMl36/KIr3jgusYbUAflOJO BRjNYAAXV9vz9eSCkibuFkIdfnd0e6Vw46WeWIsARS6pitw8Ey/nqExg6l7h5wLgfeYG5jLmpsq tArc0jdpd+zdPvRkUjlCSuiDhVRM1C0mhbLfZVreckS8VbEzKT+EXXVfLqTw== X-Received: by 2002:a05:6a00:179f:b0:848:60a2:4e9b with SMTP id d2e1a72fcca58-8488970ae6fmr14622666b3a.42.1784092323189; Tue, 14 Jul 2026 22:12:03 -0700 (PDT) Received: from phuc-desktop.. ([183.91.15.56]) by smtp.gmail.com with ESMTPSA id d2e1a72fcca58-84a4f271ddbsm2594093b3a.18.2026.07.14.22.11.59 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 14 Jul 2026 22:12:02 -0700 (PDT) From: phucduc.bui@gmail.com To: Mark Brown , Thierry Reding , Liam Girdwood , Jaroslav Kysela , Takashi Iwai , Jonathan Hunter Cc: Krzysztof Kozlowski , Sheetal , u.kleine-koenig@baylibre.com, Kuninori Morimoto , Rosen Penev , Piyush Patle , Takashi Sakamoto , Bjorn Helgaas , linux-tegra@vger.kernel.org, linux-kernel@vger.kernel.org, linux-sound@vger.kernel.org, bui duc phuc Subject: [PATCH 4/4] ASoC: tegra: tegra210: Use devm_clk_get_optional() for sync_input clock Date: Wed, 15 Jul 2026 12:11:15 +0700 Message-ID: <20260715051115.17385-5-phucduc.bui@gmail.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20260715051115.17385-1-phucduc.bui@gmail.com> References: <20260715051115.17385-1-phucduc.bui@gmail.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit From: bui duc phuc The existing comment states that the sync_input clock is only needed when another I/O is configured to use the current I2S instance as its input clock, and the current code does not treat its absence as an error. Use devm_clk_get_optional() to match the existing behaviour while still reporting real failures via dev_err_probe(). Update the comment to describe the optional nature of the clock rather than the previous error handling. Signed-off-by: bui duc phuc --- sound/soc/tegra/tegra210_i2s.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/sound/soc/tegra/tegra210_i2s.c b/sound/soc/tegra/tegra210_i2s.c index ff8c72fc38c5..e7e26e917291 100644 --- a/sound/soc/tegra/tegra210_i2s.c +++ b/sound/soc/tegra/tegra210_i2s.c @@ -1078,13 +1078,13 @@ static int tegra210_i2s_probe(struct platform_device *pdev) "can't retrieve I2S bit clock\n"); /* - * Not an error, as this clock is needed only when some other I/O - * requires input clock from current I2S instance, which is - * configurable from DT. + * This clock is optional and is only needed when another I/O uses + * the current I2S instance as its input clock, as configured in DT. */ - i2s->clk_sync_input = devm_clk_get(dev, "sync_input"); + i2s->clk_sync_input = devm_clk_get_optional(dev, "sync_input"); if (IS_ERR(i2s->clk_sync_input)) - dev_dbg(dev, "can't retrieve I2S sync input clock\n"); + return dev_err_probe(dev, PTR_ERR(i2s->clk_sync_input), + "can't retrieve I2S sync input clock\n"); regs = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(regs)) -- 2.43.0