git://git.onelab.eu
/
linux-2.6.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
VServer 1.9.2 (patch-2.6.8.1-vs1.9.2.diff)
[linux-2.6.git]
/
drivers
/
md
/
dm-table.c
diff --git
a/drivers/md/dm-table.c
b/drivers/md/dm-table.c
index
14cabe5
..
d189f85
100644
(file)
--- a/
drivers/md/dm-table.c
+++ b/
drivers/md/dm-table.c
@@
-400,7
+400,7
@@
static int upgrade_mode(struct dm_dev *dd, int new_mode)
struct dm_dev dd_copy;
dev_t dev = dd->bdev->bd_dev;
struct dm_dev dd_copy;
dev_t dev = dd->bdev->bd_dev;
-
memcpy(&dd_copy, dd, sizeof(dd_copy))
;
+
dd_copy = *dd
;
dd->mode |= new_mode;
dd->bdev = NULL;
dd->mode |= new_mode;
dd->bdev = NULL;
@@
-408,7
+408,7
@@
static int upgrade_mode(struct dm_dev *dd, int new_mode)
if (!r)
close_dev(&dd_copy);
else
if (!r)
close_dev(&dd_copy);
else
-
memcpy(dd, &dd_copy, sizeof(dd_copy))
;
+
*dd = dd_copy
;
return r;
}
return r;
}