Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

190 test task usermode #191

Merged
merged 8 commits into from
Dec 5, 2023
Merged

190 test task usermode #191

merged 8 commits into from
Dec 5, 2023

Conversation

dreamos82
Copy link
Owner

@dreamos82 dreamos82 commented Nov 22, 2023

Close #190

@dreamos82 dreamos82 marked this pull request as draft November 22, 2023 16:11
@dreamos82 dreamos82 marked this pull request as ready for review November 27, 2023 11:18

## Loading the kernel

The kernel is loaded by grub2, using the multibtoo2 specifications.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

multiboo? sounds very spooky.

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ahaha i started it when during the halloween season, lol

@@ -57,7 +57,7 @@ thread_t* create_thread(char* thread_name, void (*_entry_point)(void *), void* a
}

// Every thread need it's kernel stack allocated (aka rsp0 field of the TSS)
new_thread->rsp0 = kmalloc(THREAD_DEFAULT_STACK_SIZE);
new_thread->rsp0 = kmalloc(THREAD_DEFAULT_STACK_SIZE) + THREAD_DEFAULT_STACK_SIZE;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

might be useful to allocate stacks from the vmm, and then you can pass in a flag like VM_STACK - which can automatically return the top address for you (to avoid future errors like this one).

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is a cool idea!
i'll implement it!

@DeanoBurrito DeanoBurrito merged commit 3c1d17c into master Dec 5, 2023
3 checks passed
@DeanoBurrito DeanoBurrito deleted the 190_test_task_usermode branch December 5, 2023 12:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[USERMODE] Create a test task to run in user mode
2 participants