<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux-stable.git/drivers/md/md.c, branch v4.9</title>
<subtitle>Linux kernel stable tree</subtitle>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/'/>
<entry>
<title>md: be careful not lot leak internal curr_resync value into metadata. -- (all)</title>
<updated>2016-10-29T05:04:05+00:00</updated>
<author>
<name>NeilBrown</name>
<email>neilb@suse.com</email>
</author>
<published>2016-10-28T04:59:41+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=1217e1d1999ed6c9c1e1b1acae0a74ab70464ae2'/>
<id>1217e1d1999ed6c9c1e1b1acae0a74ab70464ae2</id>
<content type='text'>
mddev-&gt;curr_resync usually records where the current resync is up to,
but during the starting phase it has some "magic" values.

 1 - means that the array is trying to start a resync, but has yielded
     to another array which shares physical devices, and also needs to
     start a resync
 2 - means the array is trying to start resync, but has found another
     array which shares physical devices and has already started resync.

 3 - means that resync has commensed, but it is possible that nothing
     has actually been resynced yet.

It is important that this value not be visible to user-space and
particularly that it doesn't get written to the metadata, as the
resync or recovery checkpoint.  In part, this is because it may be
slightly higher than the correct value, though this is very rare.
In part, because it is not a multiple of 4K, and some devices only
support 4K aligned accesses.

There are two places where this value is propagates into either
-&gt;curr_resync_completed or -&gt;recovery_cp or -&gt;recovery_offset.
These currently avoid the propagation of values 1 and 3, but will
allow 3 to leak through.

Change them to only propagate the value if it is &gt; 3.

As this can cause an array to fail, the patch is suitable for -stable.

Cc: stable@vger.kernel.org (v3.7+)
Reported-by: Viswesh &lt;viswesh.vichu@gmail.com&gt;
Signed-off-by: NeilBrown &lt;neilb@suse.com&gt;
Signed-off-by: Shaohua Li &lt;shli@fb.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
mddev-&gt;curr_resync usually records where the current resync is up to,
but during the starting phase it has some "magic" values.

 1 - means that the array is trying to start a resync, but has yielded
     to another array which shares physical devices, and also needs to
     start a resync
 2 - means the array is trying to start resync, but has found another
     array which shares physical devices and has already started resync.

 3 - means that resync has commensed, but it is possible that nothing
     has actually been resynced yet.

It is important that this value not be visible to user-space and
particularly that it doesn't get written to the metadata, as the
resync or recovery checkpoint.  In part, this is because it may be
slightly higher than the correct value, though this is very rare.
In part, because it is not a multiple of 4K, and some devices only
support 4K aligned accesses.

There are two places where this value is propagates into either
-&gt;curr_resync_completed or -&gt;recovery_cp or -&gt;recovery_offset.
These currently avoid the propagation of values 1 and 3, but will
allow 3 to leak through.

Change them to only propagate the value if it is &gt; 3.

As this can cause an array to fail, the patch is suitable for -stable.

Cc: stable@vger.kernel.org (v3.7+)
Reported-by: Viswesh &lt;viswesh.vichu@gmail.com&gt;
Signed-off-by: NeilBrown &lt;neilb@suse.com&gt;
Signed-off-by: Shaohua Li &lt;shli@fb.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>md: report 'write_pending' state when array in sync</title>
<updated>2016-10-24T22:28:19+00:00</updated>
<author>
<name>Tomasz Majchrzak</name>
<email>tomasz.majchrzak@intel.com</email>
</author>
<published>2016-10-24T10:47:28+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=16f889499a5214ebe038f8bd00f4c0094ed0ed75'/>
<id>16f889499a5214ebe038f8bd00f4c0094ed0ed75</id>
<content type='text'>
If there is a bad block on a disk and there is a recovery performed from
this disk, the same bad block is reported for a new disk. It involves
setting MD_CHANGE_PENDING flag in rdev_set_badblocks. For external
metadata this flag is not being cleared as array state is reported as
'clean'. The read request to bad block in RAID5 array gets stuck as it
is waiting for a flag to be cleared - as per commit c3cce6cda162
("md/raid5: ensure device failure recorded before write request
returns.").

The meaning of MD_CHANGE_PENDING and MD_CHANGE_CLEAN flags has been
clarified in commit 070dc6dd7103 ("md: resolve confusion of
MD_CHANGE_CLEAN"), however MD_CHANGE_PENDING flag has been used in
personality error handlers since and it doesn't fully comply with
initial purpose. It was supposed to notify that write request is about
to start, however now it is also used to request metadata update.
Initially (in md_allow_write, md_write_start) MD_CHANGE_PENDING flag has
been set and in_sync has been set to 0 at the same time. Error handlers
just set the flag without modifying in_sync value. Sysfs array state is
a single value so now it reports 'clean' when MD_CHANGE_PENDING flag is
set and in_sync is set to 1. Userspace has no idea it is expected to
take some action.

Swap the order that array state is checked so 'write_pending' is
reported ahead of 'clean' ('write_pending' is a misleading name but it
is too late to rename it now).

Signed-off-by: Tomasz Majchrzak &lt;tomasz.majchrzak@intel.com&gt;
Signed-off-by: Shaohua Li &lt;shli@fb.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
If there is a bad block on a disk and there is a recovery performed from
this disk, the same bad block is reported for a new disk. It involves
setting MD_CHANGE_PENDING flag in rdev_set_badblocks. For external
metadata this flag is not being cleared as array state is reported as
'clean'. The read request to bad block in RAID5 array gets stuck as it
is waiting for a flag to be cleared - as per commit c3cce6cda162
("md/raid5: ensure device failure recorded before write request
returns.").

The meaning of MD_CHANGE_PENDING and MD_CHANGE_CLEAN flags has been
clarified in commit 070dc6dd7103 ("md: resolve confusion of
MD_CHANGE_CLEAN"), however MD_CHANGE_PENDING flag has been used in
personality error handlers since and it doesn't fully comply with
initial purpose. It was supposed to notify that write request is about
to start, however now it is also used to request metadata update.
Initially (in md_allow_write, md_write_start) MD_CHANGE_PENDING flag has
been set and in_sync has been set to 0 at the same time. Error handlers
just set the flag without modifying in_sync value. Sysfs array state is
a single value so now it reports 'clean' when MD_CHANGE_PENDING flag is
set and in_sync is set to 1. Userspace has no idea it is expected to
take some action.

Swap the order that array state is checked so 'write_pending' is
reported ahead of 'clean' ('write_pending' is a misleading name but it
is too late to rename it now).

Signed-off-by: Tomasz Majchrzak &lt;tomasz.majchrzak@intel.com&gt;
Signed-off-by: Shaohua Li &lt;shli@fb.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>md: set rotational bit</title>
<updated>2016-10-03T17:20:27+00:00</updated>
<author>
<name>Shaohua Li</name>
<email>shli@fb.com</email>
</author>
<published>2016-09-30T16:45:40+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=bb086a89a406b5d877ee616f1490fcc81f8e1b2b'/>
<id>bb086a89a406b5d877ee616f1490fcc81f8e1b2b</id>
<content type='text'>
if all disks in an array are non-rotational, set the array
non-rotational.

This only works for array with all disks populated at startup. Support
for disk hotadd/hotremove could be added later if necessary.

Acked-by: Tejun Heo &lt;tj@kernel.org&gt;
Signed-off-by: Shaohua Li &lt;shli@fb.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
if all disks in an array are non-rotational, set the array
non-rotational.

This only works for array with all disks populated at startup. Support
for disk hotadd/hotremove could be added later if necessary.

Acked-by: Tejun Heo &lt;tj@kernel.org&gt;
Signed-off-by: Shaohua Li &lt;shli@fb.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>md: fix a potential deadlock</title>
<updated>2016-09-21T16:09:44+00:00</updated>
<author>
<name>Shaohua Li</name>
<email>shli@fb.com</email>
</author>
<published>2016-09-14T21:26:54+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=90bcf1338193da4c87fb7492c716f225b907acf4'/>
<id>90bcf1338193da4c87fb7492c716f225b907acf4</id>
<content type='text'>
lockdep reports a potential deadlock. Fix this by droping the mutex
before md_import_device

[ 1137.126601] ======================================================
[ 1137.127013] [ INFO: possible circular locking dependency detected ]
[ 1137.127013] 4.8.0-rc4+ #538 Not tainted
[ 1137.127013] -------------------------------------------------------
[ 1137.127013] mdadm/16675 is trying to acquire lock:
[ 1137.127013]  (&amp;bdev-&gt;bd_mutex){+.+.+.}, at: [&lt;ffffffff81243cf3&gt;] __blkdev_get+0x63/0x450
[ 1137.127013]
but task is already holding lock:
[ 1137.127013]  (detected_devices_mutex){+.+.+.}, at: [&lt;ffffffff81a5138c&gt;] md_ioctl+0x2ac/0x1f50
[ 1137.127013]
which lock already depends on the new lock.

[ 1137.127013]
the existing dependency chain (in reverse order) is:
[ 1137.127013]
-&gt; #1 (detected_devices_mutex){+.+.+.}:
[ 1137.127013]        [&lt;ffffffff810b6f19&gt;] lock_acquire+0xb9/0x220
[ 1137.127013]        [&lt;ffffffff81c51647&gt;] mutex_lock_nested+0x67/0x3d0
[ 1137.127013]        [&lt;ffffffff81a4eeaf&gt;] md_autodetect_dev+0x3f/0x90
[ 1137.127013]        [&lt;ffffffff81595be8&gt;] rescan_partitions+0x1a8/0x2c0
[ 1137.127013]        [&lt;ffffffff81590081&gt;] __blkdev_reread_part+0x71/0xb0
[ 1137.127013]        [&lt;ffffffff815900e5&gt;] blkdev_reread_part+0x25/0x40
[ 1137.127013]        [&lt;ffffffff81590c4b&gt;] blkdev_ioctl+0x51b/0xa30
[ 1137.127013]        [&lt;ffffffff81242bf1&gt;] block_ioctl+0x41/0x50
[ 1137.127013]        [&lt;ffffffff81214c96&gt;] do_vfs_ioctl+0x96/0x6e0
[ 1137.127013]        [&lt;ffffffff81215321&gt;] SyS_ioctl+0x41/0x70
[ 1137.127013]        [&lt;ffffffff81c56825&gt;] entry_SYSCALL_64_fastpath+0x18/0xa8
[ 1137.127013]
-&gt; #0 (&amp;bdev-&gt;bd_mutex){+.+.+.}:
[ 1137.127013]        [&lt;ffffffff810b6af2&gt;] __lock_acquire+0x1662/0x1690
[ 1137.127013]        [&lt;ffffffff810b6f19&gt;] lock_acquire+0xb9/0x220
[ 1137.127013]        [&lt;ffffffff81c51647&gt;] mutex_lock_nested+0x67/0x3d0
[ 1137.127013]        [&lt;ffffffff81243cf3&gt;] __blkdev_get+0x63/0x450
[ 1137.127013]        [&lt;ffffffff81244307&gt;] blkdev_get+0x227/0x350
[ 1137.127013]        [&lt;ffffffff812444f6&gt;] blkdev_get_by_dev+0x36/0x50
[ 1137.127013]        [&lt;ffffffff81a46d65&gt;] lock_rdev+0x35/0x80
[ 1137.127013]        [&lt;ffffffff81a49bb4&gt;] md_import_device+0xb4/0x1b0
[ 1137.127013]        [&lt;ffffffff81a513d6&gt;] md_ioctl+0x2f6/0x1f50
[ 1137.127013]        [&lt;ffffffff815909b3&gt;] blkdev_ioctl+0x283/0xa30
[ 1137.127013]        [&lt;ffffffff81242bf1&gt;] block_ioctl+0x41/0x50
[ 1137.127013]        [&lt;ffffffff81214c96&gt;] do_vfs_ioctl+0x96/0x6e0
[ 1137.127013]        [&lt;ffffffff81215321&gt;] SyS_ioctl+0x41/0x70
[ 1137.127013]        [&lt;ffffffff81c56825&gt;] entry_SYSCALL_64_fastpath+0x18/0xa8
[ 1137.127013]
other info that might help us debug this:

[ 1137.127013]  Possible unsafe locking scenario:

[ 1137.127013]        CPU0                    CPU1
[ 1137.127013]        ----                    ----
[ 1137.127013]   lock(detected_devices_mutex);
[ 1137.127013]                                lock(&amp;bdev-&gt;bd_mutex);
[ 1137.127013]                                lock(detected_devices_mutex);
[ 1137.127013]   lock(&amp;bdev-&gt;bd_mutex);
[ 1137.127013]
 *** DEADLOCK ***

Cc: Cong Wang &lt;xiyou.wangcong@gmail.com&gt;
Signed-off-by: Shaohua Li &lt;shli@fb.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
lockdep reports a potential deadlock. Fix this by droping the mutex
before md_import_device

[ 1137.126601] ======================================================
[ 1137.127013] [ INFO: possible circular locking dependency detected ]
[ 1137.127013] 4.8.0-rc4+ #538 Not tainted
[ 1137.127013] -------------------------------------------------------
[ 1137.127013] mdadm/16675 is trying to acquire lock:
[ 1137.127013]  (&amp;bdev-&gt;bd_mutex){+.+.+.}, at: [&lt;ffffffff81243cf3&gt;] __blkdev_get+0x63/0x450
[ 1137.127013]
but task is already holding lock:
[ 1137.127013]  (detected_devices_mutex){+.+.+.}, at: [&lt;ffffffff81a5138c&gt;] md_ioctl+0x2ac/0x1f50
[ 1137.127013]
which lock already depends on the new lock.

[ 1137.127013]
the existing dependency chain (in reverse order) is:
[ 1137.127013]
-&gt; #1 (detected_devices_mutex){+.+.+.}:
[ 1137.127013]        [&lt;ffffffff810b6f19&gt;] lock_acquire+0xb9/0x220
[ 1137.127013]        [&lt;ffffffff81c51647&gt;] mutex_lock_nested+0x67/0x3d0
[ 1137.127013]        [&lt;ffffffff81a4eeaf&gt;] md_autodetect_dev+0x3f/0x90
[ 1137.127013]        [&lt;ffffffff81595be8&gt;] rescan_partitions+0x1a8/0x2c0
[ 1137.127013]        [&lt;ffffffff81590081&gt;] __blkdev_reread_part+0x71/0xb0
[ 1137.127013]        [&lt;ffffffff815900e5&gt;] blkdev_reread_part+0x25/0x40
[ 1137.127013]        [&lt;ffffffff81590c4b&gt;] blkdev_ioctl+0x51b/0xa30
[ 1137.127013]        [&lt;ffffffff81242bf1&gt;] block_ioctl+0x41/0x50
[ 1137.127013]        [&lt;ffffffff81214c96&gt;] do_vfs_ioctl+0x96/0x6e0
[ 1137.127013]        [&lt;ffffffff81215321&gt;] SyS_ioctl+0x41/0x70
[ 1137.127013]        [&lt;ffffffff81c56825&gt;] entry_SYSCALL_64_fastpath+0x18/0xa8
[ 1137.127013]
-&gt; #0 (&amp;bdev-&gt;bd_mutex){+.+.+.}:
[ 1137.127013]        [&lt;ffffffff810b6af2&gt;] __lock_acquire+0x1662/0x1690
[ 1137.127013]        [&lt;ffffffff810b6f19&gt;] lock_acquire+0xb9/0x220
[ 1137.127013]        [&lt;ffffffff81c51647&gt;] mutex_lock_nested+0x67/0x3d0
[ 1137.127013]        [&lt;ffffffff81243cf3&gt;] __blkdev_get+0x63/0x450
[ 1137.127013]        [&lt;ffffffff81244307&gt;] blkdev_get+0x227/0x350
[ 1137.127013]        [&lt;ffffffff812444f6&gt;] blkdev_get_by_dev+0x36/0x50
[ 1137.127013]        [&lt;ffffffff81a46d65&gt;] lock_rdev+0x35/0x80
[ 1137.127013]        [&lt;ffffffff81a49bb4&gt;] md_import_device+0xb4/0x1b0
[ 1137.127013]        [&lt;ffffffff81a513d6&gt;] md_ioctl+0x2f6/0x1f50
[ 1137.127013]        [&lt;ffffffff815909b3&gt;] blkdev_ioctl+0x283/0xa30
[ 1137.127013]        [&lt;ffffffff81242bf1&gt;] block_ioctl+0x41/0x50
[ 1137.127013]        [&lt;ffffffff81214c96&gt;] do_vfs_ioctl+0x96/0x6e0
[ 1137.127013]        [&lt;ffffffff81215321&gt;] SyS_ioctl+0x41/0x70
[ 1137.127013]        [&lt;ffffffff81c56825&gt;] entry_SYSCALL_64_fastpath+0x18/0xa8
[ 1137.127013]
other info that might help us debug this:

[ 1137.127013]  Possible unsafe locking scenario:

[ 1137.127013]        CPU0                    CPU1
[ 1137.127013]        ----                    ----
[ 1137.127013]   lock(detected_devices_mutex);
[ 1137.127013]                                lock(&amp;bdev-&gt;bd_mutex);
[ 1137.127013]                                lock(detected_devices_mutex);
[ 1137.127013]   lock(&amp;bdev-&gt;bd_mutex);
[ 1137.127013]
 *** DEADLOCK ***

Cc: Cong Wang &lt;xiyou.wangcong@gmail.com&gt;
Signed-off-by: Shaohua Li &lt;shli@fb.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>md-cluster: clean related infos of cluster</title>
<updated>2016-09-21T16:09:44+00:00</updated>
<author>
<name>Guoqing Jiang</name>
<email>gqjiang@suse.com</email>
</author>
<published>2016-08-12T05:42:38+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=c20c33f0e2abdb8bab1ec755ed668d7894bf9336'/>
<id>c20c33f0e2abdb8bab1ec755ed668d7894bf9336</id>
<content type='text'>
cluster_info and bitmap_info.nodes also need to be
cleared when array is stopped.

Reviewed-by: NeilBrown &lt;neilb@suse.com&gt;
Signed-off-by: Guoqing Jiang &lt;gqjiang@suse.com&gt;
Signed-off-by: Shaohua Li &lt;shli@fb.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
cluster_info and bitmap_info.nodes also need to be
cleared when array is stopped.

Reviewed-by: NeilBrown &lt;neilb@suse.com&gt;
Signed-off-by: Guoqing Jiang &lt;gqjiang@suse.com&gt;
Signed-off-by: Shaohua Li &lt;shli@fb.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>md: changes for MD_STILL_CLOSED flag</title>
<updated>2016-09-21T16:09:44+00:00</updated>
<author>
<name>Guoqing Jiang</name>
<email>gqjiang@suse.com</email>
</author>
<published>2016-08-12T05:42:37+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=af8d8e6f031589ccf32b08eea91def53db8cfa95'/>
<id>af8d8e6f031589ccf32b08eea91def53db8cfa95</id>
<content type='text'>
When stop clustered raid while it is pending on resync,
MD_STILL_CLOSED flag could be cleared since udev rule
is triggered to open the mddev. So obviously array can't
be stopped soon and returns EBUSY.

	mdadm -Ss          md-raid-arrays.rules
  set MD_STILL_CLOSED          md_open()
	... ... ...          clear MD_STILL_CLOSED
	do_md_stop

We make below changes to resolve this issue:

1. rename MD_STILL_CLOSED to MD_CLOSING since it is set
   when stop array and it means we are stopping array.
2. let md_open returns early if CLOSING is set, so no
   other threads will open array if one thread is trying
   to close it.
3. no need to clear CLOSING bit in md_open because 1 has
   ensure the bit is cleared, then we also don't need to
   test CLOSING bit in do_md_stop.

Reviewed-by: NeilBrown &lt;neilb@suse.com&gt;
Signed-off-by: Guoqing Jiang &lt;gqjiang@suse.com&gt;
Signed-off-by: Shaohua Li &lt;shli@fb.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
When stop clustered raid while it is pending on resync,
MD_STILL_CLOSED flag could be cleared since udev rule
is triggered to open the mddev. So obviously array can't
be stopped soon and returns EBUSY.

	mdadm -Ss          md-raid-arrays.rules
  set MD_STILL_CLOSED          md_open()
	... ... ...          clear MD_STILL_CLOSED
	do_md_stop

We make below changes to resolve this issue:

1. rename MD_STILL_CLOSED to MD_CLOSING since it is set
   when stop array and it means we are stopping array.
2. let md_open returns early if CLOSING is set, so no
   other threads will open array if one thread is trying
   to close it.
3. no need to clear CLOSING bit in md_open because 1 has
   ensure the bit is cleared, then we also don't need to
   test CLOSING bit in do_md_stop.

Reviewed-by: NeilBrown &lt;neilb@suse.com&gt;
Signed-off-by: Guoqing Jiang &lt;gqjiang@suse.com&gt;
Signed-off-by: Shaohua Li &lt;shli@fb.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>md-cluster: call md_kick_rdev_from_array once ack failed</title>
<updated>2016-09-21T16:09:44+00:00</updated>
<author>
<name>Guoqing Jiang</name>
<email>gqjiang@suse.com</email>
</author>
<published>2016-08-12T05:42:34+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=e566aef12a166732b7fd85897f8736ccf4fc7814'/>
<id>e566aef12a166732b7fd85897f8736ccf4fc7814</id>
<content type='text'>
The new_disk_ack could return failure if WAITING_FOR_NEWDISK
is not set, so we need to kick the dev from array in case
failure happened.

And we missed to check err before call new_disk_ack othwise
we could kick a rdev which isn't in array, thanks for the
reminder from Shaohua.

Reviewed-by: NeilBrown &lt;neilb@suse.com&gt;
Signed-off-by: Guoqing Jiang &lt;gqjiang@suse.com&gt;
Signed-off-by: Shaohua Li &lt;shli@fb.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The new_disk_ack could return failure if WAITING_FOR_NEWDISK
is not set, so we need to kick the dev from array in case
failure happened.

And we missed to check err before call new_disk_ack othwise
we could kick a rdev which isn't in array, thanks for the
reminder from Shaohua.

Reviewed-by: NeilBrown &lt;neilb@suse.com&gt;
Signed-off-by: Guoqing Jiang &lt;gqjiang@suse.com&gt;
Signed-off-by: Shaohua Li &lt;shli@fb.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>md-cluster: make md-cluster also can work when compiled into kernel</title>
<updated>2016-09-08T18:11:27+00:00</updated>
<author>
<name>Guoqing Jiang</name>
<email>gqjiang@suse.com</email>
</author>
<published>2016-09-05T02:17:28+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=47a7b0d8888c04c9746812820b6e60553cc77bbc'/>
<id>47a7b0d8888c04c9746812820b6e60553cc77bbc</id>
<content type='text'>
The md-cluster is compiled as module by default,
if it is compiled by built-in way, then we can't
make md-cluster works.

[64782.630008] md/raid1:md127: active with 2 out of 2 mirrors
[64782.630528] md-cluster module not found.
[64782.630530] md127: Could not setup cluster service (-2)

Fixes: edb39c9 ("Introduce md_cluster_operations to handle cluster functions")
Cc: stable@vger.kernel.org (v4.1+)
Reported-by: Marc Smith &lt;marc.smith@mcc.edu&gt;
Reviewed-by: NeilBrown &lt;neilb@suse.com&gt;
Signed-off-by: Guoqing Jiang &lt;gqjiang@suse.com&gt;
Signed-off-by: Shaohua Li &lt;shli@fb.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The md-cluster is compiled as module by default,
if it is compiled by built-in way, then we can't
make md-cluster works.

[64782.630008] md/raid1:md127: active with 2 out of 2 mirrors
[64782.630528] md-cluster module not found.
[64782.630530] md127: Could not setup cluster service (-2)

Fixes: edb39c9 ("Introduce md_cluster_operations to handle cluster functions")
Cc: stable@vger.kernel.org (v4.1+)
Reported-by: Marc Smith &lt;marc.smith@mcc.edu&gt;
Reviewed-by: NeilBrown &lt;neilb@suse.com&gt;
Signed-off-by: Guoqing Jiang &lt;gqjiang@suse.com&gt;
Signed-off-by: Shaohua Li &lt;shli@fb.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge tag 'md/4.8-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/shli/md</title>
<updated>2016-08-30T18:24:04+00:00</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2016-08-30T18:24:04+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=86a1679860babbacd61fc1e8c0c0f43641d5860d'/>
<id>86a1679860babbacd61fc1e8c0c0f43641d5860d</id>
<content type='text'>
Pull MD fixes from Shaohua Li:
 "This includes several bug fixes:

   - Alexey Obitotskiy fixed a hang for faulty raid5 array with external
     management

   - Song Liu fixed two raid5 journal related bugs

   - Tomasz Majchrzak fixed a bad block recording issue and an
     accounting issue for raid10

   - ZhengYuan Liu fixed an accounting issue for raid5

   - I fixed a potential race condition and memory leak with DIF/DIX
     enabled

   - other trival fixes"

* tag 'md/4.8-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/shli/md:
  raid5: avoid unnecessary bio data set
  raid5: fix memory leak of bio integrity data
  raid10: record correct address of bad block
  md-cluster: fix error return code in join()
  r5cache: set MD_JOURNAL_CLEAN correctly
  md: don't print the same repeated messages about delayed sync operation
  md: remove obsolete ret in md_start_sync
  md: do not count journal as spare in GET_ARRAY_INFO
  md: Prevent IO hold during accessing to faulty raid5 array
  MD: hold mddev lock to change bitmap location
  raid5: fix incorrectly counter of conf-&gt;empty_inactive_list_nr
  raid10: increment write counter after bio is split
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Pull MD fixes from Shaohua Li:
 "This includes several bug fixes:

   - Alexey Obitotskiy fixed a hang for faulty raid5 array with external
     management

   - Song Liu fixed two raid5 journal related bugs

   - Tomasz Majchrzak fixed a bad block recording issue and an
     accounting issue for raid10

   - ZhengYuan Liu fixed an accounting issue for raid5

   - I fixed a potential race condition and memory leak with DIF/DIX
     enabled

   - other trival fixes"

* tag 'md/4.8-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/shli/md:
  raid5: avoid unnecessary bio data set
  raid5: fix memory leak of bio integrity data
  raid10: record correct address of bad block
  md-cluster: fix error return code in join()
  r5cache: set MD_JOURNAL_CLEAN correctly
  md: don't print the same repeated messages about delayed sync operation
  md: remove obsolete ret in md_start_sync
  md: do not count journal as spare in GET_ARRAY_INFO
  md: Prevent IO hold during accessing to faulty raid5 array
  MD: hold mddev lock to change bitmap location
  raid5: fix incorrectly counter of conf-&gt;empty_inactive_list_nr
  raid10: increment write counter after bio is split
</pre>
</div>
</content>
</entry>
<entry>
<title>r5cache: set MD_JOURNAL_CLEAN correctly</title>
<updated>2016-08-24T17:21:50+00:00</updated>
<author>
<name>Song Liu</name>
<email>songliubraving@fb.com</email>
</author>
<published>2016-08-19T22:34:01+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=486b0f7bcd64be027535811ef44195bc1027fbd3'/>
<id>486b0f7bcd64be027535811ef44195bc1027fbd3</id>
<content type='text'>
Currently, the code sets MD_JOURNAL_CLEAN when the array has
MD_FEATURE_JOURNAL and the recovery_cp is MaxSector. The array
will be MD_JOURNAL_CLEAN even if the journal device is missing.

With this patch, the MD_JOURNAL_CLEAN is only set when the journal
device presents.

Signed-off-by: Song Liu &lt;songliubraving@fb.com&gt;
Signed-off-by: Shaohua Li &lt;shli@fb.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Currently, the code sets MD_JOURNAL_CLEAN when the array has
MD_FEATURE_JOURNAL and the recovery_cp is MaxSector. The array
will be MD_JOURNAL_CLEAN even if the journal device is missing.

With this patch, the MD_JOURNAL_CLEAN is only set when the journal
device presents.

Signed-off-by: Song Liu &lt;songliubraving@fb.com&gt;
Signed-off-by: Shaohua Li &lt;shli@fb.com&gt;
</pre>
</div>
</content>
</entry>
</feed>
