# Re: fix a lock order reversal in md\_alloc

- From: Song Liu \<song@kernel.org\>
- Date: 2021-09-09 06:14:26 
- List: linux-raid
- Page: https://ratatoskr.run/linux-raid/2021/09/6640665
- Thread: https://ratatoskr.run/linux-raid/2021/09/6640639/t.md

```text
On Wed, Sep 1, 2021 at 4:39 AM Christoph Hellwig [ref] wrote:
>
> Hi Song,
>
> the first patch in this series fixed the reported lock order reversal
> in md_alloc.  The rest sort out the error handling in that function,
> starting with the patch from Luis to handle add_disk errors, which
> would otherwise conflict with the first patch.
>
> Note that I have had a hard time verifying this all works fine as the
> testsuite in mdadm already keeps failing a lot for me with the baseline
> kernel. Some of thos reproducibly and others randomly.  Is there a
> good document somehow describing what to expect from the mdadm test
> suite?
>
> Diffstat:
>  drivers/md/md.c |   56 +++++++++++++++++++++++++++++---------------------------
>  1 file changed, 29 insertions(+), 27 deletions(-)

Applied to md-fixes. Thanks!

Song
```
