Date: Tue, 5 Jan 2010 22:50:36 +0000 (UTC) From: Rui Paulo <rpaulo@FreeBSD.org> To: src-committers@freebsd.org, svn-src-user@freebsd.org Subject: svn commit: r201618 - user/rpaulo/ubthidctl Message-ID: <201001052250.o05MoaKo036802@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: rpaulo Date: Tue Jan 5 22:50:36 2010 New Revision: 201618 URL: http://svn.freebsd.org/changeset/base/201618 Log: Try to cope with the new usb stack. Modified: user/rpaulo/ubthidctl/ubthidctl.c Modified: user/rpaulo/ubthidctl/ubthidctl.c ============================================================================== --- user/rpaulo/ubthidctl/ubthidctl.c Tue Jan 5 22:37:05 2010 (r201617) +++ user/rpaulo/ubthidctl/ubthidctl.c Tue Jan 5 22:50:36 2010 (r201618) @@ -22,9 +22,6 @@ * 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$ - * */ /* @@ -33,9 +30,7 @@ */ #include <sys/cdefs.h> -#ifdef __FreeBSD__ __FBSDID("$FreeBSD$"); -#endif #include <err.h> #include <fcntl.h> @@ -46,7 +41,8 @@ __FBSDID("$FreeBSD$"); #include <sys/ioctl.h> -#include <dev/usb/usb.h> +#include <dev/usb/usb_ioctl.h> +#include <dev/usb/usbdi.h> typedef enum { HCI = 0, @@ -81,7 +77,7 @@ finddevice(tblentry_t tblentry) dev.devno = -1; for (i = 0; i < 20; i++) { - snprintf(filename, sizeof(filename) - 1, "/dev/usb%d", i); + snprintf(filename, sizeof(filename) - 1, "/dev/ugen%d.1", i); fd = open(filename, O_RDONLY); if (fd < 0) return dev; @@ -171,7 +167,7 @@ switchmode(const char *dev, const int de USETW(req.ucr_request.wIndex, 0); USETW(req.ucr_request.wLength, 0); req.ucr_data = NULL; - req.ucr_flags = USBD_SHORT_XFER_OK; + req.ucr_flags = USB_SHORT_XFER_OK; req.ucr_request.bmRequestType = UT_VENDOR; req.ucr_request.bRequest = 0;
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201001052250.o05MoaKo036802>