On Thu, Jul 18, 2019 at 06:14:57PM +0200, Sam Ravnborg wrote: > From: Jani Nikula <jani.nik...@intel.com> > > Fix build warning if drm_panel.h is built with CONFIG_OF=n or > CONFIG_DRM_PANEL=n and included without the prerequisite err.h: > > ./include/drm/drm_panel.h: In function ‘of_drm_find_panel’: > ./include/drm/drm_panel.h:203:9: error: implicit declaration of function > ‘ERR_PTR’ [-Werror=implicit-function-declaration] > return ERR_PTR(-ENODEV); > ^~~~~~~ > ./include/drm/drm_panel.h:203:9: error: returning ‘int’ from a function with > return type ‘struct drm_panel *’ makes pointer from integer without a cast > [-Werror=int-conversion] > return ERR_PTR(-ENODEV); > ^~~~~~~~~~~~~~~~ > > Fixes: 5fa8e4a22182 ("drm/panel: Make of_drm_find_panel() return an ERR_PTR() > instead of NULL") > Cc: Boris Brezillon <boris.brezil...@bootlin.com> > Signed-off-by: Jani Nikula <jani.nik...@intel.com> > Acked-by: Thierry Reding <tred...@nvidia.com> > Reviewed-by: Sam Ravnborg <s...@ravnborg.org>
Reviewed-by: Sean Paul <s...@poorly.run> > --- > include/drm/drm_panel.h | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/include/drm/drm_panel.h b/include/drm/drm_panel.h > index 8c738c0e6e9f..26377836141c 100644 > --- a/include/drm/drm_panel.h > +++ b/include/drm/drm_panel.h > @@ -24,6 +24,7 @@ > #ifndef __DRM_PANEL_H__ > #define __DRM_PANEL_H__ > > +#include <linux/err.h> > #include <linux/errno.h> > #include <linux/list.h> > > -- > 2.20.1 > -- Sean Paul, Software Engineer, Google / Chromium OS _______________________________________________ Intel-gfx mailing list Intel-gfx@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/intel-gfx