Subject: Re: Atheros HAL vs NetBSD
To: Quentin Garnier <cube@cubidou.net>
From: Andrew Doran <ad@netbsd.org>
List: tech-kern
Date: 08/25/2007 01:45:27
On Sat, Aug 25, 2007 at 02:07:53AM +0200, Quentin Garnier wrote:

> On Fri, Aug 24, 2007 at 11:52:11PM +0000, Andrew Doran wrote:
> > 
> > Module Name:	src
> > Committed By:	ad
> > Date:		Fri Aug 24 23:52:11 UTC 2007
> > 
> > Modified Files:
> > 	src/sys/arch/mips/mips: genassym.cf mipsX_subr.S
> > 	src/sys/contrib/dev/ath/netbsd: ah_osdep.c
> > 
> > Log Message:
> > The Atheros HAL on MIPS uses %s7 as a general purpose register, but the
> > rest of the kernel uses it to store the value of curlwp. Sam won't
> > recompile the HAL for us (fair enough), and we can't modify the HAL
> > to use another register because doing so could put us in breach of
> > the license (v. crappy). So, do a save/set/restore on %s7 in KernIntr()
> > and in the stubs that the HAL uses to call back into the kernel.
> 
> So NetBSD is a second-class citizen for a binary blob whose licence, as
> friendly as it might be to end users, is a pain in NetBSD's own
> developers' necks.
> 
> That _should_ teach us a lesson.  I won't go as far as daring hoping it
> will, but it definitely should.

I don't have any strong feelings about blobs. Anyway, here's my perspective:
I found it frustrating because it has wasted a lot of our time in figuring
out what the issue is, figuring out how to fix it, implmenting a workaround,
and then testing that.

Ultimatley the main thing is that Atheros cards work on NetBSD and that our
users don't experience difficulty over it. I hope that people know by know
that if they're buying a wireless card that will be used with a free OS,
then they should support manufacturers that make their specifications freely
available.

(Even then, within the indivudal manufacturers there are different groups
and different people. One personal experience I had was with Adaptec. In
that case we had great trouble before getting specs from one group, another
group was more than happy to provide documentation, test boards, low level
information .. anything that we needed. YMMV.)

Thanks,  
Andrew