Skip to contentSkip to conversation

dma: imx-dma: Fix build by including <linux/module.h>

PATCH In review Fabio Estevam 2 participants 2 messages Mar 8, 2012 – Mar 13, 2012

Subsystems (2)
lore
Share & tools
lore

Fabio Estevam

author reviewer
#0 lore raw

PATCH 1/1 dma: imx-dma: Fix build by including <linux/module.h>

commit 13ae246 (includecheck: delete any duplicate instances of module.) removed a duplicated module.h inclusion from imx-dma.c.

,and commit 865d9438 (drivers/dma: linux/module.h included twice) did the same.

Let one linux/module.h be included so that it can be built again.

This fix the following error:

C drivers/dma/imx-dma.o
drivers/dma/imx-dma.c:658: error: expected declaration specifiers or '...' before string constant drivers/dma/imx-dma.c:658: warning: data definition has no type or storage class drivers/dma/imx-dma.c:658: warning: type defaults to 'int' in declaration of 'MODULE_AUTHOR' drivers/dma/imx-dma.c:658: warning: function declaration isn't a prototype drivers/dma/imx-dma.c:659: error: expected declaration specifiers or '...' before string constant drivers/dma/imx-dma.c:659: warning: data definition has no type or storage class drivers/dma/imx-dma.c:659: warning: type defaults to 'int' in declaration of 'MODULE_DESCRIPTION' drivers/dma/imx-dma.c:659: warning: function declaration isn't a prototype drivers/dma/imx-dma.c:660: error: expected declaration specifiers or '...' before string constant drivers/dma/imx-dma.c:660: warning: data definition has no type or storage class drivers/dma/imx-dma.c:660: warning: type defaults to 'int' in declaration of 'MODULE_LICENSE' drivers/dma/imx-dma.c:660: warning: function declaration isn't a prototype

---
 drivers/dma/imx-dma.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
drivers/dma/imx-dma.c +1 -0
index ca78fca..7be8d1f 100644
@@ -25,6 +25,7 @@
 #include <linux/slab.h>
 #include <linux/platform_device.h>
 #include <linux/dmaengine.h>
+#include <linux/module.h>
 
 #include <asm/irq.h>
 #include <mach/dma-v1.h>
Signature · 1 line
1.7.1
#1 lore raw
Quoted 9 lines · Fabio Estevam

commit 13ae246 (includecheck: delete any duplicate instances of module.) removed a duplicated module.h inclusion from imx-dma.c.

,and commit 865d9438 (drivers/dma: linux/module.h included twice) did the same.

Let one linux/module.h be included so that it can be built again.

This fix the following error:

Quoted 13 lines

C drivers/dma/imx-dma.o
drivers/dma/imx-dma.c:658: error: expected declaration specifiers or '...' before string constant drivers/dma/imx-dma.c:658: warning: data definition has no type or storage class drivers/dma/imx-dma.c:658: warning: type defaults to 'int' in declaration of 'MODULE_AUTHOR' drivers/dma/imx-dma.c:658: warning: function declaration isn't a prototype drivers/dma/imx-dma.c:659: error: expected declaration specifiers or '...' before string constant drivers/dma/imx-dma.c:659: warning: data definition has no type or storage class drivers/dma/imx-dma.c:659: warning: type defaults to 'int' in declaration of 'MODULE_DESCRIPTION' drivers/dma/imx-dma.c:659: warning: function declaration isn't a prototype drivers/dma/imx-dma.c:660: error: expected declaration specifiers or '...' before string constant drivers/dma/imx-dma.c:660: warning: data definition has no type or storage class drivers/dma/imx-dma.c:660: warning: type defaults to 'int' in declaration of 'MODULE_LICENSE' drivers/dma/imx-dma.c:660: warning: function declaration isn't a prototype

I reverted the commit 865d9438 (drivers/dma: linux/module.h included twice) afetr it was reported on linux-next. You should not see any errors now.

Quoted 18 lines
---
 drivers/dma/imx-dma.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
drivers/dma/imx-dma.c +1 -0
index ca78fca..7be8d1f 100644
@@ -25,6 +25,7 @@
 #include <linux/slab.h>
 #include <linux/platform_device.h>
 #include <linux/dmaengine.h>
+#include <linux/module.h>
 
 #include <asm/irq.h>
 #include <mach/dma-v1.h>
Signature · 1 line
~Vinod