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

Re: [PATCH v3 2/9] xen: reuse x86 EFI stub functions for Arm


  • To: Wei Chen <Wei.Chen@xxxxxxx>
  • From: Bertrand Marquis <Bertrand.Marquis@xxxxxxx>
  • Date: Fri, 20 May 2022 09:08:36 +0000
  • Accept-language: en-GB, en-US
  • Arc-authentication-results: i=2; mx.microsoft.com 1; spf=pass (sender ip is 63.35.35.123) smtp.rcpttodomain=lists.xenproject.org smtp.mailfrom=arm.com; dmarc=pass (p=none sp=none pct=100) action=none header.from=arm.com; dkim=pass (signature was verified) header.d=armh.onmicrosoft.com; arc=pass (0 oda=1 ltdi=1 spf=[1,1,smtp.mailfrom=arm.com] dkim=[1,1,header.d=arm.com] dmarc=[1,1,header.from=arm.com])
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=arm.com; dmarc=pass action=none header.from=arm.com; dkim=pass header.d=arm.com; arc=none
  • Arc-message-signature: i=2; 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=Tg9wI8pbLsSNAOGEc544JGsIFy0/XLtT+D4FLaodeWQ=; b=hjSZi6qSStBFZpDlir5mNs/wk6W0IpMNFTRBWTabT26HFPQSFx0ek/bsT4eRoIaHOfmSp7LatqVXdlPCrG82MTIsqqdmfKK/KUYEbA74zWqIwoaU3Vi25+tYToHSXuThB2ugbovg0Ol2L7m/Y2Oc58jMJPWS3bahiec/tMzVZUa23cEXnm7AsYU3dZ5Nd3SH0xJOuklFn1a7ptppjhGP86EVRVnMefwkPJxAeB8E51PImOuhtVZmdyloCda22o/mNzHkligib+srLDsZZ27yGRL8NyZYA/rQHSmMz6iPrDM0+QWxtckLwRhFva+XO05Urwpl4owXI79qTWmYFOj1dQ==
  • 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=Tg9wI8pbLsSNAOGEc544JGsIFy0/XLtT+D4FLaodeWQ=; b=WF3M7dynjO+xJcuCGi5t6kXVMG82W3NnHEL8JHzxW0rA6K+CuRpNwLrCm7OGVWVGDglvYckkClqQ875VcseGAOpLFTUx3dTESuwMJIAat06iQb0U71qpA4w51PC3QMaq7PEtyvhNt8YWZ+1tnO1uxwqOWHvD4c7AfrAoY1GD27ZzPXffV4tjm1Jniy8/6v82xr5U41OV+GsqUFnnT1xC+qYDc6B9I9oIa5kDTB5UalbjL1JsfEpucoB2vHA7uj5EF7bQomzAn1gu6GtNyQhpzxB35cYBpmp9wHJKvtkd+Z3JtJz1B6MgJYpnLq1gXhkCntJBvRWsTojAetSUWH1ffw==
  • Arc-seal: i=2; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=pass; b=K6P+y6XYwAQPShHyS/3T/JXYfoHYEM9kFOKGRt45Vej+iVJXPMNPgxg94O6pHzVc7Cg76CAzXYmVsV038Is0gYQ99b+v01x9UpTb6mCpEZZIdOGMMXJCYu2Sxb5wPvzZChyq5D1D/V2Ua7l4VhgP41IdePoFM8H3N51wTZ/ULpIutFaW7GIWODj4Gcd0wpWMkHPCqiFjAJfXlg7N2otGUbbmWtTQ1WWJjRKoy+qs3xHjiMI6vtUtB9yK0CCsb9dlA8hUiKGRFo8I2VQKJvX1SEYBfT+F5Z6F2tHE4JaVM0UHAZ4uZZOi+ddFhl1Op3VbDIcMzv+eylbD3LZiqunBaA==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=noEccqOyPZMiV0Ia6f1x8SSadP3zPl31uy++hftBXi4iIriF7zun4++6RbyVvKkgirKbqwv2fIYTrSnBKWUyD9NJtEi9/sW7wmyEPh7U4ych7dBYinAIZvazWGryAjuG7yck3TKk59WqX/G4MQfdAFQSu/8g2JG9eYiv4rvslgbI2lWbwOllCi3Lxhs0E7k8dPMwijjmOxvEaqgy/OvtM59eUBStyc10BBoh7v+VHnuQGjiJB8AX438Q86UQd4HF8GN4DjSzNcEpa5yi3tp5R1J0MbgNZ2HBHU1Bat6nsAnP6nTiuVp/3+3Og7v978zTnk7fmYmtmVKp7n5bpDMiIA==
  • Authentication-results-original: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=arm.com;
  • Cc: Jan Beulich <jbeulich@xxxxxxxx>, Stefano Stabellini <sstabellini@xxxxxxxxxx>, Julien Grall <julien@xxxxxxx>, nd <nd@xxxxxxx>, Volodymyr Babchuk <Volodymyr_Babchuk@xxxxxxxx>, Andrew Cooper <andrew.cooper3@xxxxxxxxxx>, Roger Pau Monné <roger.pau@xxxxxxxxxx>, Wei Liu <wl@xxxxxxx>, Jiamei Xie <Jiamei.Xie@xxxxxxx>, "xen-devel@xxxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxxx>
  • Delivery-date: Fri, 20 May 2022 09:08:53 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
  • Nodisclaimer: true
  • Original-authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=arm.com;
  • Thread-index: AQHYZNkEfStZ9tvSv0uE8gVJVUTE+a0kpgQAgADixQCAAf/jgA==
  • Thread-topic: [PATCH v3 2/9] xen: reuse x86 EFI stub functions for Arm

Hi,

> On 19 May 2022, at 03:36, Wei Chen <Wei.Chen@xxxxxxx> wrote:
> 
> Hi Jan,
> 
>> -----Original Message-----
>> From: Jan Beulich <jbeulich@xxxxxxxx>
>> Sent: 2022年5月18日 21:05
>> To: Wei Chen <Wei.Chen@xxxxxxx>
>> Cc: nd <nd@xxxxxxx>; Stefano Stabellini <sstabellini@xxxxxxxxxx>; Julien
>> Grall <julien@xxxxxxx>; Bertrand Marquis <Bertrand.Marquis@xxxxxxx>;
>> Volodymyr Babchuk <Volodymyr_Babchuk@xxxxxxxx>; Andrew Cooper
>> <andrew.cooper3@xxxxxxxxxx>; Roger Pau Monné <roger.pau@xxxxxxxxxx>; Wei
>> Liu <wl@xxxxxxx>; Jiamei Xie <Jiamei.Xie@xxxxxxx>; xen-
>> devel@xxxxxxxxxxxxxxxxxxxx
>> Subject: Re: [PATCH v3 2/9] xen: reuse x86 EFI stub functions for Arm
>> 
>> On 11.05.2022 03:46, Wei Chen wrote:
>>> x86 is using compiler feature testing to decide EFI build
>>> enable or not. When EFI build is disabled, x86 will use an
>>> efi/stub.c file to replace efi/runtime.c for build objects.
>>> Following this idea, we introduce a stub file for Arm, but
>>> use CONFIG_ARM_EFI to decide EFI build enable or not.
>>> 
>>> And the most functions in x86 EFI stub.c can be reused for
>>> other architectures, like Arm. So we move them to common
>>> and keep the x86 specific function in x86/efi/stub.c.
>>> 
>>> To avoid the symbol link conflict error when linking common
>>> stub files to x86/efi. We add a regular file check in efi
>>> stub files' link script. Depends on this check we can bypass
>>> the link behaviors for existed stub files in x86/efi.
>>> 
>>> As there is no Arm specific EFI stub function for Arm in
>>> current stage, Arm still can use the existed symbol link
>>> method for EFI stub files.
>> 
>> Wouldn't it be better to mandate that every arch has its stub.c,
>> and in the Arm one all you'd do (for now) is #include the common
>> one? (But see also below.)
>> 
> 
> Personally, I don't like to include a C file into another C file.
> But I am OK as long as the Arm maintainers agree.
> @Stefano Stabellini @Bertrand Marquis @Julien Grall

I agree with Wei here and if we are realistic the current way the EFI code 
works needs a redesign anyway and asking him to change this in this serie is 
not right.
So I am OK with Wei solution.

Cheers
Bertrand


 


Rackspace

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