lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Thu, 18 Oct 2007 15:58:24 +0400
From:	Sergei Shtylyov <sshtylyov@...mvista.com>
To:	Sergei Shtylyov <sshtylyov@...mvista.com>
Cc:	Benjamin Herrenschmidt <benh@...nel.crashing.org>,
	Bartlomiej Zolnierkiewicz <bzolnier@...il.com>,
	Linux IDE <linux-ide@...r.kernel.org>,
	linux-kernel@...r.kernel.org, Andrew Morton <akpm@...l.org>
Subject: Re: [PATCH 0/3] ide: Fix use of paired device

Hello, I wrote:

>> At least 2 drivers (siimage and cs5535) have a bug where they use
>> the construct:

>>     ide_drive_t *pair    = &hwif->drives[drive->dn ^ 1];

>> To access the other drive in a master/slave pair. This is bogus
>> because drive->dn is not the unit number, but the global drive
>> number, thus can be 2 & 3 for ide1, 4 & 5 for ide2 etc...

>    Huh? With drive->dn calculated as:

>         for (unit = 0; unit < MAX_DRIVES; ++unit) {
>                 ide_drive_t *drive = &hwif->drives[unit];
>                 drive->dn = (hwif->channel ? 2 : 0) + unit;

> (with MAX_DRIVES always being 2) how comes it may be 4 or 5?!

>> Please apply to 2.6.24 if no objection.

>    I object. :-)

    Well, actually no objections about the patch itself since it deals with 
the cases of drive->dn being 2 and 3. But this probably be better to be done 
all in one patch, or at least in 2 patches (please also update driver version 
in the heading comment).

MBR, Sergei
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ