From owner-svn-src-head@FreeBSD.ORG Wed Dec 10 20:17:41 2014 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 43F1460D; Wed, 10 Dec 2014 20:17:41 +0000 (UTC) Received: from aslan.scsiguy.com (mail.scsiguy.com [70.89.174.89]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 1D5DFD17; Wed, 10 Dec 2014 20:17:40 +0000 (UTC) Received: from [192.168.6.155] (slboulder.spectralogic.com [192.30.190.3] (may be forged)) (authenticated bits=0) by aslan.scsiguy.com (8.14.9/8.14.9) with ESMTP id sBAKHXYT060457 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Wed, 10 Dec 2014 13:17:34 -0700 (MST) (envelope-from gibbs@scsiguy.com) Content-Type: text/plain; charset=utf-8 Mime-Version: 1.0 (Mac OS X Mail 8.1 \(1993\)) Subject: Re: svn commit: r275679 - head/sys/x86/xen From: "Justin T. Gibbs" In-Reply-To: <201412101325.sBADPMgZ081973@svn.freebsd.org> Date: Wed, 10 Dec 2014 13:17:28 -0700 Content-Transfer-Encoding: quoted-printable Message-Id: References: <201412101325.sBADPMgZ081973@svn.freebsd.org> To: Roger Pau MonnXX X-Mailer: Apple Mail (2.1993) Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 10 Dec 2014 20:17:41 -0000 On Dec 10, 2014, at 6:25 AM, Roger Pau MonnXX = wrote: >=20 > Author: royger > Date: Wed Dec 10 13:25:21 2014 > New Revision: 275679 > URL: https://svnweb.freebsd.org/changeset/base/275679 >=20 > Log: > xen/intr: balance dynamic interrupts across available vCPUs >=20 > By default Xen binds all event channels to vCPU#0, and FreeBSD only = shuffles > the interrupt sources once, at the end of the boot process. Since new = event > channels might be created after this point (because new devices or = backends > are added), try to automatically shuffle them at creation time.=20 >=20 > This does not affect VIRQ or IPI event channels, that are already = bound to a > specific vCPU as requested by the caller. >=20 > Sponsored by: Citrix Systems R&D >=20 > Modified: > head/sys/x86/xen/xen_intr.c >=20 > Modified: head/sys/x86/xen/xen_intr.c > = =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D > --- head/sys/x86/xen/xen_intr.c Wed Dec 10 11:42:02 2014 = (r275678) > +++ head/sys/x86/xen/xen_intr.c Wed Dec 10 13:25:21 2014 = (r275679) > @@ -425,6 +425,17 @@ xen_intr_bind_isrc(struct xenisrc **isrc > /* Assign the opaque handler (the event channel port) */ > *port_handlep =3D &isrc->xi_port; >=20 > +#ifdef SMP > + if (type =3D=3D EVTCHN_TYPE_PORT) { > + /* > + * By default all interrupts are assigned to vCPU#0 > + * unless specified otherwise, so shuffle them to = balance > + * the interrupt load. > + */ > + xen_intr_assign_cpu(&isrc->xi_intsrc, intr_next_cpu()); > + } > +#endif > + Shouldn't this only happen for new interrupt source objects, not those = that are being reclaimed/reused? =E2=80=94 Justin=