Received: by 2002:a5b:505:0:0:0:0:0 with SMTP id o5csp4745676ybp; Mon, 14 Oct 2019 09:22:04 -0700 (PDT) X-Google-Smtp-Source: APXvYqx3cn1eWmc3x0EOwHY7ZNqv6UIxZcYq82YSHlI5yWxXN2EYHMC55eo1qwr8nlD0MCWWYFQI X-Received: by 2002:aa7:d888:: with SMTP id u8mr28164567edq.144.1571070124626; Mon, 14 Oct 2019 09:22:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1571070124; cv=none; d=google.com; s=arc-20160816; b=uQ2zyA0esIStwfUXv6hHIBGK2tb8cqxgSRIjfpvNuqDQqUMc2q6zgOCDzmEuedaeGV VKf2Y+tNh7SXtNHtK1cXh2D+a0sygbwam8gfw9Lr5x/YoPvgnvL69dJnKIq5EbWrQBow bnNTKJ94Zm3eWXKJFPFCeebcErDgAcU8udIfBf0WOjcJHJ1F9PrJEN+vxL2D/tDPwN6q tIgxaihSYSy7mF+VMdWu9EHRD0aneehI03qlCDIY2KfDK+pKr72WcAYtrVawJ4DoR5Lj RM+eiZe//H24PSPDHuGaJNwHeNE9LAGZ/ZJDzSq3N462Qe47CTJaOgMlaq44+H9shRHP jQzA== 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:message-id:subject:cc :to:from:date:dkim-signature; bh=BUs6ww2wp2HkRKO5Ig1yFUSfYWRm/mJFXsejJnbtOqs=; b=gYoqGTkkTftTNv4DEfb6Weav0ATzde6K2VxvJCgKlTcJVlIgTY1BDzgdLXpeonrNzb YE4WCRYZPs/Uo76fVbpvjclOcmi2j+oIWpLdzsVwjrpqzHIcofqkdDPxlxsS1n5px+3f qa8KRE9QqIf3pxO79la2mlfDMOG2Kk3xP9TIRJGv03Nr7nOcQZb/T9BU3jGY2bWZ1Q8H IqPkp4kL8xxNpe9xG2x26JkvyECUi+QOlTicRdWPp7kl4pAD6XqxKCNPIqNNht4kiha4 Snax7U2vjj9eXOs9zZHL5GwZepDXGisef7BPlux+sMGelazsW8XZt4z9gtohnDGtPFl+ rDgQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@gmail.com header.s=20161025 header.b=oQOzhgiL; 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=fail (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 i23si11371456edr.191.2019.10.14.09.21.40; Mon, 14 Oct 2019 09:22:04 -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=fail header.i=@gmail.com header.s=20161025 header.b=oQOzhgiL; 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=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731551AbfJNPll (ORCPT + 99 others); Mon, 14 Oct 2019 11:41:41 -0400 Received: from mail-qk1-f196.google.com ([209.85.222.196]:36800 "EHLO mail-qk1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731457AbfJNPlk (ORCPT ); Mon, 14 Oct 2019 11:41:40 -0400 Received: by mail-qk1-f196.google.com with SMTP id y189so16290892qkc.3; Mon, 14 Oct 2019 08:41:39 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=BUs6ww2wp2HkRKO5Ig1yFUSfYWRm/mJFXsejJnbtOqs=; b=oQOzhgiLemf2MFAncmQNwr1h9wmPYZjB9Mhg6CjWxiGAzLmQaUUeRd3rfj1VMVUgXB T/o3WuHsOpozELcayBmb+2CMX2fA22LFOds2rvcs7WSjLFP2WyZn5MlPTOwV0zJEUGk/ 0AH3sWGN4COj6efHDv2YZyJZGaaUl/5jK7q8NriAucA/qduGE/SI5d3R8Kq47J5m2EXo AP2tAQNe4qD4gD8HfxptPoFq51uauD9hmaTSpJmi6PdyFi/oYoXjibGgvoME/Pzo/d3Y 7pv6CwmKL8neIiyMfpoFvvqHNK7ArxkXw1SmJyNxDEi5/K0k6Cd9X3hcnMsDpkSu1bUO /G1A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:date:from:to:cc:subject:message-id :references:mime-version:content-disposition:in-reply-to:user-agent; bh=BUs6ww2wp2HkRKO5Ig1yFUSfYWRm/mJFXsejJnbtOqs=; b=G4AAw2jhzNI4PL0K2aVdIemeTkbuKlVHFnWUEvUcTnxF15VOcfOVu61KrSotSFV6kf p3FOrqX+uPG9a9emycij6j50iCG5q5+GpawRoSXhnos9ISzyZxnJhhNKYsSJa/2OSDPJ WKOkiKjwzhSdGqvBTkv/mxI5a1rkMS20zhoSP/DdpcIw37hEMrp6BIBbL6G0+d2MG9+w joj6B688sUo7eOd99dSii3q4u83Qiyl0M7XkFFnnNEGrcWyGjnnKjOUNj8slPWkbhWVf G7MVLeBYVJHvUhUnrb1vAbOHjjcd0orzdhKBI39khT8x1+XjIcWwwllfQwuv9yZU3ymo dFBg== X-Gm-Message-State: APjAAAWLnftbc/ZoibBYV/Xnr8m97g4EgbUEG/B+618L8bmFCUfcW+zX lw5omnY2eYAJCwhG6WSXvlQ= X-Received: by 2002:a05:620a:887:: with SMTP id b7mr27937691qka.186.1571067698911; Mon, 14 Oct 2019 08:41:38 -0700 (PDT) Received: from localhost ([2620:10d:c091:500::1:50c5]) by smtp.gmail.com with ESMTPSA id c20sm7453462qkm.11.2019.10.14.08.41.38 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 14 Oct 2019 08:41:38 -0700 (PDT) Date: Mon, 14 Oct 2019 08:41:36 -0700 From: Tejun Heo To: Aleksa Sarai Cc: Li Zefan , Johannes Weiner , cgroups@vger.kernel.org, linux-kernel@vger.kernel.org, stable@vger.kernel.org Subject: Re: [PATCH] cgroup: pids: use {READ,WRITE}_ONCE for pids->limit operations Message-ID: <20191014154136.GF18794@devbig004.ftw2.facebook.com> References: <20191012010539.6131-1-cyphar@cyphar.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20191012010539.6131-1-cyphar@cyphar.com> User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sat, Oct 12, 2019 at 12:05:39PM +1100, Aleksa Sarai wrote: > Because pids->limit can be changed concurrently (but we don't want to > take a lock because it would be needlessly expensive), use the > appropriate memory barriers. I can't quite tell what problem it's fixing. Can you elaborate a scenario where the current code would break that your patch fixes? Thanks. -- tejun