qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH] MIPS: DMA support for RC4030 chipset [v4]


From: Aurelien Jarno
Subject: Re: [Qemu-devel] [PATCH] MIPS: DMA support for RC4030 chipset [v4]
Date: Tue, 30 Dec 2008 01:30:22 +0100
User-agent: Mutt/1.5.18 (2008-05-17)

On Sat, Dec 27, 2008 at 07:09:18PM +0100, Hervé Poussineau wrote:
> Hi,
>
> Attached patch implements DMA support to RC4030 chipset and simplifies  
> jazz IO part (at 0xf0000000), where registers contain 16 bit values.
> The patch also wires DMA transfers for the SCSI adapter in the Jazz  
> emulation (Mips Magnum 4000 and Acer Pica 61).
>
> Signed-off-by: Hervé Poussineau <address@hidden>
>
> Changes since v1:
> - Support reuse of esp callback functions up to DMA engine
> - Don't keep in memory the DMA table, but read it when needed
>
> Changes since v2:
> - Don't use cpu_single_env in the DMA transfer function, as it is NULL  
> in the aio path
> - Multiple improvements to the DMA transfer function: report errors to  
> the caller, support for non contiguous physical pages...
>
> Changes since v3:
> - Mask out higher bits of DMA translation table address
>

This patches introduces some new warnings:
/home/aurel32/git/qemu/hw/rc4030.c: In function ‘rc4030_readl’:
/home/aurel32/git/qemu/hw/rc4030.c:227: warning: format ‘%08x’ expects type 
‘unsigned int’, but argument 4 has type ‘target_phys_addr_t’
/home/aurel32/git/qemu/hw/rc4030.c: In function ‘rc4030_writel’:
/home/aurel32/git/qemu/hw/rc4030.c:374: warning: format ‘%08x’ expects type 
‘unsigned int’, but argument 5 has type ‘target_phys_addr_t’
/home/aurel32/git/qemu/hw/rc4030.c: In function ‘jazzio_readw’:
/home/aurel32/git/qemu/hw/rc4030.c:501: warning: format ‘%08x’ expects type 
‘unsigned int’, but argument 4 has type ‘target_phys_addr_t’
/home/aurel32/git/qemu/hw/rc4030.c: In function ‘jazzio_writew’:
/home/aurel32/git/qemu/hw/rc4030.c:539: warning: format ‘%08x’ expects type 
‘unsigned int’, but argument 5 has type ‘target_phys_addr_t’

Also, please include a Signed-off.

[snip]

> +    jazzio_writeb,
> +    jazzio_writew,
> +    jazzio_writel,
>  };
>  
> -#define G364_512KB_RAM (0x0)
> -#define G364_2MB_RAM   (0x1)
> -#define G364_8MB_RAM   (0x2)
> -#define G364_32MB_RAM  (0x3)
> -
>  static void rc4030_reset(void *opaque)
>  {
>      rc4030State *s = opaque;
>      int i;
>  
> -    s->config = (G364_2MB_RAM << 8) | 0x04;
> +    s->config = 0x410;

Why this change? This make the resulting code less readable.

>      s->invalid_address_register = 0;
>  
>      memset(s->dma_regs, 0, sizeof(s->dma_regs));
> @@ -569,7 +589,6 @@
>      s->cache_ptag = s->cache_ltag = 0;
>      s->cache_bmask = s->cache_bwin = 0;
>  
 
-- 
  .''`.  Aurelien Jarno             | GPG: 1024D/F1BCDB73
 : :' :  Debian developer           | Electrical Engineer
 `. `'   address@hidden         | address@hidden
   `-    people.debian.org/~aurel32 | www.aurel32.net




reply via email to

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