On Tuesday 21 February 2012 01:41:21 Simon Glass wrote:
> --- /dev/null
> +++ b/common/fdt_decode.c
>
> +static struct fdt_compat compat_types[] = {

const

> +void fdt_decode_uart_calc_divisor(struct fdt_uart *uart)
> +{
> +     if (uart->multiplier && uart->baudrate)
> +             uart->divisor = (uart->clock_freq +
> +                             (uart->baudrate * (uart->multiplier / 2))) /
> +                     (uart->multiplier * uart->baudrate);
> +}

does the multiplier really need to be part of device tree ?

> +int fdt_decode_get_spi_switch(const void *blob, struct fdt_spi_uart
> *config) +{
> +     int node, uart_node;
> +     const u32 *gpio;
> +
> +     node = fdt_node_offset_by_compatible(blob, 0,
> +                                          "nvidia,spi-uart-switch");

what's with the hardcoded SoC names in common code ?

> --- /dev/null
> +++ b/drivers/serial/serial_fdt.c
>
> +void uart_calc_divisor(struct fdt_uart *uart)
> +{
> +     if (uart->multiplier && uart->baudrate)
> +             uart->divisor = (uart->clock_freq +
> +                             (uart->baudrate * (uart->multiplier / 2))) /
> +                     (uart->multiplier * uart->baudrate);
> +}

isn't this exactly the same as fdt_decode_uart_calc_divisor ?
-mike

Attachment: signature.asc
Description: This is a digitally signed message part.

_______________________________________________
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot

Reply via email to