> As I've said before, I think we need to take a step back and refactor
> the console code. I'm concerned that in order to make things work
> with the limited functionality available, it has taken on a certain
> hackish aspect. Shared memory resources need to be encapsulated. Has
> anyone thought about some kind of a DeviceManager or DriverManager?
> Really, the current state of things can be tracked back to the fact
> that we don't have seperate statics for each process yet (the
> System.out hack). Todd, how is the multiprocess support coming? I
> think that is required before we can really make the consoles clean.
JM suggests that we adopt the JavaOS/Business model for managing
resources and drivers. I don't, particularly, want to be the one to write
the re-implementation; and in looking at the specs, it seems as if using
any small part that's applicable to our needs now would entail an
enourmous amount of back-end work.
On the other hand, we clearly do need something to manage
resources. What that might be, I'm not too sure, and furthermore, I think
it will heavily depend on multiprocessing. (I'm not too familiar with the
Java 2 security model -- would it extend cleanly to handle h/w
access/ownership?)
Yes, the console stuff needs to be refactored, but I think not to
too great an extent; on FocusLost(), the console releases its physical
resources, and on FocusGained(), it acquires them. Something ingenous
will have to be arranged in the native code to put kprintf()s by kernel
code in the 'right place' (wherever that might be); with mulitprocessing,
the System.out & err statics can be directed at the appropriate
ConsoleStream, which will just write into its buffer until it gains focus.
I haven't made any progress on multiprocessing, unfortunately; I
wanted to work on that last weekend/this week, but that didn't happen
because I was too busy repairing the carnage I had accidentally wreaked on
my hard drive Saturday morning. I think the basic mechanism should be
relatively easy to code; efficient mechanisms and proper interaction with
Java (esp. class loaders) will most probably take a while.
-_Quinn
_______________________________________________
Kernel maillist - [EMAIL PROTECTED]
http://jos.org/mailman/listinfo/kernel