summaryrefslogtreecommitdiffstats
path: root/sys/dev/usb/usb_dev.c
diff options
context:
space:
mode:
authored <ed@FreeBSD.org>2012-02-10 12:35:57 +0000
committered <ed@FreeBSD.org>2012-02-10 12:35:57 +0000
commit28b4a002d6c95bc9e26ea30871aa91c1cc4b3563 (patch)
tree38fefd1e5bde255db2d3eab529d481ce373dec71 /sys/dev/usb/usb_dev.c
parent7bf1094d6b76324d8ab7decb5dc0d06999a72842 (diff)
downloadFreeBSD-src-28b4a002d6c95bc9e26ea30871aa91c1cc4b3563.zip
FreeBSD-src-28b4a002d6c95bc9e26ea30871aa91c1cc4b3563.tar.gz
Remove direct access to si_name.
Code should just use the devtoname() function to obtain the name of a character device. Also add const keywords to pieces of code that need it to build properly. MFC after: 2 weeks
Diffstat (limited to 'sys/dev/usb/usb_dev.c')
-rw-r--r--sys/dev/usb/usb_dev.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/dev/usb/usb_dev.c b/sys/dev/usb/usb_dev.c
index e2c934e..2b99036 100644
--- a/sys/dev/usb/usb_dev.c
+++ b/sys/dev/usb/usb_dev.c
@@ -842,7 +842,7 @@ usb_open(struct cdev *dev, int fflags, int devtype, struct thread *td)
struct usb_cdev_privdata *cpd;
int err, ep;
- DPRINTFN(2, "%s fflags=0x%08x\n", dev->si_name, fflags);
+ DPRINTFN(2, "%s fflags=0x%08x\n", devtoname(dev), fflags);
KASSERT(fflags & (FREAD|FWRITE), ("invalid open flags"));
if (((fflags & FREAD) && !(pd->mode & FREAD)) ||
OpenPOWER on IntegriCloud