Commit 372994e9 authored by NeilBrown's avatar NeilBrown Committed by Greg Kroah-Hartman

md/linear: avoid corrupting structure while waiting for rcu_free to complete.

commit 1b6afa17 upstream.

I don't know what I was thinking putting 'rcu' after a dynamically
sized array!  The array could still be in use when we call rcu_free()
(That is the point) so we mustn't corrupt it.
Signed-off-by: default avatarNeilBrown <neilb@suse.de>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
parent 10ae01e2
...@@ -10,9 +10,9 @@ typedef struct dev_info dev_info_t; ...@@ -10,9 +10,9 @@ typedef struct dev_info dev_info_t;
struct linear_private_data struct linear_private_data
{ {
struct rcu_head rcu;
sector_t array_sectors; sector_t array_sectors;
dev_info_t disks[0]; dev_info_t disks[0];
struct rcu_head rcu;
}; };
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment