diff mbox

[GIT,PULL] ext4 bug fixes for 4.6

Message ID CA+55aFyGeZTy291E5jRkF63qBL=cRpLVw4FGzePZR7FhNUFp_w@mail.gmail.com
State New, archived
Headers show

Commit Message

Linus Torvalds April 10, 2016, 8:50 p.m. UTC
On Sun, Apr 10, 2016 at 1:48 PM, Linus Torvalds
<torvalds@linux-foundation.org> wrote:
>
> The attached patch is actually tested and seems to fix the issue.

Christ. Now really attached.

I'll just go back to bed, because today is just not working out. Maybe
things will be better tomorrow.

Or maybe I should start drinking, and at least have an excuse.

              Linus
fs/ext4/namei.c | 2 +-
 fs/readdir.c    | 2 ++
 2 files changed, 3 insertions(+), 1 deletion(-)

Comments

Theodore Y. Ts'o April 12, 2016, 1:28 a.m. UTC | #1
Linus,

Thanks for reverting the broken commit.  I'll work on a proper fix for
the readdir() issue for the next merge cycle, and make sure it gets
proper testing.

I'll also take care of packaging up Greg's test program and getting it
submitted to xfstests so we have a proper regression test case.

Cheers,

						- Ted
--
To unsubscribe from this list: send the line "unsubscribe linux-fsdevel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
diff mbox

Patch

diff --git a/fs/ext4/namei.c b/fs/ext4/namei.c
index db98f89f737f..c07422d254b6 100644
--- a/fs/ext4/namei.c
+++ b/fs/ext4/namei.c
@@ -1107,7 +1107,7 @@  int ext4_htree_fill_tree(struct file *dir_file, __u32 start_hash,
 	}
 
 	while (1) {
-		if (signal_pending(current)) {
+		if (fatal_signal_pending(current)) {
 			err = -ERESTARTSYS;
 			goto errout;
 		}
diff --git a/fs/readdir.c b/fs/readdir.c
index e69ef3b79787..2b0bb4fb8990 100644
--- a/fs/readdir.c
+++ b/fs/readdir.c
@@ -248,6 +248,8 @@  static int filldir64(struct dir_context *ctx, const char *name, int namlen,
 		return -EINVAL;
 	dirent = buf->previous;
 	if (dirent) {
+		if (signal_pending(current))
+			return -EINTR;
 		if (__put_user(offset, &dirent->d_off))
 			goto efault;
 	}