summaryrefslogtreecommitdiff
path: root/include/linux/usbdevice_fs.h
AgeCommit message (Collapse)Author
2008-07-21USB: remove CVS keywordsAdrian Bunk
This patch removes CVS keywords that weren't updated for a long time from comments. Signed-off-by: Adrian Bunk <bunk@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-04-24USB: usbfs: export the URB_NO_INTERRUPT flag to userspaceAlan Stern
This patch (as1079) cleans up the way URB_* flags are exported in usbfs. The URB_NO_INTERRUPT flag is now exported (this is the only behavioral change). USBDEVFS_URB_* macros are added for URB_NO_FSBR, URB_ZERO_PACKET, and URB_NO_INTERRUPT, making explicit the fact that the kernel accepts them. The flag matching takes into account that the URB_* values may change as the kernel evolves, whereas the USBDEVFS_URB_* values must remain fixed since they are a user API. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-02-01USB: usbdevfs_urb: __user annotationMarcin Slusarz
fix warning: drivers/usb/core/devio.c:1226:20: warning: incorrect type in assignment (different address spaces) drivers/usb/core/devio.c:1226:20: expected void *usercontext drivers/usb/core/devio.c:1226:20: got void [noderef] <asn:1>* Signed-off-by: Marcin Slusarz <marcin.slusarz@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-11-28USB: Fix signr comment in usbdevice_fs.hPhil Endecott
This trivial documentation patch corrects a comment in usbdevice_fs.h; it previously suggested that the signal would only be sent on error, but I am told that it is sent on both successful and unsuccessful completion, and that zero indicates that no signal should be sent. Signed-off-by: Phil Endecott <spam_from_usb_devel@chezphil.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-02-16USB: use __u32 rather than u32 in userspace ioctls in usbdevice_fs.hMike Frysinger
Use __u32 rather than u32 in userspace ioctl defines. Signed-off-by: Mike Frysinger <vapier@gentoo.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-09-24Move several *_SUPER_MAGIC symbols to include/linux/magic.h.Jeff Garzik
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2006-04-25Don't export CONFIG_COMPAT stuff in linux/usbdevice_fs.h to userspaceDavid Woodhouse
Signed-off-by: David Woodhouse <dwmw2@infradead.org>
2005-10-28[PATCH] usb: Patch for USBDEVFS_IOCTL from 32-bit programsPete Zaitcev
Dell supplied me with the following test: #include<stdio.h> #include<errno.h> #include<sys/ioctl.h> #include<fcntl.h> #include<linux/usbdevice_fs.h> main(int argc,char*argv[]) { struct usbdevfs_hub_portinfo hubPortInfo = {0}; struct usbdevfs_ioctl command = {0}; command.ifno = 0; command.ioctl_code = USBDEVFS_HUB_PORTINFO; command.data = (void*)&hubPortInfo; int fd, ret; if(argc != 2) { fprintf(stderr,"Usage: %s /proc/bus/usb/<BusNo>/<HubID>\n",argv[0]); fprintf(stderr,"Example: %s /proc/bus/usb/001/001\n",argv[0]); exit(1); } errno = 0; fd = open(argv[1],O_RDWR); if(fd < 0) { perror("open failed:"); exit(errno); } errno = 0; ret = ioctl(fd,USBDEVFS_IOCTL,&command); printf("IOCTL return status:%d\n",ret); if(ret<0) { perror("IOCTL failed:"); close(fd); exit(3); } else { printf("IOCTL passed:Num of ports %d\n",hubPortInfo.nports); close(fd); exit(0); } return 0; } I have verified that it breaks if built in 32 bit mode on x86_64 and that the patch below fixes it. Signed-off-by: Pete Zaitcev <zaitcev@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2005-09-12[PATCH] USB: fix usbdevice_fs header breakageHarald Welte
[USBDEVFS] fix inclusion of <linux/compat.h> to avoud header mess Without moving the include of compat.h down, userspace programs that use usbdevice_fs.h end up including half the kernel includes (and eventually fail to compile). Signed-off-by: Harald Welte <laforge@netfilter.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2005-03-07[PATCH] USB: compat ioctl for submiting URBAndrew Morton
From: Christopher Li <chrisl@vmware.com> - Let usbdevfs directly handle 32 bit URB ioctl. More specifically: USBDEVFS_SUBMITURB32, USBDEVFS_REAPURB32 and USBDEVFS_REAPURBNDELAY32. Those asynchronous ioctls are too complicate to handle by the compatible layer. Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2004-11-29USB: move a internal usbfs only structure out of a public header file.Greg Kroah-Hartman
Signed-off-by: Greg Kroah-Hartman <greg@kroah.com>
2004-09-05USB: remove usbdevfs filesystem name, usbfs is the proper one to use.Greg Kroah-Hartman
This has been publicised for years now, and the usvfs name will work just fine with a 2.4 kernel, so we are not breaking backwards compatibility. Signed-off-by: Greg Kroah-Hartman <greg@kroah.com>
2004-07-12[PATCH] sparse: usb ioctl cleanupsAlexander Viro
usb ioctls in compat_ioctl.c switched to compat_alloc_user_space() and cleaned up; ioctl structures annotated.
2004-04-23[PATCH] USB usbfs: replace the per-file semaphore with the per-device semaphoreDuncan Sands
devio.c | 43 +++++++++++++++++++++++-------------------- usbdevice_fs.h | 1 - 2 files changed, 23 insertions(+), 21 deletions(-)
2003-06-10[PATCH] USB: lots of sparse fixups for usbfsGreg Kroah-Hartman
2002-09-30[PATCH] usbcore misc cleanupDavid Brownell
This has minor usbcore cleanups: DOC: - the changes passing a usb_interface to driver probe() and disconnect() weren't reflected in their adjacent docs. likewise they still said it was possible to get a null usb_device_id (no more). - the (root) hub API restrictions from rmk's ARM patch weren't flagged - mention the non-dma-coherent cache issue for usb_buffer_alloc() - mention disconnect() cleanup issue with usb_{control,bulk}_msg() [ you can't cancel those urbs from disconnect() ] CODE - make driver ioctl() use 'usb_interface' too ... this update also resolves an old 'one instance per device' bad assumption - module locking on driver->ioctl() was goofy, kept BKL way too long and didn't try_inc_mod_count() like the rest of usbcore - hcd unlink code treated iso inappropriately like interrupt; only interrupt still wants that automagic mode - move iso init out of ohci into shared submit_urb logic - remove interrupt transfer length restriction; hcds that don't handle packetization (just like bulk :) should be updated, but device drivers won't care for now.
2002-07-06[PATCH] urb->transfer_flags updatesDavid Brownell
This patch fixes two problems that have already been discussed on this list: - USB_QUEUE_BULK is rather pointless (and UHCI-specific). If drivers really want only one bulk urb queued at a time, they just shouldn't issue such urbs till others complete. FIX: remove it entirely. - USB_DISABLE_SPD is horribly named (based on a UHCI flag). What it really does is turn non-ISO short reads into errors. FIX: rename it. Now it's URB_SHORT_NOT_OK. I changed all the drivers using these two flags, including corresponding changes in the "usbfs" API. Most of the patch by volume is doc updates: - Documentation/usb/URB.txt hadn't been updated in two years (!) and was pretty out of date. It also had many details that were inappropriately specific to usb-uhci. - Most of the URB flags weren't even commented as to intent. - DISABLE_SPD was often documented as if it were SHORT_IS_OK. - There was still some doc saying how iso should use urb->next. There are also some related updates: - Some of the submit sanity checks for transfer flags were overly broad ... SHORT_NOT_OK is only for reads, NO_FSBR is for non-periodic requests, ZERO_PACKET only for writes. - The ohci-hcd code thought SHORT_NOT_OK worked for ISO. - The uhci-hcd code thought QUEUE_BULK applied to non-bulk Note that this patch doesn't update any of the "old" HCDs, including usb-ohci-hcd. In the case of usb-uhci{,-hcd} it'd have been painful to fix the QUEUE_BULK logic. That logic was, I think, the original reason to have that flag! So I count switching to "uhci-hcd" as a win already ... :)
2002-04-07[PATCH] usbfs disconnectDan Streetman
This was originally created by David many months ago and posted to the list, but not put into the kernel. I modified the original patch to: -patch against the 2.5.7 kernel -use the 'real' interface number, not position (to do this I added 2 methods in usb.c)
2002-02-05v2.5.1.9 -> v2.5.1.10Linus Torvalds
- Kai Germaschewski: ISDN updates - Al Viro: start moving buffer cache indexing to "struct block_device *" - Greg KH: USB update - Russell King: fix up some ARM merge issues - Ingo Molnar: scalable scheduler
2002-02-04v2.5.1.5 -> v2.5.1.6Linus Torvalds
- Davide Libenzi: nicer timeslices for scheduler - Arnaldo: wd7000 scsi driver cleanups and bio update - Greg KH: USB update (including initial 2.0 support) - me: strict typechecking on "kdev_t"
2002-02-04v2.4.6.1 -> v2.4.6.2Linus Torvalds
- merge with Alan (USB, zoran, sony motion-eye, rio, dmi-scan)
2002-02-04Import changesetLinus Torvalds