| 1 | hw_display_modules = {} |
| 2 | |
| 3 | system_ss.add(when: 'CONFIG_DDC', if_true: files('i2c-ddc.c')) |
| 4 | system_ss.add(when: 'CONFIG_EDID', if_true: files('edid-generate.c', 'edid-region.c')) |
| 5 | |
| 6 | system_ss.add(when: 'CONFIG_FW_CFG_DMA', if_true: files('ramfb.c')) |
| 7 | stub_ss.add(files('ramfb-stubs.c')) |
| 8 | system_ss.add(when: 'CONFIG_FW_CFG_DMA', if_true: files('ramfb-standalone.c')) |
| 9 | |
| 10 | system_ss.add(when: 'CONFIG_VGA_CIRRUS', if_true: files('cirrus_vga.c')) |
| 11 | system_ss.add(when: ['CONFIG_VGA_CIRRUS', 'CONFIG_VGA_ISA'], if_true: files('cirrus_vga_isa.c')) |
| 12 | system_ss.add(when: 'CONFIG_G364FB', if_true: files('g364fb.c')) |
| 13 | system_ss.add(when: 'CONFIG_JAZZ_LED', if_true: files('jazz_led.c')) |
| 14 | system_ss.add(when: 'CONFIG_PL110', if_true: files('pl110.c')) |
| 15 | system_ss.add(when: 'CONFIG_IMX6UL_LCDIF', if_true: files('imx6ul_lcdif.c')) |
| 16 | system_ss.add(when: 'CONFIG_SII9022', if_true: files('sii9022.c')) |
| 17 | system_ss.add(when: 'CONFIG_SSD0303', if_true: files('ssd0303.c')) |
| 18 | system_ss.add(when: 'CONFIG_SSD0323', if_true: files('ssd0323.c')) |
| 19 | system_ss.add(when: 'CONFIG_XEN_BUS', if_true: files('xenfb.c')) |
| 20 | |
| 21 | system_ss.add(when: 'CONFIG_VGA_PCI', if_true: files('vga-pci.c')) |
| 22 | system_ss.add(when: 'CONFIG_VGA_ISA', if_true: files('vga-isa.c')) |
| 23 | system_ss.add(when: 'CONFIG_VGA_MMIO', if_true: files('vga-mmio.c')) |
| 24 | system_ss.add(when: 'CONFIG_VMWARE_VGA', if_true: files('vmware_vga.c')) |
| 25 | system_ss.add(when: 'CONFIG_BOCHS_DISPLAY', if_true: files('bochs-display.c')) |
| 26 | |
| 27 | system_ss.add(when: 'CONFIG_EXYNOS4', if_true: files('exynos4210_fimd.c')) |
| 28 | system_ss.add(when: 'CONFIG_FRAMEBUFFER', if_true: files('framebuffer.c')) |
| 29 | |
| 30 | system_ss.add(when: 'CONFIG_RASPI', if_true: files('bcm2835_fb.c')) |
| 31 | system_ss.add(when: 'CONFIG_SM501', if_true: files('sm501.c')) |
| 32 | system_ss.add(when: 'CONFIG_TCX', if_true: files('tcx.c')) |
| 33 | system_ss.add(when: 'CONFIG_CG3', if_true: files('cg3.c')) |
| 34 | system_ss.add(when: 'CONFIG_MACFB', if_true: files('macfb.c')) |
| 35 | system_ss.add(when: 'CONFIG_NEXTCUBE', if_true: files('next-fb.c')) |
| 36 | |
| 37 | system_ss.add(when: 'CONFIG_VGA', if_true: files('vga.c')) |
| 38 | system_ss.add(when: 'CONFIG_VIRTIO', if_true: files('virtio-dmabuf.c')) |
| 39 | system_ss.add(when: 'CONFIG_DM163', if_true: files('dm163.c')) |
| 40 | |
| 41 | stub_ss.add([files('acpi-vga-stub.c'), pixman]) |
| 42 | if (config_all_devices.has_key('CONFIG_VGA_CIRRUS') or |
| 43 | config_all_devices.has_key('CONFIG_VGA_PCI') or |
| 44 | config_all_devices.has_key('CONFIG_VMWARE_VGA') or |
| 45 | config_all_devices.has_key('CONFIG_ATI_VGA') |
| 46 | ) |
| 47 | system_ss.add(when: 'CONFIG_ACPI', if_true: files('acpi-vga.c')) |
| 48 | endif |
| 49 | |
| 50 | if config_all_devices.has_key('CONFIG_QXL') |
| 51 | qxl_ss = ss.source_set() |
| 52 | qxl_ss.add(when: 'CONFIG_QXL', if_true: [files('qxl.c', 'qxl-logger.c', 'qxl-render.c'), |
| 53 | pixman, spice]) |
| 54 | qxl_ss.add(when: 'CONFIG_ACPI', if_true: files('acpi-vga.c')) |
| 55 | hw_display_modules += {'qxl': qxl_ss} |
| 56 | endif |
| 57 | |
| 58 | system_ss.add(when: 'CONFIG_DPCD', if_true: files('dpcd.c')) |
| 59 | system_ss.add(when: 'CONFIG_XLNX_DISPLAYPORT', if_true: files('xlnx_dp.c')) |
| 60 | |
| 61 | system_ss.add(when: 'CONFIG_ARTIST', if_true: files('artist.c')) |
| 62 | |
| 63 | system_ss.add(when: 'CONFIG_ATI_VGA', if_true: [files('ati.c', 'ati_2d.c', 'ati_dbg.c'), pixman]) |
| 64 | |
| 65 | system_ss.add(when: [pvg, 'CONFIG_MAC_PVG_PCI'], if_true: [files('apple-gfx.m', 'apple-gfx-pci.m')]) |
| 66 | system_ss.add(when: [pvg, 'CONFIG_MAC_PVG_MMIO'], if_true: [files('apple-gfx.m', 'apple-gfx-mmio.m')]) |
| 67 | |
| 68 | if config_all_devices.has_key('CONFIG_VIRTIO_GPU') |
| 69 | virtio_gpu_ss = ss.source_set() |
| 70 | virtio_gpu_ss.add(when: 'CONFIG_VIRTIO_GPU', |
| 71 | if_true: [files('virtio-gpu-base.c', 'virtio-gpu.c'), pixman]) |
| 72 | if host_os == 'linux' |
| 73 | virtio_gpu_ss.add(files('virtio-gpu-udmabuf.c')) |
| 74 | else |
| 75 | virtio_gpu_ss.add(files('virtio-gpu-udmabuf-stubs.c')) |
| 76 | endif |
| 77 | virtio_gpu_ss.add(when: 'CONFIG_VHOST_USER_GPU', if_true: files('vhost-user-gpu.c')) |
| 78 | hw_display_modules += {'virtio-gpu': virtio_gpu_ss} |
| 79 | |
| 80 | if virgl.found() and opengl.found() |
| 81 | virtio_gpu_gl_ss = ss.source_set() |
| 82 | virtio_gpu_gl_ss.add(when: ['CONFIG_VIRTIO_GPU', virgl, opengl], |
| 83 | if_true: [files('virtio-gpu-gl.c', 'virtio-gpu-virgl.c'), pixman, virgl]) |
| 84 | hw_display_modules += {'virtio-gpu-gl': virtio_gpu_gl_ss} |
| 85 | endif |
| 86 | |
| 87 | if rutabaga.found() |
| 88 | virtio_gpu_rutabaga_ss = ss.source_set() |
| 89 | virtio_gpu_rutabaga_ss.add(when: ['CONFIG_VIRTIO_GPU', rutabaga], |
| 90 | if_true: [files('virtio-gpu-rutabaga.c'), pixman]) |
| 91 | hw_display_modules += {'virtio-gpu-rutabaga': virtio_gpu_rutabaga_ss} |
| 92 | endif |
| 93 | endif |
| 94 | |
| 95 | if config_all_devices.has_key('CONFIG_VIRTIO_PCI') |
| 96 | virtio_gpu_pci_ss = ss.source_set() |
| 97 | virtio_gpu_pci_ss.add(when: ['CONFIG_VIRTIO_GPU', 'CONFIG_VIRTIO_PCI'], |
| 98 | if_true: [files('virtio-gpu-pci.c'), pixman]) |
| 99 | virtio_gpu_pci_ss.add(when: ['CONFIG_VHOST_USER_GPU', 'CONFIG_VIRTIO_PCI'], |
| 100 | if_true: files('vhost-user-gpu-pci.c')) |
| 101 | hw_display_modules += {'virtio-gpu-pci': virtio_gpu_pci_ss} |
| 102 | |
| 103 | if virgl.found() and opengl.found() |
| 104 | virtio_gpu_pci_gl_ss = ss.source_set() |
| 105 | virtio_gpu_pci_gl_ss.add(when: ['CONFIG_VIRTIO_GPU', 'CONFIG_VIRTIO_PCI', virgl, opengl], |
| 106 | if_true: [files('virtio-gpu-pci-gl.c'), pixman]) |
| 107 | hw_display_modules += {'virtio-gpu-pci-gl': virtio_gpu_pci_gl_ss} |
| 108 | endif |
| 109 | if rutabaga.found() |
| 110 | virtio_gpu_pci_rutabaga_ss = ss.source_set() |
| 111 | virtio_gpu_pci_rutabaga_ss.add(when: ['CONFIG_VIRTIO_GPU', 'CONFIG_VIRTIO_PCI', rutabaga], |
| 112 | if_true: [files('virtio-gpu-pci-rutabaga.c'), pixman]) |
| 113 | hw_display_modules += {'virtio-gpu-pci-rutabaga': virtio_gpu_pci_rutabaga_ss} |
| 114 | endif |
| 115 | endif |
| 116 | |
| 117 | if config_all_devices.has_key('CONFIG_VIRTIO_VGA') |
| 118 | virtio_vga_ss = ss.source_set() |
| 119 | virtio_vga_ss.add(when: 'CONFIG_VIRTIO_VGA', |
| 120 | if_true: [files('virtio-vga.c'), pixman]) |
| 121 | virtio_vga_ss.add(when: 'CONFIG_VHOST_USER_VGA', |
| 122 | if_true: files('vhost-user-vga.c')) |
| 123 | virtio_vga_ss.add(when: 'CONFIG_ACPI', if_true: files('acpi-vga.c')) |
| 124 | hw_display_modules += {'virtio-vga': virtio_vga_ss} |
| 125 | |
| 126 | if virgl.found() and opengl.found() |
| 127 | virtio_vga_gl_ss = ss.source_set() |
| 128 | virtio_vga_gl_ss.add(when: ['CONFIG_VIRTIO_VGA', virgl, opengl], |
| 129 | if_true: [files('virtio-vga-gl.c'), pixman]) |
| 130 | virtio_vga_gl_ss.add(when: 'CONFIG_ACPI', if_true: files('acpi-vga.c')) |
| 131 | hw_display_modules += {'virtio-vga-gl': virtio_vga_gl_ss} |
| 132 | endif |
| 133 | |
| 134 | if rutabaga.found() |
| 135 | virtio_vga_rutabaga_ss = ss.source_set() |
| 136 | virtio_vga_rutabaga_ss.add(when: ['CONFIG_VIRTIO_VGA', rutabaga], |
| 137 | if_true: [files('virtio-vga-rutabaga.c'), pixman]) |
| 138 | virtio_vga_rutabaga_ss.add(when: 'CONFIG_ACPI', if_true: files('acpi-vga.c')) |
| 139 | hw_display_modules += {'virtio-vga-rutabaga': virtio_vga_rutabaga_ss} |
| 140 | endif |
| 141 | endif |
| 142 | |
| 143 | system_ss.add(when: 'CONFIG_OMAP', if_true: files('omap_lcdc.c')) |
| 144 | |
| 145 | modules += { 'hw-display': hw_display_modules } |