[U-Boot] [PATCH] BeagleBoard: Added LED driver

Wolfgang Denk wd at denx.de
Sun Nov 7 22:38:45 CET 2010


Dear Jason Kridner,

In message <AANLkTim71JeaAkjbHNHfv8FqDvcc5L=ES1XFbwLBmt8r at mail.gmail.com> you wrote:
>
> > [sp] I see too many ifdef blocks in the code above. The also seems to be
> >     repetitive.
> >
> >     Is user really expected to change the u-boot config for each LED > bit/color?
>
> This is the existing architecture in status_led.h.  I want to make
> sure this code compiles no matter which of the defines have been set.
>
> >     Can this be simplified by one function that takes an argument?
>
> Do you mean set vs. toggle?  I think that would be great too, but
> again following an existing definition.

Please don;t stick with bad examples just because they exist.

Please feel free to come up ith an improvement.

If you have time and resources, please feel free to clean up the
status_led code as well.

Best regards,

Wolfgang Denk

-- 
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
Don't panic.


More information about the U-Boot mailing list