diff options
Diffstat (limited to 'sys/boot/ofw/libofw/libofw.h')
-rw-r--r-- | sys/boot/ofw/libofw/libofw.h | 43 |
1 files changed, 4 insertions, 39 deletions
diff --git a/sys/boot/ofw/libofw/libofw.h b/sys/boot/ofw/libofw/libofw.h index c65c84a..a7d73e6 100644 --- a/sys/boot/ofw/libofw/libofw.h +++ b/sys/boot/ofw/libofw/libofw.h @@ -31,57 +31,22 @@ 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 - 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 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); @@ -99,10 +64,10 @@ extern struct file_format ofw_elf; extern void reboot(void); -extern int main(int (*openfirm)(void *)); - struct ofw_reg { cell_t base; cell_t size; }; + +extern int (*openfirmware)(void *); |