Received: by 2002:a05:7412:8521:b0:e2:908c:2ebd with SMTP id t33csp630390rdf; Fri, 3 Nov 2023 10:09:39 -0700 (PDT) X-Google-Smtp-Source: AGHT+IEpk+agceMfxIvC+E2JLpKI5pwPFFXhM3hbzmTl0pX86+njdnafkq5e3wN4RdCRVGD2vUPe X-Received: by 2002:a05:6358:cb23:b0:168:eb13:807d with SMTP id gr35-20020a056358cb2300b00168eb13807dmr19649986rwb.14.1699031378807; Fri, 03 Nov 2023 10:09:38 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1699031378; cv=none; d=google.com; s=arc-20160816; b=StbJebg92bayodXpS8ml2+NvbnOZ1A/BYC1ry26o2+ozA3grO42gnUVeSSHeJckGy4 Z6IJTp9rcg+GH0rXfDJ6zbQwlID+7Ia9zrCR5XygSPxjVUdBKmtG4iFFVPd89DBOBP+F rWD+MvB5wkaMLgMqrH6NFchn9tSUBgIMI0OGwEDWyTmwEGoMn64PkIt6cXEN64mPAEjf xd/V7JOKATMtnf+1Czlg5fAlHz1Y+B1X3PNqZzLkOoQ5mXga+LKwmH5NRSlObkDhYfTJ bBxzrg5+8R6tw3zOUg5yCMJskU0jVAHsiuUbLfBJQ4OSzuQ2w2NttiA6t7dnq+AnNnGY vvyw== 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; bh=LZQRJECQvRD0auEjV4St85BEREnST+CNM+72xZ0RJWw=; fh=6gCmTtEhkwkVgC2NPLOXwxKxseMiCBV7DsjRUiW2oN8=; b=FytgxxWXCBH8lsJBRk4Hj6tLGSbbhdIniq1FrDwfgVR2jXcXagwcccNnxdM008kwxe keouY7UQdtEpqtrjMLi5+xry8v+CXPaSeZq8ECb3YroAmZbEw6JCzP39Mb18pGslHLVy ux/8F7msEwe6NfaolRFE8UJd/ceA3xTWqy8crKQt5/Zrm84oBPKGB2S1fVqq059VAnwE iQqZx/BeLplB2TeI9GWAJrf4WV8ZD/p9E1JullansIbLgGhqqxIHMZkpGdObzPb4iYw9 xKxHoA/dtzMs+qG173pxvcUP12sNK6eccT+UUXf/p4QHyto5dimufhXKIvY2XpAUen2g LjDQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=tkhmF8t+; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from snail.vger.email (snail.vger.email. [23.128.96.37]) by mx.google.com with ESMTPS id p27-20020a635b1b000000b005b92db1e113si1868798pgb.702.2023.11.03.10.09.38 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 03 Nov 2023 10:09:38 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 as permitted sender) client-ip=23.128.96.37; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=tkhmF8t+; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by snail.vger.email (Postfix) with ESMTP id D57B783C1DEB; Fri, 3 Nov 2023 10:09:37 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at snail.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1376508AbjKCRJh (ORCPT + 99 others); Fri, 3 Nov 2023 13:09:37 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34988 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1345483AbjKCRJg (ORCPT ); Fri, 3 Nov 2023 13:09:36 -0400 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id CB85A8E for ; Fri, 3 Nov 2023 10:09:33 -0700 (PDT) Received: by smtp.kernel.org (Postfix) with ESMTPSA id B4560C433C8; Fri, 3 Nov 2023 17:09:30 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1699031373; bh=sq3L5gUrO9wxalfWm5HOiwIfw0lC8DkpESy25Odx+hE=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=tkhmF8t+hdszhtvZFdcxIUCkZguAyqoHMDR2jOPEL+5Ked3zu9OKkuNyiwqVLy/zr fdB95qyMygnaWOzw5t9vbfRhjzYrKSYi0JNsxd4zmLq+FPUmFeRWegt7XPiFDEx7GV nPHRTjDtBEdyok9/nLUpZjzEpOVgRY7Tw1o/izNpDfFzPrsq23Y+FKgxPNH/UktSUJ /CtAipVpNhDWss8cxTM8wD9nSarGpkH8RRjHX+MX5ID9pKEz0AtOrbGxFD5OcFW72x QoCRp1XTBISxXF0s+oDYMZF6LmxK1aygn1ecLzoFztXYt4+2ERqi6gg3p4tv4H1DhN ZWAFlbJpccrZw== Date: Fri, 3 Nov 2023 17:09:28 +0000 From: Simon Horman To: Ivan Vecera Cc: netdev@vger.kernel.org, Jesse Brandeburg , Tony Nguyen , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , intel-wired-lan@lists.osuosl.org, linux-kernel@vger.kernel.org, Jacob Keller , Wojciech Drewek Subject: Re: [PATCH iwl-next] iavf: Remove queue tracking fields from iavf_adminq_ring Message-ID: <20231103170928.GD714036@kernel.org> References: <20231026083932.2623631-1-ivecera@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20231026083932.2623631-1-ivecera@redhat.com> X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF, RCVD_IN_DNSWL_BLOCKED,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net 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 (snail.vger.email [0.0.0.0]); Fri, 03 Nov 2023 10:09:38 -0700 (PDT) On Thu, Oct 26, 2023 at 10:39:32AM +0200, Ivan Vecera wrote: > Fields 'head', 'tail', 'len', 'bah' and 'bal' in iavf_adminq_ring > are used to store register offsets. These offsets are initialized > and remains constant so there is no need to store them in the > iavf_adminq_ring structure. > > Remove these fields from iavf_adminq_ring and use register offset > constants instead. Remove iavf_adminq_init_regs() that originally > stores these constants into these fields. > > Finally improve iavf_check_asq_alive() that assumes that > non-zero value of hw->aq.asq.len indicates fully initialized > AdminQ send queue. Replace it by check for non-zero value > of field hw->aq.asq.count that is non-zero when the sending > queue is initialized and is zeroed during shutdown of > the queue. > > Signed-off-by: Ivan Vecera Thanks, this is a nice cleanup. Reviewed-by: Simon Horman ...