From patchwork Thu Apr 7 01:09:42 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: tthayer@opensource.altera.com X-Patchwork-Id: 8767841 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 0C9379F372 for ; Thu, 7 Apr 2016 01:07:30 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id DD7F6201B9 for ; Thu, 7 Apr 2016 01:07:28 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.9]) (using TLSv1.2 with cipher AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id CBD2D201B4 for ; Thu, 7 Apr 2016 01:07:27 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1anyOG-0000WM-JA; Thu, 07 Apr 2016 01:05:44 +0000 Received: from mail-bn1bon0094.outbound.protection.outlook.com ([157.56.111.94] helo=na01-bn1-obe.outbound.protection.outlook.com) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1anyOD-0000Pc-Hd for linux-arm-kernel@lists.infradead.org; Thu, 07 Apr 2016 01:05:42 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=altera.onmicrosoft.com; s=selector1-opensource-altera-com; h=From:To:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=AxiQplDKpxN5AEk8sLAXMgr6rRZ3LAI2o1b2r6yui6Q=; b=duedyrWZ4JCvRl589Y2jg+6oMU7O9MXit1AEv9R6/uw1zHNNj9yRKDk0BTbsuwhV/BSWBcuFE0uEkHxRABY8a5zK1Y7yFwrelt+WeWJOmZbM8LN/BjNUNOVEuPhKch8PAvorlhyzYnUZ/7AJWDKMq1ek8Hbawmf7cIBfFmEwXHk= Received: from BY2PR03CA012.namprd03.prod.outlook.com (10.255.93.29) by DM2PR0301MB1296.namprd03.prod.outlook.com (10.160.222.15) with Microsoft SMTP Server (TLS) id 15.1.447.15; Thu, 7 Apr 2016 01:05:18 +0000 Received: from BY2FFO11FD033.protection.gbl (10.255.93.4) by BY2PR03CA012.outlook.office365.com (10.255.93.29) with Microsoft SMTP Server (TLS) id 15.1.447.15 via Frontend Transport; Thu, 7 Apr 2016 01:05:17 +0000 Authentication-Results: spf=fail (sender IP is 66.35.236.227) smtp.mailfrom=opensource.altera.com; linaro.org; dkim=pass (signature was verified) header.d=altera.onmicrosoft.com; linaro.org; dmarc=none action=none header.from=opensource.altera.com; Received-SPF: Fail (protection.outlook.com: domain of opensource.altera.com does not designate 66.35.236.227 as permitted sender) receiver=protection.outlook.com; client-ip=66.35.236.227; helo=sj-itexedge03.altera.priv.altera.com; Received: from sj-itexedge03.altera.priv.altera.com (66.35.236.227) by BY2FFO11FD033.mail.protection.outlook.com (10.1.14.218) with Microsoft SMTP Server (TLS) id 15.1.453.6 via Frontend Transport; Thu, 7 Apr 2016 01:05:17 +0000 Received: from na01-bn1-obe.outbound.protection.outlook.com (207.46.163.144) by webmail.altera.com (66.35.236.227) with Microsoft SMTP Server (TLS) id 14.3.174.1; Wed, 6 Apr 2016 18:03:43 -0700 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=altera.onmicrosoft.com; s=selector1-opensource-altera-com; h=From:To:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=AxiQplDKpxN5AEk8sLAXMgr6rRZ3LAI2o1b2r6yui6Q=; b=duedyrWZ4JCvRl589Y2jg+6oMU7O9MXit1AEv9R6/uw1zHNNj9yRKDk0BTbsuwhV/BSWBcuFE0uEkHxRABY8a5zK1Y7yFwrelt+WeWJOmZbM8LN/BjNUNOVEuPhKch8PAvorlhyzYnUZ/7AJWDKMq1ek8Hbawmf7cIBfFmEwXHk= Authentication-Results: alien8.de; dkim=none (message not signed) header.d=none;alien8.de; dmarc=none action=none header.from=opensource.altera.com; Received: from tthayer-HP-Z620-Ubuntu.137.57.187.33 (64.129.157.38) by BY1PR03MB1482.namprd03.prod.outlook.com (10.162.210.140) with Microsoft SMTP Server (TLS) id 15.1.447.15; Thu, 7 Apr 2016 01:05:08 +0000 From: To: , , , , , , , Subject: [PATCHv3 7/8] ARM: socfpga: Enable Arria10 OCRAM ECC on startup Date: Wed, 6 Apr 2016 20:09:42 -0500 Message-ID: <1459991382-7859-1-git-send-email-tthayer@opensource.altera.com> X-Mailer: git-send-email 1.7.9.5 MIME-Version: 1.0 X-Originating-IP: [64.129.157.38] X-ClientProxiedBy: BLUPR11CA0019.namprd11.prod.outlook.com (10.141.240.29) To BY1PR03MB1482.namprd03.prod.outlook.com (10.162.210.140) X-MS-Office365-Filtering-Correlation-Id: bb4a2896-7bdb-4292-521f-08d35e80af33 X-Microsoft-Exchange-Diagnostics-untrusted: 1; BY1PR03MB1482; 2:iOKZJmXPg7ZQrmZ9jm+FyU5tYqdmEtTvh5o/4ZTzC8eL3sv6E90u1amc5oPamTBMeYLGfAnOlyfP84B3V1ymi3hGRmwDyLFNZCQ9avURggfahVCZMrhi004ifuv8liewTZPzxLuJt4R4Yc4F1nGZcspursdkUWkNJee+UNZ85RYuIayP3lPpnUilO9N1MwaU; 3:O6yh2S8LVX0SZ0N6cWEwDSHI7XO0dd+0X4GO5/yKRqvIh8GWSevh8yxQgJP7zUvJo10EzBpr7JkS4EWtoFC6Pm6AHgM3zAyr+a9zMn4cP0KEplUJEZU2zohFoMtcXAM/ X-Microsoft-Antispam-Untrusted: UriScan:; BCL:0; PCL:0; RULEID:; SRVR:BY1PR03MB1482; X-Microsoft-Exchange-Diagnostics-untrusted: 1; BY1PR03MB1482; 25:NyxgBuGVnwE1SZ+ga/iujVuxNYWuCNtOG4ugZMP0NhkkayXu1PS6zymndUx+hIY/ywefKb8VqWoZGDqrm6QZVP9wJeJV85+lZvu2exfWSq/iSYI8jHeh00xPZnpWoIRVpKoE/9ieY+0CuzdUL36NaHd2MS4BhfTpL6SkMvD4SbX/9wLW8DYLkdq1P5lyFeYdHN4OD9R/nAc7OF7TVDwf4u624cGxeTd7Vz7MBcxbMtc32TnyuPRmiAaxg5C8H5NSK8PjgO69gylY6Wafu8nblcIeKgMUdqxOPHqQ8D10cUiYARM+h3s0s84PB9U/bIb+uDVZOP3KgxuNEER57HNyz87DffnS1O5dV8atCVmSxyZFlWfOHiW5aB8dTacUiJC61Wmjvv4l1WNLeS5wIlhzwSWgPfYxxOTBGf8DFuEB/+WzIWjxdMPO6VcTEK7bJQ1lF2eZiqXq8in17ykA3UE6jEkXZRRkx1WpJivL4CHsRXKvG9Nnk7yNuCCVwIvD37VGIBeF3amk7nI70Pq9KHTHojewh8Crzt2oWqRwcibjWbflY+cSVNZsjYC+K5/jgs5PjSAMMXlvZOQCMQERn4c0Zx6opuKxQ2+QlKzPs7/aE64Qg/FlFeQ0AuFJtSL4vXBTbXOPl6DhssJPXaH5lY5476R/C9BmHHsw6EsTb/q75NhD52gBWqGAvzej6w64/hCK; 20:zFgbMXeWMTHv6gbrvPKbnEsat4WPhA8P+tqfwXS4xVEaM80gETxhVLmdbWP1gLtAPpp+fta2cUprBoystLYC8xiAaZKUeF/8vL7uv4Nn7bozGQD3WqPKlTc2pty7CUn4PFolkG5FStfWiL+pgfA0OlH5+thxXNIIG8jnVbE63IM= X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:;UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(601004)(2401047)(5005006)(8121501046)(3002001)(10201501046); SRVR:BY1PR03MB1482; BCL:0; PCL:0; RULEID:; SRVR:BY1PR03MB1482; BCL:0; PCL:0; RULEID:(601004)(2401047)(13018025)(13023025)(13024025)(8121501046)(5005006)(13015025)(13017025)(3002001)(10201501046); SRVR:DM2PR0301MB1296; BCL:0; PCL:0; RULEID:; SRVR:DM2PR0301MB1296; X-Microsoft-Exchange-Diagnostics-untrusted: 1; BY1PR03MB1482; 4:t62gd5Ev/muWFe4/DRFn12VdQ+KqJwr4dtspQ7FJ7euD9oebUiBBIi6jLIqifIgRiPTj/rKFbxlngfmIlSZ7YMmzbGFe8B8LzQo0LrUbIIdZqL56J8Kjpnld9p8go7bzZM+WcltwyhVgL1RY66dQhs70uTdxWhFzVxJwkkanxiBR8lTHeB4d3JB0nZd7VCZoejOyvAtInw/Dhelo8yKPzbvKZFbLAHchxJplcrpaFXoFWecjBEMLceWD+IWozfCYRi0tiuvDbMTUPTYxsCxfobM9CvoKuSzAVYPoBDsacG7gXDiUeCEH3M8UkFQoyixu+S0mrNFIjTrKaS3Oj47vBIXETMqLrDDERhgRyOvOsX0UsL1fDHwXKqvhDeMLlgHM X-Forefront-PRVS: 0905A6B2C7 X-Forefront-Antispam-Report-Untrusted: SFV:NSPM; SFS:(10009020)(4630300001)(6049001)(6009001)(50226001)(575784001)(50986999)(19580405001)(15975445007)(6116002)(1096002)(4001430100002)(3846002)(5001770100001)(50466002)(33646002)(19580395003)(77096005)(586003)(48376002)(47776003)(107886002)(81166005)(5008740100001)(66066001)(86152002)(189998001)(4326007)(229853001)(2906002)(2201001)(92566002)(5004730100002)(42186005)(2876002)(5003940100001)(86362001)(4720700001)(217873001); DIR:OUT; SFP:1101; SCL:1; SRVR:BY1PR03MB1482; H:tthayer-HP-Z620-Ubuntu.137.57.187.33; FPR:; SPF:None; MLV:sfv; LANG:en; X-Microsoft-Exchange-Diagnostics-untrusted: =?us-ascii?Q?1; BY1PR03MB1482; 23:YFHTqtyH2mxQaXBJdUSSocK9jI6s17ji6Dp89RxyN?= =?us-ascii?Q?Dmt7i2OBozOS3xrJXYtVNecqh1lMJi/Uy7iq3aGFHRNTFOeyJuGHmfxvY3Fd?= =?us-ascii?Q?7FUCwlBkZqZLm2s6yGWGYVXbZl6YayhR+EYu5W8pRVnDyoUvk39JXyoB0fi+?= =?us-ascii?Q?z4yMUSPfcwmAh/IS11/2FFOTfMXq3EluXEppxis+Cab9d+3EUezqreaRzNIM?= =?us-ascii?Q?6RySLYLNB/48tlkr+B0OlmmXAVyIQtfTvfA7vQqddQD7Wrcm5QytCr5zQhTr?= =?us-ascii?Q?MF8tuY/hrxC9roxjhUU4Er5YWi8yP8ZPKbLaSsV+pata5G2Kqf8p3iyA0BxE?= =?us-ascii?Q?mWOtH+VgqxT3rI39xgpQDPogyx+2s6i1EavM5pRXSbdh4oIbVesbQzy87izz?= =?us-ascii?Q?5Hhtv08Y6xIQ2MoqoIZUGEBBh/5ahopk8EHLGH+MN+8gmTBylI9OUhmfu+Ah?= =?us-ascii?Q?huE2B0H2+NV1kMBPDmknkXpbTXl/31f8rXC5Te3cUNistdvuV1FbTNp/B1AA?= =?us-ascii?Q?i2W8/kfLfoJfRUKVvlU+R0//dRSZhB9lYdhSx2x5bX7wIzheEAao3x9873eD?= =?us-ascii?Q?yycRp3slQH7yYWAdn9TfUpcw9aCv43uo1jgFL76Z39wyOZGkfq7RCcUvRQPQ?= =?us-ascii?Q?bcharZuI9UVGUibSjw5Bi5wcSW/QF/mS2TSF5u7cr30Mm/bZyWhZcfJxdbvp?= =?us-ascii?Q?mjaDw9m9OFfG8ByfK+/2xEVIiVTEXXND/QCr7lYsyTB1LuAnvFonYDu1W/53?= =?us-ascii?Q?mFUjm+xYkfBNR4inA+gLofmyz4O4gZkEqaJ4WB3QrISwFXMBB1iRCRxuLs/d?= =?us-ascii?Q?cp8LOPtRv+AD3/LEzq102IeJ/b7/PcsW9+MYX4an6ESb6cNdzXRvbc8o5XN+?= =?us-ascii?Q?z6Ly97+DA3AoVqvN2tEZuwlcMWmAxu3kc+ehVmLJyrZ57beWameQjhE1q3hd?= =?us-ascii?Q?QqGqWShOY+nCkJqC8uIWc88ObSe1hta426FinYeskGPAKZdd+q1M/HVcTKDq?= =?us-ascii?Q?GpJ4auoqSkJ2C766vn58NafzY072FW/zo3RwXiSRSMnm4emjioReI9qgacTD?= =?us-ascii?Q?0D0KjI=3D?= X-Microsoft-Exchange-Diagnostics-untrusted: 1; BY1PR03MB1482; 5:QkA1K1enHrBlaX/0uQO3KtKDx7iOGfSTRyHy5qL0Yzz2n2CaGgmrU6LxRH4UIvj0k+ci0iEx7KSxCmB53MnxyPGSf+SmfihMEwWskl5qnTPr2V+XpG57gEisIFpUbHJYPSdgOyLI30vNrHuvP40BDg==; 24:ksTbmSyfeCaYn/JHxl3AYFmnqMf49xpkCrJHpRhST+jgM+NNgQbNpRuyngpRuVx6p8EbR7e7TQRT0H1mwIoA6kk7dMz3MdfA7F67/UvGPrw=; 20:Y9vERgWuTUKn1kBgxfw2ZhXrAxQgaC63kSvCy1iO8PwJKY+QATaSpEQBQdt3JYiXepfmOV6oP0qEWCxuNCPifbH56zGMPP38dlhP9AOQ2Uo2yNVh5YFLWFw0ufJfRW2aB9e2FjNFUFux8EVxZRQxTOu4PJpJvCKgZFMzKuR7iIA= SpamDiagnosticOutput: 1:23 SpamDiagnosticMetadata: NSPM X-MS-Exchange-Transport-CrossTenantHeadersStamped: BY1PR03MB1482 X-EOPAttributedMessage: 0 X-MS-Exchange-Transport-CrossTenantHeadersStripped: BY2FFO11FD033.protection.gbl X-Forefront-Antispam-Report: CIP:66.35.236.227; IPV:NLI; CTRY:US; EFV:NLI; SFV:NSPM; SFS:(10009020)(6009001)(2980300002)(1110001)(1109001)(339900001)(199003)(189002)(48376002)(50466002)(19580405001)(87936001)(2201001)(19580395003)(105606002)(11100500001)(106466001)(575784001)(107886002)(5001770100001)(47776003)(189998001)(77096005)(956001)(2876002)(66066001)(586003)(1096002)(3846002)(5004730100002)(15975445007)(86152002)(21840400001)(1220700001)(6116002)(85426001)(50986999)(81166005)(92566002)(50226001)(86362001)(4326007)(16796002)(2906002)(3720700001)(229853001)(6806005)(4001430100002)(5008740100001)(5003940100001)(33646002)(7099028)(217873001)(4720700001); DIR:OUT; SFP:1101; SCL:1; SRVR:DM2PR0301MB1296; H:sj-itexedge03.altera.priv.altera.com; FPR:; SPF:Fail; MLV:sfv; A:0; MX:1; LANG:en; X-Microsoft-Exchange-Diagnostics: 1; BY2FFO11FD033; 1:QWH3IaH61QBVHxN2BHOznk2nMi90Na6OD/qTijqsbMKATEIaPaekbAiNT2da6X9HKNq6qbBpLM8ySrBpAtshnV/Y6gxdWHlXnXD6RVnK3RW5SKsv0ea4WqGTItQLCeALgtHahApon8NF1tfjcIgCXqEx80OOOH9u5b1POgjKFTzlaJoSuveIEzoF+7MiWehvHOsx8Kzz2UnLP8Ruh45ZZZn+Lp9EaWMs5yAbw6XgFM+/RVSM663kZDq7Z13XKjcnRyUsL2ox9qjyHAr/Pkpmj0G+9pZYrK3nqqKE+GCpacAaL1maPqCDZjwsy9+EfxXe8hrgMr5AgvJNvjsZ10JCmKT53vlzVDGSOllElDdS20+3pSdRxY952/2V4pnlrSYeTDIFtBCvV5BhsskdAqtbvQoADpAlXylfV4asjfsUpUi9E1PWFTXmNuQgQfRb4/3uc7J1zpdapKIm8bb8Sq0w20bs4f91ZUhmID6INzCBawlTeNtvkPRjEKA5vAUujMgHPeI6o1L7Nl/I522hpCQV2NqufPYOZ88p1IY95L6Zjq36I9/4cS9EdMffJecHiwna X-Microsoft-Exchange-Diagnostics: 1; DM2PR0301MB1296; 2:en4/SgiRY9KHLsA/3kKx7J0stSZ5GDqsKKqyTKH6B72sP/pa7HeYlAqegRteEpUMtn/pbiYpJtgFihoZGeyL3Bk96NQmDh/pLZ4Z2/CNEa7pRAMG/AB3GzwTWtqGABUMnGqwT39ARdzeXHVZEOFNo+6Bfy+ND2jblNMWiprt1+5bBXlUtB/wwWLk0Us1gOpr; 3:1FKO0oiukqlr518nJ5RLcFSjiti/kyN2wBcuK0DECo5uydbp8xBswdnr/yOaUvejv6Bic52UqSqrPcnCs5yyDxKABVAfIjGWFwtWPZCk+oWE73pq5xW5iZXjSrEWjo/V2XVGC1DMacL+IUMiUe4+26ihC9svyQKrxQin1Dbw63Sb7M2rqj/xfZKWckQ5bza+kVu7VrDFI/JIDk7IycD1Eanz+CkLa7tGFUNoclYH/w5B4raOcuuBwpICaAFHhDa7; 25:6QqiZ8qNm5H9lcKqjXJRN4z+w5hbPJ8o8KmuxC0haO+2YIADTP/WBpnE8X8pgufZaa3VHOHfgjy58KhqVZIg6BZ2meQFRMbKHV+PXxRbXp2k3e/EsWZCHLEYTdund7pdCdu81ZYVxAELY1xYLd+txJ5A0rSggdszNlf16RKmBVMUs5xmBpux2ZlwHXt77EvyAHxC75W7TAP8mZBG+8uMVl4dbqCXfdxs1hNu+TXeoOZJQq/wHhDCQzSZQ7WmyTtHzbcx9s+1qYlQGs3iD/bJqNpc+J9saiQ0mXh7ZF5TcTl3NreKgwB2d7i5YC/wlrmFAnn8ccI+PktJkDCxUiFtyA== X-DkimResult-Test: Passed X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(3001016); SRVR:DM2PR0301MB1296; X-Microsoft-Exchange-Diagnostics: 1; DM2PR0301MB1296; 20:PCHoFwpy7CW87AhQmXH3pMKu5+20TdxlzY1TVt2e+Er4MW+U6duey/5/zIhZwy74Vey85mpsem0GIZ1r5MqT/yEQqsGbEcdw1zz8jUBdETp4TyPc45FpptzzZlbXDP638cPYq+fsJS92DvU6Gk6iqmoLCQBwItC85xlqDRtycpc=; 4:2MyTZDAb4sMrjF9P0WOof43GEzEegRoioJSNJjcC9pAU9oYjODDnDALEGTaU+WklDxYHiA9YpCw+X76iKlCdeEFdmXHe2mvczd5yj5xB1aptPNsOQOnXKSlYfBM25hfN+BU60U2j0556nvGzX9akCZiLRGDRCAaYjcUCFnIAkeb83oOhz7zy+MpPnOE+a3JDcvtNibIUiNundde/u/OSyI/fmAlWT3xnOsmrKRGbuyW2b+ERuBv05hQ9EHs4a+o0HB//k2fCHZKQI7uo5hKDX1hPn+mJYrFU1B2Hd6gAsh742UtE0/GJl7CspQM9M26SyJ1lev8jtY/JpIoZTqNox0CcKwLw/MF9o6Q/i3ZdLGPd11DgsCprCn0LQsfHk1GOio9mWMq1sALa8vZxJTbDKv0+t4fyJOgnKaLLzUbhKg5RWaC0bbenWR8VHItlvvBBhiqSoLazqtjRqplLMaef9A== X-Forefront-PRVS: 0905A6B2C7 X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; DM2PR0301MB1296; 23:TKmma/MOqa9dCG2dpz5kgIRMBXZzFFaX+2mp8MA?= =?us-ascii?Q?TYMlDnOcZktJ5enZwxAyYySW4tnIc6KixZZrr/gptRZuz0REKPtOBOb1MkFu?= =?us-ascii?Q?vwq6TrnnRMgV7/LlQigM4UoUA1UXKlCcfvKLYt0YE74gXPCi+oAtTFRlVj5I?= =?us-ascii?Q?EurcrwmkFgjnjs12oBEYljdlTcOAsVJH/rMlDz7ABQf9r902vYvtJWYWJV5L?= =?us-ascii?Q?gOCccJLzKBNt7OXv0SqhHGPAghCRaD8Ja8Z3BANHdJ7EwRU4OPq4IiFMF4ZS?= =?us-ascii?Q?CwmJRoRQtgF543215LnRCq+1HqEsgZm2QIgv1ZCG78OiXDsmGPNtc3SXOWwC?= =?us-ascii?Q?GCW9xRwDhQNAdSTMZAq95S3pF1HVh1h7mTVtgcEvCvrSa4BHjHZsjmF82TSY?= =?us-ascii?Q?r5AMMSIW2tHaQQO/dOwQWysi9DgX+zerMSX9W1/2ateP+1A71BlTFQdz6Sr3?= =?us-ascii?Q?EczBK5PkgdCPjEIkM/jttCA7/5a3b+3fnYXFb2ntdcI++/w63rY2M+XEovH9?= =?us-ascii?Q?ru30305FnTKrtFKzjiUAV/e9y0i0pWfpqWR4bUiuRkw90XWXFZQmGGkTmJgp?= =?us-ascii?Q?QABpBoGDT4lcnEBgoKiHhI78AcP8qO+Mi+XbZR3W1uq+q+yGo2RFzT6lN+7V?= =?us-ascii?Q?QAgj/t0mH68keTVx0Xtzs89vByWDAI7zbbEojkhmXkK7NwT+2cz+WAlW3gA2?= =?us-ascii?Q?ZZ+L174K7QRdW6ILelg7uxA6L8/Yz2eL7SQr3yFeTkvnQ6MVX0VAujsOYfk4?= =?us-ascii?Q?thth6pFLG806XiV4NV1LYXd0Z6gOeO8S4btZXy/f/A+pYYp4UPxUNP38vPz6?= =?us-ascii?Q?DEupC/Q94dcJRfHMEbx68MlpGZtLNoxqQ3B4YF2838LdOYBta24pIcmI2lXe?= =?us-ascii?Q?q5c9a8yoLfwb0GxWmNDol5loaD+52eUgl8E0Fzzg6irgOxa1OXlXMgJWBrfP?= =?us-ascii?Q?MiKtXklgUicdCJaXtm+EvoFCMLRUTwU85pRsh46Bu2XQh1/p4wWgiKf19AQm?= =?us-ascii?Q?nkRPk44fQ6TJhhak7aM5Bbv/eQFvg9fvdm8Eo0mA9IBqxAcZKscXE1cnJtgd?= =?us-ascii?Q?MIVp1XwX+kgKflKOaM3UTpEftTzNfasyx1NLKQhi3M/tJSctzfJEzQpml+sh?= =?us-ascii?Q?Fy2K/UuU6212SjaIXNiiJAzePtOQTcP2YKc6CTsuRPdUaZy7MMqnegaY1bs3?= =?us-ascii?Q?uvbC9uTk/4p4k5caNFymRzMJXUXeaJmGyRI6iTY5NpvA3+HWLWOSlhIn2wUY?= =?us-ascii?Q?eEYo3Q4QyBWmIhOn5rdhSEyWStylW4fYBBwHh4f2cWwgYgQEJBatvP6bBPzV?= =?us-ascii?Q?FgOpGvRYmpTeCv1Odk3QfiKeF7Q+tnXeWwKoYpclBeaPgXcoBbP/cMSGb/gJ?= =?us-ascii?Q?nSG2o3w=3D=3D?= X-Microsoft-Exchange-Diagnostics: 1; DM2PR0301MB1296; 5:HCqszk01DktY+un96c3d/g17iQa6wwX9JXzr4uW2biRGoQ5HB1mM3+letgFKzXbFefKiF+WfFL/I3rjKCxz8Tm55UO6UqX3zy9ziR9vy5eVr7EymTlTDaGdx7iysajwrGJMniSTweUEXOxaK1uAA1g==; 24:J77kQEjqI0qbJOmz9yg6dsbXOzK9APTKBVNc+q592Akt4me5FowqACOjCPG8d//8QYrL1VeQ7D6Pos8EjnD+/RyFXfhhKHx6e7Ms9SnevTM=; 20:ga9fWv4587G1IzHEYRWJtH+1ung4srbHFARevQShsCEtzELNWt82sjhn2QULPlm6xPQfLZ+UEAdIIPqAGOk0xyIDIvcbYEdKtBfB+iRkxDVwSTGcJP2jAGlNjiS+Cpu4lzZ6+IWP4um2Vb9HsgTJ2yGg0r9INo182IpXKdeNuPs= X-OriginatorOrg: opensource.altera.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 07 Apr 2016 01:05:17.5388 (UTC) X-MS-Exchange-CrossTenant-Id: fbd72e03-d4a5-4110-adce-614d51f2077a X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=fbd72e03-d4a5-4110-adce-614d51f2077a; Ip=[66.35.236.227]; Helo=[sj-itexedge03.altera.priv.altera.com] X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM2PR0301MB1296 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20160406_180541_855514_9F1DF011 X-CRM114-Status: UNSURE ( 7.17 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -1.9 (-) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: tthayer@opensource.altera.com, linux-arm-kernel@lists.infradead.org, linux-edac@vger.kernel.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Spam-Status: No, score=-5.1 required=5.0 tests=BAD_ENC_HEADER,BAYES_00, DKIM_SIGNED,RCVD_IN_DNSWL_MED,RP_MATCHES_RCVD,T_DKIM_INVALID, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Thor Thayer Enable ECC for Arria10 On-Chip RAM on machine startup. The ECC has to be enabled and memory initialized before data is stored in memory otherwise the ECC will fail on reads. Signed-off-by: Thor Thayer Acked-by: Dinh Nguyen --- v3: Add iounmap() and make ecc functions static inline. v2: Add Arria10 ECC block initialization locally. --- arch/arm/mach-socfpga/ocram.c | 133 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 133 insertions(+) diff --git a/arch/arm/mach-socfpga/ocram.c b/arch/arm/mach-socfpga/ocram.c index 60ec643..10d6732 100644 --- a/arch/arm/mach-socfpga/ocram.c +++ b/arch/arm/mach-socfpga/ocram.c @@ -13,12 +13,15 @@ * You should have received a copy of the GNU General Public License along with * this program. If not, see . */ +#include #include #include #include #include #include +#include "core.h" + #define ALTR_OCRAM_CLEAR_ECC 0x00000018 #define ALTR_OCRAM_ECC_EN 0x00000019 @@ -47,3 +50,133 @@ void socfpga_init_ocram_ecc(void) iounmap(mapped_ocr_edac_addr); } + +/* Arria10 OCRAM Section */ +#define ALTR_A10_ECC_CTRL_OFST 0x08 +#define ALTR_A10_OCRAM_ECC_EN_CTL (BIT(1) | BIT(0)) +#define ALTR_A10_ECC_INITA BIT(16) + +#define ALTR_A10_ECC_INITSTAT_OFST 0x0C +#define ALTR_A10_ECC_INITCOMPLETEA BIT(0) +#define ALTR_A10_ECC_INITCOMPLETEB BIT(8) + +#define ALTR_A10_ECC_ERRINTEN_OFST 0x10 +#define ALTR_A10_ECC_SERRINTEN BIT(0) + +#define ALTR_A10_ECC_INTSTAT_OFST 0x20 +#define ALTR_A10_ECC_SERRPENA BIT(0) +#define ALTR_A10_ECC_DERRPENA BIT(8) +#define ALTR_A10_ECC_ERRPENA_MASK (ALTR_A10_ECC_SERRPENA | \ + ALTR_A10_ECC_DERRPENA) +/* ECC Manager Defines */ +#define A10_SYSMGR_ECC_INTMASK_SET_OFST 0x94 +#define A10_SYSMGR_ECC_INTMASK_CLR_OFST 0x98 +#define A10_SYSMGR_ECC_INTMASK_OCRAM BIT(1) + +#define ALTR_A10_ECC_INIT_WATCHDOG_10US 10000 + +static inline void ecc_set_bits(u32 bit_mask, void __iomem *ioaddr) +{ + u32 value = readl(ioaddr); + + value |= bit_mask; + writel(value, ioaddr); +} + +static inline void ecc_clear_bits(u32 bit_mask, void __iomem *ioaddr) +{ + u32 value = readl(ioaddr); + + value &= ~bit_mask; + writel(value, ioaddr); +} + +static inline int ecc_test_bits(u32 bit_mask, void __iomem *ioaddr) +{ + u32 value = readl(ioaddr); + + return (value & bit_mask) ? 1 : 0; +} + +/* + * This function uses the memory initialization block in the Arria10 ECC + * controller to initialize/clear the entire memory data and ECC data. + */ +static int altr_init_memory_port(void __iomem *ioaddr) +{ + int limit = ALTR_A10_ECC_INIT_WATCHDOG_10US; + + ecc_set_bits(ALTR_A10_ECC_INITA, (ioaddr + ALTR_A10_ECC_CTRL_OFST)); + while (limit--) { + if (ecc_test_bits(ALTR_A10_ECC_INITCOMPLETEA, + (ioaddr + ALTR_A10_ECC_INITSTAT_OFST))) + break; + udelay(1); + } + if (limit < 0) + return -EBUSY; + + /* Clear any pending ECC interrupts */ + writel(ALTR_A10_ECC_ERRPENA_MASK, + (ioaddr + ALTR_A10_ECC_INTSTAT_OFST)); + + return 0; +} + +void socfpga_init_arria10_ocram_ecc(void) +{ + struct device_node *np; + int ret = 0; + void __iomem *ecc_block_base; + + if (!sys_manager_base_addr) { + pr_err("SOCFPGA: sys-mgr is not initialized\n"); + return; + } + + /* Find the OCRAM EDAC device tree node */ + np = of_find_compatible_node(NULL, NULL, "altr,socfpga-a10-ocram-ecc"); + if (!np) { + pr_err("Unable to find socfpga-a10-ocram-ecc\n"); + return; + } + + /* Map the ECC Block */ + ecc_block_base = of_iomap(np, 0); + of_node_put(np); + if (!ecc_block_base) { + pr_err("Unable to map OCRAM ECC block\n"); + return; + } + + /* Disable ECC */ + writel(ALTR_A10_OCRAM_ECC_EN_CTL, + sys_manager_base_addr + A10_SYSMGR_ECC_INTMASK_SET_OFST); + ecc_clear_bits(ALTR_A10_ECC_SERRINTEN, + (ecc_block_base + ALTR_A10_ECC_ERRINTEN_OFST)); + ecc_clear_bits(ALTR_A10_OCRAM_ECC_EN_CTL, + (ecc_block_base + ALTR_A10_ECC_CTRL_OFST)); + + /* Ensure all writes complete */ + wmb(); + + /* Use HW initialization block to initialize memory for ECC */ + ret = altr_init_memory_port(ecc_block_base); + if (ret) { + pr_err("ECC: cannot init OCRAM PORTA memory\n"); + goto exit; + } + + /* Enable ECC */ + ecc_set_bits(ALTR_A10_OCRAM_ECC_EN_CTL, + (ecc_block_base + ALTR_A10_ECC_CTRL_OFST)); + ecc_set_bits(ALTR_A10_ECC_SERRINTEN, + (ecc_block_base + ALTR_A10_ECC_ERRINTEN_OFST)); + writel(ALTR_A10_OCRAM_ECC_EN_CTL, + sys_manager_base_addr + A10_SYSMGR_ECC_INTMASK_CLR_OFST); + + /* Ensure all writes complete */ + wmb(); +exit: + iounmap(ecc_block_base); +}