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, 18 Jan 2023 12:51:42 +0200
From:   Vladimir Oltean <vladimir.oltean@....com>
To:     netdev@...r.kernel.org
Cc:     "David S. Miller" <davem@...emloft.net>,
        Eric Dumazet <edumazet@...gle.com>,
        Jakub Kicinski <kuba@...nel.org>,
        Paolo Abeni <pabeni@...hat.com>,
        Claudiu Manoil <claudiu.manoil@....com>
Subject: Re: [PATCH net-next 09/12] net: enetc: implement ring
 reconfiguration procedure for PTP RX timestamping

On Wed, Jan 18, 2023 at 01:02:31AM +0200, Vladimir Oltean wrote:
> The crude enetc_stop() -> enetc_open() mechanism suffers from 2
> problems:
> 
> 1. improper error checking
> 2. it involves phylink_stop() -> phylink_start() which loses the link
> 
> Right now, the driver is prepared to offer a better alternative: a ring
> reconfiguration procedure which takes the RX BD size (normal or
> extended) as argument. It allocates new resources (failing if that
> fails), stops the traffic, and assigns the new resources to the rings.
> 
> Signed-off-by: Vladimir Oltean <vladimir.oltean@....com>
> ---

There is a transient build warning here which I didn't notice at home:

../drivers/net/ethernet/freescale/enetc/enetc.c:2492:12: warning: ‘enetc_reconfigure’ defined but not used [-Wunused-function]
 2492 | static int enetc_reconfigure(struct enetc_ndev_priv *priv, bool extended)
      |            ^~~~~~~~~~~~~~~~~

because enetc_hwtstamp_set() (the caller of enetc_reconfigure()) is
apparently under #ifdef CONFIG_FSL_ENETC_PTP_CLOCK.

A later patch also uses enetc_reconfigure() from enetc_setup_xdp_prog(),
which isn't conditionally compiled, so the warning goes away.

What do the experts think, resend or leave it as is?

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ