search for: smp_sync_call_struct

Displaying 16 results from an estimated 16 matches for "smp_sync_call_struct".

2016 Apr 01
2
[PATCH v3 5/6] virt, sched: add cpu pinning to smp_call_sync_on_phys_cpu()
...--- a/kernel/smp.c > +++ b/kernel/smp.c > @@ -14,6 +14,7 @@ > #include <linux/smp.h> > #include <linux/cpu.h> > #include <linux/sched.h> > +#include <linux/hypervisor.h> > > #include "smpboot.h" > > @@ -758,9 +759,14 @@ struct smp_sync_call_struct { > static void smp_call_sync_callback(struct work_struct *work) > { > struct smp_sync_call_struct *sscs; > + unsigned int cpu; > > sscs = container_of(work, struct smp_sync_call_struct, work); > + cpu = get_cpu(); > + hypervisor_pin_vcpu(cpu); > sscs->ret =...
2016 Apr 01
2
[PATCH v3 5/6] virt, sched: add cpu pinning to smp_call_sync_on_phys_cpu()
...--- a/kernel/smp.c > +++ b/kernel/smp.c > @@ -14,6 +14,7 @@ > #include <linux/smp.h> > #include <linux/cpu.h> > #include <linux/sched.h> > +#include <linux/hypervisor.h> > > #include "smpboot.h" > > @@ -758,9 +759,14 @@ struct smp_sync_call_struct { > static void smp_call_sync_callback(struct work_struct *work) > { > struct smp_sync_call_struct *sscs; > + unsigned int cpu; > > sscs = container_of(work, struct smp_sync_call_struct, work); > + cpu = get_cpu(); > + hypervisor_pin_vcpu(cpu); > sscs->ret =...
2016 Mar 21
8
[PATCH v2 0/6] Support calling functions on dedicated physical cpu
Some hardware (e.g. Dell Studio laptops) require special functions to be called on physical cpu 0 in order to avoid occasional hangs. When running as dom0 under Xen this could be achieved only via special boot parameters (vcpu pinning) limiting the hypervisor in it's scheduling decisions. This patch series is adding a generic function to be able to temporarily pin a (virtual) cpu to a
2016 Mar 21
8
[PATCH v2 0/6] Support calling functions on dedicated physical cpu
Some hardware (e.g. Dell Studio laptops) require special functions to be called on physical cpu 0 in order to avoid occasional hangs. When running as dom0 under Xen this could be achieved only via special boot parameters (vcpu pinning) limiting the hypervisor in it's scheduling decisions. This patch series is adding a generic function to be able to temporarily pin a (virtual) cpu to a
2016 Apr 01
2
[PATCH v3 5/6] virt, sched: add cpu pinning to smp_call_sync_on_phys_cpu()
...>> #include <linux/smp.h> > >> #include <linux/cpu.h> > >> #include <linux/sched.h> > >> +#include <linux/hypervisor.h> > >> > >> #include "smpboot.h" > >> > >> @@ -758,9 +759,14 @@ struct smp_sync_call_struct { > >> static void smp_call_sync_callback(struct work_struct *work) > >> { > >> struct smp_sync_call_struct *sscs; > >> + unsigned int cpu; > >> > >> sscs = container_of(work, struct smp_sync_call_struct, work); > >> + cpu = get...
2016 Apr 01
2
[PATCH v3 5/6] virt, sched: add cpu pinning to smp_call_sync_on_phys_cpu()
...>> #include <linux/smp.h> > >> #include <linux/cpu.h> > >> #include <linux/sched.h> > >> +#include <linux/hypervisor.h> > >> > >> #include "smpboot.h" > >> > >> @@ -758,9 +759,14 @@ struct smp_sync_call_struct { > >> static void smp_call_sync_callback(struct work_struct *work) > >> { > >> struct smp_sync_call_struct *sscs; > >> + unsigned int cpu; > >> > >> sscs = container_of(work, struct smp_sync_call_struct, work); > >> + cpu = get...
2016 Apr 01
0
[PATCH v3 2/6] smp: add function to execute a function synchronously on a physical cpu
...BOL_GPL(wake_up_all_idle_cpus); + +/** + * smp_call_sync_on_phys_cpu - Call a function on a specific physical cpu + * + * Used to call a function on a specific physical cpu. Even if the specified + * cpu isn't the current one, return only after the called function has + * returned. + */ +struct smp_sync_call_struct { + struct work_struct work; + struct completion done; + int (*func)(void *); + void *data; + int ret; +}; + +static void smp_call_sync_callback(struct work_struct *work) +{ + struct smp_sync_call_struct *sscs; + + sscs = container_of(work, struct smp_sync_call_struct, work); + sscs->ret =...
2016 Apr 01
8
[PATCH v3 0/6] Support calling functions on dedicated physical cpu
Some hardware (e.g. Dell Studio laptops) require special functions to be called on physical cpu 0 in order to avoid occasional hangs. When running as dom0 under Xen this could be achieved only via special boot parameters (vcpu pinning) limiting the hypervisor in it's scheduling decisions. This patch series is adding a generic function to be able to temporarily pin a (virtual) cpu to a
2016 Apr 01
8
[PATCH v3 0/6] Support calling functions on dedicated physical cpu
Some hardware (e.g. Dell Studio laptops) require special functions to be called on physical cpu 0 in order to avoid occasional hangs. When running as dom0 under Xen this could be achieved only via special boot parameters (vcpu pinning) limiting the hypervisor in it's scheduling decisions. This patch series is adding a generic function to be able to temporarily pin a (virtual) cpu to a
2016 Mar 21
1
[Xen-devel] [PATCH v2 5/6] virt, sched: add cpu pinning to smp_call_sync_on_phys_cpu()
>>> On 21.03.16 at 13:24, <JGross at suse.com> wrote: > @@ -758,9 +759,14 @@ struct smp_sync_call_struct { > static void smp_call_sync_callback(struct work_struct *work) > { > struct smp_sync_call_struct *sscs; > + unsigned int cpu = smp_processor_id(); So this obtains the vCPU number, yet ... > sscs = container_of(work, struct smp_sync_call_struct, work); > + preempt_disable...
2016 Mar 21
0
[Xen-devel] [PATCH v2 5/6] virt, sched: add cpu pinning to smp_call_sync_on_phys_cpu()
On 21/03/16 14:42, Jan Beulich wrote: >>>> On 21.03.16 at 13:24, <JGross at suse.com> wrote: >> @@ -758,9 +759,14 @@ struct smp_sync_call_struct { >> static void smp_call_sync_callback(struct work_struct *work) >> { >> struct smp_sync_call_struct *sscs; >> + unsigned int cpu = smp_processor_id(); > > So this obtains the vCPU number, yet ... > >> sscs = container_of(work, struct smp_sync_call_st...
2016 Apr 01
0
[PATCH v3 5/6] virt, sched: add cpu pinning to smp_call_sync_on_phys_cpu()
...l/smp.c >> @@ -14,6 +14,7 @@ >> #include <linux/smp.h> >> #include <linux/cpu.h> >> #include <linux/sched.h> >> +#include <linux/hypervisor.h> >> >> #include "smpboot.h" >> >> @@ -758,9 +759,14 @@ struct smp_sync_call_struct { >> static void smp_call_sync_callback(struct work_struct *work) >> { >> struct smp_sync_call_struct *sscs; >> + unsigned int cpu; >> >> sscs = container_of(work, struct smp_sync_call_struct, work); >> + cpu = get_cpu(); >> + hypervisor_pin_v...
2016 Mar 21
1
[Xen-devel] [PATCH v2 5/6] virt, sched: add cpu pinning to smp_call_sync_on_phys_cpu()
>>> On 21.03.16 at 13:24, <JGross at suse.com> wrote: > @@ -758,9 +759,14 @@ struct smp_sync_call_struct { > static void smp_call_sync_callback(struct work_struct *work) > { > struct smp_sync_call_struct *sscs; > + unsigned int cpu = smp_processor_id(); So this obtains the vCPU number, yet ... > sscs = container_of(work, struct smp_sync_call_struct, work); > + preempt_disable...
2016 Apr 01
0
[PATCH v3 5/6] virt, sched: add cpu pinning to smp_call_sync_on_phys_cpu()
...t;linux/smp.h> >>>> #include <linux/cpu.h> >>>> #include <linux/sched.h> >>>> +#include <linux/hypervisor.h> >>>> >>>> #include "smpboot.h" >>>> >>>> @@ -758,9 +759,14 @@ struct smp_sync_call_struct { >>>> static void smp_call_sync_callback(struct work_struct *work) >>>> { >>>> struct smp_sync_call_struct *sscs; >>>> + unsigned int cpu; >>>> >>>> sscs = container_of(work, struct smp_sync_call_struct, work); >&gt...
2016 Mar 21
0
[PATCH v2 5/6] virt, sched: add cpu pinning to smp_call_sync_on_phys_cpu()
...smp.c b/kernel/smp.c index 62da74b..673242b 100644 --- a/kernel/smp.c +++ b/kernel/smp.c @@ -14,6 +14,7 @@ #include <linux/smp.h> #include <linux/cpu.h> #include <linux/sched.h> +#include <linux/hypervisor.h> #include "smpboot.h" @@ -758,9 +759,14 @@ struct smp_sync_call_struct { static void smp_call_sync_callback(struct work_struct *work) { struct smp_sync_call_struct *sscs; + unsigned int cpu = smp_processor_id(); sscs = container_of(work, struct smp_sync_call_struct, work); + preempt_disable(); + hypervisor_pin_vcpu(cpu); sscs->ret = sscs->func(sscs-&gt...
2016 Apr 01
0
[PATCH v3 5/6] virt, sched: add cpu pinning to smp_call_sync_on_phys_cpu()
...smp.c b/kernel/smp.c index 62da74b..f9cfb7d 100644 --- a/kernel/smp.c +++ b/kernel/smp.c @@ -14,6 +14,7 @@ #include <linux/smp.h> #include <linux/cpu.h> #include <linux/sched.h> +#include <linux/hypervisor.h> #include "smpboot.h" @@ -758,9 +759,14 @@ struct smp_sync_call_struct { static void smp_call_sync_callback(struct work_struct *work) { struct smp_sync_call_struct *sscs; + unsigned int cpu; sscs = container_of(work, struct smp_sync_call_struct, work); + cpu = get_cpu(); + hypervisor_pin_vcpu(cpu); sscs->ret = sscs->func(sscs->data); + hypervisor_pi...