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:	Sat, 24 Mar 2012 08:53:18 -0700
From:	Joe Perches <joe@...ches.com>
To:	Mike Sinkovsky <msink@...monline.ru>
Cc:	netdev@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH v3] Ethernet driver for the WIZnet W5300 chip

On Sat, 2012-03-24 at 16:02 +0500, Mike Sinkovsky wrote:
> Based on original driver from chip manufacturer, but nearly full rewite.
> Tested and used in production with Blackfin BF531 embedded processor.

Hi Mike.

Just a trivial comment.  Instead of:
	if (netif_<test>(priv))
		netdev_<level>(ndev, ...)
you can use
	netif_<level>(priv, <test>, ndev, ,...)

> diff --git a/drivers/net/ethernet/wiznet/w5300.c b/drivers/net/ethernet/wiznet/w5300.c
[]
> +static irqreturn_t w5300_detect_link(int irq, void *ndev_instance)
> +{
> +	struct net_device *ndev = ndev_instance;
> +	struct w5300_private *priv = netdev_priv(ndev);
> +
> +	if (netif_running(ndev)) {
> +		if (gpio_get_value(priv->link_gpio) != 0) {
[]
> +			if (netif_msg_link(priv))
> +				netdev_info(ndev, "link is Up\n");

like:
			netif_info(priv, link, ndev, "link is up\n");

> +			netif_carrier_on(ndev);
> +		} else {
> +			if (netif_msg_link(priv))
> +				netdev_info(ndev, "link is Down\n");

			netif_info(priv, link, ndev, "link is down\n");

> +static int w5300_stop(struct net_device *ndev)
> +{
> +	struct w5300_private *priv = netdev_priv(ndev);
> +
> +	if (netif_msg_ifdown(priv))
> +		netdev_dbg(ndev, "shutting down\n");

		netif_dbg(priv, ifdown, ndev, "shutting down\n");


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