About my OS Design
About my OS Design
I Want to know what type of Design it's My OS..
Question:
1) It's good idea to make the multitasker in Daemon Server on Ring 2?
2) Making a Callgate From Ring 3 to Ring 2 and then Syscall from Ring 2 to Ring 0, it's slow?
Question:
1) It's good idea to make the multitasker in Daemon Server on Ring 2?
2) Making a Callgate From Ring 3 to Ring 2 and then Syscall from Ring 2 to Ring 0, it's slow?
Re: About my OS Design
monolithic...
Working On:Bootloader, RWFS Image Program
Leviathan: http://leviathanv.googlecode.com
Kernel:Working on Design Doc
Leviathan: http://leviathanv.googlecode.com
Kernel:Working on Design Doc
Re: About my OS Design
Monolithic use Message Passing? My os does that, can be hybrid?nekros wrote:monolithic...
- Love4Boobies
- Member
- Posts: 2111
- Joined: Fri Mar 07, 2008 5:36 pm
- Location: Bucharest, Romania
Re: About my OS Design
Can you think of any advantages for using rings 1 and 2? What do you base your design decisions on?
"Computers in the future may weigh no more than 1.5 tons.", Popular Mechanics (1949)
[ Project UDI ]
[ Project UDI ]
Re: About my OS Design
Hi,
Cheers,
Brendan
One of the things I'd consider is whether or not a device driver for something like a USB coffee cup warmer actually does need to have access to read/write code and data in all your applications, daemons and other device drivers....Love4Boobies wrote:What do you base your design decisions on?
Cheers,
Brendan
For all things; perfection is, and will always remain, impossible to achieve in practice. However; by striving for perfection we create things that are as perfect as practically possible. Let the pursuit of perfection be our guide.
- Love4Boobies
- Member
- Posts: 2111
- Joined: Fri Mar 07, 2008 5:36 pm
- Location: Bucharest, Romania
Re: About my OS Design
Good call But seriously, should drivers be allowed to directly read or write from/to applications? I think they should make use of the kernel, a special server, whatever safe mechanism you can think of. So your coffee warmer should go with the rest of the other devices to ring 3 where it belongsBrendan wrote:One of the things I'd consider is whether or not a device driver for something like a USB coffee cup warmer actually does need to have access to read/write code and data in all your applications, daemons and other device drivers....Love4Boobies wrote:What do you base your design decisions on?
"Computers in the future may weigh no more than 1.5 tons.", Popular Mechanics (1949)
[ Project UDI ]
[ Project UDI ]
Re: About my OS Design
First of all I would like to point out that if there is no rationale to use all three rings you shouldn't use them. Just because there are three rings does not mean that you have to use all, I think it would be enough to use only ring3 and ring0 (unless you of course has a valid reason to use more). That would make the design more portable.
Is there a difference between driver and hal? I think one should be clear about what these are, since putting two things that could potentially mean the same thing in different places in the architecture could become confusing.
Exactly what do you mean by multitasker? Putting the task/context switching in ring2 is not a good idea.
About call gates I'd use similar reasoning as using all rings, unless you have a rationale for using them you shouldn't use them.
Is there a difference between driver and hal? I think one should be clear about what these are, since putting two things that could potentially mean the same thing in different places in the architecture could become confusing.
Exactly what do you mean by multitasker? Putting the task/context switching in ring2 is not a good idea.
About call gates I'd use similar reasoning as using all rings, unless you have a rationale for using them you shouldn't use them.
Re: About my OS Design
I think this would work, but it may not be the best idea unless you are doing it for experimental purposes. To go from user space to kernel space, youd have to make 3 switches rather than just 1, and there seems to be a lot of unnecessary over head
Re: About my OS Design
My os it's just experimental, i'm trying to use all ring for a security purpouse and also testing my ipc experimental code using the 4 rings
The Diferent between Driver's and hal, it's that the driver doesn't need to readwrite all memory. and also doesn't need to change any system var, like gdt,idt. Also i didn't put the drivers in Ring3, because hal can only be called though Ring (0,1), so any User Application, can't access to an Device, without the interaction of the Daemon -> Driver.
The Diferent between Driver's and hal, it's that the driver doesn't need to readwrite all memory. and also doesn't need to change any system var, like gdt,idt. Also i didn't put the drivers in Ring3, because hal can only be called though Ring (0,1), so any User Application, can't access to an Device, without the interaction of the Daemon -> Driver.
Re: About my OS Design
I'm curious to see how paging will work. (there is only supervisor/user, no 4 ring crap.)
- Brynet-Inc
- Member
- Posts: 2426
- Joined: Tue Oct 17, 2006 9:29 pm
- Libera.chat IRC: brynet
- Location: Canada
- Contact:
Re: About my OS Design
You're in luck, little gadgets like that don't actually follow standards.. they just leech away power without any care in the world.Brendan wrote:Hi,
One of the things I'd consider is whether or not a device driver for something like a USB coffee cup warmer actually does need to have access to read/write code and data in all your applications, daemons and other device drivers....Love4Boobies wrote:What do you base your design decisions on?
Cheers,
Brendan
As for drivers having access to kernel space, in my opinion.. you should write your own drivers and discourage 3rd party ones.
Also, USB devices don't have direct memory access.. unlike Firewire.
Re: About my OS Design
Hi,
You could take advantage of unsuspecting volunteers (while you let device manufacturers take advantage of you); and until your OS becomes popular you won't have much choice, but it's not the sort of arrangement I'd want to be stuck with forever.
Finally, better protection in the OS means faster device driver development - do you want to spend hours trying to find a mystery bug, or do you want the OS to say "Hey, the instruction at FOO tried to do BAR!". If you're relying on volunteers, then you should have the decency to make it as easy as possible for those volunteers to do your work, including providing protection for device drivers so that they don't have to waste as much of their time finding bugs.
Cheers,
Brendan
If there's 1000 device manufacturers creating 10 new devices each year, and if it takes a programmer an average of 1 month to write (and test) each device driver, then how many programmers do you need to employ to keep up? Where are you going to get that kind of money, and how much extra profit will the device manufacturers make by claiming their devices are fully supported by your OS?Brynet-Inc wrote:As for drivers having access to kernel space, in my opinion.. you should write your own drivers and discourage 3rd party ones.
You could take advantage of unsuspecting volunteers (while you let device manufacturers take advantage of you); and until your OS becomes popular you won't have much choice, but it's not the sort of arrangement I'd want to be stuck with forever.
Finally, better protection in the OS means faster device driver development - do you want to spend hours trying to find a mystery bug, or do you want the OS to say "Hey, the instruction at FOO tried to do BAR!". If you're relying on volunteers, then you should have the decency to make it as easy as possible for those volunteers to do your work, including providing protection for device drivers so that they don't have to waste as much of their time finding bugs.
Cheers,
Brendan
For all things; perfection is, and will always remain, impossible to achieve in practice. However; by striving for perfection we create things that are as perfect as practically possible. Let the pursuit of perfection be our guide.
Re: About my OS Design
this will work?earlz wrote:I'm curious to see how paging will work. (there is only supervisor/user, no 4 ring crap.)
Process (Ring 3): Has mapped his own Memory and server Memory for access, when the process call a server function, it's swicth to server AddressSpace, if the function needs a kernel function, it make a syscall to it, if it needs a driver, it will change again the AddressSpace to the Driver, the driver will parse the function, save to a shared buffer, againt switch to the Server AddressSpace, copy the shared Server/Driver Buffer to Process/Server Shared Buffer, and then return the process. Can that work?