Re: [RFC 1/2] hw/ppc/ppc440_uc: Initialize length passed to cpu_physical_memory_map()

2022-07-28 Thread Peter Maydell
On Wed, 27 Jul 2022 at 15:11, Daniel Henrique Barboza wrote: > > > > On 7/26/22 15:24, Peter Maydell wrote: > > On Tue, 26 Jul 2022 at 19:23, Peter Maydell > > wrote: > >> > >> In dcr_write_dma(), there is code that uses cpu_physical_memory_map() > >> to implement a DMA transfer. That function

Re: [RFC 1/2] hw/ppc/ppc440_uc: Initialize length passed to cpu_physical_memory_map()

2022-07-27 Thread Daniel Henrique Barboza
On 7/26/22 15:24, Peter Maydell wrote: On Tue, 26 Jul 2022 at 19:23, Peter Maydell wrote: In dcr_write_dma(), there is code that uses cpu_physical_memory_map() to implement a DMA transfer. That function takes a 'plen' argument, which points to a hwaddr which is used for both input and

Re: [RFC 1/2] hw/ppc/ppc440_uc: Initialize length passed to cpu_physical_memory_map()

2022-07-26 Thread Richard Henderson
On 7/26/22 11:23, Peter Maydell wrote: In dcr_write_dma(), there is code that uses cpu_physical_memory_map() to implement a DMA transfer. That function takes a 'plen' argument, which points to a hwaddr which is used for both input and output: the caller must set it to the size of the range it

Re: [RFC 1/2] hw/ppc/ppc440_uc: Initialize length passed to cpu_physical_memory_map()

2022-07-26 Thread Peter Maydell
On Tue, 26 Jul 2022 at 19:23, Peter Maydell wrote: > > In dcr_write_dma(), there is code that uses cpu_physical_memory_map() > to implement a DMA transfer. That function takes a 'plen' argument, > which points to a hwaddr which is used for both input and output: the > caller must set it to the

[RFC 1/2] hw/ppc/ppc440_uc: Initialize length passed to cpu_physical_memory_map()

2022-07-26 Thread Peter Maydell
In dcr_write_dma(), there is code that uses cpu_physical_memory_map() to implement a DMA transfer. That function takes a 'plen' argument, which points to a hwaddr which is used for both input and output: the caller must set it to the size of the range it wants to map, and on return it is updated