Received: by 2002:a05:7412:a9a2:b0:e2:908c:2ebd with SMTP id o34csp2802373rdh; Mon, 30 Oct 2023 08:06:33 -0700 (PDT) X-Google-Smtp-Source: AGHT+IHIAqmuGTZtTpNj5ZovEDBxbpS0ZfgRpBdoFCTPElR1N+CrHUfCaLHDiwQJqFuyH4CUjcl0 X-Received: by 2002:a17:902:c211:b0:1c7:8345:f377 with SMTP id 17-20020a170902c21100b001c78345f377mr6657254pll.29.1698678392843; Mon, 30 Oct 2023 08:06:32 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1698678392; cv=none; d=google.com; s=arc-20160816; b=LYay51cmfSfu9lHro6EZp3GAeGR33ojJc7SM12Hiqx4BHRktShrXgIxSwaXuZWBlKJ DUBK6PCwcz8g3jwk0uvL7LozdcvjXCOhJ3OUhqGilTEHf6z8wvvNa98S+Tjay7ihxlfM o/cpceo9Bfxxg0cAgYNHkxJVh7ub0qXwAawW+WEzabQrffEfV/CGSiZSsVZEvQ3MMyiX nStepuBX+FImbOzBP00W60SCxV4tFq6f37UpfMt/O+bi8pD0wPOwI0VtYXvSSfjuSWsT 9SCVpagNzE3sqy4GRDC1Yvccb7ju/h5xb5aSmJ/0EY5Ylo1W9n9jogpiMYkZBo8NNlzY 8VXA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature :dkim-signature; bh=pRSRixE2mgVa7EvEDqaaDxfv9jGRdAqZmDs0EgL3tJ0=; fh=FveD8JvFGp03enXOpDNVPCHczTOY/28Mw7g62KFgPnA=; b=r3w8aGwOFQ9xlPDUipbqIu4LknKNnc1JfiCm917eQ3xE1U694JeVCgBHHs+9kUmmmm FYxKTe0fKcip/A236QhvT7a8NOGFlXduK8WYe3HN4H6kUiVKQQuyH2T55hZB8LZMX7bP g6Hgd09VJDXnF3Soe1Pr8ql9v27WZNV6h3Uxejr2hoYPKhmU4gIXpfe4nwg04RcA0n8+ ALYnGZlOYbfby1TXr2HxUEkGyqQ3Jsx+MZMwwnzZS3d9aocHEHn29Ke6zYXELqJrg97S U3l9US6ffVEmUIsI0v0nK+usOhWG1EfyR2ZlzeBq60ByzY6VTNMTrgsOqzHW3ZLz098x a+dw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@suse.de header.s=susede2_rsa header.b=DBG6F9BW; dkim=neutral (no key) header.i=@suse.de header.s=susede2_ed25519 header.b=E8m9QPC1; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=suse.de Return-Path: Received: from lipwig.vger.email (lipwig.vger.email. [23.128.96.33]) by mx.google.com with ESMTPS id e17-20020a170902f1d100b001b8922e82e3si5106114plc.297.2023.10.30.08.06.32 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 30 Oct 2023 08:06:32 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) client-ip=23.128.96.33; Authentication-Results: mx.google.com; dkim=pass header.i=@suse.de header.s=susede2_rsa header.b=DBG6F9BW; dkim=neutral (no key) header.i=@suse.de header.s=susede2_ed25519 header.b=E8m9QPC1; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=suse.de Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by lipwig.vger.email (Postfix) with ESMTP id 7A2AD80784FC; Mon, 30 Oct 2023 08:05:58 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at lipwig.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233597AbjJ3PFx (ORCPT + 99 others); Mon, 30 Oct 2023 11:05:53 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:41222 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233594AbjJ3PFu (ORCPT ); Mon, 30 Oct 2023 11:05:50 -0400 Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.220.28]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 77D51DB for ; Mon, 30 Oct 2023 08:05:47 -0700 (PDT) Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id 314C9218D6; Mon, 30 Oct 2023 15:05:46 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1698678346; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=pRSRixE2mgVa7EvEDqaaDxfv9jGRdAqZmDs0EgL3tJ0=; b=DBG6F9BWLVvk/qnBjGmeeh4L/T31SoFVPzcLORdktl2gR3VdOuH70WJkQImKtuu3+WvAip ZrcabA/a7gFpz4n9Y/aLcjal20VYAEnBkXnY5r2N2V13Ru9RPgG6xOhghILuZMaI5qGdbk efFTa+0H9zXRkAtvYBCB7EgUdBlGBqs= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1698678346; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=pRSRixE2mgVa7EvEDqaaDxfv9jGRdAqZmDs0EgL3tJ0=; b=E8m9QPC1QxJVZvTMOoRu1BnzSKrZ/n3y2iFSoVnyWXVWle9Dx6kyqsGEzdmQjK8IO1L8I6 asrlzLntKGUtSkCg== Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id 171D6138EF; Mon, 30 Oct 2023 15:05:46 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id f+eYBUrGP2XCWgAAMHmgww (envelope-from ); Mon, 30 Oct 2023 15:05:46 +0000 Date: Mon, 30 Oct 2023 16:07:21 +0100 From: Daniel Wagner To: Niklas Cassel Cc: Keith Busch , "linux-nvme@lists.infradead.org" , "linux-kernel@vger.kernel.org" , Christoph Hellwig , Kenji Tomonaga Subject: Re: [PATCH v2] nvme: update firmware version after commit Message-ID: References: <20231013163420.3097-1-dwagner@suse.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-0.8 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lipwig.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (lipwig.vger.email [0.0.0.0]); Mon, 30 Oct 2023 08:05:58 -0700 (PDT) On Fri, Oct 13, 2023 at 08:37:32PM +0000, Niklas Cassel wrote: > On Fri, Oct 13, 2023 at 10:43:48AM -0600, Keith Busch wrote: > > On Fri, Oct 13, 2023 at 06:34:20PM +0200, Daniel Wagner wrote: > > > if (nvme_get_log(ctrl, NVME_NSID_ALL, NVME_LOG_FW_SLOT, 0, NVME_CSI_NVM, > > > - log, sizeof(*log), 0)) > > > + log, sizeof(*log), 0)) { > > > dev_warn(ctrl->device, "Get FW SLOT INFO log error\n"); > > > + goto out_free_log; > > > + } > > > + > > > + afi = le64_to_cpu(log->afi); > > BTW, this field is a single byte, so there should be no need to > use *_to_cpu() on this. (Byte order is only important when the > field is more than one byte.) Indeed, I somehow thought afi is of type __le64.