Read() Syscall | 32 Bit OS Dev (in C)
Adding a read() syscall to read bytes from files written to by write(), and (almost) reading text files with a 'type' command.
Errata: the memcpy function is still bad, that was mainly the source of not printing all 13 characters in the string.
Next video:
- Making programs load and run again; Fixing graphics modes for all bpp values; and other things
OS Dev playlist:
https://www.youtube.com/playlist?list=PLT7NbkyNWaqajsw8Xh7SP9KJwjfpP8TNX
Git Repos:
Sourcehut: https://git.sr.ht/~queso_fuego/quesos
Github mirror: https://github.com/queso-fuego/amateuros
Repo state at the start of this video:
git clone -n https://github.com/queso-fuego/amateuros
cd amateuros
git checkout cc2870d7c297c1ede4bea2996b28727fc8959acc
Join the Community Discord: https://discord.gg/yKm4T89QFn
Contact:
https://queso_fuego.srht.site/contact.html
- Let me know if there's anything specific you'd like to see!
Outline:
0:00 small changes since last video
2:28 start read() syscall
16:46 add read() test
34:40 add checks for open flags to read() & write()
38:16 add 'type' command to print file to screen
50:09 show a couple bugfixes & coming up/outro
Questions about setup/software/etc.?
Check the FAQ: https://queso_fuego.srht.site/about.html
Music credits:
City Life by Artificial.Music | https://soundcloud.com/artificial-music/
Music promoted by https://www.chosic.com/free-music/all/
Creative Commons CC BY 3.0
https://creativecommons.org/licenses/by/3.0/
#readsyscall #kerneldev #cprogramming