Commit graph

65 commits

Author SHA1 Message Date
Michael Hennerich b99ab54d4f Blackfin serial driver: use new GPIO API
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-10-11 10:57:54 +08:00
Mike Frysinger 1708268f7e Blackfin arch: scrub remaining ASSEMBLY usage since the switch to __ASSEMBLY__
Signed-off-by: Mike Frysinger <michael.frysinger@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-07-25 11:50:42 +08:00
Michael Hennerich 06039e90b9 Blackfin arch: Fix define - SPORT0_DTPRI is first function
Sigend-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-08-27 16:57:55 +08:00
Bryan Wu 7c100f3b90 Blackfin arch: fix bugs report by Andy Liu <yjhsou@gmail.com>, AD1836 can't be probed in BF561-EZ
Cc: Andy Liu <yjhsou@gmail.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-08-05 15:43:03 +08:00
Bryan Wu 214cccbbb2 Blackfin arch: bug fixing, add missing BF533_FAMILY GPIO_PFx definition
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-07-25 14:42:03 +08:00
Michael Hennerich 40d63406a0 Blackfin arch: store labels so we later know who allocated GPIO/Peripheral resources
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-10-10 22:55:30 +08:00
Michael Hennerich 301af2952b Blackfin arch: Finalize the generic gpio support - add gpio_to_irq and irq_to_gpio
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-07-24 15:35:53 +08:00
Mike Frysinger bc8c84c947 Blackfin arch: update to latest anomaly sheets
Signed-off-by: Mike Frysinger <michael.frysinger@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-08-05 17:32:25 +08:00
Robin Getz fb51d56680 Blackfin arch: Fix Anomaly hanlding, as pointed out by Mike
Signed-off-by: Robin Getz <robin.getz@analog.com>
Cc: Mike Frysinger <michael.frysinger@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-08-03 17:56:29 +08:00
Mike Frysinger 35c724f310 Blackfin arch: fix typo... we want csync in CSYNC(), not ssync
Signed-off-by: Mike Frysinger <michael.frysinger@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-08-03 16:48:13 +08:00
Mike Frysinger 36a1548f99 Blackfin arch: reorganize headers slightly so we can be sure things are defined early enough
Signed-off-by: Mike Frysinger <michael.frysinger@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-07-25 12:01:19 +08:00
Mike Frysinger d5148ffa60 Blackfin arch: use the [CS]SYNC() macros which include anomaly workarounds rather than __builtin_bfin_[cs]sync()
Signed-off-by: Mike Frysinger <michael.frysinger@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-07-25 11:57:42 +08:00
Mike Frysinger 60e9356d77 Blackfin arch: update BF54x anomaly list
Signed-off-by: Mike Frysinger <michael.frysinger@analog.com>
Signed-off-by: Roy Huang <roy.huang@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-07-25 11:56:01 +08:00
Mike Frysinger 1aafd90912 Blackfin arch: revise anomaly handling by basing things on the compiler not the kconfig defines
revise anomaly handling by basing things on the compiler not the kconfig defines,
so the header is stable and usable outside of the kernel. This also allows us to
move some code from preprocessing to compiling (gcc culls dead code)
which should help with code quality (readability, catch minor bugs, etc...).

Signed-off-by: Mike Frysinger <michael.frysinger@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-07-25 11:19:14 +08:00
Mike Frysinger 287050fe13 Blackfin arch: cleanup and standardize anomaly.h file format -- no functional changes
Signed-off-by: Mike Frysinger <michael.frysinger@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-07-24 15:23:20 +08:00
Michael Hennerich cda6a20b68 Blackfin arch: fix PORT_J BUG for BF537/6 EMAC driver reported by Kalle Pokki <kalle.pokki@iki.fi>
Cc: Kalle Pokki <kalle.pokki@iki.fi>
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-10-04 00:36:18 +08:00
Michael Hennerich c58c2140f0 Blackfin arch: gpio pinmux and resource allocation API required by BF537 on chip ethernet mac driver
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-10-04 00:35:05 +08:00
Bryan Wu 0b95f22bd3 Blackfin arch: add some missing syscall
When compiling the Blackfin kernel, checksyscalls.pl will report lots of missing syscalls warnings.
This patch will add some missing syscalls which make sense on Blackfin arch

After appling this patch, toolchain should be rebuilt. Then recompiling the kernel with the new
toolchain.

Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-09-23 00:51:32 +08:00
Mike Frysinger 0931ce8439 Blackfin arch: fix some bugs in lib/string.h functions found by our string testing modules
- use ints for the return value rather than char since we actually return
   an int and we dont want it improperly being sign extended during the reload
   http://blackfin.uclinux.org/gf/project/uclinux-dist/tracker/?action=TrackerItemEdit&tracker_item_id=3525

 - if src is shorter than the requested number of copy bytes, we need to null
   pad the rest
   http://blackfin.uclinux.org/gf/project/uclinux-dist/tracker/?action=TrackerItemEdit&tracker_item_id=3524

 - mark these as __volatile__ and add memory to the clobber list so gcc does
   not optimize buffers around on us we may be using

 - rewrite asm code to be readable/maintainable

Signed-off-by: Mike Frysinger <michael.frysinger@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-09-12 16:30:15 +08:00
Robin Getz e62687f995 Blackfin arch: fix the aliased write macros
Signed-off-by: Robin Getz <robin.getz@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-08-05 17:21:55 +08:00
Stephane Eranian a583f1b542 remove unused TIF_NOTIFY_RESUME flag
Remove unused TIF_NOTIFY_RESUME flag for all processor architectures.  The
flag was not used excecpt on IA-64 where the patch replaces it with
TIF_PERFMON_WORK.

Signed-off-by: stephane eranian <eranian@hpl.hp.com>
Cc: <linux-arch@vger.kernel.org>
Cc: "Luck, Tony" <tony.luck@intel.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-07-31 15:39:38 -07:00
Bryan Wu d8e715428f Blackfin arch: add BF54x I2C/TWI TWI0 driver support
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-07-25 16:58:03 +08:00
Bernd Schmidt 8be80ed3f7 Blackfin arch: Initialize the exception vectors early in the boot process
Initialize the exception vectors early in the boot process, so that CPLB faults
can be handled when memory protection is enabled.

Signed-off-by: Bernd Schmidt <bernd.schmidt@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-07-25 14:44:49 +08:00
Mike Frysinger 12a7991180 Blackfin arch: switch to using proper defines this time THREAD_SIZE and PAGE_SIZE instead of just PAGE_SIZE everywhere
Signed-off-by: Mike Frysinger <michael.frysinger@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-07-25 10:25:29 +08:00
Mike Frysinger 315a8e34f7 Blackfin arch: setup aliases for some core Core A MMRs
setup aliases for some core Core A MMRs to ease porting in cases
where common code would actually want Core A (or Core B MMR is reserved)

Signed-off-by: Mike Frysinger <michael.frysinger@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-07-24 15:58:41 +08:00
Antonino A. Daplas 317b3c2167 fbdev: detect primary display device
Add function helper, fb_is_primary_device().  Given struct fb_info, it will
return a nonzero value if the device is the primary display.

Currently, only the i386 is supported where the function checks for the
IORESOURCE_ROM_SHADOW flag.

Signed-off-by: Antonino Daplas <adaplas@gmail.com>
Cc: David Miller <davem@davemloft.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-07-17 10:23:11 -07:00
Antonino A. Daplas 10eb2659cc fbdev: move arch-specific bits to their respective subdirectories
Move arch-specific bits of fb_mmap() to their respective subdirectories

[bob.picco@hp.com: efi_range_is_wc is referenced but not declared]
[bunk@stusta.de: fix include/asm-m68k/fb.h]
Signed-off-by: Antonino Daplas <adaplas@gmail.com>
Acked-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Adrian Bunk <bunk@stusta.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-07-17 10:23:11 -07:00
Sonic Zhang 61b5956326 Blackfin arch: Add peripheral io API to gpio header file
Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-07-12 17:06:45 +08:00
Sonic Zhang e745106ce3 Blackfin arch: set up gpio interrupt IRQ_PJ9 for BF54x ATAPI PATA driver
Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-07-12 15:20:25 +08:00
Bryan Wu c04d66bbbd Blackfin arch: clean up some coding style issues
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-07-12 17:26:31 +08:00
Michael Hennerich 5610db61cf Blackfin arch: Add Support for Peripheral PortMux and resouce allocation
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-07-12 12:32:52 +08:00
Mike Frysinger 520473b077 Blackfin arch: use PAGE_SIZE when doing aligns rather than hardcoded values
Signed-off-by: Mike Frysinger <michael.frysinger@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-07-12 12:20:20 +08:00
Michael Hennerich 9be343c5bc Blackfin arch: There is no CDPRIO Bit in the EBIU_AMGCTL Register of BF54x arch
However there are similar things in the EBIU_DDRQUE Register

Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-07-12 11:58:44 +08:00
Michael Hennerich c9e27ece79 Blackfin arch: Fix Warning add some defines in BF54x header file
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-07-12 11:48:14 +08:00
Michael Hennerich cefe658bca Blackfin arch: add BF54x missing GPIO access functions
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-07-02 11:45:50 +08:00
Michael Hennerich 34e0fc89bd Blackfin arch: Enable BF54x PIN/GPIO interrupts
Signed-off-bu: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-07-12 16:17:18 +08:00
Robin Getz 669b792c77 Blackfin arch: Clean up trace buffer handling, No major functional changes.
Turns on trace earlier, so crashes at kernel start should print out a
trace, making things easier to debug.

Signed-off-by: Robin Getz <robin.getz@analog.com>
Signed-off-by: Mike Frysinger <michael.frysinger@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-06-21 16:34:08 +08:00
Bernd Schmidt 29440a2b4c Blackfin arch: Start untangling the CPLB handling code.
- Move cache initialization to C from assembly.
 - Move anomaly workaround for writing [ID]MEM_CONTROL to assembly, so
   that we don't have to mess around with .align directives in C source.
 - Fix a bug where bfin_write_DMEM_CONTROL would write to IMEM_CONTROL
 - Break out CPLB related code from kernel/setup.c into their own file.
 - Don't define variables in header files, only declare them.

Signed-off-by: Bernd Schmidt <bernd.schmidt@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-07-12 16:25:29 +08:00
Sonic Zhang 474f1a667d Blackfin arch: kgdb specific code
Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-06-29 16:35:17 +08:00
Michael Hennerich 1c5d2265a8 Blackfin arch: add missing implementations SIC_IWR crosses several registers
SIC_IWR crosses several registers
 - add missing implementations
 - make sure SIC_IWR is SET after boot

Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-06-21 11:34:16 +08:00
Bernd Schmidt 7adfb58fbd Blackfin arch: defines and provides entry points for certain user space functions at fixed addresses
This patch defines (and provides) entry points for certain user space functions
at fixed addresses.  The Blackfin has no usable atomic instructions, but we can
ensure that these code sequences appear atomic from a user space point of view
by detecting when we're in the process of executing them during the interrupt
handler return path.  This allows much more efficient pthread lock
implementations than the bfin_spinlock syscall we're currently using.

Also provided is a small sys_rt_sigreturn stub which can be used by the signal
handler setup code.  The signal.c part will be committed separately.

Signed-off-by: Bernd Schmidt <bernd.schmidt@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-06-21 11:34:16 +08:00
Roy Huang 24a07a1241 Blackfin arch: initial supporting for BF548-EZKIT
The ADSP-BF54x was specifically designed to meet the needs of convergent multimedia
applications where system performance and cost are essential ingredients. The
integration of multimedia, human interface, and connectivity peripherals combined
with increased system bandwidth and on-chip memory provides customers a platform to
design the most demanding applications.

Since now, ADSP-BF54x will be supported in the Linux kernel and bunch of related drivers
such as USB OTG, ATAPI, NAND flash controller, LCD framebuffer, sound, touch screen will
be submitted later.

Please enjoy the show.

Signed-off-by: Roy Huang <roy.huang@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-07-12 22:41:45 +08:00
Roy Huang 088eec1192 Blackfin arch: Add header files for BF548
Signed-off-by: Roy Huang <roy.huang@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-06-21 11:34:16 +08:00
Alan Cox 4eb6bf6bfb lots-of-architectures: enable arbitary speed tty support
Add the termios2 structure ready for enabling on most platforms.  One or
two like Sparc are plain weird so have been left alone.  Most can use the
same structure as ktermios for termios2 (ie the newer ioctl uses the
structure matching the current kernel structure)

Signed-off-by: Alan Cox <alan@redhat.com>
Cc: Bryan Wu <bryan.wu@analog.com>
Cc: Ian Molton <spyro@f2s.com>
Cc: Haavard Skinnemoen <hskinnemoen@atmel.com>
Cc: Yoshinori Sato <ysato@users.sourceforge.jp>
Cc: Mikael Starvik <starvik@axis.com>
Cc: David Howells <dhowells@redhat.com>
Cc: "Luck, Tony" <tony.luck@intel.com>
Cc: Hirokazu Takata <takata@linux-m32r.org>
Cc: Geert Uytterhoeven <geert@linux-m68k.org>
Cc: Roman Zippel <zippel@linux-m68k.org>
Cc: Ralf Baechle <ralf@linux-mips.org>
Cc: Kyle McMartin <kyle@mcmartin.ca>
Cc: Matthew Wilcox <willy@debian.org>
Cc: Heiko Carstens <heiko.carstens@de.ibm.com>
Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
Cc: Paul Mundt <lethal@linux-sh.org>
Cc: Kazumoto Kojima <kkojima@rr.iij4u.or.jp>
Cc: Richard Curnow <rc@rc0.org.uk>
Cc: Miles Bader <uclinux-v850@lsi.nec.co.jp>
Cc: Chris Zankel <chris@zankel.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-07-10 17:51:13 -07:00
Marco Roeland 7718457dc8 Blackfin arch: remove zero-sized include/asm-blackfin/macros.h
This file accidentally got truncated instead of deleted in commit df30b11.

Signed-off-by: Marco Roeland <marco.roeland@xs4all.nl>
Cc: Robert P. J. Day <rpjday@mindspring.com>
Cc: Jeff Garzik <jeff@garzik.org>
Cc: Jesper Juhl <jesper.juhl@gmail.com>
Cc: Alex Riesen <raa.lkml@gmail.com>
Cc: Robin Getz <robin.getz@analog.com>
Acked-by: Bryan Wu <bryan.wu@analog.com>
2007-07-03 08:25:50 +08:00
Jie Zhang de3025f4e2 Blackfin arch: Add proper -mcpu option according to the cpu and silicon revision configuration
Add silicon revision "any" and "none". Add proper -mcpu option according
to the cpu and silicon revision configuration.

Need update to use latest Blackfin cross compile toolchain.

Signed-off-by: Jie Zhang <jie.zhang@analog.com>
Signed-off-by: Mike Frysinger <michael.frysinger@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-06-25 18:04:12 +08:00
Mike Frysinger 216e39db11 Blackfin arch: add proper const volatile to addr argument to the read functions
Signed-off-by: Mike Frysinger <michael.frysinger@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-06-21 11:34:16 +08:00
Sonic Zhang 334280fff3 Blackfin arch: Add definition of dma_mapping_error
Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-06-21 11:34:16 +08:00
Mike Frysinger b9b7127657 Blackfin arch: move cond_syscall() behind __KERNEL__ like all other architectures
Signed-off-by: Mike Frysinger <michael.frysinger@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-06-21 11:34:16 +08:00
Mike Frysinger 9c8f1729b0 Blackfin arch: add missing braces around array bfin serial init
Signed-off-by: Mike Frysinger <michael.frysinger@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2007-06-21 11:34:16 +08:00