akaros/kern/arch/x86/types.h
<<
>>
Prefs
   1#pragma once
   2
   3#include <stddef.h>
   4#ifndef LITTLE_ENDIAN
   5#define LITTLE_ENDIAN
   6#endif /* !LITTLE_ENDIAN */
   7
   8// Explicitly-sized versions of integer types
   9typedef __signed char int8_t;
  10typedef unsigned char uint8_t;
  11typedef short int16_t;
  12typedef unsigned short uint16_t;
  13typedef int int32_t;
  14typedef unsigned int uint32_t;
  15typedef long long int64_t;
  16typedef unsigned long long uint64_t;
  17
  18typedef long ssize_t;
  19typedef int pid_t;
  20typedef int uid_t;
  21typedef int gid_t;
  22
  23#define NUM_ADDR_BITS 64
  24#define BITS_PER_LONG 64
  25#define MAX_VADDR     ((uint64_t)(~0) >> (64-NUM_ADDR_BITS))
  26typedef uint64_t uintptr_t;
  27typedef int64_t intptr_t;
  28#define PAGE_SHIFT 12
  29#define PAGE_SIZE (1<<PAGE_SHIFT)
  30#define PAGE_MASK 0xFFFFFFFFfffff000
  31