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:	Mon, 21 Sep 2015 23:01:39 +0200
From:	Francois Romieu <romieu@...zoreil.com>
To:	David Woodhouse <dwmw2@...radead.org>
Cc:	netdev@...r.kernel.org
Subject: Re: [PATCH 4/7] 8139cp: Fix TSO/scatter-gather descriptor setup

David Woodhouse <dwmw2@...radead.org> :
[...]
> diff --git a/drivers/net/ethernet/realtek/8139cp.c b/drivers/net/ethernet/realtek/8139cp.c
> index 058f835..07621b5 100644
> --- a/drivers/net/ethernet/realtek/8139cp.c
> +++ b/drivers/net/ethernet/realtek/8139cp.c
[...]
> @@ -865,20 +864,20 @@ static netdev_tx_t cp_start_xmit (struct sk_buff *skb,
>  		txd->addr = cpu_to_le64(first_mapping);
>  		wmb();
>  
> -		if (skb->ip_summed == CHECKSUM_PARTIAL) {
> +		ctrl = first_eor | first_len | FirstFrag | DescOwn;
> +		if (mss)
> +			ctrl |= LargeSend |
> +				((mss & MSSMask) << MSSShift);

			ctrl |= LargeSend | ((mss & MSSMask) << MSSShift);

> +		else if (skb->ip_summed == CHECKSUM_PARTIAL) {
>  			if (ip->protocol == IPPROTO_TCP)
> -				txd->opts1 = cpu_to_le32(first_eor | first_len |
> -							 FirstFrag | DescOwn |
> -							 IPCS | TCPCS);
> +				ctrl |= IPCS | TCPCS;
>  			else if (ip->protocol == IPPROTO_UDP)
> -				txd->opts1 = cpu_to_le32(first_eor | first_len |
> -							 FirstFrag | DescOwn |
> -							 IPCS | UDPCS);
> +				ctrl |= IPCS | UDPCS;
>  			else
>  				BUG();

Can you pile a patch to replace BUG with WARN_ON_ONCE(1) ?

-- 
Ueimor
--
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