All of lore.kernel.org
 help / color / mirror / Atom feed
From: Borsenkow Andrej <Andrej.Borsenkow@mow.siemens.ru>
To: linux-kernel list <linux-kernel@vger.kernel.org>
Cc: Juan Quintela <quintela@mandrakesoft.com>,
	Cooker list <cooker@linux-mandrake.com>
Subject: BUG: pdcraid OOPS due to uninitialized variable access
Date: 14 Jul 2002 21:34:40 +0400	[thread overview]
Message-ID: <1026668086.3181.3.camel@localhost.localdomain> (raw)

On both 2.4.18-6mdk (from 8.2) and in current cooker pdcraid oopses
immediately after insertion. The reason is usage of uninitialized
variable in drivers/ide/pdcraid.c:


static void __init probedisk(int devindex,int device, int raidlevel)
{
        int i;
        int major, minor;
        struct promise_raid_conf *prom;
        static unsigned char block[4096];
        struct block_device *bdev;

        if (devlist[devindex].device!=-1) /* already assigned to another
array
*/
                return;
        if (strcmp("Promise Technology, Inc.",prom->promise_id))
                return; /* magic number must match */
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

here it bails out. prom is initialized later:

       major = devlist[devindex].major;
        minor = devlist[devindex].minor;

        if (read_disk_sb(major,minor,(unsigned
char*)&block,sizeof(block)))
                return;


        prom = (struct promise_raid_conf*)&block[512];

I am sorry, I do not have vanilla kernel so I cannot check if bug is in
general kernel or Mandrake-specific.

-andrej


             reply	other threads:[~2002-07-14 17:31 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-07-14 17:34 Borsenkow Andrej [this message]
2002-07-14 23:11 ` BUG: pdcraid OOPS due to uninitialized variable access Alan Cox

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=1026668086.3181.3.camel@localhost.localdomain \
    --to=andrej.borsenkow@mow.siemens.ru \
    --cc=cooker@linux-mandrake.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=quintela@mandrakesoft.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.