Fork us on GitHub Follow us on Facebook Follow us on Twitter

Changeset b6b02c0 in mainline


Ignore:
Timestamp:
2013-09-01T19:15:59Z (7 years ago)
Author:
Jakub Klama <jakub.klama@…>
Branches:
master
Children:
b77207e, ef9a2a8
Parents:
b886b60
Message:

Initial work on sparc32 architecture support.

  • /boot/arch/sparc32 loosely based on arm32 port
  • /kernel/arch/sparc32 based on abs32le template
  • /uspace/lib/c/arch/sparc32 based on sparc64 implementation with incompatible parts temporarily commented out.

Work currently done:

  • AMBA plug and play support in loader
  • initial MMU setup
  • kernel booting
  • register window traps
  • context_save_arch/context_restore_arch

Completed milestones: M1, M2

Files:
92 added
4 edited

Legend:

Unmodified
Added
Removed
  • HelenOS.config

    rb886b60 rb6b02c0  
    3939@ "mips64" MIPS 64-bit
    4040@ "ppc32" PowerPC 32-bit (iMac G4)
     41@ "sparc32" SPARC v8 (32-bit)
    4142@ "sparc64" Sun UltraSPARC 64-bit
    4243! PLATFORM (choice)
     
    6061@ "generic" Generic Sun workstation or server
    6162! [PLATFORM=sparc64] MACHINE (choice)
     63
     64% Machine type
     65@ "leon3" Gaisler Aeroflex LEON3
     66! [PLATFORM=sarc32] MACHINE (choice)
    6267
    6368% Machine type
     
    8893
    8994% CPU type
     95@ "leon3" Gaisler Aeroflex LEON3
     96! [PLATFORM=sparc32&MACHINE=leon3] PROCESSOR (choice)
     97
     98% CPU type
    9099@ "cortex_a8" ARM Cortex A-8
    91100! [PLATFORM=arm32&(MACHINE=beagleboardxm|MACHINE=beaglebone)] PROCESSOR (choice)
     
    176185! [PLATFORM=sparc64] KARCH (choice)
    177186
     187% Kernel architecture
     188@ "sparc32"
     189! [PLATFORM=sparc32] KARCH (choice)
    178190
    179191## Mapping between platform and user space architecture
     
    223235! [PLATFORM=sparc64] UARCH (choice)
    224236
     237% User space architecture
     238@ "sparc32"
     239! [PLATFORM=sparc32] UARCH (choice)
    225240
    226241## Mapping between platform and boot architecture
     
    270285! [PLATFORM=sparc64] BARCH (choice)
    271286
     287% Boot architecture
     288@ "sparc32"
     289! [PLATFORM=sparc32] BARCH (choice)
    272290
    273291## Mapping between platform and image format
     
    284302@ "binary"
    285303! [PLATFORM=mips64] IMAGE (choice)
    286 
    287304
    288305## Compiler options
     
    310327@ "gcc_native" GNU C Compiler (native)
    311328@ "clang" Clang
    312 ! [PLATFORM=abs32le|PLATFORM=arm32|PLATFORM=sparc64] COMPILER (choice)
     329! [PLATFORM=abs32le|PLATFORM=arm32|PLATFORM=sparc64|PLATFORM=sparc32] COMPILER (choice)
    313330
    314331
     
    337354
    338355% Hierarchical page tables support
    339 ! [PLATFORM=abs32le|PLATFORM=ia32|PLATFORM=amd64|PLATFORM=arm32|PLATFORM=mips32|PLATFORM=ppc32] CONFIG_PAGE_PT (y)
     356! [PLATFORM=abs32le|PLATFORM=ia32|PLATFORM=amd64|PLATFORM=arm32|PLATFORM=mips32|PLATFORM=ppc32|PLATFORM=sparc32] CONFIG_PAGE_PT (y)
    340357
    341358% Page hash table support
     
    343360
    344361% Software integer division support
    345 ! [PLATFORM=abs32le|PLATFORM=ia32|PLATFORM=arm32|PLATFORM=ia64|PLATFORM=mips32|PLATFORM=mips64|PLATFORM=ppc32] CONFIG_SOFTINT (y)
     362! [PLATFORM=abs32le|PLATFORM=ia32|PLATFORM=arm32|PLATFORM=ia64|PLATFORM=mips32|PLATFORM=mips64|PLATFORM=ppc32|PLATFORM=sparc32] CONFIG_SOFTINT (y)
    346363
    347364% ASID support
  • kernel/generic/src/main/main.c

    rb886b60 rb6b02c0  
    166166        config.stack_base = config.base + config.kernel_size;
    167167       
     168        printf("base = 0x%08x\n", config.base);
     169        printf("kernel_size = 0x%08x\n", config.kernel_size);
     170        printf("stack_base = 0x%08x\n", config.stack_base);
     171
    168172        /* Avoid placing stack on top of init */
    169173        size_t i;
  • tools/autotool.py

    rb886b60 rb6b02c0  
    256256                gnu_target = "sparc64-linux-gnu"
    257257                clang_target = "sparc-unknown-linux"
     258
     259        if (config['PLATFORM'] == "sparc32"):
     260                target = config['PLATFORM'];
     261                gnu_target = "sparc-leon3-linux-gnu"
    258262       
    259263        return (target, cc_args, gnu_target, clang_target)
  • uspace/lib/c/include/atomicdflt.h

    rb886b60 rb6b02c0  
    6060static inline bool cas(atomic_t *val, atomic_count_t ov, atomic_count_t nv)
    6161{
    62         return __sync_bool_compare_and_swap(&val->count, ov, nv);
     62// XXX  return __sync_bool_compare_and_swap(&val->count, ov, nv);
     63        return false;
    6364}
    6465#endif
Note: See TracChangeset for help on using the changeset viewer.