Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754540AbbEMRo1 (ORCPT ); Wed, 13 May 2015 13:44:27 -0400 Received: from mail-ig0-f182.google.com ([209.85.213.182]:33264 "EHLO mail-ig0-f182.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752393AbbEMRoY (ORCPT ); Wed, 13 May 2015 13:44:24 -0400 MIME-Version: 1.0 X-Originating-IP: [5.101.106.105] In-Reply-To: <20150513172906.GY11388@htj.duckdns.org> References: <1429446154-10660-1-git-send-email-cyphar@cyphar.com> <1429446154-10660-5-git-send-email-cyphar@cyphar.com> <20150422162954.GF10738@htj.duckdns.org> <20150424153657.GC24029@htj.duckdns.org> <20150513172906.GY11388@htj.duckdns.org> Date: Thu, 14 May 2015 03:44:24 +1000 Message-ID: Subject: Re: [PATCH v10 4/4] cgroups: implement the PIDs subsystem From: Aleksa Sarai To: Tejun Heo Cc: lizefan@huawei.com, mingo@redhat.com, Peter Zijlstra , richard@nod.at, =?UTF-8?B?RnLDqWTDqXJpYyBXZWlzYmVja2Vy?= , linux-kernel@vger.kernel.org, cgroups@vger.kernel.org Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 863 Lines: 28 >> Would you be okay with this? >> >> if (limit < 0 || limit >= PIDS_MAX) >> >> I'd prefer if we used PIDS_MAX as the maximum input value as well as >> being the internal representation of the maximum, rather than >> switching to something like INT_MAX. > > Yeah, that sounds okay to me but I forgot why we went for INT_MAX in > the first place. Do you remember why we tried INT_MAX at all? > > Thanks. > > -- > tejun I think it's because we didn't want to expose PIDS_MAX to userspace. But we're not *really* exposing it, we're just enforcing the input limit for "max". -- Aleksa Sarai (cyphar) www.cyphar.com -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/