On Sat, Jul 4, 2020 at 10:50 PM Alexey Dobriyan wrote:
>
> Al wrote:
>
> > > On Sat, Jul 04, 2020 at 09:41:09PM +0200, Miklos Szeredi wrote:
> > > 1) just leave the first explanation (it's an open + read + close
> > > equivalent) and leave out the rest
> > >
> > > 2) add a loop around the vfs_re
Al wrote:
> > On Sat, Jul 04, 2020 at 09:41:09PM +0200, Miklos Szeredi wrote:
> > 1) just leave the first explanation (it's an open + read + close
> > equivalent) and leave out the rest
> >
> > 2) add a loop around the vfs_read() in the code.
>
> 3) don't bother with the entire thing, until som
On Sat, Jul 04, 2020 at 09:12:06PM +0100, Al Viro wrote:
> On Sat, Jul 04, 2020 at 09:41:09PM +0200, Miklos Szeredi wrote:
> > And "If the size of file is smaller than the value provided in count
> > then the whole file will be copied into buf", which is simply a lie;
> > for example seq_file will
On Sat, Jul 04, 2020 at 09:41:09PM +0200, Miklos Szeredi wrote:
> And "If the size of file is smaller than the value provided in count
> then the whole file will be copied into buf", which is simply a lie;
> for example seq_file will happily return a smaller-than-PAGE_SIZE
> chunk if at least one r
On Sat, Jul 4, 2020 at 4:03 PM Greg Kroah-Hartman
wrote:
>
> It's a tiny syscall, meant to allow a user to do a single "open this
> file, read into this buffer, and close the file" all in a single shot.
>
> Should be good for reading "tiny" files like sysfs, procfs, and other
> "small" files.
>
>
On Sat, Jul 04, 2020 at 04:02:47PM +0200, Greg Kroah-Hartman wrote:
> + /* only accept a small subset of O_ flags that make sense */
> + if ((flags & (O_NOFOLLOW | O_NOATIME)) != flags)
> + return -EINVAL;
> +
> + /* add some needed flags to be able to open the file properly
Hi Greg,
On Sat, Jul 4, 2020 at 4:05 PM Greg Kroah-Hartman
wrote:
> It's a tiny syscall, meant to allow a user to do a single "open this
> file, read into this buffer, and close the file" all in a single shot.
>
> Should be good for reading "tiny" files like sysfs, procfs, and other
> "small" fil
7 matches
Mail list logo