Files
linux-nv-oot/drivers/net/wireless/realtek/Makefile
Jon Hunter f00b8b2cd4 net: rtl8852ce: Add option to skip driver build
The RealTek drivers do not build against all Linux distributions because
some Linux distributions have back-ported upstream changes and so the
KERNEL_VERSION checks in the driver do not work for these distributions.

Add a compilation flag for the rtl8852ce driver so that we can skip
building of this driver for certain Linux distributions.

Bug 4667769

Change-Id: Ie4ec2308b458e4d5e6a3fa29d5e247c5a709172d
Signed-off-by: Jon Hunter <jonathanh@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3231107
Reviewed-by: svcacv <svcacv@nvidia.com>
Reviewed-by: Brad Griffis <bgriffis@nvidia.com>
GVS: buildbot_gerritrpt <buildbot_gerritrpt@nvidia.com>
2024-10-18 06:23:56 -07:00

19 lines
596 B
Makefile

# SPDX-License-Identifier: GPL-2.0-only
# SPDX-FileCopyrightText: Copyright (c) 2022-2024 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
LINUX_VERSION := $(shell expr $(VERSION) \* 256 + $(PATCHLEVEL))
LINUX_VERSION_6_6 := $(shell expr 6 \* 256 + 6)
ifeq ($(findstring ack_src,$(NV_BUILD_KERNEL_OPTIONS)),)
ifeq ($(VERSION).$(PATCHLEVEL),5.15)
ifneq ($(NV_OOT_REALTEK_RTL8822CE_SKIP_BUILD),y)
obj-m += rtl8822ce/
endif
endif
ifneq ($(NV_OOT_REALTEK_RTL8852CE_SKIP_BUILD),y)
ifeq ($(shell test $(LINUX_VERSION) -lt $(LINUX_VERSION_6_6); echo $$?),0)
obj-m += rtl8852ce/
endif
endif
endif