Message: previous - next
Month: April 2012

knemo - patch to change default backend from 'Nettools' to 'Sys'

From: "David C. Rankin" <drankinatty@...>
Date: Wed, 18 Apr 2012 00:15:25 -0500

  I'm trying to patch knemo to initialize with the Sys backend (as default) for
the package. You have the option to set Nettools or Sys (kernel) providing
network information to the monitor. Sys is much more efficient than Nettools,
but only works for kernels >= 2.6 (which is everybody now). I wouldn't care or
go to the effort is the Nettools backend still worked, but as of the Linux
3.0/3.1 kernels, (as well as later 2.6.X kernels) Nettools doesn't seem to work
forcing the user to find and set the obscure setting to Sys before the module
will work at all. I propose we make 'Sys' the default backend in TDE.

  Hunting and picking through the code, I have found where the default values
are set for the backend as well as the colors for the plotter graph. There were
a couple of structs and constructors involved depending on how knemo was
launched. I have created a patch that does both (1) set the default backend to
sys and (2) change the graph colors a bit so it is readable regardless of
whether there is a dark/light background shown.

  Here is the patch, look it over, engage in discourse and if the yays are
greater than the nays --> push it :) (works with gcc47 too :)

David C. Rankin, J.D.,P.E.