From: Chris Webb <chris@arachsys.com>
To: linux-bcachefs@vger.kernel.org
Subject: Re: [PATCH 2/2] bcachefs-tools: Avoid glibc-specific mallinfo() in shrinker
Date: Sat, 9 Dec 2023 13:10:38 +0000 [thread overview]
Message-ID: <A8210FBA-2AFF-4ADE-87AF-654A0AFB48A7@arachsys.com> (raw)
In-Reply-To: <a954a56e0923e067d646f584fc3838bdeae9e2d7.1702125906.git.chris@arachsys.com>
Chris Webb <chris@arachsys.com> wrote:
> + /* Aim for 6% of physical RAM free without anything in swap */
> + want_shrink = (info.totalram << 4) - info.freeram
> + + info.totalswap - info.freeswap;
> + if (want_shrink <= 0)
> + return;
(info.totalram >> 4) here, sorry, of course!
Best wishes,
Chris.
next prev parent reply other threads:[~2023-12-09 13:10 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-12-09 12:49 [PATCH 1/2] bcachefs-tools: Use sysinfo(2) directly to implement si_meminfo() Chris Webb
2023-12-09 12:50 ` [PATCH 2/2] bcachefs-tools: Avoid glibc-specific mallinfo() in shrinker Chris Webb
2023-12-09 13:10 ` Chris Webb [this message]
2023-12-10 4:28 ` Kent Overstreet
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=A8210FBA-2AFF-4ADE-87AF-654A0AFB48A7@arachsys.com \
--to=chris@arachsys.com \
--cc=linux-bcachefs@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox