From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752699AbdHKJO1 (ORCPT ); Fri, 11 Aug 2017 05:14:27 -0400 Received: from mail.skyhub.de ([5.9.137.197]:39950 "EHLO mail.skyhub.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751521AbdHKJOY (ORCPT ); Fri, 11 Aug 2017 05:14:24 -0400 Date: Fri, 11 Aug 2017 11:14:02 +0200 From: Borislav Petkov To: Chris Packham Cc: robh+dt@kernel.org, gregory.clement@free-electrons.com, jlu@pengutronix.de, linux-arm-kernel@lists.infradead.org, linux-edac@vger.kernel.org, linux-kernel@vger.kernel.org, Mauro Carvalho Chehab Subject: Re: [RESEND PATCH 4/4] EDAC: add support for reduced-width Armada-XP SDRAM Message-ID: <20170811091402.GD9432@nazgul.tnic> References: <20170807014641.4003-1-chris.packham@alliedtelesis.co.nz> <20170807014641.4003-5-chris.packham@alliedtelesis.co.nz> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20170807014641.4003-5-chris.packham@alliedtelesis.co.nz> User-Agent: Mutt/1.6.0 (2016-04-01) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Aug 07, 2017 at 01:46:41PM +1200, Chris Packham wrote: > Some integrated Armada XP SoCs use a reduced pin count so the width of > the SDRAM interface is smaller than the traditional discrete SoCs. This > means that the definition of "full" and "half" width is further reduced. > > Signed-off-by: Chris Packham > --- > drivers/edac/armada_xp_edac.c | 3 +++ > 1 file changed, 3 insertions(+) > > diff --git a/drivers/edac/armada_xp_edac.c b/drivers/edac/armada_xp_edac.c > index 68e88b180928..d8edcaac87c0 100644 > --- a/drivers/edac/armada_xp_edac.c > +++ b/drivers/edac/armada_xp_edac.c > @@ -350,6 +350,9 @@ static int armada_xp_mc_edac_probe(struct platform_device *pdev) > if (armada_xp_mc_edac_read_config(mci)) > return -EINVAL; > > + if (of_property_read_bool(pdev->dev.of_node, "marvell,reduced-width")) > + drvdata->width /= 2; If the compiler doesn't already convert it to a shift on ARM, you probably should do >>= 1; here, just in case. With that you can add my Acked-by: Borislav Petkov and route it through an ARM tree. Thx. -- Regards/Gruss, Boris. ECO tip #101: Trim your mails when you reply. --