From owner-freebsd-arm@FreeBSD.ORG Sun Mar 3 04:21:06 2013 Return-Path: Delivered-To: freebsd-arm@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id B0C709D5 for ; Sun, 3 Mar 2013 04:21:06 +0000 (UTC) (envelope-from imp@bsdimp.com) Received: from mail-ie0-x234.google.com (mail-ie0-x234.google.com [IPv6:2607:f8b0:4001:c03::234]) by mx1.freebsd.org (Postfix) with ESMTP id 720EA28C for ; Sun, 3 Mar 2013 04:21:06 +0000 (UTC) Received: by mail-ie0-f180.google.com with SMTP id bn7so5089512ieb.11 for ; Sat, 02 Mar 2013 20:21:06 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-received:sender:subject:mime-version:content-type:from :in-reply-to:date:cc:content-transfer-encoding:message-id:references :to:x-mailer:x-gm-message-state; bh=2dGcD423IgQYr0sWwQxAokqItfcbHkmP/YOVmMsry50=; b=aVo67bT3TzFSlAb9FSPQOnWEXaf2mVuFRewg3YgRHhPkG0BYxq5Sq6I+p8DM/zVzUF TjGM0VP9hzDJhvDH+UuvMD5os6TLoerdPNR8SkLv1s1DBiGrrLjFesZCpjEx5gkl3A57 QeJCUJeT5KwW1Nm9QI540dLsppj86ypVrtRsnymU9ODkhyp7w4mAhgZv2AtOVM085KVE 2mXOd5CBc/6G29iHzlx7YYAqp5Z9stfkLWYHSqCltq5pqL6SqEjikgfJjUu3DsELrhAW LkGORefLhPPnGAM834w1hd/C0zp74x47wYnwTWiRr8193Y51XpqCV/fVG/m7IsOaTOX+ krLw== X-Received: by 10.42.247.8 with SMTP id ma8mr19000182icb.1.1362284465882; Sat, 02 Mar 2013 20:21:05 -0800 (PST) Received: from 53.imp.bsdimp.com (50-78-194-198-static.hfc.comcastbusiness.net. [50.78.194.198]) by mx.google.com with ESMTPS id xe9sm4782124igb.7.2013.03.02.20.21.03 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Sat, 02 Mar 2013 20:21:05 -0800 (PST) Sender: Warner Losh Subject: Re: About board-specific files.* Mime-Version: 1.0 (Apple Message framework v1085) Content-Type: text/plain; charset=windows-1252 From: Warner Losh In-Reply-To: <20130303163139.3af41ae5@bender> Date: Sat, 2 Mar 2013 21:21:01 -0700 Content-Transfer-Encoding: quoted-printable Message-Id: <83771FC1-9729-4DFF-A336-B61F4FD32368@bsdimp.com> References: <58FF3A9F-2782-429F-BE82-27728E8D209D@bsdimp.com> <20130303163139.3af41ae5@bender> To: Andrew Turner X-Mailer: Apple Mail (2.1085) X-Gm-Message-State: ALoCoQkdpUdoZzqDDJh2Q1pwQaQ7M/y7WwSg8uyywHfEzbSn4zZxuIy8ha8WAjQ+Qd6lyx5Dbygn Cc: freebsd-arm@freebsd.org X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Porting FreeBSD to the StrongARM Processor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 03 Mar 2013 04:21:06 -0000 On Mar 2, 2013, at 8:31 PM, Andrew Turner wrote: > On Sat, 2 Mar 2013 16:20:54 -0700 > Warner Losh wrote: >=20 >>=20 >> On Mar 2, 2013, at 2:05 PM, Tim Kientzle wrote: >>=20 >>> Now that I think I understand some of the issues in building >>> a GENERIC arm kernel, I'm starting to piece together >>> a kernel that has both RPi and BBone bits that I can >>> use as a testbed. >>>=20 >>> Next Problem: A lot of the boards are using >>> board-specific files.* to control what files get >>> linked into the kernel. >>>=20 >>> This seems like a real problem for a GENERIC kernel, >>> so I propose merging them into sys/conf/files.arm. >>>=20 >>> Here's how I'm doing it right now for my current >>> experiments. If anyone has a better idea, I'm >>> definitely interested. >>>=20 >>> Basically, I'm using "device bcm2835" to represent >>> all of the basic support for that particular SoC. >>> (An SoC is, after all, just another piece of hardware.) >>>=20 >>> Then the files marked "standard" in >>> arm/bcm2835/files.bcm2835 move to >>> files.arm as "optional bcm2835". >>>=20 >>> With this approach, the GENERIC arm kernel will >>> list the SoCs as devices: >>>=20 >>> device bcm2835 >>> device am335x >>> device omap4 >>> =85 etc =85 >>>=20 >>> That will bring in the basic support for those SoCs >>> (e.g., interrupt handler, gpio, clock management, etc). >>> Additional drivers (SDHCI, UART, USB, etc) will >>> be separate devices. >>>=20 >>> I think this makes sense, but I'm open to other ideas. >>=20 >> I think this is perfect. It is what atmel uses to bring in different >> atmel things. I don't think there are any atmel files specified as >> std any more, and if there are they could transition to this. I know >> this isn't an issue for a GENERIC for armv6, since there is not way >> an armv4 and an armv6 kernel could be built today... >=20 > I don't think that is a problem. We can have two GENERIC kernels, i.e. > an arm and an armv6 kernel. Having two GENERIC like kernels doesn't > preclude having a single GENERIC in the future, quite the opposite. We > are unlikely to have a GENERIC kernel for any hardware that doesn't > have fdt, or some other way to detect which SoC & board we are running > on. Yes. I'd love to see Atmel move to FDT, but my time for hacking that = lately has meant almost no progress. For other, older armv4/5 parts, = those could be part of LINT, but not GENERIC, or we can drop support for = them... Warner Warner=