Am 23.01.2012 08:20, schrieb Peter A. G. Crosthwaite:
> Device model for Cadence UART
> 
> Signed-off-by: Peter A. G. Crosthwaite <peter.crosthwa...@petalogix.com>
> ---
>  Makefile.target   |    1 +
>  hw/cadence_uart.c |  619 
> +++++++++++++++++++++++++++++++++++++++++++++++++++++
>  2 files changed, 620 insertions(+), 0 deletions(-)
>  create mode 100644 hw/cadence_uart.c

> diff --git a/hw/cadence_uart.c b/hw/cadence_uart.c
> new file mode 100644
> index 0000000..931ff2c
> --- /dev/null
> +++ b/hw/cadence_uart.c

> +typedef struct {
[...]
> +} uart_state;

Coding Style mandates CamelCase for structs.

> +static void uart_register_devices(void)
> +{
> +    sysbus_register_dev("cadence_uart", sizeof(uart_state),
> +                        uart_init);

Please use sysbus_register_withprop() instead, for the upcoming QOM
conversion.

Could you also consider adding VMState for the devices, to allow
load/save? If not, they should at least be marked as unmigratable.

> +}

Andreas

-- 
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer; HRB 16746 AG Nürnberg

Reply via email to