diff options
author | Aaron Plattner <aplattner@nvidia.com> | 2019-10-17 08:23:47 -0700 |
---|---|---|
committer | Aaron Plattner <aplattner@nvidia.com> | 2019-10-17 08:23:47 -0700 |
commit | 44c396c29496f285317fcf6440e2e649784df108 (patch) | |
tree | 43b5c8fb0b493df1dc1f380785d9c8f1c3f41124 | |
parent | 18ecf178aa6764cb6f4c447d053ba8339091e7af (diff) |
440.26440.26
-rw-r--r-- | kernel.c | 27 | ||||
-rw-r--r-- | nvidia-installer.c | 14 | ||||
-rw-r--r-- | version.mk | 2 |
3 files changed, 28 insertions, 15 deletions
@@ -1661,32 +1661,35 @@ PrecompiledInfo *find_precompiled_kernel_interface(Options *op, Package *p) * the user specified via the --kernel-name option, or `uname -r`. */ -char __kernel_name[256]; - char *get_kernel_name(Options *op) { + static char kernel_name[256]; struct utsname uname_buf; - __kernel_name[0] = '\0'; + if (!kernel_name[0]) { + if (uname(&uname_buf) == -1) { + static int uname_failed; - if (uname(&uname_buf) == -1) { - ui_warn(op, "Unable to determine the version of the running kernel " - "(%s).", strerror(errno)); - } else { - strncpy(__kernel_name, uname_buf.release, sizeof(__kernel_name)); - __kernel_name[sizeof(__kernel_name) - 1] = '\0'; + if (!uname_failed) { + ui_warn(op, "Unable to determine the version of the running " + "kernel (%s).", strerror(errno)); + uname_failed = TRUE; + } + } else { + strncpy(kernel_name, uname_buf.release, sizeof(kernel_name) - 1); + } } if (op->kernel_name) { - if (strcmp(op->kernel_name, __kernel_name) != 0) { + if (strcmp(op->kernel_name, kernel_name) != 0) { /* Don't load kernel modules built against a non-running kernel */ op->skip_module_load = TRUE; } return op->kernel_name; } - if (__kernel_name[0]) { - return __kernel_name; + if (kernel_name[0]) { + return kernel_name; } return NULL; diff --git a/nvidia-installer.c b/nvidia-installer.c index 00f8b98..48e684e 100644 --- a/nvidia-installer.c +++ b/nvidia-installer.c @@ -458,7 +458,12 @@ static void parse_commandline(int argc, char *argv[], Options *op) NV_OPTIONAL_BOOL_FALSE; break; case GLVND_GLX_CLIENT_OPTION: - /* This option is no longer used; ignore it. */ + /* This option is no longer used */ + if (!boolval) { + nv_error_msg("The --no-glvnd-glx-client option is no longer supported"); + goto fail; + } + nv_warning_msg("The '--glvnd-glx-client' option is deprecated: " "nvidia-installer will ignore this option."); break; @@ -466,7 +471,12 @@ static void parse_commandline(int argc, char *argv[], Options *op) op->libglvnd_json_path = strval; break; case GLVND_EGL_CLIENT_OPTION: - /* This option is no longer used; ignore it. */ + /* This option is no longer used */ + if (!boolval) { + nv_error_msg("The --no-glvnd-egl-client option is no longer supported"); + goto fail; + } + nv_warning_msg("The '--glvnd-egl-client' option is deprecated: " "nvidia-installer will ignore this option."); break; @@ -1 +1 @@ -NVIDIA_VERSION = 435.21 +NVIDIA_VERSION = 440.26 |