dbdf20db53
This is a mixture ofcMichael McTernan's patch and the existing cplb-mpu code. We ditch the old cplb-nompu implementation, which is a good example of why a good algorithm in a HLL is preferrable to a bad algorithm written in assembly. Rather than try to construct a table of all posible CPLBs and search it, we just create a (smaller) table of memory regions and their attributes. Some of the data structures are now unified for both the mpu and nompu cases. A lot of needless complexity in cplbinit.c is removed. Further optimizations: * compile cplbmgr.c with a lot of -ffixed-reg options, and omit saving these registers on the stack when entering a CPLB exception. * lose cli/nop/nop/sti sequences for some workarounds - these don't * make sense in an exception context Additional code unification should be possible after this. [Mike Frysinger <vapier.adi@gmail.com>: - convert CPP if statements to C if statements - remove redundant statements - use a do...while loop rather than a for loop to get slightly better optimization and to avoid gcc "may be used uninitialized" warnings ... we know that the [id]cplb_nr_bounds variables will never be 0, so this is OK - the no-mpu code was the last user of MAX_MEM_SIZE and with that rewritten, we can punt it - add some BUG_ON() checks to make sure we dont overflow the small cplb_bounds array - add i/d cplb entries for the bootrom because there is functions/data in there we want to access - we do not need a NULL trailing entry as any time we access the bounds arrays, we use the nr_bounds variable ] Signed-off-by: Michael McTernan <mmcternan@airvana.com> Signed-off-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> |
||
---|---|---|
.. | ||
.gitignore | ||
atomic.h | ||
auxvec.h | ||
bfin-global.h | ||
bfin5xx_spi.h | ||
bfin_simple_timer.h | ||
bfin_sport.h | ||
bfrom.h | ||
bitops.h | ||
blackfin.h | ||
bug.h | ||
bugs.h | ||
byteorder.h | ||
cache.h | ||
cacheflush.h | ||
cdef_LPBlackfin.h | ||
checksum.h | ||
clocks.h | ||
context.S | ||
cplb.h | ||
cplbinit.h | ||
cpu.h | ||
cputime.h | ||
current.h | ||
def_LPBlackfin.h | ||
delay.h | ||
device.h | ||
div64.h | ||
dma-mapping.h | ||
dma.h | ||
dpmc.h | ||
early_printk.h | ||
elf.h | ||
emergency-restart.h | ||
entry.h | ||
errno.h | ||
fb.h | ||
fcntl.h | ||
fixed_code.h | ||
flat.h | ||
futex.h | ||
gpio.h | ||
gptimers.h | ||
hardirq.h | ||
hw_irq.h | ||
io.h | ||
ioctl.h | ||
ioctls.h | ||
ipcbuf.h | ||
irq.h | ||
irq_handler.h | ||
irq_regs.h | ||
Kbuild | ||
kdebug.h | ||
kgdb.h | ||
kmap_types.h | ||
l1layout.h | ||
linkage.h | ||
local.h | ||
mem_init.h | ||
mem_map.h | ||
mman.h | ||
mmu.h | ||
mmu_context.h | ||
module.h | ||
msgbuf.h | ||
mutex-dec.h | ||
mutex.h | ||
nand.h | ||
page.h | ||
page_offset.h | ||
param.h | ||
pci.h | ||
pda.h | ||
percpu.h | ||
pgalloc.h | ||
pgtable.h | ||
poll.h | ||
portmux.h | ||
posix_types.h | ||
processor.h | ||
ptrace.h | ||
reboot.h | ||
resource.h | ||
rwlock.h | ||
scatterlist.h | ||
sections.h | ||
segment.h | ||
sembuf.h | ||
serial.h | ||
setup.h | ||
shmbuf.h | ||
shmparam.h | ||
sigcontext.h | ||
siginfo.h | ||
signal.h | ||
smp.h | ||
socket.h | ||
sockios.h | ||
spinlock.h | ||
spinlock_types.h | ||
stat.h | ||
statfs.h | ||
string.h | ||
swab.h | ||
system.h | ||
termbits.h | ||
termios.h | ||
thread_info.h | ||
time.h | ||
timex.h | ||
tlb.h | ||
tlbflush.h | ||
topology.h | ||
trace.h | ||
traps.h | ||
types.h | ||
uaccess.h | ||
ucontext.h | ||
unaligned.h | ||
unistd.h | ||
user.h | ||
xor.h |