Frage

I have userspace sysctl calls made to sysctl tables configured on a 2.6.24 kernel. I have migrated the sysctl code to 2.6.35 kernel. I'm seeing warning msgs sayg that 'deprecated sysctl warning' when i make sysctl() calls from userspace. The same is workinng on 2.6.24. Does anyone have any idea on this. Also, sysctl handler do_sysctl islocated in sysctl.c in 2.6.24 whereas in 2.6.35 is located in sysctl_binary.c oa

War es hilfreich?

Lösung

The sysctl() system call has long been considered deprecated; indeed the man page has said this for some time:

Or rather... don't call it: use of this system call has long been discouraged, and it is so unloved that it is likely to disappear in a future kernel version. Remove it from your programs now; use the /proc/sys interface instead.

As it says, you should rewrite your userspace portion of the code to use the /proc/sys interface.

Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit StackOverflow
scroll top