From owner-freebsd-arm@FreeBSD.ORG Tue Sep 4 19:12:59 2012 Return-Path: Delivered-To: freebsd-arm@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 6D852106566B; Tue, 4 Sep 2012 19:12:59 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from bigwig.baldwin.cx (bigknife-pt.tunnel.tserv9.chi1.ipv6.he.net [IPv6:2001:470:1f10:75::2]) by mx1.freebsd.org (Postfix) with ESMTP id 432078FC1A; Tue, 4 Sep 2012 19:12:59 +0000 (UTC) Received: from jhbbsd.localnet (unknown [209.249.190.124]) by bigwig.baldwin.cx (Postfix) with ESMTPSA id 64968B972; Tue, 4 Sep 2012 15:12:58 -0400 (EDT) From: John Baldwin To: freebsd-hackers@freebsd.org Date: Tue, 4 Sep 2012 12:05:19 -0400 User-Agent: KMail/1.13.5 (FreeBSD/8.2-CBSD-20110714-p17; KDE/4.5.5; amd64; ; ) References: In-Reply-To: MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Message-Id: <201209041205.19794.jhb@freebsd.org> X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.7 (bigwig.baldwin.cx); Tue, 04 Sep 2012 15:12:58 -0400 (EDT) Cc: freebsd-arm@freebsd.org, Aleksander Dutkowski Subject: Re: availability of interrupts during bootup process X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to the StrongARM Processor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Sep 2012 19:12:59 -0000 On Sunday, September 02, 2012 5:31:21 pm Aleksander Dutkowski wrote: > hello! > > I have PMIC (TWL4030) module connected to the SoC (ARM/OMAP3) via i2c (iicbus). > Current solution is that i2c_attach calls bus_generic_attach(dev); > which calls my pmic probe/attach functions, but main configuration of > PMIC in done after drivers setup by config_intrhook. > But I need it to be configured during device attaching, because usb > ehci driver depends on it. > Is it possbile? I've tried it but it hangs on waiting for i2c > interrupt, but someone told me, that interrupts are available during > bootup for some time. No, interrupts do not work during bootup. If you can poll your hardware you could use polling until interrupts are enabled (using 'if (cold)' to check for the boot time before interrupts are enabled). -- John Baldwin