From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 3EA6A1549E for ; Thu, 17 Aug 2023 16:22:30 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 6BB6FC433C9; Thu, 17 Aug 2023 16:22:30 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1692289350; bh=BiHl3deEBRiifvhk1+E9nkSfJCf9Bl2uVTRZ861Ta1o=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=c9KCm0cwB3Yp3ckGxZ2XKyj5dWCLe178Td3z3NU0QNOs0A+jcj/dfvPaTldEN8xGq fjYM9gpELm2wDLl3ZaxuUL36ZrVxz1vwF/thx2XfqjYOQTkqbrUQ4F+9S6bxLfVCcb h2H4vVRyx+KjFgpHh5arf7hVI5udR6ivsrm/m1SPQxEW5M/KTuFMIM3sBx4ORy1Wxq +naqg/v4L9A/A2Ibo6bIkKROIlGv8SK9apcYXRSMYCHI8/Bnwduy4lY7Ao1eMZI9Z8 hdX7m8ctXE7tHU+WNDoV2or4ISiDsiJbMK/5JUoKSQOII6o+r/xURj9YHIHrwe++YC A1mbSc9jy5isA== Date: Thu, 17 Aug 2023 09:22:29 -0700 From: Jakub Kicinski To: Simon Horman Cc: netdev@vger.kernel.org, hawk@kernel.org, ilias.apalodimas@linaro.org, aleksander.lobakin@intel.com, linyunsheng@huawei.com, almasrymina@google.com Subject: Re: [RFC net-next 05/13] net: page_pool: record pools per netdev Message-ID: <20230817092229.4cea4e2a@kernel.org> In-Reply-To: References: <20230816234303.3786178-1-kuba@kernel.org> <20230816234303.3786178-6-kuba@kernel.org> Precedence: bulk X-Mailing-List: netdev@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit On Thu, 17 Aug 2023 09:26:09 +0200 Simon Horman wrote: > I'm not sure if it is possible, but if the hlist loop above iterates zero > times then last will be uninitialised here. > > Flagged by Smatch. Hm, the caller checks if the list is empty but there may be a race condition since we don't hold the lock, yet. Thanks for flagging!