summaryrefslogtreecommitdiff
path: root/kernel/src/memory.c
diff options
context:
space:
mode:
authorTyler Murphy <=>2023-07-22 11:05:30 -0400
committerTyler Murphy <=>2023-07-22 11:05:30 -0400
commitda094d011f52a8f1ce879810cd1a4bbbe34f08d4 (patch)
tree4649b04705b49c2eb5f8691a5d9951351f65df04 /kernel/src/memory.c
parentrefactoring (diff)
downloadfinix-da094d011f52a8f1ce879810cd1a4bbbe34f08d4.tar.gz
finix-da094d011f52a8f1ce879810cd1a4bbbe34f08d4.tar.bz2
finix-da094d011f52a8f1ce879810cd1a4bbbe34f08d4.zip
paging is not very funHEADmain
Diffstat (limited to 'kernel/src/memory.c')
-rw-r--r--kernel/src/memory.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/kernel/src/memory.c b/kernel/src/memory.c
index e8d864b..57fdd68 100644
--- a/kernel/src/memory.c
+++ b/kernel/src/memory.c
@@ -26,7 +26,7 @@ struct boundary_tag {
#define MODE MODE_BEST
-struct boundary_tag* l_freePages[MAXEXP];
+struct boundary_tag *l_freePages[MAXEXP];
int l_completePages[MAXEXP];
static int l_initialized = 0;
@@ -79,7 +79,7 @@ static inline void remove_tag(struct boundary_tag *tag) {
tag->index = -1;
}
-static inline struct boundary_tag* melt_left(struct boundary_tag *tag) {
+static inline struct boundary_tag *melt_left(struct boundary_tag *tag) {
struct boundary_tag *left = tag->split_left;
left->real_size += tag->real_size;
@@ -91,7 +91,7 @@ static inline struct boundary_tag* melt_left(struct boundary_tag *tag) {
}
-static inline struct boundary_tag* absorb_right(struct boundary_tag *tag) {
+static inline struct boundary_tag *absorb_right(struct boundary_tag *tag) {
struct boundary_tag *right = tag->split_right;
remove_tag(right);
@@ -105,7 +105,7 @@ static inline struct boundary_tag* absorb_right(struct boundary_tag *tag) {
return tag;
}
-static inline struct boundary_tag* split_tag(struct boundary_tag* tag) {
+static inline struct boundary_tag *split_tag(struct boundary_tag *tag) {
unsigned int remainder = tag->real_size - sizeof(struct boundary_tag) - tag->size;
struct boundary_tag *new_tag =
@@ -130,7 +130,7 @@ static inline struct boundary_tag* split_tag(struct boundary_tag* tag) {
return new_tag;
}
-static struct boundary_tag* allocate_new_tag(unsigned int size) {
+static struct boundary_tag *allocate_new_tag(unsigned int size) {
unsigned int pages;
unsigned int usage;
struct boundary_tag *tag;
@@ -268,7 +268,7 @@ void free(void *ptr) {
memory_unlock();
}
-void* calloc(size_t nobj, size_t size) {
+void *calloc(size_t nobj, size_t size) {
int real_size;
void *p;
@@ -281,7 +281,7 @@ void* calloc(size_t nobj, size_t size) {
return p;
}
-void* realloc(void *p, size_t size) {
+void *realloc(void *p, size_t size) {
void *ptr;
struct boundary_tag *tag;
size_t real_size;