Received: by 2002:a05:6a10:7420:0:0:0:0 with SMTP id hk32csp4413478pxb; Mon, 21 Feb 2022 20:49:11 -0800 (PST) X-Google-Smtp-Source: ABdhPJylRjZ6xQ4N8g8OVQvXSTkgpmj5UTnQbUHwMb8zW5wQMYnejzcdyPGS5+wuyD18gAdAy5t6 X-Received: by 2002:a63:fe01:0:b0:372:b258:a8c9 with SMTP id p1-20020a63fe01000000b00372b258a8c9mr18490605pgh.376.1645505351385; Mon, 21 Feb 2022 20:49:11 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1645505351; cv=none; d=google.com; s=arc-20160816; b=1IQAhq8+qWN/zwxkBlQSlemafsW2PM9Ikj/lgzOqCrQEUC6cmL9hoyOXXZ4W6vQq8j 7xK4nJxdv/6fB3n0zCW06m/yyP1FxrpgIZmQbXOAlQBFnrVV54biN0wzgeL7GmVa8VmF TFpziveLACva/Aq24NtApdbpjdI3CJnK1NDX1G8E+F5POjMJwGMTwLNjz3XljMfhAmwo qMMTHrjdSrwBCsiNYVJjDADvQE1iNIol7PGUNHQ860fyM2UCl7PsV/w70iqq633LhSN5 NtRL/roQjtoIvqQFfhjhvz9noYBXMrXZVYTa0EqSqTSEM//+OpItokjznEujika5QA/4 52Bg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:cc:to:content-language:subject:user-agent:mime-version :date:message-id:dkim-signature; bh=iVU7c8UkMZo7uX8Y0ZB2Ieotxw1lKENHkT4ow3N2bJE=; b=cT9TlMqnI5L7RDrrKc8cqd8qZ8I4HRfbIOSeezIOKw8xISFIiIKqlohSdeZ0y/RDZe LCP4dBizpYgUSiutF5NG3Jf5w8SGuKbzn9BoiE7vjwEaMsdxMaCKsW/ygTuiBgz4YA3i VY2fDjKjZmxeiY/TRQF7xEyS3+QjBeXFu6SBCrQQoue5Swe1nUdMoCcFeADv6CfdYr4B 2QzLhSKiwkJvSZvkFXxqvc5/9g6d7NERHH60E0Uoq08pxEAsu/7BJNNrEyXpqy33oojT IWta8GE4L7Jk13J5oxQitWh0H/BjPOTOmPRhLyH1ZAmzNrDsPwRVSztSXDwkcSUFEgaN Ihtw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=ONDKZguD; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 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 lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [2620:137:e000::1:18]) by mx.google.com with ESMTPS id h12si11521217pfi.180.2022.02.21.20.49.10 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 21 Feb 2022 20:49:11 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) client-ip=2620:137:e000::1:18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=ONDKZguD; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 9634789CFA; Mon, 21 Feb 2022 20:30:12 -0800 (PST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233113AbiBVDDC (ORCPT + 99 others); Mon, 21 Feb 2022 22:03:02 -0500 Received: from mxb-00190b01.gslb.pphosted.com ([23.128.96.19]:36944 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230357AbiBVDDC (ORCPT ); Mon, 21 Feb 2022 22:03:02 -0500 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E574125E82; Mon, 21 Feb 2022 19:02:37 -0800 (PST) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 0B70961508; Tue, 22 Feb 2022 03:02:37 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 3DC4FC340E9; Tue, 22 Feb 2022 03:02:36 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1645498956; bh=i2JV150Bxh2CDePbvSFpRNI2nyIamIuh4TPThhKNDmE=; h=Date:Subject:To:Cc:References:From:In-Reply-To:From; b=ONDKZguDyvUS6Ba+JucYYfxZx4RZ9ps9BEFXdykSkENakEiKWXZArov/4HbVlixmD ibKENzo1Ku97jTfG37/v1druN4vUya3Kg/MzM0MOgdnN6Ycsucnm9v4ZWtWKOgW1bC 2L/UE+EooG7R0Uw6xi78i+d4YWqbe4tZlAgsYnQdHFef49nCkrOc7Q3/FQ5qITn5q3 bSThToYVt1qP3Y9TeLtJVwkIeKwbFhd6y6NL3H8mPSdT0CAGjAIqotyKWnxLOFSpvc DCjrGvLhESqTXEZSU25T1t0S4ZchEI3NKqLhHRN381OiqoEA6Rtx6cwtGvCP5AXaou WuBMWe24YSMpw== Message-ID: Date: Mon, 21 Feb 2022 20:02:35 -0700 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:91.0) Gecko/20100101 Thunderbird/91.6.0 Subject: Re: [PATCH] ipv6: prevent a possible race condition with lifetimes Content-Language: en-US To: Niels Dossche , "David S. Miller" , Hideaki YOSHIFUJI Cc: netdev@vger.kernel.org, linux-kernel@vger.kernel.org References: <5599cc3b-8925-4cfd-f035-ae3b87e821a3@ugent.be> From: David Ahern In-Reply-To: <5599cc3b-8925-4cfd-f035-ae3b87e821a3@ugent.be> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-2.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,MAILING_LIST_MULTI, NICE_REPLY_A,RDNS_NONE,SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE autolearn=unavailable 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 On 2/20/22 10:54 AM, Niels Dossche wrote: > valid_lft, prefered_lft and tstamp are always accessed under the lock > "lock" in other places. Reading these without taking the lock may result > in inconsistencies regarding the calculation of the valid and preferred > variables since decisions are taken on these fields for those variables. > > Signed-off-by: Niels Dossche > --- > net/ipv6/addrconf.c | 2 ++ > 1 file changed, 2 insertions(+) > Reviewed-by: David Ahern