Date: Wed, 16 Jun 2010 15:25:47 -0600 (MDT) From: "M. Warner Losh" <imp@bsdimp.com> To: andrew@fubar.geek.nz Cc: svn-src-head@FreeBSD.org, raj@FreeBSD.org, svn-src-all@FreeBSD.org, src-committers@FreeBSD.org Subject: Re: svn commit: r209129 - head/sys/arm/arm Message-ID: <20100616.152547.756786594356063577.imp@bsdimp.com> In-Reply-To: <20100616210344.47209ff2@bender> References: <201006131308.o5DD8NTA033564@svn.freebsd.org> <20100616210344.47209ff2@bender>
next in thread | previous in thread | raw e-mail | index | archive | help
In message: <20100616210344.47209ff2@bender> Andrew Turner <andrew@fubar.geek.nz> writes: : On Sun, 13 Jun 2010 13:08:23 +0000 (UTC) : Rafal Jaworowski <raj@FreeBSD.org> wrote: : : > Author: raj : > Date: Sun Jun 13 13:08:23 2010 : > New Revision: 209129 : > URL: http://svn.freebsd.org/changeset/base/209129 : > : > Log: : > Improve style. : > : > Modified: : > head/sys/arm/arm/nexus.c : > : > Modified: head/sys/arm/arm/nexus.c : > ============================================================================== : > --- head/sys/arm/arm/nexus.c Sun Jun 13 13:02:43 2010 : > (r209128) +++ head/sys/arm/arm/nexus.c Sun Jun 13 13:08:23 : > 2010 (r209129) @@ -107,6 +107,7 @@ static devclass_t : > nexus_devclass; static int : > nexus_probe(device_t dev) : > { : > + : > device_quiet(dev); /* suppress attach message for : > neatness */ : > mem_rman.rm_start = 0; : > @@ -116,7 +117,7 @@ nexus_probe(device_t dev) : > if (rman_init(&mem_rman) || rman_manage_region(&mem_rman, 0, : > ~0u)) panic("nexus_probe mem_rman"); : > : > - return (0); : > + return (BUS_PROBE_DEFAULT); : Changing the return value of nexus_probe from 0 to BUS_PROBE_DEFAULT : causes the following panic for me when the s3c24x0 driver calls : rman_init. The attached patch fixes it by moving the call to rman_init : from nexus_probe to nexus_attach. The reason is that softc is reset between probe/attach when a number that isn't 0 is returned, but doesn't when 0 is returned. Warner : Andrew : : KDB: debugger backends: ddb : KDB: current backend: ddb : Copyright (c) 1992-2010 The FreeBSD Project. : Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994 : The Regents of the University of California. All rights : reserved. FreeBSD is a registered trademark of The FreeBSD Foundation. : FreeBSD 9.0-CURRENT #10 r209128M: Wed Jun 16 20:47:22 NZST 2010 : andrew@bender:/usr/obj/arm/home/andrew/freebsd/svn/head/sys/LN2410SBC : arm WARNING: WITNESS option enabled, expect reduced performance. : CPU: ARM920T rev 0 (ARM9TDMI core) : DC enabled IC enabled WB enabled LABT : 16KB/32B 64-way Instruction cache : 16KB/32B 64-way write-back-locking-A Data cache : real memory = 67108864 (64 MB) : avail memory = 56320000 (53 MB) : s3c24x00 on motherboard : s3c24x00: Found S3C2410A CPU (Chip ID: 0x32410002) : s3c24x00: fclk 202 MHz hclk 101 MHz pclk 50 MHz : panic: Bad tailq NEXT(0xc068eab8->tqh_last) != NULL : KDB: enter: panic : [ thread pid 0 tid 100000 ] : Stopped at kdb_enter+0x44: ldrb r15, [r15, r15, ror r15]! : db> reset
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20100616.152547.756786594356063577.imp>