linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/2] shmem: fix faulting into a hole while it's punched, take 3
@ 2014-07-15 10:28 Hugh Dickins
  2014-07-15 10:31 ` [PATCH 1/2] shmem: fix faulting into a hole, not taking i_mutex Hugh Dickins
                   ` (2 more replies)
  0 siblings, 3 replies; 21+ messages in thread
From: Hugh Dickins @ 2014-07-15 10:28 UTC (permalink / raw)
  To: Andrew Morton
  Cc: Sasha Levin, Vlastimil Babka, Konstantin Khlebnikov,
	Johannes Weiner, Michel Lespinasse, Lukas Czerner, Dave Jones,
	linux-mm, linux-fsdevel, linux-kernel

Hi Andrew,

Here's my latest and hopefully last stab at fixing the trinity
hole-punch starvation issue that became known as CVE-2014-4171.

You may prefer to hear a testing update from Sasha and Vlastimil before
paying any attention to these, or you may prefer to add them into mmotm
for wider testing now: whichever you think appropriate.

Please throw away mmotm's
revert-shmem-fix-faulting-into-a-hole-while-its-punched.patch
and replace it by 1/2, which fixes that commit instead of reverting it.

Please throw away mmotm's
shmem-fix-faulting-into-a-hole-while-its-punched-take-2.patch
and replace it by 2/2, which reworks the commit message and adds a fix.

Please keep the 3/3 I sent last time in mmotm
mm-fs-fix-pessimization-in-hole-punching-pagecache.patch
which remains valid.

In the end I decided that we had better look at it as two problems,
the trinity faulting starvation, and the indefinite punching loop,
so 1/2 and 2/2 present both solutions: belt and braces.

Which may be the best for fixing, but the worst for ease of backporting.
Vlastimil, I have prepared (and lightly tested) a 3.2.61-based version
of the combination of f00cdc6df7d7 and 1/2 and 2/2 (basically, I moved
vmtruncate_range from mm/truncate.c to mm/shmem.c, since nothing but
shmem ever implemented the truncate_range method).  It should give a
good hint for backports earlier and later: I'll send it privately to
you now, but keep in mind that it may need to be revised if today's
patches for 3.16 get revised again (I'll send it to Ben Hutchings
only when that's settled).

Thanks,
Hugh

^ permalink raw reply	[flat|nested] 21+ messages in thread

end of thread, other threads:[~2014-07-25 14:33 UTC | newest]

Thread overview: 21+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-07-15 10:28 [PATCH 0/2] shmem: fix faulting into a hole while it's punched, take 3 Hugh Dickins
2014-07-15 10:31 ` [PATCH 1/2] shmem: fix faulting into a hole, not taking i_mutex Hugh Dickins
2014-07-15 16:07   ` Vlastimil Babka
2014-07-15 19:26     ` Hugh Dickins
2014-07-16  7:18       ` Vlastimil Babka
2014-07-25 14:25   ` Michal Hocko
2014-07-15 10:33 ` [PATCH 2/2] shmem: fix splicing from a hole while it's punched Hugh Dickins
2014-07-25 14:33   ` Michal Hocko
2014-07-17 16:10 ` [PATCH 0/2] shmem: fix faulting into a hole while it's punched, take 3 Vlastimil Babka
2014-07-17 16:12   ` Sasha Levin
2014-07-18 10:44     ` Sasha Levin
2014-07-19 23:44       ` Hugh Dickins
2014-07-22  3:24         ` Sasha Levin
2014-07-22  8:07           ` Hugh Dickins
2014-07-22 10:06             ` Vlastimil Babka
2014-07-22 12:09               ` Vlastimil Babka
2014-07-22 18:42                 ` Hugh Dickins
2014-07-22 23:19             ` Sasha Levin
2014-07-22 23:58               ` Hugh Dickins
2014-07-17 23:34   ` Hugh Dickins
2014-07-18  8:05     ` Vlastimil Babka

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).