[Qemu-devel] [PATCH] hw/display/ramfb: Compile the ramfb code only when CONFIG_FW_CFG_DMA is set

Thomas Huth posted 1 patch 7 years, 2 months ago
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/qemu tags/patchew/1534786083-26559-1-git-send-email-thuth@redhat.com
Test checkpatch passed
Test docker-mingw@fedora passed
Test docker-clang@ubuntu passed
Test docker-quick@centos7 passed
hw/display/Makefile.objs | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
[Qemu-devel] [PATCH] hw/display/ramfb: Compile the ramfb code only when CONFIG_FW_CFG_DMA is set
Posted by Thomas Huth 7 years, 2 months ago
According to the ramfb_setup() function, the ramfb device needs fw_cfg
with DMA, so we should also only compile and link it into those targets
which support it, to avoid that the device shows up on systems where it
can not be used at all (e.g. s390x).

Signed-off-by: Thomas Huth <thuth@redhat.com>
---
 hw/display/Makefile.objs | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/hw/display/Makefile.objs b/hw/display/Makefile.objs
index fb8408c..a606fb7 100644
--- a/hw/display/Makefile.objs
+++ b/hw/display/Makefile.objs
@@ -1,5 +1,5 @@
-common-obj-y += ramfb.o
-common-obj-y += ramfb-standalone.o
+common-obj-$(CONFIG_FW_CFG_DMA) += ramfb.o
+common-obj-$(CONFIG_FW_CFG_DMA) += ramfb-standalone.o
 
 common-obj-$(CONFIG_ADS7846) += ads7846.o
 common-obj-$(CONFIG_VGA_CIRRUS) += cirrus_vga.o
-- 
1.8.3.1


Re: [Qemu-devel] [PATCH] hw/display/ramfb: Compile the ramfb code only when CONFIG_FW_CFG_DMA is set
Posted by Gerd Hoffmann 7 years, 2 months ago
On Mon, Aug 20, 2018 at 07:28:03PM +0200, Thomas Huth wrote:
> According to the ramfb_setup() function, the ramfb device needs fw_cfg
> with DMA, so we should also only compile and link it into those targets
> which support it, to avoid that the device shows up on systems where it
> can not be used at all (e.g. s390x).
> 
> Signed-off-by: Thomas Huth <thuth@redhat.com>

Added to vga queue.

thanks,
  Gerd