Files
linux-nv-oot/drivers/media/Makefile
Jon Hunter 79e8e9cf3a media: Allow drivers to be built without V4L2
When building the NVIDIA out-of-tree drivers against 3rd party Linux
kernels where V4L2 support is not be enabled by default, the camera
drivers fail to build. Although this is expected, it is preferred that
the driver can still be built but then fail when loaded. Update the
camera drivers to guard around the V4L2 functions so that the drivers
can still be built but will return an error where needed.

Bug 4119327

Change-Id: I3a1115e5f0451153831c396244c01d7525cb51a1
Signed-off-by: Jon Hunter <jonathanh@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/2979254
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
2023-09-14 13:32:09 -07:00

19 lines
386 B
Makefile

# SPDX-License-Identifier: GPL-2.0
# Copyright (c) 2022-2023, NVIDIA CORPORATION & AFFILIATES. All rights reserved.
ifdef CONFIG_V4L2_ASYNC
subdir-ccflags-y += -DCONFIG_V4L2_ASYNC
endif
ifdef CONFIG_V4L2_FWNODE
subdir-ccflags-y += -DCONFIG_V4L2_FWNODE
endif
ifdef CONFIG_VIDEOBUF2_DMA_CONTIG
subdir-ccflags-y += -DCONFIG_VIDEOBUF2_DMA_CONTIG
endif
obj-m += i2c/
obj-m += platform/