lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Wed, 23 Apr 2008 11:04:46 +0100
From:	Ben Hutchings <bhutchings@...arflare.com>
To:	Stephen Hemminger <stephen.hemminger@...tta.com>
Cc:	Kieran Mansley <kmansley@...arflare.com>,
	Stephen Hemminger <shemminger@...tta.com>,
	netdev@...r.kernel.org
Subject: Re: LRO/GSO interaction when packets are forwarded

Stephen Hemminger wrote:
<snip>
> > diff --git a/net/ipv4/devinet.c b/net/ipv4/devinet.c
> > index 6848e47..f88d395 100644
> > --- a/net/ipv4/devinet.c
> > +++ b/net/ipv4/devinet.c
> > @@ -171,6 +171,8 @@ static struct in_device *inetdev_init(struct net_device *dev)
> >  	in_dev->dev = dev;
> >  	if ((in_dev->arp_parms = neigh_parms_alloc(dev, &arp_tbl)) == NULL)
> >  		goto out_kfree;
> > +	if (IPV4_DEVCONF(in_dev->cnf, FORWARDING))
> > +		dev_disable_lro(dev);
> >  	/* Reference in_dev->dev */
> >  	dev_hold(dev);
> >  	/* Account for reference dev->ip_ptr (below) */
> > @@ -1250,6 +1252,8 @@ static void inet_forward_change(struct net *net)
> >  	read_lock(&dev_base_lock);
> >  	for_each_netdev(net, dev) {
> >  		struct in_device *in_dev;
> > +		if (on)
> > +			dev_disable_lro(dev);
> >  		rcu_read_lock();
> >  		in_dev = __in_dev_get_rcu(dev);
> >  		if (in_dev)
> > @@ -1257,8 +1261,6 @@ static void inet_forward_change(struct net *net)
> >  		rcu_read_unlock();
> >  	}
> >  	read_unlock(&dev_base_lock);
> > -
> > -	rt_cache_flush(0);
> >  }
> 
> Why did you delete the route cache flush here?

I changed devinet_sysctl_forward() (the only caller of inet_forward_change())
to combine code for the change-one and change-all cases.  It calls
rt_cache_flush(0) in both cases.

Ben.

-- 
Ben Hutchings, Senior Software Engineer, Solarflare Communications
Not speaking for my employer; that's the marketing department's job.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ