[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-devel] [PATCH 6/6] x86/smt: Don't use -EBUSY for smt_up_down_helper() continuations
Tasklet context is now capable of using handling continuations. Use this rather than -EBUSY as it is a more efficient way to restart the hypercall. Signed-off-by: Andrew Cooper <andrew.cooper3@xxxxxxxxxx> --- CC: Jan Beulich <JBeulich@xxxxxxxx> CC: Wei Liu <wl@xxxxxxx> CC: Roger Pau Monné <roger.pau@xxxxxxxxxx> --- xen/arch/x86/sysctl.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/xen/arch/x86/sysctl.c b/xen/arch/x86/sysctl.c index 4a76f0f47f..06955fdc3e 100644 --- a/xen/arch/x86/sysctl.c +++ b/xen/arch/x86/sysctl.c @@ -85,6 +85,9 @@ long cpu_up_helper(void *data) /* On EBUSY, flush RCU work and have one more go. */ rcu_barrier(); ret = cpu_up(cpu); + + if ( ret == -EBUSY ) + ret = -ERESTART; } if ( !ret && !opt_smt && @@ -110,6 +113,9 @@ long cpu_down_helper(void *data) /* On EBUSY, flush RCU work and have one more go. */ rcu_barrier(); ret = cpu_down(cpu); + + if ( ret == -EBUSY ) + ret = -ERESTART; } return ret; } @@ -143,8 +149,7 @@ static long smt_up_down_helper(void *data) */ if ( ret != -EEXIST && general_preempt_check() ) { - /* In tasklet context - can't create a contination. */ - ret = -EBUSY; + ret = -ERESTART; break; } -- 2.11.0 _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxxxxxxxxx https://lists.xenproject.org/mailman/listinfo/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |