Bug 217341 - x11/nvidia-driver: Unbreak build for 375.39. 1 hunk of patch is merged upstream.
Summary: x11/nvidia-driver: Unbreak build for 375.39. 1 hunk of patch is merged upstream.
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Alexey Dokuchaev
URL:
Keywords:
Depends on:
Blocks: 216574
  Show dependency treegraph
 
Reported: 2017-02-25 07:52 UTC by Tomoaki AOKI
Modified: 2017-04-04 02:41 UTC (History)
5 users (show)

See Also:
bugzilla: maintainer-feedback? (danfe)


Attachments
Minimal diff (830 bytes, patch)
2017-02-25 08:00 UTC, Tomoaki AOKI
no flags Details | Diff
patch (4.61 KB, patch)
2017-02-25 19:33 UTC, Tijl Coosemans
no flags Details | Diff
Implementation of Option b from Tomoaki AOKI's comment. (1.13 KB, patch)
2017-03-26 16:57 UTC, Andrew Marks
no flags Details | Diff
Cumulative option b (for real this time) (5.71 KB, patch)
2017-03-26 17:17 UTC, Andrew Marks
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Tomoaki AOKI 2017-02-25 07:52:58 UTC
nvidia-driver is now at 375.39 upstream.
Now it includes 2nd hunk of the freebsd patch below.

 files/extra-patch-src_nvidia-modeset_nvidia-modeset-freebsd.c

Eliminating 2nd hunk of the patch above allows build, and running fine for me.
But I'm not 100% shure that no other change is needed or not.

Tested only on amd64. Not at all tested on i386.
Comment 1 Tomoaki AOKI 2017-02-25 08:00:34 UTC
Created attachment 180276 [details]
Minimal diff

Just a diff for affected patch.
Need updating Makefile and distinfo to merge.
Version check on Makefile should be needed for ones who want to use
358.009 <= NVVERSION < 375.39 via setting DISTVERSION.
Comment 2 Tijl Coosemans freebsd_committer freebsd_triage 2017-02-25 19:33:20 UTC
Created attachment 180292 [details]
patch

This patch updates all nvidia-driver* ports.  304.135 also fixes bug 216574.
Comment 3 Tomoaki AOKI 2017-03-19 06:14:14 UTC
Sorry for looong delay.
Your patch works fine. But we should have 4 options for now.

 a) Commit your patch as is.

 b) Fix further to allow building 358.009 <= NVVERSION < 375.39
    via setting DISTVERSION and -DNO_CHECKSUM.

 c) Update patch for 378.13, as x11/nvidia-settings is at 378.13.

 d) Same as b), but update for 378.13.

keeping x11/nvidia-driver and x11/nvidia-settings in sync would be
worth considering, but 378.13 is Short Lived Branch, while 375.39
is Long Lived Branch.

Which should be preferred?
Mostly, catching up with latest vesion would be OK, but someone
who needs older version (of same branch) with some reason
(ex. problems depending on specific chips) can require b) or d).
Comment 4 Andrew Marks 2017-03-26 15:10:25 UTC
This works for me as well on amd64

Also this addresses this security issue:
http://nvidia.custhelp.com/app/answers/detail/a_id/4398
Comment 5 Andrew Marks 2017-03-26 16:57:39 UTC
Created attachment 181212 [details]
Implementation of Option b from Tomoaki AOKI's comment.

Implementation of Option b from Tomoaki AOKI's comment.

To be applied on-top of the first patch.
Comment 6 Andrew Marks 2017-03-26 17:17:37 UTC
Created attachment 181213 [details]
Cumulative option b (for real this time)

I quickly realized my error, so I moved the conditional block in the Makefile

Sorry for the clutter. This time is cumulative and implements option b from above.
Comment 7 Jason Unovitch freebsd_committer freebsd_triage 2017-03-28 01:50:16 UTC
(In reply to Andrew Marks from comment #4)
Andrew, thanks for pointing this out. Hopping on CC for now.
Comment 8 commit-hook freebsd_committer freebsd_triage 2017-04-03 12:09:33 UTC
A commit references this bug:

Author: danfe
Date: Mon Apr  3 12:08:33 UTC 2017
New revision: 437618
URL: https://svnweb.freebsd.org/changeset/ports/437618

Log:
  Update nVidia drivers to their most recent versions: 375.39 (long lived
  branch); legacy versions: 340.102 and 304.135.

  PR:	216574, 217341

Changes:
  head/x11/nvidia-driver/Makefile
  head/x11/nvidia-driver/distinfo
  head/x11/nvidia-driver/files/extra-patch-src_nvidia-modeset_nvidia-modeset-freebsd.c
  head/x11/nvidia-driver-304/Makefile
  head/x11/nvidia-driver-340/Makefile
Comment 9 commit-hook freebsd_committer freebsd_triage 2017-04-04 02:28:04 UTC
A commit references this bug:

Author: danfe
Date: Tue Apr  4 02:27:16 UTC 2017
New revision: 437678
URL: https://svnweb.freebsd.org/changeset/ports/437678

Log:
  - Document recent NVIDIA GPU display driver vulnerabilities
  - Spell "NVIDIA UNIX driver" consistently throughout the file

  PR:	217341

Changes:
  head/security/vuxml/vuln.xml
Comment 10 Alexey Dokuchaev freebsd_committer freebsd_triage 2017-04-04 02:41:14 UTC
NVidia driver ports were updated as of ports r437618 and vulnerabilities documented in ports r437678, thank you.

Ultimately I've decided that maintaining two patches would not buy us much and had committed the patch identical to Tijl's proposal (comment #2).