patch-2.4.21 linux-2.4.21/drivers/md/raid1.c
Next file: linux-2.4.21/drivers/md/raid5.c
Previous file: linux-2.4.21/drivers/md/raid0.c
Back to the patch index
Back to the overall index
- Lines: 24
- Date:
2003-06-13 07:51:34.000000000 -0700
- Orig file:
linux-2.4.20/drivers/md/raid1.c
- Orig date:
2002-11-28 15:53:13.000000000 -0800
diff -urN linux-2.4.20/drivers/md/raid1.c linux-2.4.21/drivers/md/raid1.c
@@ -719,18 +719,17 @@
return (0);
}
-static int raid1_status (char *page, mddev_t *mddev)
+static void raid1_status(struct seq_file *seq, mddev_t *mddev)
{
raid1_conf_t *conf = mddev_to_conf(mddev);
- int sz = 0, i;
+ int i;
- sz += sprintf (page+sz, " [%d/%d] [", conf->raid_disks,
+ seq_printf(seq, " [%d/%d] [", conf->raid_disks,
conf->working_disks);
for (i = 0; i < conf->raid_disks; i++)
- sz += sprintf (page+sz, "%s",
+ seq_printf(seq, "%s",
conf->mirrors[i].operational ? "U" : "_");
- sz += sprintf (page+sz, "]");
- return sz;
+ seq_printf(seq, "]");
}
#define LAST_DISK KERN_ALERT \
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)