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] [day] [month] [year] [list]
Message-Id: <20150607.192202.705812138482774611.davem@davemloft.net>
Date:	Sun, 07 Jun 2015 19:22:02 -0700 (PDT)
From:	David Miller <davem@...emloft.net>
To:	jonas.jensen@...il.com
Cc:	netdev@...r.kernel.org, linux-arm-kernel@...ts.infradead.org,
	linux-kernel@...r.kernel.org
Subject: Re: [PATCH] net: moxa: fix TX overrun memory leak

From: Jonas Jensen <jonas.jensen@...il.com>
Date: Fri,  5 Jun 2015 15:46:18 +0200

>  	desc = priv->tx_desc_base + (TX_REG_DESC_SIZE * tx_head);
>  
> -	spin_lock_irq(&priv->txlock);
> +	if (CIRC_SPACE(tx_head, tx_tail, TX_DESC_NUM) == 0) {
> +		priv->stats.tx_dropped++;
> +		goto out_unlock;
> +	}

You can't do this.

Whatever code creates this condition _must_ stop the TX queue
so that the core netdevice transmit layer does not call your
transmit method.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ