Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752984AbcCGPYf (ORCPT ); Mon, 7 Mar 2016 10:24:35 -0500 Received: from mail.skyhub.de ([78.46.96.112]:58654 "EHLO mail.skyhub.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752418AbcCGPY1 (ORCPT ); Mon, 7 Mar 2016 10:24:27 -0500 Date: Mon, 7 Mar 2016 16:24:13 +0100 From: Borislav Petkov To: Hubert Chrzaniuk Cc: lukasz.anaczkowski@intel.com, mchehab@osg.samsung.com, dougthompson@xmission.com, linux-edac@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] EDAC, sb_edac: Fixed logic error in sb_edac driver Message-ID: <20160307152413.GB27820@pd.tnic> References: <1457361045-26221-1-git-send-email-hubert.chrzaniuk@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <1457361045-26221-1-git-send-email-hubert.chrzaniuk@intel.com> User-Agent: Mutt/1.5.24 (2015-08-30) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1358 Lines: 40 On Mon, Mar 07, 2016 at 03:30:45PM +0100, Hubert Chrzaniuk wrote: > Patch corrects a typo introduced previously. > As a result under some configurations dimms were not > correctly recognized. Problem affects only Xeon Phi architecture. > > Signed-off-by: Hubert Chrzaniuk > --- > drivers/edac/sb_edac.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/edac/sb_edac.c b/drivers/edac/sb_edac.c > index e438ee5..f5c6b97 100644 > --- a/drivers/edac/sb_edac.c > +++ b/drivers/edac/sb_edac.c > @@ -1574,7 +1574,7 @@ static int knl_get_dimm_capacity(struct sbridge_pvt *pvt, u64 *mc_sizes) > for (cha = 0; cha < KNL_MAX_CHAS; cha++) { > if (knl_get_mc_route(target, > mc_route_reg[cha]) == channel > - && participants[channel]) { > + && !participants[channel]) { > participant_count++; > participants[channel] = 1; > break; > -- Do I see it correctly this one fixes d0cdf9003140 ("EDAC, sb_edac: Add Knights Landing (Xeon Phi gen 2) support") and needs to go to Linus now otherwise 4.5 is b0rked on KNL? On a related note, that knl_get_dimm_capacity() is huuuge and hard to read and could use some nice cleanups and splitting out functionality into helper functions... -- Regards/Gruss, Boris. ECO tip #101: Trim your mails when you reply.