From owner-svn-src-stable@FreeBSD.ORG Wed Sep 17 16:46:24 2014 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id B8BEAE9D; Wed, 17 Sep 2014 16:46:24 +0000 (UTC) Received: from mail-la0-x230.google.com (mail-la0-x230.google.com [IPv6:2a00:1450:4010:c03::230]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 8098A813; Wed, 17 Sep 2014 16:46:23 +0000 (UTC) Received: by mail-la0-f48.google.com with SMTP id ty20so2282248lab.35 for ; Wed, 17 Sep 2014 09:46:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:message-id:date:from:user-agent:mime-version:to:subject :references:in-reply-to:content-type:content-transfer-encoding; bh=5XSDHv3lQGfj7sLr0fvxRNxmhKW5UmZjnCMQKWswf7Q=; b=lvtfH2wvgfp2vXY+W/7nDi6CmpXdkf+Y0nHaN6HYT3Fvfd2+YDFXDz2VeAXeIC3ort RegSZFwczDCxBqfHsngufZH2SsvRXq1yVq3XWBTKHkWaAmNAKQ9wnU4hu0S7L5R/4TvM vQWlyoossiVhtbKPStZxBnF9JxBlJhXzpghvzX53yhxEvv8iJscwOH6wrfbDVVKO7sO2 HWjb44wbDME91hkcAZaDcsWe6Rak2Q/0+gKy97G+xdk9mIgzVrP9oNhT2D24kqxsi8w7 GhqRhVJR4THWWDXvAyI9ScarGDjze4M46PyYo79ofIm3kgjLI4XRw7cuDHSlgwjTmvgL aRTw== X-Received: by 10.152.1.137 with SMTP id 9mr20617479lam.85.1410972381397; Wed, 17 Sep 2014 09:46:21 -0700 (PDT) Received: from mavbook.mavhome.dp.ua ([134.249.139.101]) by mx.google.com with ESMTPSA id ki7sm1828744lac.38.2014.09.17.09.46.18 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Wed, 17 Sep 2014 09:46:20 -0700 (PDT) Sender: Alexander Motin Message-ID: <5419BAD7.4000600@FreeBSD.org> Date: Wed, 17 Sep 2014 19:46:15 +0300 From: Alexander Motin User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:24.0) Gecko/20100101 Thunderbird/24.6.0 MIME-Version: 1.0 To: Andrey Chernov , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: Re: svn commit: r271707 - stable/10/sys/kern References: <201409171406.s8HE6LNu071461@svn.freebsd.org> <5419B3E1.1090703@freebsd.org> In-Reply-To: <5419B3E1.1090703@freebsd.org> X-Enigmail-Version: 1.6 Content-Type: text/plain; charset=KOI8-R Content-Transfer-Encoding: 7bit X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 17 Sep 2014 16:46:24 -0000 On 17.09.2014 19:16, Andrey Chernov wrote: > On 17.09.2014 18:06, Alexander Motin wrote: >> + /* >> + * Make sure that tdq_load updated before calling this function >> + * is globally visible before we read tdq_cpu_idle. Idle thread >> + * accesses both of them without locks, and the order is important. >> + */ >> + mb(); >> + >> if (TD_IS_IDLETHREAD(ctd)) { > > I don't understand this comment's first phrase with two verbs. Copy & > paste result? No, only possibly missing commas around "updated before calling this function". > I also don't see tdq_load access in this function. It is incremented by tdq_load_add(), called by tdq_add(), called by sched_add(), just before calling tdq_notify(). -- Alexander Motin