mirror of
git://nv-tegra.nvidia.com/linux-nv-oot.git
synced 2025-12-22 09:11:26 +03:00
video: tegra: nvmap: Define nth_page
In Linux v6.18, commit 84efbefa26df ("mm: remove nth_page()") removes
the nth_page macro and this breaks the build for NVMAP. Define the
nth_page macro if it is not defined in the kernel to fix the build.
Bug 5566555
Bug 5215421
Change-Id: Iaa6bcd2204e4c1ab59516bb7353a71f3ec6e19c4
Signed-off-by: Jon Hunter <jonathanh@nvidia.com>
Signed-off-by: Ketan Patil <ketanp@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3449760
(cherry picked from commit c0db792d335d8525821d3aac16e64506e84bf4c2)
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3475136
GVS: buildbot_gerritrpt <buildbot_gerritrpt@nvidia.com>
Reviewed-by: Brad Griffis <bgriffis@nvidia.com>
This commit is contained in:
committed by
mobile promotions
parent
d7466525c8
commit
a530fa20f8
@@ -22,6 +22,14 @@
|
|||||||
#define NVMAP_IVM_ALIGNMENT (SZ_32K)
|
#define NVMAP_IVM_ALIGNMENT (SZ_32K)
|
||||||
#define NVMAP_IVM_INVALID_PEER (-1)
|
#define NVMAP_IVM_INVALID_PEER (-1)
|
||||||
|
|
||||||
|
#ifndef nth_page
|
||||||
|
#if defined(CONFIG_SPARSEMEM) && !defined(CONFIG_SPARSEMEM_VMEMMAP)
|
||||||
|
#define nth_page(page, n) pfn_to_page(page_to_pfn((page)) + (n))
|
||||||
|
#else
|
||||||
|
#define nth_page(page, n) ((page) + (n))
|
||||||
|
#endif /* CONFIG_SPARSEMEM && !CONFIG_SPARSEMEM_VMEMMAP */
|
||||||
|
#endif /* nth_page */
|
||||||
|
|
||||||
struct nvmap_heap;
|
struct nvmap_heap;
|
||||||
struct debugfs_info;
|
struct debugfs_info;
|
||||||
struct nvmap_carveout_node;
|
struct nvmap_carveout_node;
|
||||||
|
|||||||
Reference in New Issue
Block a user