Deleted Added
sdiff udiff text old ( 185087 ) new ( 188622 )
full compact
1/* $FreeBSD: head/usr.sbin/usbconfig/dump.c 185087 2008-11-19 08:56:35Z alfred $ */
2/*-
3 * Copyright (c) 2008 Hans Petter Selasky. All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer.

--- 161 unchanged lines hidden (view full) ---

171 for (z = 0; z != iface->num_endpoints; z++) {
172 printf("\n Endpoint %u\n", z);
173 dump_endpoint(pdev, iface->endpoints + z);
174 }
175 return;
176}
177
178void
179dump_device_info(struct libusb20_device *pdev)
180{
181 printf("%s, cfg=%u md=%s spd=%s pwr=%s\n",
182 libusb20_dev_get_desc(pdev),
183 libusb20_dev_get_config_index(pdev),
184 dump_mode(libusb20_dev_get_mode(pdev)),
185 dump_speed(libusb20_dev_get_speed(pdev)),
186 dump_power_mode(libusb20_dev_get_power_mode(pdev)));
187 return;
188}
189
190void
191dump_be_quirk_names(struct libusb20_backend *pbe)
192{
193 struct libusb20_quirk q;
194 uint16_t x;
195 int error;

--- 138 unchanged lines hidden (view full) ---

334 if ((error = libusb20_dev_get_iface_perm(pdev, iface, &mode))) {
335 return (error);
336 }
337 if (mode) {
338
339 owner = (pw = getpwuid(uid)) ? pw->pw_name : "UNKNOWN";
340 group = (gr = getgrgid(gid)) ? gr->gr_name : "UNKNOWN";
341
342 printf(" " "Interface %u Access: %s:%s 0%o\n", iface, owner, group, mode);
343 } else {
344 printf(" " "Interface %u Access: <not set>\n", iface);
345 }
346
347 return (0);
348}
349
350void

--- 57 unchanged lines hidden ---