linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Andrew Morton <akpm@linux-foundation.org>
To: Dan Streetman <ddstreet@ieee.org>
Cc: Seth Jennings <sjennings@variantweb.net>,
	linux-mm@kvack.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH 3/3] zswap: change zpool/compressor at runtime
Date: Wed, 5 Aug 2015 13:14:06 -0700	[thread overview]
Message-ID: <20150805131406.8bd8a1a6d2a6691aa6eedd34@linux-foundation.org> (raw)
In-Reply-To: <1438782403-29496-4-git-send-email-ddstreet@ieee.org>

On Wed,  5 Aug 2015 09:46:43 -0400 Dan Streetman <ddstreet@ieee.org> wrote:

> Update the zpool and compressor parameters to be changeable at runtime.
> When changed, a new pool is created with the requested zpool/compressor,
> and added as the current pool at the front of the pool list.  Previous
> pools remain in the list only to remove existing compressed pages from.
> The old pool(s) are removed once they become empty.
> 
> +/*********************************
> +* param callbacks
> +**********************************/
> +
> +static int __zswap_param_set(const char *val, const struct kernel_param *kp,
> +			     char *type, char *compressor)
> +{
> +	struct zswap_pool *pool, *put_pool = NULL;
> +	char str[kp->str->maxlen], *s;

What's the upper bound on the size of this variable-sized array?

> +	int ret;
> +
> +	strlcpy(str, val, kp->str->maxlen);
> +	s = strim(str);
> +
> +	/* if this is load-time (pre-init) param setting,

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>

  reply	other threads:[~2015-08-05 20:14 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-08-05 13:46 [PATCH 0/3] make zswap params changeable " Dan Streetman
2015-08-05 13:46 ` [PATCH 1/3] zpool: add zpool_has_pool() Dan Streetman
2015-08-05 20:08   ` Andrew Morton
2015-08-05 22:00     ` Dan Streetman
2015-08-05 22:06       ` Andrew Morton
2015-08-06 21:50         ` Seth Jennings
2015-08-07  3:30           ` Seth Jennings
2015-08-14 20:01         ` Dan Streetman
2015-08-06 17:54       ` [PATCH] zpool: clarification comment for zpool_has_pool Dan Streetman
2015-08-05 13:46 ` [PATCH 2/3] zswap: dynamic pool creation Dan Streetman
2015-08-07  6:30   ` Sergey Senozhatsky
2015-08-07 14:24     ` Dan Streetman
2015-08-07 18:57       ` Dan Streetman
2015-08-10  0:49       ` Sergey Senozhatsky
2015-08-14 20:02         ` Dan Streetman
2015-08-05 13:46 ` [PATCH 3/3] zswap: change zpool/compressor at runtime Dan Streetman
2015-08-05 20:14   ` Andrew Morton [this message]
2015-08-06 10:06     ` Dan Streetman
2015-08-06 17:54       ` [PATCH] zswap: comment clarifying maxlen Dan Streetman
2015-08-06  0:08   ` [PATCH 3/3] zswap: change zpool/compressor at runtime Sergey Senozhatsky
2015-08-06 10:20     ` Dan Streetman
2015-08-06 10:59       ` Sergey Senozhatsky
2015-08-06 11:07         ` Dan Streetman

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=20150805131406.8bd8a1a6d2a6691aa6eedd34@linux-foundation.org \
    --to=akpm@linux-foundation.org \
    --cc=ddstreet@ieee.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=sjennings@variantweb.net \
    /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