272505 Commits

Author SHA1 Message Date
reed
030d4fb522 Simply Subsection headers
There was a formatting issue with mandoc showing the
literal "Ss" macros. I reported this bug to mandoc since groff
didn't have same formatting. It was recommended to simplify
the formatting due to the weird feature.
Note because of this for groff I didn't use the Ux macro but spelled
out UNIX literally for these subsection headers
(since the macro reset the subsection formatting which was why
the Ss macro was repeated before to reactivate it).
2019-12-23 17:51:57 +00:00
reed
99bf06da72 Simplify Subsection formatting
Had a formatting issue with mandoc but not groff.
Reported to mandoc developer. Bug in mandoc
but was recommended to not use the "weird" feature.
2019-12-23 17:31:54 +00:00
tkusumi
a9ece8969c dm: Make target's ->table() optional
Since ->info() (counter part of ->table() in the original dm design
in Linux kernel in .status where both INFO and TABLE are optional)
is an optional handler, make ->table() optional as well. Some
targets don't have anything to do in ->table() just as in ->info().

taken-from: DragonFlyBSD
2019-12-23 16:17:35 +00:00
thorpej
1dee6ab2d0 Oops, missed one more instance of unneeded-I2C_F_POLL. 2019-12-23 15:51:50 +00:00
jmcneill
3adad74236 Add reference counts to intr_mask/intr_unmask as calls can be nested, spotted by thorpej 2019-12-23 15:51:47 +00:00
thorpej
68a026119d In as3722_poweroff and as3722_reboot(), check for errors from iic_acquire_bus()
before proceeding with writing to the device.
2019-12-23 15:48:51 +00:00
thorpej
5ac7bb284e piixpm_i2c_exec(): No need to check 'cold' to force I2C_F_POLL; the i2c
upper layer does it for us.
2019-12-23 15:41:34 +00:00
thorpej
ef632d17eb ichsmb_i2c_exec(): No need to check 'cold' to force I2C_F_POLL; the i2c
upper layer does it for us.
2019-12-23 15:34:40 +00:00
jmcneill
d7ae102b32 Implement acpi_md_intr_mask and acpi_md_intr_unmask 2019-12-23 15:34:23 +00:00
thorpej
23300298e3 No need to use I2C_F_POLL here. 2019-12-23 15:31:31 +00:00
thorpej
8a538e103e pcfiic_i2c_exec(): No need to check 'cold' to force I2C_F_POLL; the i2c
upper layer does it for us.
2019-12-23 15:29:36 +00:00
thorpej
baeac228ea dwiic_i2c_exec(): No need to check 'cold' to force I2C_F_POLL; the i2c
upper layer does it for us.
2019-12-23 15:28:08 +00:00
thorpej
b0b4a0fa7b No need to use I2C_F_POLL here. 2019-12-23 15:25:08 +00:00
thorpej
fe54f38b71 No need to use I2C_F_POLL here. 2019-12-23 15:07:42 +00:00
thorpej
4cca0dfa33 No need to check 'cold' for I2C_F_POLL; the i2c code does it for us. 2019-12-23 15:05:32 +00:00
thorpej
7c3bc3baec No need to use I2C_F_POLL here. 2019-12-23 14:55:22 +00:00
thorpej
57968d4c6d No need to use I2C_F_POLL here. 2019-12-23 14:41:41 +00:00
thorpej
1104dc0723 In axppmic_power_poweroff(), check for errors from iic_acquire_bus()
before proceeding with writing to the device.
2019-12-23 14:34:23 +00:00
thorpej
d52651a2da Disable the not-in-interrupt assertions for now; more work needs to be
done in several i2c client drivers.
2019-12-23 14:26:19 +00:00
thorpej
3499874410 Provide XEN stubs for intr_mask() / intr_unmask(). 2019-12-23 13:35:37 +00:00
msaitoh
09d135e173 Add recovery code for unsupported SFP+.
Before this commit:
   If an unsuppored SFP module is inserted before booting, the driver attach
   failed and there was no way to recover form it without rebooting or
   detaching/reattaching drvier (drvctl -d && drvctl -r pciN).
After this commit:
   We can automatically recover any time by replacing it with a supported
   module.
2019-12-23 09:36:17 +00:00
msaitoh
2aadcc8478 Add missing core lock in ixgbe_handle_mod(). 2019-12-23 09:19:40 +00:00
maxv
87107185b5 Revert the removal of filemon. 2019-12-23 06:45:36 +00:00
thorpej
0c3f769417 No need to do the poll-during-autoconfiguration dance; the i2c code
does the right thing for us.
2019-12-23 02:50:50 +00:00
thorpej
bf8fd4f373 seeprom_bootstrap_read(): no need to hard-code I2C_F_POLL here because
the i2c code will ensure it's there if the system is cold.
2019-12-23 02:39:47 +00:00
thorpej
82af5f8187 No need to do the poll-during-autoconfiguration dance; the i2c code
does the right thing for us.
2019-12-23 02:25:28 +00:00
thorpej
48bd655e5e No need to check cold ourselves; iic_exec() does it for us. 2019-12-23 02:16:43 +00:00
kamil
cd653c6e17 Explain in kevent(2) the semantics of EINTR
All changes contained in the changelist are applied before returning this
error.
2019-12-23 01:46:09 +00:00
thorpej
6b26049d8e When deciding to delay (rather than kpause), pay attention to
I2C_F_POLL, not 'cold'.
2019-12-23 00:24:02 +00:00
thorpej
17465ae731 Use a separate lock (not the i2c bus lock) to synchronize with the
interrupt handler.  Refactor the code slightly to make the lock use
consistent.

Also includes the changes for:

Cleanup i2c bus acquire / release, centralizing all of the logic into
iic_acquire_bus() / iic_release_bus().  "acquire" and "release" hooks
no longer need to be provided by back-end controller drivers (only if
they need special handling, e.g. powering on the i2c controller).
This results in the removal of a bunch of rendundant code from each
back-end controller driver.

Assert that we are not in hard interrupt context in iic_acquire_bus(),
iic_exec(), and iic_release_bus().
2019-12-22 23:50:43 +00:00
thorpej
7e5becee2e Use a separate lock (not the i2c bus lock) to synchronize with the
interrupt handler.  This in all liklihood fixes a deadlock bug that
necessitated forcing I2C_F_POLL in tegra_i2c_exec() (someone who has
the hardware should test removing that line).

Also includes the changes for:

Cleanup i2c bus acquire / release, centralizing all of the logic into
iic_acquire_bus() / iic_release_bus().  "acquire" and "release" hooks
no longer need to be provided by back-end controller drivers (only if
they need special handling, e.g. powering on the i2c controller).
This results in the removal of a bunch of rendundant code from each
back-end controller driver.

Assert that we are not in hard interrupt context in iic_acquire_bus(),
iic_exec(), and iic_release_bus().
2019-12-22 23:40:49 +00:00
thorpej
6be8ac77ed Rewrite the bcm2835 i2c driver as an interrupt-driven state machine. This
improves general system responsiveness when tranferring large amounts of
data on a single-core Pi board.  This also includes:

Cleanup i2c bus acquire / release, centralizing all of the logic into
iic_acquire_bus() / iic_release_bus().  "acquire" and "release" hooks
no longer need to be provided by back-end controller drivers (only if
they need special handling, e.g. powering on the i2c controller).
This results in the removal of a bunch of rendundant code from each
back-end controller driver.

Assert that we are not in hard interrupt context in iic_acquire_bus(),
iic_exec(), and iic_release_bus().
2019-12-22 23:24:56 +00:00
thorpej
601e178380 Cleanup i2c bus acquire / release, centralizing all of the logic into
iic_acquire_bus() / iic_release_bus().  "acquire" and "release" hooks
no longer need to be provided by back-end controller drivers (only if
they need special handling, e.g. powering on the i2c controller).
This results in the removal of a bunch of rendundant code from each
back-end controller driver.

Assert that we are not in hard interrupt context in iic_acquire_bus(),
iic_exec(), and iic_release_bus().
2019-12-22 23:23:29 +00:00
ad
6a0b48a361 NetBSD 9.99.29 - struct mount changed. 2019-12-22 22:24:37 +00:00
ad
e09f6b17de Avoid doing zero sized allocations if we get bad data. 2019-12-22 22:18:04 +00:00
jdolecek
6de223d1f9 don't treat the EDMA self disable as autoconfig error, it's perfectly
normal at least during boot when device connection is reported by controller
2019-12-22 20:59:42 +00:00
jdolecek
df29ad10a1 remove check for idle status when disabling EDMA, and always toggle
the disable regardless of current state - this particularly seems
to fail during error recovery, and on my system this also fails
during regular boot

this matches both FreeBSD and Linux drivers - neither of those checks
the idle status

should help with PR kern/52419 and maybe also the lock spinout part
of PR kern/52126
2019-12-22 20:54:00 +00:00
ad
7d06f3305f Make mntvnode_lock per-mount, and address false sharing of struct mount. 2019-12-22 19:47:34 +00:00
jmcneill
060b393c80 When resetting a drive, if the command list is running and CLO is not
supported, attempt to stop the drive first and fail gracefully if that
fails instead of triggering a KASSERT on DIAGNOSTIC kernels.
2019-12-22 19:19:43 +00:00
christos
007f692c78 PR/54730: Izumi Tsutsui: obsolete etc files are not being cleaned up on
an upgrade build.
2019-12-22 18:41:36 +00:00
ad
93aed9560e Have vmstat -H report on vcache_hashtab. 2019-12-22 17:27:53 +00:00
kamil
e6ecafaf7d Document udata type switch in struct kevent in the kqueue(2) 2019-12-22 17:01:15 +00:00
ad
626292fb42 Fix compile on !DIAGNOSTIC. 2019-12-22 16:50:03 +00:00
thorpej
7c6616d932 The hid-over-i2c spec specifies that compliant devices use level-sensitive
interrupts.  However, it's not safe to do i2c bus access in hard interrupt
context, and we must read the event data off the device in order to clear
the interrupt condition.

Address this by using acpi_intr_mask() to mask off the interrupt source
while a softint is pending to service the events, re-enabling it once
servicing is completed.

While here, re-factor the interrupt setup / tear-down code a bit to
eventually once day simplify supporting the FDT bindings for hid-over-i2c.
2019-12-22 16:44:35 +00:00
ad
be88751995 uvm_pagealloc_strat(): Tweak the locking to allow for lazy dequeue of pages
in the pdpolicy code.  This means taking pg->interlock if assigning to
an object.  The remaining barrier to lazy dequeue is having a dedicated
TAILQ_ENTRY in the page (it's currently shared with the page allocator).
2019-12-22 16:37:36 +00:00
thorpej
659765da91 Add acpi_intr_mask() and acpi_intr_unmask() which, following the pre-existing
ACPI software layering model, are wrappers around acpi_md_intr_mask() and
acpi_md_intr_unmask(), which in turn are wrappers around intr_mask() and
intr_unmask().

XXX ARM and IA64 implementations of acpi_md_intr_mask() and
acpi_md_intr_unmask() are just stubs for now.
2019-12-22 15:57:06 +00:00
ad
680f3a8667 pmap_get_ptp(): the uvm_pagefree() call in the failure case can block too.
Pacify the assertion in pmap_unmap_ptes().

XXX Revisit and solve this chicken-and-egg problem in a more elegant way.

Reported-by: syzbot+24967905b8d17344581c@syzkaller.appspotmail.com
2019-12-22 15:15:20 +00:00
thorpej
b1ae49d210 Add intr_mask() and corresponding intr_unmask() calls that allow specific
interrupt lines / sources to be masked as needed (rather than making a
set of sources by IPL as with spl*()).
2019-12-22 15:09:39 +00:00
ad
1e5952fd48 Fix integer overflow when printing available memory size (resulting from
a cast lost during merges).

Reported-by: syzbot+f02ca5f83ac7196b8afd@syzkaller.appspotmail.com
2019-12-22 15:00:42 +00:00
tkusumi
9c30b6c561 dm: Make numsec/secsize arguments in dm_table_disksize() optional 2019-12-22 13:16:09 +00:00