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]
Date:   Mon, 6 Dec 2021 03:10:08 +0100
From:   Andrew Lunn <andrew@...n.ch>
To:     Aleksander Jan Bajkowski <olek2@...pl>
Cc:     hauke@...ke-m.de, davem@...emloft.net, kuba@...nel.org,
        netdev@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH net] net: lantiq_xrx200: increase buffer reservation

> +static inline int xrx200_max_frame_len(int mtu)
> +{
> +	return VLAN_ETH_HLEN + mtu + ETH_FCS_LEN;
> +}
> +
> +static inline int xrx200_buffer_size(int mtu)
> +{
> +	return round_up(xrx200_max_frame_len(mtu) - 1, 4 * XRX200_DMA_BURST_LEN);
> +}

Please don't use inline in .c files. Let the compiler decide.

       Andrew

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ