linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: shawn.guo@freescale.com (Shawn Guo)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH] drm/cma: include <drm/drmP.h> as needed
Date: Mon, 24 Mar 2014 20:14:48 +0800	[thread overview]
Message-ID: <1395663288-30940-1-git-send-email-shawn.guo@freescale.com> (raw)

The following error and warnings will be seen when compiling a C file
which includes <drm/drm_gem_cma_helper.h> but without <drm/drmP.h>
being included before.

include/drm/drm_gem_cma_helper.h:5:24: error: field ?base? has incomplete type
include/drm/drm_gem_cma_helper.h: In function ?to_drm_gem_cma_obj?:
include/drm/drm_gem_cma_helper.h:16:9: warning: initialization from incompatible pointer type [enabled by default]
include/drm/drm_gem_cma_helper.h: At top level:
include/drm/drm_gem_cma_helper.h:24:34: warning: ?struct drm_mode_create_dumb? declared inside parameter list [enabled by default]
include/drm/drm_gem_cma_helper.h:24:34: warning: its scope is only this definition or declaration, which is probably not what you want [enabled by default]
include/drm/drm_gem_cma_helper.h:24:34: warning: ?struct drm_device? declared inside parameter list [enabled by default]
include/drm/drm_gem_cma_helper.h:24:34: warning: ?struct drm_file? declared inside parameter list [enabled by default]
include/drm/drm_gem_cma_helper.h:28:10: warning: ?struct drm_device? declared inside parameter list [enabled by default]
include/drm/drm_gem_cma_helper.h:28:10: warning: ?struct drm_file? declared inside parameter list [enabled by default]
include/drm/drm_gem_cma_helper.h:35:3: warning: ?struct drm_device? declared inside parameter list [enabled by default]
include/drm/drm_gem_cma_helper.h:46:14: warning: ?struct drm_device? declared inside parameter list [enabled by default]

Fix them by including <drm/drmP.h> in drm_gem_cma_helper.h.

Signed-off-by: Shawn Guo <shawn.guo@freescale.com>
---
 include/drm/drm_gem_cma_helper.h | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/include/drm/drm_gem_cma_helper.h b/include/drm/drm_gem_cma_helper.h
index 89b4d7d..2a3cea9 100644
--- a/include/drm/drm_gem_cma_helper.h
+++ b/include/drm/drm_gem_cma_helper.h
@@ -1,6 +1,8 @@
 #ifndef __DRM_GEM_CMA_HELPER_H__
 #define __DRM_GEM_CMA_HELPER_H__
 
+#include <drm/drmP.h>
+
 struct drm_gem_cma_object {
 	struct drm_gem_object base;
 	dma_addr_t paddr;
-- 
1.8.3.2

                 reply	other threads:[~2014-03-24 12:14 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1395663288-30940-1-git-send-email-shawn.guo@freescale.com \
    --to=shawn.guo@freescale.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).