OpenVZ Forum


Home » Mailing lists » Devel » [PATCH v2 0/5] Fix problem with static_key decrement
Re: [PATCH v2 3/5] change number_of_cpusets to an atomic [message #46043 is a reply to message #46034] Tue, 24 April 2012 02:25 Go to previous messageGo to previous message
KAMEZAWA Hiroyuki is currently offline  KAMEZAWA Hiroyuki
Messages: 463
Registered: September 2006
Senior Member
(2012/04/24 4:37), Glauber Costa wrote:

> This will allow us to call destroy() without holding the
> cgroup_mutex(). Other important updates inside update_flags()
> are protected by the callback_mutex.
>
> We could protect this variable with the callback_mutex as well,
> as suggested by Li Zefan, but we need to make sure we are protected
> by that mutex at all times, and some of its updates happen inside the
> cgroup_mutex - which means we would deadlock.
>
> An atomic variable is not expensive, since it is seldom updated,
> and protect us well.
>
> Signed-off-by: Glauber Costa <glommer@parallels.com>


Reviewed-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: [PATCH 0/3] Fix problem with static_key decrement
Next Topic: [PATCH 1/6] LockD: pass service to per-net up and down functions
Goto Forum:
  


Current Time: Wed Oct 08 12:05:37 GMT 2025

Total time taken to generate the page: 0.12566 seconds