[PATCH] DM 4/6: Return table status for dev_wait

From: Kevin Corry
Date: Mon Sep 22 2003 - 10:55:10 EST


dev_wait was meant to return table status not dev status. [Alasdair Kergon]

--- diff/drivers/md/dm-ioctl-v4.c 2003-09-17 13:09:04.000000000 +0100
+++ source/drivers/md/dm-ioctl-v4.c 2003-09-17 13:09:26.000000000 +0100
@@ -769,6 +769,7 @@
{
int r;
struct mapped_device *md;
+ struct dm_table *table;
DECLARE_WAITQUEUE(wq, current);

md = find_device(param);
@@ -791,7 +792,16 @@
* him and save an ioctl.
*/
r = __dev_status(md, param);
+ if (r)
+ goto out;
+
+ table = dm_get_table(md);
+ if (table) {
+ retrieve_status(table, param, param_size);
+ dm_table_put(table);
+ }

+ out:
dm_put(md);
return r;
}

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