summaryrefslogtreecommitdiffstats
path: root/sys/dev/usb/dwc2/dwc2.c (follow)
Commit message (Collapse)AuthorAgeFilesLines
* Use non-blocking allocation in dwc2_allocx() to makevisa2019-03-141-2/+6
| | | | | | | | | the routine safe to use in soft interrupt context. This fixes an assertwaitok() panic reported by Abel Abraham Camarillo Ojeda. OK mpi@
* Add missing bus powered bit, from aalm@mpi2019-03-111-2/+2
|
* kill RCSID macros; discussed with millertderaadt2017-06-291-6/+1
|
* Replace remaining SPLUSBCHECK by a splsoftassert(IPL_SOFTUSB).mpi2017-05-151-2/+2
| | | | USB is the last real user of IPL_SOFTNET.
* Rename Debugger() into db_enter().mpi2017-04-301-2/+2
| | | | | | | Using a name with the 'db_' prefix makes it invisible from the dynamic profiler. ok deraadt@, kettenis@, visa@
* Fix a use-after-free when sending root hub control transfers.mpi2017-03-101-2/+2
| | | | | | | | | | | *_root_ctrl_start() routines are synchronous and all end up calling usb_transfer_complete() in the non-error case. After calling this function it is unsafe to dereference ``xfer'' since the transfer callback has been called. So returning USBD_IN_PROGRESS is wrong in this case since transfers are always completed at this point. So return USBD_NORMAL_COMPLETION or the corresponding error code if something wrong happen.
* Move per HC polling code to the stack.mpi2017-03-101-47/+1
| | | | | | | | | This code contains a use-after-free which be addressed in an upcoming diff. This fix xhci(4) polling mode. ok kettenis@
* Remove an unnecessary NULL pointer check.visa2017-02-161-7/+4
| | | | OK stsp@
* Replace dummy mutex asserts with real ones.visa2017-02-121-2/+2
| | | | OK stsp@
* Prefer <sys/endian.h> to <machine/endian.h>guenther2017-02-041-2/+2
| | | | ok visa@
* Remove unused functions.kettenis2016-09-241-51/+1
| | | | ok jmatthew@, visa@
* all pools have their ipl set via pool_setipl, so fold it into pool_init.dlg2016-09-151-7/+4
| | | | | | | | | | | | | | | | | | | | | | the ioff argument to pool_init() is unused and has been for many years, so this replaces it with an ipl argument. because the ipl will be set on init we no longer need pool_setipl. most of these changes have been done with coccinelle using the spatch below. cocci sucks at formatting code though, so i fixed that by hand. the manpage and subr_pool.c bits i did myself. ok tedu@ jmatthew@ @ipl@ expression pp; expression ipl; expression s, a, o, f, m, p; @@ -pool_init(pp, s, a, o, f, m, p); -pool_setipl(pp, ipl); +pool_init(pp, s, a, ipl, f, m, p);
* Drop unused goto label.visa2015-12-231-4/+3
|
* Remove two error-on-NULL conditions for allocations that can't fail.mmcc2015-12-181-5/+1
| | | | ok visa@
* Properly cancel any pending USB abort task when aborting a transfervisa2015-09-031-2/+13
| | | | | | | and skip completed transfers in dwc2_abort_xfer(). This fixes some timeout-related crashes. Feedback and ok mpi@
* Remove the abort_task field in struct dwc2_xfer. There is an identicalvisa2015-09-031-6/+4
| | | | | | field in struct usbd_xfer which is part of dwc2_xfer. ok mpi@
* Remove sc->sc_lock and add several splusb()'s in dwc2, to avoid avisa2015-09-031-85/+14
| | | | | | | possible lock recursion panic on transfer timeout. The lock is not needed yet because the USB stack is not MP-safe. ok mpi@, "makes sense" jasper@
* Convert list_head lists into TAILQs and LISTs and fix up header includesjmatthew2015-06-281-2/+2
| | | | | | so we can build dwc2 without extra stuff. tested by several edgerouter lite owners, ok jasper@
* Revert previous. uvideo checks the transfered length of every frame andmpi2015-06-261-5/+5
| | | | | | this break some devices. As found the hardway by Hugo Sastre via sobrado@
* Do not update frame lengths to reflect what has really been transferedmpi2015-06-221-5/+5
| | | | | | | | when an isochronous transfer is done. Frame lengths are just input values and no driver mess with them. ok ratchov@, jmatthew@
* rearrange delayed_work to avoid the use of container_of while leaving it injmatthew2015-06-081-2/+2
| | | | | | more or less the same shape. ok uebayasi@
* refuse to do polled isochronous transfers, as other usb controller drivers dojmatthew2015-06-081-4/+5
| | | | requested by mpi@
* Ensure polled bulk, control and interrupt transfers actually poll, fixingjmatthew2015-06-081-9/+6
| | | | | | panics on shutdown with various usb sticks. ok mpi@
* Let it compile.mpi2015-03-191-5/+5
|
* Abort tasks are run in their own thead, that's why they need a specialmpi2015-03-191-2/+2
| | | | type, from Patrick Wildt.
* Use the same workaround as ehci(4) and ohci(4) in setaddr() to deal withmpi2015-03-191-1/+26
| | | | half configured control pipe, from Patrick Wildt.
* Handle (poll) HCD interrupt right after initialization to immediately markuebayasi2015-02-141-1/+4
| | | | ports as enabled/connected.
* Provide interface for external DMA address configuration.uebayasi2015-02-121-1/+8
|
* De-static for backtracing, but using #define to not change indent (for now).uebayasi2015-02-121-111/+111
|
* Don't panic even if parent port doesn't exist.uebayasi2015-02-121-3/+5
|
* - Fix thinko about struct usbd_xfer allocation.uebayasi2015-02-111-7/+7
| | | | - Use bus_dma_tag_t held in struct usbd_bus.
* Fix debug build, etc.uebayasi2015-02-111-18/+18
|
* Adjust usb(9) API differences to at least compile.uebayasi2015-02-101-48/+58
|
* Adjust various kernel API differences.uebayasi2015-02-101-11/+11
|
* Convert tsleep(9)/wakeup(9) usages.uebayasi2015-02-101-5/+5
|
* Whitespace.uebayasi2015-02-101-14/+14
|
* Convert timeout(9)/taskq(9) usages.uebayasi2015-02-101-5/+6
|
* Convert malloc(9)/free(9) usages.uebayasi2015-02-101-3/+4
|
* Convert pool(9) usages.uebayasi2015-02-101-9/+12
|
* s/device_t/struct device */uebayasi2015-02-101-14/+14
|
* s/mutex/mtx/uebayasi2015-02-101-87/+87
| | | | | | | | s/pool_cache/pool/ s/callout/timeout/ s/kmem/malloc/ s/workqueue/taskq/ s/softint/softintr/
* Whitespace.uebayasi2015-02-101-38/+38
|
* s/usb_dma_t/struct usb_dma */uebayasi2015-02-101-5/+5
|
* s/usbd_xfer_handle/struct usbd_xfer */uebayasi2015-02-101-103/+103
| | | | | s/usbd_pipe_handle/struct usbd_pipe */ s/usbd_device_handle/struct usbd_device */
* s/Static/static/uebayasi2015-02-101-97/+97
|
* Convert header paths.uebayasi2015-02-101-6/+13
|
* Add RCS IDs.uebayasi2015-02-101-0/+3
|
* Redo dwc2 import with CVS tags expanded.uebayasi2015-02-101-2/+2
|
* Import dwc2 core and glue code from NetBSD. OK deraadt@ jsing@ miod@ mpi@uebayasi2015-02-101-0/+1801