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 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 04520C433F5 for ; Mon, 4 Oct 2021 17:15:01 +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 C01426139F for ; Mon, 4 Oct 2021 17:15:00 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org C01426139F Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=ziepe.ca 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:In-Reply-To:MIME-Version:References: Message-ID:Subject:Cc:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=oriImz64R/z+jBeO56FU7Qa/08KAW3wpZlY3PiuY/lw=; b=BzNdgJpXV9oHM1 ybcCqhK6lnQUZVezLpJZNcalsh6321n9ULvYiQeHi8whMWTWSmNEiDw1UDwBZbu4oFuw9lThsOiJE 4lFIYFqlztjTelktd6SpJkRVtidUp+z0IBux3S8/pRFbekpnTLjFq8omWugjlu+4iuMY/OYbiz9g7 ucomQRMqSGPzJXubcKZzze7sOfqg8h+8jbcrg7bGlyj5byqwr1YyR9Wb792grquUhI7goVxlLYO4X 65Ab3dono1kQgHWuOS6sDwM4u+L93RpSIAxlQjQHgrv/78rUE6Dh03w7JjWRfRiEp41gveeqoJWlR MBwDiiCy+9sKQCZHTKaA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1mXRWV-007JZp-QO; Mon, 04 Oct 2021 17:13:08 +0000 Received: from mail-qt1-x82d.google.com ([2607:f8b0:4864:20::82d]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1mXRWR-007JYT-Hf for linux-arm-kernel@lists.infradead.org; Mon, 04 Oct 2021 17:13:04 +0000 Received: by mail-qt1-x82d.google.com with SMTP id t2so260089qtx.8 for ; Mon, 04 Oct 2021 10:13:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ziepe.ca; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=cOKjddDH5+4xS9V6U2CWaH8D4d1KqVMcYRtfQMaTs5c=; b=GgvWKF+Qow1pRmPozvXwK2n6+vlzlAdHg6CBoGnUsGSCYEVdzLPd45F7dE6qGax55W uIZXUFTGdekCCcreTwaTXheY/u4z2Htz1g2kRHKpkvOjcN7f9zK83dzPuh36ynHbAj5r Q0khND2u9HtkPw+KjpvYUFBXWsR+ItBJjfAn2U2Zxrx3MEB63rzpJWoot7UvfQCk6YfW IwQEebSORZ1pdAiMpCIg3xzfCmjRrNJlswM7uqD+Ei7mVjWfa3RP2U+6lKdPt4ub+2MK vQUGdOTByuoOBxPzrJiOvrS8wxIeXzQoY3i9NFRVPcpqoDY3nsjb74rbLQb4AXYrn/6q QCNg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=cOKjddDH5+4xS9V6U2CWaH8D4d1KqVMcYRtfQMaTs5c=; b=xU/ZQTqWXOjByfzSiGfWoFj9lVuId3eHxXT2sqjVH//2JmjrcoIJQcjZk4/n+5SzTi 2+1hBqEQwfK2Qrlwrq2MiPvRA1VyDYuCuWOnGp2mVhRCL77zNoWYXxWd7DMzUaLw7k2Y XEz3TO1cQjJ4epD/grHhMk8HHrKpG8ar9nYMlM1Cd2CVFfMqFo2clBdQUAax77zNWIQO a0tpXxLXuBHtLdMCfwx7B5uS2Y81A3kQe6iROx2MVt7BkmItiCuR8xjvXbSGLT4vGYUH Pa4biM0a5Zcxz/lwxh5V/yvbOEZrdL/o6FATcYteAN/14a3Thi0sLTF5wau6biWmSSce +q8g== X-Gm-Message-State: AOAM5301LakvjDAfp1A5Wib/sSeq8vykEdgDVtqD/qFpo0AUFAJF9TNf rJf5uV0TTzjbKNparC2dxX6QwA== X-Google-Smtp-Source: ABdhPJyHXh9xAEaI+chzKoDCbjRMjAzxAmOsUGwwrilg5S3YihxeXByibrc9cOiMrfCR5Vojnwty/g== X-Received: by 2002:ac8:709a:: with SMTP id y26mr14324507qto.142.1633367582734; Mon, 04 Oct 2021 10:13:02 -0700 (PDT) Received: from ziepe.ca (hlfxns017vw-142-162-113-129.dhcp-dynamic.fibreop.ns.bellaliant.net. [142.162.113.129]) by smtp.gmail.com with ESMTPSA id h14sm8793364qkn.4.2021.10.04.10.13.02 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 04 Oct 2021 10:13:02 -0700 (PDT) Received: from jgg by mlx with local (Exim 4.94) (envelope-from ) id 1mXRWP-00AXWA-O2; Mon, 04 Oct 2021 14:13:01 -0300 Date: Mon, 4 Oct 2021 14:13:01 -0300 From: Jason Gunthorpe To: Florian Fainelli Cc: Mark Brown , Lino Sanfilippo , rjui@broadcom.com, sbranden@broadcom.com, bcm-kernel-feedback-list@broadcom.com, nsaenz@kernel.org, linux-spi@vger.kernel.org, linux-rpi-kernel@lists.infradead.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, p.rosenberger@kunbus.com, linux-integrity@vger.kernel.org, stable@vger.kernel.org Subject: Re: [PATCH] spi: bcm2835: do not unregister controller in shutdown handler Message-ID: <20211004171301.GA3544071@ziepe.ca> References: <20211001175422.GA53652@sirena.org.uk> <2c4d7115-7a02-f79e-c91b-3c2dd54051b2@gmx.de> <20211004131756.GW3544071@ziepe.ca> <20211004154436.GY3544071@ziepe.ca> <20211004165127.GZ3544071@ziepe.ca> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20211004_101303_621545_52106F8D X-CRM114-Status: GOOD ( 21.78 ) 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: , 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 On Mon, Oct 04, 2021 at 09:55:32AM -0700, Florian Fainelli wrote: > On 10/4/21 9:51 AM, Jason Gunthorpe wrote: > > On Mon, Oct 04, 2021 at 09:36:37AM -0700, Florian Fainelli wrote: > > > >> No please don't, I should have arguably justified the reasons why > >> better, but the main reason is that one of the platforms on which this > >> driver is used has received extensive power management analysis and > >> changes, and shutting down every bit of hardware, including something as > >> small as a SPI controller, and its clock (and its PLL) helped meet > >> stringent power targets. > > > > Huh? for device shutdown? What would this matter if the next step is > > reboot or power off? > > Power off, the device is put into a low power state (equivalent to ACPI > S5) and then a remote control key press, or a GPIO could wake-up the > device again. While it is in that mode, it consumes less than 0.5W(AC). > Imagine your stick/cast/broom behind your TV falling in that category. So really this is more of a very deep sleep that cannot be recovered from than what other platforms would call a shutdown - eg the powerdomain of the device under driver control will not loose power. I'm kind of surprised a scheme like this didn't involve a FW call after Linux is done with the CPUs to quiet all the HW and let it sleep, I've built things that way before at least. > I am fairly sure that no driver write knows about the being bound in > time aspect. Well, it is a logical consequence. The system is shutting down, no driver should be designed to deadlock the shutdown forever. I suppose this is why I've occasionally seen Linux just hang at a black screen and no power off when told to shutdown :) Jason _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel