Skip to content

Commit 3531841

Browse files
Updated doxygen documents.
1 parent 8d6d299 commit 3531841

File tree

5 files changed

+46
-0
lines changed

5 files changed

+46
-0
lines changed

source/includes/memory2.h

+7
Original file line numberDiff line numberDiff line change
@@ -72,4 +72,11 @@ int memcmp(const void *s1, const void *s2, size_t n);
7272
*/
7373
void memory_dump(const void* start, const void* end);
7474

75+
/**
76+
* @brief Allocates memory at an specific address.
77+
*
78+
* @param phys_addr Physical address to allocate memory.
79+
* @param size Size of the memory to allocate.
80+
* @return Pointer to the allocated memory, or NULL if allocation fails.
81+
*/
7582
void* allocate_memory_at_address(int64 phys_addr, size_t size);

source/includes/secure-boot.h

+4
Original file line numberDiff line numberDiff line change
@@ -10,4 +10,8 @@
1010
*/
1111
#include <basics.h>
1212

13+
/**
14+
* @brief Declaration of the public key used for secure boot.
15+
*
16+
*/
1317
extern cstring public_key;

source/includes/strings2.h

+17
Original file line numberDiff line numberDiff line change
@@ -134,6 +134,15 @@ string strcat(string dest, cstring src);
134134
*/
135135
void remove_last_char(string str);
136136

137+
/**
138+
/**
139+
* @brief Converts a string to a long integer.
140+
*
141+
* @param str The input string to be converted.
142+
* @param endptr Reference to a pointer that will be updated to point to the character after the last valid character.
143+
* @param base The base of the number.
144+
* @return long
145+
*/
137146
long strtol(const char *str, char **endptr, int base);
138147

139148
/**
@@ -159,4 +168,12 @@ char* hex_to_string(signed int num, bool caps);
159168
*/
160169
char* leading_trailing_trim(const char *str);
161170

171+
/**
172+
* @brief Splits a string into tokens based on a delimiter.
173+
*
174+
* @param str The input string to be split.
175+
* @param delim The delimiter character.
176+
* @param num_tokens The number of tokens found.
177+
* @return char** Returns an array of strings containing the tokens.
178+
*/
162179
char** splitf(const char* str, char delim, int* num_tokens);

source/includes/syscalls.h

+14
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,22 @@
1111
#include <basics.h>
1212
#include <isr.h>
1313

14+
/**
15+
* @brief Prefix for the syscalls
16+
*
17+
*/
1418
#define syscalls_prefix "Syscall Invoked: "
1519

20+
/**
21+
* @brief Syscall number for the read syscall
22+
*
23+
* @param num Syscall number.
24+
*/
1625
void invoke_syscall(int64 num);
1726

27+
/**
28+
* @brief Function to handle syscalls.
29+
*
30+
* @param frame The interrupt frame.
31+
*/
1832
void syscalls_handler(InterruptFrame* frame);

source/includes/unifont.h

+4
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,10 @@
1414
#define UNIFONT_WIDTH 8
1515
#define UNIFONT_HEIGHT 16
1616

17+
/**
18+
* @brief Font used for flanterm.
19+
*
20+
*/
1721
static const int8 unifont[] = {
1822
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
1923
0x00, 0x00, 0x00, 0x00, 0x3c, 0x42, 0x81, 0xa5, 0x81, 0xa5, 0x99, 0x42, 0x3c, 0x00, 0x00, 0x00,

0 commit comments

Comments
 (0)