Received: by 2002:a25:31c3:0:0:0:0:0 with SMTP id x186csp3199247ybx; Fri, 8 Nov 2019 15:43:30 -0800 (PST) X-Google-Smtp-Source: APXvYqyzd69x4VDS7TMYCc+Ax/O0934G6gCg1+1OEdi7djbY8hMYGo+OuxMAbUcb+9C3lFF6IERk X-Received: by 2002:a05:6402:339:: with SMTP id q25mr13722209edw.80.1573256610193; Fri, 08 Nov 2019 15:43:30 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1573256610; cv=none; d=google.com; s=arc-20160816; b=JWkE/qSKiSgTukRuTQX+PxKT6S9Hw0WkA5y9X1GH+2YDqC/fYmUFwLnWCnmMO4qOF8 1KNR9s1DFQ1FRpC8dL6hw6ZL5RJGs8ifGMuivTKveaK2++HEaVsO8iwidhjpO+fUbQ/A 5D1GVS/65AVUIrPjrq/njNimMCAstx8DooZ2mlFFTNrPHvu3KqeHJAlAVqIYvSgiUNxY GLX9ubUbNmNuQwXRvNz9DjuGON13fC2G+MHS2LKa3I/iUOzmjEX4Q3Bgbp2slTjSxu/a 2TXuIHX0WgDrkERPV2TRWEpbWSH1OjeUmxyKO2fZOqSvw/QZ3Luthx4xN0jkoQMsJMN/ 3T3w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:reply-to:message-id :subject:cc:to:from:date:dkim-signature; bh=aYBaJ3XBr6G8NmlhLIVwlgAwYnpbTXhUmsIWg1id1+E=; b=zTri+LuDA0kAEpHJlpF2fq4VDCSKZT2BukY/UijywN6/8+LR+Etoe+wzeOqYnxcUDR OqEaFFLjLOxQluolriB1YKTEBJ7jUmpwxzGmU21i+KSH3s3y0JojDOZ31spXxIQRILGq LIR6e/J2/72hD4Ns3THrCkZxaJkKeWIojLlVb0Cjm8XwatoUhJlRRH/xnaiXbwI+LK90 UwRuVRhkhhhbuFBTbVSHxTlfFm8dTp2NFmn9s0TyslQhboG+L7dNlgYA92l6eHlIpYye VAk1rAe43IQEV7A/WtXDgggvprTwQ3Ml2Ro+J+hJW7UtNDCUVhbNoj2xXhrFRnDfPgAK guZw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=ZfsypRI+; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 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 vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id t26si5484523edc.102.2019.11.08.15.43.06; Fri, 08 Nov 2019 15:43:30 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=ZfsypRI+; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727559AbfKHXm2 (ORCPT + 99 others); Fri, 8 Nov 2019 18:42:28 -0500 Received: from mail.kernel.org ([198.145.29.99]:36278 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726394AbfKHXm1 (ORCPT ); Fri, 8 Nov 2019 18:42:27 -0500 Received: from paulmck-ThinkPad-P72.home (unknown [193.120.164.244]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id DE1C0207FA; Fri, 8 Nov 2019 23:42:26 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1573256547; bh=njd2BrNS+CzqOGrTNd0P/SZn4caSso1i9s77K2rtDlM=; h=Date:From:To:Cc:Subject:Reply-To:References:In-Reply-To:From; b=ZfsypRI+tdJF9WNRVlFaZeKwDUwJ1rHBPopMKn94YcPfzYc59892vSEPLYoDAF2YF h7CTnROlSogdw8odeUevtUempX7ghDinliYP/d43cw7zJ4dXhx9p/KnBzHy7jyZkiP esgvK6ID0tTmEkbM3NSVs/hAcXscUvdc2d1rqESk= Received: by paulmck-ThinkPad-P72.home (Postfix, from userid 1000) id 0512F3520B54; Fri, 8 Nov 2019 15:42:25 -0800 (PST) Date: Fri, 8 Nov 2019 15:42:24 -0800 From: "Paul E. McKenney" To: Eric Dumazet Cc: Thomas Gleixner , linux-kernel , Eric Dumazet Subject: Re: [PATCH 1/2] list: add hlist_unhashed_lockless() Message-ID: <20191108234224.GF20975@paulmck-ThinkPad-P72> Reply-To: paulmck@kernel.org References: <20191107193738.195914-1-edumazet@google.com> <20191108192448.GB20975@paulmck-ThinkPad-P72> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.9.4 (2018-02-28) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Nov 08, 2019 at 12:17:49PM -0800, Eric Dumazet wrote: > On Fri, Nov 8, 2019 at 11:24 AM Paul E. McKenney wrote: > > > > On Thu, Nov 07, 2019 at 11:37:37AM -0800, Eric Dumazet wrote: > > > We would like to use hlist_unhashed() from timer_pending(), > > > which runs without protection of a lock. > > > > > > Note that other callers might also want to use this variant. > > > > > > Instead of forcing a READ_ONCE() for all hlist_unhashed() > > > callers, add a new helper with an explicit _lockless suffix > > > in the name to better document what is going on. > > > > > > Also add various WRITE_ONCE() in __hlist_del(), hlist_add_head() > > > and hlist_add_before()/hlist_add_behind() to pair with > > > the READ_ONCE(). > > > > > > Signed-off-by: Eric Dumazet > > > Cc: "Paul E. McKenney" > > > Cc: Thomas Gleixner > > > > I have queued this, but if you prefer it go some other way: > > > > Acked-by: Paul E. McKenney > > > > But shouldn't the uses in include/linux/rculist.h also be converted > > into the patch below? If so, I will squash the following into your > > patch. > > > > Thanx, Paul > > > > ------------------------------------------------------------------------ > > Agreed, thanks for the addition of this Paul. Very good, squashed and pushed, thank you! Thanx, Paul