lkml.org 
[lkml]   [2002]   [Jan]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
SubjectPatch: linux-2.5.2-pre8/drivers/md/raid1.c kdev_t compilation fixes
	kdev_t compilation fixes for linux-2.5.2-pre8/drivers/md/raid1.c.
I have not tested it beyond seeing that it compiles.

--
Adam J. Richter __ ______________ 4880 Stevens Creek Blvd, Suite 104
adam@yggdrasil.com \ / San Jose, California 95129-1034
+1 408 261-6630 | g g d r a s i l United States of America
fax +1 408 261-6631 "Free Software For The Rest Of Us."
--- linux-2.5.2-pre8/drivers/md/raid1.c Fri Jan 4 19:40:37 2002
+++ linux/drivers/md/raid1.c Sat Jan 5 00:10:46 2002
@@ -611,7 +611,7 @@
* else mark the drive as failed
*/
for (i = 0; i < disks; i++)
- if (mirrors[i].dev == dev && mirrors[i].operational)
+ if (kdev_same(mirrors[i].dev, dev) && mirrors[i].operational)
break;
if (i == disks)
return 0;
@@ -853,7 +853,7 @@

*d = failed_desc;

- if (sdisk->dev == MKDEV(0,0))
+ if (kdev_none(sdisk->dev))
sdisk->used_slot = 0;
/*
* this really activates the spare.
@@ -879,7 +879,7 @@
err = 1;
goto abort;
}
- rdisk->dev = MKDEV(0,0);
+ rdisk->dev = mk_kdev(0,0);
rdisk->used_slot = 0;
conf->nr_disks--;
break;
@@ -896,7 +896,7 @@

adisk->number = added_desc->number;
adisk->raid_disk = added_desc->raid_disk;
- adisk->dev = MKDEV(added_desc->major, added_desc->minor);
+ adisk->dev = mk_kdev(added_desc->major, added_desc->minor);

adisk->operational = 0;
adisk->write_only = 0;
@@ -1098,7 +1098,7 @@
case READA:
dev = bio->bi_dev;
map(mddev, &bio->bi_dev);
- if (bio->bi_dev == dev) {
+ if (kdev_same(bio->bi_dev, dev)) {
printk(IO_ERROR, partition_name(bio->bi_dev), r1_bio->sector);
raid_end_bio_io(r1_bio, 0, 0);
break;
@@ -1428,7 +1428,7 @@

disk->number = descriptor->number;
disk->raid_disk = disk_idx;
- disk->dev = MKDEV(0,0);
+ disk->dev = mk_kdev(0,0);

disk->operational = 0;
disk->write_only = 0;
\
 
 \ /
  Last update: 2005-03-22 13:15    [W:0.048 / U:12.528 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site