DESCRIPTION = "Kernel module for contiguous memory allocation from userspace"

include cmem.inc

# This package builds a kernel module, use kernel PR as base and append a local
MACHINE_KERNEL_PR:append = "a"
PR = "${MACHINE_KERNEL_PR}"

inherit module

EXTRA_OEMAKE += '-f lu.mak KERNEL_INSTALL_DIR="${STAGING_KERNEL_DIR}" TOOLCHAIN_PREFIX="${TOOLCHAIN_PREFIX}" EXEC_DIR="${D}/lib/modules/${KERNEL_VERSION}/extra"'
MAKE_TARGETS = "module"

KERNEL_MODULE_AUTOLOAD += "cmemk"

do_install:prepend() {
    cp ${B}/src/cmem/module/Module.symvers ${B}/ || true
}

DESCRIPTION = "Kernel module for contiguous memory allocation from userspace"

include cmem.inc

# This package builds a kernel module, use kernel PR as base and append a local
MACHINE_KERNEL_PR:append = "a"
PR = "${MACHINE_KERNEL_PR}"

inherit module

EXTRA_OEMAKE += '-f lu.mak KERNEL_INSTALL_DIR="${STAGING_KERNEL_DIR}" TOOLCHAIN_PREFIX="${TOOLCHAIN_PREFIX}" EXEC_DIR="${D}${nonarch_base_libdir}/modules/${KERNEL_VERSION}/extra"'
MAKE_TARGETS = "module"

KERNEL_MODULE_AUTOLOAD += "cmemk"

do_install:prepend() {
    cp ${B}/src/cmem/module/Module.symvers ${B}/ || true
}

Fix kernel module packaging for usrmerge
cmem-mod: Fix kernel module packaging for usrmerge

ERROR: cmem-mod-4.20.00.01+gitAUTOINC+86269258a4-0a do_package: QA Issue: cmem-mod: Files/directories were installed but not shipped in any package:
  /lib/modules/5.10.100-g4a12bec7d3/extra/cmemk.ko

Signed-off-by: Khem Raj <729d64b6f67515e258459a5f6d20ec88b2caf8df@gmail.com>
Signed-off-by: Ryan Eatmon <c832a3efa8dfb59911a35349a6eeba0397feadf1@ti.com>
