qemu-devel
[Top][All Lists]
Advanced

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

Re: [PATCH] mos6522: remove anh register


From: Philippe Mathieu-Daudé
Subject: Re: [PATCH] mos6522: remove anh register
Date: Sat, 14 Dec 2019 14:19:33 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.2.2

On 12/14/19 11:47 AM, Mark Cave-Ayland wrote:
On 13/12/2019 08:45, Laurent Vivier wrote:
Le 13/12/2019 à 02:44, David Gibson a écrit :
On Thu, Dec 12, 2019 at 08:43:59PM +0100, Laurent Vivier wrote:
Register addr 1 is defined as buffer A with handshake (vBufAH),
register addr 15 is also defined as buffer A without handshake (vBufA).

Linux kernel has a big "DON'T USE!" next to the register 1 addr
definition (vBufAH), and only uses register 15 (vBufA).

So remove the definition of 'anh' and use only 'a' (with VIA_REG_ANH and
VIA_REG_A).

I'm not actually following the rationale for removing the register.
Linux doesn't use it, but if it's part of the real hardware model we
should keep it, no?

It's actually two methods to access the same register (with handshake,
without handshake).

In the datashit Register 15 is described as "Same as register 1 except
no handshake".

Indeed, certainly my reading of the specification was that it was the same 
register.
I'd be inclined to add qemu_log() at unimp for the handshake registers so at 
least we
can easily spot if anything is using them.

Agreed, clever than my review suggestion.

     case VIA_REG_A:
+        qemu_log_mask(LOG_UNIMP, ...);
+        /* fall through */
+    case VIA_REG_ANH:
         val = s->a;
         break;




reply via email to

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