linux-stable/arch/sh/include
Frederic Weisbecker feef47d0cb hw-breakpoints: Get the number of available registers on boot dynamically
The breakpoint generic layer assumes that archs always know in advance
the static number of address registers available to host breakpoints
through the HBP_NUM macro.

However this is not true for every archs. For example Arm needs to get
this information dynamically to handle the compatiblity between
different versions.

To solve this, this patch proposes to drop the static HBP_NUM macro
and let the arch provide the number of available slots through a
new hw_breakpoint_slots() function. For archs that have
CONFIG_HAVE_MIXED_BREAKPOINTS_REGS selected, it will be called once
as the number of registers fits for instruction and data breakpoints
together.
For the others it will be called first to get the number of
instruction breakpoint registers and another time to get the
data breakpoint registers, the targeted type is given as a
parameter of hw_breakpoint_slots().

Reported-by: Will Deacon <will.deacon@arm.com>
Signed-off-by: Frederic Weisbecker <fweisbec@gmail.com>
Acked-by: Paul Mundt <lethal@linux-sh.org>
Cc: Mahesh Salgaonkar <mahesh@linux.vnet.ibm.com>
Cc: K. Prasad <prasad@linux.vnet.ibm.com>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Jason Wessel <jason.wessel@windriver.com>
Cc: Ingo Molnar <mingo@elte.hu>
2010-05-01 04:32:14 +02:00
..
asm hw-breakpoints: Get the number of available registers on boot dynamically 2010-05-01 04:32:14 +02:00
cpu-common/cpu sh: Kill off unused cpu/cacheflush.h. 2009-08-21 16:20:57 +09:00
cpu-sh2/cpu sh: Mass ctrl_in/outX to __raw_read/writeX conversion. 2010-01-26 12:58:40 +09:00
cpu-sh2a/cpu sh: Convert SH-2A to new cacheflush interface. 2009-08-15 12:38:29 +09:00
cpu-sh3/cpu dmaengine: shdma: separate DMA headers. 2010-03-02 11:09:04 +09:00
cpu-sh4/cpu sh: update the TLB replacement counter for entry wiring. 2010-03-26 11:37:16 +09:00
cpu-sh5/cpu sh: Convert cache disabled SH-5 over to new cache interface. 2009-08-16 00:53:56 +09:00
mach-common/mach sh: Mass ctrl_in/outX to __raw_read/writeX conversion. 2010-01-26 12:58:40 +09:00
mach-dreamcast/mach sh: mach-dreamcast: Convert to sparseirq. 2010-02-02 18:01:55 +09:00
mach-ecovec24/mach sh: mach-ecovec24: Remove un-defined settings for VPU 2009-12-04 13:42:34 +09:00
mach-kfr2r09/mach sh: LCDC start_transfer() for the KFR2R09 board 2009-12-09 12:40:45 +09:00
mach-landisk/mach sh: migrate to arch/sh/include/ 2008-07-29 08:09:44 +09:00
mach-migor/mach sh: audio support for the sh7722 Migo-R board 2010-03-02 11:08:54 +09:00
mach-sdk7786/mach sh: mach-sdk7786: Probe system FPGA area mapping. 2010-01-20 18:25:19 +09:00
mach-se/mach sh: mach-se: Convert SE7343 FPGA to dynamic IRQ allocation. 2010-01-12 13:37:04 +09:00
mach-sh03/mach sh: migrate to arch/sh/include/ 2008-07-29 08:09:44 +09:00