From patchwork Tue Apr 9 16:23:02 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Paolo Bonzini X-Patchwork-Id: 10891705 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 1727317EF for ; Tue, 9 Apr 2019 16:33:58 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 0958828643 for ; Tue, 9 Apr 2019 16:33:58 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id F14A828671; Tue, 9 Apr 2019 16:33:57 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.7 required=2.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI autolearn=ham version=3.3.1 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 897C328643 for ; Tue, 9 Apr 2019 16:33:57 +0000 (UTC) Received: from localhost ([127.0.0.1]:46089 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hDth6-0004tg-FB for patchwork-qemu-devel@patchwork.kernel.org; Tue, 09 Apr 2019 12:33:56 -0400 Received: from eggs.gnu.org ([209.51.188.92]:59235) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hDtWh-0004VT-DO for qemu-devel@nongnu.org; Tue, 09 Apr 2019 12:23:12 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hDtWg-0003RC-93 for qemu-devel@nongnu.org; Tue, 09 Apr 2019 12:23:11 -0400 Received: from mail-wr1-x442.google.com ([2a00:1450:4864:20::442]:34400) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hDtWg-0003Qi-2f for qemu-devel@nongnu.org; Tue, 09 Apr 2019 12:23:10 -0400 Received: by mail-wr1-x442.google.com with SMTP id p10so21738025wrq.1 for ; Tue, 09 Apr 2019 09:23:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=GhKLXN4x2Bh28KK1khKEa4UYDz15n5B2iNQEOKiXWDU=; b=hR1WFic2qsFaBAdo1S5anNkuo4o4ECzVnVkmxzxdv7FkwkP/NmWX6o1Sj6x42PVrcl 3K0JktEwwbY17r562rBY0eKg1YzOCsWjBxvyj4+aJXpoUjl7FMVE9oONKWkvtZ7zbr6Q +yfwURJqT1mCNj+vA2Pm4iim8LOwS/kP15V/D1WaZ3wQYRomcNB8UVbUNQJvlN1Pn0cI q1UXLa22jwuAkMtRio9BjuVCfGO5DpE0nDUYdsoHybnsobtIlYWoYzDrefbAN6OEsrvu W7MD/NCxoCFNFdsT/VGI2w6Fj6zsXkNjirmriuQs3h7JZ1E8y8DTKf3mPQrdnHjpqmbr eHTg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=GhKLXN4x2Bh28KK1khKEa4UYDz15n5B2iNQEOKiXWDU=; b=KWK1ukmVHppMGWbojA7S5eJi+MP7CZCtBKHDYgp5sjOwsYXlNSjW/T55qYjksC00w1 7EOv7NqNpYDlxBHFqq5iQD7iXgdH3mWRPFPMeB8xceBrKC1S7FKpg9Ie1712RjKrEvw+ Fd6IPdZRoxbYqQs78pIyVbn8VeBg9GwcAmS7w8/zhlIyqpZOU50oojfeuPG8RU96npc2 G3zFY0jyCZoqqMPJbz5Xo959hDxQs7RP4zc6IHMvVSPQ93y5EUI0yL+6OzgH6l+CSOUc lnONSAO0GU4Gq6iNGZQVzzGYLXcCwM3OWxbM673eOfZH2vnRH5X2gx2LQYzIO+VzDy0k mv8Q== X-Gm-Message-State: APjAAAXHXHZyBK7FT1bHb0QOUhC/OhthUgvpHCyQkTjg+5+k9vvCneIm FU12VqjSdS0Cqxc83ph0C2dObhAr X-Google-Smtp-Source: APXvYqwxP3Cj5q0ZZGOsRSCThvk9Z8391JuM6Loru9njh+P+J2c2V60FSZxoQHrT6DNMNKFMDw2ddw== X-Received: by 2002:a05:6000:14a:: with SMTP id r10mr4028157wrx.107.1554826988811; Tue, 09 Apr 2019 09:23:08 -0700 (PDT) Received: from 640k.lan ([93.56.166.5]) by smtp.gmail.com with ESMTPSA id e1sm59579736wrw.66.2019.04.09.09.23.07 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 09 Apr 2019 09:23:08 -0700 (PDT) From: Paolo Bonzini To: qemu-devel@nongnu.org Date: Tue, 9 Apr 2019 18:23:02 +0200 Message-Id: <1554826986-37164-2-git-send-email-pbonzini@redhat.com> X-Mailer: git-send-email 1.8.3.1 In-Reply-To: <1554826986-37164-1-git-send-email-pbonzini@redhat.com> References: <1554826986-37164-1-git-send-email-pbonzini@redhat.com> MIME-Version: 1.0 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::442 Subject: [Qemu-devel] [PULL 1/5] roms: Rename the EFIROM variable to avoid clashing with iPXE X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= Errors-To: qemu-devel-bounces+patchwork-qemu-devel=patchwork.kernel.org@nongnu.org Sender: "Qemu-devel" X-Virus-Scanned: ClamAV using ClamSMTP From: Philippe Mathieu-Daudé The iPXE's 'veryclean' recipe removes $(EFIROM) even if the EFIROM macro originates from elsewhere: $ git checkout f590a812c21~ $ make -C roms clean EFIROM=$(type -P EfiRom) make: Entering directory '/source/qemu/roms' [...] make -C ipxe/src veryclean make[1]: Entering directory '/source/qemu/roms/ipxe/src' rm -f bin{,-*}/*.* bin{,-*}/.certificate.* bin{,-*}/.certificates.* bin{,-*}/.private_key.* bin{,-*}/errors bin{,-*}/NIC ./util/zbin ./util/elf2efi32 ./util/elf2efi64 /usr/bin/EfiRom ./util/efifatbin ./util/iccfix ./util/einfo TAGS bin{,-*}/symtab rm: cannot remove '/usr/bin/EfiRom': Permission denied make[1]: *** [Makefile.housekeeping:1564: clean] Error 1 make[1]: Leaving directory '/source/qemu/roms/ipxe/src' make: *** [Makefile:152: clean] Error 2 make: Leaving directory '/source/qemu/roms' Before f590a812c21 this variable could be overridden or unset, and the 'veryclean' Makefile rule would not complain. Commit f590a812c21 enforces this variable to the Intel EfiRom tool provided by the EDK2 project. To avoid the name clash and make the difference between the projects obvious, rename the variable used by the EDK2 project as EDK2_EFIROM. Fixes: f590a812c21074e82228de3e1dfb57b75fc02b62 Reported-by: Olaf Hering Reviewed-by: Laszlo Ersek Signed-off-by: Philippe Mathieu-Daudé Message-Id: <20190409134536.15548-2-philmd@redhat.com> Signed-off-by: Paolo Bonzini --- roms/Makefile | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/roms/Makefile b/roms/Makefile index 78d5dd1..d28252d 100644 --- a/roms/Makefile +++ b/roms/Makefile @@ -47,7 +47,7 @@ SEABIOS_EXTRAVERSION="-prebuilt.qemu.org" # We need that to combine multiple images (legacy bios, # efi ia32, efi x64) into a single rom binary. # -EFIROM = edk2/BaseTools/Source/C/bin/EfiRom +EDK2_EFIROM = edk2/BaseTools/Source/C/bin/EfiRom default: @echo "nothing is build by default" @@ -102,8 +102,8 @@ pxe-rom-%: build-pxe-roms efirom: $(patsubst %,efi-rom-%,$(pxerom_variants)) -efi-rom-%: build-pxe-roms build-efi-roms $(EFIROM) - $(EFIROM) -f "0x$(VID)" -i "0x$(DID)" -l 0x02 \ +efi-rom-%: build-pxe-roms build-efi-roms $(EDK2_EFIROM) + $(EDK2_EFIROM) -f "0x$(VID)" -i "0x$(DID)" -l 0x02 \ -b ipxe/src/bin/$(VID)$(DID).rom \ -ec ipxe/src/bin-i386-efi/$(VID)$(DID).efidrv \ -ec ipxe/src/bin-x86_64-efi/$(VID)$(DID).efidrv \ @@ -120,7 +120,7 @@ build-efi-roms: build-pxe-roms $(patsubst %,bin-i386-efi/%.efidrv,$(pxerom_targets)) \ $(patsubst %,bin-x86_64-efi/%.efidrv,$(pxerom_targets)) -$(EFIROM): +$(EDK2_EFIROM): $(MAKE) -C edk2/BaseTools slof: From patchwork Tue Apr 9 16:23:03 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Paolo Bonzini X-Patchwork-Id: 10891693 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 8D73217E0 for ; Tue, 9 Apr 2019 16:27:15 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 7FF302864A for ; Tue, 9 Apr 2019 16:27:15 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 73BB728904; Tue, 9 Apr 2019 16:27:15 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.7 required=2.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI autolearn=ham version=3.3.1 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 1D6232864A for ; Tue, 9 Apr 2019 16:27:15 +0000 (UTC) Received: from localhost ([127.0.0.1]:45891 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hDtac-0008L2-DM for patchwork-qemu-devel@patchwork.kernel.org; Tue, 09 Apr 2019 12:27:14 -0400 Received: from eggs.gnu.org ([209.51.188.92]:59267) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hDtWl-0004Z9-4k for qemu-devel@nongnu.org; Tue, 09 Apr 2019 12:23:16 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hDtWk-0003US-4h for qemu-devel@nongnu.org; Tue, 09 Apr 2019 12:23:15 -0400 Received: from mail-wr1-x429.google.com ([2a00:1450:4864:20::429]:45458) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hDtWj-0003TX-Tm for qemu-devel@nongnu.org; Tue, 09 Apr 2019 12:23:14 -0400 Received: by mail-wr1-x429.google.com with SMTP id s15so21649839wra.12 for ; Tue, 09 Apr 2019 09:23:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=J/oX2Py0fTzs8jjZVuYDRStPJAK1DgZHWNwrWKfTCFU=; b=nbBAubcDKlZUtyrL0DR9I9vj0e5w7B8rMWbAN+MsNvVZoSJlUN6qdSRFEeW7Ou++TK CLTRt/CoufNL+T4nQ92JJzyx/3C6cTu8ShqobeWn+rYu9sGc1anhkMZwtaw8M+5wqLqq hvyJHNJV3U22gUqDMFr+V7u66PY0CSOZxjC0EDV0F5Y4dPjFVSOuBGGoJ7O0ZEn+bq8r m/Ad/lIonEWZDimtDU3msV62wGs64K49pXH7eHQovM5SY08HNxQn7d+6A5ZF07py2YpA TC/foxsAbJSk4bHy8I+iTWn8Kx/A8rc2Tw33Tir1HMqYPOxXTYBEGNucxwcSXX/6XQ5H IWHQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=J/oX2Py0fTzs8jjZVuYDRStPJAK1DgZHWNwrWKfTCFU=; b=iT3Vb0ZWeXUTLbqt6aimdv13ZrNQEVpXCPvRpoBdtgyAaYSn6wu0qyDCuAe/fnoaE1 mNaj/4muQynRENSMU3M1I17Iii2T7x4Aj5TSdkypvpzyL+7K1BgIfkZSYsP3WLHZOkfZ YQmBB3IYfVqtHSexz6yhBtE2rOAsyNQpKv4yImHExak3Nw/Kjm5VZzBfMK2U96cruAT7 wBhtfNzJh4zoXfvlcM5AqgiHKnBegdjz3p039VzyUiPqA8zM8yet3Zi80TtZdIdxybz0 PzsgsgE0JQLP4167bHLjZU4OwPofZjKlj+xzAHNX73datptZCQa3fuurUC4ISeNvIJKi OpeA== X-Gm-Message-State: APjAAAUPdFN4KhC0ru1nfk6mKN/dRB8ziIzJXIOAdEO9/vb6GR9HA0rl gM8wpoLiJWttA/dvsNbeoEEB8DYY X-Google-Smtp-Source: APXvYqyQ+r8lW1vi4HIicna5uqVl3dtZdMZ6WCxLHFH45Re4PX8qhJ0IQukPrkww3NHWl+JHO6aWeA== X-Received: by 2002:a5d:62c4:: with SMTP id o4mr2469619wrv.282.1554826992681; Tue, 09 Apr 2019 09:23:12 -0700 (PDT) Received: from 640k.lan ([93.56.166.5]) by smtp.gmail.com with ESMTPSA id e1sm59579736wrw.66.2019.04.09.09.23.08 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 09 Apr 2019 09:23:12 -0700 (PDT) From: Paolo Bonzini To: qemu-devel@nongnu.org Date: Tue, 9 Apr 2019 18:23:03 +0200 Message-Id: <1554826986-37164-3-git-send-email-pbonzini@redhat.com> X-Mailer: git-send-email 1.8.3.1 In-Reply-To: <1554826986-37164-1-git-send-email-pbonzini@redhat.com> References: <1554826986-37164-1-git-send-email-pbonzini@redhat.com> MIME-Version: 1.0 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::429 Subject: [Qemu-devel] [PULL 2/5] roms: Allow passing configure options to the EDK2 build tools X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= Errors-To: qemu-devel-bounces+patchwork-qemu-devel=patchwork.kernel.org@nongnu.org Sender: "Qemu-devel" X-Virus-Scanned: ClamAV using ClamSMTP From: Philippe Mathieu-Daudé Since commit f590a812c210 we build the EDK2 EfiRom utility unconditionally. Some distributions require to use extra compiler/linker flags, i.e. SUSE which enforces the PIE protection (see [*]). EDK2 build tools already provide a set of variables for that, use them to allow the caller to easily inject compiler/linker options.. Now build scripts can pass extra options, example: $ make -C roms \ EDK2_BASETOOLS_OPTFLAGS='-fPIE' \ efirom [*] https://lists.opensuse.org/opensuse-factory/2017-06/msg00403.html Reported-by: Olaf Hering Suggested-by: Laszlo Ersek Signed-off-by: Philippe Mathieu-Daudé Message-Id: <20190409134536.15548-3-philmd@redhat.com> Signed-off-by: Paolo Bonzini --- roms/Makefile | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/roms/Makefile b/roms/Makefile index d28252d..1ff78b6 100644 --- a/roms/Makefile +++ b/roms/Makefile @@ -120,8 +120,21 @@ build-efi-roms: build-pxe-roms $(patsubst %,bin-i386-efi/%.efidrv,$(pxerom_targets)) \ $(patsubst %,bin-x86_64-efi/%.efidrv,$(pxerom_targets)) +# Build scripts can pass compiler/linker flags to the EDK2 build tools +# via the EDK2_BASETOOLS_OPTFLAGS (CPPFLAGS and CFLAGS) and +# EDK2_BASETOOLS_LDFLAGS (LDFLAGS) environment variables. +# +# Example: +# +# make -C roms \ +# EDK2_BASETOOLS_OPTFLAGS='...' \ +# EDK2_BASETOOLS_LDFLAGS='...' \ +# efirom +# $(EDK2_EFIROM): - $(MAKE) -C edk2/BaseTools + $(MAKE) -C edk2/BaseTools \ + EXTRA_OPTFLAGS='$(EDK2_BASETOOLS_OPTFLAGS)' \ + EXTRA_LDFLAGS='$(EDK2_BASETOOLS_LDFLAGS)' slof: $(MAKE) -C SLOF CROSS=$(powerpc64_cross_prefix) qemu From patchwork Tue Apr 9 16:23:04 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Paolo Bonzini X-Patchwork-Id: 10891709 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 4327A17EF for ; Tue, 9 Apr 2019 16:35:20 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 2D05226AE3 for ; Tue, 9 Apr 2019 16:35:20 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 20CF928917; Tue, 9 Apr 2019 16:35:20 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.7 required=2.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI autolearn=ham version=3.3.1 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 8C98026AE3 for ; Tue, 9 Apr 2019 16:35:19 +0000 (UTC) Received: from localhost ([127.0.0.1]:46132 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hDtiQ-0005dZ-Pn for patchwork-qemu-devel@patchwork.kernel.org; Tue, 09 Apr 2019 12:35:18 -0400 Received: from eggs.gnu.org ([209.51.188.92]:59286) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hDtWm-0004a9-4s for qemu-devel@nongnu.org; Tue, 09 Apr 2019 12:23:17 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hDtWk-0003VE-V7 for qemu-devel@nongnu.org; Tue, 09 Apr 2019 12:23:16 -0400 Received: from mail-wr1-x444.google.com ([2a00:1450:4864:20::444]:37291) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hDtWk-0003UF-Kr for qemu-devel@nongnu.org; Tue, 09 Apr 2019 12:23:14 -0400 Received: by mail-wr1-x444.google.com with SMTP id w10so21725274wrm.4 for ; Tue, 09 Apr 2019 09:23:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=yuUuDxVVhvaliOcBi/FPf1oamn6ohJyWlwtQJvK0xe8=; b=N4GWWyRVPkOCIEtChuIdzWi/gK31m5rK10iK9ZaAWO97j9DaFYcfm6JDajGcU1ew4s JQPAnx1jsD60XBJE1ShWdWZ+iOdtFf00hqSF4hFZIU/j3n2WjVRZzI0VP4/t+26zJuCT SqI9HvbMg+C1cI7Xz/CEvSwqwDRd6qpXGTiE8Br30VkJehRuepMmTqAe8kJ4NOxgBJGm c6S7xb0G7ruQr7CVLpAZOXB3pJpgYodBbZgMk/bDxy/J1k4PBxbdmEbfLd6CJ7k27xNM 3caU0LRscSLtczz1FlXiU/+C7z8QtHNUeywyp8VJfwryy/C/AkJLJHiRbUTwlH/3L6tV oj4g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=yuUuDxVVhvaliOcBi/FPf1oamn6ohJyWlwtQJvK0xe8=; b=i7dI8xjNL3PBb44Z2O6q7ru0j0YHzMyK+hvGR7c51Hj/hmBma6Hs4q/sRI4DCXDg19 HJxfy1UGoHFbOq8WH4NZ6nTVAkZe5MwPKVGutsCzRRwTjJrNOE+Cw51rd3n3klTpw3ua BLVIHA31tkj1Bm+c/665p0zCDb5Ga9Kr7v/42QOXt4sQI57qFgUShqHlN7OtkNkeiZRW jlGH60ojcI1B8BUO6FoGZ4XB856tzSHzrtV/Wz7wXEn7xYosQqc70E49SfMu1dS93FLs S7eBLHt1HKjK73bex6zOIWiI4StG5flrPFEqK/JOxTiEmIg7iSL545iDblKYv4oW2Ss7 8xfw== X-Gm-Message-State: APjAAAWtjrNFskEWRkrEr+CGpGbcfP5kV+c6va11xZkXJI0bohLT4wOW unLZxmdytMwKtIY+PsW4aWifapgT X-Google-Smtp-Source: APXvYqwB92SFss/xtg++wewUs//c6kiLVdJUnKMqeDvX4zxz5533S6r4vV2zO6tDf3ZEJUzZlS4ieA== X-Received: by 2002:a5d:458f:: with SMTP id p15mr23213671wrq.188.1554826993397; Tue, 09 Apr 2019 09:23:13 -0700 (PDT) Received: from 640k.lan ([93.56.166.5]) by smtp.gmail.com with ESMTPSA id e1sm59579736wrw.66.2019.04.09.09.23.12 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 09 Apr 2019 09:23:12 -0700 (PDT) From: Paolo Bonzini To: qemu-devel@nongnu.org Date: Tue, 9 Apr 2019 18:23:04 +0200 Message-Id: <1554826986-37164-4-git-send-email-pbonzini@redhat.com> X-Mailer: git-send-email 1.8.3.1 In-Reply-To: <1554826986-37164-1-git-send-email-pbonzini@redhat.com> References: <1554826986-37164-1-git-send-email-pbonzini@redhat.com> MIME-Version: 1.0 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::444 Subject: [Qemu-devel] [PULL 3/5] include/qemu/bswap.h: Use __builtin_memcpy() in accessor functions X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Peter Maydell Errors-To: qemu-devel-bounces+patchwork-qemu-devel=patchwork.kernel.org@nongnu.org Sender: "Qemu-devel" X-Virus-Scanned: ClamAV using ClamSMTP From: Peter Maydell In the accessor functions ld*_he_p() and st*_he_p() we use memcpy() to perform a load or store to a pointer which might not be aligned for the size of the type. We rely on the compiler to optimize this memcpy() into an efficient load or store instruction where possible. This is required for good performance, but at the moment it is also required for correct operation, because some users of these functions require that the access is atomic if the pointer is aligned, which will only be the case if the compiler has optimized out the memcpy(). (The particular example where we discovered this is the virtio vring_avail_idx() which calls virtio_lduw_phys_cached() which eventually ends up calling lduw_he_p().) Unfortunately some compile environments, such as the fortify-source setup used in Alpine Linux, define memcpy() to a wrapper function in a way that inhibits this compiler optimization. The correct long-term fix here is to add a set of functions for doing atomic accesses into AddressSpaces (and to other relevant families of accessor functions like the virtio_*_phys_cached() ones), and make sure that callsites which want atomic behaviour use the correct functions. In the meantime, switch to using __builtin_memcpy() in the bswap.h accessor functions. This will make us robust against things like this fortify library in the short term. In the longer term it will mean that we don't end up with these functions being really badly-performing even if the semantics of the out-of-line memcpy() are correct. Reported-by: Fernando Casas Schössow Signed-off-by: Peter Maydell Reviewed-by: Richard Henderson Message-Id: <20190318112938.8298-1-peter.maydell@linaro.org> Signed-off-by: Paolo Bonzini --- include/qemu/bswap.h | 26 ++++++++++++++++---------- 1 file changed, 16 insertions(+), 10 deletions(-) diff --git a/include/qemu/bswap.h b/include/qemu/bswap.h index 5a70f78..2a9f3fe 100644 --- a/include/qemu/bswap.h +++ b/include/qemu/bswap.h @@ -316,51 +316,57 @@ static inline void stb_p(void *ptr, uint8_t v) *(uint8_t *)ptr = v; } -/* Any compiler worth its salt will turn these memcpy into native unaligned - operations. Thus we don't need to play games with packed attributes, or - inline byte-by-byte stores. */ +/* + * Any compiler worth its salt will turn these memcpy into native unaligned + * operations. Thus we don't need to play games with packed attributes, or + * inline byte-by-byte stores. + * Some compilation environments (eg some fortify-source implementations) + * may intercept memcpy() in a way that defeats the compiler optimization, + * though, so we use __builtin_memcpy() to give ourselves the best chance + * of good performance. + */ static inline int lduw_he_p(const void *ptr) { uint16_t r; - memcpy(&r, ptr, sizeof(r)); + __builtin_memcpy(&r, ptr, sizeof(r)); return r; } static inline int ldsw_he_p(const void *ptr) { int16_t r; - memcpy(&r, ptr, sizeof(r)); + __builtin_memcpy(&r, ptr, sizeof(r)); return r; } static inline void stw_he_p(void *ptr, uint16_t v) { - memcpy(ptr, &v, sizeof(v)); + __builtin_memcpy(ptr, &v, sizeof(v)); } static inline int ldl_he_p(const void *ptr) { int32_t r; - memcpy(&r, ptr, sizeof(r)); + __builtin_memcpy(&r, ptr, sizeof(r)); return r; } static inline void stl_he_p(void *ptr, uint32_t v) { - memcpy(ptr, &v, sizeof(v)); + __builtin_memcpy(ptr, &v, sizeof(v)); } static inline uint64_t ldq_he_p(const void *ptr) { uint64_t r; - memcpy(&r, ptr, sizeof(r)); + __builtin_memcpy(&r, ptr, sizeof(r)); return r; } static inline void stq_he_p(void *ptr, uint64_t v) { - memcpy(ptr, &v, sizeof(v)); + __builtin_memcpy(ptr, &v, sizeof(v)); } static inline int lduw_le_p(const void *ptr) From patchwork Tue Apr 9 16:23:05 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Paolo Bonzini X-Patchwork-Id: 10891687 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 59D8317E0 for ; Tue, 9 Apr 2019 16:24:49 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 80EB3284C5 for ; Tue, 9 Apr 2019 16:24:41 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 7324C285D4; Tue, 9 Apr 2019 16:24:41 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.7 required=2.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI autolearn=ham version=3.3.1 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 16EA7284C5 for ; Tue, 9 Apr 2019 16:24:41 +0000 (UTC) Received: from localhost ([127.0.0.1]:45823 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hDtY8-0005s9-8c for patchwork-qemu-devel@patchwork.kernel.org; Tue, 09 Apr 2019 12:24:40 -0400 Received: from eggs.gnu.org ([209.51.188.92]:59294) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hDtWm-0004ab-LB for qemu-devel@nongnu.org; Tue, 09 Apr 2019 12:23:17 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hDtWl-0003W8-Nm for qemu-devel@nongnu.org; Tue, 09 Apr 2019 12:23:16 -0400 Received: from mail-wr1-x434.google.com ([2a00:1450:4864:20::434]:41959) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hDtWl-0003V7-Hm for qemu-devel@nongnu.org; Tue, 09 Apr 2019 12:23:15 -0400 Received: by mail-wr1-x434.google.com with SMTP id r4so21688793wrq.8 for ; Tue, 09 Apr 2019 09:23:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references; bh=LysOdumLJ0HHNb4iRzo747jgyjnNQN4WQpGaMoS1fmY=; b=q1PR5WWBv8OLoh06HepGijXB8D6ndEM9VI5wyqQXRv5lACPrp+nzf+GS7GxVRZYMBW cUctwDzrle8moIfpYpfdN/fGN7Flb3HerRthTol8UOn4exmkcmILvMsQIC8EqK2niIs9 ozF6shIf66RAvFyqIW36YkxT5AgiOKrzpDucBfPqUWXW96cWkCJb1xpc1cri+ocVIQX9 C8ox1NtEZGZ39E+osWS2gKUkequk8Y5S1E6J+nbhyGggqhPKzdsb28qq+oIWdc6PbVdX CG5A0knY59YoKq37pKchMkKxDAmNwe5wBIpjB9BSx35VbJHoeWoLk+CjBnQbRLCwASuz tDqQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references; bh=LysOdumLJ0HHNb4iRzo747jgyjnNQN4WQpGaMoS1fmY=; b=TJoQ7SdYtOlm5XGcgPTEB636yfD5t2f/GzdUSs1YTTNztNUdOy37F53aGVhOkHnIMW oSG8kcH94Kdsx95B/T4Y6w3VjK45/7J5pLVObSLCVsIHE0An8F1QNPSWxUSi7LbGAB0f yRhAOHtJX4DG8V3F/RY9H6bTqn2yrwlH8VDie/heJKkGWsESeVucjEqDM0l9AbkggQhR 9P7D4jk3jze82sNvFJmw9+DXyDY5eZpfwJjvPrcXVpIqr2ovlwY2H6wBygHDxdTmdU8B RP1CihUg4/anCBBeoNtnQ77T2Khq5EJM7QEIX/XA+lX31vu0u3VXsTpXBGpjBq1UHU4E SzPw== X-Gm-Message-State: APjAAAXy9GrwjmLquXCSMVtq3blLFx/EtVA7us9fO+wMa6t4XBd/JAxs EZMSPExjXJ4cjr1hXyMq5WKvqc7U X-Google-Smtp-Source: APXvYqxOb8iQMDW3OeuKs8lgMVluOzllPnZx0Ew6Hvd6baE4zdLvEqiqnMOcSALFuGNkRflcA4UA3Q== X-Received: by 2002:adf:f1ce:: with SMTP id z14mr23524050wro.152.1554826994262; Tue, 09 Apr 2019 09:23:14 -0700 (PDT) Received: from 640k.lan ([93.56.166.5]) by smtp.gmail.com with ESMTPSA id e1sm59579736wrw.66.2019.04.09.09.23.13 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 09 Apr 2019 09:23:13 -0700 (PDT) From: Paolo Bonzini To: qemu-devel@nongnu.org Date: Tue, 9 Apr 2019 18:23:05 +0200 Message-Id: <1554826986-37164-5-git-send-email-pbonzini@redhat.com> X-Mailer: git-send-email 1.8.3.1 In-Reply-To: <1554826986-37164-1-git-send-email-pbonzini@redhat.com> References: <1554826986-37164-1-git-send-email-pbonzini@redhat.com> X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::434 Subject: [Qemu-devel] [PULL 4/5] hw/i386/pc: Fix crash when hot-plugging nvdimm on older machine types X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Thomas Huth Errors-To: qemu-devel-bounces+patchwork-qemu-devel=patchwork.kernel.org@nongnu.org Sender: "Qemu-devel" X-Virus-Scanned: ClamAV using ClamSMTP From: Thomas Huth QEMU currently crashes when you try to hot-plug an "nvdimm" device on older machine types: $ qemu-system-x86_64 -monitor stdio -M pc-1.1 QEMU 3.1.92 monitor - type 'help' for more information (qemu) device_add nvdimm,id=nvdimmn1 qemu-system-x86_64: /home/thuth/devel/qemu/util/error.c:57: error_setv: Assertion `*errp == ((void *)0)' failed. Aborted (core dumped) The call to hotplug_handler_pre_plug() in pc_memory_pre_plug() has been added recently before the check whether nvdimm is enabled. It should be done after the check. And while we're at it, also check the errp after the hotplug_handler_pre_plug(), otherwise errors are silently ignored here. Fixes: 9040e6dfa8c3fed87695a3de555d2c775727bb51 Signed-off-by: Thomas Huth Message-Id: <20190407092314.11066-1-thuth@redhat.com> Signed-off-by: Paolo Bonzini --- hw/i386/pc.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/hw/i386/pc.c b/hw/i386/pc.c index 6077d27..f2c15bf 100644 --- a/hw/i386/pc.c +++ b/hw/i386/pc.c @@ -2078,6 +2078,7 @@ static void pc_memory_pre_plug(HotplugHandler *hotplug_dev, DeviceState *dev, const MachineState *ms = MACHINE(hotplug_dev); const bool is_nvdimm = object_dynamic_cast(OBJECT(dev), TYPE_NVDIMM); const uint64_t legacy_align = TARGET_PAGE_SIZE; + Error *local_err = NULL; /* * When -no-acpi is used with Q35 machine type, no ACPI is built, @@ -2090,13 +2091,17 @@ static void pc_memory_pre_plug(HotplugHandler *hotplug_dev, DeviceState *dev, return; } - hotplug_handler_pre_plug(pcms->acpi_dev, dev, errp); - if (is_nvdimm && !ms->nvdimms_state->is_enabled) { error_setg(errp, "nvdimm is not enabled: missing 'nvdimm' in '-M'"); return; } + hotplug_handler_pre_plug(pcms->acpi_dev, dev, &local_err); + if (local_err) { + error_propagate(errp, local_err); + return; + } + pc_dimm_pre_plug(PC_DIMM(dev), MACHINE(hotplug_dev), pcmc->enforce_aligned_dimm ? NULL : &legacy_align, errp); } From patchwork Tue Apr 9 16:23:06 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Paolo Bonzini X-Patchwork-Id: 10891713 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id A362317EF for ; Tue, 9 Apr 2019 16:37:10 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 9668728904 for ; Tue, 9 Apr 2019 16:37:10 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 893EB28917; Tue, 9 Apr 2019 16:37:10 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.7 required=2.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI autolearn=ham version=3.3.1 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 39BF328918 for ; Tue, 9 Apr 2019 16:37:10 +0000 (UTC) Received: from localhost ([127.0.0.1]:46144 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hDtkD-00072Q-Ej for patchwork-qemu-devel@patchwork.kernel.org; Tue, 09 Apr 2019 12:37:09 -0400 Received: from eggs.gnu.org ([209.51.188.92]:59310) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hDtWn-0004b9-AK for qemu-devel@nongnu.org; Tue, 09 Apr 2019 12:23:18 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hDtWm-0003Wv-EF for qemu-devel@nongnu.org; Tue, 09 Apr 2019 12:23:17 -0400 Received: from mail-wr1-x430.google.com ([2a00:1450:4864:20::430]:38760) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hDtWm-0003Vv-6m for qemu-devel@nongnu.org; Tue, 09 Apr 2019 12:23:16 -0400 Received: by mail-wr1-x430.google.com with SMTP id k11so21730020wro.5 for ; Tue, 09 Apr 2019 09:23:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references; bh=rDCyQEV68QiNrEEjUa3/5MOv4E0APgi3UE7jUK7dh9w=; b=fX/myj8Rudaimerv+kTIou3DvYgG2Zjcy5RoUWWomnAKwfUhiDpl7sUAktx2Mq6Fxf 8F1/Jjnz3vz9QRaiY+iMUNaOsHHiImj22FmRQ97Ut4b/PLX9rxricu3s2UPZB9ne2otI eElWxvauMOJ2SjA4Fxijflp63fEIZLtSa8+B4wgQ1R8+Sxx/BCkT0Dc2+fyvP9PrFIfQ mqsfYsPBUm3R9P5O/gbebnytDjvsAURzonb/RSoKK8nHYWcJCy+9rkIss7u5P5ITJGZM rr/5IbU9TPLf0DodLcxrCD0t4NwdMIFDh6yK1V7s/KYgE+qG5nB8Dxz77O/JpdoBkTbu lOWQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references; bh=rDCyQEV68QiNrEEjUa3/5MOv4E0APgi3UE7jUK7dh9w=; b=bUlGtFoFhmVZm1LnfWm3U1YizvCut/4CtLdcVk2Y/6Lc4VQdowvbFdexJo7DC6/1r6 4hFHdPII2OndlH652DGUs1Fk8h+ZcoPWUJgWAGTIL+UUVFATAgz1pbwBMgoZSXMhAD3Z +BEVkhyhcUouw+HSezXhSUlpByDvTeCo5Mzs/K0GyQvL1MpLVw9oyLlEFPgyOSJLP1HB ksZEvLjoI8vmNOu7HBQm34hk31/NtJdH65+XFc/9cI2MclGD0soos+DC186p1xDSy6Zo y85zcG9+VeLBORcW1jNq14t+pKyWO8yxMVh0gFTs+i355LCY24CaLXVZdrVKx5w+e3Xi rj/g== X-Gm-Message-State: APjAAAVR2NVojlcY6WSJrBFPzE5WYL//bAcqIutkB6rBMaC7UNcvzU3j ubLTWh88qZ8zmmT3Ungfq2q9EH+H X-Google-Smtp-Source: APXvYqyeLQa9BvTuBVZ7X0ojWQZrCU2pVHTleMWRc8HVwe+Qd0NroWnTAwETRs+13hxJq7Gz+g37jw== X-Received: by 2002:a5d:530f:: with SMTP id e15mr25218670wrv.19.1554826995063; Tue, 09 Apr 2019 09:23:15 -0700 (PDT) Received: from 640k.lan ([93.56.166.5]) by smtp.gmail.com with ESMTPSA id e1sm59579736wrw.66.2019.04.09.09.23.14 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 09 Apr 2019 09:23:14 -0700 (PDT) From: Paolo Bonzini To: qemu-devel@nongnu.org Date: Tue, 9 Apr 2019 18:23:06 +0200 Message-Id: <1554826986-37164-6-git-send-email-pbonzini@redhat.com> X-Mailer: git-send-email 1.8.3.1 In-Reply-To: <1554826986-37164-1-git-send-email-pbonzini@redhat.com> References: <1554826986-37164-1-git-send-email-pbonzini@redhat.com> X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::430 Subject: [Qemu-devel] [PULL 5/5] tests: Make check-block a phony target X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Markus Armbruster Errors-To: qemu-devel-bounces+patchwork-qemu-devel=patchwork.kernel.org@nongnu.org Sender: "Qemu-devel" X-Virus-Scanned: ClamAV using ClamSMTP From: Markus Armbruster Fixes: b93b63f574c "test makefile overhaul" Signed-off-by: Markus Armbruster Reviewed-by: Eric Blake Message-Id: <20190319072104.32591-1-armbru@redhat.com> Signed-off-by: Paolo Bonzini --- tests/Makefile.include | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/Makefile.include b/tests/Makefile.include index 6b904d7..36fc73f 100644 --- a/tests/Makefile.include +++ b/tests/Makefile.include @@ -1164,7 +1164,7 @@ check-acceptance: check-venv $(TESTS_RESULTS_DIR) # Consolidated targets -.PHONY: check-qapi-schema check-qtest check-unit check check-clean +.PHONY: check-block check-qapi-schema check-qtest check-unit check check-clean check-qapi-schema: $(patsubst %,check-%, $(check-qapi-schema-y)) check-tests/qapi-schema/doc-good.texi check-qtest: $(patsubst %,check-qtest-%, $(QTEST_TARGETS)) check-block: $(patsubst %,check-%, $(check-block-y))