From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-3.8 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 1D14CC433E7 for ; Mon, 12 Oct 2020 11:02:40 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (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 94FF2206BE for ; Mon, 12 Oct 2020 11:02:39 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="2yEeDPPA" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 94FF2206BE Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=arri.de Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To:Message-ID:Date: Subject:To:From:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=YVsNso36ifaycEih4+7K4AzMl+LkBxZIRP5JmDTSCUU=; b=2yEeDPPAqJjU07tgRWUl0LtRV JPlxjOhe+X+LJZTckeaJq7UcxhXteWSOkJ3nG+QCD3PlvcfxoaNKZuwxGjBuM6oUotMkN9WhCsglx EW0JwKbdAYbf/QxKvtS1Zu2dNfp7+XZHcOjTfd1VrSu8psBG3+C1ixIVQZRqKl/0TuytVF0lbRlR+ TcbAMztfH7D4hf08grvWw+6l2E/vfHrnbdr2wAg3/e3pNxTE+6ZyoWOFeFdG2liu/JwFXuyHF3oOJ twTLWNKuhVhelfUUFDb/rAzEbin91+ZhnZrZZahsWzh+DkhHtPx6NMZlOrAepYUlxOrmAy+kHInu+ KU+SyXuWA==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1kRvZw-0004h4-I7; Mon, 12 Oct 2020 11:01:20 +0000 Received: from mailout04.rmx.de ([94.199.90.94]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1kRvZs-0004eb-39 for linux-arm-kernel@lists.infradead.org; Mon, 12 Oct 2020 11:01:18 +0000 Received: from kdin02.retarus.com (kdin02.dmz1.retloc [172.19.17.49]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mailout04.rmx.de (Postfix) with ESMTPS id 4C8whW66vqz3r0h8; Mon, 12 Oct 2020 13:00:59 +0200 (CEST) Received: from mta.arri.de (unknown [217.111.95.66]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-SHA384 (256/256 bits)) (No client certificate requested) by kdin02.retarus.com (Postfix) with ESMTPS id 4C8whK1HBLz2TTNp; Mon, 12 Oct 2020 13:00:49 +0200 (CEST) Received: from n95hx1g2.localnet (192.168.54.46) by mta.arri.de (192.168.100.104) with Microsoft SMTP Server (TLS) id 14.3.408.0; Mon, 12 Oct 2020 12:59:35 +0200 From: Christian Eggers To: Sascha Hauer Subject: Re: [PATCH] spi: imx: Revert "spi: imx: enable runtime pm support" Date: Mon, 12 Oct 2020 12:59:34 +0200 Message-ID: <2670390.HS4A6M72fu@n95hx1g2> Organization: Arnold & Richter Cine Technik GmbH & Co. Betriebs KG In-Reply-To: <20201009073944.GA11648@pengutronix.de> References: <20201009042738.26602-1-ceggers@arri.de> <20201009073944.GA11648@pengutronix.de> MIME-Version: 1.0 X-Originating-IP: [192.168.54.46] X-RMX-ID: 20201012-130049-4C8whK1HBLz2TTNp-0@kdin02 X-RMX-SOURCE: 217.111.95.66 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20201012_070116_272660_E1D53A55 X-CRM114-Status: GOOD ( 16.90 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Shawn Guo , linux-kernel@vger.kernel.org, linux-spi@vger.kernel.org, Mark Brown , Clark Wang , NXP Linux Team , Pengutronix Kernel Team , Fabio Estevam , linux-arm-kernel@lists.infradead.org Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Hi Sascha, On Friday, 9 October 2020, 09:39:44 CEST, Sascha Hauer wrote: > On Fri, Oct 09, 2020 at 06:27:38AM +0200, Christian Eggers wrote: > > This reverts commit 525c9e5a32bd7951eae3f06d9d077fea51718a6c. > > > > If CONFIG_PM is disabled, the system completely freezes on probe as > > nothing enables the clock of the SPI peripheral. > > Instead of reverting it, why not just fix it? > > Normally the device should be brought to active state manually in probe > before pm_runtime takes over, then CONFIG_PM disabled doesn't hurt. > Using pm_runtime to put the device to active state initially has the > problem you describe. prior introducing runtime pm for spi-imx, the clock was "manually" enabled and disabled around each transfer (so the power usage should already have been optimal). If we would manually enable the clock in probe() as you suggested, for users without CONFIG_PM there would be a drawback compared with the previous state (as the clock will always be on now). What is the benefit of controlling the SPI clock with runtime PM instead of doing it manually? As I have no experience with runtime PM, hopefully somebody else can fix (or revert) this. @Clark: I forgot to put you on CC on my initial message. You can find the full discussion here: https://lore.kernel.org/patchwork/patch/1318736/ Best regards Christian _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel