From patchwork Wed Jul 27 18:20:34 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Baryshkov X-Patchwork-Id: 12930674 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 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 smtp.lore.kernel.org (Postfix) with ESMTPS id 82038C04A68 for ; Wed, 27 Jul 2022 18:21:49 +0000 (UTC) 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: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:In-Reply-To:References: List-Owner; bh=n+zSpRiEiCQNTkYZHzVv/upOUxiIbYJDHEVVqAXRJqk=; b=AV5x8Krlm9nhWU fjjbOEwt/n7KRUJneiF29K8EPzSOkrDfPadtYNzcOR7jtvDlAyJtDYel+p+X1CeGCts/kFLHr1NjU pmMtCfjN5lbrRLlNOab70cg4fRUBorVEJLyvoT4SdmWkzASu4osCz1oVnY3pZCnNq2VWPVhA+pPGG /0k7r002vyrpYnb+I/1wdE6t/1UR2eo2iOXOHJ56nFSB2/jY7wcipKFFc8Kd870v+6t/ADfkvMdT/ DAI5JeQEw4ia/qvtQrfkDlRqzSItySZLJa6xCcZ8pxIWN1PDe/FdiOFbjRJWk1mGj/SK+U4oLtamw YFCwDW4sHT1TbXQL65Jw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1oGleF-00GWpU-Lr; Wed, 27 Jul 2022 18:20:43 +0000 Received: from mail-lj1-x233.google.com ([2a00:1450:4864:20::233]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1oGleC-00GWlo-36 for linux-arm-kernel@lists.infradead.org; Wed, 27 Jul 2022 18:20:41 +0000 Received: by mail-lj1-x233.google.com with SMTP id z13so20311989ljj.6 for ; Wed, 27 Jul 2022 11:20:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=Pfz4ucLua8Uf/3c1EnbcfE9Jss18H9ObDxnKPg92bNA=; b=r3JdHvFvd/BmJ7+OQbTmw6h12geAftWU58MlN65plTwUZOZF8EKRclSeeaCcStmsdd Ifo9YqtCLjRQIh6jz/Xjb+A9FG2CUFWIGjdd2ovCNtgyjTdpl95LkiZJmgY3Wwws2sCj O/T3atapdONt77sd5xTCVqsOEibooq6GNJxwuafoss5tr9ZhX/Ph5wKEgAhBvXPHcI2r +HFoYIOIZejk4t+8Bb0R4vpRDMYeN9puN9bIvwinBimQMiy2ykXIa3f5JnllV5lcAPWz iJQ7IC4nJMPw5JJvxc4gdYC27e73XhYvbd5FLuiFH7PpJShrJS8XeyYMjU51aSQPQ9ul nhjQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=Pfz4ucLua8Uf/3c1EnbcfE9Jss18H9ObDxnKPg92bNA=; b=4fny0LeIH+xtLW7j4UluKJlChRrwraDXqC4e+U+G3+pRRqifqQbey22k00bMgjnuw3 OumZr97GbLxMu3LcNESfYdpGcaZ7+m6ovTLK/h56QLRodq/vhyhXeIBjPNr697ownlh1 y0qAcKPXTBf8af/pfw7JxOYzvXV03oI1L+2LIEmrKXZX/lwIf1N4NcbHY6a9d8KeMtfq oCToIfFlCVvrwzXOdYLgCCB00E+Civ3PRXS7L8BiWRcXoM/FeS/HlXJ+6T1uLY3oim68 QtnsmcpWm91XW2De+2JzqJMIgLgN/rdetyrAKnXBsOMwVngsx40+y/EtaOB5qXdZCP5Z zayA== X-Gm-Message-State: AJIora8yXNkZa3uXH17GILTJioh7gRD2RmGoyok9TQ6D7hCR4ZZAPeLo 76Z7SnGzH+7tFvuBimCb65PipA== X-Google-Smtp-Source: AGRyM1tvNOnLvQMG3h/BExaz3Z0xrLsDolUoR6VfIRtzQ2/GOVPeGc/UPBnV0muwc8DoKRc8SgnOxw== X-Received: by 2002:a2e:b057:0:b0:25d:fc4a:5b6 with SMTP id d23-20020a2eb057000000b0025dfc4a05b6mr6878322ljl.24.1658946035272; Wed, 27 Jul 2022 11:20:35 -0700 (PDT) Received: from eriador.lan ([37.153.55.125]) by smtp.gmail.com with ESMTPSA id bg35-20020a05651c0ba300b0025d2d495dc6sm1118764ljb.66.2022.07.27.11.20.34 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 27 Jul 2022 11:20:34 -0700 (PDT) From: Dmitry Baryshkov To: Mark Rutland , Lorenzo Pieralisi Cc: linux-arm-kernel@lists.infradead.org, linux-pm@vger.kernel.org Subject: [PATCH] PSCI: Print a warning if PSCI doesn't accept PC mode Date: Wed, 27 Jul 2022 21:20:34 +0300 Message-Id: <20220727182034.983727-1-dmitry.baryshkov@linaro.org> X-Mailer: git-send-email 2.35.1 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220727_112040_155379_966E8DE3 X-CRM114-Status: GOOD ( 11.34 ) 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 The function psci_pd_try_set_osi_mode() will print an error if enabling OSI mode fails. To ease debugging PSCI issues print corresponding message if switching to PC mode fails too. Signed-off-by: Dmitry Baryshkov --- drivers/firmware/psci/psci.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/firmware/psci/psci.c b/drivers/firmware/psci/psci.c index cfb448eabdaa..b907768eea01 100644 --- a/drivers/firmware/psci/psci.c +++ b/drivers/firmware/psci/psci.c @@ -597,7 +597,9 @@ static int __init psci_1_0_init(struct device_node *np) pr_info("OSI mode supported.\n"); /* Default to PC mode. */ - psci_set_osi_mode(false); + err = psci_set_osi_mode(false); + if (err) + pr_info("setting PC mode failed with %d\n", err); } return 0;