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]
Message-ID: <alpine.DEB.2.10.1506051745370.2388@hadrien>
Date:	Fri, 5 Jun 2015 17:45:50 +0200 (CEST)
From:	Julia Lawall <julia.lawall@...6.fr>
To:	Antonio Murdaca <antonio.murdaca@...il.com>
cc:	davem@...emloft.net, netdev@...r.kernel.org,
	linux-kernel@...r.kernel.org, joe@...ches.com,
	julia.lawall@...6.fr, akpm@...ux-foundation.org
Subject: Re: [PATCH] ethernet: micrel: use time_after_eq macro

On Fri, 5 Jun 2015, Antonio Murdaca wrote:

> use time_after_eq macro for time comparison
>
> Signed-off-by: Antonio Murdaca <antonio.murdaca@...il.com>
> ---
>  drivers/net/ethernet/micrel/ksz884x.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/net/ethernet/micrel/ksz884x.c b/drivers/net/ethernet/micrel/ksz884x.c
> index 48d2aec..9bce30c 100644
> --- a/drivers/net/ethernet/micrel/ksz884x.c
> +++ b/drivers/net/ethernet/micrel/ksz884x.c
> @@ -6689,7 +6689,7 @@ static void mib_monitor(unsigned long ptr)
>
>  	/* This is used to verify Wake-on-LAN is working. */
>  	if (hw_priv->pme_wait) {
> -		if (hw_priv->pme_wait <= jiffies) {
> +		if (time_after_eq(jiffies, hw_priv->pme_wait)) {

There is also time_is_before_eq_jiffies.

julia

>  			hw_clr_wol_pme_status(&hw_priv->hw);
>  			hw_priv->pme_wait = 0;
>  		}
> --
> 2.4.2
>
>
--
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