Re: [v4.9 Regression] vfs,mm: fix a dead loop in truncate_inode_pages_range()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Dec 14, 2016 at 12:45 PM, Linus Torvalds
<torvalds@xxxxxxxxxxxxxxxxxxxx> wrote:
>
> and then look at the final part of the trace, which will look something like
>
>     lseek(0, 17592186040320, SEEK_SET)      = 17592186040320
>     read(0, 0x7ffe1d2df140, 10)             = -1 EINVAL (Invalid argument)
>     lseek(0, 17592186040319, SEEK_SET)      = 17592186040319
>     read(0, "", 10)                         = 0
>
> and that EINVAL from the first read is just bogus and wrong.

Trivially tested that yes, my suggested patch does actually fix it,
and with it you get

  lseek(0, 17592186040320, SEEK_SET)      = 17592186040320
  read(0, "", 10)                         = 0
  lseek(0, 17592186040319, SEEK_SET)      = 17592186040319
  read(0, "", 10)                         = 0

instead. Commited and pushed out, and marked for stable.

I didn't actually test the md5 case that was in the original report,
but it seems "obviously the same thing".

Famous last words.

             Linus
--
To unsubscribe from this list: send the line "unsubscribe stable" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux Kernel]     [Kernel Development Newbies]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite Hiking]     [Linux Kernel]     [Linux SCSI]