Changes in / [dc0d8b52:054476d] in mainline


Ignore:
Files:
4 added
4 deleted
16 edited

Legend:

Unmodified
Added
Removed
  • abi/include/abi/asmtool.h

    rdc0d8b52 r054476d  
    4545
    4646#define OBJECT_BEGIN(obj) \
    47         .type obj, @object; \
     47        .type obj STT_OBJECT; \
    4848        SYMBOL_BEGIN(obj)
    4949#define OBJECT_END(obj) \
     
    5151
    5252#define FUNCTION_BEGIN(func) \
    53         .type func, @function; \
     53        .type func STT_FUNC; \
    5454        SYMBOL_BEGIN(func)     
    5555#define FUNCTION_END(func) \
  • boot/Makefile.build

    rdc0d8b52 r054476d  
    3131include Makefile.common
    3232
    33 INCLUDES = generic/include
     33INCLUDES = -Igeneric/include -I$(ROOT_PATH)/abi/include
    3434OPTIMIZATION = 3
    3535
     
    3838LFLAGS = --fatal-warnings
    3939
    40 GCC_CFLAGS = -I$(INCLUDES) -O$(OPTIMIZATION) -imacros $(CONFIG_HEADER) \
     40GCC_CFLAGS = $(INCLUDES) -O$(OPTIMIZATION) -imacros $(CONFIG_HEADER) \
    4141        -fexec-charset=UTF-8 -fwide-exec-charset=UTF-32$(ENDIANESS) \
    4242        -finput-charset=UTF-8 -ffreestanding -fno-builtin -nostdlib -nostdinc \
     
    4545        -pipe
    4646
    47 ICC_CFLAGS = -I$(INCLUDES) -O$(OPTIMIZATION) -imacros $(CONFIG_HEADER) \
     47ICC_CFLAGS = $(INCLUDES) -O$(OPTIMIZATION) -imacros $(CONFIG_HEADER) \
    4848        -ffreestanding -fno-builtin -nostdlib -nostdinc -Wall -Wmissing-prototypes \
    4949        -Werror-implicit-function-declaration -wd170
    5050
    51 CLANG_CFLAGS = -I$(INCLUDES) -O$(OPTIMIZATION) -imacros $(CONFIG_HEADER) \
     51CLANG_CFLAGS = $(INCLUDES) -O$(OPTIMIZATION) -imacros $(CONFIG_HEADER) \
    5252        -fexec-charset=UTF-8 -fwide-exec-charset=UTF-32$(ENDIANESS) \
    5353        -finput-charset=UTF-8 -ffreestanding -fno-builtin -nostdlib -nostdinc \
  • boot/arch/arm32/src/asm.S

    rdc0d8b52 r054476d  
    2727#
    2828
     29#include <abi/asmtool.h>
    2930#include <arch/arch.h>
    3031
    3132.section BOOTSTRAP
    3233
    33 .global start
    34 .global boot_pt
    35 .global boot_stack
    36 .global halt
    37 .global jump_to_kernel
    38 
    39 start:
     34SYMBOL(start)
    4035        ldr sp, =boot_stack
    4136        b bootstrap
    4237
    4338.section BOOTPT
    44 boot_pt:
     39SYMBOL(boot_pt)
    4540        .space PTL0_ENTRIES * PTL0_ENTRY_SIZE
    4641
    4742.section BOOTSTACK
    4843        .space 4096
    49 boot_stack:
     44SYMBOL(boot_stack)
    5045
    5146.text
    5247
    53 halt:
     48FUNCTION_BEGIN(halt)
    5449        b halt
     50FUNCTION_END(halt)
    5551
    56 jump_to_kernel:
     52FUNCTION_BEGIN(jump_to_kernel)
    5753        #
    5854        # Make sure that the I-cache, D-cache and memory are mutually coherent
     
    108104#endif
    109105        mov pc, r0
     106FUNCTION_END(jump_to_kernel)
     107
  • boot/arch/arm32/src/eabi.S

    rdc0d8b52 r054476d  
    2727#
    2828
     29#include <abi/asmtool.h>
     30
    2931.text
    3032
    31 .global __aeabi_idiv
    32 .global __aeabi_uidiv
    33 
    34 .global __aeabi_idivmod
    35 .global __aeabi_uidivmod
    36 
    37 .global __aeabi_ldivmod
    38 .global __aeabi_uldivmod
    39 
    40 __aeabi_idiv:
     33FUNCTION_BEGIN(__aeabi_idiv)
    4134        push {lr}
    4235        bl __divsi3
    4336        pop {lr}
    4437        mov pc, lr
     38FUNCTION_END(__aeabi_idiv)
    4539
    46 __aeabi_uidiv:
     40FUNCTION_BEGIN(__aeabi_uidiv)
    4741        push {lr}
    4842        bl __udivsi3
    4943        pop {lr}
    5044        mov pc, lr
     45FUNCTION_END(__aeabi_uidiv)
    5146
    52 __aeabi_idivmod:
     47FUNCTION_BEGIN(__aeabi_idivmod)
    5348        push {lr}
    5449        sub sp, sp, #12
     
    5954        pop {lr}
    6055        mov pc, lr
     56FUNCTION_END(__aeabi_idivmod)
    6157
    62 __aeabi_uidivmod:
     58FUNCTION_BEGIN(__aeabi_uidivmod)
    6359        push {lr}
    6460        sub sp, sp, #12
     
    6965        pop {lr}
    7066        mov pc, lr
     67FUNCTION_END(__aeabi_uidivmod)
    7168
    72 __aeabi_ldivmod:
     69FUNCTION_BEGIN(__aeabi_ldivmod)
    7370        push {lr}
    7471        sub sp, sp, #24
     
    8077        pop {lr}
    8178        mov pc, lr
     79FUNCTION_END(__aeabi_ldivmod)
    8280
    83 __aeabi_uldivmod:
     81FUNCTION_BEGIN(__aeabi_uldivmod)
    8482        push {lr}
    8583        sub sp, sp, #24
     
    9189        pop {lr}
    9290        mov pc, lr
     91FUNCTION_END(__aeabi_uldivmod)
     92
  • kernel/arch/arm32/Makefile.inc

    rdc0d8b52 r054476d  
    3333ATSIGN = %
    3434
    35 GCC_CFLAGS += -fno-omit-frame-pointer -mapcs-frame -march=$(subst _,-,$(PROCESSOR_ARCH)) -mno-unaligned-access
     35GCC_CFLAGS += -fno-omit-frame-pointer -mapcs-frame -march=$(subst _,-,$(PROCESSOR_ARCH)) -mno-unaligned-access -mfpu=vfpv3
    3636
    3737ifeq ($(CONFIG_FPU),y)
     
    7070ifeq ($(CONFIG_FPU),y)
    7171        ARCH_SOURCES += arch/$(KARCH)/src/fpu_context.c
    72         ARCH_SOURCES += arch/$(KARCH)/src/fpu.s
     72        ARCH_SOURCES += arch/$(KARCH)/src/fpu.S
    7373endif
    7474
  • kernel/arch/arm32/src/asm.S

    rdc0d8b52 r054476d  
    2727 */
    2828
     29#include <abi/asmtool.h>
     30
    2931.text
    3032
    31 .global memcpy_from_uspace
    32 .global memcpy_to_uspace
    33 .global memcpy_from_uspace_failover_address
    34 .global memcpy_to_uspace_failover_address
    35 .global early_putchar
    36 
    37 memcpy_from_uspace:
    38 memcpy_to_uspace:
     33FUNCTION_BEGIN(memcpy_from_uspace)
     34FUNCTION_BEGIN(memcpy_to_uspace)
    3935        add r3, r1, #3
    4036        bic r3, r3, #3
     
    9490                bne 7b
    9591                b 3b
     92FUNCTION_END(memcpy_from_uspace)
     93FUNCTION_END(memcpy_to_uspace)
    9694
    97 memcpy_from_uspace_failover_address:
    98 memcpy_to_uspace_failover_address:
     95SYMBOL(memcpy_from_uspace_failover_address)
     96SYMBOL(memcpy_to_uspace_failover_address)
    9997        mov r0, #0
    10098        ldmia sp!, {r4, r5, pc}
    10199
    102 early_putchar:
     100FUNCTION_BEGIN(early_putchar)
    103101        mov pc, lr
     102FUNCTION_END(early_putchar)
     103
  • kernel/arch/arm32/src/context.S

    rdc0d8b52 r054476d  
    2727#
    2828
     29#include <abi/asmtool.h>
     30
    2931.text   
    3032
    31 .global context_save_arch
    32 .global context_restore_arch
    33 
    34 context_save_arch:
     33FUNCTION_BEGIN(context_save_arch)
    3534        stmfd sp!, {r1}
    3635        mrs r1, cpsr
     
    4443        mov r0, #1
    4544        mov pc, lr
     45FUNCTION_END(context_save_arch)
    4646
    47 
    48 context_restore_arch:
     47FUNCTION_BEGIN(context_restore_arch)
    4948        ldmia r0!, {r4}
    5049        mrs r5, cpsr
     
    5857        mov r0, #0
    5958        mov pc, lr
     59FUNCTION_END(context_restore_arch)
     60
  • kernel/arch/arm32/src/debug/stacktrace_asm.S

    rdc0d8b52 r054476d  
    2727#
    2828
     29#include <abi/asmtool.h>
     30
    2931.text
    3032
    31 .global frame_pointer_get
    32 .global program_counter_get
    33 
    34 frame_pointer_get:
     33FUNCTION_BEGIN(frame_pointer_get)
    3534        mov r0, fp
    3635        mov pc, lr
     36FUNCTION_END(frame_pointer_get)
    3737
    38 program_counter_get:
     38FUNCTION_BEGIN(program_counter_get)
    3939        mov r0, lr
    4040        mov pc, lr
     41FUNCTION_END(program_counter_get)
     42
  • kernel/arch/arm32/src/dummy.S

    rdc0d8b52 r054476d  
    2727#
    2828
     29#include <abi/asmtool.h>
     30
    2931.text
    3032
    31 .global calibrate_delay_loop
    32 .global asm_delay_loop
     33FUNCTION_BEGIN(calibrate_delay_loop)
     34        mov     pc, lr
     35FUNCTION_END(calibrate_delay_loop)
    3336
    34 .global sys_tls_set
    35 .global dummy
    36 
    37 calibrate_delay_loop:
     37FUNCTION_BEGIN(asm_delay_loop)
    3838        mov     pc, lr
    39 
    40 asm_delay_loop:
    41         mov     pc, lr
     39FUNCTION_END(asm_delay_loop)
    4240
    4341# not used on ARM
    44 sys_tls_set:
     42FUNCTION_BEGIN(sys_tls_set)
     43FUNCTION_BEGIN(dummy)
     44        mov pc, lr
     45FUNCTION_END(dummy)
     46FUNCTION_END(sys_tls_set)
    4547
    46 dummy:
    47         mov pc, lr
  • kernel/arch/arm32/src/eabi.S

    rdc0d8b52 r054476d  
    2727#
    2828
     29#include <abi/asmtool.h>
     30
    2931.text
    3032
    31 .global __aeabi_idiv
    32 .global __aeabi_uidiv
    33 
    34 .global __aeabi_idivmod
    35 .global __aeabi_uidivmod
    36 
    37 .global __aeabi_ldivmod
    38 .global __aeabi_uldivmod
    39 
    40 __aeabi_idiv:
     33FUNCTION_BEGIN(__aeabi_idiv)
    4134        push {lr}
    4235        bl __divsi3
    4336        pop {lr}
    4437        mov pc, lr
     38FUNCTION_END(__aeabi_idiv)
    4539
    46 __aeabi_uidiv:
     40FUNCTION_BEGIN(__aeabi_uidiv)
    4741        push {lr}
    4842        bl __udivsi3
    4943        pop {lr}
    5044        mov pc, lr
     45FUNCTION_END(__aeabi_uidiv)
    5146
    52 __aeabi_idivmod:
     47FUNCTION_BEGIN(__aeabi_idivmod)
    5348        push {lr}
    5449        sub sp, sp, #12
     
    5954        pop {lr}
    6055        mov pc, lr
     56FUNCTION_END(__aeabi_idivmod)
    6157
    62 __aeabi_uidivmod:
     58FUNCTION_BEGIN(__aeabi_uidivmod)
    6359        push {lr}
    6460        sub sp, sp, #12
     
    6965        pop {lr}
    7066        mov pc, lr
     67FUNCTION_END(__aeabi_uidivmod)
    7168
    72 __aeabi_ldivmod:
     69FUNCTION_BEGIN(__aeabi_ldivmod)
    7370        push {lr}
    7471        sub sp, sp, #24
     
    8077        pop {lr}
    8178        mov pc, lr
     79FUNCTION_END(__aeabi_ldivmod)
    8280
    83 __aeabi_uldivmod:
     81FUNCTION_BEGIN(__aeabi_uldivmod)
    8482        push {lr}
    8583        sub sp, sp, #24
     
    9189        pop {lr}
    9290        mov pc, lr
     91FUNCTION_END(__aeabi_uldivmod)
     92
  • kernel/arch/arm32/src/exc_handler.S

    rdc0d8b52 r054476d  
    2727#
    2828
     29#include <abi/asmtool.h>
     30
    2931.text   
    30 
    31 .global irq_exception_entry
    32 .global fiq_exception_entry
    33 .global data_abort_exception_entry
    34 .global prefetch_abort_exception_entry
    35 .global undef_instr_exception_entry
    36 .global swi_exception_entry
    37 .global reset_exception_entry
    38 
    3932
    4033# Switches to kernel stack and saves all registers there.
     
    156149.endm
    157150
    158 reset_exception_entry:
     151SYMBOL(reset_exception_entry)
    159152        SAVE_REGS_TO_STACK
    160153        mov r0, #0
     
    163156        LOAD_REGS_FROM_STACK
    164157
    165 irq_exception_entry:
     158SYMBOL(irq_exception_entry)
    166159        sub lr, lr, #4
    167160        SAVE_REGS_TO_STACK
     
    171164        LOAD_REGS_FROM_STACK
    172165
    173 fiq_exception_entry:
     166SYMBOL(fiq_exception_entry)
    174167        sub lr, lr, #4
    175168        SAVE_REGS_TO_STACK
     
    179172        LOAD_REGS_FROM_STACK
    180173
    181 undef_instr_exception_entry:
     174SYMBOL(undef_instr_exception_entry)
    182175        SAVE_REGS_TO_STACK
    183176        mov r0, #1
     
    186179        LOAD_REGS_FROM_STACK
    187180
    188 prefetch_abort_exception_entry:
     181SYMBOL(prefetch_abort_exception_entry)
    189182        sub lr, lr, #4
    190183        SAVE_REGS_TO_STACK
     
    194187        LOAD_REGS_FROM_STACK
    195188
    196 data_abort_exception_entry:
     189SYMBOL(data_abort_exception_entry)
    197190        sub lr, lr, #8
    198191        SAVE_REGS_TO_STACK
     
    202195        LOAD_REGS_FROM_STACK
    203196
    204 swi_exception_entry:
     197SYMBOL(swi_exception_entry)
    205198        ldr r13, =exc_stack
    206199        SAVE_REGS_TO_STACK
  • kernel/arch/arm32/src/start.S

    rdc0d8b52 r054476d  
    2727#
    2828
     29#include <abi/asmtool.h>
    2930#include <arch/asm/boot.h>
    3031
    3132.text
    3233
    33 .global kernel_image_start
    34 .global exc_stack
    35 .global supervisor_sp
    36 
    37 kernel_image_start:
    38 
     34SYMBOL(kernel_image_start)
    3935        # initialize Stack pointer for exception modes
    4036        mrs r4, cpsr
     
    8379
    8480        .space 1024
    85 exc_stack:
     81SYMBOL(exc_stack)
    8682
    87 supervisor_sp:
     83SYMBOL(supervisor_sp)
    8884        .space 4
  • uspace/lib/c/arch/arm32/Makefile.inc

    rdc0d8b52 r054476d  
    2929
    3030ARCH_SOURCES = \
    31         arch/$(UARCH)/src/entry.s \
    32         arch/$(UARCH)/src/entryjmp.s \
    33         arch/$(UARCH)/src/thread_entry.s \
     31        arch/$(UARCH)/src/entry.S \
     32        arch/$(UARCH)/src/entryjmp.S \
     33        arch/$(UARCH)/src/thread_entry.S \
    3434        arch/$(UARCH)/src/syscall.c \
    3535        arch/$(UARCH)/src/fibril.S \
  • uspace/lib/c/arch/arm32/src/eabi.S

    rdc0d8b52 r054476d  
    2727#
    2828
     29#include <abi/asmtool.h>
     30
    2931.text
    3032
    31 .global __aeabi_read_tp
    32 
    33 .global __aeabi_idiv
    34 .global __aeabi_uidiv
    35 
    36 .global __aeabi_idivmod
    37 .global __aeabi_uidivmod
    38 
    39 .global __aeabi_ldivmod
    40 .global __aeabi_uldivmod
    41 
    42 __aeabi_read_tp:
     33FUNCTION_BEGIN(__aeabi_read_tp)
    4334        mov r0, r9
    4435        mov pc, lr
     36FUNCTION_END(__aeabi_read_tp)
    4537
    46 __aeabi_idiv:
     38FUNCTION_BEGIN(__aeabi_idiv)
    4739        push {lr}
    4840        bl __divsi3
    4941        pop {lr}
    5042        mov pc, lr
     43FUNCTION_END(__aeabi_idiv)
    5144
    52 __aeabi_uidiv:
     45FUNCTION_BEGIN(__aeabi_uidiv)
    5346        push {lr}
    5447        bl __udivsi3
    5548        pop {lr}
    5649        mov pc, lr
     50FUNCTION_END(__aeabi_uidiv)
    5751
    58 __aeabi_idivmod:
     52FUNCTION_BEGIN(__aeabi_idivmod)
    5953        push {lr}
    6054        sub sp, sp, #12
     
    6559        pop {lr}
    6660        mov pc, lr
     61FUNCTION_END(__aeabi_idivmod)
    6762
    68 __aeabi_uidivmod:
     63FUNCTION_BEGIN(__aeabi_uidivmod)
    6964        push {lr}
    7065        sub sp, sp, #12
     
    7570        pop {lr}
    7671        mov pc, lr
     72FUNCTION_END(__aeabi_uidivmod)
    7773
    78 __aeabi_ldivmod:
     74FUNCTION_BEGIN(__aeabi_ldivmod)
    7975        push {lr}
    8076        sub sp, sp, #24
     
    8682        pop {lr}
    8783        mov pc, lr
     84FUNCTION_END(__aeabi_ldivmod)
    8885
    89 __aeabi_uldivmod:
     86FUNCTION_BEGIN(__aeabi_uldivmod)
    9087        push {lr}
    9188        sub sp, sp, #24
     
    9794        pop {lr}
    9895        mov pc, lr
     96FUNCTION_END(__aeabi_uldivmod)
     97
  • uspace/lib/c/arch/arm32/src/fibril.S

    rdc0d8b52 r054476d  
    2727#
    2828
     29#include <abi/asmtool.h>
     30
    2931.text
    3032
    31 .global context_save
    32 .global context_restore
    33 
    34 context_save:
     33FUNCTION_BEGIN(context_save)
    3534        stmia r0!, {sp, lr}
    3635        stmia r0!, {r4-r11}
     
    3938        mov r0, #1
    4039        mov pc, lr
     40FUNCTION_END(context_save)
    4141
    42 context_restore:
     42FUNCTION_BEGIN(context_restore)
    4343        ldmia r0!, {sp, lr}
    4444        ldmia r0!, {r4-r11}
     
    4747        mov r0, #0
    4848        mov pc, lr
     49FUNCTION_END(context_restore)
    4950
  • uspace/lib/c/arch/arm32/src/stacktrace_asm.S

    rdc0d8b52 r054476d  
    2727#
    2828
     29#include <abi/asmtool.h>
     30
    2931.text
    3032
    31 .global stacktrace_prepare
    32 .global stacktrace_fp_get
    33 .global stacktrace_pc_get
     33FUNCTION_BEGIN(stacktrace_prepare)
     34        mov pc, lr
     35FUNCTION_END(stacktrace_prepare)
    3436
    35 stacktrace_prepare:
    36         mov pc, lr
    37 
    38 stacktrace_fp_get:
     37FUNCTION_BEGIN(stacktrace_fp_get)
    3938        mov r0, fp
    4039        mov pc, lr
     40FUNCTION_END(stacktrace_fp_get)
    4141
    42 stacktrace_pc_get:
     42FUNCTION_BEGIN(stacktrace_pc_get)
    4343        mov r0, lr
    4444        mov pc, lr
     45FUNCTION_END(stacktrace_pc_get)
     46
Note: See TracChangeset for help on using the changeset viewer.