Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 31 Aug 2003 18:31:21 +0200
From:      Hendrik Hasenbein <hhasenbe@techfak.uni-bielefeld.de>
To:        Andrew Atrens <atrens@nortelnetworks.com>
Cc:        freebsd-current@freebsd.org
Subject:   Re: nvidia.ko freezes system in -current
Message-ID:  <3F5222D9.8020404@techfak.uni-bielefeld.de>
In-Reply-To: <3F4F765E.3080104@nortelnetworks.com>
References:  <200308281540.h7SFeUV22668@accms33.physik.rwth-aachen.de> <20030828201301.GA14685@gattaca.yadt.co.uk> <3F4F57FA.4030605@techfak.uni-bielefeld.de> <3F4F5F80.8050205@nortelnetworks.com> <3F4F6978.3000301@techfak.uni-bielefeld.de> <3F4F765E.3080104@nortelnetworks.com>

next in thread | previous in thread | raw e-mail | index | archive | help
This is a multi-part message in MIME format.
--------------010408070600020605000904
Content-Type: text/plain; charset=us-ascii; format=flowed
Content-Transfer-Encoding: 7bit

Andrew Atrens wrote:
> The nvidia probe code gets invoked for every pci device discovered on 
> the bus.  The can't-attach-memory-resource thing essentially means that 
> the driver is trying to attach to a device that isn't a graphics card.

Ok. That seems to be the cause for the death of fsck on boot, too.
Because I use the x11/nvidia-driver port I created a patch. It is 
lacking a lot of IDs, because it is the reverse approach to Andrew's.

Hendrik

--------------010408070600020605000904
Content-Type: text/plain;
 name="patch-aa"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline;
 filename="patch-aa"

--- src/nvidia_pci.c.orig	Wed May 28 18:51:52 2003
+++ src/nvidia_pci.c	Sun Aug 31 17:34:19 2003
@@ -29,17 +29,26 @@
     
     vendor = pci_get_vendor(dev);
     device = pci_get_device(dev);
-    
+
     if (vendor != NVIDIA_VENDORID || device < 0x0020)
         return ENXIO;
 
-    if (rm_get_device_name(device, NV_DEVICE_NAME_LENGTH, name)
-            != RM_OK) {
-        strcpy(name, "Unknown");
-    }
+    switch ( device ) {
+        case 0x0281:
+            if (rm_get_device_name(device, NV_DEVICE_NAME_LENGTH, name)
+                    != RM_OK) {
+                strcpy(name, "Unknown");
+            }
     
-    device_set_desc_copy(dev, name);
-    return 0;
+            device_set_desc_copy(dev, name);
+            return 0;
+            break;
+        default:
+            if (pci_get_class(dev) == PCIC_DISPLAY)
+                device_printf(dev, "Unknown ID\nIf you are sure your device works with this driver\nplease post the ID");
+            return ENXIO;
+            break;
+    }
 }
 
 int nvidia_pci_attach(device_t dev)

--------------010408070600020605000904--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?3F5222D9.8020404>