commit 2af94902bb0c417fe91f8760ab470703e0ddc00a
Author: Henrik Nordström <henrik(a)hno.se>
Date: Sat Jun 18 17:14:40 2022 +0200
Update to 390.151
kernel-5.18-uvm.patch | 99 ++++++++++++++++++++++++++++++++++++++++++++++++++
kernel-5.18.patch | 94 +++++++++++++++++++++++++++++++++++++++++++++++
nvidia-390xx-kmod.spec | 30 ++++++++++-----
3 files changed, 213 insertions(+), 10 deletions(-)
---
diff --git a/kernel-5.18-uvm.patch b/kernel-5.18-uvm.patch
new file mode 100644
index 0000000..ea86903
--- /dev/null
+++ b/kernel-5.18-uvm.patch
@@ -0,0 +1,99 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html
xmlns="http://www.w3.org/1999/xhtml" xml:lang="en-US"
lang="en-US">
+<!-- git web interface version 2.35.1, (C) 2005-2006, Kay Sievers
<kay.sievers(a)vrfy.org>, Christian Gierke -->
+<!-- git core binaries version 2.35.1 -->
+<head>
+<meta http-equiv="content-type" content="text/html;
charset=utf-8"/>
+<meta name="generator" content="gitweb/2.35.1 git/2.35.1"/>
+<meta name="robots" content="index, nofollow"/>
+<title>git.pld-linux.org Git -
packages/xorg-driver-video-nvidia-legacy-390xx.git/blob -
kernel-5.18-uvm.patch</title>
+<link rel="stylesheet" type="text/css"
href="static/gitweb-site.css"/>
+<link rel="alternate"
title="packages/xorg-driver-video-nvidia-legacy-390xx.git - history of
kernel-5.18-uvm.patch - RSS feed"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=rss;f=kernel-5.18-uvm.patch"
type="application/rss+xml" />
+<link rel="alternate"
title="packages/xorg-driver-video-nvidia-legacy-390xx.git - history of
kernel-5.18-uvm.patch - RSS feed (no merges)"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=rss;f=kernel-5.18-uvm.patch;opt=--no-merges"
type="application/rss+xml" />
+<link rel="alternate"
title="packages/xorg-driver-video-nvidia-legacy-390xx.git - history of
kernel-5.18-uvm.patch - Atom feed"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=atom;f=kernel-5.18-uvm.patch"
type="application/atom+xml" />
+<link rel="alternate"
title="packages/xorg-driver-video-nvidia-legacy-390xx.git - history of
kernel-5.18-uvm.patch - Atom feed (no merges)"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=atom;f=kernel-5.18-uvm.patch;opt=--no-merges"
type="application/atom+xml" />
+<link rel="shortcut icon" href="static/pld-favicon.ico"
type="image/png" />
+</head>
+<body>
+<div class="page_header">
+<a href="http://www.pld-linux.org" title="PLD Linux
distribution"><img alt="git" class="logo"
height="27" src="static/pld-logo.png" width="72"
/></a><a href="/gitweb.cgi">projects</a> / <a
href="/gitweb.cgi?a=project_list;pf=packages">packages</a> / <a
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=summary">xorg-driver-video-nvidia-legacy-390xx.git</a>
/ blob
+</div>
+<form method="get" action="/gitweb.cgi"
enctype="multipart/form-data"><div class="search">
+<input name="p" type="hidden"
value="packages/xorg-driver-video-nvidia-legacy-390xx.git" />
+<input name="a" type="hidden" value="search" />
+<input name="h" type="hidden"
value="70ee162314861b60f333d00d2485c2a7ac2fce4a" />
+<select name="st" >
+<option selected="selected"
value="commit">commit</option>
+<option value="grep">grep</option>
+<option value="author">author</option>
+<option value="committer">committer</option>
+<option value="pickaxe">pickaxe</option>
+</select> <a
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=search_help"
title="search help">?</a> search:
+<input type="text" name="s" />
+<span title="Extended regular expression"><label><input
type="checkbox" name="sr" value="1"
/>re</label></span></div>
+</form>
+<div class="page_nav">
+<a
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=summary">summary</a>
| <a
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=shortlog">shortlog</a>
| <a
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=log">log</a>
| <a
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=commit;h=70ee162314861b60f333d00d2485c2a7ac2fce4a">commit</a>
| <a
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=commitdiff;h=70ee162314861b60f333d00d2485c2a7ac2fce4a">commitdiff</a>
| <a
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=tree;h=0080accee796263228ef22a51610904fd5abe487;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a">tree</a><br/>
+<a
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=blame;f=kernel-5.18-uvm.patch;h=cc02ee9a3d63c82418b91299608c4a9bbe04118b;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a">blame</a>
| <a
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=history;f=kernel-5.18-uvm.patch;h=cc02ee9a3d63c82418b91299608c4a9bbe04118b;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a">history</a>
| <a
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=blob_plain;f=kernel-5.18-uvm.patch;h=cc02ee9a3d63c82418b91299608c4a9bbe04118b;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a">raw</a>
| <a
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=blob;f=kernel-5.18-uvm.patch;hb=HEAD">HEAD</a><br/>
+</div>
+<div class="header">
+<a class="title"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=commit;h=70ee162314861b60f333d00d2485c2a7ac2fce4a">-
fixes for kernel 5.18, rel 2</a>
+</div>
+<div class="page_path"><a
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=tree;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a"
title="tree
root">[packages/xorg-driver-video-nvidia-legacy-390xx.git]</a> / <a
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=blob_plain;f=kernel-5.18-uvm.patch;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a"
title="kernel-5.18-uvm.patch">kernel-5.18-uvm.patch</a><br/></div>
+<div class="page_body">
+<div class="pre"><a id="l1"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=blob;f=kernel-5.18-uvm.patch;h=cc02ee9a3d63c82418b91299608c4a9bbe04118b;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a#l1"
class="linenr"> 1</a>
--- NVIDIA-Linux-x86_64-390.151-no-compat32/kernel/nvidia-uvm/uvm8_gpu.c~ 2022-04-20 19:57:58.000000000 +0200</div>
+<div class="pre"><a id="l2"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=blob;f=kernel-5.18-uvm.patch;h=cc02ee9a3d63c82418b91299608c4a9bbe04118b;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a#l2"
class="linenr"> 2</a>
+++ NVIDIA-Linux-x86_64-390.151-no-compat32/kernel/nvidia-uvm/uvm8_gpu.c 2022-05-26 11:20:33.644914149 +0200</div>
+<div class="pre"><a id="l3"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=blob;f=kernel-5.18-uvm.patch;h=cc02ee9a3d63c82418b91299608c4a9bbe04118b;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a#l3"
class="linenr"> 3</a>
@@ -2214,7 +2214,11 @@</div>
+<div class="pre"><a id="l4"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=blob;f=kernel-5.18-uvm.patch;h=cc02ee9a3d63c82418b91299608c4a9bbe04118b;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a#l4"
class="linenr"> 4</a> </div>
+<div class="pre"><a id="l5"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=blob;f=kernel-5.18-uvm.patch;h=cc02ee9a3d63c82418b91299608c4a9bbe04118b;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a#l5"
class="linenr"> 5</a>
NV_STATUS uvm_gpu_map_cpu_pages(uvm_gpu_t *gpu, struct page *page, size_t size, NvU64 *dma_addr_out)</div>
+<div class="pre"><a id="l6"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=blob;f=kernel-5.18-uvm.patch;h=cc02ee9a3d63c82418b91299608c4a9bbe04118b;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a#l6"
class="linenr"> 6</a> {</div>
+<div class="pre"><a id="l7"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=blob;f=kernel-5.18-uvm.patch;h=cc02ee9a3d63c82418b91299608c4a9bbe04118b;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a#l7"
class="linenr"> 7</a>
+#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 18, 0)</div>
+<div class="pre"><a id="l8"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=blob;f=kernel-5.18-uvm.patch;h=cc02ee9a3d63c82418b91299608c4a9bbe04118b;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a#l8"
class="linenr"> 8</a>
NvU64 dma_addr = pci_map_page(gpu->pci_dev, page, 0, size, PCI_DMA_BIDIRECTIONAL);</div>
+<div class="pre"><a id="l9"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=blob;f=kernel-5.18-uvm.patch;h=cc02ee9a3d63c82418b91299608c4a9bbe04118b;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a#l9"
class="linenr"> 9</a> +#else</div>
+<div class="pre"><a id="l10"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=blob;f=kernel-5.18-uvm.patch;h=cc02ee9a3d63c82418b91299608c4a9bbe04118b;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a#l10"
class="linenr"> 10</a>
+ NvU64 dma_addr = dma_map_page(&gpu->pci_dev->dev, page, 0, size, DMA_BIDIRECTIONAL);</div>
+<div class="pre"><a id="l11"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=blob;f=kernel-5.18-uvm.patch;h=cc02ee9a3d63c82418b91299608c4a9bbe04118b;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a#l11"
class="linenr"> 11</a> +#endif</div>
+<div class="pre"><a id="l12"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=blob;f=kernel-5.18-uvm.patch;h=cc02ee9a3d63c82418b91299608c4a9bbe04118b;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a#l12"
class="linenr"> 12</a> </div>
+<div class="pre"><a id="l13"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=blob;f=kernel-5.18-uvm.patch;h=cc02ee9a3d63c82418b91299608c4a9bbe04118b;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a#l13"
class="linenr"> 13</a>
UVM_ASSERT(PAGE_ALIGNED(size));</div>
+<div class="pre"><a id="l14"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=blob;f=kernel-5.18-uvm.patch;h=cc02ee9a3d63c82418b91299608c4a9bbe04118b;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a#l14"
class="linenr"> 14</a> </div>
+<div class="pre"><a id="l15"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=blob;f=kernel-5.18-uvm.patch;h=cc02ee9a3d63c82418b91299608c4a9bbe04118b;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a#l15"
class="linenr"> 15</a>
@@ -2222,7 +2226,11 @@</div>
+<div class="pre"><a id="l16"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=blob;f=kernel-5.18-uvm.patch;h=cc02ee9a3d63c82418b91299608c4a9bbe04118b;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a#l16"
class="linenr"> 16</a>
return NV_ERR_OPERATING_SYSTEM;</div>
+<div class="pre"><a id="l17"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=blob;f=kernel-5.18-uvm.patch;h=cc02ee9a3d63c82418b91299608c4a9bbe04118b;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a#l17"
class="linenr"> 17</a> </div>
+<div class="pre"><a id="l18"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=blob;f=kernel-5.18-uvm.patch;h=cc02ee9a3d63c82418b91299608c4a9bbe04118b;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a#l18"
class="linenr"> 18</a>
if (dma_addr < gpu->dma_addressable_start || dma_addr + size - 1 > gpu->dma_addressable_limit) {</div>
+<div class="pre"><a id="l19"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=blob;f=kernel-5.18-uvm.patch;h=cc02ee9a3d63c82418b91299608c4a9bbe04118b;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a#l19"
class="linenr"> 19</a>
+#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 18, 0)</div>
+<div class="pre"><a id="l20"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=blob;f=kernel-5.18-uvm.patch;h=cc02ee9a3d63c82418b91299608c4a9bbe04118b;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a#l20"
class="linenr"> 20</a>
pci_unmap_page(gpu->pci_dev, dma_addr, size, PCI_DMA_BIDIRECTIONAL);</div>
+<div class="pre"><a id="l21"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=blob;f=kernel-5.18-uvm.patch;h=cc02ee9a3d63c82418b91299608c4a9bbe04118b;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a#l21"
class="linenr"> 21</a> +#else</div>
+<div class="pre"><a id="l22"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=blob;f=kernel-5.18-uvm.patch;h=cc02ee9a3d63c82418b91299608c4a9bbe04118b;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a#l22"
class="linenr"> 22</a>
+ dma_unmap_page(&gpu->pci_dev->dev, dma_addr, size, DMA_BIDIRECTIONAL);</div>
+<div class="pre"><a id="l23"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=blob;f=kernel-5.18-uvm.patch;h=cc02ee9a3d63c82418b91299608c4a9bbe04118b;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a#l23"
class="linenr"> 23</a> +#endif</div>
+<div class="pre"><a id="l24"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=blob;f=kernel-5.18-uvm.patch;h=cc02ee9a3d63c82418b91299608c4a9bbe04118b;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a#l24"
class="linenr"> 24</a>
UVM_ERR_PRINT_RL("PCI mapped range [0x%llx, 0x%llx) not in the addressable range [0x%llx, 0x%llx), GPU %s\n",</div>
+<div class="pre"><a id="l25"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=blob;f=kernel-5.18-uvm.patch;h=cc02ee9a3d63c82418b91299608c4a9bbe04118b;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a#l25"
class="linenr"> 25</a>
dma_addr,</div>
+<div class="pre"><a id="l26"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=blob;f=kernel-5.18-uvm.patch;h=cc02ee9a3d63c82418b91299608c4a9bbe04118b;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a#l26"
class="linenr"> 26</a>
dma_addr + (NvU64)size,</div>
+<div class="pre"><a id="l27"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=blob;f=kernel-5.18-uvm.patch;h=cc02ee9a3d63c82418b91299608c4a9bbe04118b;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a#l27"
class="linenr"> 27</a>
@@ -2256,7 +2264,11 @@</div>
+<div class="pre"><a id="l28"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=blob;f=kernel-5.18-uvm.patch;h=cc02ee9a3d63c82418b91299608c4a9bbe04118b;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a#l28"
class="linenr"> 28</a>
if (gpu->npu_dev)</div>
+<div class="pre"><a id="l29"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=blob;f=kernel-5.18-uvm.patch;h=cc02ee9a3d63c82418b91299608c4a9bbe04118b;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a#l29"
class="linenr"> 29</a>
dma_address = nv_expand_nvlink_addr(dma_address);</div>
+<div class="pre"><a id="l30"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=blob;f=kernel-5.18-uvm.patch;h=cc02ee9a3d63c82418b91299608c4a9bbe04118b;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a#l30"
class="linenr"> 30</a>
dma_address += gpu->dma_addressable_start;</div>
+<div class="pre"><a id="l31"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=blob;f=kernel-5.18-uvm.patch;h=cc02ee9a3d63c82418b91299608c4a9bbe04118b;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a#l31"
class="linenr"> 31</a>
+#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 18, 0)</div>
+<div class="pre"><a id="l32"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=blob;f=kernel-5.18-uvm.patch;h=cc02ee9a3d63c82418b91299608c4a9bbe04118b;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a#l32"
class="linenr"> 32</a>
pci_unmap_page(gpu->pci_dev, dma_address, size, PCI_DMA_BIDIRECTIONAL);</div>
+<div class="pre"><a id="l33"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=blob;f=kernel-5.18-uvm.patch;h=cc02ee9a3d63c82418b91299608c4a9bbe04118b;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a#l33"
class="linenr"> 33</a> +#else</div>
+<div class="pre"><a id="l34"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=blob;f=kernel-5.18-uvm.patch;h=cc02ee9a3d63c82418b91299608c4a9bbe04118b;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a#l34"
class="linenr"> 34</a>
+ dma_unmap_page(&gpu->pci_dev->dev, dma_address, size, DMA_BIDIRECTIONAL);</div>
+<div class="pre"><a id="l35"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=blob;f=kernel-5.18-uvm.patch;h=cc02ee9a3d63c82418b91299608c4a9bbe04118b;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a#l35"
class="linenr"> 35</a> +#endif</div>
+<div class="pre"><a id="l36"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=blob;f=kernel-5.18-uvm.patch;h=cc02ee9a3d63c82418b91299608c4a9bbe04118b;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a#l36"
class="linenr"> 36</a>
atomic64_sub(size, &gpu->mapped_cpu_pages_size);</div>
+<div class="pre"><a id="l37"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=blob;f=kernel-5.18-uvm.patch;h=cc02ee9a3d63c82418b91299608c4a9bbe04118b;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a#l37"
class="linenr"> 37</a> }</div>
+<div class="pre"><a id="l38"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=blob;f=kernel-5.18-uvm.patch;h=cc02ee9a3d63c82418b91299608c4a9bbe04118b;hb=70ee162314861b60f333d00d2485c2a7ac2fce4a#l38"
class="linenr"> 38</a> </div>
+</div><div class="page_footer">
+<div class="page_footer_text">Linux Drivers for nVidia GeForce/Quadro
Chips</div>
+<a class="rss_logo"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=rss;f=kernel-5.18-uvm.patch"
title="history of kernel-5.18-uvm.patch RSS feed">RSS</a>
+<a class="rss_logo"
href="/gitweb.cgi?p=packages/xorg-driver-video-nvidia-legacy-390xx.git;a=atom;f=kernel-5.18-uvm.patch"
title="history of kernel-5.18-uvm.patch Atom feed">Atom</a>
+</div>
+<div id="generating_info">
+This page took <span id="generating_time"
class="time_span">0.05935 seconds </span> and <span
id="generating_cmd">3</span> git commands to generate.
+</div>
+<script type="text/javascript"
src="static/gitweb.js"></script>
+<script type="text/javascript">
+window.onload = function () {
+ var tz_cookie = { name: 'gitweb_tz', expires: 14, path: '/' };
+ onloadTZSetup('local', tz_cookie, 'datetime');
+};
+</script>
+</body>
+</html>
\ No newline at end of file
diff --git a/kernel-5.18.patch b/kernel-5.18.patch
new file mode 100644
index 0000000..43cf468
--- /dev/null
+++ b/kernel-5.18.patch
@@ -0,0 +1,94 @@
+--- NVIDIA-Linux-x86_64-390.151-no-compat32/kernel/nvidia/nv.c~ 2022-04-20
19:57:55.000000000 +0200
++++ NVIDIA-Linux-x86_64-390.151-no-compat32/kernel/nvidia/nv.c 2022-05-26
10:54:29.375034057 +0200
+@@ -2742,7 +2742,11 @@
+ if (!nvl->tce_bypass_enabled)
+ {
+ NvU64 new_mask = (((NvU64)1) << phys_addr_bits) - 1;
++#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 18, 0)
+ pci_set_dma_mask(nvl->dev, new_mask);
++#else
++ dma_set_mask(&nvl->dev->dev, new_mask);
++#endif
+ }
+ }
+
+--- NVIDIA-Linux-x86_64-390.151-no-compat32/kernel/nvidia/nv-dma.c.orig 2022-04-20
19:57:55.000000000 +0200
++++ NVIDIA-Linux-x86_64-390.151-no-compat32/kernel/nvidia/nv-dma.c 2022-05-26
11:03:12.139154417 +0200
+@@ -27,8 +27,13 @@
+ NvU64 *va
+ )
+ {
++#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 18, 0)
+ *va = pci_map_page(dma_map->dev, dma_map->pages[0], 0,
+ dma_map->page_count * PAGE_SIZE, PCI_DMA_BIDIRECTIONAL);
++#else
++ *va = dma_map_page(&dma_map->dev->dev, dma_map->pages[0], 0,
++ dma_map->page_count * PAGE_SIZE, DMA_BIDIRECTIONAL);
++#endif
+ if (NV_PCI_DMA_MAPPING_ERROR(dma_map->dev, *va))
+ {
+ return NV_ERR_OPERATING_SYSTEM;
+@@ -57,8 +62,13 @@
+
+ static void nv_dma_unmap_contig(nv_dma_map_t *dma_map)
+ {
++#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 18, 0)
+ pci_unmap_page(dma_map->dev, dma_map->mapping.contig.dma_addr,
+ dma_map->page_count * PAGE_SIZE, PCI_DMA_BIDIRECTIONAL);
++#else
++ dma_unmap_page(&dma_map->dev->dev, dma_map->mapping.contig.dma_addr,
++ dma_map->page_count * PAGE_SIZE, DMA_BIDIRECTIONAL);
++#endif
+ }
+
+ static void nv_fill_scatterlist
+@@ -166,10 +176,17 @@
+
+ NV_FOR_EACH_DMA_SUBMAP(dma_map, submap, i)
+ {
++#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 18, 0)
+ submap->sg_map_count = pci_map_sg(dma_map->dev,
+ NV_DMA_SUBMAP_SCATTERLIST(submap),
+ NV_DMA_SUBMAP_SCATTERLIST_LENGTH(submap),
+ PCI_DMA_BIDIRECTIONAL);
++#else
++ submap->sg_map_count = dma_map_sg(&dma_map->dev->dev,
++ NV_DMA_SUBMAP_SCATTERLIST(submap),
++ NV_DMA_SUBMAP_SCATTERLIST_LENGTH(submap),
++ DMA_BIDIRECTIONAL);
++#endif
+ if (submap->sg_map_count == 0)
+ {
+ status = NV_ERR_OPERATING_SYSTEM;
+@@ -197,9 +214,15 @@
+ break;
+ }
+
++#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 18, 0)
+ pci_unmap_sg(dma_map->dev, NV_DMA_SUBMAP_SCATTERLIST(submap),
+ NV_DMA_SUBMAP_SCATTERLIST_LENGTH(submap),
+ PCI_DMA_BIDIRECTIONAL);
++#else
++ dma_unmap_sg(&dma_map->dev->dev, NV_DMA_SUBMAP_SCATTERLIST(submap),
++ NV_DMA_SUBMAP_SCATTERLIST_LENGTH(submap),
++ DMA_BIDIRECTIONAL);
++#endif
+ }
+ }
+
+--- NVIDIA-Linux-x86_64-390.151-no-compat32/kernel/common/inc/nv-linux.h.orig 2022-04-20
19:57:56.000000000 +0200
++++ NVIDIA-Linux-x86_64-390.151-no-compat32/kernel/common/inc/nv-linux.h 2022-05-26
11:05:45.337533146 +0200
+@@ -339,8 +339,13 @@
+
+ #if defined(NV_PCI_DMA_MAPPING_ERROR_PRESENT)
+ #if (NV_PCI_DMA_MAPPING_ERROR_ARGUMENT_COUNT == 2)
++#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 18, 0)
+ #define NV_PCI_DMA_MAPPING_ERROR(dev, addr) \
+ pci_dma_mapping_error(dev, addr)
++#else
++#define NV_PCI_DMA_MAPPING_ERROR(pdev, addr) \
++ dma_mapping_error(&pdev->dev, addr)
++#endif
+ #elif (NV_PCI_DMA_MAPPING_ERROR_ARGUMENT_COUNT == 1)
+ #define NV_PCI_DMA_MAPPING_ERROR(dev, addr) \
+ pci_dma_mapping_error(addr)
diff --git a/nvidia-390xx-kmod.spec b/nvidia-390xx-kmod.spec
index 9e1550b..0edc633 100644
--- a/nvidia-390xx-kmod.spec
+++ b/nvidia-390xx-kmod.spec
@@ -16,9 +16,9 @@
Name: nvidia-390xx-kmod
Epoch: 3
-Version: 390.147
+Version: 390.151
# Taken over by kmodtool
-Release: 3%{?dist}
+Release: 1%{?dist}
Summary: NVIDIA 390xx display driver kernel module
Group: System Environment/Kernel
License: Redistributable, no modification permitted
@@ -36,10 +36,14 @@ Source11: nvidia-390xx-kmodtool-excludekernel-filterfile
Patch10: 0001-backport-error-on-unknown-conftests.patch
Patch11: 0002-backport-error-on-unknown-conftests-uvm-part.patch
Patch12: do-div-cast.patch
-Patch13: kernel-5.7.0-set-memory-array.patch
-Patch14: kernel-5.12.patch
-Patch15:
https://gitlab.com/herecura/packages/nvidia-390xx-dkms/-/raw/herecura/ker...
-Patch16: nvidia-470xx-fix-linux-5.17.patch
+#Patch13: kernel-5.7.0-set-memory-array.patch
+#Patch14: kernel-5.12.patch
+#Patch15:
https://gitlab.com/herecura/packages/nvidia-390xx-dkms/-/raw/herecura/ker...
+#Patch16: nvidia-470xx-fix-linux-5.17.patch
+#
http://git.pld-linux.org/gitweb.cgi?p=packages/xorg-driver-video-nvidia-l...
+Patch17: kernel-5.18.patch
+#
http://git.pld-linux.org/gitweb.cgi?p=packages/xorg-driver-video-nvidia-l...
+Patch18: kernel-5.18-uvm.patch
# build system updates
Patch30: use-kbuild-compiler.patch
@@ -85,10 +89,13 @@ tar --use-compress-program xz -xf
%{_datadir}/%{name}-%{version}/%{name}-%{versi
%patch11 -p1 -b 11 -d kernel
%endif
%patch12 -p1 -b 12 -d kernel
-%patch13 -p1 -b 13 -d kernel
-%patch14 -p2 -b 14 -d kernel
-%patch15 -p2 -b 15 -d kernel
-%patch16 -p2 -b 15 -d kernel
+#patch13 -p1 -b 13 -d kernel
+#patch14 -p2 -b 14 -d kernel
+#patch15 -p2 -b 15 -d kernel
+#patch16 -p2 -b 15 -d kernel
+%patch17 -p1 -b 17 -d kernel
+%patch18 -p1 -b 18 -d kernel
+
%patch30 -p1 -b 30 -d kernel
%patch31 -p1 -b 31 -d kernel
%patch32 -p1 -b 32 -d kernel
@@ -125,6 +132,9 @@ done
%changelog
+* Sat Jun 18 2022 Henrik Nordstrom <henrik(a)henriknordstrom.net> - 390.151-1
+- Update to 390.151
+
* Wed Apr 20 2022 Sérgio Basto <sergio(a)serjux.com> - 3:390.147-3
- Try to fix linux-5.17 based on patch provided on
https://bugzilla.rpmfusion.org/6263