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]
Message-ID: <CAGHK07Dwv_fkP222WtMeH-E+bqOG8CFGQyNObDtkYbmeD4LELQ@mail.gmail.com>
Date: Thu, 8 Feb 2024 11:21:33 +1100
From: Jonathan Maxwell <jmaxwell37@...il.com>
To: Andrew Lunn <andrew@...n.ch>
Cc: jesse.brandeburg@...el.com, anthony.l.nguyen@...el.com, 
	davem@...emloft.net, edumazet@...gle.com, kuba@...nel.org, pabeni@...hat.com, 
	intel-wired-lan@...ts.osuosl.org, netdev@...r.kernel.org, 
	linux-kernel@...r.kernel.org
Subject: Re: [net-next] intel: make module parameters readable in sys filesystem

On Thu, Feb 8, 2024 at 11:04 AM Andrew Lunn <andrew@...n.ch> wrote:
>
> On Thu, Feb 08, 2024 at 10:04:30AM +1100, Jon Maxwell wrote:
> > Linux users sometimes need an easy way to check current values of module
> > parameters. For example the module may be manually reloaded with different
> > parameters. Make these visible and readable in the /sys filesystem to allow
> > that.
> >
> > Signed-off-by: Jon Maxwell <jmaxwell37@...il.com>
> > ---
> >  drivers/net/ethernet/intel/e100.c                 | 6 +++---
> >  drivers/net/ethernet/intel/e1000/e1000_main.c     | 2 +-
> >  drivers/net/ethernet/intel/e1000e/netdev.c        | 2 +-
> >  drivers/net/ethernet/intel/i40e/i40e_main.c       | 2 +-
> >  drivers/net/ethernet/intel/igb/igb_main.c         | 4 ++--
> >  drivers/net/ethernet/intel/igbvf/netdev.c         | 2 +-
> >  drivers/net/ethernet/intel/igc/igc_main.c         | 2 +-
> >  drivers/net/ethernet/intel/ixgbe/ixgbe_main.c     | 6 +++---
> >  drivers/net/ethernet/intel/ixgbevf/ixgbevf_main.c | 2 +-
> >  9 files changed, 14 insertions(+), 14 deletions(-)
> >
> > diff --git a/drivers/net/ethernet/intel/e100.c b/drivers/net/ethernet/intel/e100.c
> > index 01f0f12035caeb7ca1657387538fcebf5c608322..2d879579fc888abda880e7105304941db5d4e263 100644
> > --- a/drivers/net/ethernet/intel/e100.c
> > +++ b/drivers/net/ethernet/intel/e100.c
> > @@ -170,9 +170,9 @@ MODULE_FIRMWARE(FIRMWARE_D102E);
> >  static int debug = 3;
> >  static int eeprom_bad_csum_allow = 0;
> >  static int use_io = 0;
> > -module_param(debug, int, 0);
> > -module_param(eeprom_bad_csum_allow, int, 0);
> > -module_param(use_io, int, 0);
> > +module_param(debug, int, 0444);
>
> ethtool should show you debug. And it is pretty much standardized, it
> should work for most ethernet interfaces which support msglvl. So i
> would say it is better to teach your Linux users how to use ethtool
> for this.

Yes they know about that. But take the scenario where  allow_unsupported_sfp
is set 0 after it was set to 1 at boot. That won't be logged.

>
> There might be some value in this change for module parameters which
> are not standardised, but i suggest you drop debug from the patchset.
>

Fair enough makes sense seeing that it can be controlled by ethtool.
I'll submit a v2 with that change.

Regards

Jon

>     Andrew

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ