Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755884AbcCUNnF (ORCPT ); Mon, 21 Mar 2016 09:43:05 -0400 Received: from prv-mh.provo.novell.com ([137.65.248.74]:58206 "EHLO prv-mh.provo.novell.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755669AbcCUNnD convert rfc822-to-8bit (ORCPT ); Mon, 21 Mar 2016 09:43:03 -0400 Message-Id: <56F0087202000078000DED9F@prv-mh.provo.novell.com> X-Mailer: Novell GroupWise Internet Agent 14.2.0 Date: Mon, 21 Mar 2016 07:42:58 -0600 From: "Jan Beulich" To: "Juergen Gross" Cc: , , , , , , , , , , , , , , "Jean Delvare" , , , Subject: Re: [Xen-devel] [PATCH v2 5/6] virt, sched: add cpu pinning to smp_call_sync_on_phys_cpu() References: <1458563075-30298-1-git-send-email-jgross@suse.com> <1458563075-30298-6-git-send-email-jgross@suse.com> In-Reply-To: <1458563075-30298-6-git-send-email-jgross@suse.com> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 8BIT Content-Disposition: inline Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 544 Lines: 18 >>> On 21.03.16 at 13:24, 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(); > + hypervisor_pin_vcpu(cpu); ... here you're supposed to pass a pCPU number. Also don't you need to call smp_processor_id() after preempt_disable()? Jan