On Mon, 22 Jan 2024 at 11:10, Philippe Mathieu-Daudé <[email protected]> wrote: > On 22/1/24 10:42, Paolo Bonzini wrote: > > Always allow -dtb in qemu-system-xtensa. Basically all other targets > > require > > it if it can be used (including for example i386/x86_64).
> I've been wondering for some time why not requires libfdt > for all sysemu targets. It gives some pain with MIPS machines, > and I wonder if there is any value in not including it. I think traditionally we wanted to avoid the dependency for the common case of "I only care about x86 guests", back when fdt was mostly limited to ppc or arm, but since these days even x86 sets TARGET_NEED_FDT there's something to be said for just making it obligatory. Guest archs which *don't* use fdt: alpha cris hppa m68k s390x sh4 sparc tricore xtensa. Of those, s390x is the only one with KVM support and so the only one where maybe somebody might care about the extra dependency for security auditing purposes. But given it's already in x86 binaries I don't think that's a very strong argument. The rest are all "minor" architectures. So if making fdt mandatory makes our lives easier for development purposes I think we should go ahead and do it. (mips is a bit odd because only mips64el-softmmu sets TARGET_NEED_FDT, not the other mips configs. Since upstream Linux has an arch/mips/boot/dts/mti/malta.dts, presumably in theory the 32-bit boards also ought to support -dtb and friends; though CONFIG_MIPS_RAW_APPENDED_DTB makes this not a problem in practice.) thanks -- PMM
