[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH v2] iscsi_ibft: Fix finding the iBFT under Xen Dom 0


  • To: Dave Hansen <dave.hansen@xxxxxxxxx>, "linux-kernel@xxxxxxxxxxxxxxx" <linux-kernel@xxxxxxxxxxxxxxx>, "xen-devel@xxxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxxx>
  • From: Ross Lagerwall <ross.lagerwall@xxxxxxxxxx>
  • Date: Mon, 5 Jun 2023 10:27:49 +0000
  • Accept-language: en-US
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=citrix.com; dmarc=pass action=none header.from=citrix.com; dkim=pass header.d=citrix.com; arc=none
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=/ZdXyEYA9GG2pDpXNCZbGMa6ZF07QnkHm18ZET2blfY=; b=VjJ0miidi1H6z3I0VQJEz0Galg2GG0PeMj2NhIv5s20wq+3y9g7Pt1ibCcEG5Tmduq1/H5nYjtjiCX39++vFA7rEaTF5XcGrgsSe/jHXDcVRQkokSSHZxwbzEbaMoO8j14CISBCqwny8VZUzq9DH9A13Z0r/nhI0yP00UoOCL50NGfU4691wa2S9YTni2Dq0mdNn5gv2aCnd2j5LHde27Rciyqb6jCm4nBTnm+FUg9OIMujxjYtAxqt3FH9tjW1vTHWbdNF6ILrqzXxihSkojAp7Xj50ZbBcNfq2wVlDFqMb+WWFHWO8XywvZ5wCosQUebR2mkjFIhCkWbshgtiMkg==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=hCQLgLU6AZd5epGW+VAeUY6DWT8pXGfYIh9dL5WPj4P4bs2Edt1pWUa9UEJ1nhXeM7SDxG/kSwvV4fcujhgsEZq2GVkz6RBcZA4g6KomgMicoOsF8kSevw6sGrw2rzUhbJbgvXQXrigFP5G+ywoQIryDrOKP761a5+BQcvB6Lc7mniIhQHmCZpN8+idiVfRWWLMTMPDW8zKbRD2lKRPAwfevAgAPBN8h6xP8vvYfYH2mFZ7D+rZClTWnBURrYP1K2hgY0eTevnHwN/r+ZhOIZP2IjUBxAXWRai9bldxUt17LH2Wp8wkxYFAzWGJEfrqqX12Xu49OAAJsA2RCq5fK6Q==
  • Authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=citrix.com;
  • Cc: Jan Beulich <jbeulich@xxxxxxxx>, Thomas Gleixner <tglx@xxxxxxxxxxxxx>, Ingo Molnar <mingo@xxxxxxxxxx>, Borislav Petkov <bp@xxxxxxxxx>, Dave Hansen <dave.hansen@xxxxxxxxxxxxxxx>, "x86@xxxxxxxxxx" <x86@xxxxxxxxxx>, Juergen Gross <jgross@xxxxxxxx>, Boris Ostrovsky <boris.ostrovsky@xxxxxxxxxx>, Peter Jones <pjones@xxxxxxxxxx>, Konrad Rzeszutek Wilk <konrad@xxxxxxxxxx>
  • Delivery-date: Mon, 05 Jun 2023 10:28:22 +0000
  • Ironport-data: A9a23:8ApNyqvnf1/yoBHpwWAvii5jhufnVFZeMUV32f8akzHdYApBsoF/q tZmKWzVOPyJamqnfNx2a47g8UwFvZTXnYdrGQBpq3swFCpE+JbJXdiXEBz9bniYRiHhoOCLz O1FM4Wdc5pkJpP4jk3wWlQ0hSAkjclkfpKlVKiffHg3HVQ+IMsYoUoLs/YjhYJ1isSODQqIu Nfjy+XSI1bg0DNvWo4uw/vrRChH4rKq4Fv0gnRkPaoQ5AGGyyFMZH4iDfrZw0XQE9E88tGSH 44v/JnhlkvF8hEkDM+Sk7qTWiXmlZaLYGBiIlIPM0STqkAqSh4ai87XB9JFAatjsB2bnsgZ9 Tl4ncfYpTHFnEH7sL91vxFwS0mSNEDdkVPNCSDXXce7lyUqf5ZwqhnH4Y5f0YAwo45K7W9yG fMwEQsINgytjs2NyYmAS+JVl8MZHvbhM9ZK0p1g5Wmx4fcOZ7nmGvyPz/kImTA6i4ZJAOrUY NcfZXx3dhPcbhZTO1ARTpUjgOOvgXq5eDpdwL6XjfNvvy6Pk0osgP60bou9lt+iHK25mm6Co XnduWDwDRwAK9WbzRKO8262h/+JliT+MG4XPOThrKYz3wPLnAT/DjUoEmnkpNKk1HKeRvtfc mEU3S4Ig4QLoRnDot7VGkfQTGS/lhIVRdcWE+Q88wyL4qvS/wudQGMDS1ZpbN0gqd9zRjEw0 FKNt83mCCYps7CPT3+ZsLCOoluaKSUTaGMPeyIAZQ8E+MX45pE+iArVSdRuG7Lzicf6cRnyy T2XqCk1h50IkNUGka68+Djvnz2otrDNTwgo+h/QWGO1qA90DKagZoqn7nDB4PpAJZrfRV6E1 FAOg+CX6OEDC8HLmCHlaOkEArzv5/+DKzDaqVpuGYQxsTWr53OnO4tX5VlWNBc3GsUJYznkZ AnUoww5zJ1cJnyxdodsfpm8Tc8tyMDIH9P/V+uSacFSeJ9vbwyW1CZ0bEWU0ibml01Eubk9P pGWau62AHoaALghxz2zL88e1rkxzywWxm7JQ53/iRO93tKjiGW9TL4ENB6EaLA/5abd+QHNq Y8BZo2N1glVV/D4bm/P64kPIFsWLH89Q5frt8hQce3FKQ1jcI08N8LsLXoaU9QNt8xoei3gp xlRhmcwJILDuED6
  • Ironport-hdrordr: A9a23:jF0ala+YKBrm5xcAE7puk+DcI+orL9Y04lQ7vn2ZLiYlFfBw9v re+MjzsCWetN9/Yh0dcLy7V5VoI0mzyXcF2+ks1N6ZNWGN1VdAR7sC0WKN+UyDJwTOssJbyK d8Y+xfJbTLfD1HZB/BkWqFL+o=
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
  • Msip_labels:
  • Thread-index: AQHZkwepCLd5o5Ie30KiSFAaN3rMQq92Lj4AgAXcJLg=
  • Thread-topic: [PATCH v2] iscsi_ibft: Fix finding the iBFT under Xen Dom 0

> From: Dave Hansen <dave.hansen@xxxxxxxxx>
> Sent: Thursday, June 1, 2023 5:57 PM
> To: Ross Lagerwall <ross.lagerwall@xxxxxxxxxx>; linux-kernel@xxxxxxxxxxxxxxx 
> <linux-kernel@xxxxxxxxxxxxxxx>; xen-devel@xxxxxxxxxxxxxxxxxxxx 
> <xen-devel@xxxxxxxxxxxxxxxxxxxx>
> Cc: Jan Beulich <jbeulich@xxxxxxxx>; Thomas Gleixner <tglx@xxxxxxxxxxxxx>; 
> Ingo Molnar <mingo@xxxxxxxxxx>; Borislav Petkov <bp@xxxxxxxxx>; Dave Hansen 
> <dave.hansen@xxxxxxxxxxxxxxx>; x86@xxxxxxxxxx <x86@xxxxxxxxxx>; Juergen Gross 
> <jgross@xxxxxxxx>; Boris Ostrovsky <boris.ostrovsky@xxxxxxxxxx>; Peter Jones 
> <pjones@xxxxxxxxxx>; Konrad Rzeszutek Wilk <konrad@xxxxxxxxxx>
> Subject: Re: [PATCH v2] iscsi_ibft: Fix finding the iBFT under Xen Dom 0 
>  
> On 5/30/23 08:01, Ross Lagerwall wrote:
> > Since firmware doesn't indicate the iBFT in the E820, add a reserved
> > region so that it gets identity mapped when running as Dom 0 so that it
> > is possible to search for it. Move the call to reserve_ibft_region()
> > later so that it is called after the Xen identity mapping adjustments
> > are applied.
> > 
> > Finally, instead of using isa_bus_to_virt() which doesn't do the right
> > thing under Xen, use early_memremap() like the dmi_scan code does.
> 
> This is connecting Xen, iSCSI and x86.  Some background here would be
> *really* nice for dummies like me that deal heavily in only one of those
> three.
> 
> One or two sentences like this:
> 
>         Firmware can provide an iSCSI-specific table called the iBFT
>         which helps the OS boot from iSCSI devices.
> 
> can go a long way for dummies like me.  As could some background about
> why this:
> 
>         ... add a reserved region so that it gets identity mapped when
>         running as Dom 0 so that it is possible to search for it.
> 
> These are all English words, but off the top of my head, I have no idea
> why reserved regions get identity mapped when running as Dom 0 or why
> that makes it possible to search.
> 
> The addresses and size here:
> 
> > +#ifdef CONFIG_ISCSI_IBFT_FIND
> > +             /* Reserve 0.5 MiB to 1 MiB region so iBFT can be found */
> > +             xen_e820_table.entries[xen_e820_table.nr_entries].addr = 
> > 0x80000;
> > +             xen_e820_table.entries[xen_e820_table.nr_entries].size = 
> > 0x80000;
> > +             xen_e820_table.entries[xen_e820_table.nr_entries].type = 
> > E820_TYPE_RESERVED;
> > +             xen_e820_table.nr_entries++;
> > +#endif
> 
> also appear to be conjured out of thin air.
> 
> As does the move of:
> 
> > +     reserve_ibft_region();
> 
> I'm sure I can go figure this all out with some research.  But, I'd
> really appreciate some extra effort from you in this changelog to save
> me the time.  I bet you can explain it a lot more efficiently than I can
> go figure it out.

Sure, I will resend with an expanded commit message.

Ross


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.