qemu-trivial
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-trivial] [Qemu-devel] [PATCH] ioport/memory: check that both .


From: Peter Crosthwaite
Subject: Re: [Qemu-trivial] [Qemu-devel] [PATCH] ioport/memory: check that both .read and .write callbacks are defined
Date: Tue, 11 Jun 2013 08:30:12 +1000

Hi Michael,

On Tue, Jun 11, 2013 at 3:06 AM, Michael S. Tsirkin <address@hidden> wrote:
> On Mon, Jun 10, 2013 at 07:14:45PM +1000, Peter Crosthwaite wrote:
>> Hi,
>>
>> On Mon, Jun 10, 2013 at 3:27 PM, Gerd Hoffmann <address@hidden> wrote:
>> >   Hi,
>> >
>> >> Maybe instead (or in addition to), we should provide a dummy
>> >> read or write functions -- instead of fixing each such occurence
>> >> to use its own dummy function
>> >
>> > Makes sense, especially for write where we can just ignore what the
>> > guest attempts to write.  Not sure we can have a generic handler for
>> > reads.  Maybe two, one which returns 0xff and one which returns 0x00.
>> >
>>
>> FWIW, I have one in my tree that qemu_log(LOG_GUEST_ERROR's such
>> accesses that I use for unimplemented devices. It's worthwhile to trap
>> such accesses and speaking for the Xilinx LQSPI case, my preference is
>> for some form of failure rather than silent write-ignore. And can we
>> have an option where a invalid writes have consistent behavior with
>> unassigned accesses?
>>
>> Regards,
>> Peter
>
> Probably not a good idea. Ignoring unassigned addresses
> is very handy for compatibility: we can run new guests
> on old qemu and They don't crash or log errors.
>

Log errors do not crash QEMU even if they are enabled. They just make
noise and even then only if you pass -d guest_errors (which we do as
pretty much habit now for this reason). It is the compromise solution
between those of us who want to ignore them and those of us who need
to know about them. The default behavior will still be to ignore
accesses with no action.

Regards,
Peter

>> > cheers,
>> >   Gerd
>> >
>> >
>



reply via email to

[Prev in Thread] Current Thread [Next in Thread]