Skip to content

Commit

Permalink
Merge pull request #4766 from lrusak/nvidia-fix
Browse files Browse the repository at this point in the history
xf86-video-nvidia: adjust udev rule to ignore non display devices
  • Loading branch information
sraue committed Feb 24, 2016
2 parents 6e85306 + 5f0186a commit ac75813
Show file tree
Hide file tree
Showing 2 changed files with 308 additions and 306 deletions.
Expand Up @@ -41,11 +41,12 @@
# Write the rules to the file
with open(__rules__, 'w') as f:
f.write('ACTION!="add|change", GOTO="end_video"\n')
f.write('SUBSYSTEM=="pci", ATTR{class}!="0x030000", GOTO="end_video"\n\n')
for id in unique_ids:
f.write('ATTRS{vendor}=="0x10de", ATTRS{device}=="0x' + str(id) + '", GOTO="configure_nvidia"\n')
f.write('ATTRS{vendor}=="0x10de", GOTO="configure_nvidia-legacy"\n')
f.write('SUBSYSTEM=="pci", ATTR{class}=="0x030000", ATTRS{vendor}=="0x10de", GOTO="subsystem_pci"\n')
f.write('GOTO="end_video"\n\n')
f.write('LABEL="subsystem_pci"\n')
for id in unique_ids:
f.write('ATTRS{device}=="0x' + str(id) + '", GOTO="configure_nvidia"\n')
f.write('GOTO="configure_nvidia-legacy"\n\n')
f.write('LABEL="configure_nvidia"\n')
f.write('ENV{xorg_driver}="nvidia", TAG+="systemd", ENV{SYSTEMD_WANTS}+="xorg-configure@nvidia.service"\n')
f.write('GOTO="end_video"\n\n')
Expand Down

0 comments on commit ac75813

Please sign in to comment.