Hi Andrey. On Thu, Jun 14, 2018 at 09:11:10PM -0700, Andrey Smirnov wrote: > Move all of the shared code into lib/console.c and convert both files > to use that. > > Signed-off-by: Andrey Smirnov <andrew.smirnov@xxxxxxxxx> > --- > +++ b/lib/console.c > @@ -0,0 +1,130 @@ > +// SPDX-License-Identifier: GPL-2.0+ > + > +/* > + * File containing all of the console-related code that is used by all > + * possible consumers: PBL, CONSOLE_FULL, CONSOLE_SIMPLE, etc. > + * > + * Copyright (C) 2018 Zodiac Inflight Innovations > + * Author: Andrey Smirnov <andrew.smirnov@xxxxxxxxx> > + */ > + > +#include <debug_ll.h> > +#include <console.h> > + > +/* > + * Put this in the data section so that it survives the clearing of > + * the BSS segment. > + */ > +#define __data __attribute__ ((section(".data"))) This definition would be better placed in compiler.h together with all the __naked etc. definitions. And then it could be used in other places, like for example first patch in this serie. Sam _______________________________________________ barebox mailing list barebox@xxxxxxxxxxxxxxxxxxx http://lists.infradead.org/mailman/listinfo/barebox