On Fri, Aug 29, 2008 at 09:57:10AM -0500, Adam Litke wrote: > On Fri, 2008-08-29 at 15:43 +1000, David Gibson wrote: > > On Wed, Aug 27, 2008 at 09:39:29PM +0000, Adam Litke wrote: > > > In some cases (such as a distro kernel with backported features) > > > libhugetlbfs > > > will be wrong about the presence of a feature. In these rare cases it > > > will be > > > useful to tell the library whether or not the feature is present in the > > > running > > > kernel. > > > > > > Add a string field to 'struct feature' which contains the environment > > > variable > > > to be used for overriding feature detection. __lh_setup_features() will > > > check > > > if an override variable is set for each defined feature. If that > > > variable is > > > "yes" the feature is assumed to be present. If the variable is "no" is it > > > assumed to be absent. All other values are ignored. > > > > Hrm. A separate environment variable for each features seems a bit > > ugly. I was suggesting just a string name for each one, then a single > > environment variable which has a list of those strings to switch the > > features. > > I would be okay with that but the form would have to be something like: > > HUGETLB_FEATURES="private_reservation=yes,some_other_feature=no"
I was assuming something like the convention for gcc -f and -m options, so: HUGETLB_FEATURES="private_reservation,no_some_other_feature" > The [=yes|no] part is necessary so that only specific features that > require an override need to be specified. Any features omitted from the > environment variable would then be probed as normal. > > Mel: Are you okay with this suggestion as well? > -- David Gibson | I'll have my music baroque, and my code david AT gibson.dropbear.id.au | minimalist, thank you. NOT _the_ _other_ | _way_ _around_! http://www.ozlabs.org/~dgibson ------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ _______________________________________________ Libhugetlbfs-devel mailing list Libhugetlbfs-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/libhugetlbfs-devel