From patchwork Mon Oct 11 16:57:02 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hector Martin X-Patchwork-Id: 12550617 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 8EB3FC433F5 for ; Mon, 11 Oct 2021 17:00:57 +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 598DF60F6E for ; Mon, 11 Oct 2021 17:00:57 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 598DF60F6E Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=marcan.st Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=3CklIHugj4Xm2bqobFrKaKj4wgXnLDPpfCSRtxkMwg8=; b=2vJIXKutonFkpb ruFgevtbR6AM0y5NiO0jv41JQ1Wg2juC4nBlmxCVnvYkGYvLTDiPztM1mhB3bSzrn5cpMmlAeJs8h C5MkIhgxQn0lNJwcWE7cC7MPGzfu+T+svrpt6S2iNwmL7BYzDxmnjWZC2Qduqje7YNinHDzFWRvIh SyiyBOaMdsmizbnEIDVPMP2Oi1nDdSNfw0sqc4q+EmJo39j07M3o59qqpxuqZE29sCFWe8dxnSg5y 4M1/CnBm+9+oMsvIG8GxQHQj5Tp4z5T9+Pb8iAP1V/rSj3C19LBf4QJz4uvUx7O0YVhcMrDHgsO3c fdZL4lk9Zu2v5xpy5wAA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1mZyd7-00A8Sp-Fn; Mon, 11 Oct 2021 16:58:25 +0000 Received: from marcansoft.com ([212.63.210.85] helo=mail.marcansoft.com) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1mZycb-00A8IQ-Fi for linux-arm-kernel@lists.infradead.org; Mon, 11 Oct 2021 16:57:54 +0000 Received: from [127.0.0.1] (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: hector@marcansoft.com) by mail.marcansoft.com (Postfix) with ESMTPSA id A1FE742468; Mon, 11 Oct 2021 16:57:46 +0000 (UTC) From: Hector Martin To: linux-arm-kernel@lists.infradead.org Cc: Hector Martin , Alyssa Rosenzweig , Sven Peter , Marc Zyngier , Mark Kettenis , Michael Turquette , Stephen Boyd , Rob Herring , Krzysztof Kozlowski , Viresh Kumar , Nishanth Menon , Catalin Marinas , "Rafael J. Wysocki" , Kevin Hilman , Ulf Hansson , linux-clk@vger.kernel.org, devicetree@vger.kernel.org, linux-pm@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [RFC PATCH 4/9] opp: core: Don't warn if required OPP device does not exist Date: Tue, 12 Oct 2021 01:57:02 +0900 Message-Id: <20211011165707.138157-5-marcan@marcan.st> X-Mailer: git-send-email 2.33.0 In-Reply-To: <20211011165707.138157-1-marcan@marcan.st> References: <20211011165707.138157-1-marcan@marcan.st> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20211011_095753_703119_E32DFEAB X-CRM114-Status: GOOD ( 13.52 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org When required-opps is used in CPU OPP tables, there is no parent power domain to drive it. Squelch this error, to allow a clock driver to handle this directly instead. Signed-off-by: Hector Martin --- drivers/opp/core.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/drivers/opp/core.c b/drivers/opp/core.c index 04b4691a8aac..89e616721f70 100644 --- a/drivers/opp/core.c +++ b/drivers/opp/core.c @@ -873,12 +873,13 @@ static int _set_required_opp(struct device *dev, struct device *pd_dev, return 0; ret = dev_pm_genpd_set_performance_state(pd_dev, pstate); - if (ret) { + if (ret && ret != -ENODEV) { dev_err(dev, "Failed to set performance rate of %s: %d (%d)\n", dev_name(pd_dev), pstate, ret); + return ret; } - return ret; + return 0; } /* This is only called for PM domain for now */