From mboxrd@z Thu Jan 1 00:00:00 1970 From: Masahiro Yamada Date: Thu, 11 May 2017 11:12:46 +0900 Subject: [U-Boot] [PATCH v2 1/9] dm: Use dm.h header when driver mode is used In-Reply-To: <20170510214300.GR12511@bill-the-cat> References: <20170501151852.26670-1-sjg@chromium.org> <20170501151852.26670-2-sjg@chromium.org> <20170510214300.GR12511@bill-the-cat> Message-ID: List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Hi Simon, 2017-05-11 6:43 GMT+09:00 Tom Rini : > On Mon, May 01, 2017 at 09:18:44AM -0600, Simon Glass wrote: > >> This header includes things that are needed to make driver build. Adjust >> existing users to include that always, even if other dm/ includes are >> present >> >> Signed-off-by: Simon Glass > > Reviewed-by: Tom Rini > I'd say this is a bad idea. I believe .c files should include headers that are really necessary. Mostly, drivers need only dm/device.h, but this commit requires additional parse of dm/uclass.h and dm/platdata.h. Rather, it is better to deprecate dm.h. Its concept is DM common header that you force drivers to include where some in them may not be necessary. It is a similar idea to include/common.h, which is one of the biggest design mistakes in U-Boot. -- Best Regards Masahiro Yamada