xtensa: nommu: fix Image.elf reset code and ld script

Don't hardcode kernel entry address as 0x3000 or 0xd0003000, use
LOAD_MEMORY_ADDRESS macro. Don't compile MMU remapping code and don't try
to link it when building noMMU configuration.

Signed-off-by: Max Filippov <jcmvbkbc@gmail.com>
xtensa: nommu: fix load address definitions

Change KERNELOFFSET, LOAD_MEMORY_ADDRESS and VIRTUAL_MEMORY_ADDRESS to be
relative to the start of physical memory in noMMU configuration, as
there's no uniform memory remapping to KSEG starting at 0xd0000000.

Signed-off-by: Max Filippov <jcmvbkbc@gmail.com>
xtensa: move vecbase SR initialization to _startup

Instead of initializing vecbase in initialize_mmu macro, which may be
expanded either in Image.elf reset vector hadler or in the kernel
head.S, both times only when CONFIG_MMU is enabled, do this
initialization once in _startup function.

Signed-off-by: Max Filippov <jcmvbkbc@gmail.com>
xtensa: nommu: fix uImage load address

Use the same offset from the default physical memory start address as in
LOAD_MEMORY_ADDRESS definition.

Signed-off-by: Max Filippov <jcmvbkbc@gmail.com>
xtensa: nommu: reserve memory below PLATFORM_DEFAULT_MEM_START

Memory accounting code can't handle pages below
PLATFORM_DEFAULT_MEM_START. Reserve those pages if they exist.
When PLATFORM_DEFAULT_MEM_START is zero reserve one page at address 0 to
make sure that successfull memory allocations don't return NULL.

Signed-off-by: Max Filippov <jcmvbkbc@gmail.com>
xtensa: nommu: clean up memory map dump

noMMU configuration doesn't use special area for vmalloc allocations,
don't print it in the memory map.
PAGE_OFFSET is fixed to 0 in noMMU, use min_low_pfn and max_low_pfn for
lowmem range display.
Make all XCHAL_KSEG_* constants unsigned long for consistency with other
addresses.

Signed-off-by: Max Filippov <jcmvbkbc@gmail.com>
xtensa: make PLATFORM_DEFAULT_MEM parameters configurable

This allows using xtfpga platform with both MMU and noMMU cores.

Signed-off-by: Max Filippov <jcmvbkbc@gmail.com>
xtensa: s6000: provide variant_irq_disable prototype

Signed-off-by: Max Filippov <jcmvbkbc@gmail.com>
xtensa: s6000: fix build error in gpio.c

'irq' parameter of function 'set_type' was replaced with
struct irq_data *d in the commit '0e77575 xtensa: Convert s6000 gpio
irq_chip to new functions', but not all uses of 'irq' were replaced with
'd->irq'. Fix that.

Signed-off-by: Max Filippov <jcmvbkbc@gmail.com>
xtensa: s6000: move delay.c to platform

Signed-off-by: Max Filippov <jcmvbkbc@gmail.com>
xtensa: s6000: move platform-specific patches to platforms/s6105

Signed-off-by: Max Filippov <jcmvbkbc@gmail.com>
xtensa: s6105: drop KERNELOFFSET definition

Use generic KERNELOFFSET definition from asm/vectors.h instead.

Signed-off-by: Max Filippov <jcmvbkbc@gmail.com>