From patchwork Sun Jun 26 17:42:11 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Darren Stevens X-Patchwork-Id: 640713 Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from lists.ozlabs.org (lists.ozlabs.org [103.22.144.68]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3rd1H01thwz9sRZ for ; Mon, 27 Jun 2016 04:45:48 +1000 (AEST) Received: from ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3]) by lists.ozlabs.org (Postfix) with ESMTP id 3rd1H015ZzzDqrK for ; Mon, 27 Jun 2016 04:45:48 +1000 (AEST) X-Original-To: linuxppc-dev@lists.ozlabs.org Delivered-To: linuxppc-dev@lists.ozlabs.org Received: from mout.kundenserver.de (mout.kundenserver.de [212.227.126.135]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by lists.ozlabs.org (Postfix) with ESMTPS id 3rd1Fm2zyczDqm9 for ; Mon, 27 Jun 2016 04:44:42 +1000 (AEST) Received: from mintppc.lan ([86.169.226.157]) by mrelayeu.kundenserver.de (mreue001) with ESMTPA (Nemesis) id 0LmiNA-1bpVV12fOu-00h66r; Sun, 26 Jun 2016 20:42:19 +0200 From: Darren Stevens To: linuxppc-dev@lists.ozlabs.org Date: Sun, 26 Jun 2016 18:42:11 +0100 (BST) Message-ID: <4863e2f8235.599ebfcf@auth.smtp.1and1.co.uk> User-Agent: YAM/2.9p1 (AmigaOS4; PPC; rv:20140418r7798) Subject: Proposed: Patch to fix boot on PA6T MIME-Version: 1.0 Content-type: multipart/mixed; boundary="--=_BOUNDARY.6d401b301879572c.5f" X-Provags-ID: V03:K0:ts9caAAeT1jpDEu2UJbFtbThBF6jrQUFOwLOg1Fat2NiJ/YA/BR x1qgNNiGnB6PbQw4C6SETCNGWlG+N9O7+9g8F9wFCqZhhjLrcSEJnPkSt7sm2Pzjtajd2db vgSHAvAs3MkBe1zG1ed/R40d0SgDwrYh9u8uqu5wfd4NERcFzqMi7isTaGo/eZWcGR2+e3l S85fZ6jF1ZjOnibg1rJPQ== X-UI-Out-Filterresults: notjunk:1; V01:K0:ZtGNsAvB3Uw=:t0ZRb6o/l33XhtMINqH6M+ RRBrtsffagk7JzXEr2Z6BVZFZ6sHxzWw5N8xmxm36fz0vy3SPsM3wubft9WaZzZAFkL+xDAr+ bjtGiw71crG1a4faPWMjxh5PEHwpsfSJ0Khu4p4B9ikLzMxm+1hXiBH6dVWjYjxMP4fXoGY7r ZvkLI8gXEAYhuZCepeMCAlwbCZnj1Aog0lsl9vWgdUyjVPjwl5zlPGcMwvnZGOcdQLAak7fGz LNob17+fZJ/eaXpZdcc36uC08KPsU4R6s34qlYxNhl/uHl+R6UksEhIzCbtP3hhyMVcM3o/RD EjKcp8kP8oPDz1N3UPv7YlFbab9Cgd1cVS8xfkQyGqB6G+Xva9UKYG4nyqokhpfIrmTLNP4dN V2mi8BaZ/mvNaxp4N6OcEnLvYT5UsJd2jI/XRxTK06LyV60mRUr5lbjIeqK6+Y1/mmvGstwFM K3GJ20XJj9x9CvGvdKfWCGEgeaBQHXfOuWXbs5hE7t6CgC0L/XodCOkfFJt9uEsU5SBxB21Of F0n6Z4ZJdiNUXa/LmyoNjEmKEsqUc6qZvWezlhG1et5KwBizw0Z47w+7aO3NhGGqDN1cYuGue 9vI4fx6DK71zSmSxlUQnc7XW0KPMiX8z5VtwTzjRUMKmgjapsoC6og7v/NZn19XT6XzvbnqDU I5u4c/8gfZbhl6r3qeHcXBAIIShBYyLZI1qTZHkharRXyZK6IlHO2BzYYSJe1xk++34g= X-BeenThere: linuxppc-dev@lists.ozlabs.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Pat Wall , matthew@a-eon.com, aperez@alexperez.com, "R.T.Dickinson" , Christian Zigotzky Errors-To: linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org Sender: "Linuxppc-dev" Hello All, commit d6a9996e84ac4beb7713e9485f4563e100a9b03e powerpc/mm: vmalloc abstraction in preparation for radix This commit introduced variables for some linux kernel addresses that had before been constants, unfortunately this stopped PaSemi PA6T systems(*) from booting as they call ioremap to map SoC registers before the mmu is initialised. The attached patch adds a hard-coded init of pci_io_base to the pas_init_early() function which which allows the kernel to boot normally. The value will be harmlessly set again once pci starts up. (*) At the moment this has only been tested on an AmigaOneX1000, but I expect PaSemi reference systems to have been affected in the same way. Kind regards Darren diff --git a/arch/powerpc/platforms/pasemi/setup.c b/arch/powerpc/platforms/pasemi/setup.c index d71b2c7..6b8d2ab 100644 --- a/arch/powerpc/platforms/pasemi/setup.c +++ b/arch/powerpc/platforms/pasemi/setup.c @@ -61,6 +61,7 @@ static struct mce_regs mce_regs[MAX_MCE_REGS]; static int num_mce_regs; static int nmi_virq = NO_IRQ; +extern unsigned long pci_io_base; static void pas_restart(char *cmd) { @@ -341,6 +342,10 @@ out: static void __init pas_init_early(void) { + /* Initialise the IO pointer so we don't crash on boot */ + + pci_io_base = (H_KERN_VIRT_START + (H_KERN_VIRT_SIZE >> 1)); + iommu_init_early_pasemi(); }