mirror of
https://github.com/NVIDIA/open-gpu-kernel-modules.git
synced 2026-05-13 09:16:17 +00:00
595.58.03
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* SPDX-FileCopyrightText: Copyright (c) 2001-2025 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
|
||||
* SPDX-FileCopyrightText: Copyright (c) 2001-2026 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
@@ -1351,7 +1351,6 @@ typedef struct nv_linux_state_s {
|
||||
struct reset_control *nvdisplay_reset;
|
||||
struct reset_control *dsi_core_reset;
|
||||
struct reset_control *mipi_cal_reset;
|
||||
struct reset_control *hdacodec_reset;
|
||||
|
||||
/*
|
||||
* nv_imp_icc_path represents the interconnect path across which display
|
||||
|
||||
@@ -216,6 +216,16 @@ static inline void nv_vma_flags_clear_word(struct vm_area_struct *vma, unsigned
|
||||
ACCESS_PRIVATE(vma, __vm_flags) &= ~flags;
|
||||
#endif
|
||||
}
|
||||
|
||||
static inline int nv_is_vma_write_locked(struct vm_area_struct *vma, unsigned int *mm_lock_seq)
|
||||
{
|
||||
#if defined(NV_IS_VMA_WRITE_LOCKED_HAS_MM_LOCK_SEQ_ARG)
|
||||
return __is_vma_write_locked(vma, mm_lock_seq);
|
||||
#else
|
||||
*mm_lock_seq = __vma_raw_mm_seqnum(vma);
|
||||
return __is_vma_write_locked(vma);
|
||||
#endif
|
||||
}
|
||||
#endif // !NV_CAN_CALL_VMA_START_WRITE
|
||||
|
||||
static inline void nv_vm_flags_set(struct vm_area_struct *vma, vm_flags_t flags)
|
||||
|
||||
@@ -604,7 +604,17 @@ struct NvKmsKapiGpuInfo {
|
||||
MIGDeviceId migDevice;
|
||||
};
|
||||
|
||||
/*
|
||||
* Linux kernel options CONFIG_RANDSTRUCT_* randomize structs that are composed
|
||||
* entirely of function pointers, but can only control struct layout for sources
|
||||
* built by kbuild. NvKmsKapiCallbacks is shared between kbuild-built
|
||||
* nvidia-drm.ko, and the "OS-agnostic" portions of nvidia-modeset.ko (not built
|
||||
* by kbuild). Add a _padding member to disable struct randomization.
|
||||
*
|
||||
* Refer to https://github.com/NVIDIA/open-gpu-kernel-modules/issues/1033
|
||||
*/
|
||||
struct NvKmsKapiCallbacks {
|
||||
int _padding;
|
||||
void (*suspendResume)(NvBool suspend);
|
||||
void (*remove)(NvU32 gpuId);
|
||||
void (*probe)(const struct NvKmsKapiGpuInfo *gpu_info);
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* SPDX-FileCopyrightText: Copyright (c) 1993-2025 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
|
||||
* SPDX-FileCopyrightText: Copyright (c) 1993-2026 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
@@ -514,6 +514,16 @@ typedef struct
|
||||
#define NV_DECLARE_ALIGNED(TYPE_VAR, ALIGN) __declspec(align(ALIGN)) TYPE_VAR
|
||||
#elif defined(__arm)
|
||||
#define NV_DECLARE_ALIGNED(TYPE_VAR, ALIGN) __align(ALIGN) TYPE_VAR
|
||||
#endif
|
||||
|
||||
#if defined(__STDC_VERSION__) && (__STDC_VERSION__ >= 201112L)
|
||||
#define NV_ALIGNOF(type) _Alignof(type)
|
||||
#elif defined(__cplusplus) && (__cplusplus >= 201103L)
|
||||
#define NV_ALIGNOF(type) alignof(type)
|
||||
#elif defined(__GNUC__) || defined(__clang__)
|
||||
#define NV_ALIGNOF(type) __alignof__(type)
|
||||
#elif defined(_MSC_VER)
|
||||
#define NV_ALIGNOF(type) __alignof(type)
|
||||
#endif
|
||||
|
||||
/***************************************************************************\
|
||||
|
||||
Reference in New Issue
Block a user