Changeset db3c8834 in mainline


Ignore:
Timestamp:
2018-03-06T18:09:19Z (6 years ago)
Author:
Jiří Zárevúcky <zarevucky.jiri@…>
Children:
95aed62
Parents:
5af6cf3d
Message:

amd64

Location:
uspace/lib/c/arch/amd64
Files:
2 deleted
4 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/c/arch/amd64/Makefile.inc

    r5af6cf3d rdb3c8834  
    3737
    3838ARCH_AUTOGENS_AG = \
    39         arch/$(UARCH)/include/libarch/istate_struct.ag \
    40         arch/$(UARCH)/include/libarch/fibril_context.ag
     39        arch/$(UARCH)/include/libarch/fibril_context.ag.h
    4140
    4241EXTRA_OUTPUT += arch/$(UARCH)/src/entry.o
  • uspace/lib/c/arch/amd64/include/libarch/fibril_context.h

    r5af6cf3d rdb3c8834  
     1/* Copyright (c) 2014 Jakub Jermar
     2 * All rights reserved.
     3 *
     4 * Redistribution and use in source and binary forms, with or without
     5 * modification, are permitted provided that the following conditions
     6 * are met:
     7 *
     8 * - Redistributions of source code must retain the above copyright
     9 *   notice, this list of conditions and the following disclaimer.
     10 * - Redistributions in binary form must reproduce the above copyright
     11 *   notice, this list of conditions and the following disclaimer in the
     12 *   documentation and/or other materials provided with the distribution.
     13 * - The name of the author may not be used to endorse or promote products
     14 *   derived from this software without specific prior written permission.
     15 *
     16 * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
     17 * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
     18 * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
     19 * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
     20 * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
     21 * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
     22 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
     23 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
     24 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
     25 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
     26 */
    127
    2 /*****************************************************************************
    3  * AUTO-GENERATED FILE, DO NOT EDIT!!!
    4  * Generated by: tools/autogen.py
    5  * Generated from: arch/amd64/include/libarch/fibril_context.ag
    6  *****************************************************************************/
     28#pragma once
     29#include <stdint.h>
    730
    8 #ifndef AUTOGEN_CONTEXT_H
    9 #define AUTOGEN_CONTEXT_H
    10 
    11 #ifndef __ASM__
    12 #include <stddef.h>
    13 #include <stdint.h>
    14 #endif
    15 
    16 #define CONTEXT_OFFSET_SP 0
    17 #define CONTEXT_SIZE_SP 8
    18 #define CONTEXT_OFFSET_PC 8
    19 #define CONTEXT_SIZE_PC 8
    20 #define CONTEXT_OFFSET_RBX 16
    21 #define CONTEXT_SIZE_RBX 8
    22 #define CONTEXT_OFFSET_RBP 24
    23 #define CONTEXT_SIZE_RBP 8
    24 #define CONTEXT_OFFSET_R12 32
    25 #define CONTEXT_SIZE_R12 8
    26 #define CONTEXT_OFFSET_R13 40
    27 #define CONTEXT_SIZE_R13 8
    28 #define CONTEXT_OFFSET_R14 48
    29 #define CONTEXT_SIZE_R14 8
    30 #define CONTEXT_OFFSET_R15 56
    31 #define CONTEXT_SIZE_R15 8
    32 #define CONTEXT_OFFSET_TLS 64
    33 #define CONTEXT_SIZE_TLS 8
    34 #define CONTEXT_SIZE 72
    35 
    36 #ifndef __ASM__
    3731typedef struct context {
     32        /* We include only registers that must be preserved
     33         * during function call.
     34         */
    3835        uint64_t sp;
    3936        uint64_t pc;
     
    4643        uint64_t tls;
    4744} context_t;
    48 #endif
    4945
    50 #endif
    51        
  • uspace/lib/c/arch/amd64/include/libarch/istate_struct.h

    • Property mode changed from 100644 to 120000
    r5af6cf3d rdb3c8834  
    1 
    2 /*****************************************************************************
    3  * AUTO-GENERATED FILE, DO NOT EDIT!!!
    4  * Generated by: tools/autogen.py
    5  * Generated from: arch/amd64/include/libarch/istate_struct.ag
    6  *****************************************************************************/
    7 
    8 #ifndef AUTOGEN_ISTATE_H
    9 #define AUTOGEN_ISTATE_H
    10 
    11 #ifndef __ASM__
    12 #ifdef KERNEL
    13 #include <typedefs.h>
    14 #endif
    15 #ifndef KERNEL
    16 #include <stddef.h>
    17 #endif
    18 #ifndef KERNEL
    19 #include <stdint.h>
    20 #endif
    21 #endif
    22 
    23 #define ISTATE_OFFSET_RAX 0
    24 #define ISTATE_SIZE_RAX 8
    25 #define ISTATE_OFFSET_RBX 8
    26 #define ISTATE_SIZE_RBX 8
    27 #define ISTATE_OFFSET_RCX 16
    28 #define ISTATE_SIZE_RCX 8
    29 #define ISTATE_OFFSET_RDX 24
    30 #define ISTATE_SIZE_RDX 8
    31 #define ISTATE_OFFSET_RSI 32
    32 #define ISTATE_SIZE_RSI 8
    33 #define ISTATE_OFFSET_RDI 40
    34 #define ISTATE_SIZE_RDI 8
    35 #define ISTATE_OFFSET_RBP 48
    36 #define ISTATE_SIZE_RBP 8
    37 #define ISTATE_OFFSET_R8 56
    38 #define ISTATE_SIZE_R8 8
    39 #define ISTATE_OFFSET_R9 64
    40 #define ISTATE_SIZE_R9 8
    41 #define ISTATE_OFFSET_R10 72
    42 #define ISTATE_SIZE_R10 8
    43 #define ISTATE_OFFSET_R11 80
    44 #define ISTATE_SIZE_R11 8
    45 #define ISTATE_OFFSET_R12 88
    46 #define ISTATE_SIZE_R12 8
    47 #define ISTATE_OFFSET_R13 96
    48 #define ISTATE_SIZE_R13 8
    49 #define ISTATE_OFFSET_R14 104
    50 #define ISTATE_SIZE_R14 8
    51 #define ISTATE_OFFSET_R15 112
    52 #define ISTATE_SIZE_R15 8
    53 #define ISTATE_OFFSET_ALIGNMENT 120
    54 #define ISTATE_SIZE_ALIGNMENT 8
    55 #define ISTATE_OFFSET_RBP_FRAME 128
    56 #define ISTATE_SIZE_RBP_FRAME 8
    57 #define ISTATE_OFFSET_RIP_FRAME 136
    58 #define ISTATE_SIZE_RIP_FRAME 8
    59 #define ISTATE_OFFSET_ERROR_WORD 144
    60 #define ISTATE_SIZE_ERROR_WORD 8
    61 #define ISTATE_OFFSET_RIP 152
    62 #define ISTATE_SIZE_RIP 8
    63 #define ISTATE_OFFSET_CS 160
    64 #define ISTATE_SIZE_CS 8
    65 #define ISTATE_OFFSET_RFLAGS 168
    66 #define ISTATE_SIZE_RFLAGS 8
    67 #define ISTATE_OFFSET_RSP 176
    68 #define ISTATE_SIZE_RSP 8
    69 #define ISTATE_OFFSET_SS 184
    70 #define ISTATE_SIZE_SS 8
    71 #define ISTATE_SIZE 192
    72 
    73 #ifndef __ASM__
    74 typedef struct istate {
    75         uint64_t rax;
    76         uint64_t rbx;
    77         uint64_t rcx;
    78         uint64_t rdx;
    79         uint64_t rsi;
    80         uint64_t rdi;
    81         uint64_t rbp;
    82         uint64_t r8;
    83         uint64_t r9;
    84         uint64_t r10;
    85         uint64_t r11;
    86         uint64_t r12;
    87         uint64_t r13;
    88         uint64_t r14;
    89         uint64_t r15;
    90         uint64_t alignment;
    91         uint64_t rbp_frame;
    92         uint64_t rip_frame;
    93         uint64_t error_word;
    94         uint64_t rip;
    95         uint64_t cs;
    96         uint64_t rflags;
    97         uint64_t rsp;
    98         uint64_t ss;
    99 } istate_t;
    100 #endif
    101 
    102 #endif
    103        
     1../../../../../../../kernel/arch/amd64/include/arch/istate_struct.h
  • uspace/lib/c/arch/amd64/src/fibril.S

    r5af6cf3d rdb3c8834  
    2828
    2929#include <abi/asmtool.h>
    30 #include <libarch/fibril_context.h>
     30#include <libarch/fibril_context.ag.h>
    3131
    3232.text
Note: See TracChangeset for help on using the changeset viewer.