Subject: Re: ichlpcib TCO (watchdog) support for ICH6 or newer
To: Quentin Garnier <cube@cubidou.net>
From: Juan RP <juan@xtrarom.org>
List: current-users
Date: 08/17/2007 17:43:32
On Fri, 17 Aug 2007 17:03:34 +0200
Quentin Garnier <cube@cubidou.net> wrote:

> On Fri, Aug 17, 2007 at 01:51:17PM +0200, Juan RP wrote:
> > 
> > Hi,
> > 
> > I added support for the TCO (watchdog) on ICH6 or newer chipsets,
> > adapter from FreeBSD and verified with the datasheet.
> > 
> > I tested it with ICH7 and works fine (you can test it by adding
> > a timeout of X seconds and skipping the bus_space_write_X() in
> > tcotimer_tickle() to the TCO_RLD register).
> > 
> > I'm interested in reports about this working on ICH5 or older.
> > Please test and let me know if there's some problem, I'll commit
> > it in 1st September if there are no complaints or other problems.
> > 
> > http://www.netbsd.org/~xtraeme/tco_ich6plus.diff
> 
> As a general rule, don't hold resources for longer than necessary, i.e.
> free them as soon as you know you won't use them.
> 
> So please unmap the regions you won't be using anymore, either because
> there is an error or because you're done with them.  Along those lines,
> don't keep stuff in the softc you won't actually be using outside of
> initialisation.

You are right, I forgot to call bus_space_unmap(). It's fixed on this
patch, and I verified working with ICH7.

Please review... I'm really out for holidays now:

http://www.netbsd.org/~xtraeme/tco_ich6plus2.diff

Thanks.

-- 
Juan Romero Pardines	- The NetBSD Project
http://plog.xtrarom.org	- NetBSD/pkgsrc news in Spanish