puppy icon indicating copy to clipboard operation
puppy copied to clipboard

Kernel objects

Open egranata opened this issue 7 years ago • 0 comments

This is much more of a wishlist item that anything concretely actionable at this point, but here's the gist

All long-lived objects in kernel space that represent something that userspace can interact with (so, things like a semaphore, a file, a disk, ...) should be represented as deriving from a common kobject_t base class.

kobject_t would expose:

  • LLVM-style RTTI with globally unique types and a hierarchy (so one would have object, synch_object, semaphore as elements of the hierarchy) - this could probably be defined in (one or more) .tbl file and imported as needed somehow;
  • shared_ptr reference counting semantics;
  • support for being written into logs easily (probably with a custom printf formatter %K);
  • trivial to insert into handle tables and type-checked on extraction from such

egranata avatar Nov 30 '18 23:11 egranata