Re: md_raid: mdX_raid6 looping after sync_action "check" to "idle" transition

From
Guoqing Jiang <hidden>
Date
2021-02-08 14:57:35
Also in
lkml
Reply to
Donald Buczek, 2021-02-08

On 2/8/21 12:38, Donald Buczek wrote:
quoted
5. maybe don't hold reconfig_mutex when try to unregister sync_thread, like this.

         /* resync has finished, collect result */
         mddev_unlock(mddev);
         md_unregister_thread(&mddev->sync_thread);
         mddev_lock(mddev);
As above: While we wait for the sync thread to terminate, wouldn't it be a problem, if another user space operation takes the mutex?
I don't think other places can be blocked while hold mutex, otherwise these places can cause potential deadlock. Please try above two lines change. And perhaps others have better idea.

Thanks,
Guoqing
Thread (49 messages) 49 messages, 8 authors, last reply 2023-09-25
Keyboard shortcuts
hback out one level
jnext message in thread / next series-diff position
kprevious message in thread / previous series-diff position
ldrill in
Escclose help / fold thread tree
?toggle this help