public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Jan Kara <jack@suse.cz>
To: Namhyung Kim <namhyung@gmail.com>
Cc: Andrew Morton <akpm@linux-foundation.org>,
	Jan Kara <jack@suse.cz>,
	linux-ext4@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] jbd: Use printk_ratelimit() in journal_alloc_journal_head()
Date: Mon, 4 Oct 2010 11:43:32 +0200	[thread overview]
Message-ID: <20101004094331.GC3589@quack.suse.cz> (raw)
In-Reply-To: <1286183834-10548-1-git-send-email-namhyung@gmail.com>

On Mon 04-10-10 18:17:14, Namhyung Kim wrote:
>  #ifdef CONFIG_JBD_DEBUG
>  	atomic_inc(&nr_journal_heads);
> @@ -1726,11 +1725,10 @@ static struct journal_head *journal_alloc_journal_head(void)
>  	ret = kmem_cache_alloc(journal_head_cache, GFP_NOFS);
>  	if (ret == NULL) {
>  		jbd_debug(1, "out of memory for journal_head\n");
> -		if (time_after(jiffies, last_warning + 5*HZ)) {
> +		if (printk_ratelimit())
>  			printk(KERN_NOTICE "ENOMEM in %s, retrying.\n",
>  			       __func__);
> -			last_warning = jiffies;
> -		}
> +
  OK, but can we convert this directly to printk_ratelimited please?
Thanks.

								Honza

-- 
Jan Kara <jack@suse.cz>
SUSE Labs, CR

  reply	other threads:[~2010-10-04  9:44 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-10-04  9:17 [PATCH] jbd: Use printk_ratelimit() in journal_alloc_journal_head() Namhyung Kim
2010-10-04  9:43 ` Jan Kara [this message]
2010-10-04 10:12   ` [PATCH UPDATED] jbd: Use printk_ratelimited() " Namhyung Kim
2010-10-04 10:31     ` Jan Kara
2010-10-04 11:37       ` Jan Kara
2010-10-04 12:20         ` Namhyung Kim

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=20101004094331.GC3589@quack.suse.cz \
    --to=jack@suse.cz \
    --cc=akpm@linux-foundation.org \
    --cc=linux-ext4@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=namhyung@gmail.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox