diff options
author | Aaron Plattner <aplattner@nvidia.com> | 2008-02-13 10:21:37 -0800 |
---|---|---|
committer | Aaron Plattner <aplattner@nvidia.com> | 2008-02-13 10:21:37 -0800 |
commit | f0c14e5a22db1d31ea26aa6b034cf8d06d528d2c (patch) | |
tree | d58f67b7eb30a17da9381294ce4d01d52ac09af9 | |
parent | 2b28038f0c31d049ba9e6d7e3dfdc8c437bf87a1 (diff) |
96.43.0596.43.05
-rw-r--r-- | DRIVER_VERSION | 2 | ||||
-rw-r--r-- | command-list.c | 16 | ||||
-rw-r--r-- | install-from-cwd.c | 3 | ||||
-rw-r--r-- | misc.c | 25 | ||||
-rw-r--r-- | nvidia-installer.h | 2 | ||||
-rw-r--r-- | option_table.h | 10 |
6 files changed, 47 insertions, 11 deletions
diff --git a/DRIVER_VERSION b/DRIVER_VERSION index 20723f9..6927adb 100644 --- a/DRIVER_VERSION +++ b/DRIVER_VERSION @@ -1 +1 @@ -96.43.01 +96.43.05 diff --git a/command-list.c b/command-list.c index aa3f283..db4b729 100644 --- a/command-list.c +++ b/command-list.c @@ -209,6 +209,16 @@ CommandList *build_command_list(Options *op, Package *p) /* Add all the installable files to the list */ for (i = 0; i < p->num_entries; i++) { + if (op->selinux_enabled && + (op->utils[EXECSTACK] != NULL) && + ((p->entries[i].flags & FILE_TYPE_SHARED_LIB) || + (p->entries[i].flags & FILE_TYPE_XMODULE_SHARED_LIB))) { + tmp = nvstrcat(op->utils[EXECSTACK], " -c ", + p->entries[i].file, NULL); + add_command(c, RUN_CMD, tmp); + nvfree(tmp); + } + if (p->entries[i].flags & installable_files) { add_command(c, INSTALL_CMD, p->entries[i].file, @@ -226,8 +236,8 @@ CommandList *build_command_list(Options *op, Package *p) add_command(c, DELETE_CMD, p->entries[i].file); } - - if (op->selinux_enabled && + + if (op->selinux_enabled && ((p->entries[i].flags & FILE_TYPE_SHARED_LIB) || (p->entries[i].flags & FILE_TYPE_XMODULE_SHARED_LIB))) { tmp = nvstrcat(op->utils[CHCON], " -t ", op->selinux_chcon_type, @@ -475,6 +485,7 @@ static ConflictingFileInfo __xfree86_libs[] = { { "libXvMCNVIDIA", 13 /* strlen("libXvMCNVIDIA") */ }, { "libnvidia-cfg.", 14 /* strlen("libnvidia-cfg.") */ }, { "nvidia_drv.", 11 /* strlen("nvidia_drv.") */ }, + { "libcuda.", 8 /* strlen("libcuda.") */ }, { NULL, 0 } }; @@ -518,6 +529,7 @@ static ConflictingFileInfo __opengl_libs[] = { { "libnvidia-tls.", 14 /* strlen("libnvidia-tls.") */ }, { "libGLwrapper.", 13 /* strlen("libGLwrapper.") */ }, { "libnvidia-cfg.", 14 /* strlen("libnvidia-cfg.") */ }, + { "libcuda.", 8 /* strlen("libcuda.") */ }, { NULL, 0 } }; diff --git a/install-from-cwd.c b/install-from-cwd.c index a8a7e9d..edb8888 100644 --- a/install-from-cwd.c +++ b/install-from-cwd.c @@ -234,7 +234,8 @@ int install_from_cwd(Options *op) /* done */ - if (op->kernel_module_only) { + if (op->kernel_module_only || op->no_nvidia_xconfig_question) { + ui_message(op, "Installation of the kernel module for the %s " "(version %s) is now complete.", p->description, p->version); @@ -42,6 +42,10 @@ #include <libgen.h> #include <pci/pci.h> +#ifndef PCI_CLASS_DISPLAY_3D +#define PCI_CLASS_DISPLAY_3D 0x302 +#endif + #include "nvidia-installer.h" #include "user-interface.h" #include "kernel.h" @@ -704,6 +708,7 @@ int find_system_utils(Options *op) { "chcon", "selinux" }, { "selinuxenabled", "selinux" }, { "getenforce", "selinux" }, + { "execstack", "selinux" }, { "pkg-config", "pkg-config" }, { "X", "xserver" } }; @@ -2177,6 +2182,7 @@ int check_for_nvidia_graphics_devices(Options *op, Package *p) struct pci_access *pacc; struct pci_dev *dev; int i, found_supported_device = FALSE; + int found_vga_device = FALSE; uint16 class; pacc = pci_alloc(); @@ -2190,8 +2196,12 @@ int check_for_nvidia_graphics_devices(Options *op, Package *p) pci_scan_bus(pacc); for (dev = pacc->devices; dev != NULL; dev = dev->next) { - if ((pci_fill_info(dev, PCI_FILL_IDENT) & PCI_FILL_IDENT) && - ((class = pci_read_word(dev, PCI_CLASS_DEVICE)) == PCI_CLASS_DISPLAY_VGA) && + if ((pci_fill_info(dev, PCI_FILL_IDENT) & PCI_FILL_IDENT) == 0) + continue; + + class = pci_read_word(dev, PCI_CLASS_DEVICE); + + if ((class == PCI_CLASS_DISPLAY_VGA || class == PCI_CLASS_DISPLAY_3D) && (dev->vendor_id == 0x10de) /* NVIDIA */ && (dev->device_id >= 0x0020) /* TNT or later */) { /* @@ -2210,7 +2220,13 @@ int check_for_nvidia_graphics_devices(Options *op, Package *p) found_legacy_device = TRUE; } } - if (!found_legacy_device) found_supported_device = TRUE; + + if (!found_legacy_device) { + found_supported_device = TRUE; + + if (class == PCI_CLASS_DISPLAY_VGA) + found_vga_device = TRUE; + } } } @@ -2226,6 +2242,9 @@ int check_for_nvidia_graphics_devices(Options *op, Package *p) return FALSE; } + if (!found_vga_device) + op->no_nvidia_xconfig_question = TRUE; + return TRUE; } /* check_for_nvidia_graphics_devices() */ diff --git a/nvidia-installer.h b/nvidia-installer.h index 5a06536..5315635 100644 --- a/nvidia-installer.h +++ b/nvidia-installer.h @@ -53,6 +53,7 @@ typedef enum { CHCON = MAX_SYSTEM_UTILS, SELINUX_ENABLED, GETENFORCE, + EXECSTACK, PKG_CONFIG, XSERVER, MAX_SYSTEM_OPTIONAL_UTILS @@ -135,6 +136,7 @@ typedef struct __options { int selinux_enabled; int sigwinch_workaround; int no_x_check; + int no_nvidia_xconfig_question; char *opengl_prefix; char *opengl_libdir; diff --git a/option_table.h b/option_table.h index 313ade6..2398fee 100644 --- a/option_table.h +++ b/option_table.h @@ -394,10 +394,12 @@ static const NVOption __options[] = { "Linux installations using SELinux (Security-Enhanced Linux) " "require that the security type of all shared libraries be set " "to 'shlib_t' or 'textrel_shlib_t', depending on the distribution. " - "nvidia-installer will detect when to set " - "the security type, and set it using chcon(1) on the shared " - "libraries it installs. Use this option to override " - "nvidia-installer's detection of when to set the security type. " + "nvidia-installer will detect when to set the security type, " + "and set it using chcon(1) on the shared libraries it installs. " + "If the execstack(8) system utility is present, nvidia-installer will " + "use it to also clear the executable stack flag of the libraries. " + "Use this option to override nvidia-installer's detection of when " + "to set the security type. " "Valid values for [FORCE-SELINUX] are 'yes' (force setting of the " "security type), " "'no' (prevent setting of the security type), and 'default' " |