[openbeosstorage] Re: Syscall Multiplexing

> > > Why do you think it has to be demultiplexed internally again?
> > For the syscalls for the actual operations (move, resize,...) there's
> > no
> > question, since the DDM carries out these operations (on the shadow
> > partitions), not the modules.
> > 
> > That leaves the _kern_supports_*() and _kern_validate_*() calls. Of
> > the
> > latter type exist only seven, all just invoking reusable functions
> > (as
> > mentioned in my last mail), which one probably doesn't want to
> > multiplex,
> > since their parameters are different enough, that invoking a
> > multiplexed
> > version would be very ugly.
> > 
> > Several of the _kern_supports_*() style syscalls are indeed of the
> > form:
> > 
> >     <preamble>
> >     ...
> >     return diskSystem->SupportsXYZ(partition[,...]);
> > 
> > But others require specific checking (like the ones for resize, move,
> > initialize). The simply-structured ones fall into two categories, one
> > that
> > can be invoked for file systems (and therefore have a `whileMounted'
> > parameter) and those that can't.
> > 
> > So I'm not even sure, if we would do us a favor by multiplexing the
> > _kern_supports_*() calls.
> > 
> > > Or do you mean the final implementation in the module? In this
> > > case,
> > > you'd be right, although it would be less write effort to implement
> > > them :)
> > 
> > Whether I write ten functions or just one with a gigantic switch
> > doesn't
> > make that much of a difference, I think. For clarity one would
> > probably
> > dispatch to separate functions in the first case, anyway.
> > 
> > And not to implement a feature is very easy -- one just puts NULL
> > into the
> > slot for the respective hook. So, a read-only partitioning system
> > like the
> > one for CD sessions will implement only a handful of standard hooks.
> 
> That all sounds as if we should try to not to multiplex them first :-)

Aren't these the reasons for why we agreed to not multiplex them the first 
two times we discussed this :-P :-)? That, and the fact that having a 
single hook per operation makes the interface much more self-documenting.

At any rate, I got absolutely nothing done last week, sorry. I'll try to 
make this week different. 

-Tyler

Other related posts: