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:   Mon, 19 Apr 2021 11:55:54 -0700
From:   Jakub Kicinski <kuba@...nel.org>
To:     Ido Schimmel <idosch@...sch.org>
Cc:     netdev@...r.kernel.org, davem@...emloft.net, andrew@...n.ch,
        mkubecek@...e.cz, idosch@...dia.com, saeedm@...dia.com,
        michael.chan@...adcom.com
Subject: Re: [PATCH net-next v2 6/9] ethtool: add interface to read RMON
 stats

On Sun, 18 Apr 2021 11:04:16 +0300 Ido Schimmel wrote:
> On Fri, Apr 16, 2021 at 12:27:42PM -0700, Jakub Kicinski wrote:
> > +/**
> > + * struct ethtool_rmon_hist_range - byte range for histogram statistics
> > + * @low: low bound of the bucket (inclusive)
> > + * @high: high bound of the bucket (inclusive)
> > + */
> > +struct ethtool_rmon_hist_range {
> > +	u16 low;
> > +	u16 high;  
> 
> Given ETHTOOL_A_STATS_GRP_HIST_BKT_{LOW,HI} are u32, should this also be
> u32?

I felt a little bad about wasting memory in each driver. It's around
40B per driver. I thought we can adjust when needed given this is
internal to the kernel, and static checkers should have no problem
detecting truncation (or any rudimentary testing).

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ