From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.1 required=3.0 tests=DKIM_INVALID,DKIM_SIGNED, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS, USER_AGENT_SANE_1 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id B6AA9C4360C for ; Tue, 8 Oct 2019 20:14:22 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id 28316206C0 for ; Tue, 8 Oct 2019 20:14:22 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=garybgenett-net.20150623.gappssmtp.com header.i=@garybgenett-net.20150623.gappssmtp.com header.b="iIfS37Qe" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 28316206C0 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=garybgenett.net Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id B222E8E0006; Tue, 8 Oct 2019 16:14:21 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id AD3AB8E0003; Tue, 8 Oct 2019 16:14:21 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 9E8B48E0006; Tue, 8 Oct 2019 16:14:21 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0009.hostedemail.com [216.40.44.9]) by kanga.kvack.org (Postfix) with ESMTP id 7E2A18E0003 for ; Tue, 8 Oct 2019 16:14:21 -0400 (EDT) Received: from smtpin02.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay05.hostedemail.com (Postfix) with SMTP id 00A87181AC9B6 for ; Tue, 8 Oct 2019 20:14:20 +0000 (UTC) X-FDA: 76021719522.02.title72_601e6bfe70c1a X-HE-Tag: title72_601e6bfe70c1a X-Filterd-Recvd-Size: 4536 Received: from mail-pl1-f194.google.com (mail-pl1-f194.google.com [209.85.214.194]) by imf27.hostedemail.com (Postfix) with ESMTP for ; Tue, 8 Oct 2019 20:14:20 +0000 (UTC) Received: by mail-pl1-f194.google.com with SMTP id c3so7476938plo.2 for ; Tue, 08 Oct 2019 13:14:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=garybgenett-net.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:content-transfer-encoding:in-reply-to :user-agent; bh=O5uB4GttudeUw81hDmiI3zlS9X5bqZq39jfrwref+N4=; b=iIfS37QesZ8E54lkAbUAENoUB+2+qflRjbigkkyf3u4if5cPx4RIXNG78893TTMd7t hM20IHIssO8AC3iNkkbdhLSD876KIG+V/kTHVmjyNfML5DpNQe9NrUROLcQ/6M6y4GP2 0zH92Bz3DiaGc/9SZAlgyHTScEjrXMYKo5+Kl6lz64Frm171EFaad5utSlO2z019/Eut vB0at6hK/gEY+alsmzvZu+JXbKbPz+r44qcd7w7OzIIt0AQB97fdtgOj8I/47GbZUb6c cpkGy988mHc+sSGSg/PNMGWksEbVLzMouoLFBduLTF45qDo7nTQPoA45c009YXX2+M3d ewww== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:content-transfer-encoding :in-reply-to:user-agent; bh=O5uB4GttudeUw81hDmiI3zlS9X5bqZq39jfrwref+N4=; b=CZLgc8EURBdQ3jXF6wKwQeC908BGqpbWowS3v2dn84Y4mE0D5E6E9lYs0Q96eqxPMj J13sJGYuf+B4A+/KGXdVxMw3+MeNjpQOaofnYuirnN1+EX5sKoHRv54xwcPfqfHSciIZ UlMGBSDDf8rAre3Whm9zKdnqVeUAin1yON1LgBBfklmZDDiBIgbDyiwn39TdrOzhonvC 5RoTdcPU5S7ph69IMCpKe2SQ4JsUcnMF7Zo61S7zfgxsDWWQd0va8rJ4+oSJkI127EM+ BvttEVbphO6x8vjVAnhHvKOTBC6C7EEG79AF0ixwVPBk/Ne1DYP6RvtGcECHQXj+CPux D3dw== X-Gm-Message-State: APjAAAWO/Mhb2hOVbBm0dNAT28tRC2HpLDx1aJm0INJ9nDueLS5u4vO+ I4dU4yJGvDHJrmMv9KaFek+lBg== X-Google-Smtp-Source: APXvYqwg0xSc+0LbvhBXj/bylvFyLENndRyxDWXiaoDKOQIfUIAku+51/1EGMJNscZPYqepXXsUo6g== X-Received: by 2002:a17:902:a40a:: with SMTP id p10mr36898179plq.149.1570565658479; Tue, 08 Oct 2019 13:14:18 -0700 (PDT) Received: from spider ([71.212.141.220]) by smtp.gmail.com with ESMTPSA id 26sm42917pgz.70.2019.10.08.13.14.17 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 08 Oct 2019 13:14:17 -0700 (PDT) Date: Tue, 8 Oct 2019 13:14:15 -0700 From: -Gary- To: Qian Cai Cc: Hugh Dickins , linux-mm@kvack.org Subject: Re: [PATCH] shmem: add shmem_size option, set filesystem size Message-ID: <20191008201414.GC22291@spider> References: <20191008011532.GB22291@spider> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.10.1 (2018-07-13) Content-Transfer-Encoding: quoted-printable X-Bogosity: Ham, tests=bogofilter, spamicity=0.001084, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: > > At the least, it should be a "#define", or something. Right now it i= s a hard-coded magic token. > > I am not sure if it worth the complication. Right now, you have the cho= ice of resizing shmem like every body else or increasing your system memo= ry a bit. > > If there are more compiling reasons to bump the limit, it is probably m= ore appropriate to make it the default to use something like 75% memory i= f there isn=E2=80=99t much side-effect. Thank you again, Qian. I appreciate the conversation and coaching! That makes perfect sense. I agree with the effort to keep things tidy, e= fficient and supportable. With your blessing, I will submit a separate p= atch that only adds a configuration option to set the number of pages, an= d does not perform any additional math or steps other than reporting the = value. This will at least make it a defined value rather than a magic to= ken, and will allow any expert users who need it to change the value. I'm very reluctant, if not outright opposed, to changing the default, reg= ardless of how compelling the case. The possible side-effects of that ch= ange in behavior are unforeseen, and the scope of testing required is inf= easible. I sense that you agree with this. I hope my subsequent patch is low-impact enough to be accepted. It means a lot that you took the time to review and comment on my work. = I do greatly appreciate it. This was my first kernel patch submission, a= nd you made it a good experience. <^) -- Gary