submit_bio() flush to disk immediately
Rajat Sharma
fs.rajat at gmail.com
Tue Aug 6 07:10:16 EDT 2013
On Tue, Aug 6, 2013 at 4:37 PM, Prashant Shah <pshah.mumbai at gmail.com> wrote:
> Hi,
>
> On Tue, Aug 6, 2013 at 4:33 PM, Rajat Sharma <fs.rajat at gmail.com> wrote:
>
>> so has penalty on all files and hence applications. Are you okay with
>> it? You need it just for one file. purge cache of just one file from
>> your module. Also there could be open file mappings, you might have to
>> wait for them to close first.
>
> Its ok, the writes happens early on before the shell is started so
> there are no applications using the file.
>
> I stumbled upon invalidate_inode_pages() - testing it right now.
>
At the same time, following proc interface, I stumbled upon
invalidate_mapping_pages() to purge cache of desired inode. Try this
one if invalidate_inode_pages() does not work.
> Regards.
More information about the Kernelnewbies
mailing list