mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Andrew Morton <akpm@osdl.org>
To: Neil Horman <nhorman@tuxdriver.com>
Cc: linux-kernel@vger.kernel.org, joe.korty@ccur.com
Subject: Re: [PATCH] proc: fix duplicate line in /proc/devices
Date: Wed, 22 Mar 2006 11:12:31 -0800	[thread overview]
Message-ID: <20060322111231.779efd38.akpm@osdl.org> (raw)
In-Reply-To: <20060322132558.GB29565@hmsreliant.homelinux.net>

Neil Horman <nhorman@tuxdriver.com> wrote:
>
> Patch to fix a potential duplicate block device line printed after the "Block
> device" header in /proc/devices.  Tested and confirmed working by the reporter.
> 

<looks>

Block devices:
  1 ramdisk
  1 ramdisk
  2 fd
  8 sd

> 
> diff --git a/fs/proc/proc_misc.c b/fs/proc/proc_misc.c
> index 1d24fea..b097958 100644
> --- a/fs/proc/proc_misc.c
> +++ b/fs/proc/proc_misc.c
> @@ -312,7 +312,6 @@ static void *devinfo_next(struct seq_fil
>  		case BLK_HDR:
>  			info->state = BLK_LIST;
>  			(*pos)++;
> -			break;
>  		case BLK_LIST:
>  			if (get_blkdev_info(info->blkdev,&idummy,&ndummy)) {
>  				/*

OK, so that's the same as CHR_HDR and lines up with the fallthroughs in
devinfo_show().  A somewhat strange way of implementing a state machine,
but I guess it saves a few cycles...

I'll copy the stable-kernel guys - this is 2.6.16.1 material, thanks.

  reply	other threads:[~2006-03-22 19:16 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-03-22 13:25 Neil Horman
2006-03-22 19:12 ` Andrew Morton [this message]
2006-03-22 19:22   ` Neil Horman

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=20060322111231.779efd38.akpm@osdl.org \
    --to=akpm@osdl.org \
    --cc=joe.korty@ccur.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=nhorman@tuxdriver.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

all inboxes | Powered by JetHome®