From owner-freebsd-ppc Sun Nov 3 16:49: 9 2002 Delivered-To: freebsd-ppc@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 821C037B4B5 for ; Sun, 3 Nov 2002 16:48:40 -0800 (PST) Received: from k6.locore.ca (k6.locore.ca [198.96.117.170]) by mx1.FreeBSD.org (Postfix) with ESMTP id 32BA843E7B for ; Sun, 3 Nov 2002 16:48:37 -0800 (PST) (envelope-from jake@k6.locore.ca) Received: from k6.locore.ca (jake@localhost.locore.ca [127.0.0.1]) by k6.locore.ca (8.12.5/8.12.5) with ESMTP id gA412qbd050813 for ; Sun, 3 Nov 2002 20:02:52 -0500 (EST) (envelope-from jake@k6.locore.ca) Received: (from jake@localhost) by k6.locore.ca (8.12.5/8.12.5/Submit) id gA412p1S050812 for ppc@freebsd.org; Sun, 3 Nov 2002 20:02:51 -0500 (EST) Date: Sun, 3 Nov 2002 20:02:51 -0500 From: Jake Burkholder To: ppc@freebsd.org Subject: loader patch Message-ID: <20021103200251.O22677@locore.ca> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i Sender: owner-freebsd-ppc@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Hi, I'd like to change the device representation in libofw to use the firmware paths directly, instead of converting to an internal respresentation. In particular this allows the full path for disks to be passed through to the firmware, instead of parsing and then reconstructing the slice and partition, the format of which may be machine dependent. Here is the patch. I updated the powerpc parts as best I could, not being able to compile it. What you need to do is add a dev_aliases array which maps firmware paths to loader device switches. The match is done on each component of the firmware device path. For example /pci@1f,4000/scsi@3/disk@0,0 matches disk /pci@1f,4000/network@1,1 matches net or network See the sparc64 dev_aliases in sparc64/loader/main.c. Paths which contain the character '@' have a leading device path. For example /etc/fstab refers to /etc/fstab on currdev /pci@1f,4000/scsi@3/disk@0,0/etc/fstab refers to /etc/fstab on /pci@1f,4000/scsi@3/disk@0,0 currdev will refer to a firmware device path, instead of the old contrived format, ie currdev=/pci@1f,4000/scsi@3/disk@1,0:a I would like to commit this in 1 week, re@ permitting. Jake Index: common/boot.c =================================================================== RCS file: /home/ncvs/src/sys/boot/common/boot.c,v retrieving revision 1.28 diff -u -r1.28 boot.c --- common/boot.c 11 Sep 2001 01:09:19 -0000 1.28 +++ common/boot.c 3 Nov 2002 04:23:32 -0000 @@ -291,7 +291,7 @@ if ((fd = open(lbuf, O_RDONLY)) < 0) return(1); - /* loop reading lines from /etc/fstab What was that about sscanf again? */ + /* loop reading lines from /etc/fstab What was that about sscanf again? */ error = 1; while (fgetstr(lbuf, sizeof(lbuf), fd) >= 0) { if ((lbuf[0] == 0) || (lbuf[0] == '#')) Index: ofw/common/main.c =================================================================== RCS file: /home/ncvs/src/sys/boot/ofw/common/main.c,v retrieving revision 1.2 diff -u -r1.2 main.c --- ofw/common/main.c 7 Oct 2001 13:22:18 -0000 1.2 +++ ofw/common/main.c 3 Nov 2002 17:11:58 -0000 @@ -32,7 +32,6 @@ #include "libofw.h" #include "bootstrap.h" -struct ofw_devdesc currdev; /* our current device */ struct arch_switch archsw; /* MI/MD interface boundary */ extern char end[]; @@ -123,41 +122,9 @@ printf("\n"); - switch (ofw_devicetype(bootpath)) { - case DEVT_DISK: - currdev.d_dev = &ofwdisk; - currdev.d_type = DEVT_DISK; - strncpy(currdev.d_kind.ofwdisk.path, bootpath, 64); - currdev.d_kind.ofwdisk.unit = ofwd_getunit(bootpath); - - if (currdev.d_kind.ofwdisk.unit == -1) { - printf("Could not locate boot device.\n"); - OF_exit(); - } - - break; - - case DEVT_NET: - currdev.d_dev = &netdev; - currdev.d_type = DEVT_NET; - strncpy(currdev.d_kind.netif.path, bootpath, 64); - /* XXX Only works when we only look for one net device */ - currdev.d_kind.netif.unit = 0; - - break; - - case DEVT_NONE: - default: - printf("\n"); - printf("Could not establish type of boot device.\n"); - OF_exit(); - /* NOTREACHED */ - break; - } - - env_setenv("currdev", EV_VOLATILE, ofw_fmtdev(&currdev), + env_setenv("currdev", EV_VOLATILE, bootpath, ofw_setcurrdev, env_nounset); - env_setenv("loaddev", EV_VOLATILE, ofw_fmtdev(&currdev), env_noset, + env_setenv("loaddev", EV_VOLATILE, bootpath, env_noset, env_nounset); setenv("LINES", "24", 1); /* optional */ Index: ofw/libofw/Makefile =================================================================== RCS file: /home/ncvs/src/sys/boot/ofw/libofw/Makefile,v retrieving revision 1.7 diff -u -r1.7 Makefile --- ofw/libofw/Makefile 13 May 2002 11:09:07 -0000 1.7 +++ ofw/libofw/Makefile 3 Nov 2002 18:33:21 -0000 @@ -3,9 +3,8 @@ LIB= ofw INTERNALLIB= true -SRCS= devicename.c elf_freebsd.c ofw_console.c ofw_copy.c ofw_devsearch.c \ - ofw_disk.c ofw_memory.c ofw_module.c ofw_net.c ofw_reboot.c \ - ofw_time.c openfirm.c +SRCS= devicename.c elf_freebsd.c ofw_console.c ofw_copy.c ofw_disk.c \ + ofw_memory.c ofw_module.c ofw_net.c ofw_reboot.c ofw_time.c openfirm.c CFLAGS+= -I${.CURDIR}/../../../../lib/libstand/ Index: ofw/libofw/devicename.c =================================================================== RCS file: /home/ncvs/src/sys/boot/ofw/libofw/devicename.c,v retrieving revision 1.10 diff -u -r1.10 devicename.c --- ofw/libofw/devicename.c 11 May 2002 21:30:46 -0000 1.10 +++ ofw/libofw/devicename.c 3 Nov 2002 06:11:39 -0000 @@ -30,7 +30,7 @@ #include #include "libofw.h" -static int ofw_parsedev(struct ofw_devdesc **, const char *, const char **); +static int ofw_parsedev(struct ofw_devdesc **, const char *, const char **); /* * Point (dev) at an allocated device specifier for the device matching the @@ -42,14 +42,13 @@ { struct ofw_devdesc **dev = (struct ofw_devdesc **)vdev; int rv; - + /* * If it looks like this is just a path and no * device, go with the current device. */ if ((devspec == NULL) || - (devspec[0] == '/') || - (strchr(devspec, ':') == NULL)) { + (strchr(devspec, '@') == NULL)) { if (((rv = ofw_parsedev(dev, getenv("currdev"), NULL)) == 0) && (path != NULL)) @@ -80,97 +79,35 @@ static int ofw_parsedev(struct ofw_devdesc **dev, const char *devspec, const char **path) { - struct ofw_devdesc *idev; + struct ofw_devdesc *idev; + struct dev_alias *da; struct devsw *dv; - int i, unit, slice, partition, err; - char *cp; - const char *np; - - /* minimum length check */ - if (strlen(devspec) < 2) - return(EINVAL); - - /* look for a device that matches */ - for (i = 0, dv = NULL; devsw[i] != NULL; i++) { - if (!strncmp(devspec, devsw[i]->dv_name, strlen(devsw[i]->dv_name))) { - dv = devsw[i]; - break; + const char *p; + const char **n; + int len; + + p = devspec; + while ((p = strchr(p, '/')) != NULL) { + p++; + for (da = dev_aliases; da->da_name != NULL; da++) { + if (strncmp(p, da->da_name, strlen(da->da_name)) == 0) { + dv = da->da_dsw; + goto found; + } } } + return(ENOENT); - if (dv == NULL) - return(ENOENT); +found: idev = malloc(sizeof(struct ofw_devdesc)); - err = 0; - np = (devspec + strlen(dv->dv_name)); - - switch(dv->dv_type) { - case DEVT_NONE: /* XXX what to do here? Do we care? */ - break; - - case DEVT_DISK: - unit = -1; - slice = -1; - partition = -1; - if (*np && (*np != ':')) { - unit = strtol(np, &cp, 10); /* next comes the unit number */ - if (cp == np) { - err = EUNIT; - goto fail; - } - if (*cp == 's') { /* got a slice number */ - np = cp + 1; - slice = strtol(np, &cp, 10); - if (cp == np) { - err = ESLICE; - goto fail; - } - } - if (*cp && (*cp != ':')) { - partition = *cp - 'a'; /* get a partition number */ - if ((partition < 0) || (partition >= MAXPARTITIONS)) { - err = EPART; - goto fail; - } - cp++; - } - } - if (*cp && (*cp != ':')) { - err = EINVAL; - goto fail; - } - - idev->d_kind.ofwdisk.unit = unit; - idev->d_kind.ofwdisk.slice = slice; - idev->d_kind.ofwdisk.partition = partition; - if (path != NULL) - *path = (*cp == 0) ? cp : cp + 1; - break; - - case DEVT_NET: - unit = 0; - - if (*np && (*np != ':')) { - unit = strtol(np, &cp, 0); /* get unit number if present */ - if (cp == np) { - err = EUNIT; - goto fail; - } - } - if (*cp && (*cp != ':')) { - err = EINVAL; - goto fail; - } - - idev->d_kind.netif.unit = unit; - if (path != NULL) - *path = (*cp == 0) ? cp : cp + 1; - break; - - default: - err = EINVAL; - goto fail; - } + if ((p = strchr(p, '/')) == NULL) + len = sizeof(idev->d_path) - 1; + else + len = p - devspec; + if (path != NULL) + *path = p; + strncpy(idev->d_path, devspec, len); + idev->d_path[len] = '\0'; idev->d_dev = dv; idev->d_type = dv->dv_type; if (dev == NULL) { @@ -179,81 +116,18 @@ *dev = idev; } return(0); - - fail: - free(idev); - return(err); -} - -/* - * Hack to correctly parse bootpath for currdev. Also, enter the device into - * the device array in the case of lazy probing (i.e. on sparc64). This has the - * effect that the disk the loader was loaded from will always be the first - * in the list, but it saves lots of time. - */ -int -ofw_parseofwdev(struct ofw_devdesc *dev, const char *devspec) -{ - char *cp, *ep; - int i; - struct devsw *dv; - -#ifdef __sparc64__ - ofwd_enter_dev(devspec); -#endif - if ((dev->d_kind.ofwdisk.unit = ofwd_getunit(devspec)) == -1) - return EUNIT; - if ((cp = strrchr(devspec, ',')) == 0) - return EINVAL; - cp++; - if (*cp != ',') - return ESLICE; - ep = ++cp; - dev->d_kind.ofwdisk.slice = strtol(cp, &cp, 10) + 1; - if (cp == ep) - return ESLICE; - if (*cp != ':') - return EPART; - dev->d_kind.ofwdisk.partition = *++cp - 'a'; -} - -char * -ofw_fmtdev(void *vdev) -{ - struct ofw_devdesc *dev = (struct ofw_devdesc *)vdev; - static char buf[128]; - char *cp; - - switch(dev->d_type) { - case DEVT_NONE: - strcpy(buf, "(no device)"); - break; - - case DEVT_DISK: - sprintf(buf, "%s%ds%d%c:", dev->d_dev->dv_name, - dev->d_kind.ofwdisk.unit, dev->d_kind.ofwdisk.slice, - dev->d_kind.ofwdisk.partition + 'a'); - break; - - case DEVT_NET: - sprintf(buf, "%s%d:", dev->d_dev->dv_name, - dev->d_kind.netif.unit); - break; - } - - return buf; } int ofw_setcurrdev(struct env_var *ev, int flags, void *value) { - struct ofw_devdesc *ncurr; - int rv; + struct ofw_devdesc *ncurr; + int rv; - if ((rv = ofw_parsedev(&ncurr, value, NULL)) != 0) - return rv; + if ((rv = ofw_parsedev(&ncurr, value, NULL)) != 0) + return rv; - free(ncurr); - env_setenv(ev->ev_name, flags | EV_NOHOOK, value, NULL, NULL); - return 0; + free(ncurr); + env_setenv(ev->ev_name, flags | EV_NOHOOK, value, NULL, NULL); + return 0; } Index: ofw/libofw/libofw.h =================================================================== RCS file: /home/ncvs/src/sys/boot/ofw/libofw/libofw.h,v retrieving revision 1.6 diff -u -r1.6 libofw.h --- ofw/libofw/libofw.h 11 May 2002 21:30:46 -0000 1.6 +++ ofw/libofw/libofw.h 3 Nov 2002 18:37:04 -0000 @@ -31,56 +31,27 @@ struct ofw_devdesc { struct devsw *d_dev; int d_type; - union { - struct { - phandle_t handle; /* OFW handle */ - unsigned long partoff; /* sector offset */ - int unit; /* disk number */ - char path[64]; /* OFW path */ - int slice; /* slice# */ - int partition; /* partition in slice */ - int bsize; /* block size */ - } ofwdisk; - struct { - int unit; - char path[64]; - void *dmabuf; - } netif; - } d_kind; -/* - * Keeping this around so I know what came from the NetBSD stuff. - * I've made a wild guess as to what goes where, but I have no idea if it's - * right. - * - * void *dmabuf; - */ + phandle_t d_handle; + char d_path[256]; }; -#define MAXDEV 31 /* Maximum number of devices. */ - -/* Known types. Use the same as alpha for consistancy. */ -#define DEVT_NONE 0 -#define DEVT_DISK 1 -#define DEVT_NET 2 +struct dev_alias { + const char *da_name; + struct devsw *da_dsw; +}; extern int ofw_getdev(void **vdev, const char *devspec, const char **path); -extern char *ofw_fmtdev(void *vdev); -extern int ofw_parseofwdev(struct ofw_devdesc *, const char *devspec); extern int ofw_setcurrdev(struct env_var *ev, int flags, void *value); extern struct devsw ofwdisk; +extern struct dev_alias dev_aliases[]; extern struct netif_driver ofwnet; -void ofwd_enter_dev(const char *); int ofwn_getunit(const char *); ssize_t ofw_copyin(const void *src, vm_offset_t dest, const size_t len); ssize_t ofw_copyout(const vm_offset_t src, void *dest, const size_t len); ssize_t ofw_readin(const int fd, vm_offset_t dest, const size_t len); - -void ofw_devsearch_init(void); -int ofw_devsearch(const char *, char *); -int ofw_devicetype(char *); extern int ofw_boot(void); extern int ofw_autoload(void); Index: ofw/libofw/ofw_devsearch.c =================================================================== RCS file: ofw/libofw/ofw_devsearch.c diff -N ofw/libofw/ofw_devsearch.c --- ofw/libofw/ofw_devsearch.c 15 Oct 2001 09:52:38 -0000 1.3 +++ /dev/null 1 Jan 1970 00:00:00 -0000 @@ -1,135 +0,0 @@ -/* - * Copyright (C) 2000 Benno Rice - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY Benno Rice ``AS IS'' AND ANY EXPRESS OR - * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. - * IN NO EVENT SHALL TOOLS GMBH BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, - * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; - * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, - * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR - * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF - * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - * $FreeBSD: src/sys/boot/ofw/libofw/ofw_devsearch.c,v 1.3 2001/10/15 09:52:38 robert Exp $ - */ - -#include - -#include "libofw.h" - -static phandle_t curnode; - -/* - * Initialise a device tree search. We do this by setting curpackage to point - * to the root node. - */ -void -ofw_devsearch_init(void) -{ - curnode = OF_peer(0); -} - -static phandle_t -nextnode(phandle_t current) -{ - phandle_t node; - - node = OF_child(current); - - if (node == -1) - return(-1); - - if (node == 0) { - node = OF_peer(current); - - if (node == -1) - return(-1); - - if (node == 0) { - phandle_t newnode; - - newnode = current; - node = 0; - - while (node == 0) { - node = OF_parent(newnode); - - if (node == -1 || node == 0) - return ((int)node); - - newnode = node; - node = OF_peer(newnode); - } - } - } - - return(node); -} - -/* - * Search for devices in the device tree with a certain device_type. - * Return their paths. - */ -int -ofw_devsearch(const char *type, char *path) -{ - phandle_t new; - char str[32]; - int i; - - for (;;) { - new = nextnode(curnode); - if (new == 0 || new == -1) { - return((int)new); - } - - curnode = new; - - if ((i = OF_getprop(curnode, "device_type", str, 31)) != -1) { - - if (strncmp(str, type, 32) == 0) { - if ((i = OF_package_to_path(curnode, path, 254)) == -1) - return(-1); - - path[i] = '\0'; - return(1); - } - } - } -} - -/* - * Get the device_type of a node. - * Return DEVT_DISK, DEVT_NET or DEVT_NONE. - */ -int -ofw_devicetype(char *path) -{ - phandle_t node; - char type[16]; - - node = OF_finddevice(path); - if (node == -1) - return DEVT_NONE; - - OF_getprop(node, "device_type", type, 16); - - if (strncmp(type, "block", 16) == 0) - return DEVT_DISK; - else if (strncmp(type, "network", 16) == 0) - return DEVT_NET; - else - return DEVT_NONE; -} Index: ofw/libofw/ofw_disk.c =================================================================== RCS file: /home/ncvs/src/sys/boot/ofw/libofw/ofw_disk.c,v retrieving revision 1.7 diff -u -r1.7 ofw_disk.c --- ofw/libofw/ofw_disk.c 18 Jul 2002 12:39:02 -0000 1.7 +++ ofw/libofw/ofw_disk.c 3 Nov 2002 18:31:23 -0000 @@ -41,16 +41,12 @@ #include "bootstrap.h" #include "libofw.h" -#define DISKSECSZ 512 - static int ofwd_init(void); static int ofwd_strategy(void *devdata, int flag, daddr_t dblk, size_t size, char *buf, size_t *rsize); static int ofwd_open(struct open_file *f, ...); static int ofwd_close(struct open_file *f); static void ofwd_print(int verbose); -static char * ofwd_getdevpath(int unit); -int readdisklabel(struct ofw_devdesc *); struct devsw ofwdisk = { "disk", @@ -63,125 +59,9 @@ ofwd_print }; -static struct ofwdinfo { - int ofwd_unit; - char ofwd_path[255]; -} ofwdinfo[MAXDEV]; -static int nofwdinfo = 0; -static int probed; - -#define OFDP_FOUND 0 -#define OFDP_NOTFOUND 1 -#define OFDP_TERMINATE 2 - -#define MAXDEV_IDE 4 -#define MAXDEV_DEFAULT 16 /* SCSI etc. */ - -void -ofwd_enter_dev(const char *devpath) -{ - char *p; - int n; - - if (ofwd_getunit(devpath) != -1) - return; - if ((p = strrchr(devpath, ',')) != NULL) - n = p - devpath; - else - n = strlen(devpath); - ofwdinfo[nofwdinfo].ofwd_unit = nofwdinfo; - strncpy(ofwdinfo[nofwdinfo].ofwd_path, devpath, n); - ofwdinfo[nofwdinfo].ofwd_path[n] = '\0'; - printf("disk%d is %s\n", nofwdinfo, ofwdinfo[nofwdinfo].ofwd_path); - nofwdinfo++; -} - -static int -ofwd_probe_dev(char *devpath) -{ - ihandle_t instance; - int rv; - - /* Is the device already in the list? */ - if (ofwd_getunit(devpath) != -1) - return OFDP_FOUND; - instance = OF_open(devpath); - if (instance != -1) { - ofwd_enter_dev(devpath); - OF_close(instance); - } else - return OFDP_NOTFOUND; - if (nofwdinfo > MAXDEV) { - printf("Hit MAXDEV probing disks.\n"); - return OFDP_TERMINATE; - } - return OFDP_FOUND; -} - -static int -ofwd_probe_devs(void) -{ - int ret; - char devpath[255]; -#ifdef __sparc64__ - int i, n; - char cdevpath[255]; -#endif - - probed = 1; - ofw_devsearch_init(); - while ((ret = ofw_devsearch("block", devpath)) != 0) { - devpath[sizeof devpath - 1] = 0; - if (ret == -1) - return 1; -#ifdef DEBUG - printf("devpath=\"%s\" ret=%d\n", devpath, ret); -#endif - - if (strstr(devpath, "cdrom") != 0) - continue; - -#ifdef __sparc64__ - /* - * sparc64 machines usually only have a single disk node as - * child of the controller (in the ATA case, there may exist - * an additional cdrom node, which we ignore above, since - * booting from it is special, and it can also be used as a - * disk node). - * Devices are accessed by using disk@unit; when no unit - * number is given, 0 is assumed. - * There is no way we can enumerate the existing disks except - * trying to open them, which unfortunately creates some deleays - * and spurioius warnings printed by the prom, which we can't - * do much about. The search may not stop on the first - * unsuccessful attempt, because that would cause disks that - * follow one with an invalid label (like CD-ROMS) would not - * be detected this way. - * Try to at least be a bit smart and only probe 4 devices in - * the IDE case. - */ - if (strstr(devpath, "/ide@") != NULL) - n = MAXDEV_IDE; - else - n = MAXDEV_DEFAULT; - for (i = 0; i < n; i++) { - sprintf(cdevpath, "%s@%d", devpath, i); - if (ofwd_probe_dev(cdevpath) == OFDP_TERMINATE) - return 1; - } -#else - if (ofwd_probe_dev(devpath) == OFDP_TERMINATE) - return 1; -#endif - } - - return 0; -} - static int ofwd_init(void) { - /* Short-circuit the device probing, since it takes too long. */ return 0; } @@ -194,18 +74,14 @@ int n; int i, j; - pos = (dp->d_kind.ofwdisk.partoff + dblk) * dp->d_kind.ofwdisk.bsize; - + pos = dblk * 512; do { - if (OF_seek(dp->d_kind.ofwdisk.handle, pos) < 0) { + if (OF_seek(dp->d_handle, pos) < 0) return EIO; - } - n = OF_read(dp->d_kind.ofwdisk.handle, buf, size); - if (n < 0 && n != -2) { + n = OF_read(dp->d_handle, buf, size); + if (n < 0 && n != -2) return EIO; - } } while (n == -2); - *rsize = size; return 0; } @@ -213,55 +89,18 @@ static int ofwd_open(struct open_file *f, ...) { - va_list vl; struct ofw_devdesc *dp; - char *devpath; - phandle_t diskh; - char buf[256]; - int i, j; + phandle_t handle; + va_list vl; va_start(vl, f); dp = va_arg(vl, struct ofw_devdesc *); va_end(vl); - - /* - * The unit number is really an index into our device array. - * If it is not in the list, we may need to probe now. - */ - if (!probed && dp->d_kind.ofwdisk.unit >= nofwdinfo) - ofwd_probe_devs(); - if (dp->d_kind.ofwdisk.unit >= nofwdinfo) - return 1; - devpath = ofwdinfo[dp->d_kind.ofwdisk.unit].ofwd_path; - sprintf(buf, "%s,%d:%c", devpath, dp->d_kind.ofwdisk.slice, - 'a' + dp->d_kind.ofwdisk.partition); - if ((diskh = OF_open(buf)) == -1) { - printf("ofwd_open: Could not open %s\n", buf); + if ((handle = OF_open(dp->d_path)) == -1) { + printf("ofwd_open: Could not open %s\n", dp->d_path); return 1; } - dp->d_kind.ofwdisk.bsize = DISKSECSZ; - dp->d_kind.ofwdisk.handle = diskh; - readdisklabel(dp); - - return 0; -} - -int -readdisklabel(struct ofw_devdesc *dp) -{ - char buf[DISKSECSZ]; - struct disklabel *lp; - size_t size; - int i; - - dp->d_kind.ofwdisk.partoff = 0; - dp->d_dev->dv_strategy(dp, 0, LABELSECTOR, sizeof(buf), buf, &size); - i = dp->d_kind.ofwdisk.partition; - if (i >= MAXPARTITIONS) - return 1; - - lp = (struct disklabel *)(buf + LABELOFFSET); - dp->d_kind.ofwdisk.partoff = lp->d_partitions[i].p_offset; + dp->d_handle = handle; return 0; } @@ -269,41 +108,12 @@ ofwd_close(struct open_file *f) { struct ofw_devdesc *dev = f->f_devdata; - OF_close(dev->d_kind.ofwdisk.handle); + OF_close(dev->d_handle); return 0; } static void ofwd_print(int verbose) { - int i; - char line[80]; - - if (!probed) - ofwd_probe_devs(); - for (i = 0; i < nofwdinfo; i++) { - sprintf(line, " disk%d: %s", i, ofwdinfo[i].ofwd_path); - pager_output(line); - pager_output("\n"); - } - return; -} - -int -ofwd_getunit(const char *path) -{ - char *p; - int i, n; - - if ((p = strrchr(path, ',')) != NULL) - n = p - path; - else - n = strlen(path); - for (i = 0; i < nofwdinfo; i++) { - if (strncmp(path, ofwdinfo[i].ofwd_path, n) == 0) - return i; - } - - return -1; } Index: ofw/libofw/ofw_net.c =================================================================== RCS file: /home/ncvs/src/sys/boot/ofw/libofw/ofw_net.c,v retrieving revision 1.6 diff -u -r1.6 ofw_net.c --- ofw/libofw/ofw_net.c 7 Jun 2002 11:49:33 -0000 1.6 +++ ofw/libofw/ofw_net.c 3 Nov 2002 18:38:29 -0000 @@ -72,7 +72,6 @@ static phandle_t netdevice; static ihandle_t netinstance; -static ihandle_t memory; static void *dmabuf; @@ -186,7 +185,6 @@ int pathlen; chosen = OF_finddevice("/chosen"); - OF_getprop(chosen, "memory", &memory, sizeof(memory)); pathlen = OF_getprop(chosen, "bootpath", path, 64); if ((ch = index(path, ':')) != NULL) *ch = '\0'; @@ -236,25 +234,3 @@ OF_call_method("dma-free", netinstance, 2, 0, dmabuf, MAXPHYS); OF_close(netinstance); } - -#if 0 -int -ofwn_getunit(const char *path) -{ - int i; - char newpath[255]; - - OF_canon(path, newpath, 254); - - for (i = 0; i < nofwninfo; i++) { - printf(">>> test =\t%s\n", ofwninfo[i].ofwn_path); - if (strcmp(path, ofwninfo[i].ofwn_path) == 0) - return i; - - if (strcmp(newpath, ofwninfo[i].ofwn_path) == 0) - return i; - } - - return -1; -} -#endif Index: powerpc/loader/metadata.c =================================================================== RCS file: /home/ncvs/src/sys/boot/powerpc/loader/metadata.c,v retrieving revision 1.1 diff -u -r1.1 metadata.c --- powerpc/loader/metadata.c 10 Jul 2002 12:13:16 -0000 1.1 +++ powerpc/loader/metadata.c 3 Nov 2002 06:55:39 -0000 @@ -255,7 +255,6 @@ struct preloaded_file *kfp; struct preloaded_file *xp; struct file_metadata *md; - struct ofw_devdesc *rootdev; vm_offset_t kernend; vm_offset_t addr; vm_offset_t envp; @@ -273,16 +272,10 @@ * MI code before launching the kernel. */ rootdevname = getenv("rootdev"); - ofw_getdev((void **)(&rootdev), rootdevname, NULL); - if (rootdev == NULL) { /* bad $rootdev/$currdev */ - printf("can't determine root device\n"); - return(EINVAL); - } - + if (rootdevname == NULL) + rootdevname = getenv("currdev"); /* Try reading the /etc/fstab file to select the root device */ - getrootmount(ofw_fmtdev((void *)rootdev)); - - free(rootdev); + getrootmount(rootdevname); /* find the last module in the chain */ addr = 0; Index: sparc64/loader/Makefile =================================================================== RCS file: /home/ncvs/src/sys/boot/sparc64/loader/Makefile,v retrieving revision 1.13 diff -u -r1.13 Makefile --- sparc64/loader/Makefile 13 Oct 2002 18:52:46 -0000 1.13 +++ sparc64/loader/Makefile 3 Nov 2002 04:43:09 -0000 @@ -81,7 +81,7 @@ .endif CFLAGS+= -I${.CURDIR}/../../../../lib/libstand/ -LDADD= ${LIBFICL} ${LIBSTAND} ${LIBOFW} +LDADD= ${LIBFICL} ${LIBOFW} ${LIBSTAND} vers.c: ${.CURDIR}/../../common/newvers.sh ${.CURDIR}/version sh ${.CURDIR}/../../common/newvers.sh ${.CURDIR}/version ${NEWVERSWHAT} Index: sparc64/loader/main.c =================================================================== RCS file: /home/ncvs/src/sys/boot/sparc64/loader/main.c,v retrieving revision 1.16 diff -u -r1.16 main.c --- sparc64/loader/main.c 13 Oct 2002 18:52:46 -0000 1.16 +++ sparc64/loader/main.c 3 Nov 2002 06:13:14 -0000 @@ -75,7 +75,6 @@ phandle_t pmemh; /* OFW memory handle */ struct memory_slice memslices[18]; -struct ofw_devdesc bootdev; /* * Machine dependent structures that the machine independent @@ -90,6 +89,16 @@ #endif 0 }; +struct dev_alias dev_aliases[] = { +#ifdef LOADER_DISK_SUPPORT + { "cdrom", &ofwdisk }, + { "disk", &ofwdisk }, +#endif +#ifdef LOADER_NET_SUPPORT + { "network", &netdev }, +#endif + { NULL, NULL } +}; struct arch_switch archsw; struct file_format sparc64_elf = { @@ -368,9 +377,6 @@ archsw.arch_copyout = ofw_copyout; archsw.arch_readin = sparc64_readin; archsw.arch_autoload = sparc64_autoload; -#ifdef ELF_CRC32 - archsw.arch_crc32 = sparc64_crc32; -#endif init_heap(); setheap((void *)heapva, (void *)(heapva + HEAPSZ)); @@ -398,46 +404,32 @@ chosenh = OF_finddevice("/chosen"); OF_getprop(chosenh, "bootpath", bootpath, sizeof(bootpath)); - bootdev.d_type = ofw_devicetype(bootpath); - switch (bootdev.d_type) { - case DEVT_DISK: - bootdev.d_dev = &ofwdisk; - /* - * Sun compatible bootable CD-ROMs have a disk label placed - * before the cd9660 data, with the actual filesystem being - * in the first partition, while the other partitions contain - * pseudo disk labels with embedded boot blocks for different - * architectures, which may be followed by UFS filesystems. - * The firmware will set the boot path to the partition it - * boots from ('f' in the sun4u case), but we want the kernel - * to be loaded from the cd9660 fs ('a'), so the boot path - * needs to be altered. - */ - if (strstr(bootpath, "cdrom") != NULL && - bootpath[strlen(bootpath) - 2] == ':') { - bootpath[strlen(bootpath) - 1] = 'a'; - printf("Boot path set to %s\n", bootpath); - } - strncpy(bootdev.d_kind.ofwdisk.path, bootpath, 64); - ofw_parseofwdev(&bootdev, bootpath); - break; - case DEVT_NET: - bootdev.d_dev = &netdev; - strncpy(bootdev.d_kind.netif.path, bootpath, 64); - bootdev.d_kind.netif.unit = 0; - break; + /* + * Sun compatible bootable CD-ROMs have a disk label placed + * before the cd9660 data, with the actual filesystem being + * in the first partition, while the other partitions contain + * pseudo disk labels with embedded boot blocks for different + * architectures, which may be followed by UFS filesystems. + * The firmware will set the boot path to the partition it + * boots from ('f' in the sun4u case), but we want the kernel + * to be loaded from the cd9660 fs ('a'), so the boot path + * needs to be altered. + */ + if (bootpath[strlen(bootpath) - 2] == ':' && + bootpath[strlen(bootpath) - 1] == 'f') { + bootpath[strlen(bootpath) - 1] = 'a'; + printf("Boot path set to %s\n", bootpath); } - env_setenv("currdev", EV_VOLATILE, ofw_fmtdev(&bootdev), + env_setenv("currdev", EV_VOLATILE, bootpath, ofw_setcurrdev, env_nounset); - env_setenv("loaddev", EV_VOLATILE, ofw_fmtdev(&bootdev), + env_setenv("loaddev", EV_VOLATILE, bootpath, env_noset, env_nounset); printf("\n"); printf("%s, Revision %s\n", bootprog_name, bootprog_rev); printf("(%s, %s)\n", bootprog_maker, bootprog_date); printf("bootpath=\"%s\"\n", bootpath); - printf("loaddev=%s\n", getenv("loaddev")); /* Give control to the machine independent loader code. */ interact(); Index: sparc64/loader/metadata.c =================================================================== RCS file: /home/ncvs/src/sys/boot/sparc64/loader/metadata.c,v retrieving revision 1.7 diff -u -r1.7 metadata.c --- sparc64/loader/metadata.c 18 Oct 2002 23:49:18 -0000 1.7 +++ sparc64/loader/metadata.c 3 Nov 2002 02:15:59 -0000 @@ -261,7 +261,6 @@ struct preloaded_file *kfp; struct preloaded_file *xp; struct file_metadata *md; - struct ofw_devdesc *rootdev; vm_offset_t kernend; vm_offset_t addr; vm_offset_t envp; @@ -276,17 +275,9 @@ * This should perhaps go to MI code and/or have $rootdev tested/set by * MI code before launching the kernel. */ - rootdevname = getenv("rootdev"); - ofw_getdev((void **)(&rootdev), rootdevname, NULL); - if (rootdev == NULL) { /* bad $rootdev/$currdev */ - printf("can't determine root device\n"); - return(EINVAL); - } - - /* Try reading the /etc/fstab file to select the root device */ - getrootmount(ofw_fmtdev((void *)rootdev)); - - free(rootdev); + if ((rootdevname = getenv("rootdev")) == NULL) + rootdevname = getenv("currdev"); + getrootmount(rootdevname); /* find the last module in the chain */ addr = 0; To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-ppc" in the body of the message From owner-freebsd-ppc Fri Nov 8 4:39:15 2002 Delivered-To: freebsd-ppc@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 4FB7737B401 for ; Fri, 8 Nov 2002 04:39:13 -0800 (PST) Received: from ns2.vipowernet.net (ns2.vipowernet.net [65.112.145.194]) by mx1.FreeBSD.org (Postfix) with ESMTP id C924243E6E for ; Fri, 8 Nov 2002 04:39:11 -0800 (PST) (envelope-from nhjudrvg@adb.gu.se) Received: from vipowernet.net (ns1.vipowernet.net [65.112.145.66]) by ns2.vipowernet.net (8.11.2/8.11.2) with ESMTP id gA8CTIS10541; Fri, 8 Nov 2002 08:29:18 -0400 Received: from faculty.sccds.stxcountryday.com ([65.113.90.91]) by vipowernet.net ; Fri, 08 Nov 2002 16:38:37 +0400 Received: from mxvc1.demo.pl (mail.rockchurch.org [66.160.109.9]) by faculty.sccds.stxcountryday.com with SMTP (Microsoft Exchange Internet Mail Service Version 5.5.2653.13) id W3BK1BRH; Fri, 8 Nov 2002 06:46:30 -0500 Message-ID: <00000e714e6d$00001908$00001015@smtp.prv.pl> To: Cc: , , , , , , , , , , , , From: "Glickman" Subject: Time out1347 Date: Fri, 08 Nov 2002 02:30:07 -2000 MIME-Version: 1.0 Content-Type: text/plain; charset="Windows-1252" Content-Transfer-Encoding: 7bit Sender: owner-freebsd-ppc@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG If your interested in putting your product or service in front of millions of prospective clients or buyers READ ON! What is the most cost effective form of advertising for the very small all the way up to the largest of companies? Commercial Email! Why? Because there is no charge for paper, printing, mailing or the unbelievabley HIGH COST of putting Ads into Magazines or Papers. Why should most of your advertising dollar go for overhead? There IS a BETTER way! How? By placing your ad directly into the e-mail boxes of consumers who, like you, have an Internet e-mail address. Almost every user of the Internet has a unique e-mail address and we can effectively reach as many of those people as you want FAST and EFFECTIVELY. Every year the number of users increases tremendously creating a huge market. Why not become part of this unlimited market by placing your personal ad in one of the largest consumer databases? We are interested in doing business with you, however, we DO NOT do pornography or schemes of any kind. Please call us with your legitimate product or service. Some of you may not be interested at all, and possibly are agitated by our message. We will respectfully remove you from our list by request. We are responsible commercial e-mailers and don't want to bother those who are not interested. We not only respect you, but also our customers. We do not want our customers spending their advertising dollars on prospects that do not have any interest. (Decline instructions are at the end of this letter.) Below you will find basic mailing options we are offering at this time. Check out our SPECIALS! Commercial Email Gets Results! Untargeted mailings: 1,000,000 E-mails for U.S $500.00 2,000,000 E-mails for U.S $900.00 3,000,000 E-mails for U.S $1200.00 4,000,000 E-mails for U.S $1400.00 For Professional Advertising Campaigns at Affordable Prices Call 818-743-7507 By utilizing our resources and technology we have achieved our goal of making advertising affordable and effective on the Internet. We hope that you will choose our company to help you in attaining your companies goals. This message is an advertisement. We will continue to bring you valuable permission based messages on the products and services that interest you most unless you wish to decline. If you no longer wish to receive our messages send a e-mail to: mailto:mxrly@yahoo.com?subject=expunge To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-ppc" in the body of the message From owner-freebsd-ppc Fri Nov 8 9:55:47 2002 Delivered-To: freebsd-ppc@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6AA5D37B401 for ; Fri, 8 Nov 2002 09:55:46 -0800 (PST) Received: from mta07-svc.ntlworld.com (mta07-svc.ntlworld.com [62.253.162.47]) by mx1.FreeBSD.org (Postfix) with ESMTP id 858DB43E42 for ; Fri, 8 Nov 2002 09:55:35 -0800 (PST) (envelope-from paul@centurymedia.co.uk) Received: from laptop.centurymedia.co.uk ([81.97.229.35]) by mta07-svc.ntlworld.com (InterMail vM.4.01.03.27 201-229-121-127-20010626) with ESMTP id <20021108175531.THAH21275.mta07-svc.ntlworld.com@laptop.centurymedia.co.uk> for ; Fri, 8 Nov 2002 17:55:31 +0000 Message-Id: <5.1.0.14.2.20021108175347.03408958@mail.centurymedia.co.uk> X-Sender: paul@mail.centurymedia.co.uk X-Mailer: QUALCOMM Windows Eudora Version 5.1 Date: Fri, 08 Nov 2002 17:57:45 +0000 To: freebsd-ppc@FreeBSD.ORG From: Paul Caselton Subject: POP Boards... Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; format=flowed Sender: owner-freebsd-ppc@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Hi All, Being new to the list and having just joined I don't know if this is general knowledge or not. But is FreeBSD for PPC being developed for just PPC based Macs, or does that include POP boards and other PPC hardware too? I'm specifically interested in a port on the new AmigaOne and Pegasos boards and if it has or will ever be considered. I love using FreeBSD on x86 and a PPC version would be a dream for me (and others). The AmigaOne board uses PPCBoot as it's firmware and has a CPU module allowing for upgrades etc. Initially coming with three different combos (I'm having the 800Mhz G4). regards, Paul To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-ppc" in the body of the message From owner-freebsd-ppc Fri Nov 8 10:58:27 2002 Delivered-To: freebsd-ppc@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 8B1EA37B401 for ; Fri, 8 Nov 2002 10:58:26 -0800 (PST) Received: from mailout6-0.nyroc.rr.com (mailout6-1.nyroc.rr.com [24.92.226.177]) by mx1.FreeBSD.org (Postfix) with ESMTP id 86D0643E4A for ; Fri, 8 Nov 2002 10:58:25 -0800 (PST) (envelope-from justin@shiningsilence.com) Received: from shiningsilence.com (roc-24-169-96-227.rochester.rr.com [24.169.96.227]) by mailout6-0.nyroc.rr.com (8.11.6/RoadRunner 1.20) with SMTP id gA8IwNk09927 for ; Fri, 8 Nov 2002 13:58:24 -0500 (EST) Received: from 192.168.0.2 (SquirrelMail authenticated user justin) by home.shiningsilence.com with HTTP; Fri, 8 Nov 2002 13:59:52 -0500 (EST) Message-ID: <1038.192.168.0.2.1036781992.squirrel@home.shiningsilence.com> Date: Fri, 8 Nov 2002 13:59:52 -0500 (EST) Subject: Re: POP Boards... From: "Justin C. Sherrill" To: In-Reply-To: <5.1.0.14.2.20021108175347.03408958@mail.centurymedia.co.uk> References: <5.1.0.14.2.20021108175347.03408958@mail.centurymedia.co.uk> X-Priority: 3 Importance: Normal X-MSMail-Priority: Normal X-Mailer: SquirrelMail (version 1.2.7) MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit Sender: owner-freebsd-ppc@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG > Being new to the list and having just joined I don't know if this is > general knowledge or not. But is FreeBSD for PPC being developed for > just PPC based Macs, or does that include POP boards and other PPC > hardware too? Recent PowerMacs are the initial target, because they are plentiful, but other platforms are expected - not surprisingly, as there's already plenty on Unixish stuff on PowerMacs. More info: http://www.freebsd.org/platforms/ppc.html> To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-ppc" in the body of the message From owner-freebsd-ppc Fri Nov 8 14: 6:23 2002 Delivered-To: freebsd-ppc@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id BBC3137B401 for ; Fri, 8 Nov 2002 14:06:22 -0800 (PST) Received: from gioria.dyndns.org (AFontenayssB-104-1-2-40.abo.wanadoo.fr [217.128.170.40]) by mx1.FreeBSD.org (Postfix) with ESMTP id E396A43E42 for ; Fri, 8 Nov 2002 14:06:21 -0800 (PST) (envelope-from eagle@gioria.dyndns.org) Received: from bushmills.intra.thorm.net (bushmills.intra.thorm.net [192.168.0.3]) by gioria.dyndns.org (Postfix) with ESMTP id 2B9E737485 for ; Fri, 8 Nov 2002 23:12:34 +0100 (CET) Received: by bushmills.intra.thorm.net (Postfix, from userid 501) id D8D27AA67; Fri, 8 Nov 2002 23:06:27 +0100 (CET) Date: Fri, 8 Nov 2002 23:06:27 +0100 From: Sebastien Gioria To: freebsd-ppc@FreeBSD.ORG Subject: Cross compilation of FreeBSD/PowerPC on a X86 ? Message-ID: <20021108220627.GA9240@bushmills.intra.thorm.net> Reply-To: Sebastien Gioria Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline X-Hostname: bushmills.intra.thorm.net X-Uptime: 23:05 up 13:57, 6 users, load averages: 2,47 2,35 2,30 X-FreeBSD-Release: FreeBSD-5.0-CURRENT User-Agent: Mutt/1.5.1i Sender: owner-freebsd-ppc@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Hi guys, Does it be possible ? Any hints to take care ? Thanks -- Sebastien Gioria gioria@{FreeBSD,FreeBSD-FR}.ORG French FreeBSD User Group http://www.FreeBSD-FR.ORG FreeBSD committer http://www.FreeBSD.ORG *-> FreeBSD + RollerBlade + Scuba Diving; What need you more ? <-* To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-ppc" in the body of the message From owner-freebsd-ppc Fri Nov 8 14:16:22 2002 Delivered-To: freebsd-ppc@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 8E33537B401 for ; Fri, 8 Nov 2002 14:16:21 -0800 (PST) Received: from gt3.OntheNet.com.au (nt.com.au [203.13.70.61]) by mx1.FreeBSD.org (Postfix) with ESMTP id 2D87143E42 for ; Fri, 8 Nov 2002 14:16:20 -0800 (PST) (envelope-from grehan@freebsd.org) Received: from freebsd.org (CPE-203-45-245-212.qld.bigpond.net.au [203.45.245.212]) by gt3.OntheNet.com.au (8.11.4/8.11.4) with ESMTP id gA8MGWU32353; Sat, 9 Nov 2002 08:16:33 +1000 (EST) Message-ID: <3DCC3812.7C0F8A79@freebsd.org> Date: Sat, 09 Nov 2002 08:17:54 +1000 From: Peter Grehan X-Mailer: Mozilla 4.79 [en] (X11; U; Linux 2.2.14-12 i686) X-Accept-Language: en MIME-Version: 1.0 To: Paul Caselton Cc: freebsd-ppc@freebsd.org Subject: Re: POP Boards... References: <5.1.0.14.2.20021108175347.03408958@mail.centurymedia.co.uk> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-ppc@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Hi Paul, > Being new to the list and having just joined I don't know if this is > general knowledge or not. But is FreeBSD for PPC being developed for just > PPC based Macs, or does that include POP boards and other PPC hardware too? As Justin mentioned, it's Macs at the moment, but I have an embedded PPC board (with PPCBoot) that will be supported at some point in the future. It may not be too difficult to support the Amiga board - from the link I saw (http://www.eyetech.co.uk/amigaone/oct252002a.php) the h/w looks pretty standard, and if there's no documentation available for the Articia system controller (http://www.mai.com/products/chipset.htm), the register spec could be extracted from Linux source. later, Peter. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-ppc" in the body of the message From owner-freebsd-ppc Fri Nov 8 22:41: 4 2002 Delivered-To: freebsd-ppc@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 1370637B401; Fri, 8 Nov 2002 22:41:04 -0800 (PST) Received: from gt3.OntheNet.com.au (nt.com.au [203.13.70.61]) by mx1.FreeBSD.org (Postfix) with ESMTP id 77B2A43E4A; Fri, 8 Nov 2002 22:41:02 -0800 (PST) (envelope-from grehan@freebsd.org) Received: from freebsd.org (CPE-203-45-245-212.qld.bigpond.net.au [203.45.245.212]) by gt3.OntheNet.com.au (8.11.4/8.11.4) with ESMTP id gA96fOU47643; Sat, 9 Nov 2002 16:41:24 +1000 (EST) Message-ID: <3DCCAE66.EFEDEAC@freebsd.org> Date: Sat, 09 Nov 2002 16:42:46 +1000 From: Peter Grehan X-Mailer: Mozilla 4.79 [en] (X11; U; Linux 2.2.14-12 i686) X-Accept-Language: en MIME-Version: 1.0 To: Sebastien Gioria Cc: freebsd-ppc@freebsd.org Subject: Re: Cross compilation of FreeBSD/PowerPC on a X86 ? References: <20021108220627.GA9240@bushmills.intra.thorm.net> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-ppc@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Hi Sebastien, > Does it be possible ? Any hints to take care ? Not as of yet - there's a lot of user-space code that hasn't made it's way into CVS - but that's how I do all my development. It should be possible to do native development with the next snapshot. later, Peter. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-ppc" in the body of the message