[U-Boot-Users] i.MX31: mx31_gpio_mux() problem

Magnus Lilja lilja.magnus at gmail.com
Thu Jun 19 23:02:02 CEST 2008


>> The first approach has the advantage that you can define convenience
>> macros like MUX_RXD1__UART1_RXD_MUX which makes it easy to setup new
>> boards by only reading the definition instead of crawling the datasheet
>> for Alternate function assignments once the list of defined is somewhat
>> completed. Looking in the datasheet for every new pin is a pain and
>> error prone.
>
>
> Thanks for the background info. I'll try to submit a patch in a couple
> of days (using the first approach).

Seems to like there are some typos in the current convenience macros already:

#define MUX_RTS1__UART1_RTS_B   ((MUX_CTL_FUNC << 8) | MUX_CTL_RTS1)
#define MUX_RTS1__UART1_CTS_B   ((MUX_CTL_FUNC << 8) | MUX_CTL_CTS1)

The last one should be
#define MUX_CTS1__UART1_CTS_B   ((MUX_CTL_FUNC << 8) | MUX_CTL_CTS1)

More..
#define MUX_CSPI2_MOSI__I2C2_SCL ((MUX_CTL_ALT1 << 8) | MUX_CTL_CSPI2_MOSI)
#define MUX_CSPI2_MISO__I2C2_SCL ((MUX_CTL_ALT1 << 8) | MUX_CTL_CSPI2_MISO)

The last one should be:
#define MUX_CSPI2_MISO__I2C2_SDA ((MUX_CTL_ALT1 << 8) | MUX_CTL_CSPI2_MISO)


I'll include that in my patch as well if there are no objections.


/Magnus




More information about the U-Boot mailing list