From patchwork Fri Mar 26 04:01:14 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Fengguang Wu X-Patchwork-Id: 88425 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter.kernel.org (8.14.3/8.14.3) with ESMTP id o2Q41cXE017074 for ; Fri, 26 Mar 2010 04:01:39 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1750800Ab0CZEBR (ORCPT ); Fri, 26 Mar 2010 00:01:17 -0400 Received: from mga11.intel.com ([192.55.52.93]:43391 "EHLO mga11.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750711Ab0CZEBQ (ORCPT ); Fri, 26 Mar 2010 00:01:16 -0400 Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by fmsmga102.fm.intel.com with ESMTP; 25 Mar 2010 20:57:35 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="4.51,311,1267430400"; d="scan'208";a="784081123" Received: from wfg-t61.sh.intel.com (HELO localhost.localdomain) ([10.239.21.119]) by fmsmga001.fm.intel.com with ESMTP; 25 Mar 2010 21:00:58 -0700 Received: from wfg by localhost.localdomain with local (Exim 4.69) (envelope-from ) id 1Nv0jS-0005ed-Cb; Fri, 26 Mar 2010 12:01:14 +0800 Date: Fri, 26 Mar 2010 12:01:14 +0800 From: Wu Fengguang To: "Yan, Zheng " Cc: "linux-btrfs@vger.kernel.org" , "kirill@shutemov.name" , Andrew Morton , stable@kernel.org, LKML Subject: Re: Oops on btrfs filesystem balance Message-ID: <20100326040114.GA20717@localhost> References: <3d0408631003252040r70c54b2fm24d64b819c59c9c@mail.gmail.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <3d0408631003252040r70c54b2fm24d64b819c59c9c@mail.gmail.com> User-Agent: Mutt/1.5.18 (2008-05-17) Sender: linux-btrfs-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-btrfs@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.3 (demeter.kernel.org [140.211.167.41]); Fri, 26 Mar 2010 04:01:39 +0000 (UTC) --- sound-2.6.orig/mm/readahead.c 2010-03-26 11:51:57.000000000 +0800 +++ sound-2.6/mm/readahead.c 2010-03-26 11:52:11.000000000 +0800 @@ -502,7 +502,7 @@ void page_cache_sync_readahead(struct ad return; /* be dumb */ - if (filp->f_mode & FMODE_RANDOM) { + if (filp && (filp->f_mode & FMODE_RANDOM)) { force_page_cache_readahead(mapping, filp, offset, req_size); return; }