Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/rump/dev/wip Add ucom@usb support. This uses the uplcom...



details:   https://anonhg.NetBSD.org/src/rev/324bc99635bd
branches:  trunk
changeset: 750212:324bc99635bd
user:      pooka <pooka%NetBSD.org@localhost>
date:      Sun Dec 20 15:43:13 2009 +0000

description:
Add ucom@usb support.  This uses the uplcom hardware driver currently
(because that's the hardware I happen to have), but others can just
be plugged in if a need arises.

diffstat:

 sys/rump/dev/wip/Makefile              |    4 +-
 sys/rump/dev/wip/libucom/Makefile      |   16 +
 sys/rump/dev/wip/libucom/locators.h    |    7 +
 sys/rump/dev/wip/libucom/shlib_version |    4 +
 sys/rump/dev/wip/libucom/ucom.h        |    3 +
 sys/rump/dev/wip/libucom/ucom_at_usb.c |  445 +++++++++++++++++++++++++++++++++
 6 files changed, 477 insertions(+), 2 deletions(-)

diffs (truncated from 507 to 300 lines):

diff -r 88a6c1d626e2 -r 324bc99635bd sys/rump/dev/wip/Makefile
--- a/sys/rump/dev/wip/Makefile Sun Dec 20 15:32:46 2009 +0000
+++ b/sys/rump/dev/wip/Makefile Sun Dec 20 15:43:13 2009 +0000
@@ -1,6 +1,6 @@
-#      $NetBSD: Makefile,v 1.1 2009/11/11 13:54:54 pooka Exp $
+#      $NetBSD: Makefile,v 1.2 2009/12/20 15:43:13 pooka Exp $
 #
 
-SUBDIR=        libnet80211 librumpusbhc libumass libusb libusbrum
+SUBDIR=        libnet80211 librumpusbhc libucom libumass libusb libusbrum
 
 .include <bsd.subdir.mk>
diff -r 88a6c1d626e2 -r 324bc99635bd sys/rump/dev/wip/libucom/Makefile
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/sys/rump/dev/wip/libucom/Makefile Sun Dec 20 15:43:13 2009 +0000
@@ -0,0 +1,16 @@
+#      $NetBSD: Makefile,v 1.1 2009/12/20 15:43:13 pooka Exp $
+#
+
+.PATH: ${.CURDIR}/../../../../dev/usb
+
+LIB=   rumpdev_ucom
+
+SRCS=  ucom.c uplcom.c
+
+SRCS+= ucom_at_usb.c
+
+CFLAGS+=       -Wno-pointer-sign
+CPPFLAGS+=     -I${RUMPTOP}/librump/rumpvfs
+
+.include <bsd.lib.mk>
+.include <bsd.klinks.mk>
diff -r 88a6c1d626e2 -r 324bc99635bd sys/rump/dev/wip/libucom/locators.h
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/sys/rump/dev/wip/libucom/locators.h       Sun Dec 20 15:43:13 2009 +0000
@@ -0,0 +1,7 @@
+/*     $NetBSD: locators.h,v 1.1 2009/12/20 15:43:13 pooka Exp $       */
+
+/* locators borrowed from config.  redo properly some day */
+
+#define UCOMBUSCF_PORTNO 0
+#define UCOMBUSCF_PORTNO_DEFAULT -1
+#define UCOMBUSCF_NLOCS 1
diff -r 88a6c1d626e2 -r 324bc99635bd sys/rump/dev/wip/libucom/shlib_version
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/sys/rump/dev/wip/libucom/shlib_version    Sun Dec 20 15:43:13 2009 +0000
@@ -0,0 +1,4 @@
+#      $NetBSD: shlib_version,v 1.1 2009/12/20 15:43:13 pooka Exp $
+#
+major=0
+minor=0
diff -r 88a6c1d626e2 -r 324bc99635bd sys/rump/dev/wip/libucom/ucom.h
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/sys/rump/dev/wip/libucom/ucom.h   Sun Dec 20 15:43:13 2009 +0000
@@ -0,0 +1,3 @@
+/*     $NetBSD: ucom.h,v 1.1 2009/12/20 15:43:13 pooka Exp $   */
+
+#define NUCOM 1
diff -r 88a6c1d626e2 -r 324bc99635bd sys/rump/dev/wip/libucom/ucom_at_usb.c
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/sys/rump/dev/wip/libucom/ucom_at_usb.c    Sun Dec 20 15:43:13 2009 +0000
@@ -0,0 +1,445 @@
+/*     $NetBSD: ucom_at_usb.c,v 1.1 2009/12/20 15:43:13 pooka Exp $    */
+
+#include <sys/param.h>
+#include <sys/types.h>
+#include <sys/conf.h>
+#include <sys/device.h>
+#include <sys/kmem.h>
+
+/*
+ * MACHINE GENERATED: DO NOT EDIT
+ *
+ * ioconf.c, from "TESTI_ucom"
+ */
+
+#include <sys/param.h>
+#include <sys/conf.h>
+#include <sys/device.h>
+#include <sys/mount.h>
+
+static const struct cfiattrdata gpibdevcf_iattrdata = {
+       "gpibdev", 1,
+       {
+               { "address", "-1", -1 },
+       }
+};
+static const struct cfiattrdata acpibuscf_iattrdata = {
+       "acpibus", 0, {
+               { NULL, NULL, 0 },
+       }
+};
+static const struct cfiattrdata caccf_iattrdata = {
+       "cac", 1,
+       {
+               { "unit", "-1", -1 },
+       }
+};
+static const struct cfiattrdata spicf_iattrdata = {
+       "spi", 1,
+       {
+               { "slave", "NULL", 0 },
+       }
+};
+static const struct cfiattrdata radiodevcf_iattrdata = {
+       "radiodev", 0, {
+               { NULL, NULL, 0 },
+       }
+};
+static const struct cfiattrdata mlxcf_iattrdata = {
+       "mlx", 1,
+       {
+               { "unit", "-1", -1 },
+       }
+};
+static const struct cfiattrdata ucombuscf_iattrdata = {
+       "ucombus", 1,
+       {
+               { "portno", "-1", -1 },
+       }
+};
+static const struct cfiattrdata videobuscf_iattrdata = {
+       "videobus", 0, {
+               { NULL, NULL, 0 },
+       }
+};
+static const struct cfiattrdata isabuscf_iattrdata = {
+       "isabus", 0, {
+               { NULL, NULL, 0 },
+       }
+};
+static const struct cfiattrdata i2cbuscf_iattrdata = {
+       "i2cbus", 0, {
+               { NULL, NULL, 0 },
+       }
+};
+static const struct cfiattrdata ata_hlcf_iattrdata = {
+       "ata_hl", 1,
+       {
+               { "drive", "-1", -1 },
+       }
+};
+static const struct cfiattrdata depcacf_iattrdata = {
+       "depca", 0, {
+               { NULL, NULL, 0 },
+       }
+};
+static const struct cfiattrdata ppbuscf_iattrdata = {
+       "ppbus", 0, {
+               { NULL, NULL, 0 },
+       }
+};
+static const struct cfiattrdata eisabuscf_iattrdata = {
+       "eisabus", 0, {
+               { NULL, NULL, 0 },
+       }
+};
+static const struct cfiattrdata atapicf_iattrdata = {
+       "atapi", 0, {
+               { NULL, NULL, 0 },
+       }
+};
+static const struct cfiattrdata usbroothubifcf_iattrdata = {
+       "usbroothubif", 0, {
+               { NULL, NULL, 0 },
+       }
+};
+static const struct cfiattrdata altmemdevcf_iattrdata = {
+       "altmemdev", 0, {
+               { NULL, NULL, 0 },
+       }
+};
+static const struct cfiattrdata tcbuscf_iattrdata = {
+       "tcbus", 0, {
+               { NULL, NULL, 0 },
+       }
+};
+static const struct cfiattrdata onewirebuscf_iattrdata = {
+       "onewirebus", 0, {
+               { NULL, NULL, 0 },
+       }
+};
+static const struct cfiattrdata gpiocf_iattrdata = {
+       "gpio", 2,
+       {
+               { "offset", "-1", -1 },
+               { "mask", "0", 0 },
+       }
+};
+static const struct cfiattrdata cbbuscf_iattrdata = {
+       "cbbus", 0, {
+               { NULL, NULL, 0 },
+       }
+};
+static const struct cfiattrdata gpiobuscf_iattrdata = {
+       "gpiobus", 0, {
+               { NULL, NULL, 0 },
+       }
+};
+static const struct cfiattrdata drmcf_iattrdata = {
+       "drm", 0, {
+               { NULL, NULL, 0 },
+       }
+};
+static const struct cfiattrdata pckbportcf_iattrdata = {
+       "pckbport", 1,
+       {
+               { "slot", "-1", -1 },
+       }
+};
+static const struct cfiattrdata irbuscf_iattrdata = {
+       "irbus", 0, {
+               { NULL, NULL, 0 },
+       }
+};
+static const struct cfiattrdata aaccf_iattrdata = {
+       "aac", 1,
+       {
+               { "unit", "-1", -1 },
+       }
+};
+static const struct cfiattrdata pcibuscf_iattrdata = {
+       "pcibus", 1,
+       {
+               { "bus", "-1", -1 },
+       }
+};
+static const struct cfiattrdata usbififcf_iattrdata = {
+       "usbifif", 6,
+       {
+               { "port", "-1", -1 },
+               { "configuration", "-1", -1 },
+               { "interface", "-1", -1 },
+               { "vendor", "-1", -1 },
+               { "product", "-1", -1 },
+               { "release", "-1", -1 },
+       }
+};
+static const struct cfiattrdata upccf_iattrdata = {
+       "upc", 1,
+       {
+               { "offset", "-1", -1 },
+       }
+};
+static const struct cfiattrdata iiccf_iattrdata = {
+       "iic", 2,
+       {
+               { "addr", "-1", -1 },
+               { "size", "-1", -1 },
+       }
+};
+static const struct cfiattrdata onewirecf_iattrdata = {
+       "onewire", 0, {
+               { NULL, NULL, 0 },
+       }
+};
+static const struct cfiattrdata mcabuscf_iattrdata = {
+       "mcabus", 0, {
+               { NULL, NULL, 0 },
+       }
+};
+static const struct cfiattrdata wsdisplaydevcf_iattrdata = {
+       "wsdisplaydev", 1,
+       {
+               { "kbdmux", "1", 1 },
+       }
+};
+static const struct cfiattrdata miicf_iattrdata = {
+       "mii", 1,
+       {
+               { "phy", "-1", -1 },
+       }
+};
+static const struct cfiattrdata cpcbuscf_iattrdata = {
+       "cpcbus", 2,
+       {
+               { "addr", "NULL", 0 },
+               { "irq", "-1", -1 },
+       }
+};
+static const struct cfiattrdata parportcf_iattrdata = {
+       "parport", 0, {
+               { NULL, NULL, 0 },
+       }
+};
+static const struct cfiattrdata dbcoolcf_iattrdata = {
+       "dbcool", 0, {
+               { NULL, NULL, 0 },
+       }
+};
+static const struct cfiattrdata usbdevifcf_iattrdata = {
+       "usbdevif", 6,
+       {
+               { "port", "-1", -1 },
+               { "configuration", "-1", -1 },
+               { "interface", "-1", -1 },
+               { "vendor", "-1", -1 },
+               { "product", "-1", -1 },
+               { "release", "-1", -1 },
+       }



Home | Main Index | Thread Index | Old Index