Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1275080
| From | Sergey Senozhatsky <sergey.senozhatsky.work@gmail.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH v2] zram: Prevent page allocation failure during zcomp_strm_alloc |
| Date | 2015-11-23 08:50 +0100 |
| Message-ID | <qxU2R-7ds-11@gated-at.bofh.it> (permalink) |
| References | <qxQLD-5bV-5@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On (11/23/15 13:18), Minchan Kim wrote: [..] > > https://lkml.org/lkml/2015/6/16/465 > > Sorry, I have missed that. > It's worth to fix that you proved it that could happen. > But when I read your patch, GFP_NOIO instead GFP_NOFS would > better way. Could you resend it? no problem. agree. we also would want to switch from vzalloc() to __vmalloc_node_flags(size, NUMA_NO_NODE, GFP_NOIO | __GFP_HIGHMEM | __GFP_ZERO) in fallbacks. I'll send the patch later today. > > > > > If it is true, we should fix several allocation flags in > > > zcomp_strm_alloc. I just want to record this warning for the future > > > in this thread so someone who is finding for the contribution > > > material will prove and fix it. :) > > > > I can re-send the patch. > > > > And, in case if you missed it, what's your opinion on the idea of > > reducing ->max_strm if we can't allocate new streams. Here: > > http://marc.info/?l=linux-kernel&m=144798049429861 > > Hmm, auto backoff max_comp_streams with warn to user, I'm not sure > we really need it. Alloc failure is depenent on the workload and > timing so although there are a fail in t1, it could be successful > in t2 so if we *really* want to introduce auto backoff, the logic > should include advance routine as well as backoff. With that, > I want to handle it traparently without notice to user. yes. auto roll-back is important (that's why I mentioned it). the idea is to avoid stealing of pages for streams. for example, in case of low memory decrease ->max_strm to MAX(->avail_strm, ->max_strm, online cpus() / 2) and even probably release some idle streams (um... as a reaction to shrinker call???). or at least prevent setting of ->max_sgtrm to some unreasonably huge values... "> 4 * NR_CPUS", for instance. but this is not so critical. > So, Kyeongdon's patch will remove warning overhead and likely to > make zcomp_stram_alloc successful with vmalloc so I want to > roll it out first. And let's add a WARN_ON_ONCE to detect of > failure and rethink it when we receive such report. -ss -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Re: [PATCH v2] zram: Prevent page allocation failure during zcomp_strm_alloc Minchan Kim <minchan@kernel.org> - 2015-11-23 05:20 +0100
Re: [PATCH v2] zram: Prevent page allocation failure during zcomp_strm_alloc Sergey Senozhatsky <sergey.senozhatsky.work@gmail.com> - 2015-11-23 08:50 +0100
Re: [PATCH v2] zram: Prevent page allocation failure during zcomp_strm_alloc Sergey Senozhatsky <sergey.senozhatsky.work@gmail.com> - 2015-11-23 09:20 +0100
csiph-web