mirror of
https://github.com/hardkernel/kernel_common_drivers.git
synced 2026-06-25 12:03:48 +09:00
2d120bb920
PD#SWPL-237927 Problem: kernel can't get boot log Solution: kernel get boot log that they are blx's log same as below CL https://scgit.amlogic.com/#/c/527327/ https://scgit.amlogic.com/#/c/568160/ https://scgit.amlogic.com/#/c/580089/ Verify: s7d_bm201 Change-Id: I786569565b2b5effde66d620e3b9b014ec6f8a2c Signed-off-by: benlong.zhou <benlong.zhou@amlogic.com>
136 lines
3.4 KiB
Python
136 lines
3.4 KiB
Python
load("//build/kernel/kleaf:kernel.bzl", "ddk_headers", "ddk_module")
|
|
load("//common_drivers:amlogic_utils.bzl", "m_k_files", "kernel_select")
|
|
|
|
m_k_files()
|
|
|
|
ddk_module(
|
|
name = "amlogic-debug-iotrace",
|
|
srcs = glob([
|
|
"**/*.h",
|
|
]),
|
|
conditional_srcs = {
|
|
"CONFIG_AMLOGIC_DEBUG_IOTRACE": {
|
|
True: [
|
|
"aml_iotrace.c",
|
|
"ftrace_ramoops.c",
|
|
],
|
|
},
|
|
"CONFIG_AMLOGIC_DEBUG_IOTM": {
|
|
True: [
|
|
"aml_iotm.c",
|
|
"iotm_v1.c",
|
|
"iotm_v2.c",
|
|
],
|
|
},
|
|
},
|
|
hdrs = [
|
|
],
|
|
local_defines = ["pr_fmt(fmt)=\"[debug-iotrace]: \" fmt"],
|
|
out = "amlogic-debug-iotrace.ko",
|
|
kernel_build = kernel_select(),
|
|
visibility = ["//visibility:public"],
|
|
deps = [
|
|
"//common_drivers/drivers/gki_tool:amlogic-gkitool",
|
|
]
|
|
)
|
|
|
|
ddk_module(
|
|
name = "amlogic-debug",
|
|
srcs = glob([
|
|
"**/*.h",
|
|
]),
|
|
conditional_srcs = {
|
|
"CONFIG_AMLOGIC_DEBUG": {
|
|
True: [
|
|
"main.c",
|
|
"lockup.c",
|
|
"sched.c",
|
|
"kprobes.c",
|
|
],
|
|
},
|
|
"CONFIG_AMLOGIC_UBOOT_LOG": {
|
|
True: [
|
|
"uboot_log.c",
|
|
"ring_buffer.c",
|
|
],
|
|
},
|
|
"CONFIG_AMLOGIC_DEBUG_ISOLCPUS": {
|
|
True: ["isolcpus.c"],
|
|
},
|
|
"CONFIG_AMLOGIC_DEBUG_MHZ": {
|
|
True: ["cpu_mhz.c"],
|
|
},
|
|
"CONFIG_AMLOGIC_DEBUG_ATRACE": {
|
|
True: [
|
|
"atrace.c",
|
|
"atrace_mem.c",
|
|
],
|
|
},
|
|
"CONFIG_AMLOGIC_DEBUG_FILE": {
|
|
True: ["debug_file.c"],
|
|
},
|
|
"CONFIG_AMLOGIC_GKI_CONFIG": {
|
|
True: ["gki_config.c"],
|
|
},
|
|
"CONFIG_AMLOGIC_DEBUG_HLD": {
|
|
True: ["watchdog_hld.c"],
|
|
},
|
|
"CONFIG_ARM64_MTE": {
|
|
True: ["debug_mte.c"],
|
|
},
|
|
"CONFIG_AMLOGIC_DEBUG_PRINTK": {
|
|
True: ["printk.c"],
|
|
},
|
|
},
|
|
hdrs = [
|
|
"//common_drivers:arch/arm64/configs/amlogic_gki.fragment",
|
|
"//common:mm/cma.h",
|
|
"//common:kernel/sched/sched.h",
|
|
"//common:kernel/sched/cpupri.h",
|
|
"//common:kernel/sched/cpudeadline.h",
|
|
"//common:kernel/sched/ext.h",
|
|
"//common:kernel/sched/stats.h",
|
|
"//common:kernel/sched/features.h",
|
|
"//common:kernel/workqueue_internal.h",
|
|
],
|
|
linux_includes = [
|
|
"../../../common/mm",
|
|
"../../../common/kernel/sched",
|
|
],
|
|
local_defines = [
|
|
"pr_fmt(fmt)=\"[debug]: \" fmt",
|
|
"GKI_CONFIG=\"../../arch/arm64/configs/amlogic_gki.fragment\"",
|
|
],
|
|
out = "amlogic-debug.ko",
|
|
kernel_build = kernel_select(),
|
|
visibility = ["//visibility:public"],
|
|
deps = [
|
|
"//common_drivers/drivers/gki_tool:amlogic-gkitool",
|
|
"//common_drivers/drivers/debug:amlogic-debug-iotrace",
|
|
],
|
|
)
|
|
|
|
ddk_module(
|
|
name = "amlogic-audio-utils",
|
|
srcs = glob([
|
|
"**/*.h",
|
|
]),
|
|
conditional_srcs = {
|
|
"CONFIG_AMLOGIC_AUDIO_UTILS": {
|
|
True: [
|
|
"audio_utils.c",
|
|
],
|
|
},
|
|
},
|
|
hdrs = [
|
|
],
|
|
local_defines = [
|
|
"pr_fmt(fmt)=\"[audio-utils]: \" fmt",
|
|
],
|
|
out = "amlogic-audio-utils.ko",
|
|
kernel_build = kernel_select(),
|
|
visibility = ["//visibility:public"],
|
|
deps = [
|
|
],
|
|
)
|