aboutsummaryrefslogtreecommitdiffstats
path: root/arch/blackfin/mach-common
Commit message (Collapse)AuthorAgeFilesLines
* Blackfin arch: Fix bug - skip single step in high priority interrupt handler ↵Sonic Zhang2008-07-261-12/+38
| | | | | | | | | | | instead of disabling all interrupts in single step debugging. Skip single step if event priority of current instruction is higher than that of the first instruction, from which gdb starts single step. Signed-off-by: Sonic Zhang <sonic.zhang@analog.com> Signed-off-by: Bryan Wu <cooloney@kernel.org>
* Blackfin arch: use local labels and ENDPROC() markingsMike Frysinger2008-07-161-6/+13
| | | | | | Signed-off-by: Mike Frysinger <vapier.adi@gmail.com> Signed-off-by: Bryan Wu <cooloney@kernel.org>
* Blackfin arch: Functional power management supportMichael Hennerich2008-07-192-45/+780
| | | | | | | | | | Enable: PM_SUSPEND_MEM -> Blackfin Hibernate to SDRAM This feature requires a special bootloader (u-boot) supporting return from hibernate. Signed-off-by: Michael Hennerich <michael.hennerich@analog.com> Signed-off-by: Bryan Wu <cooloney@kernel.org>
* Blackfin arch: Remove redundant kernel optionMichael Hennerich2008-07-141-6/+0
| | | | | | | | | use kernel command line mem and max_mem bootargs to limit availabe memory instead. Signed-off-by: Michael Hennerich <michael.hennerich@analog.com> Signed-off-by: Bryan Wu <cooloney@kernel.org>
* Blackfin arch: Fix Bug - GPIO interrupts not disabled; edge sensitive ↵Michael Hennerich2008-07-141-0/+4
| | | | | | | | | | interrupt hang system. - Implement irq_chip.enable and irq_chip.disable Signed-off-by: Michael Hennerich <michael.hennerich@analog.com> Signed-off-by: Bryan Wu <cooloney@kernel.org>
* [Blackfin] arch: fix gdb testing regressionBernd Schmidt2008-05-071-31/+77
| | | | | | | | | | | | | | When transferring to IRQ5 from an exception, save SYSCFG in memory across the transfer and clear the trace bit. When we get a single step exception, check whether we can safely clear the trace bit in SYSCFG. We can (and should) clear it after the first instruction of the interrupt handler; the first insn saves SYSCFG to the stack in all handlers. Signed-off-by: Bernd Schmidt <bernds_cb1@t-online.de> Signed-off-by: Bryan Wu <cooloney@kernel.org>
* [Blackfin] arch: In the double fault handler, set up the PT_RETI slotBernd Schmidt2008-05-071-0/+5
| | | | | | | | | In the double fault handler, set up the PT_RETI slot so that we print out the correct return address in the dumping code. Signed-off-by: Bernd Schmidt <bernds_cb1@t-online.de> Signed-off-by: Bryan Wu <cooloney@kernel.org>
* [Blackfin] arch: Support for CPU_FREQ and NOHZVitja Makarov2008-05-071-9/+15
| | | | | Singed-off-by: Vitja Makarov <vitja.makarov@gmail.com>
* [Blackfin] arch: Functional power management support: Add CPU and platform ↵Michael Hennerich2008-05-073-27/+142
| | | | | | | | voltage scaling support Signed-off-by: Michael Hennerich <michael.hennerich@analog.com> Signed-off-by: Bryan Wu <cooloney@kernel.org>
* [Blackfin] arch: Cleanup Kconfig, fix comment and make sure we exclude ↵Michael Hennerich2008-05-071-2/+2
| | | | | | | | CCLK=SCLK for some configurations Signed-off-by: Michael Hennerich <michael.hennerich@analog.com> Signed-off-by: Bryan Wu <cooloney@kernel.org>
* [Blackfin] arch: Functional power management support: Add support for cpu ↵Michael Hennerich2008-04-252-1/+196
| | | | | | | | frequency scaling Signed-off-by: Michael Hennerich <michael.hennerich@analog.com> Signed-off-by: Bryan Wu <cooloney@kernel.org>
* [Blackfin] arch: Remove the circular buffering mechanism for exceptionsBernd Schmidt2008-04-252-90/+33
| | | | | | | | | | | | | | | | Remove the circular buffering mechanism for exceptions. Instead, point RETX at a safe location from which to fetch three NOPs. This safe location is now in the fixed code area, and also used for certain anomaly workarounds, to ensure that user space can find a valid ICPLB when things are built with CONFIG_MPU. Also, save I/DCPLB_FAULT_ADDRESS when lowering to level 5, since the hardware reg is valid only at exception level. Signed-off-by: Bernd Schmidt <bernds_cb1@t-online.de> Signed-off-by: Bryan Wu <cooloney@kernel.org>
* [Blackfin] arch: Allow concurrent use of GPIO and GPIO IRQMichael Hennerich2008-04-241-39/+13
| | | | | | | | | | | The irq setup code no longer calls gpio request and free. This patch also changes the default gpio_free behavior on Blackfin. A freed GPIO keeps it's last state, and is not defaulted back to an input. This is also what all other architectures do. Signed-off-by: Michael Hennerich <michael.hennerich@analog.com> Signed-off-by: Bryan Wu <cooloney@kernel.org>
* [Blackfin] arch: detect the memory available in the system on the fly by defaultMike Frysinger2008-04-251-1/+2
| | | | | | | | | detect the memory available in the system on the fly by default rather than forcing people to set this manually in the kconfig Signed-off-by: Mike Frysinger <vapier.adi@gmail.com> Signed-off-by: Bryan Wu <cooloney@kernel.org>
* [Blackfin] arch: make the mask explicit rather than writing a negative ↵Mike Frysinger2008-04-241-1/+1
| | | | | | | | number in hex Signed-off-by: Mike Frysinger <vapier.adi@gmail.com> Signed-off-by: Bryan Wu <cooloney@kernel.org>
* [Blackfin] arch: __FUNCTION__ is gcc-specific, use __func__Harvey Harrison2008-04-231-1/+1
| | | | | | | | | | Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com> Cc: Mike Frysinger <vapier.adi@gmail.com> Signed-off-by: Bryan Wu <cooloney@kernel.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Bryan Wu <cooloney@kernel.org>
* [Blackfin] arch: fix bug - when using trace buffer with CONFIG_MPU enabled.Bernd Schmidt2008-04-231-1/+6
| | | | | | | | | | | | | | | | | There were a couple of problems with the way the trace buffer state is saved/restored in assembly. The DEBUG_HWTRACE_SAVE/RESTORE macros save a value to the stack, which is not immediately obvious; the CPLB exception code needed changes to load the correct value of the stack pointer. The other problem is that the SAVE/RESTORE macros weren't pushing and popping the value downwards on the stack, but rather moving it _upwards_, which is of course completely broken. We also need to make sure there's a matching DEBUG_HWTRACE_RESTORE in the error case of the CPLB handler. Signed-off-by: Bernd Schmidt <bernds_cb1@t-online.de> Signed-off-by: Bryan Wu <cooloney@kernel.org>
* [Blackfin] arch: to kill syscalls missing warning by adding new timerfd syscallsBryan Wu2008-03-061-1/+4
| | | | | Signed-off-by: Bryan Wu <cooloney@kernel.org>
* [Blackfin] arch: Fix CONFIG_PM support for BF561Michael Hennerich2008-02-251-4/+2
| | | | | | Signed-off-by: Michael Hennerich <michael.hennerich@analog.com> Signed-off-by: Bryan Wu <cooloney@kernel.org>
* [Blackfin] arch: Remove DPMC char driver optionMichael Hennerich2008-02-251-131/+0
| | | | | | | | Remove redundant/obsolete/dead code from DPMC driver Signed-off-by: Michael Hennerich <michael.hennerich@analog.com> Signed-off-by: Bryan Wu <cooloney@kernel.org>
* [Blackfin] arch: Cleanup abd Simplify:Michael Hennerich2008-02-251-106/+51
| | | | | | | | | | | - Simplify init_arch_irq - Make code more readable - Remove useless SSYNCs - Fix comments Signed-off-by: Michael Hennerich <michael.hennerich@analog.com> Signed-off-by: Bryan Wu <cooloney@kernel.org>
* [Blackfin] arch: fix bug - linux-2.6.24 (delayed) disable IRQ feature not ↵Michael Hennerich2008-02-251-0/+3
| | | | | | | | | | | | | functional for handle_simple_irq Bypass delayed disable feature by implementing chip->disable and chip->enable. http://lkml.org/lkml/2008/2/19/115 Signed-off-by: Michael Hennerich <michael.hennerich@analog.com> Signed-off-by: Bryan Wu <cooloney@kernel.org>
* [Blackfin] arch: fix bug - Move IWR Enable All to the end of init_arch_irq ↵Michael Hennerich2008-02-251-4/+10
| | | | | | | | otherwise it fails Signed-off-by: Michael Hennerich <michael.hennerich@analog.com> Signed-off-by: Bryan Wu <cooloney@kernel.org>
* [Blackfin] arch:Fix BUG [#3876] pfbutton test for BTN3 on bf533 don't show ↵Michael Hennerich2008-02-021-9/+13
| | | | | | | | | | | complete info - Buttons on the BF533-STAMP board are not inverted - Fix spurious GPIO Interrupt caused during set irq_type for edge triggered interrupts Signed-off-by: Michael Hennerich <michael.hennerich@analog.com> Signed-off-by: Bryan Wu <bryan.wu@analog.com>
* [Blackfin] arch: change the trace buffer control start/stop logic in the ↵Mike Frysinger2008-02-021-8/+4
| | | | | | | | | | | | exception handlers To save/restore the trace buffer control so that if we take an exception after turning off the trace buffer at a higher level we dont inadvertently turn the trace buffer back on Signed-off-by: Mike Frysinger <vapier.adi@gmail.com> Signed-off-by: Bryan Wu <bryan.wu@analog.com>
* [Blackfin] arch: hook up set_irq_wake in Blackfin's irq codeMichael Hennerich2008-02-093-34/+168
| | | | | | | | | | | - Add support for irq_wake on system and gpio interrupts - Remove outdated kernel options - Add option to select default PM mode - Fix various places where SIC_IWRx was only handled partially Signed-off-by: Michael Hennerich <michael.hennerich@analog.com> Signed-off-by: Bryan Wu <bryan.wu@analog.com>
* [Blackfin] arch: Merge BF561 support into ints-priorityMichael Hennerich2008-02-093-520/+97
| | | | | | | | | Merge single core ints-priority-sc.c and dual core ints-priority-dc.c into one common code ints-priority.c Signed-off-by: Michael Hennerich <michael.hennerich@analog.com> Signed-off-by: Bryan Wu <bryan.wu@analog.com>
* timerfd: new timerfd APIDavide Libenzi2008-02-051-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is the new timerfd API as it is implemented by the following patch: int timerfd_create(int clockid, int flags); int timerfd_settime(int ufd, int flags, const struct itimerspec *utmr, struct itimerspec *otmr); int timerfd_gettime(int ufd, struct itimerspec *otmr); The timerfd_create() API creates an un-programmed timerfd fd. The "clockid" parameter can be either CLOCK_MONOTONIC or CLOCK_REALTIME. The timerfd_settime() API give new settings by the timerfd fd, by optionally retrieving the previous expiration time (in case the "otmr" parameter is not NULL). The time value specified in "utmr" is absolute, if the TFD_TIMER_ABSTIME bit is set in the "flags" parameter. Otherwise it's a relative time. The timerfd_gettime() API returns the next expiration time of the timer, or {0, 0} if the timerfd has not been set yet. Like the previous timerfd API implementation, read(2) and poll(2) are supported (with the same interface). Here's a simple test program I used to exercise the new timerfd APIs: http://www.xmailserver.org/timerfd-test2.c [akpm@linux-foundation.org: coding-style cleanups] [akpm@linux-foundation.org: fix ia64 build] [akpm@linux-foundation.org: fix m68k build] [akpm@linux-foundation.org: fix mips build] [akpm@linux-foundation.org: fix alpha, arm, blackfin, cris, m68k, s390, sparc and sparc64 builds] [heiko.carstens@de.ibm.com: fix s390] [akpm@linux-foundation.org: fix powerpc build] [akpm@linux-foundation.org: fix sparc64 more] Signed-off-by: Davide Libenzi <davidel@xmailserver.org> Cc: Michael Kerrisk <mtk-manpages@gmx.net> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Davide Libenzi <davidel@xmailserver.org> Cc: Michael Kerrisk <mtk-manpages@gmx.net> Cc: Martin Schwidefsky <schwidefsky@de.ibm.com> Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com> Cc: Michael Kerrisk <mtk.manpages@gmail.com> Cc: Davide Libenzi <davidel@xmailserver.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* [Blackfin] arch: Add the semtimedop syscall. Upstream uClibc doesn't ↵Bernd Schmidt2008-01-271-0/+1
| | | | | | | | compile without it. Signed-off-by: Bernd Schmidt <bernd.schmidt@analog.com> Signed-off-by: Bryan Wu <bryan.wu@analog.com>
* [Blackfin] arch: Initial checkin of the memory protection support.Bernd Schmidt2008-01-271-0/+19
| | | | | | | | Enable it with CONFIG_MPU. Signed-off-by: Bernd Schmidt <bernd.schmidt@analog.com> Signed-off-by: Bryan Wu <bryan.wu@analog.com>
* [Blackfin] arch: Add some comments - fix semicolonsMichael Hennerich2008-01-111-17/+15
| | | | | | Signed-off-by: Michael Hennerich <michael.hennerich@analog.com> Signed-off-by: Bryan Wu <bryan.wu@analog.com>
* [Blackfin] arch: move all code related to CPLB handling into a new ↵Bernd Schmidt2008-01-114-986/+1
| | | | | | | | subdirectory under kernel/ Signed-off-by: Bernd Schmidt <bernd.schmidt@analog.com> Signed-off-by: Bryan Wu <bryan.wu@analog.com>
* [Blackfin] arch: Enable both edge triggered GPIO IRQs on BF54x and use ↵Michael Hennerich2007-12-241-21/+46
| | | | | | | | irq_to_gpio() Signed-off-by: Michael Hennerich <michael.hennerich@analog.com> Signed-off-by: Bryan Wu <bryan.wu@analog.com>
* [Blackfin] arch: append IRQ Number to label stringMichael Hennerich2007-12-242-8/+19
| | | | | | Signed-off-by: Michael Hennerich <michael.hennerich@analog.com> Signed-off-by: Bryan Wu <bryan.wu@analog.com>
* [Blackfin] arch: Fix bug to Enable kernel to build for bf548 with PM.Sonic Zhang2007-12-232-8/+54
| | | | | | | | | On BF548-EZKIT, build kernel faills with power management, video and audio enabled. This patch fix this. Signed-off-by: Sonic Zhang <sonic.zhang@analog.com> Signed-off-by: Bryan Wu <bryan.wu@analog.com>
* [Blackfin] arch: Let the pre-processor do the math to save a few cycles - no ↵Robin Getz2007-12-211-3/+1
| | | | | | | | functional changes Signed-off-by: Robin Getz <robin.getz@analog.com> Signed-off-by: Bryan Wu <bryan.wu@analog.com>
* [Blackfin] arch: do not use fixed numbers to describe offsets - no ↵Robin Getz2007-12-211-1/+1
| | | | | | | | functional changes Signed-off-by: Robin Getz <robin.getz@analog.com> Signed-off-by: Bryan Wu <bryan.wu@analog.com>
* [Blackfin] arch: do not use hard coded addressesRobin Getz2007-12-211-4/+4
| | | | | | Signed-off-by: Robin Getz <robin.getz@analog.com> Signed-off-by: Bryan Wu <bryan.wu@analog.com>
* [Blackfin] arch: fix bug - trap_tests fails to recover on some tests.Robin Getz2008-01-273-63/+49
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | http://blackfin.uclinux.org/gf/project/uclinux-dist/tracker/?action=TrackerItemEdit&tracker_item_id=3719 When the CPLBs get a miss, we do: - find a victim in the HW table - remove the victim - find the replacement in the software table - put it into the HW table. If we can't find a replacement in the software table, we accidently leave a duplicate in the HW table. This patch ensures that duplicate is marked as not valid. What we should do is find the replacement in the software table, before we find a victim in the HW table - but its too late in the release cycle to do that much restructuring of this code. Rather that duplicate code, connect Hardware Errors (irq5) into trap_c, so user space processes get killed properly. The rest of irq_panic() can be moved into traps.c (later) There is still a small corner case that causes problems when a pheriperal interrupt goes off a single cycle before a user space hardware error. This causes a kernel panic, rather than the user space process being killed. But, this checkin makes things work in 99.9% of the cases, and is a vast improvement from what is there today (which fails 100% of the time). Signed-off-by: Robin Getz <robin.getz@analog.com> Signed-off-by: Bryan Wu <bryan.wu@analog.com>
* [Blackfin] arch: Add a note describing what is going on - no functional changesRobin Getz2008-01-271-2/+13
| | | | | | Signed-off-by: Robin Getz <robin.getz@analog.com> Signed-off-by: Bryan Wu <bryan.wu@analog.com>
* Blackfin arch: split apart dump_bfin_regs and merge/remove show_regs from ↵Mike Frysinger2007-11-211-1/+3
| | | | | | | | process.c, which was largely duplicated Signed-off-by: Mike Frysinger <michael.frysinger@analog.com> Signed-off-by: Bryan Wu <bryan.wu@analog.com>
* Blackfin arch: use common __INIT/__FINIT defines rather than setting the ↵Mike Frysinger2007-11-211-2/+3
| | | | | | | | .section ourselves to .init.text Signed-off-by: Mike Frysinger <michael.frysinger@analog.com> Signed-off-by: Bryan Wu <bryan.wu@analog.com>
* Blackfin arch: Ensure we printk out strings with the proper loglevelRobin Getz2007-11-211-5/+5
| | | | | | Signed-off-by: Robin Getz <robin.getz@analog.com> Signed-off-by: Bryan Wu <bryan.wu@analog.com>
* Blackfin arch: Need to specify ax with the .init.text section,Bernd Schmidt2007-11-211-1/+1
| | | | | Need to specify "ax" with the .init.text section, otherwise the linker will make unique .init.text.1 .. .init.text.3 sections to cope with the flags
* Blackfin arch: Fix typo, and add ENDPROC - no functional changesMike Frysinger2007-11-211-1/+2
| | | | | | Signed-off-by: Mike Frysinger <michael.frysinger@analog.com> Signed-off-by: Bryan Wu <bryan.wu@analog.com>
* Blackfin arch: rename _return_from_exception to _bfin_return_from_exception ↵Mike Frysinger2007-11-211-4/+4
| | | | | | | | and export it Signed-off-by: Mike Frysinger <michael.frysinger@analog.com> Signed-off-by: Bryan Wu <bryan.wu@analog.com>
* Blackfin arch: fix spurious newline in headerMike Frysinger2007-11-171-1/+1
| | | | | | Signed-off-by: Mike Frysinger <michael.frysinger@analog.com> Signed-off-by: Bryan Wu <bryan.wu@analog.com>
* Blackfin arch: do not include linux/autoconf.hMike Frysinger2007-11-151-1/+0
| | | | | | Signed-off-by: Mike Frysinger <michael.frysinger@analog.com> Signed-off-by: Bryan Wu <bryan.wu@analog.com>
* Blackfin arch: remove useless CONFIG_IRQCHIP_DEMUX_GPIOMike Frysinger2007-11-152-31/+18
| | | | | | | | since we have this always turned on now and dont want it off (and hasnt been an option in a while) Signed-off-by: Mike Frysinger <michael.frysinger@analog.com> Signed-off-by: Bryan Wu <bryan.wu@analog.com>
* Blackfin arch: fix bug cplbmgr.S does not exit properly on error conditionRobin Getz2007-11-151-7/+18
| | | | | | | | | | | | https://blackfin.uclinux.org/gf/project/uclinux-dist/tracker/?action=TrackerItemEdit&tracker_item_id=1685 Ensure that cache/protection is turned back on when we get a fault, and ensure that the initial population of the CPLB tables are correct - that kernel is locked in CPLB tables Signed-off-by: Robin Getz <robin.getz@analog.com> Signed-off-by: Bryan Wu <bryan.wu@analog.com>