Re: [PATCH 2/7] A framework for holding bios until suspend

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Takahiro Yasui [tyasui@xxxxxxxxxx] wrote:
> On 11/18/09 07:11, Mikulas Patocka wrote:
> > @@ -760,6 +775,7 @@ static void do_mirror(struct work_struct
> >  	bio_list_init(&ms->reads);
> >  	bio_list_init(&ms->writes);
> >  	bio_list_init(&ms->failures);
> > +	bio_list_init(&ms->hold);
> >  	spin_unlock_irqrestore(&ms->lock, flags);
> 
> Initializing the hold list in do_mirror() is a problem. Some bios might
> already in it and they will never be processed. This makes device-mapper
> "stuck" when the device goes suspend. The hold list should be inizialized
> only when the mirror device is created in alloc_context().
> 
> alloc_context()
>         spin_lock_init(&ms->lock);
>         bio_list_init(&ms->reads);
>         bio_list_init(&ms->writes);
>         bio_list_init(&ms->failures);
> +        bio_list_init(&ms->hold);
> 
> Thanks,
> Taka

Good catch!

--
dm-devel mailing list
dm-devel@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/dm-devel

[Index of Archives]     [DM Crypt]     [Fedora Desktop]     [ATA RAID]     [Fedora Marketing]     [Fedora Packaging]     [Fedora SELinux]     [Yosemite Discussion]     [KDE Users]     [Fedora Docs]

  Powered by Linux