mirror of
git://nv-tegra.nvidia.com/tegra/kernel-src/nv-kernel-display-driver.git
synced 2025-12-22 09:11:48 +03:00
Compare commits
2 Commits
rel-36_eng
...
rel-36_eng
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
7296f7cc89 | ||
|
|
6475e2b9c3 |
@@ -1,7 +1,7 @@
|
|||||||
# NVIDIA Linux Open GPU Kernel Module Source
|
# NVIDIA Linux Open GPU Kernel Module Source
|
||||||
|
|
||||||
This is the source release of the NVIDIA Linux open GPU kernel modules,
|
This is the source release of the NVIDIA Linux open GPU kernel modules,
|
||||||
version 540.3.0.
|
version 540.4.0.
|
||||||
|
|
||||||
|
|
||||||
## How to Build
|
## How to Build
|
||||||
@@ -17,7 +17,7 @@ as root:
|
|||||||
|
|
||||||
Note that the kernel modules built here must be used with GSP
|
Note that the kernel modules built here must be used with GSP
|
||||||
firmware and user-space NVIDIA GPU driver components from a corresponding
|
firmware and user-space NVIDIA GPU driver components from a corresponding
|
||||||
540.3.0 driver release. This can be achieved by installing
|
540.4.0 driver release. This can be achieved by installing
|
||||||
the NVIDIA GPU driver from the .run file using the `--no-kernel-modules`
|
the NVIDIA GPU driver from the .run file using the `--no-kernel-modules`
|
||||||
option. E.g.,
|
option. E.g.,
|
||||||
|
|
||||||
@@ -180,7 +180,7 @@ software applications.
|
|||||||
## Compatible GPUs
|
## Compatible GPUs
|
||||||
|
|
||||||
The open-gpu-kernel-modules can be used on any Turing or later GPU
|
The open-gpu-kernel-modules can be used on any Turing or later GPU
|
||||||
(see the table below). However, in the 540.3.0 release,
|
(see the table below). However, in the 540.4.0 release,
|
||||||
GeForce and Workstation support is still considered alpha-quality.
|
GeForce and Workstation support is still considered alpha-quality.
|
||||||
|
|
||||||
To enable use of the open kernel modules on GeForce and Workstation GPUs,
|
To enable use of the open kernel modules on GeForce and Workstation GPUs,
|
||||||
@@ -188,7 +188,7 @@ set the "NVreg_OpenRmEnableUnsupportedGpus" nvidia.ko kernel module
|
|||||||
parameter to 1. For more details, see the NVIDIA GPU driver end user
|
parameter to 1. For more details, see the NVIDIA GPU driver end user
|
||||||
README here:
|
README here:
|
||||||
|
|
||||||
https://us.download.nvidia.com/XFree86/Linux-x86_64/540.3.0/README/kernel_open.html
|
https://us.download.nvidia.com/XFree86/Linux-x86_64/540.4.0/README/kernel_open.html
|
||||||
|
|
||||||
In the below table, if three IDs are listed, the first is the PCI Device
|
In the below table, if three IDs are listed, the first is the PCI Device
|
||||||
ID, the second is the PCI Subsystem Vendor ID, and the third is the PCI
|
ID, the second is the PCI Subsystem Vendor ID, and the third is the PCI
|
||||||
|
|||||||
2436
commitFile.txt
2436
commitFile.txt
File diff suppressed because it is too large
Load Diff
@@ -72,7 +72,7 @@ EXTRA_CFLAGS += -I$(src)/common/inc
|
|||||||
EXTRA_CFLAGS += -I$(src)
|
EXTRA_CFLAGS += -I$(src)
|
||||||
EXTRA_CFLAGS += -Wall $(DEFINES) $(INCLUDES) -Wno-cast-qual -Wno-error -Wno-format-extra-args
|
EXTRA_CFLAGS += -Wall $(DEFINES) $(INCLUDES) -Wno-cast-qual -Wno-error -Wno-format-extra-args
|
||||||
EXTRA_CFLAGS += -D__KERNEL__ -DMODULE -DNVRM
|
EXTRA_CFLAGS += -D__KERNEL__ -DMODULE -DNVRM
|
||||||
EXTRA_CFLAGS += -DNV_VERSION_STRING=\"540.3.0\"
|
EXTRA_CFLAGS += -DNV_VERSION_STRING=\"540.4.0\"
|
||||||
|
|
||||||
ifneq ($(SYSSRCHOST1X),)
|
ifneq ($(SYSSRCHOST1X),)
|
||||||
EXTRA_CFLAGS += -I$(SYSSRCHOST1X)
|
EXTRA_CFLAGS += -I$(SYSSRCHOST1X)
|
||||||
|
|||||||
@@ -5106,20 +5106,22 @@ compile_test() {
|
|||||||
compile_check_conftest "$CODE" "NV_PCI_CLASS_MULTIMEDIA_HD_AUDIO_PRESENT" "" "generic"
|
compile_check_conftest "$CODE" "NV_PCI_CLASS_MULTIMEDIA_HD_AUDIO_PRESENT" "" "generic"
|
||||||
;;
|
;;
|
||||||
|
|
||||||
unsafe_follow_pfn)
|
follow_pfn)
|
||||||
#
|
#
|
||||||
# Determine if unsafe_follow_pfn() is present.
|
# Determine if follow_pfn() is present.
|
||||||
#
|
#
|
||||||
# unsafe_follow_pfn() was added by commit 69bacee7f9ad
|
# follow_pfn() was added by commit 3b6748e2dd69
|
||||||
# ("mm: Add unsafe_follow_pfn") in v5.13-rc1.
|
# ("mm: introduce follow_pfn()") in v2.6.31-rc1, and removed
|
||||||
|
# by commit 233eb0bf3b94 ("mm: remove follow_pfn")
|
||||||
|
# from linux-next 233eb0bf3b94.
|
||||||
#
|
#
|
||||||
CODE="
|
CODE="
|
||||||
#include <linux/mm.h>
|
#include <linux/mm.h>
|
||||||
void conftest_unsafe_follow_pfn(void) {
|
void conftest_follow_pfn(void) {
|
||||||
unsafe_follow_pfn();
|
follow_pfn();
|
||||||
}"
|
}"
|
||||||
|
|
||||||
compile_check_conftest "$CODE" "NV_UNSAFE_FOLLOW_PFN_PRESENT" "" "functions"
|
compile_check_conftest "$CODE" "NV_FOLLOW_PFN_PRESENT" "" "functions"
|
||||||
;;
|
;;
|
||||||
|
|
||||||
drm_plane_atomic_check_has_atomic_state_arg)
|
drm_plane_atomic_check_has_atomic_state_arg)
|
||||||
@@ -6459,6 +6461,21 @@ compile_test() {
|
|||||||
compile_check_conftest "$CODE" "NV_DRM_APERTURE_REMOVE_CONFLICTING_PCI_FRAMEBUFFERS_HAS_DRIVER_ARG" "" "types"
|
compile_check_conftest "$CODE" "NV_DRM_APERTURE_REMOVE_CONFLICTING_PCI_FRAMEBUFFERS_HAS_DRIVER_ARG" "" "types"
|
||||||
;;
|
;;
|
||||||
|
|
||||||
|
crypto_tfm_ctx_aligned)
|
||||||
|
# Determine if 'crypto_tfm_ctx_aligned' is defined.
|
||||||
|
#
|
||||||
|
# Removed by commit 25c74a39e0f6 ("crypto: hmac - remove unnecessary
|
||||||
|
# alignment logic") in v6.7.
|
||||||
|
#
|
||||||
|
CODE="
|
||||||
|
#include <crypto/algapi.h>
|
||||||
|
void conftest_crypto_tfm_ctx_aligned(void) {
|
||||||
|
(void)crypto_tfm_ctx_aligned();
|
||||||
|
}"
|
||||||
|
|
||||||
|
compile_check_conftest "$CODE" "NV_CRYPTO_TFM_CTX_ALIGNED_PRESENT" "" "functions"
|
||||||
|
;;
|
||||||
|
|
||||||
crypto)
|
crypto)
|
||||||
#
|
#
|
||||||
# Determine if we support various crypto functions.
|
# Determine if we support various crypto functions.
|
||||||
|
|||||||
@@ -23,6 +23,10 @@
|
|||||||
|
|
||||||
#include "internal_crypt_lib.h"
|
#include "internal_crypt_lib.h"
|
||||||
|
|
||||||
|
#ifndef NV_CRYPTO_TFM_CTX_ALIGNED_PRESENT
|
||||||
|
#include <crypto/internal/hash.h>
|
||||||
|
#endif
|
||||||
|
|
||||||
void *lkca_hash_new(const char* alg_name)
|
void *lkca_hash_new(const char* alg_name)
|
||||||
{
|
{
|
||||||
#ifndef USE_LKCA
|
#ifndef USE_LKCA
|
||||||
@@ -87,9 +91,24 @@ bool lkca_hmac_duplicate(struct shash_desc *dst, struct shash_desc const *src)
|
|||||||
|
|
||||||
struct crypto_shash *src_tfm = src->tfm;
|
struct crypto_shash *src_tfm = src->tfm;
|
||||||
struct crypto_shash *dst_tfm = dst->tfm;
|
struct crypto_shash *dst_tfm = dst->tfm;
|
||||||
|
int ss = crypto_shash_statesize(dst_tfm);
|
||||||
|
|
||||||
|
#ifdef NV_CRYPTO_TFM_CTX_ALIGNED_PRESENT
|
||||||
char *src_ipad = crypto_tfm_ctx_aligned(&src_tfm->base);
|
char *src_ipad = crypto_tfm_ctx_aligned(&src_tfm->base);
|
||||||
char *dst_ipad = crypto_tfm_ctx_aligned(&dst_tfm->base);
|
char *dst_ipad = crypto_tfm_ctx_aligned(&dst_tfm->base);
|
||||||
int ss = crypto_shash_statesize(dst_tfm);
|
#else
|
||||||
|
int ctx_size = crypto_shash_alg(dst_tfm)->base.cra_ctxsize;
|
||||||
|
char *src_ipad = crypto_shash_ctx(src_tfm);
|
||||||
|
char *dst_ipad = crypto_shash_ctx(dst_tfm);
|
||||||
|
/*
|
||||||
|
* Actual struct definition is hidden, so I assume data we need is at
|
||||||
|
* the end. In 6.0 the struct has a pointer to crpyto_shash followed by:
|
||||||
|
* 'u8 ipad[statesize];', then 'u8 opad[statesize];'
|
||||||
|
*/
|
||||||
|
src_ipad += ctx_size - 2 * ss;
|
||||||
|
dst_ipad += ctx_size - 2 * ss;
|
||||||
|
#endif
|
||||||
|
|
||||||
memcpy(dst_ipad, src_ipad, crypto_shash_blocksize(src->tfm));
|
memcpy(dst_ipad, src_ipad, crypto_shash_blocksize(src->tfm));
|
||||||
memcpy(dst_ipad + ss, src_ipad + ss, crypto_shash_blocksize(src->tfm));
|
memcpy(dst_ipad + ss, src_ipad + ss, crypto_shash_blocksize(src->tfm));
|
||||||
crypto_shash_clear_flags(dst->tfm, CRYPTO_TFM_NEED_KEY);
|
crypto_shash_clear_flags(dst->tfm, CRYPTO_TFM_NEED_KEY);
|
||||||
|
|||||||
@@ -1389,6 +1389,7 @@ NvBool nv_get_hdcp_enabled(nv_state_t *nv)
|
|||||||
int nv_disable_simplefb_clocks(void)
|
int nv_disable_simplefb_clocks(void)
|
||||||
{
|
{
|
||||||
int status = 0;
|
int status = 0;
|
||||||
|
static bool is_coldboot = true;
|
||||||
|
|
||||||
#if defined(CONFIG_FB) && defined(NV_NUM_REGISTERED_FB_PRESENT)
|
#if defined(CONFIG_FB) && defined(NV_NUM_REGISTERED_FB_PRESENT)
|
||||||
if (num_registered_fb > 0)
|
if (num_registered_fb > 0)
|
||||||
@@ -1407,7 +1408,7 @@ int nv_disable_simplefb_clocks(void)
|
|||||||
int j;
|
int j;
|
||||||
|
|
||||||
np = of_find_node_by_name(NULL, "framebuffer");
|
np = of_find_node_by_name(NULL, "framebuffer");
|
||||||
if ((np != NULL) && of_device_is_available(np))
|
if ((np != NULL) && of_device_is_available(np) && is_coldboot)
|
||||||
{
|
{
|
||||||
#if defined(NV_LINUX_OF_CLK_H_PRESENT) && defined(NV_OF_CLK_GET_PARENT_COUNT_PRESENT)
|
#if defined(NV_LINUX_OF_CLK_H_PRESENT) && defined(NV_OF_CLK_GET_PARENT_COUNT_PRESENT)
|
||||||
clk_count = of_clk_get_parent_count(np);
|
clk_count = of_clk_get_parent_count(np);
|
||||||
@@ -1429,6 +1430,7 @@ int nv_disable_simplefb_clocks(void)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
is_coldboot = false;
|
||||||
}
|
}
|
||||||
of_node_put(np);
|
of_node_put(np);
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@@ -29,7 +29,7 @@
|
|||||||
NvU64 NV_API_CALL nv_get_kern_phys_address(NvU64 address)
|
NvU64 NV_API_CALL nv_get_kern_phys_address(NvU64 address)
|
||||||
{
|
{
|
||||||
/* direct-mapped kernel address */
|
/* direct-mapped kernel address */
|
||||||
if (virt_addr_valid(address))
|
if (virt_addr_valid((void *)address))
|
||||||
return __pa(address);
|
return __pa(address);
|
||||||
|
|
||||||
nv_printf(NV_DBG_ERRORS,
|
nv_printf(NV_DBG_ERRORS,
|
||||||
|
|||||||
@@ -161,7 +161,7 @@ NV_CONFTEST_FUNCTION_COMPILE_TESTS += pci_enable_atomic_ops_to_root
|
|||||||
NV_CONFTEST_FUNCTION_COMPILE_TESTS += vga_tryget
|
NV_CONFTEST_FUNCTION_COMPILE_TESTS += vga_tryget
|
||||||
NV_CONFTEST_FUNCTION_COMPILE_TESTS += cc_platform_has
|
NV_CONFTEST_FUNCTION_COMPILE_TESTS += cc_platform_has
|
||||||
NV_CONFTEST_FUNCTION_COMPILE_TESTS += seq_read_iter
|
NV_CONFTEST_FUNCTION_COMPILE_TESTS += seq_read_iter
|
||||||
NV_CONFTEST_FUNCTION_COMPILE_TESTS += unsafe_follow_pfn
|
NV_CONFTEST_FUNCTION_COMPILE_TESTS += follow_pfn
|
||||||
NV_CONFTEST_FUNCTION_COMPILE_TESTS += drm_gem_object_get
|
NV_CONFTEST_FUNCTION_COMPILE_TESTS += drm_gem_object_get
|
||||||
NV_CONFTEST_FUNCTION_COMPILE_TESTS += drm_gem_object_put_unlocked
|
NV_CONFTEST_FUNCTION_COMPILE_TESTS += drm_gem_object_put_unlocked
|
||||||
NV_CONFTEST_FUNCTION_COMPILE_TESTS += add_memory_driver_managed
|
NV_CONFTEST_FUNCTION_COMPILE_TESTS += add_memory_driver_managed
|
||||||
@@ -197,6 +197,7 @@ NV_CONFTEST_FUNCTION_COMPILE_TESTS += get_task_ioprio
|
|||||||
NV_CONFTEST_FUNCTION_COMPILE_TESTS += mdev_set_iommu_device
|
NV_CONFTEST_FUNCTION_COMPILE_TESTS += mdev_set_iommu_device
|
||||||
NV_CONFTEST_FUNCTION_COMPILE_TESTS += offline_and_remove_memory
|
NV_CONFTEST_FUNCTION_COMPILE_TESTS += offline_and_remove_memory
|
||||||
NV_CONFTEST_FUNCTION_COMPILE_TESTS += of_clk_get_parent_count
|
NV_CONFTEST_FUNCTION_COMPILE_TESTS += of_clk_get_parent_count
|
||||||
|
NV_CONFTEST_FUNCTION_COMPILE_TESTS += crypto_tfm_ctx_aligned
|
||||||
|
|
||||||
NV_CONFTEST_SYMBOL_COMPILE_TESTS += is_export_symbol_gpl_of_node_to_nid
|
NV_CONFTEST_SYMBOL_COMPILE_TESTS += is_export_symbol_gpl_of_node_to_nid
|
||||||
NV_CONFTEST_SYMBOL_COMPILE_TESTS += is_export_symbol_gpl_sme_active
|
NV_CONFTEST_SYMBOL_COMPILE_TESTS += is_export_symbol_gpl_sme_active
|
||||||
@@ -227,6 +228,7 @@ NV_CONFTEST_SYMBOL_COMPILE_TESTS += is_export_symbol_present_tsec_comms_clear_in
|
|||||||
NV_CONFTEST_SYMBOL_COMPILE_TESTS += is_export_symbol_present_tsec_comms_alloc_mem_from_gscco
|
NV_CONFTEST_SYMBOL_COMPILE_TESTS += is_export_symbol_present_tsec_comms_alloc_mem_from_gscco
|
||||||
NV_CONFTEST_SYMBOL_COMPILE_TESTS += is_export_symbol_present_tsec_comms_free_gscco_mem
|
NV_CONFTEST_SYMBOL_COMPILE_TESTS += is_export_symbol_present_tsec_comms_free_gscco_mem
|
||||||
NV_CONFTEST_SYMBOL_COMPILE_TESTS += crypto
|
NV_CONFTEST_SYMBOL_COMPILE_TESTS += crypto
|
||||||
|
NV_CONFTEST_SYMBOL_COMPILE_TESTS += is_export_symbol_present_follow_pte
|
||||||
|
|
||||||
NV_CONFTEST_TYPE_COMPILE_TESTS += dma_ops
|
NV_CONFTEST_TYPE_COMPILE_TESTS += dma_ops
|
||||||
NV_CONFTEST_TYPE_COMPILE_TESTS += swiotlb_dma_ops
|
NV_CONFTEST_TYPE_COMPILE_TESTS += swiotlb_dma_ops
|
||||||
|
|||||||
@@ -30,10 +30,28 @@ static inline int nv_follow_pfn(struct vm_area_struct *vma,
|
|||||||
unsigned long address,
|
unsigned long address,
|
||||||
unsigned long *pfn)
|
unsigned long *pfn)
|
||||||
{
|
{
|
||||||
#if defined(NV_UNSAFE_FOLLOW_PFN_PRESENT)
|
#if defined(NV_FOLLOW_PFN_PRESENT)
|
||||||
return unsafe_follow_pfn(vma, address, pfn);
|
|
||||||
#else
|
|
||||||
return follow_pfn(vma, address, pfn);
|
return follow_pfn(vma, address, pfn);
|
||||||
|
#else
|
||||||
|
#if NV_IS_EXPORT_SYMBOL_PRESENT_follow_pte
|
||||||
|
int status = 0;
|
||||||
|
spinlock_t *ptl;
|
||||||
|
pte_t *ptep;
|
||||||
|
|
||||||
|
if (!(vma->vm_flags & (VM_IO | VM_PFNMAP)))
|
||||||
|
return status;
|
||||||
|
|
||||||
|
status = follow_pte(vma, address, &ptep, &ptl);
|
||||||
|
if (status)
|
||||||
|
return status;
|
||||||
|
*pfn = pte_pfn(ptep_get(ptep));
|
||||||
|
|
||||||
|
// The lock is acquired inside follow_pte()
|
||||||
|
pte_unmap_unlock(ptep, ptl);
|
||||||
|
return 0;
|
||||||
|
#else // NV_IS_EXPORT_SYMBOL_PRESENT_follow_pte
|
||||||
|
return -1;
|
||||||
|
#endif // NV_IS_EXPORT_SYMBOL_PRESENT_follow_pte
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1 +1 @@
|
|||||||
rel-36_eng_2024-04-04
|
rel-36_eng_2024-06-26
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
#if defined(NV_LINUX) || defined(NV_BSD) || defined(NV_SUNOS) || defined(NV_VMWARE) || defined(NV_QNX) || defined(NV_INTEGRITY) || \
|
#if defined(NV_LINUX) || defined(NV_BSD) || defined(NV_SUNOS) || defined(NV_VMWARE) || defined(NV_QNX) || defined(NV_INTEGRITY) || \
|
||||||
(defined(RMCFG_FEATURE_PLATFORM_GSP) && RMCFG_FEATURE_PLATFORM_GSP == 1)
|
(defined(RMCFG_FEATURE_PLATFORM_GSP) && RMCFG_FEATURE_PLATFORM_GSP == 1)
|
||||||
|
|
||||||
#define NV_VERSION_STRING "540.3.0"
|
#define NV_VERSION_STRING "540.4.0"
|
||||||
|
|
||||||
#else
|
#else
|
||||||
|
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
NVIDIA_VERSION = 540.3.0
|
NVIDIA_VERSION = 540.4.0
|
||||||
|
|
||||||
# This file.
|
# This file.
|
||||||
VERSION_MK_FILE := $(lastword $(MAKEFILE_LIST))
|
VERSION_MK_FILE := $(lastword $(MAKEFILE_LIST))
|
||||||
|
|||||||
Reference in New Issue
Block a user