Hmm, can I charge Nvidia for this fix?
The only reason you are looking at symbols is to map Nvidia registry
names to module symbols. There are 9 registry names, 4 of which are
#ifdeffed out.
MODULE_PARM(NVreg_resman_debuglevel, "i");
MODULE_PARM(NVreg_VideoMemoryTypeOverride, "i"); #ifdeffed out
MODULE_PARM(NVreg_EnableVia4x, "i");
MODULE_PARM(NVreg_ReqAGPRate, "i"); #ifdeffed out
MODULE_PARM(NVreg_SkipBiosPost, "i"); #ifdeffed out
MODULE_PARM(NVreg_UseKernelAGP, "i");
MODULE_PARM(NVreg_UpdateKernelAGP, "i"); #ifdeffed out
MODULE_PARM(NVreg_ReqAGPSBA, "i");
MODULE_PARM(NVreg_ReqAGPFW, "i");
Simple fix is an array to map names to addresses.
struct {
const char *name;
int *value;
} linux_registry[] = {
{ "resman_debuglevel", &NVreg_resman_debuglevel },
{ "EnableVia4x", &NVreg_EnableVia4x },
{ "UseKernelAGP", &NVreg_UseKernelAGP },
{ "ReqAGPSBA", &NVreg_ReqAGPSBA },
{ "ReqAGPFW", &NVreg_ReqAGPFW },
};
Changing osRegistryLookup to scan that array for the registry name and
return the address of the corresponding variable is left as an exercise
for the reader.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/