1. 12 7月, 2012 1 次提交
    • G
      mn10300: move setup_jiffies_interrupt() to cevt-mn10300.c · 325c1170
      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
        ...
        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: NGeert Uytterhoeven <geert@linux-m68k.org>
      Cc: David Howells <dhowells@redhat.com>
      Cc: Koichi Yasutake <yasutake.koichi@jp.panasonic.com>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      325c1170
  2. 28 10月, 2010 3 次提交
  3. 12 1月, 2010 1 次提交
  4. 02 10月, 2009 1 次提交
    • M
      mn10300: fix kernel build failures when using gcc-4.x · d22a001b
      Mark Salter 提交于
      Fix some build failures when using gcc-4.x for MN10300.
      
      Firstly, __get_user() fails to build because the pointer points to a const and
      __gu_val ends up being read-only:
      
      In file included from include/linux/mempolicy.h:62,
                       from init/main.c:50:
      include/linux/pagemap.h: In function 'fault_in_pages_readable':
      include/linux/pagemap.h:394: error: read-only variable '__gu_val' used as 'asm' output
      include/linux/pagemap.h:394: error: read-only variable '__gu_val' used as 'asm' output
      include/linux/pagemap.h:394: error: read-only variable '__gu_val' used as 'asm' output
      include/linux/pagemap.h:400: error: read-only variable '__gu_val' used as 'asm' output
      include/linux/pagemap.h:400: error: read-only variable '__gu_val' used as 'asm' output
      include/linux/pagemap.h:400: error: read-only variable '__gu_val' used as 'asm' output
      make[1]: *** [init/main.o] Error 1
      
      Secondly, gcc-4 doesn't allow casts of lvalues:
      
        UPD     include/linux/compile.h
      arch/mn10300/kernel/rtc.c: In function 'calibrate_clock':
      arch/mn10300/kernel/rtc.c:170: error: lvalue required as left operand of assignment
      arch/mn10300/kernel/rtc.c:172: error: lvalue required as left operand of assignment
      make[1]: *** [arch/mn10300/kernel/rtc.o] Error 1
      
      These are seen with gcc 4.2.1.
      Signed-off-by: NMark Salter <msalter@redhat.com>
      Signed-off-by: NDavid Howells <dhowells@redhat.com>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      d22a001b
  5. 10 4月, 2009 1 次提交