[meta-virtualization] [PATCH 1/4] xen: drop patch that upstream says is wrong

Doug Goldstein cardoe at cardoe.com
Wed Aug 26 15:18:09 PDT 2015


On Tue, Aug 25, 2015 at 1:44 AM, Nathan Rossi <nathan at nathanrossi.com> wrote:
> On Tue, Aug 25, 2015 at 6:26 AM, Doug Goldstein <cardoe at cardoe.com> wrote:
>> Per upstream its not correct to always force -mfpmath=387 to work around
>> the -mno-sse flags. Instead strip out -mfpmath=sse that Yocto injects
>> for certain BSPs.
>> ---
>>  ...xen-x86-Fix-up-rules-when-forcing-mno-sse.patch | 28 ----------------------
>>  recipes-extended/xen/xen.inc                       |  5 ++++
>>  recipes-extended/xen/xen_4.5.0.bb                  |  1 -
>>  3 files changed, 5 insertions(+), 29 deletions(-)
>>  delete mode 100644 recipes-extended/xen/files/xen-x86-Fix-up-rules-when-forcing-mno-sse.patch
>>
>> diff --git a/recipes-extended/xen/files/xen-x86-Fix-up-rules-when-forcing-mno-sse.patch b/recipes-extended/xen/files/xen-x86-Fix-up-rules-when-forcing-mno-sse.patch
>> deleted file mode 100644
>> index 4c3e297..0000000
>> --- a/recipes-extended/xen/files/xen-x86-Fix-up-rules-when-forcing-mno-sse.patch
>> +++ /dev/null
>> @@ -1,28 +0,0 @@
>> -From: Nathan Rossi <nathan.rossi at xilinx.com>
>> -Subject: [PATCH] xen/x86: Fix up rules when forcing -mno-sse
>> -
>> -* When forcing -mno-sse specify -mfpmath=387 to avoid the fallback
>> -  warning
>> -
>> -Signed-off-by: Nathan Rossi <nathan.rossi at xilinx.com>
>> -Upstream-Status: Not-Submitted
>> ----
>> - xen/arch/x86/Rules.mk | 2 +-
>> - 1 file changed, 1 insertion(+), 1 deletion(-)
>> -
>> -diff --git a/xen/arch/x86/Rules.mk b/xen/arch/x86/Rules.mk
>> -index 6775cb5..03848f7 100644
>> ---- a/xen/arch/x86/Rules.mk
>> -+++ b/xen/arch/x86/Rules.mk
>> -@@ -42,7 +42,7 @@ x86 := y
>> - x86_32 := n
>> - x86_64 := y
>> -
>> --CFLAGS += -mno-red-zone -mno-sse -fpic
>> -+CFLAGS += -mno-red-zone -mno-sse -fpic -mfpmath=387
>> - CFLAGS += -fno-asynchronous-unwind-tables
>> - # -fvisibility=hidden reduces -fpic cost, if it's available
>> - ifneq ($(call cc-option,$(CC),-fvisibility=hidden,n),n)
>> ---
>> -2.1.1
>> -
>> diff --git a/recipes-extended/xen/xen.inc b/recipes-extended/xen/xen.inc
>> index 432bf4d..c7a2347 100644
>> --- a/recipes-extended/xen/xen.inc
>> +++ b/recipes-extended/xen/xen.inc
>> @@ -12,6 +12,11 @@ inherit autotools-brokensep gettext setuptools update-rc.d systemd
>>
>>  require xen-arch.inc
>>
>> +# Xen uses hardcodes the use of -mno-sse which conflicts -mfpmath=sse
>> +# The issue arises from certain Yocto machine BSPs injecting -mfpmath=sse
>> +# into the package's CFLAGS so we need to strip that
>> +TUNE_CCARGS := "${@oe_filter_out('-mfpmath=sse', '${TUNE_CCARGS}', d)}"
>
> Just curious, filtering out that flag will also affect the building of
> for example the target user-space tools no? is that problematic or do
> other SSE related flags (for those BSPs) cause the use of this fpmath
> setting regardless?
>
> Regards,
> Nathan

Yes you are correct. The existing patch was more targeted. However
while the tools are built a lot of them aren't used.
meta-virtualization pulls in its own QEMU and firmware blobs. The
default in this case is -mfpmath=sse,387 so it won't really affect
anything. But you are probably right this patch should be dropped and
the existing path should be used. I'll approach this from the Xen side
again.

--
Doug


>
>> +
>>  PACKAGECONFIG ??= " \
>>      sdl \
>>      ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'systemd', '', d)} \
>> diff --git a/recipes-extended/xen/xen_4.5.0.bb b/recipes-extended/xen/xen_4.5.0.bb
>> index 6c17b90..a5f03f3 100644
>> --- a/recipes-extended/xen/xen_4.5.0.bb
>> +++ b/recipes-extended/xen/xen_4.5.0.bb
>> @@ -2,7 +2,6 @@ require xen.inc
>>
>>  SRC_URI = " \
>>      http://bits.xensource.com/oss-xen/release/${PV}/xen-${PV}.tar.gz \
>> -    file://xen-x86-Fix-up-rules-when-forcing-mno-sse.patch \
>>      "
>>
>>  SRC_URI[md5sum] = "9bac43d2419d05a647064d9253bb03fa"
>> --
>> 2.1.4
>>



-- 
Doug Goldstein


More information about the meta-virtualization mailing list