Re: [PATCH v2 15/45] rcu: Use get/put_online_cpus_atomic() to prevent CPU offline

2013-06-27 Thread Srivatsa S. Bhat
On 06/27/2013 02:24 PM, David Laight wrote: > It would also increase the latency of CPU-hotunplug operations. Is that a big deal? >>> >>> I thought that was the whole deal with this patchset - making cpu >>> hotunplugs lighter and faster mostly for powersaving. That said, just >>> re

RE: [PATCH v2 15/45] rcu: Use get/put_online_cpus_atomic() to prevent CPU offline

2013-06-27 Thread David Laight
> >>> It would also increase the latency of CPU-hotunplug operations. > >> > >> Is that a big deal? > > > > I thought that was the whole deal with this patchset - making cpu > > hotunplugs lighter and faster mostly for powersaving. That said, just > > removing stop_machine call would be a pretty g

Re: [PATCH v2 15/45] rcu: Use get/put_online_cpus_atomic() to prevent CPU offline

2013-06-26 Thread Srivatsa S. Bhat
On 06/27/2013 03:04 AM, Tejun Heo wrote: > Hey, > > On Wed, Jun 26, 2013 at 11:58:48PM +0530, Srivatsa S. Bhat wrote: >> Yes, we were discussing hot-unplug latency for use-cases such as >> suspend/resume. We didn't want to make those operations slower in the >> process of removing stop_machine() f

Re: [PATCH v2 15/45] rcu: Use get/put_online_cpus_atomic() to prevent CPU offline

2013-06-26 Thread Tejun Heo
Hey, On Wed, Jun 26, 2013 at 11:58:48PM +0530, Srivatsa S. Bhat wrote: > Yes, we were discussing hot-unplug latency for use-cases such as > suspend/resume. We didn't want to make those operations slower in the > process of removing stop_machine() from hotplug. Can you please explain why tho? How

Re: [PATCH v2 15/45] rcu: Use get/put_online_cpus_atomic() to prevent CPU offline

2013-06-26 Thread Srivatsa S. Bhat
On 06/26/2013 10:59 PM, Tejun Heo wrote: > Hello, > > On Wed, Jun 26, 2013 at 11:33:43AM -0400, Steven Rostedt wrote: >> I thought the whole deal with this patchset was to remove stop_machine >> from CPU hotplug. Why halt all CPUs just to remove one? stomp_machine() >> is extremely intrusive for t

Re: [PATCH v2 15/45] rcu: Use get/put_online_cpus_atomic() to prevent CPU offline

2013-06-26 Thread Srivatsa S. Bhat
On 06/26/2013 08:51 PM, Tejun Heo wrote: > On Wed, Jun 26, 2013 at 10:51:11AM -0400, Steven Rostedt wrote: >>> It would also increase the latency of CPU-hotunplug operations. >> >> Is that a big deal? > > I thought that was the whole deal with this patchset - making cpu > hotunplugs lighter and fa

Re: [PATCH v2 15/45] rcu: Use get/put_online_cpus_atomic() to prevent CPU offline

2013-06-26 Thread Srivatsa S. Bhat
On 06/26/2013 07:59 PM, David Laight wrote: >> Once stop_machine() is gone from the CPU offline path, we won't be able >> to depend on disabling preemption to prevent CPUs from going offline >> from under us. > > Could you use an rcu-like sequence so that disabling pre-emption > would be enough? >

Re: [PATCH v2 15/45] rcu: Use get/put_online_cpus_atomic() to prevent CPU offline

2013-06-26 Thread Tejun Heo
Hello, On Wed, Jun 26, 2013 at 11:33:43AM -0400, Steven Rostedt wrote: > I thought the whole deal with this patchset was to remove stop_machine > from CPU hotplug. Why halt all CPUs just to remove one? stomp_machine() > is extremely intrusive for the entire system, where as one CPU making > sure a

Re: [PATCH v2 15/45] rcu: Use get/put_online_cpus_atomic() to prevent CPU offline

2013-06-26 Thread Steven Rostedt
On Wed, 2013-06-26 at 08:21 -0700, Tejun Heo wrote: > On Wed, Jun 26, 2013 at 10:51:11AM -0400, Steven Rostedt wrote: > > > It would also increase the latency of CPU-hotunplug operations. > > > > Is that a big deal? > > I thought that was the whole deal with this patchset - making cpu > hotunplug

Re: [PATCH v2 15/45] rcu: Use get/put_online_cpus_atomic() to prevent CPU offline

2013-06-26 Thread Tejun Heo
On Wed, Jun 26, 2013 at 10:51:11AM -0400, Steven Rostedt wrote: > > It would also increase the latency of CPU-hotunplug operations. > > Is that a big deal? I thought that was the whole deal with this patchset - making cpu hotunplugs lighter and faster mostly for powersaving. That said, just remo

Re: [PATCH v2 15/45] rcu: Use get/put_online_cpus_atomic() to prevent CPU offline

2013-06-26 Thread Steven Rostedt
On Wed, 2013-06-26 at 07:34 -0700, Paul E. McKenney wrote: > On Wed, Jun 26, 2013 at 03:29:40PM +0100, David Laight wrote: > > > Once stop_machine() is gone from the CPU offline path, we won't be able > > > to depend on disabling preemption to prevent CPUs from going offline > > > from under us. >

Re: [PATCH v2 15/45] rcu: Use get/put_online_cpus_atomic() to prevent CPU offline

2013-06-26 Thread Paul E. McKenney
On Wed, Jun 26, 2013 at 03:29:40PM +0100, David Laight wrote: > > Once stop_machine() is gone from the CPU offline path, we won't be able > > to depend on disabling preemption to prevent CPUs from going offline > > from under us. > > Could you use an rcu-like sequence so that disabling pre-emption

Re: [PATCH v2 15/45] rcu: Use get/put_online_cpus_atomic() to prevent CPU offline

2013-06-26 Thread Paul E. McKenney
On Wed, Jun 26, 2013 at 07:39:40PM +0530, Srivatsa S. Bhat wrote: > On 06/26/2013 03:30 AM, Paul E. McKenney wrote: > > On Wed, Jun 26, 2013 at 01:57:55AM +0530, Srivatsa S. Bhat wrote: > >> Once stop_machine() is gone from the CPU offline path, we won't be able > >> to depend on disabling preempti

Re: [PATCH v2 15/45] rcu: Use get/put_online_cpus_atomic() to prevent CPU offline

2013-06-26 Thread Paul E. McKenney
On Wed, Jun 26, 2013 at 03:29:40PM +0100, David Laight wrote: > > Once stop_machine() is gone from the CPU offline path, we won't be able > > to depend on disabling preemption to prevent CPUs from going offline > > from under us. > > Could you use an rcu-like sequence so that disabling pre-emption

RE: [PATCH v2 15/45] rcu: Use get/put_online_cpus_atomic() to prevent CPU offline

2013-06-26 Thread David Laight
> Once stop_machine() is gone from the CPU offline path, we won't be able > to depend on disabling preemption to prevent CPUs from going offline > from under us. Could you use an rcu-like sequence so that disabling pre-emption would be enough? Something like rebuilding the cpu list, then forcing

Re: [PATCH v2 15/45] rcu: Use get/put_online_cpus_atomic() to prevent CPU offline

2013-06-26 Thread Srivatsa S. Bhat
On 06/26/2013 03:30 AM, Paul E. McKenney wrote: > On Wed, Jun 26, 2013 at 01:57:55AM +0530, Srivatsa S. Bhat wrote: >> Once stop_machine() is gone from the CPU offline path, we won't be able >> to depend on disabling preemption to prevent CPUs from going offline >> from under us. >> >> In RCU code,

Re: [PATCH v2 15/45] rcu: Use get/put_online_cpus_atomic() to prevent CPU offline

2013-06-25 Thread Paul E. McKenney
On Wed, Jun 26, 2013 at 01:57:55AM +0530, Srivatsa S. Bhat wrote: > Once stop_machine() is gone from the CPU offline path, we won't be able > to depend on disabling preemption to prevent CPUs from going offline > from under us. > > In RCU code, rcu_implicit_dynticks_qs() checks if a CPU is offline

[PATCH v2 15/45] rcu: Use get/put_online_cpus_atomic() to prevent CPU offline

2013-06-25 Thread Srivatsa S. Bhat
Once stop_machine() is gone from the CPU offline path, we won't be able to depend on disabling preemption to prevent CPUs from going offline from under us. In RCU code, rcu_implicit_dynticks_qs() checks if a CPU is offline, while being protected by a spinlock. Use the get/put_online_cpus_atomic()