From mboxrd@z Thu Jan 1 00:00:00 1970 From: Stefan Bader Subject: Re: Question about apic ipi interface Date: Tue, 23 Apr 2013 14:23:41 +0200 Message-ID: <51767D4D.40308@canonical.com> References: <51765D56.1000906@canonical.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============4118031089509786110==" Return-path: In-Reply-To: List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Ben Guthro Cc: Lin Ming , "xen-devel@lists.xensource.com" , Konrad Rzeszutek Wilk List-Id: xen-devel@lists.xenproject.org This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --===============4118031089509786110== Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="------------enig565F9CBC6A47A4BB6C77E941" This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enig565F9CBC6A47A4BB6C77E941 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable On 23.04.2013 14:15, Ben Guthro wrote: > On Tue, Apr 23, 2013 at 11:07 AM, Stefan Bader > wrote: >> I was looking at some older patch and there is one thing I do not unde= rstand. >> >> commit f447d56d36af18c5104ff29dcb1327c0c0ac3634 >> xen: implement apic ipi interface >> >> Specifically there the implementation of xen_send_IPI_mask_allbutself(= ). >> >> void xen_send_IPI_mask_allbutself(const struct cpumask *mask, >> int vector) >> { >> unsigned cpu; >> unsigned int this_cpu =3D smp_processor_id(); >> >> if (!(num_online_cpus() > 1)) >> return; >> >> for_each_cpu_and(cpu, mask, cpu_online_mask) { >> if (this_cpu =3D=3D cpu) >> continue; >> >> xen_smp_send_call_function_single_ipi(cpu); >> } >> } >> >> Why is this using xen_smp_send_call_function_single_ipi()? This dumps = the >> supplied vector and always uses XEN_CALL_FUNCTION_SINGLE_VECTOR. In co= ntrast the >> xen_send_IPI_all() and xen_send_IPI_self() keep the (mapped) vector. >> >> Mildly wondering about whether call function would need special casing= (just >> because xen_smp_send_call_function_ipi() is special). But I don't have= the big >> picture there. >> >=20 > Adding Lin Ming here, since this was an evolution of an incomplete > implementation of mine that was > ultimately used in a larger context, outside of my original use case > for it (kgdb of dom0) that ultimately > gave me credit for this part of the patch, as part of a larger series. >=20 > I must admit that I don't recall the reasoning, if there was one. > It may be an oversight. >=20 > This was the original (incomplete) patch, in context: > http://markmail.org/message/d6ca5zfdmiqipurt >=20 >=20 > Are you seeing issues with the code, or just doing code inspection? No issues, I was just looking at the patch because we were asked to backp= ort it to fix another issue (access to the apic IPI functions without checking w= hether there is a pointer). Since things did work in most cases before, maybe th= ere is no real usage. :) I was just curious. Stefan >=20 > Ben >=20 --------------enig565F9CBC6A47A4BB6C77E941 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.11 (GNU/Linux) Comment: Using GnuPG with undefined - http://www.enigmail.net/ iQIcBAEBCgAGBQJRdn1NAAoJEOhnXe7L7s6j5XgQAJtZj3cT1Ce7H+MMYbjfuunT uUYN5Cllt7KyiZTLv/Jez0gXqeu1flT3XV1gxZgC0lqcNLDsS/8qLvx45YP0d8dJ o3hdKr4BgeWfkZoylY0E1GX813YEbYpEVFC1Dstw1xh2Q9KOIT8+3Zz28V+If/Zi OIISR4FCVc1ygK0+CpLVZVcRNFvUuQpa4Ud0gXK6qspkeoAuBk5bKWgO66si2BqJ w5tOiDVjl8ApLNwonx0AaDTTvJ3igUocDA+bf1ZYes70p9kGw5oo3WbS6z6B93CQ 4gE2sue7/ew1NJgGS7LV4q3xrav6ScXX+92C9hZLnQILeYSMAJoKFsPbORJsmhd+ nCsmAd+xVvArOMEF+Kl8m+SKWDNfODw4H1FkVKmREybnXmd2X4eu+Nbm3b+r0QzN qI3W8wgbw359b5RheyiHhQrxi6fZ5WKo6IPRNAJd2j2sBFzvEEe+O/J+mhSVbkRm /tMGJeqAsjlkUepBCcGZttIJ/fwKZAkZMQK2t4PIj8/e3B0u/4wIG36IlLaPFl20 GOofunYU3fFes7W+KLAC/t3U2RnXTJC/52rZOjJoisUQpt+v5he3UhegoIoJKZd6 5Sf/BtuBEiPEbNGzs//2eS83iIolq4f6XUDXfLLZFj/k+WGlyCftD0zpltmCd1mI TP5OO1SEkokmiI3xjmBz =3tC0 -----END PGP SIGNATURE----- --------------enig565F9CBC6A47A4BB6C77E941-- --===============4118031089509786110== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Xen-devel mailing list Xen-devel@lists.xen.org http://lists.xen.org/xen-devel --===============4118031089509786110==--