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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <alpine.DEB.2.20.1801072237070.2094@nanos>
Date:   Sun, 7 Jan 2018 22:39:45 +0100 (CET)
From:   Thomas Gleixner <tglx@...utronix.de>
To:     Greg Kroah-Hartman <gregkh@...uxfoundation.org>
cc:     LKML <linux-kernel@...r.kernel.org>,
        Linus Torvalds <torvalds@...uxfoundation.org>,
        Ingo Molnar <mingo@...nel.org>,
        Peter Zijlstra <peterz@...radead.org>,
        Borislav Petkov <bp@...en8.de>,
        David Woodhouse <dwmw@...zon.co.uk>,
        "Hansen, Dave" <dave.hansen@...el.com>
Subject: Re: [patch 1/2] sysfs/cpu: Add vulnerability folder

On Sun, 7 Jan 2018, Greg Kroah-Hartman wrote:
> >  drivers/base/Kconfig |    3 +++
> >  drivers/base/cpu.c   |   48 ++++++++++++++++++++++++++++++++++++++++++++++++
> >  include/linux/cpu.h  |    7 +++++++
> >  3 files changed, 58 insertions(+)
> 
> A Documentation/ABI/ update is needed for the new sysfs files.

Sure.

> > +#ifdef CONFIG_GENERIC_CPU_VULNERABILITIES
> > +
> > +ssize_t __weak cpu_show_meltdown(struct device *dev,
> > +				 struct device_attribute *attr, char *buf)
> > +{
> > +	return snprintf(buf, PAGE_SIZE - 2, "Not affected\n");
> 
> sysfs is one-value-per-file, so you never need to care about the page
> size, a simple sprintf() is fine.  No need to change if you don't want
> to, your call.

Done.

> > +static DEVICE_ATTR(spectre_v2, 0444, cpu_show_spectre_v2, NULL);
> 
> DEVICE_ATTR_RO() please.
> 
> Yeah, that does make the global symbols a bit different, meltdown_show()
> and the like.  Hm, I guess this is ok, given that it's ment to be
> overridden.

That and I expect that in the not so distant future we'll see write
functions as well.

> Oh, nevermind.  So, just a documentation update please, that can always
> be an add-on patch if you promise to do it :)

You should never make such offers. These promises land on that growth only
thingy, aka. todo list :)

Thanks,

	tglx

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ