Commit Graph

39069 Commits

Author SHA1 Message Date
macallan 5afb4d35f0 only read the backlight level register on mobility chips 2020-06-11 07:51:26 +00:00
macallan c0d0309dde reduce stack usage in radeonfb_pickres() and radeonfb_set_cursor() 2020-06-11 07:46:59 +00:00
msaitoh f91387c6ed Fix IXGBE_LE32_TO_CPUS() macro for big endian machine. This problem was
only on X550*. Not tested on big endian machine.
2020-06-11 05:16:22 +00:00
thorpej 814a779807 Update for proplib(3) API changes. 2020-06-11 02:32:06 +00:00
thorpej 98fcc28254 Update for proplib(3) API changes. 2020-06-08 20:19:50 +00:00
thorpej a2b798fdfa Update for proplib(3) API changes. 2020-06-08 20:14:24 +00:00
gson c2d905cb60 Conditionally enable the formerly #if'ed-out code to use the
WRITE_REGION_1 command for writing blocks of data to the device.
This is to address a performance issue where "ifconfig run0 up" would
take as long as 20-30 seconds when using a UHCI or OHCI host
controller due to the large number of control transfers performed by
the driver in combination with the inability of those host controllers
to perform multiple control transfers per USB frame.  Limit the
transfers to 64 bytes as in the corresponding #if'ed-out code in
FreeBSD.  Currently only enabled for mac_ver 0x5390 as it is the only
version tested so far.
2020-06-06 13:53:43 +00:00
skrll 648bd77418 More __BITS. NFCI. 2020-06-06 08:56:30 +00:00
maxv 9259199775 Register eight vHCI buses, and use separate KCOV mailboxes for them. 2020-06-05 17:20:56 +00:00
skrll d78befcef4 Replace calls to usbd_device2interface_handle in u3g_match() and
u3g_attach() with the interface already passed in uiaa->uiaa_iface and
store the interface in sc->sc_iface for later use by u3g_open()/

Also skip Direct IP interfaces in u3g_match() to avoid potential side effects.

PR kern/55330
2020-06-05 08:02:32 +00:00
skrll 6c5683e6b5 Remove duplicated USB_VENDOR_SIERRA USB_PRODUCT_SIERRA_USB305 entry
PR kern/55329
2020-06-05 08:01:49 +00:00
skrll 4d4b2f24d4 Near complete conversion to __BITS 2020-06-04 20:54:37 +00:00
riastradh 7e265cbbd4 Add self-tests for 3des and blowfish too.
Nobody should use these on new disks but it is good to have them so
we don't break decrypting old disks.
2020-06-04 19:54:53 +00:00
skrll 74934b7c45 Consistent whitespace. Register defines are <tab> indented. Bits defines
for registers are <tab><space> indented.
2020-06-04 19:50:21 +00:00
riastradh 891d8fde19 Nix trailing whitespace. NFCI. 2020-06-04 03:12:26 +00:00
jmcneill 5754e74670 Re-enable "set cpufreq at boot" code. 2020-06-03 19:55:13 +00:00
bouyer 909c025826 Don't print an error message on spurious interrupt. Way too noisy for Xen. 2020-06-03 18:25:26 +00:00
jmcneill 1ef4ea59ab Disable setting cpufreq at boot for now 2020-06-03 15:47:22 +00:00
jmcneill 8e61883eae Highest speed is first opp, not last 2020-06-03 15:44:45 +00:00
skrll 4a9c8cafe4 Convert ohcireg.h to __BITS. NFCI. 2020-06-03 15:38:02 +00:00
jmcneill 6ddc7ecff0 Select the highest rate at boot, and update cycle counter frequency when rates change 2020-06-02 11:40:02 +00:00
riastradh b57b0d687d Don't queue sysmon refresh until the rndsource is attached.
Using the rndsource, as refreshing the sensors will do, is not
allowed until _after_ rnd_source_attach.

XXX pullup-7
XXX pullup-8
XXX pullup-9
2020-06-01 21:54:47 +00:00
skrll 3d720802db Remove some unnecessary bit shifts by using appropriate read size 2020-06-01 10:25:00 +00:00
maxv 869e8f7b28 Reset ud_ifaces and ud_cdesc to NULL, to prevent use-after-free in
usb_free_device().

Reported-by: syzbot+c7e74d0ae89e9f08f863@syzkaller.appspotmail.com
2020-05-31 18:33:08 +00:00
jdolecek 39045d90bd also set ifc->ui_endpoints to NULL in usbd_free_iface_data() when the value
is freed, to make it impossible to re-enter this by mistake

very likely has no effect for the syzbot problem, but good to do nevetheless

Reported-by: syzbot+c555801d6bc0d768f402@syzkaller.appspotmail.com
2020-05-31 18:20:23 +00:00
maxv 3774168381 If we failed because we didn't encounter an endpoint, do not attempt to
read 'ed', because its value is past the end of the buffer, and we thus
perform out-of-bounds accesses.

Detected thanks to vHCI+KASAN. First bug found by USB fuzzing.

Reported-by: syzbot+59e7f6b3f353584ac810@syzkaller.appspotmail.com
2020-05-31 17:52:58 +00:00
jdolecek f7fe1fb9c3 make bwfm_usb_bus_ops static and const 2020-05-31 11:12:36 +00:00
maxv cbead1015e sc_statuspend is allocated with kmem_zalloc, so no need to memset it. 2020-05-31 08:05:30 +00:00
maxv ad8bcb1485 Add comments. 2020-05-31 07:53:38 +00:00
ad 4d7613fc58 Disable read of the ACPI timer during idle, fixing performance degradation
observed with acpicpu.  C1 (MWAIT) is the deepest sleep currently enabled so
there should be no functional change.  Also, the computed nap time is run
through hztoms() which seems incorrect as the ACPI timer is running in the
MHz range.
2020-05-31 01:39:33 +00:00
sevan b7feb0b56f Use device_xname() to access dv_xname 2020-05-30 22:39:40 +00:00
sevan 0940ad8bdc Use device_t for sc_dev 2020-05-30 22:27:55 +00:00
sevan a164c08f15 Switch from printf to aprintf_error/normal 2020-05-30 22:01:05 +00:00
sevan 112b980b8d Initialise sc->sc_dev, otherwise unnamed interfaces show up and things go
downhill from there.
2020-05-30 21:39:49 +00:00
jdolecek 1c446680eb catch up with changes - need bwfmreg.h before bwfmvar.h 2020-05-30 19:23:25 +00:00
jakllsch 6fe25d02bd aubtfwl(4): Use kmem_asprintf() for firmware file name creation.
A MAXPATHLEN+1 array of char on stack is "too much".
2020-05-30 17:19:45 +00:00
thorpej a4ecedc295 gem_pci_attach(): avoid allocating a 2K buffer on the stack. 2020-05-30 16:35:02 +00:00
jdolecek 1f937b3fb2 discussed with thorpej@, and it seems it's better to allocate the bss
alignment buffer statically (as part of softc) just to be sure to not
affect performance
2020-05-30 15:55:47 +00:00
jdolecek 94a3f73568 reduce stack usage in genfb_calc_hsize() 2020-05-30 14:15:43 +00:00
jdolecek 6f9c6cfca3 reduce stack usage in bwfm_rx_event_cb(), can use KM_SLEEP because
this is called from workqueue handler (i.e. thread context)
2020-05-30 14:03:08 +00:00
jdolecek 4de17f98a0 constify, and make static where possible 2020-05-30 13:41:58 +00:00
jdolecek cd91c1ceb5 fix wdcprobe_with_reset() to avoid allocating big structures on stack 2020-05-30 13:23:14 +00:00
jdolecek e7cfc031b7 allocate memory for dtv_ts_section using kmem_alloc() in dtv_demux_read(),
instead of on-stack

XXX compile-tested only
2020-05-30 13:15:10 +00:00
jdolecek 91d7bdb279 change pci_conf_print() to allocate memory for the regs dynamically
instead of on-stack
2020-05-30 10:43:46 +00:00
jdolecek 00470bd7fd remove #if 0'ed pci_conf_print() call 2020-05-30 10:27:29 +00:00
tsutsui 4981fca22f Avoid use of CALLFRAME_S0 on calling ARC BIOS functions.
On O32 and O64, 0(sp) could be clobbered by callee functions
to save argument a0, so we can't use it to save caller registers.
Use CALLFRAME_SP instead because a frame pointer is not used here.
Maybe all other references of CALLFRAME_S0 might also be problematic
on O32.  Discussed with soda@.
2020-05-30 03:16:31 +00:00
tsutsui 0d22babaca Explicitly use MIPS_CURLWP macro. No binary change. 2020-05-30 02:56:54 +00:00
tsutsui 8bf812ff0a Don't forget to save MIPS_CURLWP (t8) register before restoring it.
Maybe harmless because the only ARC BIOS function that takes
more than four arguments is currently unused.
2020-05-30 02:46:07 +00:00
rin 482eef7050 For struct timecounter, use C99 initializers.
Compile tested. No functional changes intended.
2020-05-29 12:30:38 +00:00
rin 4f34027fb8 Make this compile again. Not tested. 2020-05-29 09:05:19 +00:00