drivers: Fix build for Linux v6.12

In Linux v6.12 the definition 'no_llseek' was finally removed. Since
Linux v6.0 it had been redefined as NULL. Add a test to conftest to
determine if 'no_llseek' is present and if not then it is no longer
necessary to populate this and we can leave as NULL.

Bug 4876974

Change-Id: I051fdb285b32260b5913dad89cabe0be04253f67
Signed-off-by: Jon Hunter <jonathanh@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3222106
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
This commit is contained in:
Jon Hunter
2024-10-01 15:20:08 +01:00
parent cc49f73763
commit 5a54d4161a
11 changed files with 53 additions and 13 deletions

View File

@@ -1,5 +1,5 @@
// SPDX-License-Identifier: GPL-2.0
// Copyright (c) 2022-2023, NVIDIA CORPORATION & AFFILIATES. All rights reserved.
// SPDX-License-Identifier: GPL-2.0-only
// SPDX-FileCopyrightText: Copyright (c) 2022-2024 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
#include <nvidia/conftest.h>
@@ -226,7 +226,9 @@ static const struct file_operations tegra_camchar_fops = {
.release = tegra_camchar_release,
.unlocked_ioctl = tegra_camchar_ioctl,
.compat_ioctl = tegra_camchar_ioctl,
#if defined(NV_NO_LLSEEK_PRESENT)
.llseek = no_llseek,
#endif
};
static int __init tegra_camchar_init(struct tegra_ivc_driver *drv)