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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 62CD8C32793 for ; Wed, 18 Jan 2023 05:25:34 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229589AbjARFZa (ORCPT ); Wed, 18 Jan 2023 00:25:30 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39962 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229579AbjARFYz (ORCPT ); Wed, 18 Jan 2023 00:24:55 -0500 Received: from verein.lst.de (verein.lst.de [213.95.11.211]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D824C50871 for ; Tue, 17 Jan 2023 21:24:54 -0800 (PST) Received: by verein.lst.de (Postfix, from userid 2407) id 74CF167373; Wed, 18 Jan 2023 06:24:50 +0100 (CET) Date: Wed, 18 Jan 2023 06:24:50 +0100 From: Christoph Hellwig To: Janne Grunau Cc: Hector Martin , Sven Peter , Keith Busch , Jens Axboe , Christoph Hellwig , Sagi Grimberg , Alyssa Rosenzweig , Eric Curtin , asahi@lists.linux.dev, linux-arm-kernel@lists.infradead.org, linux-nvme@lists.infradead.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v2 1/2] nvme-apple: Reset controller during shutdown Message-ID: <20230118052450.GA24742@lst.de> References: <20230114-apple-nvme-suspend-fixes-v6.2-v2-0-9157bf633dba@jannau.net> <20230114-apple-nvme-suspend-fixes-v6.2-v2-1-9157bf633dba@jannau.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20230114-apple-nvme-suspend-fixes-v6.2-v2-1-9157bf633dba@jannau.net> User-Agent: Mutt/1.5.17 (2007-11-01) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Jan 17, 2023 at 07:25:00PM +0100, Janne Grunau wrote: > + /* > + * Always reset the NVMe controller on shutdown. The reset is > + * required to shutdown the co-processor cleanly. > + */ Hmm. This comment doesn't seem to match the discussion we had last week. Which would be: /* * NVMe requires a reset before setting up a controller to * ensure it is in a clean state. For NVMe PCIe this is * done in the setup path to be able to deal with controllers * in any kind of state. For for Apple devices, the firmware * will not be available at that time and the reset will * time out. Thus reset after shutting the NVMe controller * down and before shutting the firmware down. */