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:	Thu, 4 Sep 2008 15:10:35 -0400
From:	"Ramkrishna Vepa" <Ramkrishna.Vepa@...erion.com>
To:	"Breno Leitao" <leitao@...ux.vnet.ibm.com>,
	"Rastapur Santosh" <santosh.rastapur@...erion.com>,
	"Sivakumar Subramani" <Sivakumar.Subramani@...erion.com>
Cc:	<jeff@...zik.org>, "Jay Vosburgh" <fubar@...ibm.com>,
	"netdev" <netdev@...r.kernel.org>, "Lorandi" <rafaello@...ibm.com>
Subject: RE: [PATCH 1/1 net-2.6] s2io: enabling VLAN tag stripping at driver initialization

Breno,

When the chip comes out of reset, it's default setting is to strip the
vlan tag. So, in your patch, you will need to do this differently. The
vlan_strip_flag will have to be moved to the nic structure and
initialized there. 

> +	if (vlan_tag_strip)
> +		sp->vlan_strip_flag = 1;
> +	else 
> +		sp->vlan_strip_flag = 0;

Thanks,
Ram

> Actually s2io has a bug in VLAN support. VLAN doesn't work except if
> you'd opened the interface in promiscuous mode before.
> This happens because VLAN tag stripping is not enable by default (when
> the device is loaded). It is only enabled when the device leaves
> promiscuous mode.
> 
> Signed-off-by: Breno Leitao <leitao@...ux.vnet.ibm.com>
> Signed-off-by: Jay Vosburgh <fubar@...ibm.com>
> 
> ---
> 
> diff --git a/drivers/net/s2io.c b/drivers/net/s2io.c
> index a2b0730..e656c80 100644
> --- a/drivers/net/s2io.c
> +++ b/drivers/net/s2io.c
> @@ -8206,6 +8206,14 @@ s2io_init_nic(struct pci_dev *pdev, const
struct
> pci_device_id *pre)
>  	/* Initialize device name */
>  	sprintf(sp->name, "%s Neterion %s", dev->name,
sp->product_name);
> 
> +	/* Initialize VLAN tag strip */
> +	if (vlan_tag_strip) {
> +		val64 = readq(&bar0->rx_pa_cfg);
> +		val64 |= RX_PA_CFG_STRIP_VLAN_TAG;
> +		writeq(val64, &bar0->rx_pa_cfg);
> +		vlan_strip_flag = 1;
> +	}
> +
>  	/*
>  	 * Make Link state as off at this point, when the Link change
>  	 * interrupt comes the state will be automatically changed to
> --
> 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
--
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