qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] Re: pci_default_config_write() clean up.


From: Michael S. Tsirkin
Subject: Re: [Qemu-devel] Re: pci_default_config_write() clean up.
Date: Thu, 7 May 2009 14:46:09 +0300
User-agent: Mutt/1.5.18 (2008-05-17)

On Thu, May 07, 2009 at 08:13:51PM +0900, Isaku Yamahata wrote:
> On Thu, May 07, 2009 at 01:25:38PM +0300, Michael S. Tsirkin wrote:
> > > How about callback?
> > 
> > Yes, I think callbacks have the potential to simplify code.
> > Would you like to add them on top of my patch then?
> 
> Okay.
> 
> > - There's some tricky code there to trigger callbacks only once
> >   on a multibyte transaction. It would be simpler just to have per-dword
> >   callbacks.  These could get the mask of the written-to bytes and do
> >     if (written_mask & interesting_mask)
> >             stuff
> 
> Are you assuming that word/dword io port access is word/dword aligned?

I think this does not have to be the case in I/O generally.
However I think that configuration cycles specifically can never cross a
dword boundary (and if they could, I think that PCI spec does not define
any registers that cross dword boundary).

I found this in the PCI spec:
Register Number is an encoded value used to select a DWORD in the
Configuration Space of the intended target.


-- 
MST




reply via email to

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