mirror of
https://github.com/opnsense/src.git
synced 2026-05-28 04:12:45 -04:00
Implement linux firmware KPI compat code.
This includes: request_firmware() request_firmware_nowait(),
request_firmware_direct(), firmware_request_nowarn(),
and release_firmware().
Given we will try to map requested names from natively ported
or full-linuxkpi-using drivers to a firmware(9) auto-loading
name format (.ko file name and image name matching),
we quieten firmware(9) and print success or failure (unless
the _nowarn() version was called) in the linuxkpi implementation.
At the moment we try up-to 4 different naming combinations,
with path stripped, original name, and requested name with '/'
or '.' replaced.
We do not currently defer loading in the "nowait" case.
Sponsored-by: The FreeBSD Foundation
Sponsored-by: Rubicon Communications, LLC ("Netgate")
(firmware(9) nowarn update from D27413)
MFC after: 3 days
Reviewed by: kib, manu (looked at older versions)
Differential Revision: https://reviews.freebsd.org/D27414
(cherry picked from commit a6c2507d1b)
(cherry picked from commit 4a26380ba6)
38 lines
783 B
Makefile
38 lines
783 B
Makefile
# $FreeBSD$
|
|
.PATH: ${SRCTOP}/sys/compat/linuxkpi/common/src
|
|
|
|
KMOD= linuxkpi
|
|
SRCS= linux_compat.c \
|
|
linux_current.c \
|
|
linux_dmi.c \
|
|
linux_firmware.c \
|
|
linux_hrtimer.c \
|
|
linux_idr.c \
|
|
linux_kmod.c \
|
|
linux_kthread.c \
|
|
linux_lock.c \
|
|
linux_page.c \
|
|
linux_pci.c \
|
|
linux_radix.c \
|
|
linux_rcu.c \
|
|
linux_seq_file.c \
|
|
linux_schedule.c \
|
|
linux_shmemfs.c \
|
|
linux_shrinker.c \
|
|
linux_slab.c \
|
|
linux_tasklet.c \
|
|
linux_usb.c \
|
|
linux_work.c \
|
|
linux_xarray.c
|
|
|
|
.if ${MACHINE_CPUARCH} == "aarch64" || ${MACHINE_CPUARCH} == "amd64" || \
|
|
${MACHINE_CPUARCH} == "i386"
|
|
SRCS+= opt_acpi.h acpi_if.h linux_acpi.c linux_fpu.c
|
|
.endif
|
|
|
|
SRCS+= ${LINUXKPI_GENSRCS}
|
|
|
|
CFLAGS+= -I${SRCTOP}/sys/compat/linuxkpi/common/include
|
|
CFLAGS+= -I${SRCTOP}/sys/contrib/ck/include
|
|
|
|
.include <bsd.kmod.mk>
|