lkml.org 
[lkml]   [2014]   [Jul]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: IMA: kernel reading files opened with O_DIRECT
From
On 2 July 2014 21:45, Jeff Moyer <jmoyer@redhat.com> wrote:
> Christoph Hellwig <hch@infradead.org> writes:
>
>> On Wed, Jul 02, 2014 at 11:55:41AM -0400, Jeff Moyer wrote:
>>> It's acceptable.
>>
>> It's not because it will then also affect other reads going on at the
>> same time.
>

> OK, that part I was fuzzy on. I wasn't sure if they were preventing
> other reads/writes to the same file somehow. I should have mentioned
> that.
>
> Cheers,
> Jeff


What Christoph says is not very correct.

At open there cannot be any reads going on at the same time. IMA
reading is guarded by mutex. Following opens do not perform any IMA
readings and do not do what he says...

If file was modified with direct-io, VFS code itself always invalidate
pages before and after any write. It is basically what Christoph says.
But that is not IMA problem but direct-io itself. As it is stupid
interface. I would be more looking to kind of fadvise interface to
control amount of page caching...

So I think what Jeff suggest suites well to IMA.

--
Thanks,
Dmitry


\
 
 \ /
  Last update: 2014-07-02 21:41    [W:0.070 / U:0.664 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site