GOn Fri, Jan 06, 2017 at 07:54:48PM +0100, Lennart Poettering wrote:
> On Fri, 06.01.17 13:51, Marcelo Tosatti (mtosa...@redhat.com) wrote:
> 
> > > This really doesn't look pretty, neither the approach nor the
> > > implementation...
> > 
> > Suggestions to improve the code or the approach are welcome.
> > 
> > > Is the option actually so complex that calling resctrltool is the only way
> > > to adjust it? What about writing to the resctrlfs directly?
> > 
> > You'll have to deal with the issues that resctrltool deals with,
> > namely:
> > 
> > 1) Filesystem locking.
> > 2) Reading in every directory and the default 
> > directory.
> > 3) Converting the reservation request to proper sizes.
> > 4) Converting:
> >             type=both --> type=data/type=code
> > 
> >             type=data/type=code --> type=both
> > 
> > 4) Finding free space for the reservation.
> > 5) Adjusting the default group reservation.
> > 
> > Since this steps must be performed by every user of
> > CAT (including libvirt which plans to execute resctrltool
> > as well), it was decided its better to maintain this logic
> > in a centralized place.
> 
> Centralized place is fine, but please do this via a proper C library,
> not some tool to shell out...
> 
> Hmm, if I see that correctly, then resctrltool is a python script? I
> am particularly concerned about making systemd indirectly depend on
> Python this way, in particular for something that isn't precisely a
> core functionality of systemd.

Yes its a Python script. Sure, will write a C library for
resctrltool-0.2 and repost the patches.

Thanks.

_______________________________________________
systemd-devel mailing list
systemd-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/systemd-devel

Reply via email to