1# 2# Copyright (C) 2024 The Android Open-Source Project 3# 4# Licensed under the Apache License, Version 2.0 (the "License"); 5# you may not use this file except in compliance with the License. 6# You may obtain a copy of the License at 7# 8# http://www.apache.org/licenses/LICENSE-2.0 9# 10# Unless required by applicable law or agreed to in writing, software 11# distributed under the License is distributed on an "AS IS" BASIS, 12# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13# See the License for the specific language governing permissions and 14# limitations under the License. 15# 16 17# ETM hardware can't be enabled on user builds. So only ship ETM kernel modules on 18# USERDEBUG/ENG builds. 19 20ifneq (,$(filter userdebug eng, $(TARGET_BUILD_VARIANT))) 21 22ifeq ($(TARGET_LINUX_KERNEL_VERSION),5.15) 23 BOARD_VENDOR_KERNEL_MODULES += device/google/common/etm/5_15/coresight.ko \ 24 device/google/common/etm/5_15/coresight-etm4x.ko \ 25 device/google/common/etm/5_15/coresight-funnel.ko \ 26 device/google/common/etm/5_15/coresight-tmc.ko 27 28else ifeq ($(TARGET_LINUX_KERNEL_VERSION),6.1) 29 BOARD_VENDOR_KERNEL_MODULES += device/google/common/etm/6_1/coresight.ko \ 30 device/google/common/etm/6_1/coresight-etm4x.ko \ 31 device/google/common/etm/6_1/coresight-funnel.ko \ 32 device/google/common/etm/6_1/coresight-tmc.ko 33endif 34 35endif 36