summaryrefslogtreecommitdiffstats
path: root/arch/m68k
Commit message (Collapse)AuthorAgeFilesLines
* new helper: sigsuspend()Al Viro2012-05-211-12/+3
| | | | | | | | | guts of saved_sigmask-based sigsuspend/rt_sigsuspend. Takes kernel sigset_t *. Open-coded instances replaced with calling it. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* Merge branch 'smp-hotplug-for-linus' of ↵Linus Torvalds2012-05-212-36/+1
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull smp hotplug cleanups from Thomas Gleixner: "This series is merily a cleanup of code copied around in arch/* and not changing any of the real cpu hotplug horrors yet. I wish I'd had something more substantial for 3.5, but I underestimated the lurking horror..." Fix up trivial conflicts in arch/{arm,sparc,x86}/Kconfig and arch/sparc/include/asm/thread_info_32.h * 'smp-hotplug-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (79 commits) um: Remove leftover declaration of alloc_task_struct_node() task_allocator: Use config switches instead of magic defines sparc: Use common threadinfo allocator score: Use common threadinfo allocator sh-use-common-threadinfo-allocator mn10300: Use common threadinfo allocator powerpc: Use common threadinfo allocator mips: Use common threadinfo allocator hexagon: Use common threadinfo allocator m32r: Use common threadinfo allocator frv: Use common threadinfo allocator cris: Use common threadinfo allocator x86: Use common threadinfo allocator c6x: Use common threadinfo allocator fork: Provide kmemcache based thread_info allocator tile: Use common threadinfo allocator fork: Provide weak arch_release_[task_struct|thread_info] functions fork: Move thread info gfp flags to header fork: Remove the weak insanity sh: Remove cpu_idle_wait() ...
| * init_task: Replace CONFIG_HAVE_GENERIC_INIT_TASKThomas Gleixner2012-05-051-1/+0
| | | | | | | | | | | | | | | | | | Now that all archs except ia64 are converted, replace the config and let the ia64 select CONFIG_ARCH_INIT_TASK Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/20120503085035.867948914@linutronix.de
| * m68k: Use generic init_taskThomas Gleixner2012-05-053-36/+2
| | | | | | | | | | | | | | | | Same code. Use the generic version. Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Cc: Geert Uytterhoeven <geert@linux-m68k.org> Link: http://lkml.kernel.org/r/20120503085034.816195285@linutronix.de
* | Merge branch 'for-next' of ↵Linus Torvalds2012-05-2151-4555/+1807
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | git://git.kernel.org/pub/scm/linux/kernel/git/gerg/m68knommu Pull m68knommu tree from Greg Ungerer: "More merge and clean up of MMU and non-MMU common files, namely signal.c and dma.c. There is also a simplification of the ColdFire GPIO setup tables. Using a couple of simple macros we make the init tables really small and easy to read, and save a couple of thousand lines of code. Also a move of all the ColdFire subarch support files into the existing coldfire directory. The sub-directories just ended up duplicating Makefiles and now only contain really simple pieces of code. This saves quite a few lines of code too. As always a couple of bugs fixes thrown in too. Oh and a new defconfig for the ColdFire platforms that support having the MMU enabled." * 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/gerg/m68knommu: (39 commits) m68k: add a defconfig for the M5475EVB ColdFire with MMU board m68knommu: unaligned.h fix for M68000 core m68k: merge the MMU and non-MMU versions of the arch dma code m68knommu: reorganize the no-MMU cache flushing to match m68k m68knommu: move the 54xx platform code into the common ColdFire code directory m68knommu: move the 532x platform code into the common ColdFire code directory m68knommu: move the 5407 platform code into the common ColdFire code directory m68knommu: move the 5307 platform code into the common ColdFire code directory m68knommu: move the 528x platform code into the common ColdFire code directory m68knommu: move the 527x platform code into the common ColdFire code directory m68knommu: move the 5272 platform code into the common ColdFire code directory m68knommu: move the 5249 platform code into the common ColdFire code directory m68knommu: move the 523x platform code into the common ColdFire code directory m68knommu: move the 520x platform code into the common ColdFire code directory m68knommu: move the 5206 platform code into the common ColdFire code directory m68knommu: simplify the ColdFire 5407 GPIO struct setup m68knommu: simplify the ColdFire 532x GPIO struct setup m68knommu: simplify the ColdFire 5307 GPIO struct setup m68knommu: simplify the ColdFire 528x GPIO struct setup m68knommu: simplify the ColdFire 527x GPIO struct setup ...
| * | m68k: add a defconfig for the M5475EVB ColdFire with MMU boardGreg Ungerer2012-05-201-0/+62
| | | | | | | | | | | | | | | | | | | | | Add a default configuration for the newly supported ColdFire CPUs running with MMU enabled. This is based on Freescales own M5475EVB demo board. Signed-off-by: Greg Ungerer <gerg@uclinux.org>
| * | m68knommu: unaligned.h fix for M68000 coreLuis Alves2012-05-201-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch fixes unaligned memory access for the 68000 core based cpu's. Some time ago, my cpu (68000) was raising address/bus error's when mounting cifs shares (didn't bother to debug it at the time). After developing the MMC/SD card driver I was having the same issue when mounting the vfat fs. I've traced the issue down to the 'unaligned.h' file. (I guess nobody has ever used unaligned.h back in the 68328 'era'. Signed-off-by: Luis Alves <ljalvs@gmail.com> Signed-off-by: Greg Ungerer <gerg@uclinux.org>
| * | m68k: merge the MMU and non-MMU versions of the arch dma codeGreg Ungerer2012-05-203-209/+162
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The majority of the m68k architecture dma code is the same, so merge the current separated files dma_no.c and dma_mm.c back into a single dma.c The main alloc and free routines are a little different, so we keep a single #ifdef based on CONFIG_MMU for them. All the other support functions are now identical. Signed-off-by: Greg Ungerer <gerg@uclinux.org> Acked-by: Geert Uytterhoeven <geert@linux-m68k.org>
| * | m68knommu: reorganize the no-MMU cache flushing to match m68kGreg Ungerer2012-05-201-4/+28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Introduce cache_push() and cache_clear() functions for the non-MMU m68k devices. With these in place we can more easily merge some of the common m68k arch code. In particular by reorganizing the __flush_cache_all() code and separating the cache push and clear functions it becomes trivial to implement the new cache_push() and cache_clear() functions. Signed-off-by: Greg Ungerer <gerg@uclinux.org> Acked-by: Geert Uytterhoeven <geert@linux-m68k.org>
| * | m68knommu: move the 54xx platform code into the common ColdFire code directoryGreg Ungerer2012-05-205-21/+2
| | | | | | | | | | | | | | | | | | | | | | | | All these separate directories for each ColdFire CPU SoC varient seems like overkill. The majority of them only contain a single small config file. Move these into the common ColdFire code directory. Signed-off-by: Greg Ungerer <gerg@uclinux.org>
| * | m68knommu: move the 532x platform code into the common ColdFire code directoryGreg Ungerer2012-05-204-20/+1
| | | | | | | | | | | | | | | | | | | | | | | | All these separate directories for each ColdFire CPU SoC varient seems like overkill. The majority of them only contain a single small config file. Move these into the common ColdFire code directory. Signed-off-by: Greg Ungerer <gerg@uclinux.org>
| * | m68knommu: move the 5407 platform code into the common ColdFire code directoryGreg Ungerer2012-05-204-20/+1
| | | | | | | | | | | | | | | | | | | | | | | | All these separate directories for each ColdFire CPU SoC varient seems like overkill. The majority of them only contain a single small config file. Move these into the common ColdFire code directory. Signed-off-by: Greg Ungerer <gerg@uclinux.org>
| * | m68knommu: move the 5307 platform code into the common ColdFire code directoryGreg Ungerer2012-05-205-22/+4
| | | | | | | | | | | | | | | | | | | | | | | | All these separate directories for each ColdFire CPU SoC varient seems like overkill. The majority of them only contain a single small config file. Move these into the common ColdFire code directory. Signed-off-by: Greg Ungerer <gerg@uclinux.org>
| * | m68knommu: move the 528x platform code into the common ColdFire code directoryGreg Ungerer2012-05-204-20/+1
| | | | | | | | | | | | | | | | | | | | | | | | All these separate directories for each ColdFire CPU SoC varient seems like overkill. The majority of them only contain a single small config file. Move these into the common ColdFire code directory. Signed-off-by: Greg Ungerer <gerg@uclinux.org>
| * | m68knommu: move the 527x platform code into the common ColdFire code directoryGreg Ungerer2012-05-204-20/+1
| | | | | | | | | | | | | | | | | | | | | | | | All these separate directories for each ColdFire CPU SoC varient seems like overkill. The majority of them only contain a single small config file. Move these into the common ColdFire code directory. Signed-off-by: Greg Ungerer <gerg@uclinux.org>
| * | m68knommu: move the 5272 platform code into the common ColdFire code directoryGreg Ungerer2012-05-205-20/+1
| | | | | | | | | | | | | | | | | | | | | | | | All these separate directories for each ColdFire CPU SoC varient seems like overkill. The majority of them only contain a single small config file. Move these into the common ColdFire code directory. Signed-off-by: Greg Ungerer <gerg@uclinux.org>
| * | m68knommu: move the 5249 platform code into the common ColdFire code directoryGreg Ungerer2012-05-205-20/+1
| | | | | | | | | | | | | | | | | | | | | | | | All these separate directories for each ColdFire CPU SoC varient seems like overkill. The majority of them only contain a single small config file. Move these into the common ColdFire code directory. Signed-off-by: Greg Ungerer <gerg@uclinux.org>
| * | m68knommu: move the 523x platform code into the common ColdFire code directoryGreg Ungerer2012-05-204-19/+1
| | | | | | | | | | | | | | | | | | | | | | | | All these separate directories for each ColdFire CPU SoC varient seems like overkill. The majority of them only contain a single small config file. Move these into the common ColdFire code directory. Signed-off-by: Greg Ungerer <gerg@uclinux.org>
| * | m68knommu: move the 520x platform code into the common ColdFire code directoryGreg Ungerer2012-05-204-19/+1
| | | | | | | | | | | | | | | | | | | | | | | | All these separate directories for each ColdFire CPU SoC varient seems like overkill. The majority of them only contain a single small config file. Move these into the common ColdFire code directory. Signed-off-by: Greg Ungerer <gerg@uclinux.org>
| * | m68knommu: move the 5206 platform code into the common ColdFire code directoryGreg Ungerer2012-05-204-22/+2
| | | | | | | | | | | | | | | | | | | | | | | | All these separate directories for each ColdFire CPU SoC varient seems like overkill. The majority of them only contain a single small config file. Move these into the common ColdFire code directory. Signed-off-by: Greg Ungerer <gerg@uclinux.org>
| * | m68knommu: simplify the ColdFire 5407 GPIO struct setupGreg Ungerer2012-05-203-28/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | The GPIO data struct setup is now the only remaining code in the platform gpio.c file. So move it to the platform config.c code and remove the gpio.c file. Signed-off-by: Greg Ungerer <gerg@uclinux.org> Acked-by: Steven King <sfking@fdwdc.com>
| * | m68knommu: simplify the ColdFire 532x GPIO struct setupGreg Ungerer2012-05-203-44/+26
| | | | | | | | | | | | | | | | | | | | | | | | | | | The GPIO data struct setup is now the only remaining code in the platform gpio.c file. So move it to the platform config.c code and remove the gpio.c file. Signed-off-by: Greg Ungerer <gerg@uclinux.org> Acked-by: Steven King <sfking@fdwdc.com>
| * | m68knommu: simplify the ColdFire 5307 GPIO struct setupGreg Ungerer2012-05-203-28/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | The GPIO data struct setup is now the only remaining code in the platform gpio.c file. So move it to the platform config.c code and remove the gpio.c file. Signed-off-by: Greg Ungerer <gerg@uclinux.org> Acked-by: Steven King <sfking@fdwdc.com>
| * | m68knommu: simplify the ColdFire 528x GPIO struct setupGreg Ungerer2012-05-203-50/+32
| | | | | | | | | | | | | | | | | | | | | | | | | | | The GPIO data struct setup is now the only remaining code in the platform gpio.c file. So move it to the platform config.c code and remove the gpio.c file. Signed-off-by: Greg Ungerer <gerg@uclinux.org> Acked-by: Steven King <sfking@fdwdc.com>
| * | m68knommu: simplify the ColdFire 527x GPIO struct setupGreg Ungerer2012-05-203-62/+44
| | | | | | | | | | | | | | | | | | | | | | | | | | | The GPIO data struct setup is now the only remaining code in the platform gpio.c file. So move it to the platform config.c code and remove the gpio.c file. Signed-off-by: Greg Ungerer <gerg@uclinux.org> Acked-by: Steven King <sfking@fdwdc.com>
| * | m68knommu: simplify the ColdFire 5272 GPIO struct setupGreg Ungerer2012-05-203-30/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | The GPIO data struct setup is now the only remaining code in the platform gpio.c file. So move it to the platform config.c code and remove the gpio.c file. Signed-off-by: Greg Ungerer <gerg@uclinux.org> Acked-by: Steven King <sfking@fdwdc.com>
| * | m68knommu: simplify the ColdFire 5249 GPIO struct setupGreg Ungerer2012-05-203-29/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | The GPIO data struct setup is now the only remaining code in the platform gpio.c file. So move it to the platform config.c code and remove the gpio.c file. Signed-off-by: Greg Ungerer <gerg@uclinux.org> Acked-by: Steven King <sfking@fdwdc.com>
| * | m68knommu: simplify the ColdFire 523x GPIO struct setupGreg Ungerer2012-05-203-41/+23
| | | | | | | | | | | | | | | | | | | | | | | | | | | The GPIO data struct setup is now the only remaining code in the platform gpio.c file. So move it to the platform config.c code and remove the gpio.c file. Signed-off-by: Greg Ungerer <gerg@uclinux.org> Acked-by: Steven King <sfking@fdwdc.com>
| * | m68knommu: simplify the ColdFire 520x GPIO struct setupGreg Ungerer2012-05-203-35/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | The GPIO data struct setup is now the only remaining code in the platform gpio.c file. So move it to the platform config.c code and remove the gpio.c file. Signed-off-by: Greg Ungerer <gerg@uclinux.org> Acked-by: Steven King <sfking@fdwdc.com>
| * | m68knommu: simplify the ColdFire 5206 GPIO struct setupGreg Ungerer2012-05-203-28/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | The GPIO data struct setup is now the only remaining code in the platform gpio.c file. So move it to the platform config.c code and remove the gpio.c file. Signed-off-by: Greg Ungerer <gerg@uclinux.org> Acked-by: Steven King <sfking@fdwdc.com>
| * | m68knommu: make duplicated ColdFire GPIO init code common for allGreg Ungerer2012-05-2013-100/+34
| | | | | | | | | | | | | | | | | | | | | | | | | | | The code that adds each ColdFire platforms GPIO signals is duplicated in each platforms specific code. Remove it from each platforms code and put a single version in the existing ColdFire gpio subsystem init code. Signed-off-by: Greg Ungerer <gerg@uclinux.org> Acked-by: Steven King <sfking@fdwdc.com>
| * | m68knommu: switch to GPIO init macros in ColdFire 532x init codeGreg Ungerer2012-05-201-303/+17
| | | | | | | | | | | | | | | | | | | | | | | | Modify the GPIO setup table to use the mcfgpio.h macros for table init. Simplifies code and reduces line count significantly. Signed-off-by: Greg Ungerer <gerg@uclinux.org> Acked-by: Steven King <sfking@fdwdc.com>
| * | m68knommu: switch to GPIO init macros in ColdFire 5407 init codeGreg Ungerer2012-05-201-15/+1
| | | | | | | | | | | | | | | | | | | | | | | | Modify the GPIO setup table to use the mcfgpio.h macros for table init. Simplifies code and reduces line count significantly. Signed-off-by: Greg Ungerer <gerg@uclinux.org> Acked-by: Steven King <sfking@fdwdc.com>
| * | m68knommu: switch to GPIO init macros in ColdFire 5307 init codeGreg Ungerer2012-05-201-15/+1
| | | | | | | | | | | | | | | | | | | | | | | | Modify the GPIO setup table to use the mcfgpio.h macros for table init. Simplifies code and reduces line count significantly. Signed-off-by: Greg Ungerer <gerg@uclinux.org> Acked-by: Steven King <sfking@fdwdc.com>
| * | m68knommu: switch to GPIO init macros in ColdFire 528x init codeGreg Ungerer2012-05-202-503/+103
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Modify the GPIO setup table to use the mcfgpio.h macros for table init. Simplifies code and reduces line count significantly. We also need to rename some of the GPIO registers to be consistent with all other ColdFire parts (we can't use the new GPIO macros otherwise). Signed-off-by: Greg Ungerer <gerg@uclinux.org> Acked-by: Steven King <sfking@fdwdc.com>
| * | m68knommu: switch to GPIO init macros in ColdFire 527x init codeGreg Ungerer2012-05-201-572/+32
| | | | | | | | | | | | | | | | | | | | | | | | Modify the GPIO setup table to use the mcfgpio.h macros for table init. Simplifies code and reduces line count significantly. Signed-off-by: Greg Ungerer <gerg@uclinux.org> Acked-by: Steven King <sfking@fdwdc.com>
| * | m68knommu: switch to GPIO init macros in ColdFire 5272 init codeGreg Ungerer2012-05-201-47/+3
| | | | | | | | | | | | | | | | | | | | | | | | Modify the GPIO setup table to use the mcfgpio.h macros for table init. Simplifies code and reduces line count significantly. Signed-off-by: Greg Ungerer <gerg@uclinux.org> Acked-by: Steven King <sfking@fdwdc.com>
| * | m68knommu: switch to GPIO init macros in ColdFire 5249 init codeGreg Ungerer2012-05-201-31/+2
| | | | | | | | | | | | | | | | | | | | | | | | Modify the GPIO setup table to use the mcfgpio.h macros for table init. Simplifies code and reduces line count significantly. Signed-off-by: Greg Ungerer <gerg@uclinux.org> Acked-by: Steven King <sfking@fdwdc.com>
| * | m68knommu: switch to GPIO init macros in ColdFire 523x init codeGreg Ungerer2012-05-201-250/+14
| | | | | | | | | | | | | | | | | | | | | | | | Modify the GPIO setup table to use the mcfgpio.h macros for table init. Simplifies code and reduces line count significantly. Signed-off-by: Greg Ungerer <gerg@uclinux.org> Acked-by: Steven King <sfking@fdwdc.com>
| * | m68knommu: switch to GPIO init macros in ColdFire 520x init codeGreg Ungerer2012-05-201-141/+8
| | | | | | | | | | | | | | | | | | | | | | | | Modify the GPIO setup table to use the mcfgpio.h macros for table init. Simplifies code and reduces line count significantly. Signed-off-by: Greg Ungerer <gerg@uclinux.org> Acked-by: Steven King <sfking@fdwdc.com>
| * | m68knommu: switch to GPIO init macros in ColdFire 5206 init codeGreg Ungerer2012-05-201-15/+1
| | | | | | | | | | | | | | | | | | | | | | | | Modify the GPIO setup table to use the mcfgpio.h macros for table init. Simplifies code and reduces line count significantly. Signed-off-by: Greg Ungerer <gerg@uclinux.org> Acked-by: Steven King <sfking@fdwdc.com>
| * | m68knommu: introduce macros to simplify ColdFire GPIO table initializationGreg Ungerer2012-05-201-0/+54
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We have very large tables in the ColdFire CPU GPIO setup code that essentially boil down to 2 distinct types of GPIO pin initiaization. Using 2 macros we can reduce these large tables to at most a dozen lines of setup code, and in quite a few cases a single table entry. Introduce these 2 macros into the existing mcfgpio.h header. Signed-off-by: Greg Ungerer <gerg@uclinux.org> Acked-by: Steven King <sfking@fdwdc.com>
| * | m68k: fix compiler warning by properly inlining flat_set_persistent()Ezequiel Garcia2012-05-201-1/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | This patch removes the following warning: fs/binfmt_flat.c:752: warning: unused variable 'persistent'. There is neither functionality change, nor extra code generated. Signed-off-by: Ezequiel Garcia <elezegarcia@gmail.com> Signed-off-by: Greg Ungerer <gerg@uclinux.org>
| * | m68k: merge the MMU and non-MMU signal.c codeGreg Ungerer2012-05-203-1882/+1199
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The MMU (signal_mm.c) and non-MMU (signal_no.c) versions of the m68k architecture signal handling code are very similar. Most of their code is the same. Merge the two back into a single signal.c, and move some of the code around inside the file to minimize the number of #ifdefs required. Specificially we can group out the CONFIG_FPU and the CONFIG_MMU code. We end up needing a few other "#ifdef CONFIG_MMU" as well, but not too many. Signed-off-by: Greg Ungerer <gerg@uclinux.org> Acked-by: Geert Uytterhoeven <geert@linux-m68k.org>
* | | Merge branch 'for-linus' of ↵Linus Torvalds2012-05-218-56/+173
|\ \ \ | |/ / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | git://git.kernel.org/pub/scm/linux/kernel/git/geert/linux-m68k Pull m68k updates from Geert Uytterhoeven. * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/geert/linux-m68k: m68k: Setup CROSS_COMPILE at the top m68k: Correct the Atari ALLOWINT definition m68k/video: Create <asm/vga.h> m68k: Make sure {read,write}s[bwl]() are always defined m68k/mm: Port OOM changes to do_page_fault() scsi/atari: Make more functions static scsi/atari: Revive "atascsi=" setup option net/ariadne: Improve debug prints m68k/atari: Change VME irq numbers from unsigned long to unsigned int m68k/amiga: Use arch_initcall() for registering platform devices m68k/amiga: Add error checks when registering platform devices m68k/amiga: Mark z_dev_present() __init m68k: Remove unused MAX_NOINT_IPL definition
| * | m68k: Setup CROSS_COMPILE at the topGeert Uytterhoeven2012-05-161-6/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | CROSS_COMPILE must be setup before using e.g. cc-option (and a few other as-*, cc-*, ld-* macros), else they will check against the wrong compiler when cross-compiling, and may invoke the cross compiler with wrong or suboptimal compiler options. Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org> Acked-by: Greg Ungerer<gerg@uclinux.org>
| * | m68k: Correct the Atari ALLOWINT definitionMikael Pettersson2012-04-221-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Booting a 3.2, 3.3, or 3.4-rc4 kernel on an Atari using the `nfeth' ethernet device triggers a WARN_ONCE() in generic irq handling code on the first irq for that device: WARNING: at kernel/irq/handle.c:146 handle_irq_event_percpu+0x134/0x142() irq 3 handler nfeth_interrupt+0x0/0x194 enabled interrupts Modules linked in: Call Trace: [<000299b2>] warn_slowpath_common+0x48/0x6a [<000299c0>] warn_slowpath_common+0x56/0x6a [<00029a4c>] warn_slowpath_fmt+0x2a/0x32 [<0005b34c>] handle_irq_event_percpu+0x134/0x142 [<0005b34c>] handle_irq_event_percpu+0x134/0x142 [<0000a584>] nfeth_interrupt+0x0/0x194 [<001ba0a8>] schedule_preempt_disabled+0x0/0xc [<0005b37a>] handle_irq_event+0x20/0x2c [<0005add4>] generic_handle_irq+0x2c/0x3a [<00002ab6>] do_IRQ+0x20/0x32 [<0000289e>] auto_irqhandler_fixup+0x4/0x6 [<00003144>] cpu_idle+0x22/0x2e [<001b8a78>] printk+0x0/0x18 [<0024d112>] start_kernel+0x37a/0x386 [<0003021d>] __do_proc_dointvec+0xb1/0x366 [<0003021d>] __do_proc_dointvec+0xb1/0x366 [<0024c31e>] _sinittext+0x31e/0x9c0 After invoking the irq's handler the kernel sees !irqs_disabled() and concludes that the handler erroneously enabled interrupts. However, debugging shows that !irqs_disabled() is true even before the handler is invoked, which indicates a problem in the platform code rather than the specific driver. The warning does not occur in 3.1 or older kernels. It turns out that the ALLOWINT definition for Atari is incorrect. The Atari definition of ALLOWINT is ~0x400, the stated purpose of that is to avoid taking HSYNC interrupts. irqs_disabled() returns true if the 3-bit ipl & 4 is non-zero. The nfeth interrupt runs at ipl 3 (it's autovector 3), but 3 & 4 is zero so irqs_disabled() is false, and the warning above is generated. When interrupts are explicitly disabled, ipl is set to 7. When they are enabled, ipl is masked with ALLOWINT. On Atari this will result in ipl = 3, which blocks interrupts at ipl 3 and below. So how come nfeth interrupts at ipl 3 are received at all? That's because ipl is reset to 2 by Atari-specific code in default_idle(), again with the stated purpose of blocking HSYNC interrupts. This discrepancy means that ipl 3 can remain blocked for longer than intended. Both default_idle() and falcon_hblhandler() identify HSYNC with ipl 2, and the "Atari ST/.../F030 Hardware Register Listing" agrees, but ALLOWINT is defined as if HSYNC was ipl 3. [As an experiment I modified default_idle() to reset ipl to 3, and as expected that resulted in all nfeth interrupts being blocked.] The fix is simple: define ALLOWINT as ~0x500 instead. This makes arch_local_irq_enable() consistent with default_idle(), and prevents the !irqs_disabled() problems for ipl 3 interrupts. Tested on Atari running in an Aranym VM. Signed-off-by: Mikael Pettersson <mikpe@it.uu.se> Tested-by: Michael Schmitz <schmitzmic@googlemail.com> (on Falcon/CT60) Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
| * | m68k/video: Create <asm/vga.h>Geert Uytterhoeven2012-04-221-0/+27
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For now, it just contains the hack for cirrusfb on Amiga, which is moved out of <video/vga.h> with some slight modifications (use raw_*() instead of z_*(), which are defined on all m68k platforms). This makes it safe to include <video/vga.h> in all contexts. Before it could fail to compile with include/video/vga.h: In function ‘vga_mm_r’: include/video/vga.h:242: error: implicit declaration of function ‘z_readb’ include/video/vga.h: In function ‘vga_mm_w’: include/video/vga.h:247: error: implicit declaration of function ‘z_writeb’ include/video/vga.h: In function ‘vga_mm_w_fast’: include/video/vga.h:253: error: implicit declaration of function ‘z_writew’ or include/video/vga.h:23:21: error: asm/vga.h: No such file or directory depending on the value of CONFIG_AMIGA. Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org> Cc: linux-fbdev@vger.kernel.org Cc: dri-devel@lists.freedesktop.org
| * | m68k: Make sure {read,write}s[bwl]() are always definedGeert Uytterhoeven2012-04-221-0/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | drivers/usb/musb/musb_io.h provides default implementations for {read,write}s[bwl]() on most platforms, some of which will conflict soon with platform-specific counterparts on m68k. To avoid having to add more platform-specific checks to musb_io.h later, make sure {read,write}s[bwl]() are always defined on m68k, and disable the default implementations in musb_io.h on m68k, like is already done for several other architectures. Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org> Acked-by: Felipe Balbi <balbi@ti.com>
| * | m68k/mm: Port OOM changes to do_page_fault()Kautuk Consul2012-04-221-8/+34
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Commit d065bd810b6deb67d4897a14bfe21f8eb526ba99 (mm: retry page fault when blocking on disk transfer) and commit 37b23e0525d393d48a7d59f870b3bc061a30ccdb (x86,mm: make pagefault killable) The above commits introduced changes into the x86 pagefault handler for making the page fault handler retryable as well as killable. These changes reduce the mmap_sem hold time, which is crucial during OOM killer invocation. Port these changes to m68k. Signed-off-by: Kautuk Consul <consul.kautuk@gmail.com> Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
OpenPOWER on IntegriCloud