#include <linux/module.h>
#include <asm/uaccess.h>
#include <asm/system.h>
-#include <asm/bitops.h>
+#include <linux/bitops.h>
#include <linux/types.h>
#include <linux/kernel.h>
#include <linux/sched.h>
#endif /* CONFIG_IP_MULTIPLE_TABLES */
-void fib_flush(void)
+static void fib_flush(void)
{
int flushed = 0;
#ifdef CONFIG_IP_MULTIPLE_TABLES
int ret;
no_addr = rpf = 0;
- read_lock(&inetdev_lock);
+ rcu_read_lock();
in_dev = __in_dev_get(dev);
if (in_dev) {
no_addr = in_dev->ifa_list == NULL;
rpf = IN_DEV_RPFILTER(in_dev);
}
- read_unlock(&inetdev_lock);
+ rcu_read_unlock();
if (in_dev == NULL)
goto e_inval;
* Handle IP routing ioctl calls. These are used to manipulate the routing tables
*/
-int ip_rt_ioctl(unsigned int cmd, void *arg)
+int ip_rt_ioctl(unsigned int cmd, void __user *arg)
{
int err;
struct kern_rta rta;
return NOTIFY_DONE;
}
-struct notifier_block fib_inetaddr_notifier = {
+static struct notifier_block fib_inetaddr_notifier = {
.notifier_call =fib_inetaddr_event,
};
-struct notifier_block fib_netdev_notifier = {
+static struct notifier_block fib_netdev_notifier = {
.notifier_call =fib_netdev_event,
};