On Sun, 24 Sep 2000, Alan Cox wrote: > Im waiting for someone to either explain why the changes should have caused > the problem and to fix them. > > Right now I dont see what is going on so Im not changing anything until I > understand what is up Hi Alan, Summary: outdated vidmem override causes problems because of a change to bttv_open to call find_vga correctly the first time the device is openned. Details: (written as I rambled through the problem) I've looked at the diff between 2.2.17 and 2.2.18pre9 wrt bttv.c, and the only thing that looks possibly a cause is that the fix to bttv_open to actually call find_vga when the device is openned is exposing a bug / problem with the video memory base selection with my graphics card. (Geforce 256) *checks some more* Okay, found a problem with my installation here - I have upgraded graphics cards from a TNT/2 to the Geforce and not changed the vidmem override setting. *sigh* The change in pre9 must expose this somehow - in a way that 17 final didn't. Ie, actually calling find_vga puts a non-zero value into the vidadr member of the win struct, and this enables various ioctls with what was an incorrect override address - hence getting blank windows and crashes. Putting the right value into vidmem has fixed the problem here. I'm just test compiling with a patch adding the Creative Labs Geforce 256 to the vidbases table in bttv.c, which will at least fix the logged message from bttv that it can't find the graphics card, and obviate the need for me to specify the vidmem manually...(though it doesn't help for owners of other video cards). bttv: PCI display adapter: <3>bttv: Unknown video memory base address. 01:00.0 VGA compatible controller: nVidia Corporation: Unknown device 0100 (rev 10) (prog-if 00 [VGA]) Subsystem: Creative Labs: Unknown device 102d Flags: bus master, 66Mhz, medium devsel, latency 248, IRQ 10 Memory at e0000000 (32-bit, non-prefetchable) Memory at d8000000 (32-bit, prefetchable) Capabilities: [60] Power Management version 1 Capabilities: [44] AGP version 2.0 01:00.0 Class 0300: 10de:0100 (rev 10) Subsystem: 1102:102d Flags: bus master, 66Mhz, medium devsel, latency 248, IRQ 10 Memory at e0000000 (32-bit, non-prefetchable) Memory at d8000000 (32-bit, prefetchable) Capabilities: [60] Power Management version 1 Capabilities: [44] AGP version 2.0 The d8000000 address is the video ram. I'm assuming that the vendor id is 0x10de, and the device id 0x0100, and making a guess that because the memory is the 2nd listed, I need PCI_BASE_ADDRESS_1 in the table too. I've CC'd Jens so he can add the entries to pci.h in a form he prefers. Best regards, Mark -- +-------------------------------------------------------------------------+ Mark Cooke The views expressed above are mine and are not Systems Programmer necessarily representative of university policy University Of Birmingham URL: http://www.sr.bham.ac.uk/~mpc/ +-------------------------------------------------------------------------+
--- linux/drivers/char/bttv.c.orig Sun Sep 24 18:56:31 2000 +++ linux/drivers/char/bttv.c Sun Sep 24 19:13:13 2000 @@ -2708,6 +2708,8 @@ { PCI_VENDOR_ID_TSENG, 0, "TSENG", PCI_BASE_ADDRESS_0}, { PCI_VENDOR_ID_NVIDIA_SGS, PCI_DEVICE_ID_NVIDIA_SGS_RIVA128, "Riva128", PCI_BASE_ADDRESS_1}, + { PCI_VENDOR_ID_NVIDIA, PCI_VENDOR_ID_NVIDIA_GEFORCE256, + "GeForce 256", PCI_BASE_ADDRESS_1}, };
--- linux/include/linux/pci.h.orig Fri Sep 22 01:34:44 2000 +++ linux/include/linux/pci.h Sun Sep 24 19:11:51 2000 @@ -732,6 +732,7 @@ #define PCI_DEVICE_ID_CERN_HIPPI_SRC 0x0022 #define PCI_VENDOR_ID_NVIDIA 0x10de +#define PCI_VENDOR_ID_NVIDIA_GEFORCE256 0x0100 #define PCI_VENDOR_ID_IMS 0x10e0 #define PCI_DEVICE_ID_IMS_8849 0x8849