From: Andrew Morton Subject: Re: [PATCH V3] Allow SysRq emergency thaw to thaw frozen filesystems Date: Fri, 30 Jan 2009 13:40:09 -0800 Message-ID: <20090130134009.02d4a576.akpm@linux-foundation.org> References: <496EB639.6090800@redhat.com> <4970E087.8020308@redhat.com> <4970E4FB.7040407@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Cc: sandeen@redhat.com, linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org, t-sato@yk.jp.nec.com To: Eric Sandeen Return-path: Received: from smtp1.linux-foundation.org ([140.211.169.13]:54624 "EHLO smtp1.linux-foundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752511AbZA3Vky (ORCPT ); Fri, 30 Jan 2009 16:40:54 -0500 In-Reply-To: <4970E4FB.7040407@redhat.com> Sender: linux-fsdevel-owner@vger.kernel.org List-ID: On Fri, 16 Jan 2009 13:50:19 -0600 Eric Sandeen wrote: > +void do_thaw_all(unsigned long unused) > +{ > + struct super_block *sb; > + char b[BDEVNAME_SIZE]; > + > + list_for_each_entry(sb, &super_blocks, s_list) { > + while (sb->s_bdev && !thaw_bdev(sb->s_bdev, sb)) > + printk(KERN_WARNING "Emergency Thaw on %s\n", > + bdevname(sb->s_bdev, b)); > + } > + printk(KERN_WARNING "Emergency Thaw complete\n"); > +} Is there any reason why we're not taking the appropriate locks here? If so, please add a comment justifying the implementation. > +/** > + * emergency_thaw_all -- forcibly thaw every frozen filesystem > + * > + * Used for emergency unfreeze of all filesystems via SysRq > + */ > +void emergency_thaw_all(void) > +{ > + pdflush_operation(do_thaw_all, 0); > +}