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, 13 Aug 2014 23:19:42 +0200
From:	Richard Cochran <richardcochran@...il.com>
To:	Fugang Duan <b38611@...escale.com>
Cc:	shawn.guo@...aro.org, davem@...emloft.net, netdev@...r.kernel.org
Subject: Re: [PATCH v2 1/1] net: fec: ptp: avoid register access when ipg
 clock is disabled

On Wed, Aug 13, 2014 at 12:55:05PM +0800, Fugang Duan wrote:

> diff --git a/drivers/net/ethernet/freescale/fec_main.c b/drivers/net/ethernet/freescale/fec_main.c
> index 66fe1f6..8befa2c 100644
> --- a/drivers/net/ethernet/freescale/fec_main.c
> +++ b/drivers/net/ethernet/freescale/fec_main.c
> @@ -2198,6 +2198,8 @@ fec_enet_open(struct net_device *ndev)
>  	napi_enable(&fep->napi);
>  	phy_start(fep->phy_dev);
>  	netif_start_queue(ndev);
> +	if (fep->hwts_tx_en)
> +		schedule_delayed_work(&fep->time_keep, HZ);
>  	return 0;
>  }
>  
> @@ -2206,6 +2208,9 @@ fec_enet_close(struct net_device *ndev)
>  {
>  	struct fec_enet_private *fep = netdev_priv(ndev);
>  
> +	if (fep->hwts_tx_en)
> +		cancel_delayed_work_sync(&fep->time_keep);

You make the clock logic depend on whether time stamping is enabled or
not. Why do you do that?

The clock should keep ticking, even if time stamping is disabled.

Thanks,
Richard
--
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