md_monitor: Do not call mdadm if a device is faulty

mdadm is executed via a separate thread, so there is a race window
during with the I/O status might change.
So re-check the I/O status of all device prior to calling mdadm
to avoid any issues with recovery.

References: bnc#808647

Signed-off-by: Hannes Reinecke <hare@suse.de>
md_monitor: terminate dasd_monitor when ioctl fails

A failing ioctl means that the md device was stopped, so
we should be breaking out of the loop here.

References: bnc#812538

Signed-off-by: Hannes Reinecke <hare@suse.de>
Version 4.20

Signed-off-by: Hannes Reinecke <hare@suse.de>