Lines Matching +full:mapped +full:- +full:addr
3 # SPDX-License-Identifier: Apache-2.0
31 # Returns the offset of a segment within the sram region, or -1 if it
32 # doesn't appear to be SRAM. SRAM is mapped differently for different
38 def sram_off(addr): argument
40 if addr < 0x40000000 or addr >= 0x50000000:
41 return -1
42 block = addr & ~0xFFFFF
46 off = addr - sram_block
53 def dram_off(addr): argument
54 if (addr >> 28 not in [6, 9]) or (addr & 0x0F000000 != 0):
55 return -1
56 return addr & 0xFFFFFF
80 buf.extend(b'\x00' * (end - len(buf)))
82 # pylint: disable=consider-using-enumerate