Kernel Source Code
- GeniusCobyWalker
- Member
- Posts: 65
- Joined: Mon Jan 12, 2009 4:17 pm
Kernel Source Code
If anyone would like to post their Kernel source as an example to help others post it here.
Looking for example source here it is.
Origonal:
Heres my OS that i'm working on:
http://www.mediafire.com/?my0d80jcg31
(Extremely Basic)
Look over it and see if this helps you at all.
Sorry clicked "New topic" not "Post reply"
Looking for example source here it is.
Origonal:
Heres my OS that i'm working on:
http://www.mediafire.com/?my0d80jcg31
(Extremely Basic)
Look over it and see if this helps you at all.
Sorry clicked "New topic" not "Post reply"
Last edited by GeniusCobyWalker on Tue Jan 20, 2009 3:14 pm, edited 2 times in total.
Full Knowledge in:
GML, Ti-Basic, Zilog Z80 Assembly, SX28 Assembly and Blender
Experience in:
C++,OpenGl,NDS C++,Dark Basic,Dark Basic Pro,Dark Gdk and PSP Coding
Using:
Ubuntu ,GEdit ,NASM ,GCC ,LD ,Bochs
GML, Ti-Basic, Zilog Z80 Assembly, SX28 Assembly and Blender
Experience in:
C++,OpenGl,NDS C++,Dark Basic,Dark Basic Pro,Dark Gdk and PSP Coding
Using:
Ubuntu ,GEdit ,NASM ,GCC ,LD ,Bochs
- Love4Boobies
- Member
- Posts: 2111
- Joined: Fri Mar 07, 2008 5:36 pm
- Location: Bucharest, Romania
Re: I am new and need help please.
Trust me, you will need none of that. It's just a bunch of tutorial copy & pastes, empty files and some files unrelated to the project. And why the heck would you add a ~ after the extensions?GeniusCobyWalker wrote:Heres my OS that i'm working on:
http://www.mediafire.com/?my0d80jcg31
(Extremely Basic)
Look over it and see if this helps you at all.
"Computers in the future may weigh no more than 1.5 tons.", Popular Mechanics (1949)
[ Project UDI ]
[ Project UDI ]
Re: I am new and need help please.
Those generally signify that the file is a backup.And why the heck would you add a ~ after the extensions?
C8H10N4O2 | #446691 | Trust the nodes.
- Love4Boobies
- Member
- Posts: 2111
- Joined: Fri Mar 07, 2008 5:36 pm
- Location: Bucharest, Romania
Re: I am new and need help please.
Ah, ok. Still, I can't see the reason for including those in the archive. Also, check the contents of your files... You will find something a bit... odd...
"Computers in the future may weigh no more than 1.5 tons.", Popular Mechanics (1949)
[ Project UDI ]
[ Project UDI ]
- gzaloprgm
- Member
- Posts: 141
- Joined: Sun Sep 23, 2007 4:53 pm
- Location: Buenos Aires, Argentina
- Contact:
Re: I am new and need help please.
What's the odd thing(s)?
I can only spot these:
Cheers,
Gonzalo
I can only spot these:
- Image size is 109 KB instead of 'normal' 1474560 bytes.
- 'Blank Padding' file isn't filled with zeroes
- Ascii.c contains a keymap
- Keymap is not used anywhere
- No COPYING file (he's using GPL Grub)
- Backup of backup (.*~~) seems useless
- Grub not actually installed
- Code is stolen from other tutorials
Cheers,
Gonzalo
Visit https://gzalo.com : my web site with electronic circuits, articles, schematics, pcb, calculators, and other things related to electronics.
- Love4Boobies
- Member
- Posts: 2111
- Joined: Fri Mar 07, 2008 5:36 pm
- Location: Bucharest, Romania
Re: I am new and need help please.
That's actually a good thing.gzaloprgm wrote:
- Image size is 109 KB instead of 'normal' 1474560 bytes.
gzaloprgm wrote:Am I missing something?
- The use of semicolons after "}"s.
- The lack of optimization in loops.
- The fact that kmain() actually returns.
- Why is the directory full of makefiles?
- Don't even get me started on that batch file (which isn't very convinent to run either, since it has a backup thingamajig after the normal extension). "cat" isn't a Windows program... Besides, this is a bastardized version of the makefile(s). And why is there a copy of it called "build.sh~"?
- The presence of bochsrc.txt (and its backup).
- The fact that loader.s~ and Text.c~ are empty.
- Finally, I see no reason for including 2 files which read the text "blankpadding" 100 times (didn't actually count).
"Computers in the future may weigh no more than 1.5 tons.", Popular Mechanics (1949)
[ Project UDI ]
[ Project UDI ]
- Troy Martin
- Member
- Posts: 1686
- Joined: Fri Apr 18, 2008 4:40 pm
- Location: Langley, Vancouver, BC, Canada
- Contact:
Re: Kernel Source Code
In other words: This "kernel" is crap.
Re: Kernel Source Code
There is nothing wrong if the kernel entry point returns just so long as there is a place for it to return to.The fact that kmain() actually returns.
OS Development Series | Wiki | os | ncc
char c[2]={"\x90\xC3"};int main(){void(*f)()=(void(__cdecl*)(void))(void*)&c;f();}
char c[2]={"\x90\xC3"};int main(){void(*f)()=(void(__cdecl*)(void))(void*)&c;f();}
- Love4Boobies
- Member
- Posts: 2111
- Joined: Fri Mar 07, 2008 5:36 pm
- Location: Bucharest, Romania
Re: Kernel Source Code
Technically, you're right, but it's considered bad practice (esp. if there's more people working on one kernel, since it may be that someone else wrote the part with the Multiboot header). As I already pointed out, "loader.S~" (and friends) is(/are) empty so I guess we'll never know if it's actually a bug ...
"Computers in the future may weigh no more than 1.5 tons.", Popular Mechanics (1949)
[ Project UDI ]
[ Project UDI ]
- piranha
- Member
- Posts: 1391
- Joined: Thu Dec 21, 2006 7:42 pm
- Location: Unknown. Momentum is pretty certain, however.
- Contact:
Re: Kernel Source Code
Well, firstly, we have an OSdev projects page. No need for a topic. Plus, if you want to use all of my code, you may, but don't call it your own. btw, the only reason that I'm saying that you can do it is because I'm bound by the terms of my license file, and the tutorials that I borrowed some code from.If anyone would like to post their Kernel source as an example to help others post it here.
Looking for example source here it is.
Origonal:
Heres my OS that i'm working on:
http://www.mediafire.com/?my0d80jcg31
(Extremely Basic)
Look over it and see if this helps you at all.
Plus, you clicked the wrong button? And you didn't notice when it wanted a topic that something was askew?
-JL
SeaOS: Adding VT-x, networking, and ARM support
dbittman on IRC, @danielbittman on twitter
https://dbittman.github.io
dbittman on IRC, @danielbittman on twitter
https://dbittman.github.io
Re: Kernel Source Code
It is coinsidered bad practice by who? If the OS industry, please share any links if you have anyTechnically, you're right, but it's considered bad practice
OS Development Series | Wiki | os | ncc
char c[2]={"\x90\xC3"};int main(){void(*f)()=(void(__cdecl*)(void))(void*)&c;f();}
char c[2]={"\x90\xC3"};int main(){void(*f)()=(void(__cdecl*)(void))(void*)&c;f();}
- Love4Boobies
- Member
- Posts: 2111
- Joined: Fri Mar 07, 2008 5:36 pm
- Location: Bucharest, Romania
Re: Kernel Source Code
I remember reading this in MIT's 6.828 Operating System Engineering course, some years ago. Most probably in the source code of their example OS (i.e. comment), I can't remember and I'm too lazy to check.
"Computers in the future may weigh no more than 1.5 tons.", Popular Mechanics (1949)
[ Project UDI ]
[ Project UDI ]