Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
P
PortWINE
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Mikhail Tergoev
PortWINE
Commits
8fc21de7
Commit
8fc21de7
authored
Aug 22, 2023
by
Boria138
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added automatic detection of RTX support by Nvidia card
Unfortunately for lack of a 16 series card the code was not tested
parent
97ced970
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
51 additions
and
0 deletions
+51
-0
functions_helper
data_from_portwine/scripts/functions_helper
+51
-0
No files found.
data_from_portwine/scripts/functions_helper
View file @
8fc21de7
...
...
@@ -1061,3 +1061,54 @@ pw_find_exe () {
exit
0
fi
}
nvidia_check_arch
(){
local
gpu_info
=
$(
lspci |
grep
"VGA
\|
3D"
)
if
[[
"
$gpu_info
"
=
~ NVIDIA
]]
;
then
if
[[
"
$gpu_info
"
=
~ G[0-9]
*
|GT[0-9]
*
|MCP[0-9]
*
]]
;
then
nv_arch
=
Tesla
elif
[[
"
$gpu_info
"
=
~ GF[0-9]
*
]]
;
then
nv_arch
=
Fermi
elif
[[
"
$gpu_info
"
=
~ GK[0-9]
*
]]
;
then
nv_arch
=
Kepler
elif
[[
"
$gpu_info
"
=
~ GM[0-9]
*
]]
;
then
nv_arch
=
Maxwell
elif
[[
"
$gpu_info
"
=
~ GP[0-9]
*
]]
;
then
nv_arch
=
Pascal
elif
[[
"
$gpu_info
"
=
~ GV[0-9]
*
]]
;
then
nv_arch
=
Volta
elif
[[
"
$gpu_info
"
=
~ TU[0-9]
*
]]
;
then
nv_arch
=
Turing
elif
[[
"
$gpu_info
"
=
~ GA[0-9]
*
]]
;
then
nv_arch
=
Ampere
elif
[[
"
$gpu_info
"
=
~ AD[0-9]
*
]]
;
then
nv_arch
=
Ada_Lovelace
fi
fi
}
nvidia_check_arch
# Check for Nvidia GPU available
if
[[
-n
"
$nv_arch
"
]]
;
then
case
"
$nv_arch
"
in
Turing
)
if
[[
"
$gpu_info
"
=
~ TU16[0-9]
*
]]
;
then
# Nvida GTX 16 series
export
PW_USE_NVAPI_AND_DLSS
=
0
else
# Nvidia RTX 20 series
export
PW_USE_NVAPI_AND_DLSS
=
1
fi
;;
# Nvidia RTX 30 and 40 series
Ampere|Ada_Lovelace
)
export
PW_USE_NVAPI_AND_DLSS
=
1
;;
*
)
# Everything else nvidia cards
export
PW_USE_NVAPI_AND_DLSS
=
0
;;
esac
fi
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment