Commit Graph

1026 Commits (6941c3a0aabb6ad4167827360f384e9daed7dd7f)

Author SHA1 Message Date
Mike Frysinger 36f649a55a Blackfin arch: do not define decode_instruction if hwtrace is turned off
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-11-18 17:48:22 +08:00
Mike Frysinger 4005978424 Blackfin arch: rename irq_flags to bfin_irq_flags
rename irq_flags to bfin_irq_flags to avoid namespace
collision with common code

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-11-18 17:48:22 +08:00
Mike Frysinger b60705765a Blackfin arch: move out irq related functions
move irq related functions into asm/irq.h and out of the mondo asm/system.h

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-11-18 17:48:22 +08:00
Mike Frysinger b1271d31a5 Blackfin arch: move the PORT registers down
Move the PORT registers down as well since they may utilize
asm/system.h code

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-11-18 17:48:22 +08:00
Mike Frysinger 31fba6e752 Blackfin arch: introduce an IM_MEM macro to kgdb
create an IN_MEM() macro to simplify comparing an address in an on-chip
region of memory and make things readable

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-11-18 17:48:22 +08:00
Mike Frysinger 89c6c139a5 Blackfin arch: fix off-by-one errors on end of memory range
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-11-18 17:48:22 +08:00
Mike Frysinger 09c1db922d Blackfin arch: delete unused vars and add parenthesis to fixup warnings
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-11-18 17:48:22 +08:00
Mike Frysinger bda07aac9d Blackfin arch: move fixed code into init section
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-11-18 17:48:22 +08:00
Mike Frysinger f8c1b3909c Blackfin arch: remove superficial check on blackfin watchdog
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-11-18 17:48:22 +08:00
Mike Frysinger d1a3336e2f Blackfin arch: set PM_WAKEUP_GPIO_NUMBER default to 2 for everyone
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-11-18 17:48:22 +08:00
Mike Frysinger 53442e1cbd Blackfin arch: delay PLL_CTL/VR_CTL wrappers
Delay PLL_CTL/VR_CTL wrappers as much as possible to avoid
the inter-dependency problems with cdef and common headers

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-11-18 17:48:22 +08:00
Mike Frysinger b94919e2da Blackfin arch: dont export ack_bad_irq as no one else does
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-11-18 17:48:22 +08:00
Mike Frysinger 7beb7439ac Blackfin arch: move SIC_SYSIRQ() to the one file that actually uses it
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-11-18 17:48:22 +08:00
Mike Frysinger a638735b3d Blackfin arch: move ack_bad_irq() prototype to hardirq.h to match other arches
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-11-18 17:48:22 +08:00
Mike Frysinger 34616c8bbd Blackfin arch: delete old comments and NO_IRQ define
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-11-18 17:48:22 +08:00
Mike Frysinger 8a86176c4a Blackfin arch: overlay thread.usp over PT_USP
overlay thread.usp over PT_USP when getting the whole regfile to
match PT_USP behavior

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-11-18 17:48:22 +08:00
Mike Frysinger 3c1fbd5184 Blackfin arch: rewrite blackfin_invalidate_entire_dcache function
rewrite blackfin_invalidate_entire_dcache() in C for easier management,
better optimization, and so we take all SSYNC anomalies into account

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-11-18 17:48:22 +08:00
Mike Frysinger fe85cad25e Blackfin arch: make ADI board names consistent
Cc: Graf Yang <graf.yang@analog.com>
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-11-18 17:48:22 +08:00
Sonic Zhang 8a0e9acfd1 Blackfin arch: Fix bug - hardware breakpoint doesn't always work in kgdb
Hardware breakpoint doesn't always work in kgdb. It works at the first
two times, but if you repeatedly trigger that hardware breakpoint, it
would slip over that point once in two times.

Fix it by always setting hw bp skip to 0. gdb does skip after hw bp trap.

Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-11-18 17:48:22 +08:00
Mike Frysinger 0b82e27444 Blackfin arch: fix unused warning for some blackfin derivatives
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-11-18 17:48:22 +08:00
Bryan Wu 2e8ca59147 Blackfin arch: Use GPIO_BANKSIZE macro to replace const number 16 for GPIO_BANK_NUM macro caculating
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-11-18 17:48:22 +08:00
Graf Yang 46fa5eecec Blackfin arch: SMP supporting patchset: some other misc code
Blackfin dual core BF561 processor can support SMP like features.
https://docs.blackfin.uclinux.org/doku.php?id=linux-kernel:smp-like

In this patch, we provide SMP extend to some other misc code

Singed-off-by: Graf Yang <graf.yang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2009-01-07 23:14:39 +08:00
Graf Yang 8f65873e47 Blackfin arch: SMP supporting patchset: Blackfin kernel and memory management code
Blackfin dual core BF561 processor can support SMP like features.
https://docs.blackfin.uclinux.org/doku.php?id=linux-kernel:smp-like

In this patch, we provide SMP extend to Blackfin kernel and memory management code

Singed-off-by: Graf Yang <graf.yang@analog.com>
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-11-18 17:48:22 +08:00
Graf Yang b8a989893c Blackfin arch: SMP supporting patchset: Blackfin CPLB related code
Blackfin dual core BF561 processor can support SMP like features.
https://docs.blackfin.uclinux.org/doku.php?id=linux-kernel:smp-like

In this patch, we provide SMP extend to Blackfin CPLB related code

Signed-off-by: Graf Yang <graf.yang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-11-18 17:48:22 +08:00
Graf Yang 6b3087c64a Blackfin arch: SMP supporting patchset: Blackfin header files and machine common code
Blackfin dual core BF561 processor can support SMP like features.
https://docs.blackfin.uclinux.org/doku.php?id=linux-kernel:smp-like

In this patch, we provide SMP extend to Blackfin header files
and machine common code

Signed-off-by: Graf Yang <graf.yang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2009-01-07 23:14:39 +08:00
Graf Yang c51b4488cd Blackfin arch: SMP supporting patchset: BF561 related code
Blackfin dual core BF561 processor can support SMP like features.
https://docs.blackfin.uclinux.org/doku.php?id=linux-kernel:smp-like

In this patch, we provide SMP extend to BF561 kernel code

Signed-off-by: Graf Yang <graf.yang@analog.com>
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2009-01-07 23:14:39 +08:00
Mike Frysinger 2de73e71c2 Blackfin arch: use physmap in board resources rather than legacy config method
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-11-18 17:48:22 +08:00
Michael Hennerich a4f0b32c33 Blackfin arch: Convert Blackfin GPIO driver to use common gpiolib/gpiochip infrastructure
- This patch adds support for ARCH_WANT_OPTIONAL_GPIOLIB.
 - It may be changed in future to ARCH_REQUIRE_GPIOLIB.
 - Change GPIO_BANK_NUM use DIV_ROUND_UP( , ) macro

Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-11-18 17:48:22 +08:00
Michael Hennerich 8d0223744f Blackfin arch: Cleanup and unify Blackfin IRQ and GPIO IRQ handling
- Remove SSYNC()
 - Use irq_to_gpio where applicable
 - Remove gpio_edge_triggered bitfield, check irq_desc fields instead.
 - Remove gpio_both_edge_triggeredb bitfield, check irq_desc fields
   instead.
 - Use BITMAP and bitops on gpio_enabled
 - Preferably use 32-bit
 - Looking at the disassembly this indeed saves quite a few instructions.

Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-11-18 17:48:22 +08:00
Yi Li 4989dbc17f Blackfin arch: workaround bug: spi_mmc driver working in dma mode may hang the system
Disable spi_mmc DMA by default.

Signed-off-by: Yi Li <yi.li@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-11-18 17:48:22 +08:00
Mike Frysinger c6db04a78a Blackfin arch: remove useless SSYNC() in irq priority code
- remove SSYNC() left over from irq init split
 - do not force SSYNC() when masking/unmasking IRQs in the SIC
   as any order enforced by the hardware should already be enforced
   by software

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-11-18 17:48:22 +08:00
Bryan Wu 397861cd80 Blackfin arch: fix bug - gpio_bank() macros messed up bank number caculating with positioning a gpio
The whole story:

Before BF51x merged, all the MAX_BLACKFIN_GPIOS are integral multiple of GPIO_BANKSIZE (= 16).
But BF51x provides MAX_BLACKFIN_GPIOS = 40 which includes 3 banks and the 3rd bank has only 8
GPIO pins.

Therefore, gpio_bank() macros is correct when you try to find a GPIO in which bank (GPIO_35 is
in bank 2). But on BF51x gpio_bank(MAX_BLACKFIN_GPIOS) only gives out 2 banks instead of 3
banks for some static array initialization.

This patch add a new macros gpio_bank_n() and GPIO_BANK_NUM to do bank number caculating and
remain the gpio_bank() macros for positioning a gpio in which bank.

Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-11-18 17:48:22 +08:00
Mike Frysinger 10a88a2be5 Blackfin arch: enable i2c_bfin_twi0_device in cm_bf548 board
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-11-18 17:48:22 +08:00
Michael Hennerich 3f37569044 Blackfin arch: Enable ISP1760 USB Host Driver in platform device initialization code.
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-11-18 17:48:22 +08:00
Mike Frysinger 5ff294fa00 Blackfin arch: fixup get_user() macros
- to avoid uninitialized errors
 - make invalid sizes a build error

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-11-18 17:48:22 +08:00
Mike Frysinger 9f20cf2527 Blackfin arch: do not bother initializing the first 4k
our kernel should be sane now, and we want to catch NULL bugs,
not ignore them

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-11-18 17:48:22 +08:00
Mike Frysinger c2414bd0b1 Blackfin arch: use sti to set the mask rather than banging on imask
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-11-18 17:48:22 +08:00
Michael Hennerich 88a8078b3b Blackfin arch: don't assume a specific SPI flash part - take whatever you probe
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-11-18 17:48:22 +08:00
Mike Frysinger 57a55077dd Blackfin arch: update defconfig file for all boards
- do not bother generating deprecated /sys files by default now since
   mdev does not need it
 - Don't built-in char sport driver and build it as a module in defconfig
 - disable CONFIG_DEVKMEM by default
 - enable spi flash driver on boards that have one
 - switch config to the NAND platfrom driver rather than the bfin async one
 - do not make BFIN_DMA_5XX optional since a large portion of our code relies
   on dma functions existing

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-11-18 17:48:22 +08:00
Michael Hennerich abeb21efb1 Blackfin arch: remove most BUG_ON channel checks
keep BUG_ON in DMA request, free and set_dma_callback.

Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-29 11:06:03 +08:00
Mike Frysinger 2cf851137b Blackfin arch: only add IFLUSH nop padding when anomaly 443 is enabled
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-28 16:34:42 +08:00
Michael Hennerich e04f9f427b Blackfin arch: Remove useless SSYNCs in DMA code
Tons of SSYNC operation will impact the DMA performance

Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-28 18:18:47 +08:00
Michael Hennerich a2ba8b1998 Blackfin arch: lookup channel2irq() only once
Add irq to struct dma_channel lookup channel2irq() only once,
since channel2irq() is fairly large on some Blackfin derivatives.

Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-28 18:19:29 +08:00
Mike Frysinger 3529e0414b Blackfin arch: update anomaly lists to match latest sheets
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-28 16:22:41 +08:00
Mike Frysinger 6a87d29bc6 Blackfin arch: refine the gpio check
refine the gpio check in peripheral_request() so that it only
checks pins that can be used as both GPIO and a peripheral

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-28 16:16:29 +08:00
Jie Zhang b2c2f30388 Blackfin arch: fix bug - shared lib function in L2 failed be called
Allow user space to access L2 SRAM.

Signed-off-by: Jie Zhang <jie.zhang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-28 15:57:49 +08:00
Mike Frysinger a2d03a1d8e Blackfin arch: unify port_setup() to reduce arch differences
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-28 15:53:37 +08:00
Mike Frysinger 6c7ec0ec93 Blackfin arch: unify peripheral_request() to reduce arch differences
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-28 15:49:59 +08:00
Mike Frysinger 1f7d373f47 Blackfin arch: fix cmp_label() so it doesnt incorrectly accept partial leading matches
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-28 15:47:11 +08:00
Mike Frysinger 27228b2e4c Blackfin arch: unify check_gpio() to reduce arch differences
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-28 15:45:42 +08:00
Mike Frysinger 72edff8dd4 Blackfin arch: fix incorrect limit check for bf54x check_gpio
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-28 15:42:13 +08:00
Mike Frysinger 588ba8199e Blackfin arch: remove unused local define
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-28 14:38:51 +08:00
Bryan Wu 2f6f4bcdd6 Blackfin arch: add support for Blackfin latest processor family BF51x
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-11-18 17:48:21 +08:00
Michael Hennerich a10101d5ff Blackfin arch: fix bug - Cpufreq assumes clocks in kHz and not Hz.
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-28 14:18:29 +08:00
Mike Frysinger 2563265bdb Blackfin arch: put quotes around error to silence a ton of warnings from gcc-4.3
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-28 14:11:45 +08:00
Graf Yang efe065a1b3 Blackfin arch: fix bug - kernel with SMP patch can not bootup
The original code defined _exception_stack but not alloc space for the exception
stack. In exception, this area is over written by exception stack. Common kernel
luckly boot up, but SMP kernel stuck.

Signed-off-by: Graf Yang <graf.yang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-28 14:00:52 +08:00
Mike Frysinger da986b9fff Blackfin arch: dont warn when running a kernel on the oldest supported silicon
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-28 13:58:15 +08:00
Mike Frysinger 7f6b2e7b1f Blackfin arch: fix bug - kernel build with write back policy fails to be booted up
Make sure IFLUSH is not the last instruction in the hardware loop to avoid
infinite core stall.

The dcache/icache function that only gets used in writeback mode was putting
IFLUSH as the last instruction in the hardware loop ... we know from design
that this may often lead to inifite core stalling, so switch the FLUSH/IFLUSH
order.

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-28 12:29:26 +08:00
Mike Frysinger 39e96c8835 Blackfin arch: fix bug - dmacopy test case fail on all platform
The cache code I added flushes 1 line too little if the start address is
not aligned to the cache size. Cache align the start address so that when
we straddle cache aligns, we get the right count.

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-11-18 17:48:22 +08:00
Robin Getz 4ee1c45337 Blackfin arch: Fix typo when adding CONFIG_DEBUG_VERBOSE
Signed-off-by: Robin Getz <rgetz@blackfin.uclinux.org>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-28 11:36:11 +08:00
Mike Frysinger d292b00031 Blackfin arch: drop redundant BFIN_DMA_5XX depends
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-28 11:15:36 +08:00
Mike Frysinger 0f8befa1d1 Blackfin arch: drop unused exports and comment remaining exports
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-28 11:12:17 +08:00
Mike Frysinger 6ad2b84cf0 Blackfin arch: add an option to allow people to stick exception stack into L1 scratch
allow people to stick exception stack into L1 scratch
and make sure it gets placed into .bss sections rather than .data

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-28 11:03:09 +08:00
Mike Frysinger fe8015ce25 Blackfin arch: move EXPORT_SYMBOL to the place where it is actually defined
- kernel_thread
 - irq_flags
 - checksum

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-28 11:07:15 +08:00
Michael Hennerich dc26aec25d Blackfin arch: BF538/9 Linux kernel Support
Add supporing for Blackfin BF538 and BF539 processors.

Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-11-18 17:48:22 +08:00
Mike Frysinger 3b1f26a50a Blackfin arch: don't copy bss when copying L1
when copying L1 regions, go to the start of bss rather
than end since we have code to zero it out already

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-27 18:21:43 +08:00
Mike Frysinger f940260a98 Blackfin arch: unify duplicated bss init code
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-27 18:17:41 +08:00
Graf Yang 6776cf4476 Blackfin arch: fix bug - Fail to boot jffs2 kernel for BF561 with SMP patch
only if the cplb block overlapped with kernel area, this cplb need be locked

Signed-off-by: Graf Yang <graf.yang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-27 18:12:53 +08:00
Tim Pepper 6a0bfff44e Blackfin arch: handle case of d_path() returning error in decode_address()
d_path() can return an error.  Most of its callers do something or other to
make up something sane in that case.  Do similar for blackfin's
decode_address() call to d_path().

Signed-off-by: Tim Pepper <lnxninja@linux.vnet.ibm.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-27 12:18:36 +08:00
Matt Helsley dc52ddc0e6 container freezer: implement freezer cgroup subsystem
This patch implements a new freezer subsystem in the control groups
framework.  It provides a way to stop and resume execution of all tasks in
a cgroup by writing in the cgroup filesystem.

The freezer subsystem in the container filesystem defines a file named
freezer.state.  Writing "FROZEN" to the state file will freeze all tasks
in the cgroup.  Subsequently writing "RUNNING" will unfreeze the tasks in
the cgroup.  Reading will return the current state.

* Examples of usage :

   # mkdir /containers/freezer
   # mount -t cgroup -ofreezer freezer  /containers
   # mkdir /containers/0
   # echo $some_pid > /containers/0/tasks

to get status of the freezer subsystem :

   # cat /containers/0/freezer.state
   RUNNING

to freeze all tasks in the container :

   # echo FROZEN > /containers/0/freezer.state
   # cat /containers/0/freezer.state
   FREEZING
   # cat /containers/0/freezer.state
   FROZEN

to unfreeze all tasks in the container :

   # echo RUNNING > /containers/0/freezer.state
   # cat /containers/0/freezer.state
   RUNNING

This is the basic mechanism which should do the right thing for user space
task in a simple scenario.

It's important to note that freezing can be incomplete.  In that case we
return EBUSY.  This means that some tasks in the cgroup are busy doing
something that prevents us from completely freezing the cgroup at this
time.  After EBUSY, the cgroup will remain partially frozen -- reflected
by freezer.state reporting "FREEZING" when read.  The state will remain
"FREEZING" until one of these things happens:

	1) Userspace cancels the freezing operation by writing "RUNNING" to
		the freezer.state file
	2) Userspace retries the freezing operation by writing "FROZEN" to
		the freezer.state file (writing "FREEZING" is not legal
		and returns EIO)
	3) The tasks that blocked the cgroup from entering the "FROZEN"
		state disappear from the cgroup's set of tasks.

[akpm@linux-foundation.org: coding-style fixes]
[akpm@linux-foundation.org: export thaw_process]
Signed-off-by: Cedric Le Goater <clg@fr.ibm.com>
Signed-off-by: Matt Helsley <matthltc@us.ibm.com>
Acked-by: Serge E. Hallyn <serue@us.ibm.com>
Tested-by: Matt Helsley <matthltc@us.ibm.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-10-20 08:52:34 -07:00
Linus Torvalds 1b821bfb03 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/cooloney/blackfin-2.6
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/cooloney/blackfin-2.6:
  Blackfin arch: make sure cycles is marked as volatile so gcc doesnt reorder on us
  Blackfin arch: disable CONFIG_HW_RANDOM and CONFIG_DAB in defconfig files
  Blackfin arch: update cache flush prototypes with argument names to make them less mysterious
  Blackfin arch: move bfin_addr_dcachable() and friends into the cacheflush header where it belongs
  Blackfin arch: use the new bfin_addr_dcachable() function
  Blackfin arch: fix bug - build kernel failed at head.S when reprogram clock on all platforms
  Blackfin arch: unify/cleanup cache code
  Blackfin arch: update AD7879 platform resources in board file
  Blackfin arch: Zero out bss region in L1/L2 memory.
  Blackfin arch: add read/write IO accessor functions to Blackfin
  Blackfin arch: fix bug - some serial header files set RTS to an input when they should all be outputs
2008-10-16 12:45:08 -07:00
Linus Torvalds e4856a70cf Merge branch 'personality' of git://git390.osdl.marist.edu/pub/scm/linux-2.6
* 'personality' of git://git390.osdl.marist.edu/pub/scm/linux-2.6:
  [PATCH] remove unused ibcs2/PER_SVR4 in SET_PERSONALITY
2008-10-16 12:32:52 -07:00
Mike Frysinger 1390da4ee7 Blackfin arch: make sure cycles is marked as volatile so gcc doesnt reorder on us
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-16 23:55:41 +08:00
Mike Frysinger ed061b7ac8 Blackfin arch: disable CONFIG_HW_RANDOM and CONFIG_DAB in defconfig files
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-16 23:54:43 +08:00
Mike Frysinger 8fb4f8f056 Blackfin arch: update cache flush prototypes with argument names to make them less mysterious
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-16 23:39:12 +08:00
Mike Frysinger 04be80ef0b Blackfin arch: move bfin_addr_dcachable() and friends into the cacheflush header where it belongs
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-16 23:33:53 +08:00
Mike Frysinger a92946bc6a Blackfin arch: use the new bfin_addr_dcachable() function
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-16 23:25:34 +08:00
Robin Getz 9bebeff98e Blackfin arch: fix bug - build kernel failed at head.S when reprogram clock on all platforms
Signed-off-by: Robin Getz <rgetz@blackfin.uclinux.org>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-16 23:05:28 +08:00
Mike Frysinger ded963a486 Blackfin arch: unify/cleanup cache code
- to be correct wrt to end ranges
 - to be optimal with a one-instruction hardware loop

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-16 23:01:24 +08:00
Michael Hennerich f51501551e Blackfin arch: update AD7879 platform resources in board file
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-16 23:23:18 +08:00
Graf Yang b4f5c58fd1 Blackfin arch: Zero out bss region in L1/L2 memory.
Signed-off-by: Graf Yang <graf.yang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-16 22:50:46 +08:00
Bryan Wu 121e598f5d Blackfin arch: add read/write IO accessor functions to Blackfin
This is to kill some compiling warning on DM9000 netdev driver.

Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-16 22:31:56 +08:00
Martin Schwidefsky 0b59268285 [PATCH] remove unused ibcs2/PER_SVR4 in SET_PERSONALITY
The SET_PERSONALITY macro is always called with a second argument of 0.
Remove the ibcs argument and the various tests to set the PER_SVR4
personality.

Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
2008-10-16 15:40:05 +02:00
Dominik Brodowski 459fc208ab cpufreq: remove policy->governor setting in drivers initialization
As policy->governor is already set to CPUFREQ_DEFAULT_GOVERNOR in the
(always built-in) cpufreq core, we do not need to set it in the drivers.
This fixes the sparc64 allmodconfig build failure.

Also, remove a totally useles setting of ->policy in cpufreq-pxa3xx.c.

Signed-off-by: Dominik Brodowski <linux@dominikbrodowski.net>
Acked-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-10-15 16:42:47 -07:00
Linus Torvalds 54cebc68c8 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/cooloney/blackfin-2.6
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/cooloney/blackfin-2.6: (60 commits)
  Blackfin arch: make sure we include the fix for SPORT hysteresis when reprogramming clocks
  Blackfin arch: Fix bogus str_ident check in gpio code
  Blackfin arch: AD7879 Touchscreen driver
  Blackfin arch: introducing bfin_addr_dcachable
  Blackfin arch: fix a typo in comments
  Blackfin arch: Remove useless head file
  Blackfin arch: make sure L2 start and length are always defined (fixes building on BF542)
  Blackfin arch: use the Blackfin on-chip ROM to do software reset when possible
  Blackfin arch: update anomaly headers to match the latest sheet
  Blackfin arch: bfin_reset() is an internal reboot function ... everyone should go through machine_restart()
  Blackfin arch: print out error/warning if you are running on the incorrect CPU type
  Blackfin arch: remove non-bf54x ifdef logic since this file is only compiled on bf54x parts
  Blackfin arch: update board defconfigs
  Blackfin arch: Add optional verbose debug
  Blackfin arch: emulate a TTY over the EMUDAT/JTAG interface
  Blackfin arch: have is_user_addr_valid() check for overflows (like when address is -1)
  Blackfin arch: ptrace - fix off-by-one check on end of memory regions
  Blackfin arch: Enable framebuffer support for the BF526-EZkit TFT LCD display
  Blackfin arch: flash memory map and dm9000 resources updating
  Blackfin arch: early prink code still use uart core console functions to parse and set configure option string
  ...
2008-10-13 10:08:43 -07:00
Linus Torvalds 244dc4e54b Merge git://git.infradead.org/users/dwmw2/random-2.6
* git://git.infradead.org/users/dwmw2/random-2.6:
  Fix autoloading of MacBook Pro backlight driver.
  Automatic MODULE_ALIAS() for DMI match tables.
  Remove asm/a.out.h files for all architectures without a.out support.
  Introduce HAVE_AOUT symbol to remove hard-coded arch list for BINFMT_AOUT
  Remove redundant CONFIG_ARCH_SUPPORTS_AOUT
  S390: Update comments about why we don't use <asm-generic/statfs.h>
  SPARC: Use <asm-generic/statfs.h>
  PowerPC: Use <asm-generic/statfs.h>
  PARISC: Use <asm-generic/statfs.h>
  x86_64: Use <asm-generic/statfs.h>
  IA64: Use <asm-generic/statfs.h>
  ARM: Use <asm-generic/statfs.h>
  Make <asm-generic/statfs.h> suitable for 64-bit platforms.
  Define and use PCI_DEVICE_ID_MARVELL_88ALP01_CCIC for CAFÉ camera driver
  [MTD] [NAND] Define and use PCI_DEVICE_ID_MARVELL_88ALP01_NAND for CAFÉ
  Use PCI_DEVICE_ID_88ALP01 for CAFÉ chip, rather than PCI_DEVICE_ID_CAFE.
  EFS: Don't set f_fsid in statfs().
2008-10-13 09:59:14 -07:00
Sonic Zhang ab2375f2fe Blackfin Serial Driver: Fix bug - request UART2/3 peripheral mapped interrupts in PIO mode
Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-10-13 09:51:38 -07:00
Graf Yang b3ef5aba64 Blackfin Serial Driver: Fix bug - ircp fails on sir over Blackfin UART
We now use the sir_dev/irtty_sir/uart/bfin_serial drivers framework
to monitor the TX status.

Signed-off-by: Graf Yang <graf.yang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-10-13 09:51:38 -07:00
Mike Frysinger c9607ecc6e Blackfin Serial Driver: move common variables out of serial headers and into the serial driver
move common variables out of serial headers and into the serial driver and
rename "nr_ports" to "nr_active_ports" so as to easily differentiate
between BFIN_UART_NR_PORTS (the # of available) and nr_ports (the # of enabled)

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-10-13 09:51:38 -07:00
Sonic Zhang deffc6edac Blackfin arch: fix bug - some serial header files set RTS to an input when they should all be outputs
Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-13 17:42:12 +08:00
Robin Getz 71de1f8a63 Blackfin arch: make sure we include the fix for SPORT hysteresis when reprogramming clocks
As pointed out by Appalayagari Sreedhar, make sure we include the fix
for SPORT hysteresis when reprogramming clocks.

Signed-off-by: Robin Getz <rgetz@blackfin.uclinux.org>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-13 11:37:34 +08:00
Michael Hennerich e9fae189ca Blackfin arch: Fix bogus str_ident check in gpio code
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-13 11:35:22 +08:00
Michael Hennerich 46aa04f9b6 Blackfin arch: AD7879 Touchscreen driver
Add AD7879 Touchscreen driver to the device structures

Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-13 11:30:17 +08:00
Vitja Makarov 58c35bd31f Blackfin arch: introducing bfin_addr_dcachable
This patch introduces bfin_addr_dcachable() predicate, that simply tests is
address in cachable region or not.

Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-13 15:23:56 +08:00
Bryan Wu 3094c981f2 Blackfin arch: fix a typo in comments
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-10 21:22:01 +08:00
Graf Yang fecc8d6d56 Blackfin arch: Remove useless head file
Signed-off-by: Graf Yang <graf.yang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-10 21:23:29 +08:00
Mike Frysinger ad5dd97743 Blackfin arch: make sure L2 start and length are always defined (fixes building on BF542)
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-10 21:17:11 +08:00
Mike Frysinger cdbf4c3c5f Blackfin arch: use the Blackfin on-chip ROM to do software reset when possible
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-13 11:33:43 +08:00
Mike Frysinger 4e8086d65b Blackfin arch: update anomaly headers to match the latest sheet
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-10 21:07:55 +08:00
Mike Frysinger 9a6f5ae1f1 Blackfin arch: bfin_reset() is an internal reboot function ... everyone should go through machine_restart()
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-10 18:57:21 +08:00
Robin Getz e482cad241 Blackfin arch: print out error/warning if you are running on the incorrect CPU type
Signed-off-by: Robin Getz <rgetz@blackfin.uclinux.org>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-10 18:21:45 +08:00
Mike Frysinger 6d0b8c993d Blackfin arch: remove non-bf54x ifdef logic since this file is only compiled on bf54x parts
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-10 18:05:02 +08:00
Mike Frysinger f5623a3cf2 Blackfin arch: update board defconfigs
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-10 17:51:15 +08:00
Robin Getz 9f06c38fb2 Blackfin arch: Add optional verbose debug
Add optional verbose debug - which when turned off, quiets down
userspace errors. Saves ~8k of code/data for production systems

Signed-off-by: Robin Getz <rgetz@blackfin.uclinux.org>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-10 18:13:21 +08:00
Mike Frysinger a88c71e436 Blackfin arch: emulate a TTY over the EMUDAT/JTAG interface
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-10 17:37:52 +08:00
Mike Frysinger 3c08f1d122 Blackfin arch: have is_user_addr_valid() check for overflows (like when address is -1)
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-10 17:12:51 +08:00
Mike Frysinger d207a8c768 Blackfin arch: ptrace - fix off-by-one check on end of memory regions
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-10 17:26:57 +08:00
Michael Hennerich 2043f3f731 Blackfin arch: Enable framebuffer support for the BF526-EZkit TFT LCD display
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-13 14:46:30 +08:00
Javier Herrero 45138439e1 Blackfin arch: flash memory map and dm9000 resources updating
Signed-off-by: Javier Herrero <jherrero@hvsistemas.es>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-09 18:06:47 +08:00
Sonic Zhang 0cfbb3234c Blackfin arch: early prink code still use uart core console functions to parse and set configure option string
Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-09 17:39:37 +08:00
Mike Frysinger 0c0497c257 Blackfin arch: Move all the silicon rev handling to one place
Move all the silicon rev handling to one place (Kconfig) and
make sure we warn if you are running on silicon that has not been tested on

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-09 17:32:28 +08:00
Mike Frysinger 664d0403f9 Blackfin arch: fix end address for parallel flash and increase kernel partition size to 4meg
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-09 17:28:36 +08:00
Mike Frysinger 6c3fc69a17 Blackfin arch: avoid using actual config name in comment
avoid using actual config name in comment as a text search
is done to see what files need to be rebuilt

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-09 17:13:39 +08:00
Robin Getz 1d5ff7e27d Blackfin arch: Fix bug - HW Errors never recover on BF548
The kernel does not properly clear the EBIU Error Master (EBIU_ERRMST) Register
on BF548, which causes the kernel to panic.

We need to make sure that we clear the EBIU_ERRMST (necessary on BF54x)

Signed-off-by: Robin Getz <rgetz@blackfin.uclinux.org>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-09 17:06:32 +08:00
Graf Yang 55f2feae3a Blackfin arch: correct icache size in show_cpuinfo(), let c_start() return proper pointer
Signed-off-by: Graf Yang <graf.yang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-09 15:37:47 +08:00
Mike Frysinger 47664c1f86 Blackfin arch: give sys_strace proper entry markings
a global _sys_trace will cause the assembler to fail, it should be fixed in toolchain side firstly.

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-09 15:32:18 +08:00
Mike Frysinger f5a817e3f7 Blackfin arch: ptrace - make sure PT_ORIG_R0 and PT_ORIG_P0 offsets are declared
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-09 15:22:56 +08:00
Mike Frysinger cb4c173d94 Blackfin arch: use existing ptrace_disable() func to clear TRACE_BITS and create the opposite ptrace_enable()
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-09 15:21:05 +08:00
Mike Frysinger d3ab3a62f5 Blackfin arch: ptrace - cleanup debug messages and style
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-09 15:19:50 +08:00
Mike Frysinger dabaad5b90 Blackfin arch: fix bug -- PTRACE_PEEKDATA does not seem to work which breaks umoven() in strace
Don't add arbitrary offset when peeking at data

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-09 15:17:36 +08:00
Graf Yang dd4354fa51 Blackfin arch: fix define error in BF561 memory map macros
Signed-off-by: Graf Yang <graf.yang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-09 14:17:47 +08:00
Sonic Zhang f099f39acf Blackfin arch: Make L2 SRAM cacheable
Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-09 14:11:57 +08:00
Sonic Zhang 8606801b03 Blackfin arch: flags of UART3 mem resource is missing
Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-09 13:55:33 +08:00
Sonic Zhang 27707d3e43 Blackfin arch: Fix bug - kernel build with config kernel debugging with remote gdb fails
Add some comment and fix duplicated VEC_EXCPT02

Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-09 14:04:41 +08:00
Michael Hennerich 5e9e7687cb Blackfin arch: Fix BUG -- BF533 + 0.5 silicon + MPU + UART PIO -> crash
Apply ANOMALY_05000283 & ANOMALY_05000315
Workaround also to the EXCEPTION path.

Cover evt_ivhw also with ANOMALY_05000315
The Workaround needs to be prior to accesses (either read or write) to
any system MMR.

Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-09 12:31:03 +08:00
Mike Frysinger 49f7253cc9 Blackfin arch: add support for BF52x-0.2, BF533-0.6, and BF54x-0.2
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-09 12:06:27 +08:00
Mike Frysinger 46ce0d9a36 Blackfin arch: fix default silicon rev selection so it works for all supported parts
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-09 12:05:31 +08:00
Mike Frysinger cd88b4dca8 Blackfin arch: BF561 is supported, no longer a work in progress
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-09 12:03:22 +08:00
Robin Getz 202d7bd95c Blackfin arch: Make sure we program the correct values in only when necessary for MUSB driver
Signed-off-by: Robin Getz <rgetz@blackfin.uclinux.org>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-09 11:59:46 +08:00
Michael Hennerich 3343c1d448 Blackfin arch: Fix BUG: anomaly_threshold is used with ANOMALY_05000363
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-09 11:11:11 +08:00
Graf Yang bfd15117ae Blackfin arch: Not call generic set_irq_handler() in bfin_gpio_irq_type() due to spinlock recursion
Signed-off-by: Graf Yang <graf.yang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-08 18:02:44 +08:00
Robin Getz 9df10281e1 Blackfin arch: Use DTEST rather than DMA to poke at L1 SRAM during exception context
Signed-off-by: Robin Getz <rgetz@blackfin.uclinux.org>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-08 18:03:33 +08:00
Mike Frysinger 7eb2c23f60 Blackfin arch: fix merge errors during 2.6.26 upgrade
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-08 17:39:02 +08:00
Graf Yang 5b04f271fe Blackfin arch: Modify some funtion names to more genernal ones
Signed-off-by: Graf Yang <graf.yang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-08 17:32:57 +08:00
Robin Getz 5e95320f9f Blackfin arch: rename blackfin_sram.c to sram-alloc.c
rename blackfin_sram.c to sram-alloc.c (we know it is a blackfin file,
since it is in arch/blackfin) - and there is no "driver" code in there,
it is just an allocator/deallocator for L1 and L2 sram.

Also fix a problem that checkpatch pointed out

Signed-off-by: Robin Getz <rgetz@blackfin.uclinux.org>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-08 17:22:49 +08:00
Graf Yang 763e63c640 Blackfin arch: add a meaningful name for each irqchip
Signed-off-by: Graf Yang <graf.yang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-08 17:08:15 +08:00
Graf Yang ca87b7ad00 Blackfin arch: add CONFIG_APP_STACKS_L1 to enable or disable putting kernel stacks in L1
use CONFIG_APP_STACKS_L1 to enable or disable putting kernel stacks in L1,
default is enabled, SMP kernel need turn it off

Signed-off-by: Graf Yang <graf.yang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-08 17:30:01 +08:00
Robin Getz 7d98c881ee Blackfin arch: Make sure we protect except 2 properly, and print out memory properly
Signed-off-by: Robin Getz <rgetz@blackfin.uclinux.org>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-08 16:29:01 +08:00
Mike Frysinger 74c04503d7 Blackfin arch: mark local gpio_error() as static
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-08 16:13:17 +08:00
Mike Frysinger fffe53bee7 Blackfin arch: fix bug - sometimes there is no response to the hitting key in uboot for bf561-ezkit when running with 50mhz SCLK
use 10 delays rather than 7

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-08 14:46:09 +08:00
Robin Getz 5c64e0d510 Blackfin arch: Better error handling of unknown exceptions
Better error handling of unknown exceptions, allows userspace to do a
EXCPT n instruction for a not installed exception handler, and the
kernel doesn't crash (like it use to before this).

Signed-off-by: Robin Getz <rgetz@blackfin.uclinux.org>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-08 14:43:47 +08:00
Michael Hennerich aca5e4aac8 Blackfin arch: add BF54x / BF52x Rotary Input device driver platform resource to board file
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-08 14:27:59 +08:00
Sonic Zhang a5ac012924 Blackfin arch: add supporting for kgdb
Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-13 14:07:19 +08:00
Bernd Schmidt 5d2e321306 Blackfin arch: fixing bug - under IRQ stress, running applications may wrongly trigger an ICPLB miss and be killed
Disable IRQs while frobbing the CPLB registers, to avoid accessing the
data in current_rwx_mask while it isn't covered by CPLBs.

Signed-off-by: Bernd Schmidt <bernds_cb1@t-online.de>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-07 16:27:01 +08:00
Robin Getz 0c7a6b2135 Blackfin arch: add supporting for double fault debug handling
Signed-off-by: Robin Getz <rgetz@blackfin.uclinux.org>
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-08 16:27:12 +08:00
Mike Frysinger f4585a0847 Blackfin arch: only include asm/cplb.h when it is truly used
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-13 14:45:21 +08:00
Mike Frysinger 1ffb9bef23 Blackfin arch: add note about newer ezkits using PB4 for AD7877 instead of PJ11
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-07 16:06:27 +08:00
Michael Hennerich 8cc7117e7c Blackfin arch: Add new board support for ADZS-BF526-EZ-BRD
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-13 14:45:06 +08:00
Bryan Wu 31f3d4a317 Blackfin arch: add dma mapping stub for musb driver port
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-09-22 20:23:55 +08:00
Bryan Wu 50041acbe4 Blackfin arch: use new platform data interface of musb to replace old one
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-10-08 13:39:40 +08:00
Adrian Bunk 9d5a9e7465 Remove asm/a.out.h files for all architectures without a.out support.
This patch also includes the required removal of (unused) inclusion of
<asm/a.out.h> <linux/a.out.h>'s in the arch/ code for these
architectures.

[dwmw2: updated for 2.6.27-rc]
Signed-off-by: Adrian Bunk <bunk@kernel.org>
Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
2008-09-06 19:30:24 +01:00
Michael Hennerich d310fb4bb7 Blackfin arch: Fix PM building on BF52x: No ROTWE on BF52x, add USBWE
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-08-28 17:32:01 +08:00
Vegard Nossum 226a6ec311 Blackfin arch: sram: use 'unsigned long' for irqflags
Using just 'unsigned' will make flags an unsigned int. While this is
arguably not an error on blackfin where sizeof(int) == sizeof(long),
the patch is still justified on the grounds of principle.

The patch was generated using the Coccinelle semantic patch framework.

Cc: Julia Lawall <julia@diku.dk>
Cc: Alexey Dobriyan <adobriyan@gmail.com>
Signed-off-by: Vegard Nossum <vegard.nossum@gmail.com>
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-08-28 17:28:46 +08:00
Adrian Bunk a95ca3b2b9 Blackfin arch: let PCI depend on BROKEN
AFAIR there exists blackfin hardware with PCI support, but the support
currently in the kernel fails to build starting with:

...
  CC      drivers/pci/probe.o
probe.c: In function 'pci_scan_slot':
probe.c:1056: error: implicit declaration of function 'pcibios_scan_all_fns'
make[3]: *** [drivers/pci/probe.o] Error 1

Signed-off-by: Adrian Bunk <bunk@kernel.org>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-08-27 10:55:05 +08:00
Bryan Wu 639f657145 Blackfin arch: move include/asm-blackfin header files to arch/blackfin
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-08-27 10:51:02 +08:00
Sonic Zhang 225f7e1eb5 Blackfin arch: Fix bug - when to rmmod the L1_module, it stucks and then reboot the board.
Fix this by correcting the wrong pointer

Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-08-25 18:00:45 +08:00
Mike Frysinger d70536ec3a Blackfin arch: dont actually need to muck with EMAC_SYSTAT for BF52x for demuxing
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-08-25 17:37:35 +08:00
Michael Hennerich ceac2651e9 Blackfin arch: Add MTD Partitions for MTD_DATAFLASH, increase max SPI SCLK
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-08-25 17:39:11 +08:00
Bryan Wu a4b7b6d7d3 Blackfin arch: hook up some missing new system calls
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-08-14 15:40:19 +08:00
Mike Frysinger 7e1e7aed0c Blackfin arch: do not muck with the UART during boot -- let the serial driver worry about it
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-08-14 15:15:43 +08:00
Mike Frysinger 95a86b5e51 Blackfin arch: clear EMAC_SYSTAT during IRQ init rather than early head.S as we dont need it setup that early
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-08-14 15:05:01 +08:00
Mike Frysinger c991dd92ab Blackfin arch: use %pF when printing out the double fault address so we get symbol names
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-08-14 14:57:26 +08:00
Benjamin Matthews 130de7cebe Blackfin arch: add support for the BlackStamp board
Signed-off-by: Benjamin Matthews <bmat@lle.rochester.edu>
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-08-14 14:55:54 +08:00
Robin Getz 251383c7c5 Blackfin arch: Allow ins functions to have a low latency version
Signed-off-by: Robin Getz <rgetz@blackfin.uclinux.org>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-08-14 15:12:55 +08:00
Robin Getz cd8fb8df14 Blackfin arch: Print out doublefault addresses, so debug can occur
Signed-off-by: Robin Getz <rgetz@blackfin.uclinux.org>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-08-14 14:44:33 +08:00
Mike Frysinger 9216bbc838 Blackfin arch: mark some functions as __init as they are only called from __init functions
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-08-14 14:35:20 +08:00
Mike Frysinger 0e06b50dda Blackfin arch: cleanup cache lock code
- remove cheesy read_iloc() function
 - move invalidate_entire_icache function to lock.S
 - export proper prototypes for functions in lock.S
 - only build lock.S when BFIN_ICACHE_LOCK is enabled

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-08-14 14:29:57 +08:00
Michael Hennerich 55546ac45d Blackfin arch: workaround SIC_IWR1 reset bug, by keeping MDMA0/1 always enabled in SIC_IWR1.
This way we ensure that reboot succeeds.

Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-08-13 17:41:13 +08:00
Robin Getz d3d0ac23a3 Blackfin arch: Fix bug - when expanding the trace buffer, it does not print out the decoded instruction.
as pointed out by Michael McTernan in the forums, when expanding
the trace buffer, it does not print out the decoded instruction.

Signed-off-by: Robin Getz <rgetz@blackfin.uclinux.org>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-08-06 17:49:27 +08:00
Michael Hennerich 56f5f59052 Blackfin arch: Fix Bug - System with EMAC driver enabled - Core not idling
- Disable all bits in SIC_IWR unless we are going into a real (DPMC)
   power saving mode. Any Interrupt can wake the core form it's idle state.

 - Remove deep sleep mode as it is not going to be used anywhere:
   We support sleep, sleep deeper and hibernate.

Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-08-06 17:55:32 +08:00
Mike Frysinger 15b0753689 Blackfin arch: delete unused cache functions
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-08-13 16:19:36 +08:00
Mike Frysinger 07aa7be570 Blackfin arch: convert L2 defines to be the same as the L1 defines
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-08-13 16:16:11 +08:00
Mike Frysinger 17e89bcfa1 Blackfin arch: unify the duplicated portions of __start and split mach-specific pieces into _mach_early_start where they will be easier to trim over time
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-08-06 17:23:50 +08:00
Mike Frysinger 67618fd874 Blackfin arch: add asm/thread_info.h for THREAD_SIZE define
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-08-06 17:18:31 +08:00
Mike Frysinger 7e64acabfd Blackfin arch: move async memory programming into common setup_arch() as the banks dont really need to be setup fully as early as head.S
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-08-06 17:17:10 +08:00
Mike Frysinger 1375204611 Blackfin arch: make sure the BSS and kernel load address are 4 byte aligned
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-08-06 17:10:57 +08:00
Mike Frysinger 09e1f70e31 Blackfin arch: unify the duplicated _real_start functions
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-08-06 17:15:27 +08:00
Mike Frysinger 778307d372 Blackfin arch: remove support for Anomaly 05000125 as it doesnt exist on any supported processor/silicon
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-08-06 17:05:20 +08:00
Sonic Zhang d6a2989136 Blackfin arch: Fix bugs - Make kgdb code apparent to app debugging.
- Skip single step if global interrupt disable bit is set.
 - Extend bernds' patch r4673 to skip single step in any interrupt entry
   that interrupts the code which is under single stepping. Bernds' patch
   only allow user space single stepping.

Singed-off-by: Sonic Zhang <sonic.zhang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-08-05 18:28:26 +08:00
Mike Frysinger fe5aeb9302 Blackfin arch: use symbolic IRQ_PF define rather than hardcoded
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-08-05 18:29:56 +08:00
Mike Frysinger 908089118d Blackfin arch: remove pata resources from generic board
these are highly board specific, so putting into generic doesnt make much sense

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-08-05 18:41:20 +08:00
Mike Frysinger b9da3b9240 Blackfin arch: add support for board tcm-bf537
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-08-13 15:49:35 +08:00
Mike Frysinger 8ea8949733 Blackfin arch: add board resources for parallel flash on cm-bf537
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-08-05 18:14:44 +08:00
Robin Getz aa58297763 Blackfin arch: be consistant with parition names, and ensure the bus is identified
Signed-off-by: Robin Getz <rgetz@blackfin.uclinux.org>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-08-05 17:47:29 +08:00
Michael Hennerich 4a88d0ce49 Blackfin arch: Functional power management support
Merge VR Regulator Hibernate wakeups into set_irq_wake for internal
interrupts.

Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-08-05 17:38:41 +08:00
Jie Zhang 5400c5aa2d Blackfin arch: Fix bug - This change eliminates impact on application debugging
Signed-off-by: Jie Zhang <jie.zhang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-08-05 17:33:38 +08:00
Linus Torvalds 7f268a2ba7 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/cooloney/blackfin-2.6
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/cooloney/blackfin-2.6: (30 commits)
  Blackfin arch: If we double fault, rather than hang forever, reset
  Blackfin arch: When icache is off, make sure people know it
  Blackfin arch: Fix bug - skip single step in high priority interrupt handler instead of disabling all interrupts in single step debugging.
  Blackfin arch: cache the values of vco/sclk/cclk as the overhead of doing so (~24 bytes) is worth avoiding the software mult/div routines
  Blackfin arch: fix bug - IMDMA is not type struct dma_register
  Blackfin arch: check the EXTBANKS field of the DDRCTL1 register to see if we are using both memory banks
  Blackfin arch: Apply Bluetechnix CM-BF527 board support patch
  Blackfin arch: Add unwinding for stack info, and a little more detail on trace buffer
  Blackfin arch: Add ISP1760 board resources to BF548-EZKIT
  Blackfin arch: fix bug - detect 0.1 silicon revision BF527-EZKIT as 0.0 version
  Blackfin arch: add missing IORESOURCE_MEM flags to UART3
  Blackfin arch: Add return value check in bfin_sir_probe(), remove SSYNC().
  Blackfin arch:  Extend sram malloc to handle L2 SRAM.
  Blackfin arch: Remove useless config option.
  Blackfin arch:  change L1 malloc to base on slab cache and lists.
  Blackfin arch: use local labels and ENDPROC() markings
  Blackfin arch: Do not need this dualcore test module in kernel.
  Blackfin arch: Allow ptrace to peek and poke application data in L1 data SRAM.
  Blackfin arch: Add ANOMALY_05000368 workaround
  Blackfin arch: Functional power management support
  ...
2008-07-26 13:23:17 -07:00
Johannes Weiner a2e9c44337 blackfin: use generic show_mem()
Remove arch-specific show_mem() in favor of the generic version.

This also removes the following redundant information display:

	- free pages, printed by show_free_areas()
	- pages in swapcache, printed by show_swap_cache_info()

where show_mem() calls show_free_areas(), which calls
show_swap_cache_info().

Signed-off-by: Johannes Weiner <hannes@saeurebad.de>
Acked-by: Bryan Wu <cooloney@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-26 12:00:10 -07:00
Robin Getz 2d2009806d Blackfin arch: If we double fault, rather than hang forever, reset
Signed-off-by: Robin Getz <rgetz@blackfin.uclinux.org>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-07-26 19:41:40 +08:00
Robin Getz 9de3a0b697 Blackfin arch: When icache is off, make sure people know it
Signed-off-by: Robin Getz <rgetz@blackfin.uclinux.org>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-07-26 19:39:19 +08:00
Sonic Zhang 0d1cdd7ab6 Blackfin arch: Fix bug - skip single step in high priority interrupt handler 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>
2008-07-26 18:54:38 +08:00
Mike Frysinger 3a2521fa75 Blackfin arch: cache the values of vco/sclk/cclk as the overhead of doing so (~24 bytes) is worth avoiding the software mult/div routines
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-07-26 18:52:56 +08:00
Michael Hennerich 377d43e7d0 Blackfin arch: fix bug - IMDMA is not type struct dma_register
TEMP Workaround - avoid access to PERIPHERAL_MAP

Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-07-26 18:28:03 +08:00
Mike Frysinger b1b154e503 Blackfin arch: check the EXTBANKS field of the DDRCTL1 register to see if we are using both memory banks
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-07-26 18:02:05 +08:00
Linus Torvalds ecc8b655b3 Merge branch 'timers-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip
* 'timers-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
  nohz: adjust tick_nohz_stop_sched_tick() call of s390 as well
  nohz: prevent tick stop outside of the idle loop
2008-07-24 12:55:01 -07:00
Johannes Berg a81792f668 remove mention of CONFIG_KMOD from documentation
Also includes a few Kconfig files (xtensa, blackfin)

Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
Cc: Michael Kerrisk <mtk.manpages@gmail.com>
Cc: linux-doc@vger.kernel.org
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Acked-by: Randy Dunlap <rdunlap@xenotime.net>
2008-07-22 19:24:29 +10:00
Michael Hennerich 9db144fe89 Blackfin arch: Apply Bluetechnix CM-BF527 board support patch
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-07-19 17:16:07 +08:00
Robin Getz f09630bff5 Blackfin arch: Add unwinding for stack info, and a little more detail on trace buffer
Signed-off-by: Robin Getz <rgetz@blackfin.uclinux.org>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-07-26 19:45:46 +08:00
Michael Hennerich 0a6304a951 Blackfin arch: Add ISP1760 board resources to BF548-EZKIT
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-07-26 16:14:57 +08:00
Mike Frysinger cc2e16bd35 Blackfin arch: add missing IORESOURCE_MEM flags to UART3
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-07-19 16:43:51 +08:00
Sonic Zhang 262c3825a9 Blackfin arch: Extend sram malloc to handle L2 SRAM.
Extend system call to alloc L2 SRAM in application.
Automatically move following sections to L2 SRAM:
1. kernel built-in l2 attribute section
2. kernel module l2 attribute section
3. elf-fdpic application l2 attribute section

Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-07-19 15:42:41 +08:00
Robin Getz bafcc1b973 Blackfin arch: Remove useless config option.
Signed-off-by: Robin Getz <rgetz@blackfin.uclinux.org>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-07-19 15:11:15 +08:00
Sonic Zhang 5d481f4975 Blackfin arch: change L1 malloc to base on slab cache and lists.
Remove the sram piece limitation and improve the performance to
alloc/free sram piece data.

Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-07-19 14:51:31 +08:00
Ingo Molnar 9b610fda0d Merge branch 'linus' into timers/nohz 2008-07-18 19:53:16 +02:00
Thomas Gleixner b8f8c3cf0a nohz: prevent tick stop outside of the idle loop
Jack Ren and Eric Miao tracked down the following long standing
problem in the NOHZ code:

	scheduler switch to idle task
	enable interrupts

Window starts here

	----> interrupt happens (does not set NEED_RESCHED)
	      	irq_exit() stops the tick

	----> interrupt happens (does set NEED_RESCHED)

	return from schedule()
	
	cpu_idle(): preempt_disable();

Window ends here

The interrupts can happen at any point inside the race window. The
first interrupt stops the tick, the second one causes the scheduler to
rerun and switch away from idle again and we end up with the tick
disabled.

The fact that it needs two interrupts where the first one does not set
NEED_RESCHED and the second one does made the bug obscure and extremly
hard to reproduce and analyse. Kudos to Jack and Eric.

Solution: Limit the NOHZ functionality to the idle loop to make sure
that we can not run into such a situation ever again.

cpu_idle()
{
	preempt_disable();

	while(1) {
		 tick_nohz_stop_sched_tick(1); <- tell NOHZ code that we
		 			          are in the idle loop

		 while (!need_resched())
		       halt();

		 tick_nohz_restart_sched_tick(); <- disables NOHZ mode
		 preempt_enable_no_resched();
		 schedule();
		 preempt_disable();
	}
}

In hindsight we should have done this forever, but ... 

/me grabs a large brown paperbag.

Debugged-by: Jack Ren <jack.ren@marvell.com>, 
Debugged-by: eric miao <eric.y.miao@gmail.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
2008-07-18 18:10:28 +02:00
David S. Miller 49997d7515 Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/torvalds/linux-2.6
Conflicts:

	Documentation/powerpc/booting-without-of.txt
	drivers/atm/Makefile
	drivers/net/fs_enet/fs_enet-main.c
	drivers/pci/pci-acpi.c
	net/8021q/vlan.c
	net/iucv/iucv.c
2008-07-18 02:39:39 -07:00
Mike Frysinger 1a8caeebe3 Blackfin arch: use local labels and ENDPROC() markings
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-07-16 17:07:26 +08:00
Yi Li 7dee62ac5a Blackfin arch: Do not need this dualcore test module in kernel.
Signed-off-by: Yi Li <yi.li@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-07-19 20:53:46 +08:00
Jie Zhang 6546eae4fd Blackfin arch: Allow ptrace to peek and poke application data in L1 data SRAM.
Signed-off-by: Jie Zhang <jie.zhang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-07-15 16:15:40 +08:00
Michael Hennerich 2cfebf2bce Blackfin arch: Add ANOMALY_05000368 workaround
Possible RETS Register Corruption when Subroutine Is under 5 Cycles in Duration

Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-07-16 16:59:05 +08:00
Michael Hennerich 1efc80b53e Blackfin arch: Functional power management support
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>
2008-07-19 16:57:32 +08:00
Michael Hennerich 4f13f548ce Blackfin arch: Fix BUG - JUMP error in kernel (relocation truncated to fit: R_pcrel12_jump_s)
Use long jump

Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-07-15 16:38:28 +08:00
Jonathan Corbet 2fceef397f Merge commit 'v2.6.26' into bkl-removal 2008-07-14 15:29:34 -06:00
Mike Frysinger c71b478351 Blackfin arch: set CROSS_COMPILE in our arch Makefile so it gets used by default
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-07-14 17:10:50 +08:00
Sonic Zhang ed987319ed Blackfin arch: update board defconfigs
Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-07-26 18:40:06 +08:00
Michael Hennerich 99d95bbd48 Blackfin arch: Remove redundant kernel option
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>
2008-07-14 17:04:14 +08:00
Mike Frysinger 96b86e94bc Blackfin arch: use the symbolic IRQ define rather than the backend number
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-07-14 16:39:43 +08:00
Michael Hennerich 68e2fc78e5 Blackfin arch: Fix bug - Kernel does not boot if re-program clocks
Don't write conflicting data to EBIU_SDBCTL after the SDRAM is
configured. This can cause data corruption, since we might change SDRAM
row and column addressing modes.

Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-07-14 16:51:57 +08:00
Mike Frysinger 260d5d3517 Blackfin arch: Fix bug - do not overflow the buffer given to us which tends to happen when CONFIG_L1_MAX_PIECE is increased past its default
Singed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-07-14 16:34:05 +08:00
Michael Hennerich 1f2d18690f Blackfin arch: Fix Bug - GPIO interrupts not disabled; edge sensitive 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>
2008-07-14 16:31:22 +08:00
David S. Miller ea2aca084b Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
Conflicts:

	Documentation/feature-removal-schedule.txt
	drivers/net/wan/hdlc_fr.c
	drivers/net/wireless/iwlwifi/iwl-4965.c
	drivers/net/wireless/iwlwifi/iwl3945-base.c
2008-07-05 23:08:07 -07:00
Jonathan Corbet 57debddaa1 bf561-coreb: BKL unneeded for open()
According to Mike Frysinger:

	http://permalink.gmane.org/gmane.linux.kernel/699279

open() does not need the BKL, so take it back out.
2008-07-02 15:06:28 -06:00
Bryan Wu 8d0a60032f Blackfin arch: fix up section mismatch warning
--
WARNING: vmlinux.o(.text+0x721a): Section mismatch in reference from the function ___fill_code_cplbtab() to the function .init.text:_fill_cplbtab()
The function ___fill_code_cplbtab() references
the function __init _fill_cplbtab().
This is often because ___fill_code_cplbtab lacks a __init
annotation or the annotation of _fill_cplbtab is wrong.

WARNING: vmlinux.o(.text+0x7238): Section mismatch in reference from the function ___fill_code_cplbtab() to the function .init.text:_fill_cplbtab()
The function ___fill_code_cplbtab() references
the function __init _fill_cplbtab().
This is often because ___fill_code_cplbtab lacks a __init
annotation or the annotation of _fill_cplbtab is wrong.

WARNING: vmlinux.o(.text+0x7250): Section mismatch in reference from the function ___fill_code_cplbtab() to the function .init.text:_fill_cplbtab()
The function ___fill_code_cplbtab() references
the function __init _fill_cplbtab().
This is often because ___fill_code_cplbtab lacks a __init
annotation or the annotation of _fill_cplbtab is wrong.

WARNING: vmlinux.o(.text+0x7264): Section mismatch in reference from the function ___fill_code_cplbtab() to the function .init.text:_fill_cplbtab()
The function ___fill_code_cplbtab() references
the function __init _fill_cplbtab().
This is often because ___fill_code_cplbtab lacks a __init
annotation or the annotation of _fill_cplbtab is wrong.

WARNING: vmlinux.o(.text+0x72a2): Section mismatch in reference from the function ___fill_data_cplbtab() to the function .init.text:_fill_cplbtab()
The function ___fill_data_cplbtab() references
the function __init _fill_cplbtab().
This is often because ___fill_data_cplbtab lacks a __init
annotation or the annotation of _fill_cplbtab is wrong.

WARNING: vmlinux.o(.text+0x72bc): Section mismatch in reference from the function ___fill_data_cplbtab() to the function .init.text:_fill_cplbtab()
The function ___fill_data_cplbtab() references
the function __init _fill_cplbtab().
This is often because ___fill_data_cplbtab lacks a __init
annotation or the annotation of _fill_cplbtab is wrong.

WARNING: vmlinux.o(.text+0x72d4): Section mismatch in reference from the function ___fill_data_cplbtab() to the function .init.text:_fill_cplbtab()
The function ___fill_data_cplbtab() references
the function __init _fill_cplbtab().
This is often because ___fill_data_cplbtab lacks a __init
annotation or the annotation of _fill_cplbtab is wrong.

WARNING: vmlinux.o(.text+0x72e8): Section mismatch in reference from the function ___fill_data_cplbtab() to the function .init.text:_fill_cplbtab()
The function ___fill_data_cplbtab() references
the function __init _fill_cplbtab().
This is often because ___fill_data_cplbtab lacks a __init
annotation or the annotation of _fill_cplbtab is wrong.
--

Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-06-25 12:41:51 +08:00
Sonic Zhang 71a7d15562 Blackfin arch: fix bug - kernel boot fails when Spinlock and rw-lock debugging enabled
Initialize the lock of bad_irq_desc properly.
The content of irq_desc array is replaced by bad_irq_desc in blackfin
arch irqchip init code. So, do it properly as common irq init code.

Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-06-25 12:02:07 +08:00
Mike Frysinger fc68911ee3 Blackfin arch: use the generic platform nand driver to support nand flash on bf53x board which do not have on-chip nand flash controller
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-06-25 11:41:42 +08:00
Laurent Pinchart da3854fc9f DM9000: Fixup blackfin after removing 2 resource usage
The dm9000 driver accepts either 2 or 3 resources to describe the platform
devices. The 2 resources case abuses the ioresource mechanism by passing
ioremap()ed memory through the platform device resources. This patch removes
converts boards that were using it to the 3 resources scheme.

CC: Bryan Wu <cooloney@kernel.org>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
Signed-off-by: Laurent Pinchart <laurentp@cse-semaphore.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-06-24 22:56:57 -04:00
Arnd Bergmann 9a8bd2f76c bf561-coreb: BKL pushdown
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2008-06-20 14:05:54 -06:00
Mike Frysinger 5bda27235b Blackfin arch: protect only the SPI bus controller with CONFIG_SPI_BFIN
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-06-07 15:03:01 +08:00
Mike Frysinger bd628bd085 Blackfin arch: fixup warnings with the new cplb saved values
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-06-03 12:23:45 +08:00
Michael Hennerich b06dcee9c8 Blackfin arch: Remove bad and usless code
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-05-31 15:35:40 +08:00
Bryan Wu 2eb74ae20e Blackfin arch: Fix bug - set corret SSEL and IRQ to enable AD7877 on BF527
AD7877 use SSEL_2 (P9.9) and IRQ_PF8 (P9.14) on BF527

 - populating JP3 to enable STAMP
 - disable SW11.2 to disconnect SSEL_2/PF12 from Rotary NAND
 - disable SW18.1 to disconnect SSEL_2 from MAX1233 touchscreen chip

Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-05-31 15:17:25 +08:00
Bryan Wu ca56d9aaf2 Blackfin arch: Fix typo. it should be _outsw_8
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-05-20 16:45:29 +08:00
Michael Hennerich f086f23435 Blackfin arch: Cleanup no functional changes
Singed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-05-20 16:42:39 +08:00
Linus Torvalds e23a5f6687 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs-2.6
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs-2.6:
  [PATCH] return to old errno choice in mkdir() et.al.
  [Patch] fs/binfmt_elf.c: fix wrong return values
  [PATCH] get rid of leak in compat_execve()
  [Patch] fs/binfmt_elf.c: fix a wrong free
  [PATCH] avoid multiplication overflows and signedness issues for max_fds
  [PATCH] dup_fd() part 4 - race fix
  [PATCH] dup_fd() - part 3
  [PATCH] dup_fd() part 2
  [PATCH] dup_fd() fixes, part 1
  [PATCH] take init_files to fs/file.c
2008-05-19 16:37:45 -07:00
Jean Delvare 24fbacca02 i2c: Clean up Blackfin BF527 I2C device declarations
I2C_BOARD_INFO() now sets the type field so no need to set it
separatetly.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Cc: Bryan Wu <cooloney@kernel.org>
2008-05-18 20:49:40 +02:00
Michael Hennerich ecb9567e28 Blackfin arch: update boards defconfig files
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-05-19 14:56:33 +08:00
Michael Hennerich 5906967638 Blackfin arch: IO Port functions to read/write unalligned memory
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-05-17 16:38:52 +08:00
Cliff Cai 86ad79321c Blackfin arch: enable a choice to provide 4M DMA memory
support two cascaded AD73322 cards, more uncached DMA
memory is needed, so add a choice to provide 4M DMA memory

Signed-off-by: Cliff Cai <cliff.cai@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-05-17 16:36:52 +08:00
Mike Frysinger c6c6f75d54 Blackfin arch: cleanup the icplb/dcplb multiple hit checks
so that we always send the same signal and we handle the NULL ptr condition properly

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-05-17 16:18:08 +08:00
Michael Hennerich 803a8d2acb Blackfin arch: Add workaround to read edge triggered GPIOs
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-05-17 16:01:51 +08:00
Michael Hennerich 5ce998cf6d Blackfin arch: Check for Anomaly 05000182
IMDMA does not operate to full speed for 600MHz and higher devices

Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-05-17 15:57:01 +08:00
Al Viro f52111b154 [PATCH] take init_files to fs/file.c
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
2008-05-16 17:22:20 -04:00
Mike Frysinger 9cd9c616f5 [Blackfin] arch: rename bf5xx-flash to bfin-async-flash
- move all kconfig board settings into board resources
 - fixup casting style according to lkml feedback
 - rewrite driver so that it can handle arbitrary
   of instances according to the declared platform resources

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Cc: Joern Engel <joern@logfs.org>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-05-13 12:31:32 +08:00
Al Viro 45b3947c2d [Blackfin] arch: Blackfin checksum annotations
FSVOtest in this case, since I don't have the hardware...
However, all changes seen by gcc are actually
 - explicit cast to unsigned short in return expression of functions
    returning unsigned short
 - csum_fold() return type changed from unsigned int to __sum16
   (unsigned short), same as for all other architecture and as net/* expects;
   expression actually returned is ((~(sum << 16)) >> 16) with sum being
   unsigned 32bit, so it's (a) going to fit into the range of unsigned short
   and (b) had been unsigned all along, so no sign expansion mess happened.

Tested-by: Bryan Wu <cooloney@kernel.org>
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: David Miller <davem@davemloft.net>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-05-12 11:55:10 +08:00
Mike Frysinger e4f7c0bf1f [Blackfin] arch: protect linux/usb/musb.h include until the driver gets mainlined
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-05-10 00:08:12 +08:00
Mike Frysinger b964c592d4 [Blackfin] arch: protect linux/usb/isp1362.h include until the driver gets mainlined
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-05-10 00:06:10 +08:00
Michael Hennerich 197fba5686 [Blackfin] arch: add EBIU supporting for BF54x EZKIT SMSC LAN911x/LAN921x families embedded ethernet driver
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-05-07 17:03:27 +08:00
Grace Pan d7323696a9 [Blackfin] arch: Set spi flash partition on bf527 as like bf548.
Signed-off-by: Grace Pan <grace.pan@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-05-07 11:41:26 +08:00
Meihui Fan 96a87e2f15 [Blackfin] arch: fix bug - Remove module will not free L1 memory used
Remove module will not free L1 memory used which caused by
memory access after free.  This patch fixes it.

Signed-off-by: Meihui Fan <mhfan@hhcn.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-05-07 11:41:26 +08:00
Mike Frysinger 60c05953c1 [Blackfin] arch: fix wrong header name in comment
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-05-07 11:41:26 +08:00
Michael Hennerich b9c9e78894 [Blackfin] arch: Fix BUG - spi flash on bf527 ezkit would fail at mount
BF527-EZKit features 16MBit M25P16 flash

Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-05-07 11:41:26 +08:00
Bryan Wu 72268689cf [Blackfin] arch: add twi_lcd and twi_keypad i2c board info to bf527-ezkit
- JP3 should be installed for STAMP enable
 - IRQ for twi_keypad driver is IRQ_PF8

Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-05-07 11:41:26 +08:00
Michael Hennerich d7e5dd41e3 [Blackfin] arch: Add physmap partition for BF527-EZkit
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-05-07 11:41:26 +08:00
Bernd Schmidt 0893f1250f [Blackfin] arch: fix gdb testing regression
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>
2008-05-07 11:41:26 +08:00
Bernd Schmidt 8513c42edb [Blackfin] arch: disable single stepping when delivering a signal
When delivering a signal, disable single stepping but call
ptrace_notify if it was enabled before. The idea was taken
from the x86 port.

Signed-off-by: Bernd Schmidt <bernds_cb1@t-online.de>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-05-07 11:41:26 +08:00
Bernd Schmidt 7d39270d31 [Blackfin] arch: Delete unused (copied from m68k) entries in asm-offsets.c.
Fix some really ancient code that was correct only for the m68k port.
Delete unused (i.e. copied from m68k) entries in asm-offsets.c.

Signed-off-by: Bernd Schmidt <bernds_cb1@t-online.de>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-05-07 11:41:26 +08:00
Bernd Schmidt ddb3f00ca0 [Blackfin] arch: In the double fault handler, set up the PT_RETI slot
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>
2008-05-07 11:41:26 +08:00
Vitja Makarov 1bfb4b21c7 [Blackfin] arch: Support for CPU_FREQ and NOHZ
Singed-off-by: Vitja Makarov <vitja.makarov@gmail.com>
2008-05-07 11:41:26 +08:00
Michael Hennerich 14b03204c8 [Blackfin] arch: Functional power management support: Add CPU and platform voltage scaling support
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-05-07 11:41:26 +08:00
Bernd Schmidt 19d6d7d53c [Blackfin] arch: fix bug - breaking the atomic sections code.
The following cleanup patch:
  add __user markings to a few userspace system functions

mysteriously added a "&" operator that doesn't belong in there, breaking the
atomic sections code.

Signed-off-by: Bernd Schmidt <bernds_cb1@t-online.de>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-05-07 11:41:26 +08:00
Michael Hennerich 67dea022d8 [Blackfin] arch: Cleanup Kconfig, fix comment and make sure we exclude CCLK=SCLK for some configurations
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-05-07 11:41:26 +08:00
Ulrich Drepper d35c7b0e54 unified (weak) sys_pipe implementation
This replaces the duplicated arch-specific versions of "sys_pipe()" with
one unified implementation.  This removes almost 250 lines of duplicated
code.

It's marked __weak, so that *if* an architecture wants to override the
default implementation it can do so by simply having its own replacement
version, since many architectures use alternate calling conventions for
the 'pipe()' system call for legacy reasons (ie traditional UNIX
implementations often return the two file descriptors in registers)

I still haven't changed the cris version even though Linus says the BKL
isn't needed.  The arch maintainer can easily do it if there are really
no obstacles.

Signed-off-by: Ulrich Drepper <drepper@redhat.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-05-03 13:50:33 -07:00
Jean Delvare 3760f73671 i2c: Convert most new-style drivers to use module aliasing
Based on earlier work by Jon Smirl and Jochen Friedrich.

Update most new-style i2c drivers to use standard module aliasing
instead of the old driver_name/type driver matching scheme. I've
left the video drivers apart (except for SoC camera drivers) as
they're a bit more diffcult to deal with, they'll have their own
patch later.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Cc: Jon Smirl <jonsmirl@gmail.com>
Cc: Jochen Friedrich <jochen@scram.de>
2008-04-29 23:11:40 +02:00
Christoph Lameter 5544b9ed81 blackfin: use kbuild.h instead of defining macros in asm-macros.c
Signed-off-by: Christoph Lameter <clameter@sgi.com>
Cc: Bryan Wu <bryan.wu@analog.com>
Cc: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-04-29 08:06:29 -07:00
WANG Cong ecd0fa9825 Remove the macro get_personality
Remove the macro get_personality, use ->personality instead.

Cc: Christoph Hellwig <hch@infradead.org
Cc: Alexey Dobriyan <adobriyan@gmail.com>
Cc: David Howells <dhowells@redhat.com>
Cc: Bryan Wu <bryan.wu@analog.com>
Signed-off-by: WANG Cong <xiyou.wangcong@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-04-29 08:06:02 -07:00
Mike Frysinger 0c11700dbf [Blackfin] arch: add include/boot .gitignore files
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-25 08:29:11 +08:00
Michael Hennerich e6c91b64dd [Blackfin] arch: Functional power management support: Add support for cpu frequency scaling
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-25 04:58:29 +08:00
Michael Hennerich fe44193c55 [Blackfin] arch: Functional power management support: Remove broken cpu frequency scaling drivers
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-25 04:52:11 +08:00
Sonic Zhang 2fb6cb41ec [Blackfin] arch: Add a warning about the value of CLKIN.
Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-25 04:39:28 +08:00
Michael Hennerich 1e78042c77 [Blackfin] arch: take DDR DEVWD into consideration as well for BF548
Pointed-out-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-25 04:31:23 +08:00
Bernd Schmidt 5d750b9e4f [Blackfin] arch: Remove the circular buffering mechanism for exceptions
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>
2008-04-25 05:02:33 +08:00
Bernd Schmidt 00d205a1ce [Blackfin] arch: lose unnecessary dependency on CONFIG_BFIN_ICACHE for MPU
Signed-off-by: Bernd Schmidt <bernds_cb1@t-online.de>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-25 03:26:48 +08:00
Graf Yang 565c0d3ff4 [Blackfin] arch: fix bug - before assign new channel to the map register, need clear the bits first.
http://blackfin.uclinux.org/gf/project/uclinux-dist/tracker/?action=TrackerItemEdit&tracker_item_id=2445

Signed-off-by: Graf Yang <graf.yang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-25 03:10:04 +08:00
Graf Yang 5be36d22b2 [Blackfin] arch: add Blackfin on-chip SIR IrDA driver support
- add platform device resources in board files
 - add new bfin_sir.h to each machines

Signed-off-by: Graf Yang <graf.yang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-25 03:09:15 +08:00
Mike Frysinger 37b6972ad8 [Blackfin] arch: BF54x memsizes are in mbits, not mbytes
Pointed-out-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-25 02:19:17 +08:00
Robin Getz 7f1c906808 [Blackfin] arch: try to remove condition that causes double fault, by checking current before it gets dereferenced
Signed-off-by: Robin Getz <rgetz@blackfin.uclinux.org>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-25 03:36:31 +08:00
Michael Hennerich 8e9d5c7daf [Blackfin] arch: Add platform support for MTD DATAFLASH
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-24 08:46:19 +08:00
Mike Frysinger 5f004c2009 [Blackfin] arch: reorganize some of the board-customization options so that similar things are together and only available as needed
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-25 02:11:24 +08:00
Michael Hennerich affee2b261 [Blackfin] arch: Allow concurrent use of GPIO and GPIO IRQ
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>
2008-04-24 08:10:10 +08:00
Mike Frysinger a086ee2268 [Blackfin] arch: detect the memory available in the system on the fly by default
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>
2008-04-25 02:04:05 +08:00
Mike Frysinger 4bea8b20fd [Blackfin] arch: add implicit icplb for the bootrom so we can use the utility functions in the kernel
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-24 07:23:36 +08:00
Grace Pan ac76d889b5 [Blackfin] arch: Adjust the u-boot and kernel image partition size in mtd device.
Signed-off-by: Grace Pan <grace.pan@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-24 06:33:56 +08:00
Mike Frysinger bc6e0fa159 [Blackfin] arch: use the same style for missing L1 sections
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-24 06:21:25 +08:00
Mike Frysinger 9f8e895d6c [Blackfin] arch: now that we can panic() early, dont need the delayed L1 overflow check
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-24 06:20:11 +08:00
Sonic Zhang b85b82d980 [Blackfin] arch: fix bug - Section data_l1_cacheline_aligned should be defined in link script of kernel
http://blackfin.uclinux.org/gf/project/uclinux-dist/tracker/?action=TrackerItemEdit&tracker_item_id=3978

Section data_l1_cacheline_aligned should be defined in
link script of kernel, when L1 data sram bank A is not available.

In bf536 with all data cache is enabled, there is no L1 data sram.
Current link script won't define section data_l1.cacheline_aligned in
this case. But, if user select put cacheline_aligned data into l1 sram
in kernel menuconfig, these data will be dropped and access to these
data will trigger data CPLB exception.

Do panic in l1 relocation code as well.

Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-24 06:13:37 +08:00
Robin Getz 253bcf4f9b [Blackfin] arch: Add a little bit more runtime info for MPU
Signed-off-by: Robin Getz <rgetz@blackfin.uclinux.org>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-24 05:57:13 +08:00
Mike Frysinger 16428a4fa9 [Blackfin] arch: make the mask explicit rather than writing a negative number in hex
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-24 05:56:07 +08:00
Mike Frysinger 4e354b5499 [Blackfin] arch: cplb-mpu code clean up
- allow bootrom to be readable from supervisor mode
 - delete unused local variable "addr"
 - punt unused local defines of cplbinfo.c

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-24 05:44:32 +08:00
Bernd Schmidt 7795566495 [Blackfin] arch: Give the DMA base registers a more descriptive name
The DMA base registers are available in a global named "base_addr" for
every Blackfin variant. Give this a more descriptive name, and remove
duplicate tables from some drivers.

Signed-off-by: Bernd Schmidt <bernds_cb1@t-online.de>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-24 05:31:18 +08:00
Bernd Schmidt ac86a97853 [Blackfin] arch: Consistently export base_addr for all Blackfin variants.
Signed-off-by: Bernd Schmidt <bernds_cb1@t-online.de>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-24 05:23:31 +08:00
Bernd Schmidt 37fa24212e [Blackfin] arch: Allow AD1836A board to be connected, either to SPORT2 or SPORT3.
Signed-off-by: Bernd Schmidt <bernds_cb1@t-online.de>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-24 05:19:02 +08:00
Mike Frysinger 764cb81cdc [Blackfin] arch: actually implement get_cycles function
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-24 05:07:29 +08:00
Mike Frysinger 8cab0288c6 [Blackfin] arch: add boot messages to quickly distinguish between MPU/NOMPU settings
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-24 05:13:10 +08:00
Mike Frysinger 3132b58679 [Blackfin] arch: theres no need to declare ram{end,start,base} in the head.S files
theres no need to declare ram{end,start,base} in the head.S files
when declaring them with the other memory related variables in setup.c
is so much simpler/nicer

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-24 05:12:09 +08:00
Mike Frysinger 8b6eb473c5 [Blackfin] arch: remove duplicated prototypes for internal cplb structures from the global blackfin header
remove duplicated prototypes for internal cplb structures from
the global blackfin header as nothing else should be accessing these

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-24 05:09:06 +08:00
Mike Frysinger 681793711a [Blackfin] arch: declare list of peripherals as const since we dont modify the incoming array
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-24 05:04:24 +08:00
Mike Frysinger 5d1617b247 [Blackfin] arch: merge ip0x-specific board changes
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-24 05:03:26 +08:00
Peter Korsgaard f950f605b9 [Blackfin] arch: USB header files are now located under linux/usb/.
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-24 03:34:13 +08:00
Graf Yang 6ed8394230 [Blackfin] arch: Resolve the clash issue of UART defines between blackfin headers and include/linux/serial_reg.
Signed-off-by: Graf Yang <graf.yang@analog.com>
Cc: Robin Getz <rgetz@blackfin.uclinux.org>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-24 04:43:14 +08:00
Michael Hennerich db68254f06 [Blackfin] arch: Apply Bluetechnix vendor patch
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-24 03:18:59 +08:00
Bernd Schmidt d5adb029ef [Blackfin] arch: This allows XIP to work with FD-PIC.
Previously, init failed to do anything meaningful;
it turns out that the reason is that FD-PIC has a readonly data
section which can be located in the XIP filesystem, and various address checks
in the kernel reject such addresses for syscall arguments.  Hence, init's
  execve ("/bin/sh", ...)
failed with error code EFAULT.

There's room for improvement here: in case people want to have filesystems
on flash rather than in main memory, _access_ok should be modified to
allow this.

This bug fix is also dedicated to Michael Hennerich.

Signed-off-by: Bernd Schmidt <bernds_cb1@t-online.de>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-24 03:06:15 +08:00
Bernd Schmidt 1ebc723cf0 [Blackfin] arch: support the reserved memory region in the MPU code
Pointed-out-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bernd Schmidt <bernds_cb1@t-online.de>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-24 02:58:26 +08:00
Bernd Schmidt d56daae9be [Blackfin] arch: fix bug - a crash on bootup with CONFIG_MPU on the BF548
The function flush_switched_dcplbs was clearing the CPLB entries covering
the process permission bitmasks.  This means that the sequence

	flush_switched_dcplbs ();
        set_mask_dcplbs(mm->context.page_rwx_mask);

has a problem: if kernel code (such as an interrupt) causes a CPLB miss before
set_mask_dcplbs completes, the CPLB handler function causes a double fault,
with an instantaneous reboot.

This bug fix is dedicated to Michael Hennerich, the only person in the world
capable of providing working JTAG hardware.

Signed-off-by: Bernd Schmidt <bernds_cb1@t-online.de>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-24 02:56:36 +08:00
Bernd Schmidt 697a9d65aa [Blackfin] arch: a rather old performance improvement for the signal handling code
This is a rather old performance improvement for the signal handling
code, which was originally only committed on the 2007R1 branch as a
workaround for what we suspected to be a hardware bug.

There's no point in constructing a sigreturn stub on the stack and
flushing caches; we can just make signal handlers return to a known
location in the fixed code area.

Signed-off-by: Bernd Schmidt <bernds_cb1@t-online.de>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-24 02:51:36 +08:00
Mike Frysinger 5af29f5958 [Blackfin] arch: finish removing remnants of old BF537_PORT_H option of Blackfin EMAC driver
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
Acked-by: Jeff Garzik <jeff@garzik.org>
2008-04-24 02:37:27 +08:00
Mike Frysinger 7b8aa36e56 [Blackfin] arch: LARGE_ALLOCS was dropped along the way ... bring Blackfin in line
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-23 10:19:59 +08:00
Mike Frysinger 2973951c96 [Blackfin] arch: we no longer use BFIN_{SINGLE,DUAL}_CORE in our source
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-23 10:14:14 +08:00
Bryan Wu 1bee1a660a [Blackfin] arch: boards and machines defconfig updates
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-24 05:02:04 +08:00
Harvey Harrison b85d858b40 [Blackfin] arch: __FUNCTION__ is gcc-specific, use __func__
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>
2008-04-23 09:39:01 +08:00
Meihui Fan c5b50df8f0 [Blackfin] arch: fix bug - make sure we check the right L1 length
Signed-off-by: Meihui Fan <mhfan@hhcn.com>
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-23 08:55:26 +08:00
Meihui Fan 6eceb0d4da [Blackfin] arch: add support for the rest of the gptimers on the BF54x
Signed-off-by: Meihui Fan <mhfan@hhcn.com>
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-23 08:53:15 +08:00
Mike Frysinger 0e184c6b4f [Blackfin] arch: relocate MAX_SWITCH_{D,I}_CPLBS from the header to the file where it actually gets used.
relocate MAX_SWITCH_{D,I}_CPLBS from the header to the file
where it actually gets used.  this way when we change
CONFIG_MEM_SIZE in our kconfig, we only rebuild one or two files
rather than a whole bunch that implicitly include cplb.h.

this will also remove the ability to clear the swapcount on
the fly, but i really dont think that functionality is important.

ultimate goal is for CONFIG_MEM_SIZE to go away and calculate
this value on the fly based on what u-boot programmed for us.

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-23 08:23:51 +08:00
Mike Frysinger 618835a0e3 [Blackfin] arch: MEM_ADD_WIDTH only gets used when reprogramming clocks, so dont bother exposing it in the menu normally
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-23 08:07:05 +08:00
Mike Frysinger 6a42a91019 [Blackfin] arch: update reboot code to match latest info (really just copy from u-boot)
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-23 08:01:31 +08:00
Bernd Schmidt b4bb68f7d0 [Blackfin] arch: fix bug - Make the MPU code aware of the async banks and the uncached DMA area.
Bug: CONFIG_MPU doesn't seem to handle access to ASYNC/IO Memory well
http://blackfin.uclinux.org/gf/project/uclinux-dist/tracker/?action=TrackerItemEdit&tracker_item_id=3912

Signed-off-by: Bernd Schmidt <bernds_cb1@t-online.de>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-23 07:26:23 +08:00
Bernd Schmidt 2a0c4fdb66 [Blackfin] arch: fix bug - when using trace buffer with CONFIG_MPU enabled.
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>
2008-04-23 07:17:34 +08:00
Bernd Schmidt dbfe44f02b [Blackfin] arch: fix up - CONFIG_BLKFIN_WT was renamed CONFIG_BFIN_WT while the MPU code was out-of-tree.
Signed-off-by: Bernd Schmidt <bernds_cb1@t-online.de>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-04-23 07:11:55 +08:00
Robin Getz 904656cda1 [Blackfin] arch: fix bug - grab locks when not atomic
grab locks when not atomic - this fixes the issues
sometimes seen when using magic sysrq.

Signed-off-by: Robin Getz <rgetz@blackfin.uclinux.org>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-03-26 09:17:43 +08:00
Robin Getz 9a62ca40fd [Blackfin] arch: fix bug - when we crash, current is not valid
Sometimes when we crash, current is not valid, (has been written
over), so the existing code causes a invalid read during exception
context - which is a unrecoverable double fault. This fixes this.

Signed-off-by: Robin Getz <rgetz@blackfin.uclinux.org>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-03-26 09:15:58 +08:00
Bryan Wu 81d9c7f27d [Blackfin] arch: add i2c board info struct and move to new-style i2c interface
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-03-26 10:02:13 +08:00
Mike Frysinger d171c23327 [Blackfin] arch: fix up gpio code style -- no functional changes
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-03-26 08:35:46 +08:00
Mike Frysinger f85c4abdbc [Blackfin] arch: dump the stack before printing out an error otherwise the stack dump is useless as it shows us tracing through printk
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-03-26 08:34:23 +08:00
Mike Frysinger 793dc27b51 [Blackfin] arch: conditionally enable flash resources since it requests the async memory bank
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-03-26 08:09:12 +08:00
Yi Li 2e8d7965e6 [Blackfin] arch: add code to initialize globals declared in linux/bootmem.h: max_pfn, max_low_pfn, min_low_pfn.
Signed-off-by: Yi Li <yi.li@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-03-26 07:08:12 +08:00
Bernd Schmidt 9df7a8f622 [Blackfin] arch: remove NOTES from linker script
Since
  r3658 | vapier | 2007-09-12 16:26:11 +0200 (Wed, 12 Sep 2007) | 1 line

  add more common defines for output sections

we've had a new line, NOTES, in our linker script, which causes upstream
binutils to complain about "missing phdr".  Currently the only other arch
that uses NOTES is i386, and the patch which added it also added
PHDRS {
	text PT_LOAD FLAGS(5);	/* R_E */
	data PT_LOAD FLAGS(7);	/* RWE */
	note PT_NOTE FLAGS(0);	/* ___ */
}
and a few other modifications to use ":text" and ":data" to the linker
script.

It seems that we don't need NOTES at all, so just remove it.

Signed-off-by: Bernd Schmidt <bernds_cb1@t-online.de>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-03-26 06:39:15 +08:00
Mike Frysinger 56ce835b60 [Blackfin] arch: add twi resources to CM_BF537 board as reported by Servaes Joordens
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-03-26 06:00:18 +08:00
Mike Frysinger f692940101 [Blackfin] arch: declare CHECKFLAGS to make sparse output more readable
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-03-07 02:43:48 +08:00
Mike Frysinger 0ddeeca25c [Blackfin] arch: add missing __user marking to ss_sp member of signalstack and a few userspace system functions
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-03-07 02:37:41 +08:00
Mike Frysinger 1307a65130 [Blackfin] arch: turn generic time on by default
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-02-29 12:26:41 +08:00
Mike Frysinger b4e2d18f73 [Blackfin] arch: add board bluetechnix kernel defconfigs to kernel
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-02-29 12:14:25 +08:00
Vitja Makarov 8b5f79f9d7 [Blackfin] arch: initial generic time and clock sources
This patch enables Hight-Res Timers and tickless kernel

Signed-off-by: Vitja Makarov <vitja.makarov@gmail.com>
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-02-29 12:24:23 +08:00
Jeff Garzik 349a2444cf [BLACKFIN] minor irq handler cleanups
- use standard irq_handler_t to define irq handler function arguments

Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-04-20 18:45:27 -04:00
Matthew Wilcox 64ac24e738 Generic semaphore implementation
Semaphores are no longer performance-critical, so a generic C
implementation is better for maintainability, debuggability and
extensibility.  Thanks to Peter Zijlstra for fixing the lockdep
warning.  Thanks to Harvey Harrison for pointing out that the
unlikely() was unnecessary.

Signed-off-by: Matthew Wilcox <willy@linux.intel.com>
Acked-by: Ingo Molnar <mingo@elte.hu>
2008-04-17 10:42:34 -04:00
Mike Frysinger 11b0be7c2c [Blackfin] arch: fix atomic and32/xor32 comments and ENDPROC markings
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-03-03 17:44:14 -07:00
Michael Hennerich 3d7e6cf8f5 [Blackfin] arch: fix bug - allow SDH driver to be used as module
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-03-03 17:40:28 -07:00
Bryan Wu 2f775dbaa5 [Blackfin] arch: to kill syscalls missing warning by adding new timerfd syscalls
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-03-06 16:04:58 -07:00
Bryan Wu c051489df8 [Blackfin] arch: kill section mismatch warnings
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-02-29 12:02:10 +08:00
Mike Frysinger 8b07a2a1e5 [Blackfin] arch: handle the most common L1 shrinkage case (L1 does not exist for a part) so that any parts labeled for L1 instead get placed into external memory sections
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-02-29 11:57:35 +08:00
Mike Frysinger fee40119a2 [Blackfin] arch: make sure we have proper description/copyright/license lines
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-02-25 15:06:07 +08:00
Michael Hennerich 3927819d51 [Blackfin] arch: Fix CONFIG_PM support for BF561
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-02-25 14:39:50 +08:00
Michael Hennerich 9253d02041 [Blackfin] arch: Remove DPMC char driver option
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>
2008-02-25 14:27:28 +08:00
Michael Hennerich 464abc5de6 [Blackfin] arch: Cleanup abd Simplify:
- 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>
2008-02-25 13:50:20 +08:00
Michael Hennerich ce3b7bb61c [Blackfin] arch: fix bug - linux-2.6.24 (delayed) disable IRQ feature not 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>
2008-02-25 13:48:47 +08:00
Mike Frysinger d45118b14b [Blackfin] arch: make sure we export the _bfin_swrst symbol as modules (like the watchdog) need it
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-02-25 12:24:44 +08:00
Mike Frysinger 0db5d105cd [Blackfin] arch: punt the simple ad5304 spi driver now that the generic spidev driver lets you do it from userspace
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-02-25 12:19:57 +08:00
Michael Hennerich fe9ec9b969 [Blackfin] arch: fix bug - Move IWR Enable All to the end of init_arch_irq otherwise it fails
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-02-25 12:04:57 +08:00
Mike Frysinger 181afa9498 [Blackfin] arch: grab mac address from OTP on BF527-EZKIT
The bf527-ezkit stores the mac address in OTP,
so grab it from there rather than flash

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-02-25 11:42:17 +08:00
Sonic Zhang 549aaa8425 [Blackfin] arch: Fix bug - Setting peripheral_map only when dma channel is UART2/3.
Singed-off-by: Sonic Zhang <sonic.zhang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-02-25 11:13:07 +08:00
Mike Frysinger cad2ab65dd [Blackfin] arch: add board resources for new simple-gpio char driver
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-02-22 17:01:31 +08:00
Mike Frysinger edf056417d [Blackfin] arch: fix bug - set right partition size in the board files
- set default u-boot partition size to 256k
 - modify the offset with the size change
 - use mtd defines (append for offset and full for size)
   where applicable rather than churning constants when we dont have to

Signed-off-by: Grace Pan <grace.pan@analog.com>
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-02-25 11:38:11 +08:00
Sonic Zhang 32320ea0a6 [Blackfin] arch: Update default config
Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-02-22 16:43:45 +08:00
Mike Frysinger 8929ecf84d [Blackfin] arch: add fixed code to the memory map output
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-02-22 16:35:20 +08:00
Mike Frysinger c63d4e6408 [Blackfin] arch: add handling for the mach symlink in the `make V=1` case
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-02-22 16:12:01 +08:00
Mike Frysinger 4d94bf6746 [Blackfin] arch: respect `make -s` when creating the asm/mach symlink
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-02-22 16:03:54 +08:00
Mike Frysinger 7aa475cfb7 [Blackfin] arch: fix bug add missing header file
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-02-22 16:01:50 +08:00
Jan Blunck cf28b4863f d_path: Make d_path() use a struct path
d_path() is used on a <dentry,vfsmount> pair.  Lets use a struct path to
reflect this.

[akpm@linux-foundation.org: fix build in mm/memory.c]
Signed-off-by: Jan Blunck <jblunck@suse.de>
Acked-by: Bryan Wu <bryan.wu@analog.com>
Acked-by: Christoph Hellwig <hch@infradead.org>
Cc: Al Viro <viro@zeniv.linux.org.uk>
Cc: "J. Bruce Fields" <bfields@fieldses.org>
Cc: Neil Brown <neilb@suse.de>
Cc: Michael Halcrow <mhalcrow@us.ibm.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-02-14 21:17:09 -08:00
Peter Zijlstra aa02cd2d9b xtime_lock vs update_process_times
Commit d3d74453c3 ("hrtimer: fixup the
HRTIMER_CB_IRQSAFE_NO_SOFTIRQ fallback") broke several archs, and since
only Russell bothered to merge the fix, and Greg to ACK his arch, I'm
sending this for merger.

I have confirmation that the Alpha bit results in a booting kernel.
That leaves: blackfin, frv, sh and sparc untested.

The deadlock in question was found by Russell:

  IRQ handle
    -> timer_tick() - xtime seqlock held for write
      -> update_process_times()
        -> run_local_timers()
          -> hrtimer_run_queues()
            -> hrtimer_get_softirq_time() - tries to get a read lock

Now, Thomas assures me the fix is trivial, only do_timer() needs to be
done under the xtime_lock, and update_process_times() can savely be
removed from under it.

Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Acked-by: Greg Ungerer <gerg@uclinux.org>
CC: Richard Henderson <rth@twiddle.net>
CC: Bryan Wu <bryan.wu@analog.com>
CC: David Howells <dhowells@redhat.com>
CC: Paul Mundt <lethal@linux-sh.org>
CC: William Irwin <wli@holomorphy.com>
Acked-by: Ingo Molnar <mingo@elte.hu>
Acked-by: Ivan Kokshaysky <ink@jurassic.park.msu.ru>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-02-13 13:29:25 -08:00
Sam Ravnborg ec7748b59e ide: introduce HAVE_IDE
To allow flexible configuration of IDE introduce HAVE_IDE.
All archs except arm, um and s390 unconditionally select it.
For arm the actual configuration determine if IDE is supported.

This is a step towards introducing drivers/Kconfig for arm.

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
Acked-by: Russell King - ARM Linux <linux@arm.linux.org.uk>
Acked-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-02-09 10:46:40 +01:00
Mike Frysinger 67f2d33ec0 [Blackfin] arch: fix build fails only include header files when enabled
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2008-02-09 01:49:23 +08:00
Mike Frysinger 16e6da4fc3 [Blackfin] arch: declare default INSTALL_PATH for Blackfin ports
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2008-02-07 14:15:37 +08:00
Michael Hennerich 6e668936db [Blackfin] arch: Encourage users to use the spidev character driver: Provide platform support
- Enable kernel generic spidev driver for blackfin SPI ADC
 - spi_adc driver, document and test sample not synced

Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2008-02-09 01:54:09 +08:00
Sonic Zhang 8b01eaff4f [Blackfin] arch: Enable UART2 and UART3 for bf548
Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2008-02-02 16:31:00 +08:00
Michael Hennerich 83d9cde08b [Blackfin] arch: Enable NET2272 on BF561-EZkit - remove request_mem_region
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2008-02-02 16:25:17 +08:00
Michael Hennerich f1bceb47b3 [Blackfin] arch:Fix BUG [#3876] pfbutton test for BTN3 on bf533 don't show 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>
2008-02-02 16:17:52 +08:00
Mike Frysinger c0eab3b784 [Blackfin] arch: fix building with mtd uclinux by putting the mtd_phys option into the function it actually gets used in
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2008-02-02 15:36:11 +08:00
Mike Frysinger 550d553838 [Blackfin] arch: simpler header and update dates
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2008-02-02 15:55:37 +08:00
Mike Frysinger b7627acc43 [Blackfin] arch: move the init sections to the end of memory
Move the init sections to the end of memory so that after they
are free, run time memory is all continugous - this should help decrease
memory fragementation.

When doing this, we also pack some of the other sections a little closer
together, to make sure we don't waste memory. To make this happen,
we need to rename the .data.init_task section to .init_task.data, so
it doesn't get picked up by the linker script glob.

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2008-02-02 15:53:17 +08:00
Mike Frysinger 80f31c8a03 [Blackfin] arch: change the trace buffer control start/stop logic in the 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>
2008-02-02 15:47:24 +08:00
Mike Frysinger a3acf52885 [Blackfin] arch: fix typo in printk message
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2008-02-02 15:45:27 +08:00
Mike Frysinger a01d7a76d8 [Blackfin] arch: this is an ezkit, not a stamp, so fixup the init function name
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2008-02-02 15:34:56 +08:00
Mike Frysinger cf93425d40 [Blackfin] arch: add slightly better help text for CPLB_INFO
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2008-02-02 15:32:40 +08:00
Michael Hennerich 6cda2e9058 [Blackfin] arch: Fix BUG - Enable ISP1362 driver to work ok with BF561
This fixes a bug (zero pointer access) only seen on BF561, during USB
Mass Storage/SCSI Host initialization.

It appears to be related to registering a none existing CPU

Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2008-02-02 15:10:51 +08:00
Michael Hennerich a680ae9bdd [Blackfin] arch: Fix header file information
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2008-02-02 15:04:38 +08:00
Michael Hennerich e9d76c2d08 [Blackfin] arch: Add Support for ISP1362
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2008-02-02 14:55:28 +08:00
Mike Frysinger c827902311 [Blackfin] arch: add support for cmdline partitioning to the BF533-STAMP flash map driver and enable it as a module by default
Signed-off-by: Mike Frysinger <michael.frysinger@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2008-02-09 04:13:15 +08:00
Michael Hennerich cfefe3c683 [Blackfin] arch: hook up set_irq_wake in Blackfin's irq code
- 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>
2008-02-09 04:12:37 +08:00
Michael Hennerich 2c4f829b0c [Blackfin] arch: Merge BF561 support into ints-priority
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>
2008-02-09 04:11:14 +08:00
Yi Li 856783b37a [Blackfin] arch: add "memmap=nn[KMG]@ss[KMG]" and "memmap=nn[KMG]$ss[KMG]" options to blackfin, based on arch/i386/kernel/e820.c
Signed-off-by: Yi Li <yi.li@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2008-02-09 02:26:01 +08:00
Mike Frysinger c605999bd9 [Blackfin] arch: error out if ANOMALY_05000263 applies while enabling the MPU
Signed-off-by: Mike Frysinger <michael.frysinger@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2008-02-02 12:28:23 +08:00
Jan Engelhardt 03a44825be procfs: constify function pointer tables
Signed-off-by: Jan Engelhardt <jengelh@computergmbh.de>
Acked-by: Geert Uytterhoeven <geert@linux-m68k.org>
Acked-by: Mike Frysinger <vapier@gentoo.org>
Acked-By: David Howells <dhowells@redhat.com>
Acked-by: Bryan Wu <bryan.wu@analog.com>
Acked-by: Jesper Nilsson <jesper.nilsson@axis.com>
Cc: <linux-arch@vger.kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-02-08 09:22:38 -08:00
David Howells 1eb1141123 aout: remove unnecessary inclusions of {asm, linux}/a.out.h
Remove now unnecessary inclusions of {asm,linux}/a.out.h.

[akpm@linux-foundation.org: fix alpha build]
Signed-off-by: David Howells <dhowells@redhat.com>
Cc: <linux-arch@vger.kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-02-08 09:22:30 -08:00
Bernhard Walle 72a7fe3967 Introduce flags for reserve_bootmem()
This patchset adds a flags variable to reserve_bootmem() and uses the
BOOTMEM_EXCLUSIVE flag in crashkernel reservation code to detect collisions
between crashkernel area and already used memory.

This patch:

Change the reserve_bootmem() function to accept a new flag BOOTMEM_EXCLUSIVE.
If that flag is set, the function returns with -EBUSY if the memory already
has been reserved in the past.  This is to avoid conflicts.

Because that code runs before SMP initialisation, there's no race condition
inside reserve_bootmem_core().

[akpm@linux-foundation.org: coding-style fixes]
[akpm@linux-foundation.org: fix powerpc build]
Signed-off-by: Bernhard Walle <bwalle@suse.de>
Cc: <linux-arch@vger.kernel.org>
Cc: "Eric W. Biederman" <ebiederm@xmission.com>
Cc: Vivek Goyal <vgoyal@in.ibm.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-02-07 08:42:25 -08:00
Jeff Garzik 0a87e3e92b Rename: linux/pata_platform.h to linux/ata_platform.h
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-02-06 06:54:17 -05:00
Davide Libenzi 4d672e7ac7 timerfd: new timerfd API
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>
2008-02-05 09:44:07 -08:00
Mathieu Desnoyers 125e564582 Move Kconfig.instrumentation to arch/Kconfig and init/Kconfig
Move the instrumentation Kconfig to

arch/Kconfig for architecture dependent options
  - oprofile
  - kprobes

and

init/Kconfig for architecture independent options
  - profiling
  - markers

Remove the "Instrumentation Support" menu. Everything moves to "General setup".
Delete the kernel/Kconfig.instrumentation file.

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@polymtl.ca>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: <linux-arch@vger.kernel.org>
Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
2008-02-03 08:58:08 +01:00
Mathieu Desnoyers 42d4b839c8 Add HAVE_OPROFILE
Linus:
On the per-architecture side, I do think it would be better to *not* have
internal architecture knowledge in a generic file, and as such a line like

        depends on X86_32 || IA64 || PPC || S390 || SPARC64 || X86_64 || AVR32

really shouldn't exist in a file like kernel/Kconfig.instrumentation.

It would be much better to do

        depends on ARCH_SUPPORTS_KPROBES

in that generic file, and then architectures that do support it would just
have a

        bool ARCH_SUPPORTS_KPROBES
                default y

in *their* architecture files. That would seem to be much more logical,
and is readable both for arch maintainers *and* for people who have no
clue - and don't care - about which architecture is supposed to support
which interface...

Changelog:

Actually, I know I gave this as the magic incantation, but now that I see
it, I realize that I should have told you to just use

        config ARCH_SUPPORTS_KPROBES
                def_bool y

instead, which is a bit denser.

We seem to use both kinds of syntax for these things, but this is really
what "def_bool" is there for...

Changelog :

- Moving to HAVE_*.
- Add AVR32 oprofile.

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@polymtl.ca>
Cc: Andrew Morton <akpm@linux-foundation.org>
Cc: Haavard Skinnemoen <hskinnemoen@atmel.com>
Cc: David Howells <dhowells@redhat.com>
Cc: Jeff Dike <jdike@addtoit.com>
Cc: Ananth N Mavinakayanahalli <ananth@in.ibm.com>
Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
2008-02-03 08:58:07 +01:00
Johannes Berg f4cb570076 Suspend: Clean up Kconfig (V2)
This cleans up the suspend Kconfig and removes the need to
declare centrally which architectures support suspend. All
architectures that currently support suspend are modified
accordingly.

Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
Acked-by: Russell King <rmk@arm.linux.org.uk>
Acked-by: Paul Mackerras <paulus@samba.org>
Acked-by: Ralf Baechle <ralf@linux-mips.org>
Acked-by: Paul Mundt <lethal@linux-sh.org>
Cc: Pavel Machek <pavel@suse.cz>
Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
Signed-off-by: Len Brown <len.brown@intel.com>
2008-02-01 18:30:55 -05:00
Sam Ravnborg 01ba2bdc6b all archs: consolidate init and exit sections in vmlinux.lds.h
This patch consolidate all definitions of .init.text, .init.data
and .exit.text, .exit.data section definitions in
the generic vmlinux.lds.h.

This is a preparational patch - alone it does not buy
us much good.

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
2008-01-28 23:21:17 +01:00
Bernd Schmidt fc97551db9 [Blackfin] arch: Add the semtimedop syscall. Upstream uClibc doesn't compile without it.
Signed-off-by: Bernd Schmidt <bernd.schmidt@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2008-01-27 19:56:43 +08:00
Yi Li ee7883b746 [Blackfin] arch: fix bug kernel boot message: memory information is not reasonable
Some of the information in kernel boot message is not reasonable.
http://blackfin.uclinux.org/gf/project/uclinux-dist/tracker/?action=TrackerItemEdit&tracker_item_id=3846

 - use _rambase as the start of kernel image.
   kernel is in the region [_rambase, _ramstart]
 - count in pages in per-cpu-page list as available memory
 - reserved memory now include: [0 - 4K] for bad pointer catching,
   memory reserved for abnormaly 05000263, memory reserved by kernel itself.

Signed-off-by: Yi Li <yi.li@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2008-01-27 19:56:17 +08:00
Mike Frysinger de8c43f2fc [Blackfin] arch: use common flash driver to setup partitions rather than the bf5xx-flash driver
Signed-off-by: Mike Frysinger <michael.frysinger@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2008-01-24 17:14:04 +08:00
Michael Hennerich 96a5c6f9be [Blackfin] arch: Fix bug - kernel build with Debug option enabled fails to boot up
writes to I/DMEM_CONTROL must be followed by SSYNC

Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2008-01-22 19:23:50 +08:00
Sonic Zhang 03c5732855 [Blackfin] arch: Fix bug Only RTC interrupt can wake up deeper sleep core.
Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2008-01-22 18:45:10 +08:00
Michael Hennerich 444ad82bc3 [Blackfin] arch: Add proper SW System Reset delay sequence
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2008-01-22 18:38:02 +08:00
Michael Hennerich a628a8bcd8 [Blackfin] arch: Update copyright date
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2008-01-22 17:29:16 +08:00
Michael Hennerich a2c8cfef6a [Blackfin] arch: GPIO API cleanup and anomaly update
- Add anomaly workaround for bfin_gpio_reset_spi0_ssel1
 - Fix style
 - Update copyright
 - Remove BUG_ON checks for functions intended to be used only by arch
   support. GPIO users should only access using the generic GPIO API
 - Make all GPIO identifier unsigned int

Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2008-01-22 17:20:10 +08:00
Michael Hennerich acbcd26319 [Blackfin] arch: Fix BUG gpio_direction_output API is not compatitable with GENERIC_GPIO API interface
signef-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2008-01-22 18:36:20 +08:00
Bernd Schmidt b97b8a9983 [Blackfin] arch: Initial checkin of the memory protection support.
Enable it with CONFIG_MPU.

Signed-off-by: Bernd Schmidt <bernd.schmidt@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2008-01-27 18:39:16 +08:00
Michael Hennerich 2047e40d72 [Blackfin] arch: set_bfin_dma_config shouldnt set SYNC or RESTART by default - add argument or option
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2008-01-22 15:29:18 +08:00
Michael Hennerich 4521ef42de [Blackfin] arch: Add some comments - fix semicolons
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
2008-01-11 17:21:41 +08:00