Permalink
Switch branches/tags
Nothing to show
Commits on Mar 7, 2014
  1. gdt: add a table abstraction.

    Damien Dejean
    Damien Dejean committed Mar 6, 2014
    The Global Descriptor Table is abstracted by a class that manages its properties
    (alignment, maximum size, etc.). This representation aims to be extended and
    specified to implement the real kernel GDT. Tests are done in Arch library
    tests.
Commits on Mar 6, 2014
  1. gdt: add segment descriptor facility.

    Damien Dejean
    Damien Dejean committed Mar 4, 2014
    Adds a way to easily generate segment descriptor for the global descriptor
    table. Also provides SegmentDescriptor unit tests for validation.
Commits on Mar 3, 2014
  1. Build: protect test generator from empty input.

    Damien Dejean
    Damien Dejean committed Mar 3, 2014
    Ensures that the user declared test header files in LOCAL_TESTS_FILES in build
    specifications to avoid crashing CxxTest code generator.
    
    Testing done: remove header files from Utils' LOCAL_TESTS_FILES and check that
    an error appears when building:
    $ make kernel
    build/parse-module.mk:96: *** Utils: missing test header files in LOCAL_TESTS_FILES.  Stop
    Then restore the variable and build again, everything is OK.
  2. Utils: reintroduce tests.

    Damien Dejean
    Damien Dejean committed Mar 3, 2014
    Restores Utils library tests and fix some compile errors in them.
    
    Testing done: make kernel
    [...]
    TEST  Utils
    Running 13 tests.............OK!
    [...]
  3. Boot: update deprecated comments.

    Damien Dejean
    Damien Dejean committed Mar 3, 2014
    Updates comments on boot requirements:
    - the GDT is a simple identity table
    - the boot fails in crt0 if stage1 returns.
    
    Testing done: build & qemu -kernel out/kernel/Kernel/Kernel.bin
  4. runtime: invert dependency with kernel main.

    Damien Dejean
    Damien Dejean committed Mar 3, 2014
    Inverts dependency between the Kernel and Runtime modules. The kernel_main now
    injects the appropriate Allocator to the Runtime so that the Runtime does not
    now about upper classes/mechanisms in Kernel.
    
    Testing done: qemu -kernel out/kernel/Kernel/Kernel.bin
    Check that no assertions failed.
Commits on Feb 20, 2014
  1. Bootstrap: special location for bootstrap stack.

    Damien Dejean
    Damien Dejean committed Feb 20, 2014
    Locate the boostrap stack in a special location to eae later memory mapping.
    Remove realmode setup and special section.
  2. Build: add optimization flags.

    Damien Dejean
    Damien Dejean committed Feb 20, 2014
    Compile with the standard -O2 optimization flag and enable Link Time
    Optimizations. Fix a uninitialized variable in RawLinkedList implementation.
    
    Testing done: make kernel
    qemu -kernel out/kernel/Kernel/Kernel.bin -m 512
  3. Arch support: remove arch genericity.

    Damien Dejean
    Damien Dejean committed Feb 20, 2014
    Removes support for multiple architecture. This kernel aims to be x86 and will
    be multi-arch with more time and if the sort architecture is correct.
  4. Toolchain: rework kernel build.

    Damien Dejean
    Damien Dejean committed Oct 26, 2013
    Removes unnecessary build steps of genericity to focus on modularity. The build
    system is based on modules declared by Sok.mk files. A module declares its kind,
    the files it wants to build and the build method. The build system parses
    modules makefiles, compute dependencies and generate the output.
    
    Tests are generated as a part of a module if declared with the appropriated
    variables.
    
    Testing done: make clean && make kernel, everything is built.
    make kernel again: nothing to be done.
    All tests passed.
    qemu -kernel out/kernel/Kernel/Kernel.bin -m 512
     -> The kernel boots fine.
Commits on Oct 23, 2013
  1. FrameManager: test instantiation.

    Damien Dejean
    Damien Dejean committed Oct 23, 2013
    Instantiate the FrameManager in the System context to test in a real context.
  2. FrameManager: dedicated frame list.

    Damien Dejean
    Damien Dejean committed Oct 22, 2013
    Implements a frame list, based on RawLinkedList, dedicated to frame management.
    The list allocates its nodes on the boot strap allocator to be as independent as
    possible from standard memory management system.
Commits on Oct 22, 2013
  1. Boot x86: remove kernel offset.

    Damien Dejean
    Damien Dejean committed Oct 22, 2013
    Remove the kernel offset to have a 1G/3G for kernel/userspace mapping. It ease
    the boot process and the memory management.
Commits on Oct 21, 2013
  1. Utils: relocable LinkedList.

    Damien Dejean
    Damien Dejean committed Oct 21, 2013
    Improve LinkedList design to allow allocation on an other heap than the standard
    system heap.
Commits on May 12, 2013
  1. Memory: add a physical memory allocator.

    Damien Dejean
    Damien Dejean committed May 12, 2013
    The FrameManager allows to manage allocation of physical memory pages. This
    allocators aims to be used both from kernel en user side (through the kernel).
    The System class API changed a bit, the boot context structure is injected
    explicitely and a "bootstrap" method do a minimal system initialization.
  2. Utils: add some math utilities.

    Damien Dejean
    Damien Dejean committed May 10, 2013
    Adds a Math class to the Utils library to perform some mathematical operations
    in the kernel. Unit tests provided too.
  3. Utils: add list container interface and implementation.

    Damien Dejean
    Damien Dejean committed May 5, 2013
    The project now provides a Utils library which will provide standard containers
    and tools for the kernel. The library now provides a list container interface,
    a linked list based implementation and unit tests for lists.
Commits on Oct 2, 2012
  1. Compilation: improve library tests depedency.

    ddejean committed Oct 1, 2012
    Improves depedency of the library during the compilation allowing to define
    local compilation flags for test modules.
  2. Memory management: add a system server.

    ddejean committed Oct 1, 2012
    Adds a system serveur that allows to define global new and delete operators in
    the C++ runtime. Indeed as the memory allocator may change during the boot
    process, the system allows the operators to use the current version of the
    allocator to allocate objects. Then the allocator is associated to the object to
    be able to free it, even if the global allocator has changed.
    
    Defines the allocation operators to be able to use new and delete without
    redefining them each time. As in a normal environment.
  3. Stage2: retrieve information from previous stages

    ddejean committed Sep 23, 2012
    Provides a way to retrieve hardware/context information gathered by stages
    before the stage 2. Indeed bootloader and bootstrap process provided and
    installed a boot context before calling stage 2 and it is valuable to get
    these information for further hardware initialization/manipulation.
    
    The implementation is architecture dependant and is provided for x86 only.
  4. Standard library: right NULL definition

    ddejean committed Jul 1, 2012
    Use the standard definition of NULL for C and C++ languages. Fix
    introduced compile errors.
  5. Tools: add a .clang_complete to kernel/

    ddejean committed Jul 1, 2012
    Add a clang_compelete configuration file to allow the vim plugin to work
    with the kernel side of the project.
  6. Memory: add a human full featured panic for tests

    ddejean committed Jul 1, 2012
    Implement a nice panic function that uses the libc backtrace and
    backtrace_symbols functions when an internal assertion occurs during
    tests.
  7. BootstrapAllocator: add a test tear down.

    ddejean committed Jul 1, 2012
    Adds a missing tear down in the test class that resets the allocator between
    test cases.
Commits on Jun 29, 2012
  1. Build: fix incremental build

    ddejean committed Jun 29, 2012
    Ensure that x86 bioscall special compilation rules do not broke the
    incremental part of the build.
  2. Coding style: move du C++ Android's coding style

    ddejean committed Jun 29, 2012
    Choose to use "m" at the beginning of private class members instead of
    "_" as C++ standard coding style.
  3. Bioscall: fix a compilation warning

    ddejean committed Jun 29, 2012
    As the bios call real mode code is located at address 0x2000, we put
    this value in a register and jump to it. But in GAS assembly the
    absolute jump operand must be prefixed by a '*' and it was not the case.
  4. Early allocation: fix allocator initialization/reset

    ddejean committed Jun 29, 2012
    Fix a bug in memset parameters in BootstrapAllocator initialization and
    reset. The cleaning code has been moved in the BuddyAllocator
    constructor as it seems more consistent to reset the allocator state at
    his creation.
Commits on Jun 26, 2012
  1. backtrace: return the number of written entries

    Gaëtan Morin
    Gaëtan Morin committed May 19, 2012
Commits on Jun 16, 2012
  1. Bioscall: adapt to GDT translation.

    ddejean committed Jun 16, 2012
    At early boot stage the kernel is in 3GB virtual memory and the
    translation is done by special segments in the Global Descriptor Table.
    As bioscall have to be done in real mode without virtual adress space,
    the code have been adapted to enter into a proper context before, and
    restore the virtual context after the BIOS call.
Commits on Jun 15, 2012
  1. Build: full library based build

    ddejean committed Jun 14, 2012
    The kernel is fully build with libraries. The linker script allows us to
    find the first file to link so we use it to build the boot part of the
    kernel as a library too. The build chain is simpler than before because
    there is less corner cases.
  2. Architecture dependencies: introduce x86 real mode code.

    ddejean committed Jun 6, 2012
    Bioscall will be needed to probe memory on Intel x86 CPUs, so we'll need
    a piece of code to switch the CPU to real mode and perform bios calls.
    This changeset introduce a switch-to-real-mode code, a code to perform
    bios call and all necessary stuff to separate architecture dependent and
    independent implementation. The build toolchain is now able to manage
    multiple implementations (architectures ?) for same interfaces.
  3. Build dependency: solving incompatibility with libc

    ddejean committed May 18, 2012
    The Memory library depends on assert statement that uses a internal
    panic function. This function does not exists in standard libc so a stub
    have been added in Memory/tests to be compatible with.
  4. CUtils: backtrace and panic functions for error handling

    Gaëtan Morin authored and ddejean committed May 14, 2012
     - backtrace: only x86 (32bits) implementation for now
     - panic:     prints an error message and stack trace, then halts
     - assert:    modified to use panic()
Commits on May 15, 2012
  1. BootstrapAllocator: unit tests.

    ddejean committed May 15, 2012
    Unit tests added for bootstrap allocator, including some utilities in
    BuddyAllocator for testing purpose.