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:   Tue, 4 Apr 2017 13:30:55 +0000
From:   "Ghannam, Yazen" <Yazen.Ghannam@....com>
To:     Borislav Petkov <bp@...e.de>
CC:     "linux-edac@...r.kernel.org" <linux-edac@...r.kernel.org>,
        Tony Luck <tony.luck@...el.com>,
        "x86@...nel.org" <x86@...nel.org>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: RE: [PATCH 1/2] x86/mce/AMD: Redo use of SMCA MCA_DE{STAT,ADDR}
 registers

> -----Original Message-----
> From: Borislav Petkov [mailto:bp@...e.de]
> Sent: Monday, March 27, 2017 1:27 PM
> To: Ghannam, Yazen <Yazen.Ghannam@....com>

...

> >  static void
> > -__log_error(unsigned int bank, bool deferred_err, bool threshold_err,
> > u64 misc)
> > +__log_error(unsigned int bank, bool deferred_err, bool use_smca_destat,
> > +			       bool threshold_err, u64 misc)
> 
> So I had to paste the function signature in a separate vim window and keep
> looking between those arguments' names and the function calls.
> 
> Because if I look at:
> 
> 	__log_error(bank, true, false, false, 0);
> 
> I absolutely have no clue what that code does. So we need to think of
> something better. From the looks of it, I guess we dealt with a single
> __log_error() function long enough. Perhaps it is time for separation:
> 
> log_error_deferred
> log_error_smca
> log_error...
> 
> and have a function __log_error() which all three call to do the work which all
> three share.
> 
> That should make the code readable again IMO. __log_error() as it is now is
> hard to follow anyway.
> 

Okay, will do.

> > @@ -832,25 +823,29 @@ asmlinkage __visible void __irq_entry
> smp_trace_deferred_error_interrupt(void)
> >  	exiting_ack_irq();
> >  }
> >
> > +static inline bool check_deferred_status(u64 status)
> 
> This function name does not tell me anything.
> 
> 	if (is_deferred_error(status))
> 
> tells me more.
> 

Okay.

Thanks,
Yazen

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ