Date: Fri, 8 Jun 2007 08:14:16 +0200 (CEST) From: =?iso-8859-1?Q?Bj=F6rn_K=F6nig?= <bkoenig@alpha-tierchen.de> To: arm@freebsd.org Cc: ticso@cicely12.cicely.de Subject: Re: 4-bit SD Card mode Message-ID: <60893.2001:6f8:101e:0:20e:cff:fe6d:6adb.1181283256.squirrel@webmail.alpha-tierchen.de> In-Reply-To: <20070607.140054.74667648.imp@bsdimp.com> References: <49754.2001:6f8:101e:0:20e:cff:fe6d:6adb.1181244172.squirrel@webmail.alpha-tierchen.de> <20070607.133456.74668036.imp@bsdimp.com> <20070607123930.E75948@synthcom.com> <20070607.140054.74667648.imp@bsdimp.com>
index | next in thread | previous in thread | raw e-mail
Warner Losh skrev: > My hardware guys are somewhat agressive in their elimination of > "unused" lines. We multiplex TX/RX from one of the serial ports to be > GPIO lines dynamically at run time depending on what add-in hardware > is connected to the box. I want to keep things as flexible as > possible because I know that other designs are doing similar "icky" > things. Ok, I thought about the topic a bit over night. On the one hand I understand your concern that we can't probe for pins whether they are connected or not; this characterises a significant difference between embedded hardware and PC hardware. On the other hand the problem remains if we make the loader responsible for configuring the PIO controller, because board-specific configuration is necessary in any case. Shifting a task is not a solution, especially if we want to stay independend of the loader. I understand the loader as a very small piece of software for bootstraping. Usually it is lean and mean as much as possible and does only things that are really necessary to go on with loading the operating system, not to be able using specific hardware. Actually neither the loader nor the kernel is responsible for making those kind of decisions, but rather the user has to attend this duty. Since the FreeBSD kernel is more flexible and highly configurable in contrast to any loader I still hold the view that the kernel should give the ability to configure the PIO controller. I agree with you that it is impossible and unjustifiable to make unprovable assumptions about the hardware that may cause damage or unexpected behaviour (I like to apologise for suggesting such code ;-). The best solution that I see is to provide a way to specify the hardware without patching the kernel and without requiring special bits from the loader. This should happen directly or indirectly in the kernel configuration file. I'm still concerned about this, so I'll provide some code that takes your objection into account. Regards Björnhelp
