From mboxrd@z Thu Jan 1 00:00:00 1970 From: Wu Fengguang Subject: Re: [RFC][PATCH 2/2] readahead: avoid page-by-page reads on POSIX_FADV_RANDOM Date: Thu, 31 Dec 2009 11:03:11 +0800 Message-ID: <20091231030311.GA12517@localhost> References: <20091225000717.GA26949@yahoo-inc.com> <87aax18xms.fsf@basil.nowhere.org> <20091230051540.GA16308@localhost> <20091230052402.GB26364@localhost> <873a2s8hmp.fsf@basil.nowhere.org> <20091231013935.GA6570@localhost> <20091231025343.GA11327@localhost> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: Andrew Morton , Quentin Barnes , "linux-kernel@vger.kernel.org" , "linux-fsdevel@vger.kernel.org" , Nick Piggin , Steven Whitehouse To: Andi Kleen Return-path: Received: from mga14.intel.com ([143.182.124.37]:45974 "EHLO mga14.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752692AbZLaDDO (ORCPT ); Wed, 30 Dec 2009 22:03:14 -0500 Content-Disposition: inline In-Reply-To: <20091231025343.GA11327@localhost> Sender: linux-fsdevel-owner@vger.kernel.org List-ID: On Thu, Dec 31, 2009 at 10:53:43AM +0800, Wu Fengguang wrote: > So how about add a FMODE_HINT_RANDOM_READ bit to file->f_mode? > Modifying it at fadvise() time at least won't disturb the existing > open-time-modify-only f_mode bits.. Ah it seems file->f_flags (modified under f_lock) is ideal candidate :) Thanks, Fengguang