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

Re: [PATCH v3 03/24] arm/vuart: add hwdom prefix to UART emulator



On Monday, January 27th, 2025 at 2:58 PM, Jason Andryuk <jason.andryuk@xxxxxxx> 
wrote:

> 
> 
> On 2025-01-03 20:58, Denis Mukhin via B4 Relay wrote:
> 
> > From: Denis Mukhin dmukhin@xxxxxxxx
> > 
> > Using "vuart" in UART emulator designed for hardware domain debugging
> > is confusing in generic Arm code (e.g. vpl011 is also "vuart").
> > Fix that by adding hwdom prefix to all symbols in arm/vuart.c.
> > 
> > Also, remove domain_has_vuart() from arm/vuart.c since it is not needed.
> > 
> > Signed-off-by: Denis Mukhin dmukhin@xxxxxxxx
> 
> > diff --git a/xen/arch/arm/vuart.c b/xen/arch/arm/vuart.c
> > index 
> > 98a65b99385a2a119725bab8634ed7cf9d926d68..23e05dba3a5617863f6c08f085c358f2cf32a292
> >  100644
> > --- a/xen/arch/arm/vuart.c
> > +++ b/xen/arch/arm/vuart.c
> 
> > @@ -66,15 +64,12 @@ int domain_vuart_init(struct domain *d)
> > return 0;
> > }
> > 
> > -void domain_vuart_free(struct domain *d)
> > +void hwdom_vuart_free(struct domain *d)
> > {
> > - if ( !domain_has_vuart(d) )
> > - return;
> > -
> > - xfree(d->arch.vuart.buf);
> > + XFREE(d->arch.vuart.buf);
> 
> 
> I guess the code before and now both relied on struct domain being
> zero-initialized. You've made the free depend on the actual buffer
> instead of info as a proxy.
> 
> Reviewed-by: Jason Andryuk jason.andryuk@xxxxxxx

Thank you.

> 
> 
> Regards,
> Jason



 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.