On Thu, 16 Jul 2020 at 17:55, P J P <ppan...@redhat.com> wrote: > > +-- On Thu, 16 Jul 2020, Peter Maydell wrote --+ > | > +static void imx7_digprog_write(void *opaque, hwaddr addr, > | > + uint64_t data, unsigned size) > | > +{ > | > + qemu_log_mask(LOG_UNIMP, "%s not implemented\n", __func__); > | > +} > | > | This covers a single register (DIGPROG) which is read-only (it returns a > | silicon revision number). So this is not a LOG_UNIMP, but a LOG_GUEST_ERROR: > | > | qemu_log_mask(LOG_GUEST_ERROR, "Guest write to read-only > | ANALOG_DIGPROG register\n"); > > Should this be g_assert_not_reached() in that case?
No, because a malicious guest can write to the register (and cause the function to be called), it is merely that it is a bug in guest code for it to do that. -- PMM