[U-Boot] [PATCH v2 2/7] serial: Allow boards to determine whether a serial device is usable

Simon Glass sjg at chromium.org
Wed Jan 17 19:39:38 UTC 2018


Hi Alex,

On 17 January 2018 at 00:54, Alexander Graf <agraf at suse.de> wrote:
> On some boards, serial devices may or may not be muxed properly to actual
> pins, depending on firmware configuration. To determine whether we should
> use a serial device for U-Boot in-/output, we need to check whether it
> is muxed properly.
>
> This is something only the board file can do, so let's expose a weak
> function that a board can override to explicitly allow or disallow
> usage of certain serial devices.
>
> Signed-off-by: Alexander Graf <agraf at suse.de>
> ---
>  drivers/serial/serial-uclass.c | 11 +++++++++++
>  include/serial.h               | 11 +++++++++++
>  2 files changed, 22 insertions(+)
>

Can we please figure out how handle this in the serial driver / driver
model itself? I want to avoid weak functions with driver model.

Regards,
Simon


More information about the U-Boot mailing list