History log of /src/sys/dev/usb/ualea.c |
Revision | | Date | Author | Comments |
1.19 |
| 20-Mar-2022 |
riastradh | ualea(4): Enter the data under the softc lock.
This avoids a race with a concurrent ualea_get updating sc_needed, which could lead to hang when requesting more entropy.
ualea(4) now survives
sysctl -w kern.entropy.depletion=1 cat </dev/random >/dev/null & cat </dev/random >/dev/null &
without hanging for longer (even if yanked and reinserted in the middle, although the detach path is not relevant to the bug this change fixes).
|
1.18 |
| 20-Mar-2022 |
riastradh | ualea(4): Simplify xfer error branches.
- Avoid going into a loop in case the transfer fails repeatedly -- just give up immediately if it fails.
- Assert result size is reasonable; no need to assume usbdi(9) is malicious. If it can return ux_actlen > ux_length, that's a bug in usbdi(9) that we should fix.
|
1.17 |
| 20-Mar-2022 |
riastradh | ualea(4): Fix detach and error paths.
- Set sc_needed before aborting the pipe to prevent the xfer callback from rescheduling itself.
- Make sure all paths out of the xfer callback clear sc_inflight.
While here, use device_printf instead of aprint_* after attach.
Now my system survives repeated insertion and yanking of ualea(4) during:
sysctl -w kern.entropy.depletion=1 cat </dev/random >/dev/null
|
1.16 |
| 19-Mar-2022 |
riastradh | rnd(9): Adjust IPL of locks used by rndsource callbacks.
These no longer ever run from hard interrupt context or with a spin lock held, so there is no longer any need to have them at IPL_VM to block hard interrupts. Instead, lower them to IPL_SOFTSERIAL.
|
1.15 |
| 03-Mar-2022 |
riastradh | usb: usbd_close_pipe never fails. Make it return void.
Prune dead branches as a result of this change.
|
1.14 |
| 03-Mar-2022 |
riastradh | usb: usbd_abort_pipe never fails. Make it return void.
Prune dead branches as a result of this change.
|
1.13 |
| 29-May-2021 |
riastradh | ualea(4): Null suspend/resume handler.
|
1.12 |
| 13-Jul-2020 |
simonb | branches: 1.12.6; 1.12.8; Set up the USB xfer for every transfer, not just once in the attach function. Caught by DIAGNOSTIC on a similar driver. Thanks to phone@ for USB xfer clue and martin@ for testing.
|
1.11 |
| 30-Apr-2020 |
riastradh | rnd_attach_source calls the callback itself now.
No need for every driver to explicitly call it to prime the pool.
Eliminate now-unused <sys/rndpool.h>.
|
1.10 |
| 30-Apr-2020 |
riastradh | Turn XXX comment into KASSERT.
|
1.9 |
| 21-Jan-2018 |
skrll | branches: 1.9.10; PR kern/52931 Kernel panics with Atheros usb wireless interface
Audit the flags to usbd_create_xfer so that USBD_FORCE_SHORT_XFER is supplied wherever such a transfer is setup. We can drop USBD_SHORT_XFER_OK as it has not bearing on number of TDs
|
1.8 |
| 18-Jul-2017 |
christos | branches: 1.8.2; 1.8.4; don't subtract uninitialized pktsize in error path.
|
1.7 |
| 15-Jul-2017 |
riastradh | branches: 1.7.2; Tidy up a bit. Fulfil requests completely.
|
1.6 |
| 19-Apr-2017 |
riastradh | branches: 1.6.2; 1.6.4; 1.6.8; Modularize ualea(4).
Unclear why we have a separate xyz.ioconf for module and XYZ.ioconf for rump component, but at least xyz_modcmd obviates the need for xyz_component.c (though evidently the latter could have been replaced anyway by RUMP_COMPONENT=ioconf in the rump component Makefile).
|
1.5 |
| 18-Apr-2017 |
riastradh | gson@ informs me the Alea I and II have the same USB product id.
Thus, ualea(4) should work for both of them. Rename USB product id ARANEUS ALEA_II to ARANEUS ALEA to reflect this.
No functional change intended, except perhaps via usbdevs.
|
1.4 |
| 17-Apr-2017 |
riastradh | IPL_SOFTUSB suffices here to synchronize with usb xfer callback.
|
1.3 |
| 17-Apr-2017 |
riastradh | Follow my own locking rules.
|
1.2 |
| 17-Apr-2017 |
riastradh | Tweak locking rule. Fix broken unlocked rmw.
|
1.1 |
| 17-Apr-2017 |
riastradh | New rndsource driver for Araneus Alea II TRNG USB devices.
Disabled by default in x86/GENERIC and usbdevices.config pending review and testing without rump ugenhc in the way, but enabled in x86/ALL for compile-testing.
(Hi gson! Finally found a round tuit in my pocket, next to a certain rectangular one.)
|
1.6.8.2 |
| 13-Jul-2020 |
martin | Pull up following revision(s) (requested by simonb in ticket #1573):
sys/dev/usb/ualea.c: revision 1.12
Set up the USB xfer for every transfer, not just once in the attach function. Caught by DIAGNOSTIC on a similar driver. Thanks to mrg@ for USB xfer clue and martin@ for testing.
|
1.6.8.1 |
| 31-Jan-2018 |
martin | Pull up following revision(s) (requested by skrll in ticket #509): sys/dev/usb/if_ural.c: revision 1.53 sys/dev/usb/if_run.c: revision 1.25 sys/dev/usb/ustir.c: revision 1.39 sys/dev/usb/irmce.c: revision 1.4 sys/dev/usb/if_urtwn.c: revision 1.56 sys/dev/usb/pseye.c: revision 1.24 sys/dev/usb/if_rum.c: revision 1.59 sys/dev/usb/if_upl.c: revision 1.61 sys/dev/usb/ucom.c: revision 1.120 sys/dev/usb/if_zyd.c: revision 1.45 sys/dev/usb/if_axen.c: revision 1.12 sys/dev/usb/umidi.c: revision 1.74 sys/dev/usb/if_udav.c: revision 1.52 sys/dev/usb/if_athn_usb.c: revision 1.25 sys/dev/usb/usscanner.c: revision 1.43 sys/dev/usb/ualea.c: revision 1.6 - 1.9 sys/dev/usb/if_upgt.c: revision 1.18 sys/dev/usb/if_atu.c: revision 1.56 sys/dev/usb/utoppy.c: revision 1.30 sys/dev/usb/ubt.c: revision 1.60 sys/dev/usb/if_urtw.c: revision 1.14 sys/dev/usb/uirda.c: revision 1.43 sys/dev/usb/umass.c: revision 1.163 sys/dev/usb/if_cdce.c: revision 1.45 sys/dev/usb/if_cue.c: revision 1.77 sys/dev/usb/if_kue.c: revision 1.91 sys/dev/usb/uvideo.c: revision 1.46 sys/dev/usb/uhso.c: revision 1.27 sys/dev/usb/if_smsc.c: revision 1.33 sys/dev/usb/ugen.c: revision 1.137 sys/dev/usb/if_axe.c: revision 1.84 sys/dev/usb/if_aue.c: revision 1.142 sys/dev/usb/uscanner.c: revision 1.82 sys/dev/usb/if_urndis.c: revision 1.17 sys/dev/usb/udsir.c: revision 1.6 sys/dev/usb/if_url.c: revision 1.57 sys/dev/usb/if_otus.c: revision 1.32 sys/dev/usb/ulpt.c: revision 1.99
PR kern/52931 Kernel panics with Atheros usb wireless interface Audit the flags to usbd_create_xfer so that USBD_FORCE_SHORT_XFER is supplied wherever such a transfer is setup. We can drop USBD_SHORT_XFER_OK as it has not bearing on number of TDs
ualea: Tidy up a bit. Fulfil requests completely. Don't subtract uninitialized pktsize in error path.
|
1.6.4.2 |
| 26-Apr-2017 |
pgoyette | Sync with HEAD
|
1.6.4.1 |
| 19-Apr-2017 |
pgoyette | file ualea.c was added on branch pgoyette-localcount on 2017-04-26 02:53:23 +0000
|
1.6.2.2 |
| 21-Apr-2017 |
bouyer | Sync with HEAD
|
1.6.2.1 |
| 19-Apr-2017 |
bouyer | file ualea.c was added on branch bouyer-socketcan on 2017-04-21 16:53:53 +0000
|
1.7.2.2 |
| 15-Jul-2017 |
riastradh | 2992172
|
1.7.2.1 |
| 15-Jul-2017 |
riastradh | file ualea.c was added on branch perseant-stdc-iso10646 on 2017-07-15 05:46:10 +0000
|
1.8.4.2 |
| 03-Dec-2017 |
jdolecek | update from HEAD
|
1.8.4.1 |
| 18-Jul-2017 |
jdolecek | file ualea.c was added on branch tls-maxphys on 2017-12-03 11:37:34 +0000
|
1.8.2.2 |
| 28-Aug-2017 |
skrll | Sync with HEAD
|
1.8.2.1 |
| 18-Jul-2017 |
skrll | file ualea.c was added on branch nick-nhusb on 2017-08-28 17:52:27 +0000
|
1.9.10.3 |
| 21-Jun-2021 |
martin | Pull up following revision(s) (requested by riastradh in ticket #1302):
sys/dev/usb/ualea.c: revision 1.13
ualea(4): Null suspend/resume handler.
|
1.9.10.2 |
| 15-Jul-2020 |
martin | Pull up following revision(s) (requested by riastradh in ticket #1008):
sys/dev/usb/ualea.c: revision 1.10
Turn XXX comment into KASSERT.
|
1.9.10.1 |
| 13-Jul-2020 |
martin | Pull up following revision(s) (requested by simonb in ticket #1003):
sys/dev/usb/ualea.c: revision 1.12
Set up the USB xfer for every transfer, not just once in the attach function. Caught by DIAGNOSTIC on a similar driver. Thanks to mrg@ for USB xfer clue and martin@ for testing.
|
1.12.8.1 |
| 31-May-2021 |
cjep | sync with head
|
1.12.6.1 |
| 17-Jun-2021 |
thorpej | Sync w/ HEAD.
|