PatchworkOS  2ca1c69
A non-POSIX operating system.
Loading...
Searching...
No Matches
Integer

Integer revision handling. More...

Collaboration diagram for Integer:

Detailed Description

Integer revision handling.

This module handles the varying size of integers in AML, which can be either 32 or 64 bits depending on the ACPI revision.

Macros

#define AML_TRUE   aml_integer_ones()
 AML Boolean true value.
 
#define AML_FALSE   0
 AML Boolean false value.
 

Typedefs

typedef uint64_t aml_uint_t
 AML Integer type.
 

Functions

uint64_t aml_integer_handling_init (void)
 Initialize integer handling.
 
uint8_t aml_integer_byte_size (void) PURE
 Get the byte size of an AML integer.
 
uint8_t aml_integer_bit_size (void) PURE
 Get the bit size of an AML integer.
 
aml_uint_t aml_integer_ones (void) PURE
 Get a mask with all bits set for the current AML integer size.
 

Macro Definition Documentation

◆ AML_TRUE

#define AML_TRUE   aml_integer_ones()

AML Boolean true value.

Definition at line 25 of file integer.h.

◆ AML_FALSE

#define AML_FALSE   0

AML Boolean false value.

Definition at line 30 of file integer.h.

Typedef Documentation

◆ aml_uint_t

AML Integer type.

Definition at line 20 of file integer.h.

Function Documentation

◆ aml_integer_handling_init()

uint64_t aml_integer_handling_init ( void  )

Initialize integer handling.

Returns
On success, 0. On failure, ERR and errno is set.

Definition at line 8 of file integer.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ aml_integer_byte_size()

uint8_t aml_integer_byte_size ( void  )

Get the byte size of an AML integer.

Returns
The byte size of an AML integer (4 or 8).

Definition at line 22 of file integer.c.

Here is the caller graph for this function:

◆ aml_integer_bit_size()

uint8_t aml_integer_bit_size ( void  )

Get the bit size of an AML integer.

Returns
The bit size of an AML integer (32 or 64).

Definition at line 27 of file integer.c.

Here is the caller graph for this function:

◆ aml_integer_ones()

aml_uint_t aml_integer_ones ( void  )

Get a mask with all bits set for the current AML integer size.

Returns
A mask with all bits set for the current AML integer size.

Definition at line 32 of file integer.c.

Here is the caller graph for this function: