Received: by 2002:ac0:a5a6:0:0:0:0:0 with SMTP id m35-v6csp1970988imm; Sun, 23 Sep 2018 16:34:16 -0700 (PDT) X-Google-Smtp-Source: ACcGV61RZhNh98fgKUTSlSo3kBrsUMl3MrJCUiXrvE+lcfPJbzkiYNcKL68a2b0U/mpWLgb0+jYB X-Received: by 2002:a63:ac56:: with SMTP id z22-v6mr7292193pgn.444.1537745655982; Sun, 23 Sep 2018 16:34:15 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1537745655; cv=none; d=google.com; s=arc-20160816; b=00Qp9y+fXETsmjTfOKW+kJ60iylfc8aKyIYpIGHn74Pa1CPPp0Z3sSHNFF1IVo7dJ2 HEHbLmkY8/7dwfN+jc1xnLaLkCmetO5UUhNAn5hgcJ+sxW0HDVGFkSKY1WaK43bs9NCx yHuYHFR8mRFoCTjWoh1cYlnJ0RhQw16509dpDoSf8gX3IBibNO1RC/Kf0H+K1o9WPna/ caLlDsXoE49LNAKAsyG9gDqTapXahBL/YQMRyoC3/F/o5aJpwvzssIzDZz5SRXwM6IqL GwJF898lsFNUTD6hQW3csZqAMMrGO5j7V0PrvhFybft9YOECIUl2UD/0KTdsr1FpGe4j +pzA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=HvLwHwM9hxFAdw/QrpKA/KQOe9dZ9N7qjDamXE+LX4k=; b=nvxpinWbZMwqE/4hz/oavEe/mQ/oZUHKyjB1+rMN5RwyuZg+u+jPvjvu/yoABunEbH +TrthSjLV9p5BIF+YORt0SMtPnhUJaB69k2+QnFZIyFLz4Hv/4eHO8wVQdaBtgXAVAlN IlqBA4pjSFv9lAXxIPdcncde7TdMRJYeRWNXTXzy26FpKfsC58GaVMsQ1y1oPKO4mIhJ 7BGLwPcSTHoAajpMkf4/hzjhd32Durn/m76w7cAHEnYshQl8nHiKd77qg0zKbSfmXtWx Qa5mvFE4EVuBlN0E6fK7aFSjWI7Hmm3J2VWsKWfisjj4HQF+icraOW/giEFp+IAMjOgn NIiw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@joelfernandes.org header.s=google header.b=PPalrHoC; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id l10-v6si2800288plt.440.2018.09.23.16.34.00; Sun, 23 Sep 2018 16:34:15 -0700 (PDT) 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=@joelfernandes.org header.s=google header.b=PPalrHoC; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727139AbeIXFbO (ORCPT + 99 others); Mon, 24 Sep 2018 01:31:14 -0400 Received: from mail-lj1-f177.google.com ([209.85.208.177]:40267 "EHLO mail-lj1-f177.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726520AbeIXFbO (ORCPT ); Mon, 24 Sep 2018 01:31:14 -0400 Received: by mail-lj1-f177.google.com with SMTP id j19-v6so16600311ljc.7 for ; Sun, 23 Sep 2018 16:31:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=joelfernandes.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=HvLwHwM9hxFAdw/QrpKA/KQOe9dZ9N7qjDamXE+LX4k=; b=PPalrHoCBlaqiifvig9/v523wKEp8++NEFNPW0WLL0Og0Rd2i6TKv2yU0r2oVot1p/ VcrOvf/Xp8mhA1WOZRnleL2w22jqirljAKSnLpvE8ZYgPkQnc0+vkXGDxV2kCZMK0mec ZFSoi6agFCbjne/f5JwBM9XWbUCSV7McC87sk= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=HvLwHwM9hxFAdw/QrpKA/KQOe9dZ9N7qjDamXE+LX4k=; b=WKHLpv6MTku4NwIE4k3o7hon07JtCEL8xLw1C71sWYQioLazyhaNKtZxCHo7uM6Zff eYIUPweqoNwmYRUwJY0VMWlq//qlVEBOd6XGsOx9h4fCvnb5wlmqoeVQV3m0y2g87s2/ ViFL5fk/b/oXgaZ3al9vspbnuqLnVf37yKgMxJGptWfLiMlTxPoTrQEZmquBOpowOK1B 5kq/6wBC6sPOxLIFMYxU2Wm0ACcCJvATdWV8ESzeEwnTkkgiu9JYdOnwkCvMELkT2Lut LslOPq06NEqdah0sCrTaeoRFG6hRuHdfTV8q9K4KqmD8cydgkakhDsM305OV5issb1VV Wx/g== X-Gm-Message-State: ABuFfoiPoPuBRHfyanNlT7e9kRNEmjeZkkziHEL7/+g1fJgk8YqDG1BW PPHrVW1cVHzKMZEGl8ERgtLswuZd5FTvKigU2TUaAQ== X-Received: by 2002:a2e:8098:: with SMTP id i24-v6mr8479507ljg.36.1537745509177; Sun, 23 Sep 2018 16:31:49 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: From: Joel Fernandes Date: Sun, 23 Sep 2018 19:31:37 -0400 Message-ID: Subject: Re: Question about ->head field of rcu_segcblist To: "Paul E. McKenney" Cc: LKML Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sun, Sep 23, 2018 at 7:30 PM Joel Fernandes wrote: > > Hi Paul, > > I was parsing the Data-Structures document and had a question about > the following "Important note" text. > > Could it be clarified in the below text better why "remaining > callbacks are placed back on the RCU_DONE_TAIL segment", is a reason > for not depending on ->head for determining if no callbacks are > associated with the rcu_segcblist? If callbacks are added back to the > DONE_TAIL segment, then I would think rcu_head should be != NULL. > Infact the "rsclp->head = *rsclp->tails[RCU_DONE_TAIL];" in > rcu_segcblist_extract_done_cbs should set the ->head to NULL if I > understand correctly. Just to clarify, I meant set to NULL assuming all cbs were done waiting and ready to be invoked.