From mboxrd@z Thu Jan 1 00:00:00 1970 From: Dario Faggioli Subject: Re: Device pass through on XEN on ARM Date: Wed, 11 Jun 2014 16:07:37 +0200 Message-ID: <1402495657.16827.99.camel@Solace> References: <3A6586556649FF42BA3240F179473FD11454A64270@HIKAWSEX01.ad.harman.com> <53625DC9.7050704@linaro.org> <1398956164.22521.4.camel@kazak.uk.xensource.com> <3A6586556649FF42BA3240F179473FD114885FF8C1@HIKAWSEX01.ad.harman.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============0577510552632445496==" Return-path: In-Reply-To: <3A6586556649FF42BA3240F179473FD114885FF8C1@HIKAWSEX01.ad.harman.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: "Khandelwal, Shubham" Cc: "xen-devel@lists.xensource.com" , Arianna Avanzini , Julien Grall , 'Ian Campbell' , xen-devel List-Id: xen-devel@lists.xenproject.org --===============0577510552632445496== Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="=-hrIIJxoHGhgLcZcNo0id" --=-hrIIJxoHGhgLcZcNo0id Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On mer, 2014-06-11 at 11:16 +0200, Khandelwal, Shubham wrote: > On 05/01/2014 08:26 PM, Ian Campbell wrote: > > Obviously this is all very hacky and as Julien says there are various > > things in the pipeline for 4.5 which will allow this to be done > > properly. > > > > Ian. >=20 > Hello Ian, Julien, >=20 > Just to try out the passthrough using the hacks you mentioned, I made cha= nges in xen to assign a GPIO controlled LED to domU by calling map_mmio_reg= ions() in the domain creation path. After domU boots, when I try to access = the LED using ioremap, ioread and iowrite from kernel space I see that I am= not able to control the LED, also when I try to control LED using sysfs fr= om user space it shows 'no such device' error. >=20 > I am using xen 4.5 unstable and I have made the following changes in xen/= common/domctl.c :: do_domctl(), after line 473: >=20 >=20 >=20 > int passthrough =3D map_mmio_regions(d, 0x4805B000, 0x4805B000 + 0x1000, = 0x4805B000); > if (passthrough) > printk("Failed to map passthrough_LED @ 0x4805B000 to dom%d\n", d= ->domain_id);=20 >=20 >=20 >=20 > While booting domU, in the logs I can see there is no error in map_mmio_r= egions(). Am I missing something here. >=20 May I suggest trying to apply Arianna's series, and see whether that helps? IIRC, there should even be the possibility of setting up non 1:1 mappings, directly from the config file (uless that got dropped in the latest versions, which I could not follow closely). In any case, it look like both less work, and a more tested path (given the amount of attention and review the series is getting). It also would be greeat to have some more testing of the series itself, not to mention that, if it works, you'll be all set for when the series will go upstream! :-P I believe the last version of Arianna's series is this one: http://markmail.org/thread/wtevxxizyxjhvmg2 Just 2 cents... :-) Regards, Dario --=20 <> (Raistlin Majere) ----------------------------------------------------------------- Dario Faggioli, Ph.D, http://about.me/dario.faggioli Senior Software Engineer, Citrix Systems R&D Ltd., Cambridge (UK) --=-hrIIJxoHGhgLcZcNo0id Content-Type: application/pgp-signature; name="signature.asc" Content-Description: This is a digitally signed message part Content-Transfer-Encoding: 7bit -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.22 (GNU/Linux) iEYEABECAAYFAlOYYqkACgkQk4XaBE3IOsRYFACdFQtVevO1/iBU280GOF461NMz HfAAnRjiZf7Wu0V5kmnum2CRwo/KS5Jf =43/n -----END PGP SIGNATURE----- --=-hrIIJxoHGhgLcZcNo0id-- --===============0577510552632445496== 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 --===============0577510552632445496==--