From owner-svn-src-all@FreeBSD.ORG Mon Feb 23 18:36:55 2009 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 68BC110656CF; Mon, 23 Feb 2009 18:36:55 +0000 (UTC) (envelope-from thompsa@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 3C2348FC37; Mon, 23 Feb 2009 18:36:55 +0000 (UTC) (envelope-from thompsa@FreeBSD.org) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id n1NIatC7032671; Mon, 23 Feb 2009 18:36:55 GMT (envelope-from thompsa@svn.freebsd.org) Received: (from thompsa@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id n1NIasQM032661; Mon, 23 Feb 2009 18:36:54 GMT (envelope-from thompsa@svn.freebsd.org) Message-Id: <200902231836.n1NIasQM032661@svn.freebsd.org> From: Andrew Thompson Date: Mon, 23 Feb 2009 18:36:54 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r188945 - in head: etc/mtree include lib/libusb20 lib/libusbhid share/man/man7 usr.bin/usbhidaction usr.bin/usbhidctl usr.sbin/bluetooth/bcmfw X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 23 Feb 2009 18:36:58 -0000 Author: thompsa Date: Mon Feb 23 18:36:54 2009 New Revision: 188945 URL: http://svn.freebsd.org/changeset/base/188945 Log: Build fixups for the new USB stack. Modified: head/etc/mtree/BSD.include.dist head/include/Makefile head/lib/libusb20/libusb20_ugen20.c head/lib/libusbhid/descr.c head/lib/libusbhid/descr_compat.c head/lib/libusbhid/usbvar.h head/share/man/man7/hier.7 head/usr.bin/usbhidaction/usbhidaction.c head/usr.bin/usbhidctl/usbhid.c head/usr.sbin/bluetooth/bcmfw/bcmfw.c Modified: head/etc/mtree/BSD.include.dist ============================================================================== --- head/etc/mtree/BSD.include.dist Mon Feb 23 18:34:56 2009 (r188944) +++ head/etc/mtree/BSD.include.dist Mon Feb 23 18:36:54 2009 (r188945) @@ -120,10 +120,6 @@ .. usb .. - usb2 - include - .. - .. utopia .. vkbd Modified: head/include/Makefile ============================================================================== --- head/include/Makefile Mon Feb 23 18:34:56 2009 (r188944) +++ head/include/Makefile Mon Feb 23 18:36:54 2009 (r188945) @@ -54,7 +54,7 @@ LSUBDIRS= cam/scsi \ security/mac_mls security/mac_partition \ ufs/ffs ufs/ufs -LSUBSUBDIRS= dev/mpt/mpilib dev/usb2/include +LSUBSUBDIRS= dev/mpt/mpilib .if ${MACHINE_ARCH} == "powerpc" _dev_powermac_nvram= dev/powermac_nvram Modified: head/lib/libusb20/libusb20_ugen20.c ============================================================================== --- head/lib/libusb20/libusb20_ugen20.c Mon Feb 23 18:34:56 2009 (r188944) +++ head/lib/libusb20/libusb20_ugen20.c Mon Feb 23 18:36:54 2009 (r188945) @@ -39,11 +39,11 @@ #include "libusb20_desc.h" #include "libusb20_int.h" -#include -#include -#include -#include -#include +#include +#include +#include +#include +#include static libusb20_init_backend_t ugen20_init_backend; static libusb20_open_device_t ugen20_open_device; Modified: head/lib/libusbhid/descr.c ============================================================================== --- head/lib/libusbhid/descr.c Mon Feb 23 18:34:56 2009 (r188944) +++ head/lib/libusbhid/descr.c Mon Feb 23 18:36:54 2009 (r188945) @@ -39,7 +39,7 @@ __FBSDID("$FreeBSD$"); #include #include -#include +#include #include "usbhid.h" #include "usbvar.h" @@ -49,8 +49,10 @@ hid_set_immed(int fd, int enable) { int ret; ret = ioctl(fd, USB_SET_IMMED, &enable); +#ifdef HID_COMPAT7 if (ret < 0) ret = hid_set_immed_compat7(fd, enable); +#endif return (ret); } @@ -61,9 +63,11 @@ hid_get_report_id(int fd) int ret; ret = ioctl(fd, USB_GET_REPORT_ID, &temp); +#ifdef HID_COMPAT7 if (ret < 0) ret = hid_get_report_id_compat7(fd); else +#endif ret = temp; return (ret); @@ -81,11 +85,13 @@ hid_get_report_desc(int fd) /* get actual length first */ ugd.ugd_data = NULL; ugd.ugd_maxlen = 65535; +#ifdef HID_COMPAT7 if (ioctl(fd, USB_GET_REPORT_DESC, &ugd) < 0) { /* could not read descriptor */ /* try FreeBSD 7 compat code */ return (hid_get_report_desc_compat7(fd)); } +#endif /* * NOTE: The kernel will return a failure if Modified: head/lib/libusbhid/descr_compat.c ============================================================================== --- head/lib/libusbhid/descr_compat.c Mon Feb 23 18:34:56 2009 (r188944) +++ head/lib/libusbhid/descr_compat.c Mon Feb 23 18:36:54 2009 (r188945) @@ -28,6 +28,7 @@ * This file contains fallback-compatibility code for the old FreeBSD * USB stack. */ +#ifdef HID_COMPAT7 #include __FBSDID("$FreeBSD$"); @@ -75,3 +76,4 @@ hid_get_report_desc_compat7(int fd) return (hid_use_report_desc(rep.ucrd_data, (unsigned int)rep.ucrd_size)); } +#endif /* HID_COMPAT7 */ Modified: head/lib/libusbhid/usbvar.h ============================================================================== --- head/lib/libusbhid/usbvar.h Mon Feb 23 18:34:56 2009 (r188944) +++ head/lib/libusbhid/usbvar.h Mon Feb 23 18:36:54 2009 (r188945) @@ -36,6 +36,8 @@ struct report_desc { /* internal backwards compatibility functions */ +#ifdef HID_COMPAT7 int hid_set_immed_compat7(int fd, int enable); int hid_get_report_id_compat7(int fd); report_desc_t hid_get_report_desc_compat7(int fd); +#endif Modified: head/share/man/man7/hier.7 ============================================================================== --- head/share/man/man7/hier.7 Mon Feb 23 18:34:56 2009 (r188944) +++ head/share/man/man7/hier.7 Mon Feb 23 18:36:54 2009 (r188945) @@ -232,8 +232,6 @@ see .Xr ppbus 4 .It Pa usb/ The USB subsystem -.It Pa usb2/include -The USB subsystem .It Pa utopia/ Physical chip driver for ATM interfaces; see Modified: head/usr.bin/usbhidaction/usbhidaction.c ============================================================================== --- head/usr.bin/usbhidaction/usbhidaction.c Mon Feb 23 18:34:56 2009 (r188944) +++ head/usr.bin/usbhidaction/usbhidaction.c Mon Feb 23 18:36:54 2009 (r188945) @@ -46,7 +46,7 @@ #include #include #include -#include +#include #include #include #include Modified: head/usr.bin/usbhidctl/usbhid.c ============================================================================== --- head/usr.bin/usbhidctl/usbhid.c Mon Feb 23 18:34:56 2009 (r188944) +++ head/usr.bin/usbhidctl/usbhid.c Mon Feb 23 18:36:54 2009 (r188945) @@ -47,7 +47,7 @@ #include #include #include -#include +#include int verbose = 0; int all = 0; Modified: head/usr.sbin/bluetooth/bcmfw/bcmfw.c ============================================================================== --- head/usr.sbin/bluetooth/bcmfw/bcmfw.c Mon Feb 23 18:34:56 2009 (r188944) +++ head/usr.sbin/bluetooth/bcmfw/bcmfw.c Mon Feb 23 18:36:54 2009 (r188945) @@ -35,6 +35,7 @@ #include #include #include +#include #include #include #include