login
Login
/
Register
Search
Search this site:
Forums
News
Blogs
Features
Site
Home
»
Mailing list archives
»
linux-kernel
»
2010
»
October
»
18
Re: Deadlock possibly caused by too_many_isolated.
view
thread
Previous message: [
thread
] [
date
] [
author
]
Next message: [
thread
] [
date
] [
author
]
[view in full thread]
From: KOSAKI Motohiro
Subject:
Re: Deadlock possibly caused by too_many_isolated.
Date: Sunday, October 17, 2010 - 10:04 pm
> On Wed, 15 Sep 2010 18:44:34 +1000
quoted text
> Neil Brown <neilb@suse.de> wrote: > > > On Wed, 15 Sep 2010 16:28:43 +0800 > > Wu Fengguang <fengguang.wu@intel.com> wrote: > > > > > Neil, > > > > > > Sorry for the rushed and imaginary ideas this morning.. > > > > > > > @@ -1101,6 +1101,12 @@ static unsigned long shrink_inactive_lis > > > > int lumpy_reclaim = 0; > > > > > > > > while (unlikely(too_many_isolated(zone, file, sc))) { > > > > + if ((sc->gfp_mask & GFP_IOFS) != GFP_IOFS) > > > > + /* Not allowed to do IO, so mustn't wait > > > > + * on processes that might try to > > > > + */ > > > > + return SWAP_CLUSTER_MAX; > > > > + > > > > > > The above patch should behavior like this: it returns SWAP_CLUSTER_MAX > > > to cheat all the way up to believe "enough pages have been reclaimed". > > > So __alloc_pages_direct_reclaim() see non-zero *did_some_progress and > > > go on to call get_page_from_freelist(). That normally fails because > > > the task didn't really scanned the LRU lists. However it does have the > > > possibility to succeed -- when so many processes are doing concurrent > > > direct reclaims, it may luckily get one free page reclaimed by other > > > tasks. What's more, if it does fail to get a free page, the upper > > > layer __alloc_pages_slowpath() will be repeat recalling > > > __alloc_pages_direct_reclaim(). So, sooner or later it will succeed in > > > "stealing" a free page reclaimed by other tasks. > > > > > > In summary, the patch behavior for !__GFP_IO/FS is > > > - won't do any page reclaim > > > - won't fail the page allocation (unexpected) > > > - will wait and steal one free page from others (unreasonable) > > > > > > So it will address the problem you encountered, however it sounds > > > pretty unexpected and illogical behavior, right? > > > > > > I believe this patch will address the problem equally well. > > > What do you think? > > > > Thank you for the detailed explanation. Is agree with your reasoning and > > now understand why your patch is sufficient. > > > > I will get it tested and let you know how that goes. > > (sorry this has taken a month to follow up). > > Testing shows that this patch seems to work. > The test load (essentially kernbench) doesn't deadlock any more, though it > does get bogged down thrashing in swap so it doesn't make a lot more > progress :-) I guess that is to be expected. > > One observation is that the kernbench generated 10%-20% more context switches > with the patch than without. Is that to be expected? > > Do you have plans for sending this patch upstream?
Wow, I had thought this patch has been merged already. Wu, can you please repost this one? and please add my and Neil's ack tag. Thanks. --
unsubscribe notice
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/
Previous message: [
thread
] [
date
] [
author
]
Next message: [
thread
] [
date
] [
author
]
Messages in current thread:
Deadlock possibly caused by too_many_isolated.
, Neil Brown
, (Tue Sep 14, 4:11 pm)
Re: Deadlock possibly caused by too_many_isolated.
, Rik van Riel
, (Tue Sep 14, 5:30 pm)
Re: Deadlock possibly caused by too_many_isolated.
, Neil Brown
, (Tue Sep 14, 7:23 pm)
Re: Deadlock possibly caused by too_many_isolated.
, Wu Fengguang
, (Tue Sep 14, 7:37 pm)
Re: Deadlock possibly caused by too_many_isolated.
, Wu Fengguang
, (Tue Sep 14, 7:54 pm)
Re: Deadlock possibly caused by too_many_isolated.
, Wu Fengguang
, (Tue Sep 14, 8:06 pm)
Re: Deadlock possibly caused by too_many_isolated.
, Wu Fengguang
, (Tue Sep 14, 8:13 pm)
Re: Deadlock possibly caused by too_many_isolated.
, Neil Brown
, (Tue Sep 14, 8:17 pm)
Re: Deadlock possibly caused by too_many_isolated.
, Shaohua Li
, (Tue Sep 14, 8:18 pm)
Re: Deadlock possibly caused by too_many_isolated.
, Wu Fengguang
, (Tue Sep 14, 8:31 pm)
Re: Deadlock possibly caused by too_many_isolated.
, Wu Fengguang
, (Tue Sep 14, 8:47 pm)
Re: Deadlock possibly caused by too_many_isolated.
, Wu Fengguang
, (Wed Sep 15, 1:28 am)
Re: Deadlock possibly caused by too_many_isolated.
, Neil Brown
, (Wed Sep 15, 1:44 am)
Re: Deadlock possibly caused by too_many_isolated.
, Neil Brown
, (Sun Oct 17, 9:14 pm)
Re: Deadlock possibly caused by too_many_isolated.
, KOSAKI Motohiro
, (Sun Oct 17, 10:04 pm)
Re: Deadlock possibly caused by too_many_isolated.
, Torsten Kaiser
, (Mon Oct 18, 3:58 am)
Re: Deadlock possibly caused by too_many_isolated.
, Wu Fengguang
, (Mon Oct 18, 9:15 am)
Re: Deadlock possibly caused by too_many_isolated.
, Andrew Morton
, (Mon Oct 18, 2:58 pm)
Re: Deadlock possibly caused by too_many_isolated.
, Neil Brown
, (Mon Oct 18, 3:31 pm)
Re: Deadlock possibly caused by too_many_isolated.
, Andrew Morton
, (Mon Oct 18, 3:41 pm)
Re: Deadlock possibly caused by too_many_isolated.
, Neil Brown
, (Mon Oct 18, 4:11 pm)
Re: Deadlock possibly caused by too_many_isolated.
, KOSAKI Motohiro
, (Mon Oct 18, 5:57 pm)
Re: Deadlock possibly caused by too_many_isolated.
, Minchan Kim
, (Mon Oct 18, 6:15 pm)
Re: Deadlock possibly caused by too_many_isolated.
, KOSAKI Motohiro
, (Mon Oct 18, 6:21 pm)
Re: Deadlock possibly caused by too_many_isolated.
, Minchan Kim
, (Mon Oct 18, 6:32 pm)
Re: Deadlock possibly caused by too_many_isolated.
, KOSAKI Motohiro
, (Mon Oct 18, 7:03 pm)
Re: Deadlock possibly caused by too_many_isolated.
, Minchan Kim
, (Mon Oct 18, 7:16 pm)
Re: Deadlock possibly caused by too_many_isolated.
, Wu Fengguang
, (Mon Oct 18, 7:24 pm)
Re: Deadlock possibly caused by too_many_isolated.
, Wu Fengguang
, (Mon Oct 18, 7:35 pm)
Re: Deadlock possibly caused by too_many_isolated.
, KOSAKI Motohiro
, (Mon Oct 18, 7:37 pm)
Re: Deadlock possibly caused by too_many_isolated.
, Minchan Kim
, (Mon Oct 18, 7:37 pm)
Re: Deadlock possibly caused by too_many_isolated.
, Minchan Kim
, (Mon Oct 18, 7:52 pm)
Re: Deadlock possibly caused by too_many_isolated.
, KOSAKI Motohiro
, (Mon Oct 18, 7:54 pm)
Re: Deadlock possibly caused by too_many_isolated.
, Wu Fengguang
, (Mon Oct 18, 8:05 pm)
Re: Deadlock possibly caused by too_many_isolated.
, Minchan Kim
, (Mon Oct 18, 8:09 pm)
Re: Deadlock possibly caused by too_many_isolated.
, KOSAKI Motohiro
, (Mon Oct 18, 8:13 pm)
Re: Deadlock possibly caused by too_many_isolated.
, Shaohua Li
, (Mon Oct 18, 8:21 pm)
Re: Deadlock possibly caused by too_many_isolated.
, Minchan Kim
, (Mon Oct 18, 10:11 pm)
Re: Deadlock possibly caused by too_many_isolated.
, Shaohua Li
, (Tue Oct 19, 12:15 am)
Re: Deadlock possibly caused by too_many_isolated.
, Minchan Kim
, (Tue Oct 19, 12:34 am)
Re: Deadlock possibly caused by too_many_isolated.
, Torsten Kaiser
, (Tue Oct 19, 1:43 am)
Re: Deadlock possibly caused by too_many_isolated.
, Torsten Kaiser
, (Tue Oct 19, 3:06 am)
Re: Deadlock possibly caused by too_many_isolated.
, Wu Fengguang
, (Tue Oct 19, 10:57 pm)
Re: Deadlock possibly caused by too_many_isolated.
, KOSAKI Motohiro
, (Wed Oct 20, 12:05 am)
Re: Deadlock possibly caused by too_many_isolated.
, Torsten Kaiser
, (Wed Oct 20, 12:25 am)
Re: Deadlock possibly caused by too_many_isolated.
, Wu Fengguang
, (Wed Oct 20, 2:01 am)
Re: Deadlock possibly caused by too_many_isolated.
, Wu Fengguang
, (Wed Oct 20, 2:27 am)
Re: Deadlock possibly caused by too_many_isolated.
, Torsten Kaiser
, (Wed Oct 20, 3:07 am)
Re: Deadlock possibly caused by too_many_isolated.
, Jens Axboe
, (Wed Oct 20, 6:03 am)
Re: Deadlock possibly caused by too_many_isolated.
, Minchan Kim
, (Wed Oct 20, 7:23 am)
Re: Deadlock possibly caused by too_many_isolated.
, Torsten Kaiser
, (Wed Oct 20, 8:35 am)
Re: Deadlock possibly caused by too_many_isolated.
, Minchan Kim
, (Wed Oct 20, 4:31 pm)
Re: Deadlock possibly caused by too_many_isolated.
, Wu Fengguang
, (Thu Oct 21, 10:37 pm)
Re: Deadlock possibly caused by too_many_isolated.
, Wu Fengguang
, (Fri Oct 22, 1:07 am)
Re: Deadlock possibly caused by too_many_isolated.
, Jens Axboe
, (Fri Oct 22, 1:09 am)
Re: Deadlock possibly caused by too_many_isolated.
, Wu Fengguang
, (Sun Oct 24, 9:52 am)
Re: Deadlock possibly caused by too_many_isolated.
, Neil Brown
, (Sun Oct 24, 11:40 pm)
Re: Deadlock possibly caused by too_many_isolated.
, Wu Fengguang
, (Mon Oct 25, 12:26 am)
Navigation
Mailing list archives
Recent posts
Popular discussions
linux-kernel
:
Greg KH
Og dreams of kernels
Jens Axboe
[PATCH 31/33] Fusion: sg chaining support
Arnd Bergmann
Re: finding your own dead "CONFIG_" variables
Mark Brown
[PATCH 2/2] Subject: natsemi: Allow users to disable workaround for DspCfg reset
Tony Breeds
[LGUEST] Look in object dir for .config
git
:
Brian Downing
Re: Git in a Nutshell guide
John Benes
Re: master has some toys
Matthias Lederhofer
[PATCH 4/7] introduce GIT_WORK_TREE to specify the work tree
Alexander Sulfrian
[RFC/PATCH] RE: git calls SSH_ASKPASS even if DISPLAY is not set
Junio C Hamano
Re: Rss produced by git is not valid xml?
git-commits-head
:
Linux Kernel Mailing List
iSeries: fix section mismatch in iseries_veth
Linux Kernel Mailing List
ixbge: remove TX lock and redo TX accounting.
Linux Kernel Mailing List
ixgbe: fix several counter register errata
Linux Kernel Mailing List
b43: fix build with CONFIG_SSB_PCIHOST=n
Linux Kernel Mailing List
9p: block-based virtio client
linux-netdev
:
Michael Breuer
Re: [PATCH] af_packet: Don't use skb after dev_queue_xmit()
Michael Breuer
Re: [PATCH] af_packet: Don't use skb after dev_queue_xmit()
David Daney
[PATCH 5/7] Staging: Octeon Ethernet: Convert to NAPI.
Wolfgang Grandegger
[PATCH net-next v4 1/3] can: mscan: fix improper return if dlc < 8 in start_xmi...
Amit Kumar Salecha
[PATCHv3 NEXT 2/2] NET: Add Qlogic ethernet driver for CNA devices
openbsd-misc
:
Theo de Raadt
Re: Old IPSEC bug
Tomáš Bodžár
Problem with vpnc connection - check group password !
Insan Praja SW
Mandoc Compiling Error
Carl Roberso
Re: Cannot change MTU of carp interface?
Richard Daemon
Re: booting openbsd on eee without cd-rom
Colocation donated by:
Syndicate