From owner-svn-src-head@FreeBSD.ORG Mon Oct 27 15:27:43 2008 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E113C1065684; Mon, 27 Oct 2008 15:27:43 +0000 (UTC) (envelope-from xcllnt@mac.com) Received: from asmtpout021.mac.com (asmtpout021.mac.com [17.148.16.96]) by mx1.freebsd.org (Postfix) with ESMTP id C9BE08FC1E; Mon, 27 Oct 2008 15:27:43 +0000 (UTC) (envelope-from xcllnt@mac.com) MIME-version: 1.0 Content-transfer-encoding: 7BIT Content-type: text/plain; charset=US-ASCII; format=flowed Received: from srangarajan-lt.jnpr.net (natint3.juniper.net [66.129.224.36]) by asmtp021.mac.com (Sun Java(tm) System Messaging Server 6.3-7.03 (built Aug 7 2008; 32bit)) with ESMTPSA id <0K9E0012YLM37450@asmtp021.mac.com>; Mon, 27 Oct 2008 08:27:41 -0700 (PDT) Message-id: <0BBCA616-4F9D-48D5-9360-CACA69480632@mac.com> From: Marcel Moolenaar To: Stanislav Sedov In-reply-to: <20081027153345.d4e9dcad.stas@FreeBSD.org> Date: Mon, 27 Oct 2008 08:27:39 -0700 References: <200810250618.m9P6ICWl023370@svn.freebsd.org> <20081027153345.d4e9dcad.stas@FreeBSD.org> X-Mailer: Apple Mail (2.929.2) Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r184251 - in head/sys: conf dev/cfi sys X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 27 Oct 2008 15:27:44 -0000 On Oct 27, 2008, at 5:33 AM, Stanislav Sedov wrote: >> Add a driver for flash memory that implements to the Common Flash >> Memory Interface (CFI). The flash memory can be read and written >> to through /dev/cfi# and an ioctl() exists so processes can read >> the query information. >> The driver supports the AMD and Intel command set, though only >> the AMD command has been tested. >> >> Obtained from: Juniper Networks, Inc. > > Do you plan to introduce some infrastructure so other flash-like > drivers could be attached (e.g. non-CFI compliant, SPI flashes, etc)? > I've started working on such thing and don't want to do the duplicate > works, so if you have something in mind it's time to share:-) I have been thinking about it, but I don't have anything yet. As it is, I probably won't have the time for it either. If you started with something, then feel free to take cfi(4) and integrate it. Also, access to the raw flash is nice, but one typically uses it for various things. It would be great if we had an infrastructure in which we could allow access to the flash through more high-level interfaces. For example: The flash may contain U-Boot (possibly with embedded environment), FreeBSD loader, separate blocks for U-Boot environment, a file system, etc. Those parts of the flash that are used for disk-like storage should ideally be exposed through GEOM. Environments should ideally be exposed through a standardized interface so that we only have to write a single utility to modify environments. Open Firmware and/or EFI environment variables could then also be exposed through that interfaces, eliminating the need for drivers like powermc_nvram and special-purpose tools like nvram(8). It's not easy, but probably worth thinking about... > And thanks for this great work! You're welcome. I hope it's a good start... -- Marcel Moolenaar xcllnt@mac.com