Hi Masahiro, On 10 May 2017 at 20:21, Masahiro Yamada <yamada.masah...@socionext.com> wrote: > Hi Simon > > 2017-05-11 6:43 GMT+09:00 Tom Rini <tr...@konsulko.com>: >> On Mon, May 01, 2017 at 09:18:48AM -0600, Simon Glass wrote: >> >>> It is good practice to include common.h as the first header. This ensures >>> that required features like the DECLARE_GLOBAL_DATA_PTR macro, >>> configuration options and common types are available. >>> >>> Fix up some files which currently don't do this. This is necessary because >>> driver model will soon start using global data and configuration in the >>> dm/ofnode.h header file, included via dm.h. >>> >>> Signed-off-by: Simon Glass <s...@chromium.org> >> >> Reviewed-by: Tom Rini <tr...@konsulko.com> > > > NACK. > > include/common.h is really bad idea > and this is a step backward. > > If you need something in your include/dm/ofnode.h > you should include needed header(s) from it. > > Why do you need to touch lots of C files?
All of these files fail to build when they cannot see global_data. Also we need access to CONFIG options in dm.h. So I think we have to have common.h - it is (I think) a rule that all files should have common.h and have it first, because any other header. Regards, Simon _______________________________________________ U-Boot mailing list U-Boot@lists.denx.de https://lists.denx.de/listinfo/u-boot