Date: Mon, 05 Oct 2009 13:47:50 +0000 From: Tom Judge <tom@tomjudge.com> To: Olivier Houchard <mlfbsd@ci0.org> Cc: freebsd-hackers@freebsd.org Subject: Re: Help debugging: Fatal kernel mode data abort: 'External Linefetch Abort (P)' Message-ID: <4AC9F906.3040306@tomjudge.com> In-Reply-To: <20091004223433.GA73189@ci0.org> References: <4AC106AA.9000305@tomjudge.com> <20090928202132.GA15236@ci0.org> <4AC16B5A.8090407@tomjudge.com> <20090929093825.GA26424@ci0.org> <4AC21F44.6060004@tomjudge.com> <20091004223433.GA73189@ci0.org>
next in thread | previous in thread | raw e-mail | index | archive | help
This is a multi-part message in MIME format. --------------050000070909080403010604 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Olivier Houchard wrote: >> Hi Olivier, >> >> I have tried the patch and here are the boot results: >> >> <SNIP> >> > > I fail to see how it happens. > Could you printf the value of sc->sc_mem once set in i80321_pci_attach(), > and if it appears to be 0, the value of i80321_softc->sc_owin[0].owin_xlate_lo > at the different points it can be set ? > > Thanks a lot, > > Olivier > Hi Olivier, I have been working though this with Mark Tinguely and we came up with this patch that makes it work. Not sure on its correctness but it works. Tom --------------050000070909080403010604 Content-Type: text/plain; name="pci-1.patch" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="pci-1.patch" Index: i80321_pci.c =================================================================== --- i80321_pci.c (revision 197735) +++ i80321_pci.c (working copy) @@ -92,8 +92,7 @@ sc->sc_busno = busno; sc->sc_pciio = &i80321_softc->sc_pci_iot; sc->sc_pcimem = &i80321_softc->sc_pci_memt; - sc->sc_mem = i80321_softc->sc_owin[0].owin_xlate_lo + - VERDE_OUT_XLATE_MEM_WIN_SIZE; + sc->sc_mem = i80321_softc->sc_owin[0].owin_xlate_lo; sc->sc_io = i80321_softc->sc_iow_vaddr; /* Initialize memory and i/o rmans. */ @@ -110,7 +109,8 @@ sc->sc_mem_rman.rm_descr = "I80321 PCI Memory"; if (rman_init(&sc->sc_mem_rman) != 0 || rman_manage_region(&sc->sc_mem_rman, - 0, VERDE_OUT_XLATE_MEM_WIN_SIZE) != 0) { + VERDE_OUT_XLATE_MEM_WIN0_BASE, + VERDE_OUT_XLATE_MEM_WIN0_BASE + VERDE_OUT_XLATE_MEM_WIN_SIZE) != 0) { panic("i80321_pci_probe: failed to set up memory rman"); } sc->sc_irq_rman.rm_type = RMAN_ARRAY; @@ -297,6 +297,9 @@ sc->sc_mem; start &= (0x1000000 - 1); end &= (0x1000000 - 1); + start += 0x80000000; + end += 0x80000000; + device_printf(child, "SYS_RES_MEMORY: start: 0x%08lX end: 0x%08lX\n",start,end); break; case SYS_RES_IOPORT: rm = &sc->sc_io_rman; @@ -312,12 +315,15 @@ } rv = rman_reserve_resource(rm, start, end, count, flags, child); + device_printf(child, "RMAN_RESERVE_RESOURCE: start: 0x%08lX end: 0x%08lX\n", + rman_get_start(rv), + rman_get_end(rv)); if (rv == NULL) return (NULL); rman_set_rid(rv, *rid); if (type != SYS_RES_IRQ) { if (type == SYS_RES_MEMORY) - bh += (rman_get_start(rv)); + bh = (rman_get_start(rv)); rman_set_bustag(rv, bt); rman_set_bushandle(rv, bh); if (flags & RF_ACTIVE) { --------------050000070909080403010604--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4AC9F906.3040306>