mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-28 02:32:09 -04:00
Merge branch 'master' into upstream
This commit is contained in:
commit
f630fe2817
1487 changed files with 43462 additions and 15549 deletions
|
|
@ -14,7 +14,6 @@
|
|||
#include <asm/system.h>
|
||||
#include <linux/types.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/string.h>
|
||||
#include <linux/mm.h>
|
||||
#include <linux/socket.h>
|
||||
|
|
|
|||
|
|
@ -30,7 +30,6 @@
|
|||
#include <asm/system.h>
|
||||
#include <linux/types.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/string.h>
|
||||
#include <linux/mm.h>
|
||||
#include <linux/socket.h>
|
||||
|
|
|
|||
|
|
@ -23,7 +23,6 @@
|
|||
#include <linux/module.h>
|
||||
#include <linux/types.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/string.h>
|
||||
#include <linux/mm.h>
|
||||
#include <linux/socket.h>
|
||||
|
|
|
|||
|
|
@ -73,7 +73,7 @@ static struct ctl_table_header *atalk_table_header;
|
|||
|
||||
void atalk_register_sysctl(void)
|
||||
{
|
||||
atalk_table_header = register_sysctl_table(atalk_root_table, 1);
|
||||
atalk_table_header = register_sysctl_table(atalk_root_table);
|
||||
}
|
||||
|
||||
void atalk_unregister_sysctl(void)
|
||||
|
|
|
|||
|
|
@ -4,7 +4,6 @@
|
|||
|
||||
#include <linux/atm.h>
|
||||
#include <linux/atmdev.h>
|
||||
#include <linux/sched.h>
|
||||
#include <asm/uaccess.h>
|
||||
|
||||
#include "signaling.h"
|
||||
|
|
|
|||
|
|
@ -1437,7 +1437,6 @@ static void lane2_associate_ind(struct net_device *dev, u8 *mac_addr,
|
|||
*/
|
||||
|
||||
#include <linux/types.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/timer.h>
|
||||
#include <asm/param.h>
|
||||
#include <asm/atomic.h>
|
||||
|
|
|
|||
|
|
@ -4,7 +4,6 @@
|
|||
|
||||
|
||||
#include <linux/module.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/atmdev.h>
|
||||
#include <linux/capability.h>
|
||||
#include <linux/kernel.h>
|
||||
|
|
|
|||
|
|
@ -12,7 +12,6 @@
|
|||
#include <linux/in.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/module.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/timer.h>
|
||||
#include <linux/string.h>
|
||||
#include <linux/sockios.h>
|
||||
|
|
|
|||
|
|
@ -11,7 +11,6 @@
|
|||
#include <linux/socket.h>
|
||||
#include <linux/in.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/timer.h>
|
||||
#include <linux/string.h>
|
||||
#include <linux/sockios.h>
|
||||
|
|
|
|||
|
|
@ -12,7 +12,6 @@
|
|||
#include <linux/socket.h>
|
||||
#include <linux/in.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/timer.h>
|
||||
#include <linux/string.h>
|
||||
#include <linux/sockios.h>
|
||||
|
|
|
|||
|
|
@ -12,7 +12,6 @@
|
|||
#include <linux/socket.h>
|
||||
#include <linux/in.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/timer.h>
|
||||
#include <linux/string.h>
|
||||
#include <linux/sockios.h>
|
||||
|
|
|
|||
|
|
@ -12,7 +12,6 @@
|
|||
#include <linux/in.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/module.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/spinlock.h>
|
||||
#include <linux/timer.h>
|
||||
#include <linux/string.h>
|
||||
|
|
|
|||
|
|
@ -14,7 +14,6 @@
|
|||
#include <linux/socket.h>
|
||||
#include <linux/in.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/timer.h>
|
||||
#include <linux/string.h>
|
||||
#include <linux/sockios.h>
|
||||
|
|
|
|||
|
|
@ -12,7 +12,6 @@
|
|||
#include <linux/in.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/module.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/timer.h>
|
||||
#include <linux/string.h>
|
||||
#include <linux/sockios.h>
|
||||
|
|
|
|||
|
|
@ -14,7 +14,6 @@
|
|||
#include <linux/in.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/module.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/timer.h>
|
||||
#include <linux/string.h>
|
||||
#include <linux/sockios.h>
|
||||
|
|
|
|||
|
|
@ -19,7 +19,6 @@
|
|||
#include <linux/socket.h>
|
||||
#include <linux/in.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/timer.h>
|
||||
#include <linux/string.h>
|
||||
#include <linux/sockios.h>
|
||||
|
|
|
|||
|
|
@ -11,7 +11,6 @@
|
|||
#include <linux/socket.h>
|
||||
#include <linux/in.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/timer.h>
|
||||
#include <linux/string.h>
|
||||
#include <linux/sockios.h>
|
||||
|
|
|
|||
|
|
@ -14,7 +14,6 @@
|
|||
#include <linux/socket.h>
|
||||
#include <linux/in.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/timer.h>
|
||||
#include <linux/string.h>
|
||||
#include <linux/sockios.h>
|
||||
|
|
|
|||
|
|
@ -14,7 +14,6 @@
|
|||
#include <linux/socket.h>
|
||||
#include <linux/in.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/timer.h>
|
||||
#include <linux/string.h>
|
||||
#include <linux/sockios.h>
|
||||
|
|
|
|||
|
|
@ -13,7 +13,6 @@
|
|||
#include <linux/socket.h>
|
||||
#include <linux/in.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/timer.h>
|
||||
#include <linux/string.h>
|
||||
#include <linux/sockios.h>
|
||||
|
|
|
|||
|
|
@ -245,7 +245,7 @@ void ax25_register_sysctl(void)
|
|||
|
||||
ax25_dir_table[0].child = ax25_table;
|
||||
|
||||
ax25_table_header = register_sysctl_table(ax25_root_table, 1);
|
||||
ax25_table_header = register_sysctl_table(ax25_root_table);
|
||||
}
|
||||
|
||||
void ax25_unregister_sysctl(void)
|
||||
|
|
|
|||
|
|
@ -34,7 +34,6 @@
|
|||
#include <linux/capability.h>
|
||||
#include <linux/errno.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/slab.h>
|
||||
#include <linux/poll.h>
|
||||
#include <linux/fcntl.h>
|
||||
|
|
|
|||
|
|
@ -26,7 +26,6 @@
|
|||
#include <linux/capability.h>
|
||||
#include <linux/errno.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/slab.h>
|
||||
#include <linux/poll.h>
|
||||
#include <linux/fcntl.h>
|
||||
|
|
|
|||
|
|
@ -29,7 +29,6 @@
|
|||
#include <linux/types.h>
|
||||
#include <linux/errno.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/slab.h>
|
||||
#include <linux/poll.h>
|
||||
#include <linux/fcntl.h>
|
||||
|
|
|
|||
|
|
@ -29,7 +29,6 @@
|
|||
#include <linux/types.h>
|
||||
#include <linux/errno.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/slab.h>
|
||||
#include <linux/poll.h>
|
||||
#include <linux/fcntl.h>
|
||||
|
|
|
|||
|
|
@ -30,7 +30,6 @@
|
|||
#include <linux/capability.h>
|
||||
#include <linux/errno.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/slab.h>
|
||||
#include <linux/poll.h>
|
||||
#include <linux/fcntl.h>
|
||||
|
|
|
|||
|
|
@ -26,7 +26,6 @@
|
|||
#include <linux/capability.h>
|
||||
#include <linux/errno.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/slab.h>
|
||||
#include <linux/poll.h>
|
||||
#include <linux/fcntl.h>
|
||||
|
|
|
|||
|
|
@ -108,6 +108,7 @@ static void port_carrier_check(struct work_struct *work)
|
|||
spin_unlock_bh(&br->lock);
|
||||
}
|
||||
done:
|
||||
dev_put(dev);
|
||||
rtnl_unlock();
|
||||
}
|
||||
|
||||
|
|
@ -161,7 +162,8 @@ static void del_nbp(struct net_bridge_port *p)
|
|||
|
||||
dev_set_promiscuity(dev, -1);
|
||||
|
||||
cancel_delayed_work(&p->carrier_check);
|
||||
if (cancel_delayed_work(&p->carrier_check))
|
||||
dev_put(dev);
|
||||
|
||||
spin_lock_bh(&br->lock);
|
||||
br_stp_disable_port(p);
|
||||
|
|
@ -444,7 +446,9 @@ int br_add_if(struct net_bridge *br, struct net_device *dev)
|
|||
spin_lock_bh(&br->lock);
|
||||
br_stp_recalculate_bridge_id(br);
|
||||
br_features_recompute(br);
|
||||
schedule_delayed_work(&p->carrier_check, BR_PORT_DEBOUNCE);
|
||||
if (schedule_delayed_work(&p->carrier_check, BR_PORT_DEBOUNCE))
|
||||
dev_hold(dev);
|
||||
|
||||
spin_unlock_bh(&br->lock);
|
||||
|
||||
dev_set_mtu(br->dev, br_min_mtu(br));
|
||||
|
|
|
|||
|
|
@ -957,7 +957,7 @@ int __init br_netfilter_init(void)
|
|||
if (ret < 0)
|
||||
return ret;
|
||||
#ifdef CONFIG_SYSCTL
|
||||
brnf_sysctl_header = register_sysctl_table(brnf_net_table, 0);
|
||||
brnf_sysctl_header = register_sysctl_table(brnf_net_table);
|
||||
if (brnf_sysctl_header == NULL) {
|
||||
printk(KERN_WARNING
|
||||
"br_netfilter: can't register to sysctl.\n");
|
||||
|
|
|
|||
|
|
@ -56,7 +56,9 @@ static int br_device_event(struct notifier_block *unused, unsigned long event, v
|
|||
|
||||
case NETDEV_CHANGE:
|
||||
if (br->dev->flags & IFF_UP)
|
||||
schedule_delayed_work(&p->carrier_check, BR_PORT_DEBOUNCE);
|
||||
if (schedule_delayed_work(&p->carrier_check,
|
||||
BR_PORT_DEBOUNCE))
|
||||
dev_hold(dev);
|
||||
break;
|
||||
|
||||
case NETDEV_FEAT_CHANGE:
|
||||
|
|
|
|||
|
|
@ -16,7 +16,6 @@
|
|||
*/
|
||||
|
||||
/* used for print_string */
|
||||
#include <linux/sched.h>
|
||||
#include <linux/tty.h>
|
||||
|
||||
#include <linux/kmod.h>
|
||||
|
|
|
|||
|
|
@ -13,7 +13,6 @@
|
|||
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/fs.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/types.h>
|
||||
#include <linux/file.h>
|
||||
#include <linux/icmpv6.h>
|
||||
|
|
|
|||
|
|
@ -27,7 +27,6 @@
|
|||
#include <linux/bitops.h>
|
||||
#include <linux/types.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/string.h>
|
||||
#include <linux/mm.h>
|
||||
#include <linux/socket.h>
|
||||
|
|
|
|||
|
|
@ -12,7 +12,6 @@
|
|||
#include <linux/mm.h>
|
||||
#include <linux/module.h>
|
||||
#include <linux/netdevice.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/skbuff.h>
|
||||
#include <linux/string.h>
|
||||
#include <linux/types.h>
|
||||
|
|
|
|||
|
|
@ -18,7 +18,6 @@
|
|||
|
||||
#include <linux/module.h>
|
||||
#include <linux/types.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/mm.h>
|
||||
#include <linux/fcntl.h>
|
||||
#include <linux/socket.h>
|
||||
|
|
|
|||
|
|
@ -18,7 +18,6 @@
|
|||
|
||||
#include <linux/errno.h>
|
||||
#include <linux/module.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/mm.h>
|
||||
#include <linux/slab.h>
|
||||
|
|
|
|||
|
|
@ -19,7 +19,6 @@
|
|||
#include <linux/kernel.h>
|
||||
#include <linux/module.h>
|
||||
#include <linux/socket.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/netdevice.h>
|
||||
#include <linux/proc_fs.h>
|
||||
#ifdef CONFIG_SYSCTL
|
||||
|
|
@ -2708,7 +2707,7 @@ int neigh_sysctl_register(struct net_device *dev, struct neigh_parms *p,
|
|||
t->neigh_proto_dir[0].child = t->neigh_neigh_dir;
|
||||
t->neigh_root_dir[0].child = t->neigh_proto_dir;
|
||||
|
||||
t->sysctl_header = register_sysctl_table(t->neigh_root_dir, 0);
|
||||
t->sysctl_header = register_sysctl_table(t->neigh_root_dir);
|
||||
if (!t->sysctl_header) {
|
||||
err = -ENOBUFS;
|
||||
goto free_procname;
|
||||
|
|
|
|||
|
|
@ -21,7 +21,6 @@
|
|||
#include <linux/types.h>
|
||||
#include <linux/socket.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/timer.h>
|
||||
#include <linux/string.h>
|
||||
#include <linux/sockios.h>
|
||||
|
|
|
|||
|
|
@ -41,7 +41,6 @@
|
|||
#include <linux/module.h>
|
||||
#include <linux/types.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/mm.h>
|
||||
#include <linux/interrupt.h>
|
||||
#include <linux/in.h>
|
||||
|
|
|
|||
|
|
@ -127,7 +127,7 @@ static struct ctl_table_header *dccp_table_header;
|
|||
|
||||
int __init dccp_sysctl_init(void)
|
||||
{
|
||||
dccp_table_header = register_sysctl_table(dccp_root_table, 1);
|
||||
dccp_table_header = register_sysctl_table(dccp_root_table);
|
||||
|
||||
return dccp_table_header != NULL ? 0 : -ENOMEM;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -261,7 +261,6 @@ static void dn_dev_sysctl_register(struct net_device *dev, struct dn_dev_parms *
|
|||
for(i = 0; i < ARRAY_SIZE(t->dn_dev_vars) - 1; i++) {
|
||||
long offset = (long)t->dn_dev_vars[i].data;
|
||||
t->dn_dev_vars[i].data = ((char *)parms) + offset;
|
||||
t->dn_dev_vars[i].de = NULL;
|
||||
}
|
||||
|
||||
if (dev) {
|
||||
|
|
@ -273,16 +272,12 @@ static void dn_dev_sysctl_register(struct net_device *dev, struct dn_dev_parms *
|
|||
}
|
||||
|
||||
t->dn_dev_dev[0].child = t->dn_dev_vars;
|
||||
t->dn_dev_dev[0].de = NULL;
|
||||
t->dn_dev_conf_dir[0].child = t->dn_dev_dev;
|
||||
t->dn_dev_conf_dir[0].de = NULL;
|
||||
t->dn_dev_proto_dir[0].child = t->dn_dev_conf_dir;
|
||||
t->dn_dev_proto_dir[0].de = NULL;
|
||||
t->dn_dev_root_dir[0].child = t->dn_dev_proto_dir;
|
||||
t->dn_dev_root_dir[0].de = NULL;
|
||||
t->dn_dev_vars[0].extra1 = (void *)dev;
|
||||
|
||||
t->sysctl_header = register_sysctl_table(t->dn_dev_root_dir, 0);
|
||||
t->sysctl_header = register_sysctl_table(t->dn_dev_root_dir);
|
||||
if (t->sysctl_header == NULL)
|
||||
kfree(t);
|
||||
else
|
||||
|
|
|
|||
|
|
@ -50,7 +50,6 @@
|
|||
#include <linux/socket.h>
|
||||
#include <linux/in.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/timer.h>
|
||||
#include <linux/string.h>
|
||||
#include <linux/sockios.h>
|
||||
|
|
|
|||
|
|
@ -43,7 +43,6 @@
|
|||
#include <linux/socket.h>
|
||||
#include <linux/in.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/timer.h>
|
||||
#include <linux/string.h>
|
||||
#include <linux/sockios.h>
|
||||
|
|
|
|||
|
|
@ -491,7 +491,7 @@ static ctl_table dn_root_table[] = {
|
|||
|
||||
void dn_register_sysctl(void)
|
||||
{
|
||||
dn_table_header = register_sysctl_table(dn_root_table, 1);
|
||||
dn_table_header = register_sysctl_table(dn_root_table);
|
||||
}
|
||||
|
||||
void dn_unregister_sysctl(void)
|
||||
|
|
|
|||
|
|
@ -13,7 +13,6 @@
|
|||
|
||||
#include <linux/types.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/string.h>
|
||||
#include <linux/mm.h>
|
||||
#include <linux/socket.h>
|
||||
|
|
|
|||
|
|
@ -40,7 +40,6 @@
|
|||
#include <linux/module.h>
|
||||
#include <linux/types.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/string.h>
|
||||
#include <linux/mm.h>
|
||||
#include <linux/socket.h>
|
||||
|
|
|
|||
|
|
@ -78,7 +78,6 @@
|
|||
#include <linux/types.h>
|
||||
#include <linux/string.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/capability.h>
|
||||
#include <linux/socket.h>
|
||||
#include <linux/sockios.h>
|
||||
|
|
|
|||
|
|
@ -35,7 +35,6 @@
|
|||
#include <linux/module.h>
|
||||
#include <linux/types.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/string.h>
|
||||
#include <linux/mm.h>
|
||||
#include <linux/socket.h>
|
||||
|
|
@ -1577,7 +1576,6 @@ static void devinet_sysctl_register(struct in_device *in_dev,
|
|||
return;
|
||||
for (i = 0; i < ARRAY_SIZE(t->devinet_vars) - 1; i++) {
|
||||
t->devinet_vars[i].data += (char *)p - (char *)&ipv4_devconf;
|
||||
t->devinet_vars[i].de = NULL;
|
||||
}
|
||||
|
||||
if (dev) {
|
||||
|
|
@ -1599,15 +1597,11 @@ static void devinet_sysctl_register(struct in_device *in_dev,
|
|||
|
||||
t->devinet_dev[0].procname = dev_name;
|
||||
t->devinet_dev[0].child = t->devinet_vars;
|
||||
t->devinet_dev[0].de = NULL;
|
||||
t->devinet_conf_dir[0].child = t->devinet_dev;
|
||||
t->devinet_conf_dir[0].de = NULL;
|
||||
t->devinet_proto_dir[0].child = t->devinet_conf_dir;
|
||||
t->devinet_proto_dir[0].de = NULL;
|
||||
t->devinet_root_dir[0].child = t->devinet_proto_dir;
|
||||
t->devinet_root_dir[0].de = NULL;
|
||||
|
||||
t->sysctl_header = register_sysctl_table(t->devinet_root_dir, 0);
|
||||
t->sysctl_header = register_sysctl_table(t->devinet_root_dir);
|
||||
if (!t->sysctl_header)
|
||||
goto free_procname;
|
||||
|
||||
|
|
@ -1641,7 +1635,7 @@ void __init devinet_init(void)
|
|||
rtnetlink_links[PF_INET] = inet_rtnetlink_table;
|
||||
#ifdef CONFIG_SYSCTL
|
||||
devinet_sysctl.sysctl_header =
|
||||
register_sysctl_table(devinet_sysctl.devinet_root_dir, 0);
|
||||
register_sysctl_table(devinet_sysctl.devinet_root_dir);
|
||||
devinet_sysctl_register(NULL, &ipv4_devconf_dflt);
|
||||
#endif
|
||||
}
|
||||
|
|
|
|||
|
|
@ -22,7 +22,6 @@
|
|||
#include <linux/capability.h>
|
||||
#include <linux/types.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/mm.h>
|
||||
#include <linux/string.h>
|
||||
#include <linux/socket.h>
|
||||
|
|
|
|||
|
|
@ -20,7 +20,6 @@
|
|||
#include <linux/bitops.h>
|
||||
#include <linux/types.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/mm.h>
|
||||
#include <linux/string.h>
|
||||
#include <linux/socket.h>
|
||||
|
|
|
|||
|
|
@ -57,7 +57,6 @@
|
|||
#include <asm/bitops.h>
|
||||
#include <linux/types.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/mm.h>
|
||||
#include <linux/string.h>
|
||||
#include <linux/socket.h>
|
||||
|
|
|
|||
|
|
@ -14,7 +14,6 @@
|
|||
#include <linux/interrupt.h>
|
||||
#include <linux/spinlock.h>
|
||||
#include <linux/random.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/timer.h>
|
||||
#include <linux/time.h>
|
||||
#include <linux/kernel.h>
|
||||
|
|
|
|||
|
|
@ -23,7 +23,6 @@
|
|||
|
||||
#include <linux/types.h>
|
||||
#include <linux/mm.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/skbuff.h>
|
||||
#include <linux/ip.h>
|
||||
#include <linux/icmp.h>
|
||||
|
|
|
|||
|
|
@ -13,7 +13,6 @@
|
|||
#include <linux/capability.h>
|
||||
#include <linux/module.h>
|
||||
#include <linux/types.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <asm/uaccess.h>
|
||||
#include <linux/skbuff.h>
|
||||
|
|
|
|||
|
|
@ -49,7 +49,6 @@
|
|||
#include <linux/module.h>
|
||||
#include <linux/types.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/mm.h>
|
||||
#include <linux/string.h>
|
||||
#include <linux/errno.h>
|
||||
|
|
|
|||
|
|
@ -20,7 +20,6 @@
|
|||
#include <linux/module.h>
|
||||
#include <linux/types.h>
|
||||
#include <linux/mm.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/skbuff.h>
|
||||
#include <linux/ip.h>
|
||||
#include <linux/icmp.h>
|
||||
|
|
|
|||
|
|
@ -96,7 +96,6 @@
|
|||
#include <linux/capability.h>
|
||||
#include <linux/module.h>
|
||||
#include <linux/types.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <asm/uaccess.h>
|
||||
#include <linux/skbuff.h>
|
||||
|
|
@ -871,7 +870,7 @@ static int __init ipip_init(void)
|
|||
|
||||
printk(banner);
|
||||
|
||||
if (xfrm4_tunnel_register(&ipip_handler)) {
|
||||
if (xfrm4_tunnel_register(&ipip_handler, AF_INET)) {
|
||||
printk(KERN_INFO "ipip init: can't register tunnel\n");
|
||||
return -EAGAIN;
|
||||
}
|
||||
|
|
@ -893,7 +892,7 @@ static int __init ipip_init(void)
|
|||
err2:
|
||||
free_netdev(ipip_fb_tunnel_dev);
|
||||
err1:
|
||||
xfrm4_tunnel_deregister(&ipip_handler);
|
||||
xfrm4_tunnel_deregister(&ipip_handler, AF_INET);
|
||||
goto out;
|
||||
}
|
||||
|
||||
|
|
@ -913,7 +912,7 @@ static void __exit ipip_destroy_tunnels(void)
|
|||
|
||||
static void __exit ipip_fini(void)
|
||||
{
|
||||
if (xfrm4_tunnel_deregister(&ipip_handler))
|
||||
if (xfrm4_tunnel_deregister(&ipip_handler, AF_INET))
|
||||
printk(KERN_INFO "ipip close: can't deregister tunnel\n");
|
||||
|
||||
rtnl_lock();
|
||||
|
|
|
|||
|
|
@ -31,7 +31,6 @@
|
|||
#include <asm/system.h>
|
||||
#include <asm/uaccess.h>
|
||||
#include <linux/types.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/capability.h>
|
||||
#include <linux/errno.h>
|
||||
#include <linux/timer.h>
|
||||
|
|
|
|||
|
|
@ -2359,7 +2359,7 @@ int ip_vs_control_init(void)
|
|||
proc_net_fops_create("ip_vs", 0, &ip_vs_info_fops);
|
||||
proc_net_fops_create("ip_vs_stats",0, &ip_vs_stats_fops);
|
||||
|
||||
sysctl_header = register_sysctl_table(vs_root_table, 0);
|
||||
sysctl_header = register_sysctl_table(vs_root_table);
|
||||
|
||||
/* Initialize ip_vs_svc_table, ip_vs_svc_fwm_table, ip_vs_rtable */
|
||||
for(idx = 0; idx < IP_VS_SVC_TAB_SIZE; idx++) {
|
||||
|
|
|
|||
|
|
@ -583,7 +583,7 @@ static struct ip_vs_scheduler ip_vs_lblc_scheduler =
|
|||
static int __init ip_vs_lblc_init(void)
|
||||
{
|
||||
INIT_LIST_HEAD(&ip_vs_lblc_scheduler.n_list);
|
||||
sysctl_header = register_sysctl_table(lblc_root_table, 0);
|
||||
sysctl_header = register_sysctl_table(lblc_root_table);
|
||||
return register_ip_vs_scheduler(&ip_vs_lblc_scheduler);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -841,7 +841,7 @@ static struct ip_vs_scheduler ip_vs_lblcr_scheduler =
|
|||
static int __init ip_vs_lblcr_init(void)
|
||||
{
|
||||
INIT_LIST_HEAD(&ip_vs_lblcr_scheduler.n_list);
|
||||
sysctl_header = register_sysctl_table(lblcr_root_table, 0);
|
||||
sysctl_header = register_sysctl_table(lblcr_root_table);
|
||||
#ifdef CONFIG_IP_VS_LBLCR_DEBUG
|
||||
proc_net_create("ip_vs_lblcr", 0, ip_vs_lblcr_getinfo);
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -20,7 +20,6 @@
|
|||
*/
|
||||
|
||||
#include <linux/module.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/spinlock.h>
|
||||
#include <linux/interrupt.h>
|
||||
#include <asm/string.h>
|
||||
|
|
|
|||
|
|
@ -15,7 +15,6 @@
|
|||
#include <asm/system.h>
|
||||
#include <asm/uaccess.h>
|
||||
#include <linux/types.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/errno.h>
|
||||
#include <linux/timer.h>
|
||||
#include <linux/mm.h>
|
||||
|
|
|
|||
|
|
@ -15,7 +15,6 @@
|
|||
#include <asm/system.h>
|
||||
#include <asm/uaccess.h>
|
||||
#include <linux/types.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/errno.h>
|
||||
#include <linux/timer.h>
|
||||
#include <linux/mm.h>
|
||||
|
|
|
|||
|
|
@ -15,7 +15,6 @@
|
|||
#include <asm/system.h>
|
||||
#include <asm/uaccess.h>
|
||||
#include <linux/types.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/errno.h>
|
||||
#include <linux/timer.h>
|
||||
#include <linux/mm.h>
|
||||
|
|
|
|||
|
|
@ -15,7 +15,6 @@
|
|||
#include <asm/system.h>
|
||||
#include <asm/uaccess.h>
|
||||
#include <linux/types.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/errno.h>
|
||||
#include <linux/timer.h>
|
||||
#include <linux/mm.h>
|
||||
|
|
|
|||
|
|
@ -7,7 +7,6 @@
|
|||
*/
|
||||
|
||||
#include <linux/types.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/timer.h>
|
||||
#include <linux/netfilter.h>
|
||||
#include <linux/netfilter_ipv4/ip_conntrack_protocol.h>
|
||||
|
|
|
|||
|
|
@ -7,7 +7,6 @@
|
|||
*/
|
||||
|
||||
#include <linux/types.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/timer.h>
|
||||
#include <linux/netfilter.h>
|
||||
#include <linux/in.h>
|
||||
|
|
|
|||
|
|
@ -14,7 +14,6 @@
|
|||
*/
|
||||
|
||||
#include <linux/types.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/timer.h>
|
||||
#include <linux/interrupt.h>
|
||||
#include <linux/netfilter.h>
|
||||
|
|
@ -623,7 +622,7 @@ static int __init ip_conntrack_proto_sctp_init(void)
|
|||
}
|
||||
|
||||
#ifdef CONFIG_SYSCTL
|
||||
ip_ct_sysctl_header = register_sysctl_table(ip_ct_net_table, 0);
|
||||
ip_ct_sysctl_header = register_sysctl_table(ip_ct_net_table);
|
||||
if (ip_ct_sysctl_header == NULL) {
|
||||
ret = -ENOMEM;
|
||||
printk("ip_conntrack_proto_sctp: can't register to sysctl.\n");
|
||||
|
|
|
|||
|
|
@ -20,7 +20,6 @@
|
|||
*/
|
||||
|
||||
#include <linux/types.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/timer.h>
|
||||
#include <linux/netfilter.h>
|
||||
#include <linux/module.h>
|
||||
|
|
|
|||
|
|
@ -7,7 +7,6 @@
|
|||
*/
|
||||
|
||||
#include <linux/types.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/timer.h>
|
||||
#include <linux/netfilter.h>
|
||||
#include <linux/in.h>
|
||||
|
|
|
|||
|
|
@ -848,7 +848,7 @@ static int __init ip_conntrack_standalone_init(void)
|
|||
goto cleanup_proc_stat;
|
||||
}
|
||||
#ifdef CONFIG_SYSCTL
|
||||
ip_ct_sysctl_header = register_sysctl_table(ip_ct_net_table, 0);
|
||||
ip_ct_sysctl_header = register_sysctl_table(ip_ct_net_table);
|
||||
if (ip_ct_sysctl_header == NULL) {
|
||||
printk("ip_conntrack: can't register to sysctl.\n");
|
||||
ret = -ENOMEM;
|
||||
|
|
|
|||
|
|
@ -693,7 +693,7 @@ static int __init ip_queue_init(void)
|
|||
}
|
||||
|
||||
register_netdevice_notifier(&ipq_dev_notifier);
|
||||
ipq_sysctl_header = register_sysctl_table(ipq_root_table, 0);
|
||||
ipq_sysctl_header = register_sysctl_table(ipq_root_table);
|
||||
|
||||
status = nf_register_queue_handler(PF_INET, &nfqh);
|
||||
if (status < 0) {
|
||||
|
|
|
|||
|
|
@ -80,6 +80,10 @@ static void send_reset(struct sk_buff *oldskb, int hook)
|
|||
nskb->mark = 0;
|
||||
skb_init_secmark(nskb);
|
||||
|
||||
skb_shinfo(nskb)->gso_size = 0;
|
||||
skb_shinfo(nskb)->gso_segs = 0;
|
||||
skb_shinfo(nskb)->gso_type = 0;
|
||||
|
||||
tcph = (struct tcphdr *)((u_int32_t*)nskb->nh.iph + nskb->nh.iph->ihl);
|
||||
|
||||
/* Swap source and dest */
|
||||
|
|
|
|||
|
|
@ -12,7 +12,6 @@
|
|||
*/
|
||||
|
||||
#include <linux/types.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/timer.h>
|
||||
#include <linux/netfilter.h>
|
||||
#include <linux/in.h>
|
||||
|
|
|
|||
|
|
@ -30,7 +30,6 @@
|
|||
#include <linux/module.h>
|
||||
#include <linux/types.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/string.h>
|
||||
#include <linux/socket.h>
|
||||
#include <linux/in.h>
|
||||
|
|
|
|||
|
|
@ -70,7 +70,6 @@
|
|||
#include <linux/bitops.h>
|
||||
#include <linux/types.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/mm.h>
|
||||
#include <linux/bootmem.h>
|
||||
#include <linux/string.h>
|
||||
|
|
|
|||
|
|
@ -481,7 +481,7 @@ static int tcp_transmit_skb(struct sock *sk, struct sk_buff *skb, int clone_it,
|
|||
/* RFC1323: The window in SYN & SYN/ACK segments
|
||||
* is never scaled.
|
||||
*/
|
||||
th->window = htons(tp->rcv_wnd);
|
||||
th->window = htons(min(tp->rcv_wnd, 65535U));
|
||||
} else {
|
||||
th->window = htons(tcp_select_window(sk));
|
||||
}
|
||||
|
|
@ -2160,7 +2160,7 @@ struct sk_buff * tcp_make_synack(struct sock *sk, struct dst_entry *dst,
|
|||
}
|
||||
|
||||
/* RFC1323: The window in SYN & SYN/ACK segments is never scaled. */
|
||||
th->window = htons(req->rcv_wnd);
|
||||
th->window = htons(min(req->rcv_wnd, 65535U));
|
||||
|
||||
TCP_SKB_CB(skb)->when = tcp_time_stamp;
|
||||
tcp_syn_build_options((__be32 *)(th + 1), dst_metric(dst, RTAX_ADVMSS), ireq->tstamp_ok,
|
||||
|
|
|
|||
|
|
@ -14,9 +14,10 @@
|
|||
#include <net/xfrm.h>
|
||||
|
||||
static struct xfrm_tunnel *tunnel4_handlers;
|
||||
static struct xfrm_tunnel *tunnel64_handlers;
|
||||
static DEFINE_MUTEX(tunnel4_mutex);
|
||||
|
||||
int xfrm4_tunnel_register(struct xfrm_tunnel *handler)
|
||||
int xfrm4_tunnel_register(struct xfrm_tunnel *handler, unsigned short family)
|
||||
{
|
||||
struct xfrm_tunnel **pprev;
|
||||
int ret = -EEXIST;
|
||||
|
|
@ -24,7 +25,8 @@ int xfrm4_tunnel_register(struct xfrm_tunnel *handler)
|
|||
|
||||
mutex_lock(&tunnel4_mutex);
|
||||
|
||||
for (pprev = &tunnel4_handlers; *pprev; pprev = &(*pprev)->next) {
|
||||
for (pprev = (family == AF_INET) ? &tunnel4_handlers : &tunnel64_handlers;
|
||||
*pprev; pprev = &(*pprev)->next) {
|
||||
if ((*pprev)->priority > priority)
|
||||
break;
|
||||
if ((*pprev)->priority == priority)
|
||||
|
|
@ -44,14 +46,15 @@ err:
|
|||
|
||||
EXPORT_SYMBOL(xfrm4_tunnel_register);
|
||||
|
||||
int xfrm4_tunnel_deregister(struct xfrm_tunnel *handler)
|
||||
int xfrm4_tunnel_deregister(struct xfrm_tunnel *handler, unsigned short family)
|
||||
{
|
||||
struct xfrm_tunnel **pprev;
|
||||
int ret = -ENOENT;
|
||||
|
||||
mutex_lock(&tunnel4_mutex);
|
||||
|
||||
for (pprev = &tunnel4_handlers; *pprev; pprev = &(*pprev)->next) {
|
||||
for (pprev = (family == AF_INET) ? &tunnel4_handlers : &tunnel64_handlers;
|
||||
*pprev; pprev = &(*pprev)->next) {
|
||||
if (*pprev == handler) {
|
||||
*pprev = handler->next;
|
||||
ret = 0;
|
||||
|
|
@ -86,6 +89,26 @@ drop:
|
|||
return 0;
|
||||
}
|
||||
|
||||
#if defined(CONFIG_IPV6) || defined(CONFIG_IPV6_MODULE)
|
||||
static int tunnel64_rcv(struct sk_buff *skb)
|
||||
{
|
||||
struct xfrm_tunnel *handler;
|
||||
|
||||
if (!pskb_may_pull(skb, sizeof(struct iphdr)))
|
||||
goto drop;
|
||||
|
||||
for (handler = tunnel64_handlers; handler; handler = handler->next)
|
||||
if (!handler->handler(skb))
|
||||
return 0;
|
||||
|
||||
icmp_send(skb, ICMP_DEST_UNREACH, ICMP_PORT_UNREACH, 0);
|
||||
|
||||
drop:
|
||||
kfree_skb(skb);
|
||||
return 0;
|
||||
}
|
||||
#endif
|
||||
|
||||
static void tunnel4_err(struct sk_buff *skb, u32 info)
|
||||
{
|
||||
struct xfrm_tunnel *handler;
|
||||
|
|
@ -101,17 +124,36 @@ static struct net_protocol tunnel4_protocol = {
|
|||
.no_policy = 1,
|
||||
};
|
||||
|
||||
#if defined(CONFIG_IPV6) || defined(CONFIG_IPV6_MODULE)
|
||||
static struct net_protocol tunnel64_protocol = {
|
||||
.handler = tunnel64_rcv,
|
||||
.err_handler = tunnel4_err,
|
||||
.no_policy = 1,
|
||||
};
|
||||
#endif
|
||||
|
||||
static int __init tunnel4_init(void)
|
||||
{
|
||||
if (inet_add_protocol(&tunnel4_protocol, IPPROTO_IPIP)) {
|
||||
printk(KERN_ERR "tunnel4 init: can't add protocol\n");
|
||||
return -EAGAIN;
|
||||
}
|
||||
#if defined(CONFIG_IPV6) || defined(CONFIG_IPV6_MODULE)
|
||||
if (inet_add_protocol(&tunnel64_protocol, IPPROTO_IPV6)) {
|
||||
printk(KERN_ERR "tunnel64 init: can't add protocol\n");
|
||||
inet_del_protocol(&tunnel4_protocol, IPPROTO_IPIP);
|
||||
return -EAGAIN;
|
||||
}
|
||||
#endif
|
||||
return 0;
|
||||
}
|
||||
|
||||
static void __exit tunnel4_fini(void)
|
||||
{
|
||||
#if defined(CONFIG_IPV6) || defined(CONFIG_IPV6_MODULE)
|
||||
if (inet_del_protocol(&tunnel64_protocol, IPPROTO_IPV6))
|
||||
printk(KERN_ERR "tunnel64 close: can't remove protocol\n");
|
||||
#endif
|
||||
if (inet_del_protocol(&tunnel4_protocol, IPPROTO_IPIP))
|
||||
printk(KERN_ERR "tunnel4 close: can't remove protocol\n");
|
||||
}
|
||||
|
|
|
|||
|
|
@ -27,6 +27,7 @@ static int xfrm4_parse_spi(struct sk_buff *skb, u8 nexthdr, __be32 *spi, __be32
|
|||
{
|
||||
switch (nexthdr) {
|
||||
case IPPROTO_IPIP:
|
||||
case IPPROTO_IPV6:
|
||||
*spi = skb->nh.iph->saddr;
|
||||
*seq = 0;
|
||||
return 0;
|
||||
|
|
@ -70,7 +71,8 @@ int xfrm4_rcv_encap(struct sk_buff *skb, __u16 encap_type)
|
|||
if (xfrm_nr == XFRM_MAX_DEPTH)
|
||||
goto drop;
|
||||
|
||||
x = xfrm_state_lookup((xfrm_address_t *)&iph->daddr, spi, iph->protocol, AF_INET);
|
||||
x = xfrm_state_lookup((xfrm_address_t *)&iph->daddr, spi,
|
||||
iph->protocol != IPPROTO_IPV6 ? iph->protocol : IPPROTO_IPIP, AF_INET);
|
||||
if (x == NULL)
|
||||
goto drop;
|
||||
|
||||
|
|
|
|||
|
|
@ -95,6 +95,7 @@ static int xfrm4_tunnel_input(struct xfrm_state *x, struct sk_buff *skb)
|
|||
|
||||
switch(iph->protocol){
|
||||
case IPPROTO_IPIP:
|
||||
break;
|
||||
#if defined(CONFIG_IPV6) || defined (CONFIG_IPV6_MODULE)
|
||||
case IPPROTO_IPV6:
|
||||
break;
|
||||
|
|
|
|||
|
|
@ -64,24 +64,45 @@ static struct xfrm_tunnel xfrm_tunnel_handler = {
|
|||
.priority = 2,
|
||||
};
|
||||
|
||||
#if defined(CONFIG_IPV6) || defined(CONFIG_IPV6_MODULE)
|
||||
static struct xfrm_tunnel xfrm64_tunnel_handler = {
|
||||
.handler = xfrm4_rcv,
|
||||
.err_handler = xfrm_tunnel_err,
|
||||
.priority = 2,
|
||||
};
|
||||
#endif
|
||||
|
||||
static int __init ipip_init(void)
|
||||
{
|
||||
if (xfrm_register_type(&ipip_type, AF_INET) < 0) {
|
||||
printk(KERN_INFO "ipip init: can't add xfrm type\n");
|
||||
return -EAGAIN;
|
||||
}
|
||||
if (xfrm4_tunnel_register(&xfrm_tunnel_handler)) {
|
||||
printk(KERN_INFO "ipip init: can't add xfrm handler\n");
|
||||
|
||||
if (xfrm4_tunnel_register(&xfrm_tunnel_handler, AF_INET)) {
|
||||
printk(KERN_INFO "ipip init: can't add xfrm handler for AF_INET\n");
|
||||
xfrm_unregister_type(&ipip_type, AF_INET);
|
||||
return -EAGAIN;
|
||||
}
|
||||
#if defined(CONFIG_IPV6) || defined(CONFIG_IPV6_MODULE)
|
||||
if (xfrm4_tunnel_register(&xfrm64_tunnel_handler, AF_INET6)) {
|
||||
printk(KERN_INFO "ipip init: can't add xfrm handler for AF_INET6\n");
|
||||
xfrm4_tunnel_deregister(&xfrm_tunnel_handler, AF_INET);
|
||||
xfrm_unregister_type(&ipip_type, AF_INET);
|
||||
return -EAGAIN;
|
||||
}
|
||||
#endif
|
||||
return 0;
|
||||
}
|
||||
|
||||
static void __exit ipip_fini(void)
|
||||
{
|
||||
if (xfrm4_tunnel_deregister(&xfrm_tunnel_handler))
|
||||
printk(KERN_INFO "ipip close: can't remove xfrm handler\n");
|
||||
#if defined(CONFIG_IPV6) || defined(CONFIG_IPV6_MODULE)
|
||||
if (xfrm4_tunnel_deregister(&xfrm64_tunnel_handler, AF_INET6))
|
||||
printk(KERN_INFO "ipip close: can't remove xfrm handler for AF_INET6\n");
|
||||
#endif
|
||||
if (xfrm4_tunnel_deregister(&xfrm_tunnel_handler, AF_INET))
|
||||
printk(KERN_INFO "ipip close: can't remove xfrm handler for AF_INET\n");
|
||||
if (xfrm_unregister_type(&ipip_type, AF_INET) < 0)
|
||||
printk(KERN_INFO "ipip close: can't remove xfrm type\n");
|
||||
}
|
||||
|
|
|
|||
|
|
@ -156,6 +156,7 @@ config INET6_XFRM_MODE_ROUTEOPTIMIZATION
|
|||
config IPV6_SIT
|
||||
tristate "IPv6: IPv6-in-IPv4 tunnel (SIT driver)"
|
||||
depends on IPV6
|
||||
select INET_TUNNEL
|
||||
default y
|
||||
---help---
|
||||
Tunneling means encapsulating data of one protocol type within
|
||||
|
|
|
|||
|
|
@ -44,7 +44,6 @@
|
|||
#include <linux/types.h>
|
||||
#include <linux/socket.h>
|
||||
#include <linux/sockios.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/net.h>
|
||||
#include <linux/in6.h>
|
||||
#include <linux/netdevice.h>
|
||||
|
|
@ -3999,7 +3998,6 @@ static void addrconf_sysctl_register(struct inet6_dev *idev, struct ipv6_devconf
|
|||
return;
|
||||
for (i=0; t->addrconf_vars[i].data; i++) {
|
||||
t->addrconf_vars[i].data += (char*)p - (char*)&ipv6_devconf;
|
||||
t->addrconf_vars[i].de = NULL;
|
||||
t->addrconf_vars[i].extra1 = idev; /* embedded; no ref */
|
||||
}
|
||||
if (dev) {
|
||||
|
|
@ -4022,15 +4020,11 @@ static void addrconf_sysctl_register(struct inet6_dev *idev, struct ipv6_devconf
|
|||
t->addrconf_dev[0].procname = dev_name;
|
||||
|
||||
t->addrconf_dev[0].child = t->addrconf_vars;
|
||||
t->addrconf_dev[0].de = NULL;
|
||||
t->addrconf_conf_dir[0].child = t->addrconf_dev;
|
||||
t->addrconf_conf_dir[0].de = NULL;
|
||||
t->addrconf_proto_dir[0].child = t->addrconf_conf_dir;
|
||||
t->addrconf_proto_dir[0].de = NULL;
|
||||
t->addrconf_root_dir[0].child = t->addrconf_proto_dir;
|
||||
t->addrconf_root_dir[0].de = NULL;
|
||||
|
||||
t->sysctl_header = register_sysctl_table(t->addrconf_root_dir, 0);
|
||||
t->sysctl_header = register_sysctl_table(t->addrconf_root_dir);
|
||||
if (t->sysctl_header == NULL)
|
||||
goto free_procname;
|
||||
else
|
||||
|
|
@ -4115,7 +4109,7 @@ int __init addrconf_init(void)
|
|||
rtnetlink_links[PF_INET6] = inet6_rtnetlink_table;
|
||||
#ifdef CONFIG_SYSCTL
|
||||
addrconf_sysctl.sysctl_header =
|
||||
register_sysctl_table(addrconf_sysctl.addrconf_root_dir, 0);
|
||||
register_sysctl_table(addrconf_sysctl.addrconf_root_dir);
|
||||
addrconf_sysctl_register(NULL, &ipv6_devconf_dflt);
|
||||
#endif
|
||||
|
||||
|
|
|
|||
|
|
@ -28,7 +28,6 @@
|
|||
#include <linux/socket.h>
|
||||
#include <linux/in.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/timer.h>
|
||||
#include <linux/string.h>
|
||||
#include <linux/sockios.h>
|
||||
|
|
|
|||
|
|
@ -21,7 +21,6 @@
|
|||
#include <linux/string.h>
|
||||
#include <linux/socket.h>
|
||||
#include <linux/sockios.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/net.h>
|
||||
#include <linux/in6.h>
|
||||
#include <linux/netdevice.h>
|
||||
|
|
|
|||
|
|
@ -17,7 +17,6 @@
|
|||
#include <linux/errno.h>
|
||||
#include <linux/types.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/interrupt.h>
|
||||
#include <linux/socket.h>
|
||||
#include <linux/sockios.h>
|
||||
|
|
|
|||
|
|
@ -27,7 +27,6 @@
|
|||
#include <linux/types.h>
|
||||
#include <linux/socket.h>
|
||||
#include <linux/sockios.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/net.h>
|
||||
#include <linux/netdevice.h>
|
||||
#include <linux/in6.h>
|
||||
|
|
|
|||
|
|
@ -37,7 +37,6 @@
|
|||
#include <linux/socket.h>
|
||||
#include <linux/in.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/sockios.h>
|
||||
#include <linux/net.h>
|
||||
#include <linux/skbuff.h>
|
||||
|
|
|
|||
|
|
@ -172,7 +172,7 @@ static int __inet6_check_established(struct inet_timewait_death_row *death_row,
|
|||
const struct in6_addr *saddr = &np->daddr;
|
||||
const int dif = sk->sk_bound_dev_if;
|
||||
const __portpair ports = INET_COMBINED_PORTS(inet->dport, lport);
|
||||
const unsigned int hash = inet6_ehashfn(daddr, inet->num, saddr,
|
||||
const unsigned int hash = inet6_ehashfn(daddr, lport, saddr,
|
||||
inet->dport);
|
||||
struct inet_ehash_bucket *head = inet_ehash_bucket(hinfo, hash);
|
||||
struct sock *sk2;
|
||||
|
|
|
|||
|
|
@ -25,7 +25,6 @@
|
|||
#include <linux/types.h>
|
||||
#include <linux/socket.h>
|
||||
#include <linux/sockios.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/net.h>
|
||||
#include <linux/netdevice.h>
|
||||
#include <linux/in6.h>
|
||||
|
|
|
|||
|
|
@ -1128,7 +1128,7 @@ static int __init ip6_tunnel_init(void)
|
|||
{
|
||||
int err;
|
||||
|
||||
if (xfrm6_tunnel_register(&ip6ip6_handler)) {
|
||||
if (xfrm6_tunnel_register(&ip6ip6_handler, AF_INET6)) {
|
||||
printk(KERN_ERR "ip6ip6 init: can't register tunnel\n");
|
||||
return -EAGAIN;
|
||||
}
|
||||
|
|
@ -1147,7 +1147,7 @@ static int __init ip6_tunnel_init(void)
|
|||
}
|
||||
return 0;
|
||||
fail:
|
||||
xfrm6_tunnel_deregister(&ip6ip6_handler);
|
||||
xfrm6_tunnel_deregister(&ip6ip6_handler, AF_INET6);
|
||||
return err;
|
||||
}
|
||||
|
||||
|
|
@ -1171,7 +1171,7 @@ static void __exit ip6ip6_destroy_tunnels(void)
|
|||
|
||||
static void __exit ip6_tunnel_cleanup(void)
|
||||
{
|
||||
if (xfrm6_tunnel_deregister(&ip6ip6_handler))
|
||||
if (xfrm6_tunnel_deregister(&ip6ip6_handler, AF_INET6))
|
||||
printk(KERN_INFO "ip6ip6 close: can't deregister tunnel\n");
|
||||
|
||||
rtnl_lock();
|
||||
|
|
|
|||
|
|
@ -31,7 +31,6 @@
|
|||
#include <linux/types.h>
|
||||
#include <linux/socket.h>
|
||||
#include <linux/sockios.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/net.h>
|
||||
#include <linux/in6.h>
|
||||
#include <linux/netdevice.h>
|
||||
|
|
|
|||
|
|
@ -683,7 +683,7 @@ static int __init ip6_queue_init(void)
|
|||
}
|
||||
|
||||
register_netdevice_notifier(&ipq_dev_notifier);
|
||||
ipq_sysctl_header = register_sysctl_table(ipq_root_table, 0);
|
||||
ipq_sysctl_header = register_sysctl_table(ipq_root_table);
|
||||
|
||||
status = nf_register_queue_handler(PF_INET6, &nfqh);
|
||||
if (status < 0) {
|
||||
|
|
|
|||
|
|
@ -17,7 +17,6 @@
|
|||
*/
|
||||
|
||||
#include <linux/types.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/timer.h>
|
||||
#include <linux/module.h>
|
||||
#include <linux/netfilter.h>
|
||||
|
|
|
|||
|
|
@ -17,7 +17,6 @@
|
|||
* as published by the Free Software Foundation; either version
|
||||
* 2 of the License, or (at your option) any later version.
|
||||
*/
|
||||
#include <linux/sched.h>
|
||||
#include <linux/socket.h>
|
||||
#include <linux/net.h>
|
||||
#include <linux/ipv6.h>
|
||||
|
|
|
|||
|
|
@ -27,7 +27,6 @@
|
|||
#include <linux/types.h>
|
||||
#include <linux/socket.h>
|
||||
#include <linux/sockios.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/net.h>
|
||||
#include <linux/in6.h>
|
||||
#include <linux/netdevice.h>
|
||||
|
|
|
|||
|
|
@ -24,7 +24,6 @@
|
|||
#include <linux/types.h>
|
||||
#include <linux/socket.h>
|
||||
#include <linux/sockios.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/net.h>
|
||||
#include <linux/in6.h>
|
||||
#include <linux/netdevice.h>
|
||||
|
|
|
|||
|
|
@ -24,7 +24,6 @@
|
|||
#include <linux/types.h>
|
||||
#include <linux/socket.h>
|
||||
#include <linux/sockios.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/net.h>
|
||||
#include <linux/in6.h>
|
||||
#include <linux/netdevice.h>
|
||||
|
|
@ -216,7 +215,7 @@ static void ipip6_tunnel_uninit(struct net_device *dev)
|
|||
}
|
||||
|
||||
|
||||
static void ipip6_err(struct sk_buff *skb, u32 info)
|
||||
static int ipip6_err(struct sk_buff *skb, u32 info)
|
||||
{
|
||||
#ifndef I_WISH_WORLD_WERE_PERFECT
|
||||
|
||||
|
|
@ -228,21 +227,22 @@ static void ipip6_err(struct sk_buff *skb, u32 info)
|
|||
int type = skb->h.icmph->type;
|
||||
int code = skb->h.icmph->code;
|
||||
struct ip_tunnel *t;
|
||||
int err;
|
||||
|
||||
switch (type) {
|
||||
default:
|
||||
case ICMP_PARAMETERPROB:
|
||||
return;
|
||||
return 0;
|
||||
|
||||
case ICMP_DEST_UNREACH:
|
||||
switch (code) {
|
||||
case ICMP_SR_FAILED:
|
||||
case ICMP_PORT_UNREACH:
|
||||
/* Impossible event. */
|
||||
return;
|
||||
return 0;
|
||||
case ICMP_FRAG_NEEDED:
|
||||
/* Soft state for pmtu is maintained by IP core. */
|
||||
return;
|
||||
return 0;
|
||||
default:
|
||||
/* All others are translated to HOST_UNREACH.
|
||||
rfc2003 contains "deep thoughts" about NET_UNREACH,
|
||||
|
|
@ -253,14 +253,18 @@ static void ipip6_err(struct sk_buff *skb, u32 info)
|
|||
break;
|
||||
case ICMP_TIME_EXCEEDED:
|
||||
if (code != ICMP_EXC_TTL)
|
||||
return;
|
||||
return 0;
|
||||
break;
|
||||
}
|
||||
|
||||
err = -ENOENT;
|
||||
|
||||
read_lock(&ipip6_lock);
|
||||
t = ipip6_tunnel_lookup(iph->daddr, iph->saddr);
|
||||
if (t == NULL || t->parms.iph.daddr == 0)
|
||||
goto out;
|
||||
|
||||
err = 0;
|
||||
if (t->parms.iph.ttl == 0 && type == ICMP_TIME_EXCEEDED)
|
||||
goto out;
|
||||
|
||||
|
|
@ -271,7 +275,7 @@ static void ipip6_err(struct sk_buff *skb, u32 info)
|
|||
t->err_time = jiffies;
|
||||
out:
|
||||
read_unlock(&ipip6_lock);
|
||||
return;
|
||||
return err;
|
||||
#else
|
||||
struct iphdr *iph = (struct iphdr*)dp;
|
||||
int hlen = iph->ihl<<2;
|
||||
|
|
@ -332,7 +336,7 @@ out:
|
|||
/* Prepare fake skb to feed it to icmpv6_send */
|
||||
skb2 = skb_clone(skb, GFP_ATOMIC);
|
||||
if (skb2 == NULL)
|
||||
return;
|
||||
return 0;
|
||||
dst_release(skb2->dst);
|
||||
skb2->dst = NULL;
|
||||
skb_pull(skb2, skb->data - (u8*)iph6);
|
||||
|
|
@ -355,7 +359,7 @@ out:
|
|||
}
|
||||
}
|
||||
kfree_skb(skb2);
|
||||
return;
|
||||
return 0;
|
||||
#endif
|
||||
}
|
||||
|
||||
|
|
@ -791,9 +795,10 @@ static int __init ipip6_fb_tunnel_init(struct net_device *dev)
|
|||
return 0;
|
||||
}
|
||||
|
||||
static struct net_protocol sit_protocol = {
|
||||
static struct xfrm_tunnel sit_handler = {
|
||||
.handler = ipip6_rcv,
|
||||
.err_handler = ipip6_err,
|
||||
.priority = 1,
|
||||
};
|
||||
|
||||
static void __exit sit_destroy_tunnels(void)
|
||||
|
|
@ -812,7 +817,7 @@ static void __exit sit_destroy_tunnels(void)
|
|||
|
||||
static void __exit sit_cleanup(void)
|
||||
{
|
||||
inet_del_protocol(&sit_protocol, IPPROTO_IPV6);
|
||||
xfrm4_tunnel_deregister(&sit_handler, AF_INET6);
|
||||
|
||||
rtnl_lock();
|
||||
sit_destroy_tunnels();
|
||||
|
|
@ -826,7 +831,7 @@ static int __init sit_init(void)
|
|||
|
||||
printk(KERN_INFO "IPv6 over IPv4 tunneling driver\n");
|
||||
|
||||
if (inet_add_protocol(&sit_protocol, IPPROTO_IPV6) < 0) {
|
||||
if (xfrm4_tunnel_register(&sit_handler, AF_INET6) < 0) {
|
||||
printk(KERN_INFO "sit init: Can't add protocol\n");
|
||||
return -EAGAIN;
|
||||
}
|
||||
|
|
@ -848,7 +853,7 @@ static int __init sit_init(void)
|
|||
err2:
|
||||
free_netdev(ipip6_fb_tunnel_dev);
|
||||
err1:
|
||||
inet_del_protocol(&sit_protocol, IPPROTO_IPV6);
|
||||
xfrm4_tunnel_deregister(&sit_handler, AF_INET6);
|
||||
goto out;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -107,7 +107,7 @@ static ctl_table ipv6_root_table[] = {
|
|||
|
||||
void ipv6_sysctl_register(void)
|
||||
{
|
||||
ipv6_sysctl_header = register_sysctl_table(ipv6_root_table, 0);
|
||||
ipv6_sysctl_header = register_sysctl_table(ipv6_root_table);
|
||||
}
|
||||
|
||||
void ipv6_sysctl_unregister(void)
|
||||
|
|
|
|||
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue