* [PATCH 1/6] mn10300: Move setup_jiffies_interrupt() to cevt-mn10300.c
@ 2012-06-20 20:09 Geert Uytterhoeven
2012-06-20 20:09 ` [PATCH 2/6] mn10300: Remove duplicate definition of PTRACE_O_TRACESYSGOOD Geert Uytterhoeven
` (4 more replies)
0 siblings, 5 replies; 6+ messages in thread
From: Geert Uytterhoeven @ 2012-06-20 20:09 UTC (permalink / raw)
To: David Howells, Koichi Yasutake
Cc: Andrew Morton, linux-am33-list, linux-kernel, Geert Uytterhoeven
Move the static inline function setup_jiffies_interrupt() from
<asm/timex.h> to arch/mn10300/kernel/cevt-mn10300.c, which is its only
callsite.
This allows to remove the inclusion of <asm/hardirq.h> and <linux/irq.h>
from <asm/timex.h> and <unit/timex.h>, fixing include hell like:
include/linux/jiffies.h:260:31: warning: "CLOCK_TICK_RATE" is not defined [-Wundef]
include/linux/jiffies.h:260:31: warning: "CLOCK_TICK_RATE" is not defined [-Wundef]
include/linux/jiffies.h:46:42: error: division by zero in #if
include/linux/jiffies.h:260:31: warning: "CLOCK_TICK_RATE" is not defined [-Wundef]
include/linux/jiffies.h:260:31: warning: "CLOCK_TICK_RATE" is not defined [-Wundef]
include/linux/jiffies.h:46:42: error: division by zero in #if
include/linux/jiffies.h:260:31: warning: "CLOCK_TICK_RATE" is not defined [-Wundef]
include/linux/jiffies.h:260:31: warning: "CLOCK_TICK_RATE" is not defined [-Wundef]
include/linux/jiffies.h:46:42: error: division by zero in #if
include/linux/jiffies.h:46:42: error: division by zero in #if
include/linux/jiffies.h:260:31: warning: "CLOCK_TICK_RATE" is not defined [-Wundef]
include/linux/jiffies.h:260:31: warning: "CLOCK_TICK_RATE" is not defined [-Wundef]
include/linux/jiffies.h:46:42: error: division by zero in #if
include/linux/jiffies.h:260:31: warning: "CLOCK_TICK_RATE" is not defined [-Wundef]
include/linux/jiffies.h:260:31: warning: "CLOCK_TICK_RATE" is not defined [-Wundef]
include/linux/jiffies.h:46:42: error: division by zero in #if
include/linux/jiffies.h:260:31: warning: "CLOCK_TICK_RATE" is not defined [-Wundef]
include/linux/jiffies.h:260:31: warning: "CLOCK_TICK_RATE" is not defined [-Wundef]
include/linux/jiffies.h:46:42: error: division by zero in #if
include/linux/jiffies.h:46:42: error: division by zero in #if
include/linux/jiffies.h:260:31: warning: "CLOCK_TICK_RATE" is not defined [-Wundef]
include/linux/jiffies.h:260:31: warning: "CLOCK_TICK_RATE" is not defined [-Wundef]
include/linux/jiffies.h:46:42: error: division by zero in #if
include/linux/jiffies.h:260:31: warning: "CLOCK_TICK_RATE" is not defined [-Wundef]
include/linux/jiffies.h:260:31: warning: "CLOCK_TICK_RATE" is not defined [-Wundef]
include/linux/jiffies.h:46:42: error: division by zero in #if
include/linux/jiffies.h:260:31: warning: "CLOCK_TICK_RATE" is not defined [-Wundef]
include/linux/jiffies.h:260:31: warning: "CLOCK_TICK_RATE" is not defined [-Wundef]
include/linux/jiffies.h:46:42: error: division by zero in #if
include/linux/jiffies.h:260:31: warning: "CLOCK_TICK_RATE" is not defined [-Wundef]
include/linux/jiffies.h:260:31: warning: "CLOCK_TICK_RATE" is not defined [-Wundef]
include/linux/jiffies.h:46:42: error: division by zero in #if
include/linux/jiffies.h:260:31: warning: "CLOCK_TICK_RATE" is not defined [-Wundef]
include/linux/jiffies.h:260:31: warning: "CLOCK_TICK_RATE" is not defined [-Wundef]
include/linux/jiffies.h:46:42: error: division by zero in #if
include/linux/jiffies.h:260:31: warning: "CLOCK_TICK_RATE" is not defined [-Wundef]
include/linux/jiffies.h:260:31: warning: "CLOCK_TICK_RATE" is not defined [-Wundef]
include/linux/jiffies.h:46:42: error: division by zero in #if
include/linux/jiffies.h:46:42: error: division by zero in #if
make[4]: *** [arch/mn10300/kernel/asm-offsets.s] Error 1
and (after a quick hack for the above by defining CLOCK_TICK_RATE in
<linux/jiffies.h>):
In file included from include/linux/notifier.h:15:0,
from include/linux/memory_hotplug.h:6,
from include/linux/mmzone.h:718,
from include/linux/gfp.h:4,
from include/linux/irq.h:20,
from arch/mn10300/unit-asb2303/include/unit/timex.h:15,
from arch/mn10300/include/asm/timex.h:15,
from include/linux/timex.h:174,
from include/linux/jiffies.h:8,
from include/linux/ktime.h:25,
from include/linux/timer.h:5,
from include/linux/workqueue.h:8,
include/linux/srcu.h:55:22: error: field 'work' has incomplete type
As a consequence, we do need a few more inclusions of <asm/irq.h>, namely
in arch/mn10300/unit-asb2303/smc91111.c and
arch/mn10300/unit-asb2305/unit-init.c.
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
---
arch/mn10300/include/asm/timex.h | 11 -----------
arch/mn10300/kernel/cevt-mn10300.c | 10 ++++++++++
arch/mn10300/unit-asb2303/include/unit/timex.h | 4 ----
arch/mn10300/unit-asb2303/smc91111.c | 1 +
arch/mn10300/unit-asb2305/include/unit/timex.h | 4 ----
arch/mn10300/unit-asb2305/unit-init.c | 1 +
arch/mn10300/unit-asb2364/include/unit/timex.h | 4 ----
7 files changed, 12 insertions(+), 23 deletions(-)
diff --git a/arch/mn10300/include/asm/timex.h b/arch/mn10300/include/asm/timex.h
index bd4e90d..f8e6642 100644
--- a/arch/mn10300/include/asm/timex.h
+++ b/arch/mn10300/include/asm/timex.h
@@ -11,7 +11,6 @@
#ifndef _ASM_TIMEX_H
#define _ASM_TIMEX_H
-#include <asm/hardirq.h>
#include <unit/timex.h>
#define TICK_SIZE (tick_nsec / 1000)
@@ -30,16 +29,6 @@ static inline cycles_t get_cycles(void)
extern int init_clockevents(void);
extern int init_clocksource(void);
-static inline void setup_jiffies_interrupt(int irq,
- struct irqaction *action)
-{
- u16 tmp;
- setup_irq(irq, action);
- set_intr_level(irq, NUM2GxICR_LEVEL(CONFIG_TIMER_IRQ_LEVEL));
- GxICR(irq) |= GxICR_ENABLE | GxICR_DETECT | GxICR_REQUEST;
- tmp = GxICR(irq);
-}
-
#endif /* __KERNEL__ */
#endif /* _ASM_TIMEX_H */
diff --git a/arch/mn10300/kernel/cevt-mn10300.c b/arch/mn10300/kernel/cevt-mn10300.c
index 69cae02..ccce35e 100644
--- a/arch/mn10300/kernel/cevt-mn10300.c
+++ b/arch/mn10300/kernel/cevt-mn10300.c
@@ -70,6 +70,16 @@ static void event_handler(struct clock_event_device *dev)
{
}
+static inline void setup_jiffies_interrupt(int irq,
+ struct irqaction *action)
+{
+ u16 tmp;
+ setup_irq(irq, action);
+ set_intr_level(irq, NUM2GxICR_LEVEL(CONFIG_TIMER_IRQ_LEVEL));
+ GxICR(irq) |= GxICR_ENABLE | GxICR_DETECT | GxICR_REQUEST;
+ tmp = GxICR(irq);
+}
+
int __init init_clockevents(void)
{
struct clock_event_device *cd;
diff --git a/arch/mn10300/unit-asb2303/include/unit/timex.h b/arch/mn10300/unit-asb2303/include/unit/timex.h
index cc18fe7..c37f983 100644
--- a/arch/mn10300/unit-asb2303/include/unit/timex.h
+++ b/arch/mn10300/unit-asb2303/include/unit/timex.h
@@ -11,10 +11,6 @@
#ifndef _ASM_UNIT_TIMEX_H
#define _ASM_UNIT_TIMEX_H
-#ifndef __ASSEMBLY__
-#include <linux/irq.h>
-#endif /* __ASSEMBLY__ */
-
#include <asm/timer-regs.h>
#include <unit/clock.h>
#include <asm/param.h>
diff --git a/arch/mn10300/unit-asb2303/smc91111.c b/arch/mn10300/unit-asb2303/smc91111.c
index 43c2464..5367769 100644
--- a/arch/mn10300/unit-asb2303/smc91111.c
+++ b/arch/mn10300/unit-asb2303/smc91111.c
@@ -15,6 +15,7 @@
#include <linux/platform_device.h>
#include <asm/io.h>
+#include <asm/irq.h>
#include <asm/timex.h>
#include <asm/processor.h>
#include <asm/intctl-regs.h>
diff --git a/arch/mn10300/unit-asb2305/include/unit/timex.h b/arch/mn10300/unit-asb2305/include/unit/timex.h
index 758af30..4cefc22 100644
--- a/arch/mn10300/unit-asb2305/include/unit/timex.h
+++ b/arch/mn10300/unit-asb2305/include/unit/timex.h
@@ -11,10 +11,6 @@
#ifndef _ASM_UNIT_TIMEX_H
#define _ASM_UNIT_TIMEX_H
-#ifndef __ASSEMBLY__
-#include <linux/irq.h>
-#endif /* __ASSEMBLY__ */
-
#include <asm/timer-regs.h>
#include <unit/clock.h>
#include <asm/param.h>
diff --git a/arch/mn10300/unit-asb2305/unit-init.c b/arch/mn10300/unit-asb2305/unit-init.c
index e1becd6..bc4adfa 100644
--- a/arch/mn10300/unit-asb2305/unit-init.c
+++ b/arch/mn10300/unit-asb2305/unit-init.c
@@ -13,6 +13,7 @@
#include <linux/init.h>
#include <linux/pci.h>
#include <asm/io.h>
+#include <asm/irq.h>
#include <asm/setup.h>
#include <asm/processor.h>
#include <asm/intctl-regs.h>
diff --git a/arch/mn10300/unit-asb2364/include/unit/timex.h b/arch/mn10300/unit-asb2364/include/unit/timex.h
index ddb7ed0..42f32db 100644
--- a/arch/mn10300/unit-asb2364/include/unit/timex.h
+++ b/arch/mn10300/unit-asb2364/include/unit/timex.h
@@ -11,10 +11,6 @@
#ifndef _ASM_UNIT_TIMEX_H
#define _ASM_UNIT_TIMEX_H
-#ifndef __ASSEMBLY__
-#include <linux/irq.h>
-#endif /* __ASSEMBLY__ */
-
#include <asm/timer-regs.h>
#include <unit/clock.h>
#include <asm/param.h>
--
1.7.0.4
^ permalink raw reply [flat|nested] 6+ messages in thread* [PATCH 2/6] mn10300: Remove duplicate definition of PTRACE_O_TRACESYSGOOD
2012-06-20 20:09 [PATCH 1/6] mn10300: Move setup_jiffies_interrupt() to cevt-mn10300.c Geert Uytterhoeven
@ 2012-06-20 20:09 ` Geert Uytterhoeven
2012-06-20 20:09 ` [PATCH 3/6] mn10300: kernel/internal.h needs <linux/irqreturn.h> Geert Uytterhoeven
` (3 subsequent siblings)
4 siblings, 0 replies; 6+ messages in thread
From: Geert Uytterhoeven @ 2012-06-20 20:09 UTC (permalink / raw)
To: David Howells, Koichi Yasutake
Cc: Andrew Morton, linux-am33-list, linux-kernel, Geert Uytterhoeven
include/linux/ptrace.h:66:0: warning: "PTRACE_O_TRACESYSGOOD" redefined [enabled by default]
arch/mn10300/include/asm/ptrace.h:85:0: note: this is the location of the previous definition
We already have it in <linux/ptrace.h>, so remove it from <asm/ptrace.h>
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
---
arch/mn10300/include/asm/ptrace.h | 3 ---
1 files changed, 0 insertions(+), 3 deletions(-)
diff --git a/arch/mn10300/include/asm/ptrace.h b/arch/mn10300/include/asm/ptrace.h
index 55b79ef..44251b9 100644
--- a/arch/mn10300/include/asm/ptrace.h
+++ b/arch/mn10300/include/asm/ptrace.h
@@ -81,9 +81,6 @@ struct pt_regs {
#define PTRACE_GETFPREGS 14
#define PTRACE_SETFPREGS 15
-/* options set using PTRACE_SETOPTIONS */
-#define PTRACE_O_TRACESYSGOOD 0x00000001
-
#ifdef __KERNEL__
#define user_mode(regs) (((regs)->epsw & EPSW_nSL) == EPSW_nSL)
--
1.7.0.4
^ permalink raw reply [flat|nested] 6+ messages in thread* [PATCH 3/6] mn10300: kernel/internal.h needs <linux/irqreturn.h>
2012-06-20 20:09 [PATCH 1/6] mn10300: Move setup_jiffies_interrupt() to cevt-mn10300.c Geert Uytterhoeven
2012-06-20 20:09 ` [PATCH 2/6] mn10300: Remove duplicate definition of PTRACE_O_TRACESYSGOOD Geert Uytterhoeven
@ 2012-06-20 20:09 ` Geert Uytterhoeven
2012-06-20 20:09 ` [PATCH 4/6] mn10300: kernel/traps.c needs <linux/export.h> Geert Uytterhoeven
` (2 subsequent siblings)
4 siblings, 0 replies; 6+ messages in thread
From: Geert Uytterhoeven @ 2012-06-20 20:09 UTC (permalink / raw)
To: David Howells, Koichi Yasutake
Cc: Andrew Morton, linux-am33-list, linux-kernel, Geert Uytterhoeven
In file included from arch/mn10300/kernel/csrc-mn10300.c:14:0:
arch/mn10300/kernel/internal.h:42:1: error: unknown type name 'irqreturn_t'
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
---
arch/mn10300/kernel/internal.h | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/arch/mn10300/kernel/internal.h b/arch/mn10300/kernel/internal.h
index a5ac755..2df4401 100644
--- a/arch/mn10300/kernel/internal.h
+++ b/arch/mn10300/kernel/internal.h
@@ -9,6 +9,8 @@
* 2 of the Licence, or (at your option) any later version.
*/
+#include <linux/irqreturn.h>
+
struct clocksource;
struct clock_event_device;
--
1.7.0.4
^ permalink raw reply [flat|nested] 6+ messages in thread* [PATCH 4/6] mn10300: kernel/traps.c needs <linux/export.h>
2012-06-20 20:09 [PATCH 1/6] mn10300: Move setup_jiffies_interrupt() to cevt-mn10300.c Geert Uytterhoeven
2012-06-20 20:09 ` [PATCH 2/6] mn10300: Remove duplicate definition of PTRACE_O_TRACESYSGOOD Geert Uytterhoeven
2012-06-20 20:09 ` [PATCH 3/6] mn10300: kernel/internal.h needs <linux/irqreturn.h> Geert Uytterhoeven
@ 2012-06-20 20:09 ` Geert Uytterhoeven
2012-06-20 20:09 ` [PATCH 5/6] mn10300: mm/dma-alloc.c " Geert Uytterhoeven
2012-06-20 20:09 ` [PATCH 6/6] mn10300: Use "#elif defined(CONFIG_*)" instead of "#elif CONFIG_*" Geert Uytterhoeven
4 siblings, 0 replies; 6+ messages in thread
From: Geert Uytterhoeven @ 2012-06-20 20:09 UTC (permalink / raw)
To: David Howells, Koichi Yasutake
Cc: Andrew Morton, linux-am33-list, linux-kernel, Geert Uytterhoeven
arch/mn10300/kernel/traps.c:304:1: warning: data definition has no type or storage class [enabled by default]
arch/mn10300/kernel/traps.c:304:1: warning: type defaults to 'int' in declaration of 'EXPORT_SYMBOL' [-Wimplicit-int]
arch/mn10300/kernel/traps.c:304:1: warning: parameter names (without types) in function declaration [enabled by default]
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
---
arch/mn10300/kernel/traps.c | 1 +
1 files changed, 1 insertions(+), 0 deletions(-)
diff --git a/arch/mn10300/kernel/traps.c b/arch/mn10300/kernel/traps.c
index 94a9c6d..b900e5a 100644
--- a/arch/mn10300/kernel/traps.c
+++ b/arch/mn10300/kernel/traps.c
@@ -26,6 +26,7 @@
#include <linux/kdebug.h>
#include <linux/bug.h>
#include <linux/irq.h>
+#include <linux/export.h>
#include <asm/processor.h>
#include <linux/uaccess.h>
#include <asm/io.h>
--
1.7.0.4
^ permalink raw reply [flat|nested] 6+ messages in thread
* [PATCH 5/6] mn10300: mm/dma-alloc.c needs <linux/export.h>
2012-06-20 20:09 [PATCH 1/6] mn10300: Move setup_jiffies_interrupt() to cevt-mn10300.c Geert Uytterhoeven
` (2 preceding siblings ...)
2012-06-20 20:09 ` [PATCH 4/6] mn10300: kernel/traps.c needs <linux/export.h> Geert Uytterhoeven
@ 2012-06-20 20:09 ` Geert Uytterhoeven
2012-06-20 20:09 ` [PATCH 6/6] mn10300: Use "#elif defined(CONFIG_*)" instead of "#elif CONFIG_*" Geert Uytterhoeven
4 siblings, 0 replies; 6+ messages in thread
From: Geert Uytterhoeven @ 2012-06-20 20:09 UTC (permalink / raw)
To: David Howells, Koichi Yasutake
Cc: Andrew Morton, linux-am33-list, linux-kernel, Geert Uytterhoeven
arch/mn10300/mm/dma-alloc.c: At top level:
arch/mn10300/mm/dma-alloc.c:63:1: warning: data definition has no type or storage class [enabled by default]
arch/mn10300/mm/dma-alloc.c:63:1: warning: type defaults to 'int' in declaration of 'EXPORT_SYMBOL' [-Wimplicit-int]
arch/mn10300/mm/dma-alloc.c:63:1: warning: parameter names (without types) in function declaration [enabled by default]
arch/mn10300/mm/dma-alloc.c:75:1: warning: data definition has no type or storage class [enabled by default]
arch/mn10300/mm/dma-alloc.c:75:1: warning: type defaults to 'int' in declaration of 'EXPORT_SYMBOL' [-Wimplicit-int]
arch/mn10300/mm/dma-alloc.c:75:1: warning: parameter names (without types) in function declaration [enabled by default]
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
---
arch/mn10300/mm/dma-alloc.c | 1 +
1 files changed, 1 insertions(+), 0 deletions(-)
diff --git a/arch/mn10300/mm/dma-alloc.c b/arch/mn10300/mm/dma-alloc.c
index 159acb0..e244ebe 100644
--- a/arch/mn10300/mm/dma-alloc.c
+++ b/arch/mn10300/mm/dma-alloc.c
@@ -15,6 +15,7 @@
#include <linux/string.h>
#include <linux/pci.h>
#include <linux/gfp.h>
+#include <linux/export.h>
#include <asm/io.h>
static unsigned long pci_sram_allocated = 0xbc000000;
--
1.7.0.4
^ permalink raw reply [flat|nested] 6+ messages in thread* [PATCH 6/6] mn10300: Use "#elif defined(CONFIG_*)" instead of "#elif CONFIG_*"
2012-06-20 20:09 [PATCH 1/6] mn10300: Move setup_jiffies_interrupt() to cevt-mn10300.c Geert Uytterhoeven
` (3 preceding siblings ...)
2012-06-20 20:09 ` [PATCH 5/6] mn10300: mm/dma-alloc.c " Geert Uytterhoeven
@ 2012-06-20 20:09 ` Geert Uytterhoeven
4 siblings, 0 replies; 6+ messages in thread
From: Geert Uytterhoeven @ 2012-06-20 20:09 UTC (permalink / raw)
To: David Howells, Koichi Yasutake
Cc: Andrew Morton, linux-am33-list, linux-kernel, Geert Uytterhoeven
arch/mn10300/kernel/irq.c:173:7: warning: "CONFIG_MN10300_TTYSM1_TIMER9" is not defined [-Wundef]
arch/mn10300/kernel/irq.c:175:7: warning: "CONFIG_MN10300_TTYSM1_TIMER3" is not defined [-Wundef]
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
---
arch/mn10300/kernel/irq.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/arch/mn10300/kernel/irq.c b/arch/mn10300/kernel/irq.c
index 2381df8..35932a8 100644
--- a/arch/mn10300/kernel/irq.c
+++ b/arch/mn10300/kernel/irq.c
@@ -170,9 +170,9 @@ mn10300_cpupic_setaffinity(struct irq_data *d, const struct cpumask *mask,
case SC1TXIRQ:
#ifdef CONFIG_MN10300_TTYSM1_TIMER12
case TM12IRQ:
-#elif CONFIG_MN10300_TTYSM1_TIMER9
+#elif defined(CONFIG_MN10300_TTYSM1_TIMER9)
case TM9IRQ:
-#elif CONFIG_MN10300_TTYSM1_TIMER3
+#elif defined(CONFIG_MN10300_TTYSM1_TIMER3)
case TM3IRQ:
#endif /* CONFIG_MN10300_TTYSM1_TIMER12 */
#endif /* CONFIG_MN10300_TTYSM1 */
--
1.7.0.4
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2012-06-20 20:11 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-06-20 20:09 [PATCH 1/6] mn10300: Move setup_jiffies_interrupt() to cevt-mn10300.c Geert Uytterhoeven
2012-06-20 20:09 ` [PATCH 2/6] mn10300: Remove duplicate definition of PTRACE_O_TRACESYSGOOD Geert Uytterhoeven
2012-06-20 20:09 ` [PATCH 3/6] mn10300: kernel/internal.h needs <linux/irqreturn.h> Geert Uytterhoeven
2012-06-20 20:09 ` [PATCH 4/6] mn10300: kernel/traps.c needs <linux/export.h> Geert Uytterhoeven
2012-06-20 20:09 ` [PATCH 5/6] mn10300: mm/dma-alloc.c " Geert Uytterhoeven
2012-06-20 20:09 ` [PATCH 6/6] mn10300: Use "#elif defined(CONFIG_*)" instead of "#elif CONFIG_*" Geert Uytterhoeven
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®