From: Goldwyn Rodrigues <rgold...@suse.com>
RWF_NOWAIT informs kernel to bail out if an AIO request will block
for reasons such as file allocations, or a writeback triggered,
or would block while allocating requests while performing
direct I/O.
RWF_NOWAIT is translated to IOCB_NOWAIT fo
From: Goldwyn Rodrigues <rgold...@suse.com>
A new bio operation flag REQ_NOWAIT is introduced to identify bio's
orignating from iocb with IOCB_NOWAIT. This flag indicates
to return immediately if a request cannot be made instead
of retrying.
Stacked devices such as md (th
From: Goldwyn Rodrigues <rgold...@suse.com>
Find out if the write will trigger a wait due to writeback. If yes,
return -EAGAIN.
Return -EINVAL for buffered AIO: there are multiple causes of
delay such as page locks, dirty throttling logic, page loading
from disk etc. which cannot be take
From: Goldwyn Rodrigues <rgold...@suse.com>
Return EAGAIN if any of the following checks fail
+ i_rwsem is not lockable
+ NODATACOW or PREALLOC is not set
+ Cannot nocow at the desired location
+ Writing beyond end of file which is not allocated
Acked-by: David Sterba <dste...
From: Goldwyn Rodrigues <rgold...@suse.com>
aio_rw_flags is introduced in struct iocb (using aio_reserved1) which will
carry the RWF_* flags. We cannot use aio_flags because they are not
checked for validity which may break existing applications.
Note, the only place RWF_HIPRI comes in
From: Goldwyn Rodrigues <rgold...@suse.com>
Return EAGAIN if any of the following checks fail for direct I/O:
+ i_rwsem is lockable
+ Writing beyond end of file (will trigger allocation)
+ Blocks are not allocated at the write location
Signed-off-by: Goldwyn Rodrigues <rgold...
From: Goldwyn Rodrigues <rgold...@suse.com>
Reviewed-by: Christoph Hellwig <h...@lst.de>
Reviewed-by: Jan Kara <j...@suse.cz>
Signed-off-by: Goldwyn Rodrigues <rgold...@suse.com>
---
fs/read_write.c| 12 +++-
include/linux/fs.h | 14 ++
2 file
Formerly known as non-blocking AIO.
This series adds nonblocking feature to asynchronous I/O writes.
io_submit() can be delayed because of a number of reason:
- Block allocation for files
- Data writebacks for direct I/O
- Sleeping because of waiting to acquire i_rwsem
- Congested block
From: Goldwyn Rodrigues <rgold...@suse.com>
filemap_range_has_page() return true if the file's mapping has
a page within the range mentioned. This function will be used
to check if a write() call will cause a writeback of previous
writes.
Reviewed-by: Christoph Hellwig <h...@lst.de&
From: Goldwyn Rodrigues <rgold...@suse.com>
IOCB_NOWAIT translates to IOMAP_NOWAIT for iomaps.
This is used by XFS in the XFS patch.
Reviewed-by: Christoph Hellwig <h...@lst.de>
Reviewed-by: Jan Kara <j...@suse.cz>
Signed-off-by: Goldwyn Rodrigues <rgold...@suse
On 05/29/2017 03:33 AM, Christoph Hellwig wrote:
> On Sun, May 28, 2017 at 09:38:26PM -0500, Goldwyn Rodrigues wrote:
>>
>>
>> On 05/28/2017 04:31 AM, Christoph Hellwig wrote:
>>> Despite my previous reviewed-by tag this will need another fix:
>>>
>>
From: Goldwyn Rodrigues <rgold...@suse.com>
Code cleanup for better understanding:
Variable needs_unlock to be called extent_locked to show state as opposed to
action. Changed the type to int, to reduce code in the critical
path.
Signed-off-by: Goldwyn Rodrigues <rgold...@suse.com>
From: Goldwyn Rodrigues <rgold...@suse.com>
Code cleanup for better understanding:
needs_unlock to be called extent_locked to show state as opposed to
action.
Changed the variable to int, to reduce code in the critical path(code usually
executed).
Signed-off-by: Goldwyn Rodrigues
From: Goldwyn Rodrigues <rgold...@suse.com>
Signed-off-by: Goldwyn Rodrigues <rgold...@suse.com>
---
fs/btrfs/ctree.h | 2 +-
fs/btrfs/file.c | 2 +-
fs/btrfs/inode.c | 9 -
fs/btrfs/relocation.c| 2 +-
fs/btrfs/tests/inode-
EXTENT_PAGE_MAPPED gets set in set_page_extent_mapped(), but I don't see
it being cross checked anytime. What is the purpose of setting it?
--
Goldwyn
--
To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in
the body of a message to majord...@vger.kernel.org
More majordomo
From: Goldwyn Rodrigues <rgold...@suse.com>
IOMAP_F_NOBH tells iomap functions not to use or attach buffer heads
to the page. Page flush and writeback is the responsibility of the
filesystem (such as btrfs) code, which use bio to perform it.
Signed-off-by: Goldwyn Rodrigues <rgold...
From: Goldwyn Rodrigues <rgold...@suse.com>
This eliminates all page related code.
Signed-off-by: Goldwyn Rodrigues <rgold...@suse.com>
---
fs/btrfs/btrfs_inode.h | 4 +-
fs/btrfs/file.c| 488 ++---
2 files changed, 185 insert
From: Goldwyn Rodrigues <rgold...@suse.com>
We cannot perform a readpage in iomap_apply after
iomap_begin() because we have our extents locked. So,
we perform a readpage and make sure we unlock it, but
increase the page count.
Question: How do we deal with -EAGAIN retur
From: Goldwyn Rodrigues <rgold...@suse.com>
In dirty_page(), we are clearing PageChecked, though I don't see it set.
Is this used for compression only?
Can we call __set_page_dirty_nobuffers instead?
Signed-off-by: Goldwyn Rodrigues <rgold...@suse.com>
---
fs/btrfs/file.c | 8
From: Goldwyn Rodrigues <rgold...@suse.com>
This splits the generic_write_end() into functions which handle
block_write_end() and iomap_extend_page().
iomap_extend_page() performs the functions of increasing
i_size (if required) and extending pagecache.
Performed this split so we don
From: Goldwyn Rodrigues <rgold...@suse.com>
Preparatory patch. btrfs_iomap structure carries extent/page
state from iomap_begin() to iomap_end().
Signed-off-by: Goldwyn Rodrigues <rgold...@suse.com>
---
fs/btrfs/file.c | 68 ++
From: Goldwyn Rodrigues <rgold...@suse.com>
This adds prepare_pages() to iomap in order to set page directives
for the page so as FS such as btrfs may perform post-write operations
after write completes.
Can we do away with this? EXTENT_PAGE_PRIVATE is only set and not used.
However, w
From: Goldwyn Rodrigues <rgold...@suse.com>
In dirty_page(), we are clearing PageChecked, though I don't see it set.
Is this used for compression only?
Can we call __set_page_dirty_nobuffers instead?
Signed-off-by: Goldwyn Rodrigues <rgold...@suse.com>
---
fs/btrfs/file.c | 8
From: Goldwyn Rodrigues <rgold...@suse.com>
Preparatory patch. It reduces the arguments to __btrfs_buffered_write
to follow buffered_write() style.
Signed-off-by: Goldwyn Rodrigues <rgold...@suse.com>
---
fs/btrfs/file.c | 24
1 file changed, 12 inser
From: Goldwyn Rodrigues <rgold...@suse.com>
This adds prepare_pages() to iomap in order to set page directives
for the page so as FS such as btrfs may perform post-write operations
after write completes.
Can we do away with this? EXTENT_PAGE_PRIVATE is only set and not used.
However, w
This patch series attempts to use kernels iomap for btrfs. Currently,
it covers buffered writes only, but I intend to add some other iomap
uses once this gets through. I am sending this as an RFC because I
would like to find ways to improve the solution since some changes
require adding more
On 11/17/2017 12:45 PM, Nikolay Borisov wrote:
>
>
> On 17.11.2017 19:44, Goldwyn Rodrigues wrote:
>> This patch series attempts to use kernels iomap for btrfs. Currently,
>> it covers buffered writes only, but I intend to add some other iomap
>> uses once this
On 10/30/2017 09:01 AM, Nikolay Borisov wrote:
>
>
> On 30.10.2017 15:55, David Sterba wrote:
>> On Mon, Oct 30, 2017 at 03:21:51PM +0200, Nikolay Borisov wrote:
>>>
>>>
>>> On 27.10.2017 07:17, Liu Bo wrote:
>>>> On Tue, Oct
From: Goldwyn Rodrigues
struct kiocb carries the ki_pos, so there is no need to pass it as
a separate function parameter.
generic_file_direct_write() increments ki_pos, so we now assign pos
after the function.
Signed-off-by: Goldwyn Rodrigues
---
fs/btrfs/file.c | 15 ---
1 file
On 06-25 18:20, David Sterba wrote:
> On Mon, Jun 25, 2018 at 01:58:58PM +0900, Misono Tomohiro wrote:
> > So, this is the updated version of
> > https://patchwork.kernel.org/patch/10063039/
> >
> > This time xfstest is ok and
> > Reviewed-by: Misono Tomohiro
Yes, thats right.
>
> Your
On 15:03 08/10, David Sterba wrote:
> On Fri, Oct 05, 2018 at 07:26:15AM -0500, Goldwyn Rodrigues wrote:
> > Code cleanup.
>
> Have you check when and why the variable become unused? Thanks.
No, I did not check it earlier. git blame points to
312c89fbca06 ("btrfs: cleanup
Code cleanup.
Signed-off-by: Goldwyn Rodrigues
diff --git a/fs/btrfs/super.c b/fs/btrfs/super.c
index e7f702761cb7..f7b8b7a6b86a 100644
--- a/fs/btrfs/super.c
+++ b/fs/btrfs/super.c
@@ -1661,14 +1661,10 @@ static struct dentry *btrfs_mount(struct
file_system_type *fs_type, int flags
From: Goldwyn Rodrigues
Also, set the inode->i_flags to S_DAX
Signed-off-by: Goldwyn Rodrigues
---
fs/btrfs/ctree.h | 1 +
fs/btrfs/ioctl.c | 5 -
fs/btrfs/super.c | 15 +++
3 files changed, 20 insertions(+), 1 deletion(-)
diff --git a/fs/btrfs/ctree.h b/fs/btrfs/ctre
From: Goldwyn Rodrigues
Create a page size extent and copy the contents of the original
extent into the new one, and present to user space as the page
to write.
Signed-off-by: Goldwyn Rodrigues
---
fs/btrfs/dax.c | 39 +++
1 file changed, 39 insertions
From: Goldwyn Rodrigues
This is a combination of direct and buffered I/O. Similarties
with direct I/O is that it needs to allocate space before
writing. Similarities with buffered is when the data is not
page-aligned, it needs to copy parts of the previous extents. In
order to accomplish
From: Goldwyn Rodrigues
Signed-off-by: Goldwyn Rodrigues
---
fs/btrfs/dax.c | 25 -
1 file changed, 20 insertions(+), 5 deletions(-)
diff --git a/fs/btrfs/dax.c b/fs/btrfs/dax.c
index 88017f8799d1..6d68d39cc5da 100644
--- a/fs/btrfs/dax.c
+++ b/fs/btrfs/dax.c
From: Goldwyn Rodrigues
These functions are required for btrfs dax support.
Signed-off-by: Goldwyn Rodrigues
---
fs/dax.c| 35 ---
include/linux/dax.h | 16
2 files changed, 40 insertions(+), 11 deletions(-)
diff --git a/fs/dax.c b
From: Goldwyn Rodrigues
Since we will be using it in another part of the code, use a
better name to declare it non-static
Signed-off-by: Goldwyn Rodrigues
---
fs/btrfs/ctree.h | 7 +--
fs/btrfs/inode.c | 14 +-
2 files changed, 10 insertions(+), 11 deletions(-)
diff --git
From: Goldwyn Rodrigues
Signed-off-by: Goldwyn Rodrigues
---
fs/btrfs/Makefile | 1 +
fs/btrfs/ctree.h | 5
fs/btrfs/dax.c| 68 +++
fs/btrfs/file.c | 13 ++-
4 files changed, 86 insertions(+), 1 deletion(-)
create mode
From: Goldwyn Rodrigues
Signed-off-by: Goldwyn Rodrigues
---
fs/btrfs/ctree.h | 1 +
fs/btrfs/dax.c | 43 +++
fs/btrfs/file.c | 12 +++-
3 files changed, 55 insertions(+), 1 deletion(-)
diff --git a/fs/btrfs/ctree.h b/fs/btrfs/ctree.h
index
From: Goldwyn Rodrigues
This makes btrfs_get_extent_map_write() independent of Direct
I/O code.
Signed-off-by: Goldwyn Rodrigues
---
fs/btrfs/ctree.h | 2 ++
fs/btrfs/inode.c | 40 +++-
2 files changed, 29 insertions(+), 13 deletions(-)
diff --git a/fs
From: Goldwyn Rodrigues
Signed-off-by: Goldwyn Rodrigues
---
fs/btrfs/dax.c | 7 ++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/fs/btrfs/dax.c b/fs/btrfs/dax.c
index d614bf73bf8e..5a297674adec 100644
--- a/fs/btrfs/dax.c
+++ b/fs/btrfs/dax.c
@@ -54,7 +54,12 @@ ssize_t
This is a support for DAX in btrfs. I understand there have been
previous attempts at it. However, I wanted to make sure copy-on-write
(COW) works on dax as well.
Before I present this to the FS folks I wanted to run this through the
btrfs. Even though I wish, I cannot get it correct the first
On 6:52 05/12, Christoph Hellwig wrote:
> If you want to export these at all they have to be EXPORT_SYMBOL_GPL.
>
Understood.
> But I'd really like to avoid seeing another duplicate DAX I/O path.
> Please try to adopt the existing iomap-based infrastructure for your
> needs first.
This is not
On 11:07 06/12, Johannes Thumshirn wrote:
> On 05/12/2018 13:28, Goldwyn Rodrigues wrote:
> > This is a support for DAX in btrfs. I understand there have been
> > previous attempts at it. However, I wanted to make sure copy-on-write
> > (COW) works on dax as well.
>
201 - 245 of 245 matches
Mail list logo