All of lore.kernel.org
 help / color / mirror / Atom feed
From: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
To: Dan Magenheimer <dan.magenheimer@oracle.com>
Cc: jeremy@goop.org, xen-devel@lists.xensource.com,
	Ian Campbell <Ian.Campbell@citrix.com>,
	JBeulich@novell.com
Subject: Re: [PATCH v4] [linux-3.0+ for xen] tmem: self-ballooning and frontswap-selfshrinking
Date: Wed, 6 Jul 2011 09:42:30 -0400	[thread overview]
Message-ID: <20110706134230.GB4138@dumpdata.com> (raw)
In-Reply-To: <068f4a4e-45e1-4968-9419-5b2e2c0b661f@default>

On Tue, Jul 05, 2011 at 09:29:00AM -0700, Dan Magenheimer wrote:
> Hi Konrad (and other reviewers) --

Hey Dan,

Only got two comments.

> +static struct attribute *selfballoon_attrs[] = {
> +	&attr_selfballooning.attr,
> +	&attr_selfballoon_interval.attr,
> +	&attr_selfballoon_downhysteresis.attr,
> +	&attr_selfballoon_uphysteresis.attr,
> +#ifdef CONFIG_FRONTSWAP
> +	&attr_frontswap_selfshrinking.attr,
> +	&attr_frontswap_hysteresis.attr,
> +	&attr_frontswap_inertia.attr,
> +#endif

You are still missing the 'NULL' here.

> +};
> +
> +static struct attribute_group selfballoon_group = {
> +	.name = "selfballoon",
> +	.attrs = selfballoon_attrs
> +};
> +#endif
> +
> +int register_xen_selfballooning(struct sys_device *sysdev)
> +{
> +	int error = -1;
> +
> +#ifdef CONFIG_SYSFS
> +	error = sysfs_create_group(&sysdev->kobj, &selfballoon_group);
> +#endif
> +	return error;
> +}
> +EXPORT_SYMBOL(register_xen_selfballooning);
> +
> +static int __init noselfballooning_setup(char *s)
> +{
> +	use_selfballooning = false;
> +	return 1;
> +}
> +
> +__setup("noselfballooning", noselfballooning_setup);
> +
> +/*
> + * the default values for the various parameters were deemed reasonable
> + * by experimentation, may be workload-dependent, and can all be
> + * adjusted via sysfs
> + */
> +static int __init xen_selfballoon_init(void)
> +{
> +	if (!xen_domain())
> +		return -ENODEV;
> +
> +	pr_info("xen/balloon: Initializing Xen selfballooning driver.\n");
> +	xen_selfballooning_enabled = tmem_enabled && use_selfballooning;
> +	selfballoon_interval = 5;
> +	selfballoon_downhysteresis = 8;
> +	selfballoon_uphysteresis = 1;

I think those hysteris values can be set at the top of the file.

> +#ifdef CONFIG_FRONTSWAP
> +	pr_info("xen/balloon: Initializing frontswap selfshrinking driver.\n");
> +	frontswap_selfshrinking = use_frontswap_selfshrink && frontswap_enabled;
> +	frontswap_hysteresis = 20;
> +	frontswap_inertia = 3;

      reply	other threads:[~2011-07-06 13:42 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-07-05 16:29 [PATCH v4] [linux-3.0+ for xen] tmem: self-ballooning and frontswap-selfshrinking Dan Magenheimer
2011-07-06 13:42 ` Konrad Rzeszutek Wilk [this message]

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=20110706134230.GB4138@dumpdata.com \
    --to=konrad.wilk@oracle.com \
    --cc=Ian.Campbell@citrix.com \
    --cc=JBeulich@novell.com \
    --cc=dan.magenheimer@oracle.com \
    --cc=jeremy@goop.org \
    --cc=xen-devel@lists.xensource.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.