aboutsummaryrefslogtreecommitdiff
path: root/sys/dev/hyperv/input
Commit message (Collapse)AuthorAgeFilesLines
* chore: replace {0, 0} with {DEV,KOBJ}METHOD_ENDEnji Cooper2026-02-251-1/+1
| | | | | | | | | | | | | | Both of the aforementioned macros have been present in FreeBSD for well over a decade: 2009 for `KOBJMETHOD_END`; 2011 for `DEVMETHOD_END`. Adapt all hardcoded references of `{0, 0}` with `DEVMETHOD_END` and `KOBJMETHOD_END` as appropriate. This helps ensure that future adaptations to drivers following patterns documented in driver(9) can be made more easily/without issue. MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D55414
* newbus: replace leftover device unit wildcardsAhmad Khalifa2025-06-211-1/+1
| | | | | | Reviewed by: imp, jhb Approved by: imp (mentor) Differential Revision: https://reviews.freebsd.org/D50913
* Use bus_generic_detach instead of device_delete_children in detachJohn Baldwin2025-01-021-1/+1
| | | | | | | While here, check for errors from bus_generic_detach and move it to the start of detach if necessary. Differential Revision: https://reviews.freebsd.org/D47969
* Replace calls to bus_generic_attach with bus_attach_childrenJohn Baldwin2024-12-061-3/+1
| | | | | Reviewed by: imp Differential Revision: https://reviews.freebsd.org/D47675
* sys: Automated cleanup of cdefs and other formattingWarner Losh2023-11-271-1/+0
| | | | | | | | | | | | | | | | Apply the following automated changes to try to eliminate no-longer-needed sys/cdefs.h includes as well as now-empty blank lines in a row. Remove /^#if.*\n#endif.*\n#include\s+<sys/cdefs.h>.*\n/ Remove /\n+#include\s+<sys/cdefs.h>.*\n+#if.*\n#endif.*\n+/ Remove /\n+#if.*\n#endif.*\n+/ Remove /^#if.*\n#endif.*\n/ Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/types.h>/ Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/param.h>/ Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/capsicum.h>/ Sponsored by: Netflix
* sys: Remove $FreeBSD$: one-line .c patternWarner Losh2023-08-162-4/+0
| | | | Remove /^[\s*]*__FBSDID\("\$FreeBSD\$"\);?\s*\n/
* sys: Remove $FreeBSD$: two-line .h patternWarner Losh2023-08-161-2/+0
| | | | Remove /^\s*\*\n \*\s+\$FreeBSD\$$\n/
* hid: Add child device parameter to HID methodsVladimir Kondratyev2023-08-031-6/+7
| | | | | | | | | Some devices like Apple HID-over-SPI may contain more than one report descriptors necessitating creation of multiple hidbus children. Add indentificator of child devices to distinct them. No functional changes intended. Differential Revision: https://reviews.freebsd.org/D41246
* sys/kbio.h: make pre-unicode keymap support optionalStefan Eßer2023-02-141-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | FreeBSD-9 had introduced support for the full set of Unicode characters to the parsing and processing of keymap character tables. This support has been extended to cover the table for accented characters that are reached via dead key combinations in FreeBSD-13.2. New ioctls have been introduced to support both the pre-Unicode and the Unicode formats and keyboard drivers have been extended to support those ioctls. This commit makes the ABI compatibility functions in the kernel optional and dependent on COMPAT_FREEBSD13 in -CURRENT. The kbdcontrol command in -CURRENT and 13-STABLE (before 13.2) has been made ABI compatible with old kernels to allow a new world to be run on an old kernel (that does not have full Unicode support for keymaps). This commit is not to merged back to 12-STABLE or 13-STABLE. It is part of review D38465, which has been split into 3 separate commits due to different MFC and life-time requirements of either commit. Approved by: imp Differential Revision: https://reviews.freebsd.org/D38465
* Support Unicode characters in keymap dead key tablesStefan Eßer2023-02-061-0/+1
| | | | | | | | | | | | | | | | | | | Support for Unicode characters had been added to the keyboard code, but there are keymaps that have accented characters accessed via dead key combinations, and those were still restricted to 8 bit codes. This update to kbd.c adds support for Unicode characters and compatibility code that allows a kbdcontrol command built from kbio.h without these patches to work on a new kernel. Compatibility code that allows a new kbdcontrol binary running on an old kernel to load and display the dead key map will be committed in a separate commit. Reviewed by: imp, brooks Approved by: brooks MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D38381
* hv_hid: Hyper-V HID driverYuri2023-02-051-0/+564
| | | | | | | | | Hyper-V HID driver using hidbus/hms. Reviewed by: wulf MFC after: 1 week PR: 221074 Differential revision: https://reviews.freebsd.org/D38140
* evdev: Extend EVIOCGRAB ioctl scope to cover kbd interfaceVladimir Kondratyev2022-11-181-0/+2
| | | | | | | | | | | | | | of various keyboard drivers. EVIOCGRAB ioctl execution on /dev/input/event# device node gains exclusive access to this device to caller. It is used mostly for development purposes and remote control software. See e.g. https://reviews.freebsd.org/D30020 which is the reason of creation of this change. Keyboard grabbing is disabled in KDB and during panics. MFC with: 4a0db5e2920c Tested by: corvink Differential revision: https://reviews.freebsd.org/D30542
* hyperv: Remove unused devclass arguments to DRIVER_MODULE.John Baldwin2022-05-061-3/+1
|
* hv_kbd: Fix build with EVDEV_SUPPORT kernel option disabled.Vladimir Kondratyev2021-04-221-2/+1
| | | | | Reported by: olivier MFC with: e4643aa4c4ff
* hv_kbd: Fix leaked $FreeBSD$ expansionVladimir Kondratyev2021-04-111-1/+1
| | | | MFC with: c2a159286c76
* hv_kbd: Add support for K_XLATE and K_CODE modes for gen 2 VMsVladimir Kondratyev2021-04-112-55/+272
| | | | | | | | That fixes disabled keyboard input after Xorg server has been stopped. Reviewed by: whu MFC after: 1 month Differential revision: https://reviews.freebsd.org/D28171
* hv_kbd: Add evdev protocol support for gen 2 VMsVladimir Kondratyev2021-04-112-1/+94
| | | | | | Reviewed by: whu MFC after: 1 month Differential revision: https://reviews.freebsd.org/D28170
* Revert r355806: kbd drivers: don't double register keyboard driversKyle Evans2019-12-261-3/+0
| | | | | | | | | | | r356087 made it rather innocuous to double-register built-in keyboard drivers; we now set a flag to indicate that it's been registered and only act once on a registration anyways. There is no misleading here, as the follow-up kbd_delete_driver will actually remove the driver as needed now that the linker set isn't also consulted after kbdinit. Notes: svn path=/head/; revision=356091
* kbd drivers: don't double register keyboard driversKyle Evans2019-12-161-0/+3
| | | | | | | | | | | | | | | | | | Keyboard drivers are generally registered via linker set. In these cases, they're also available as kmods which use KPI for registering/unregistering keyboard drivers outside of the linker set. For built-in modules, we still fire off MOD_LOAD and maybe even MOD_UNLOAD if an error occurs, leading to registration via linker set and at MOD_LOAD time. This is a minor optimization at best, but it keeps the internal kbd driver tidy as a future change will merge the linker set driver list into its internal keyboard_drivers list via SYSINIT and simplify driver lookup by removing the need to consult the linker set. Notes: svn path=/head/; revision=355806
* kbd: provide default implementations of get_fkeystr/diagKyle Evans2019-12-161-2/+0
| | | | | | | | | Most keyboard drivers are using the genkbd implementations as it is; formally use them for any that aren't set and make genkbd_get_fkeystr/genkbd_diag private. Notes: svn path=/head/; revision=355796
* keyboard switch definitions: standardize on c99 initializersKyle Evans2019-12-161-19/+19
| | | | | | | | | A future change will provide default implementations for some of these where it makes sense and most of them are already using the genkbd implementation (e.g. get_fkeystr, diag). Notes: svn path=/head/; revision=355794
* kbd drivers: use kbdd_* indirection for diag invocationKyle Evans2019-12-161-1/+1
| | | | | | | | | | | These invocations were directly calling enkbd_diag(), rather than indirection back through kbdd_diag/kbdsw. While they're functionally equivent, invoking kbdd_diag where feasible (i.e. not in a diag implementation) makes it easier to visually identify locking needs in these other drivers. Notes: svn path=/head/; revision=355793
* hyperv/input: Remove unnecessary inclusion.Sepherosa Ziehau2017-06-301-1/+0
| | | | | | | | | | | | The unbreaks gcc compilation. Submitted by: Ryan Libby MFC after: 1 week Sponsored by: Microsoft Differential Revision: https://reviews.freebsd.org/D11415 Notes: svn path=/head/; revision=320490
* hyperv/kbd: Channel read expects non-NULL channel argument.Sepherosa Ziehau2017-05-051-1/+1
| | | | | | | | MFC after: now Sponsored by: Microsoft Notes: svn path=/head/; revision=317821
* hyperv/kbd: Remove unnecessary assignment.Sepherosa Ziehau2017-04-141-1/+0
| | | | | | | | | Reported by: PVS MFC after: 3 days Sponsored by: Microsoft Notes: svn path=/head/; revision=316812
* hyperv/kbd: Add support for synthetic keyboard.Sepherosa Ziehau2017-04-053-0/+1200
Synthetic keyboard is the only supported keyboard on GEN2 Hyper-V. Submitted by: Hongjiang Zhang <honzhan microsoft com> MFC after: 1 week Sponsored by: Microsoft Differential Revision: https://reviews.freebsd.org/D10196 Notes: svn path=/head/; revision=316515