Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755652AbZKCGmi (ORCPT ); Tue, 3 Nov 2009 01:42:38 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1753987AbZKCGmh (ORCPT ); Tue, 3 Nov 2009 01:42:37 -0500 Received: from comal.ext.ti.com ([198.47.26.152]:54280 "EHLO comal.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752860AbZKCGmg convert rfc822-to-8bit (ORCPT ); Tue, 3 Nov 2009 01:42:36 -0500 From: "Dasgupta, Romit" To: "Rafael J. Wysocki" CC: "viro@zeniv.linux.org.uk" , "linux-fsdevel@vger.kernel.org" , "linux-kernel@vger.kernel.org" , "linux-pm@lists.linux-foundation.org" , "linux-omap@vger.kernel.org" Date: Tue, 3 Nov 2009 12:12:07 +0530 Subject: RE: [PATCH 1/1] PM: Making bdi threads non-freezable Thread-Topic: [PATCH 1/1] PM: Making bdi threads non-freezable Thread-Index: Acpb7DeOqt9uHO/fRwa6uutit1KcVwAY223A Message-ID: References: <200911021943.49943.rjw@sisk.pl> In-Reply-To: <200911021943.49943.rjw@sisk.pl> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: acceptlanguage: en-US Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7BIT MIME-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1207 Lines: 24 > Subject: Re: [PATCH 1/1] PM: Making bdi threads non-freezable > > On Monday 02 November 2009, Dasgupta, Romit wrote: > > Fixes the case when bdi threads are in the refrigerator but file system sync > > can happen after this. This is possible in MMC when > CONFIG_MMC_UNSAFE_RESUME is > > not set. > > What's going to happen if we attemt to suspend the underlying block device(s) > when the bdi thread are doing their job? Is there any synchronisation > mechanism for that? > There is no explicit synchronization AFAICT. However, it looks like the call to 'del_gendisk' would invoke 'sync_filesystem' down the line. 'sync_filesystem' would end with synchronous writes of inodes followed by a call to '__sync_blockddev'. After this call I believe there should not be any activity pending for the blockdevice. So this should not lead to any race. My tests on the development board did not show any issues. But some FS experts may comment. Regards, -Romit -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/