This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [patch] Fix BZ 19165 -- overflow in fread / fwrite


On Thu, Feb 11, 2016 at 10:30 AM, Rich Felker <dalias@libc.org> wrote:
> On Thu, Feb 11, 2016 at 08:50:58AM -0500, Zack Weinberg wrote:
>>
>> [...] the kernel might need to finalize access checks and wire down the
>> pages for DMA before it even knows how much data is available.
>
> That makes no sense except for O_DIRECT wackiness where I doubt anyone
> cares about correctness/standards. Normal file reads should always be
> DMA into the fs cache followed by memcpy to the caller's buffer.

I was thinking of character devices and maybe also sockets.  Those don't
go through the fs cache.

And I don't think anyone wants the behavior to vary depending on which
kind of fd you have passed to read().

zw


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]