Displaying 8 results from an estimated 8 matches for "generic_write_check".
Did you mean:
generic_write_checks
2009 Jul 11
2
Initialize count in aio_write before generic_write_checks
generic_write_checks() expects count to be initialized to the size of
the write.
Writes to files open with O_DIRECT|O_LARGEFILE write 0 bytes because
count in uninitialized.
Signed-off-by: Goldwyn Rodrigues <rgoldwyn at suse.de>
diff --git a/fs/ocfs2/file.c b/fs/ocfs2/file.c
index a5887df..5b9c8af 100644
--- a...
2010 Apr 15
1
[PATCH] ocfs2: avoid direct write if we fall back to buffered v2
...cb, rw_level);
- if (direct_io) {
- ret = generic_segment_checks(iov, &nr_segs, &ocount,
- VERIFY_READ);
- if (ret)
- goto out_dio;
+ ret = generic_segment_checks(iov, &nr_segs, &ocount,
+ VERIFY_READ);
+ if (ret)
+ goto out_dio;
- count = ocount;
- ret = generic_write_checks(file, ppos, &count,
- S_ISBLK(inode->i_mode));
- if (ret)
- goto out_dio;
+ count = ocount;
+ ret = generic_write_checks(file, ppos, &count,
+ S_ISBLK(inode->i_mode));
+ if (ret)
+ goto out_dio;
+ if (direct_io) {
written = generic_file_direct_write(iocb, iov, &...
2008 Jul 03
2
iozone remove_suid oops...
...pinned[1] = NULL;
if (file->f_flags & O_DIRECT)
return -EINVAL;
pos = *ppos;
start_pos = pos;
vfs_check_frozen(inode->i_sb, SB_FREEZE_WRITE);
current->backing_dev_info = inode->i_mapping->backing_dev_info;
err = generic_write_checks(file, &pos, &count, S_ISBLK(inode->i_mode));
if (err)
goto out_nolock;
if (count == 0)
goto out_nolock;
err = remove_suid(fdentry(file)); <---
--
Daniel J Blueman
--
To unsubscribe from this list: send the line "unsubscri...
2009 Aug 11
0
[GIT PULL] ocfs2 fixes for 2.6.31-rc5
...Yinghai Lu (1):
x86: don't clear nodes_states[N_NORMAL_MEMORY] when numa is not compiled in
are available in the git repository at:
git://git.kernel.org/pub/scm/linux/kernel/git/jlbec/ocfs2.git upstream-linus
Goldwyn Rodrigues (2):
ocfs2: Initialize count in aio_write before generic_write_checks
ocfs2: Remove redundant BUG_ON in __dlm_queue_ast()
Jan Kara (9):
ocfs2: Fix deadlock on umount
ocfs2: Make global quota files blocksize aligned
ocfs2: Mark buffer uptodate before calling ocfs2_journal_access_dq()
ocfs2: Initialize blocks allocated to local quota fil...
2010 Jul 29
1
[Bug] check return of kmalloc()
...28 18:43:13.000000000 +0400
@@ -925,7 +925,6 @@ static ssize_t btrfs_file_aio_write(stru
nrptrs = min((iov_iter_count(&i) + PAGE_CACHE_SIZE - 1) /
PAGE_CACHE_SIZE, PAGE_CACHE_SIZE /
(sizeof(struct page *)));
- pages = kmalloc(nrptrs * sizeof(struct page *), GFP_KERNEL);
/* generic_write_checks can change our pos */
start_pos = pos;
--- ./fs/btrfs/inode.c 2010-07-28 08:11:33.000000000 +0400
+++ /tmp/cocci-output-7824-c1d367-inode.c 2010-07-28 18:43:15.000000000 +0400
@@ -284,7 +284,6 @@ static noinline int add_async_extent(str
{
struct async_extent *async_extent;
- async_extent =...
2013 Jul 25
0
[PATCH V8 21/33] ocfs2: add support for read_iter and write_iter
...n 0;
@@ -2343,28 +2341,24 @@ relock:
/* communicate with ocfs2_dio_end_io */
ocfs2_iocb_set_rw_locked(iocb, rw_level);
- ret = generic_segment_checks(iov, &nr_segs, &ocount,
- VERIFY_READ);
- if (ret)
- goto out_dio;
- count = ocount;
+ count = iov_iter_count(iter);
ret = generic_write_checks(file, ppos, &count,
S_ISBLK(inode->i_mode));
if (ret)
goto out_dio;
if (direct_io) {
- written = generic_file_direct_write(iocb, iov, &nr_segs, *ppos,
- ppos, count, ocount);
+ written = generic_file_direct_write_iter(iocb, iter, *ppos,
+ ppos, count...
2013 Jan 09
0
[PATCH V5 19/30] ocfs2: add support for read_iter, write_iter, and direct_IO_bvec
...n 0;
@@ -2344,28 +2342,24 @@ relock:
/* communicate with ocfs2_dio_end_io */
ocfs2_iocb_set_rw_locked(iocb, rw_level);
- ret = generic_segment_checks(iov, &nr_segs, &ocount,
- VERIFY_READ);
- if (ret)
- goto out_dio;
- count = ocount;
+ count = iov_iter_count(iter);
ret = generic_write_checks(file, ppos, &count,
S_ISBLK(inode->i_mode));
if (ret)
goto out_dio;
if (direct_io) {
- written = generic_file_direct_write(iocb, iov, &nr_segs, *ppos,
- ppos, count, ocount);
+ written = generic_file_direct_write_iter(iocb, iter, *ppos,
+ ppos, count...
2010 May 07
6
[PATCH 1/5] fs: allow short direct-io reads to be completed via buffered IO V2
V1->V2: Check to see if our current ppos is >= i_size after a short DIO read,
just in case it was actually a short read and we need to just return.
This is similar to what already happens in the write case. If we have a short
read while doing O_DIRECT, instead of just returning, fallthrough and try to
read the rest via buffered IO. BTRFS needs this because if we encounter a
compressed or