Re: ati(4) not working on 4.4-beta sparc64

2008-08-05 Thread Jasper Valentijn
2008/8/5 Mark Kettenis <[EMAIL PROTECTED]>:
> Can you try building a kernel with the attached diff?
>
> Index: vgafb.c
> ===
> RCS file: /cvs/src/sys/arch/sparc64/dev/vgafb.c,v
> retrieving revision 1.52
> diff -u -p -r1.52 vgafb.c
> --- vgafb.c 23 Mar 2008 12:10:53 -  1.52
> +++ vgafb.c 4 Aug 2008 22:07:27 -
> @@ -412,13 +412,13 @@ vgafb_mmap(v, off, prot)
>if (sc->sc_mmio_size == 0)
>return (-1);
>
> -   if (off >= sc->sc_mem_addr &&
> +   if (off >= (sc->sc_mem_addr & ~PGOFSET) &&
>off < (sc->sc_mem_addr + sc->sc_mem_size))
>return (bus_space_mmap(sc->sc_mem_t,
>sc->sc_mem_addr, off - sc->sc_mem_addr,
>prot, BUS_SPACE_MAP_LINEAR));
>
> -   if (off >= sc->sc_mmio_addr &&
> +   if (off >= (sc->sc_mmio_addr & ~PGOFSET) &&
>off < (sc->sc_mmio_addr + sc->sc_mmio_size))
>return (bus_space_mmap(sc->sc_mem_t,
>sc->sc_mmio_addr, off - sc->sc_mmio_addr,
>

Still a fatal server error.

$ tail /var/log/Xorg.0.log
[13] -1 0   0x00c0 - 0x00c7 (0x8) IX[B]E
[14] -1 0   0xff00 - 0x (0x100) IX[B](B)
[15] 0  0   0x03b0 - 0x03bb (0xc) IS[B]
[16] 0  0   0x03c0 - 0x03df (0x20) IS[B]
(II) Setting vga for screen 0.
(**) MACH64(0): Depth 16, (--) framebuffer bpp 16
(==) MACH64(0): Using XAA acceleration architecture

Fatal server error:
xf86MapVidMem: could not mmap screen [s=2000,a=e000] (Invalid argument)

Anything else I can try or should provide?



Re: ati(4) not working on 4.4-beta sparc64

2008-08-04 Thread Mark Kettenis
Can you try building a kernel with the attached diff?

Index: vgafb.c
===
RCS file: /cvs/src/sys/arch/sparc64/dev/vgafb.c,v
retrieving revision 1.52
diff -u -p -r1.52 vgafb.c
--- vgafb.c 23 Mar 2008 12:10:53 -  1.52
+++ vgafb.c 4 Aug 2008 22:07:27 -
@@ -412,13 +412,13 @@ vgafb_mmap(v, off, prot)
if (sc->sc_mmio_size == 0)
return (-1);
 
-   if (off >= sc->sc_mem_addr &&
+   if (off >= (sc->sc_mem_addr & ~PGOFSET) &&
off < (sc->sc_mem_addr + sc->sc_mem_size))
return (bus_space_mmap(sc->sc_mem_t,
sc->sc_mem_addr, off - sc->sc_mem_addr,
prot, BUS_SPACE_MAP_LINEAR));
 
-   if (off >= sc->sc_mmio_addr &&
+   if (off >= (sc->sc_mmio_addr & ~PGOFSET) &&
off < (sc->sc_mmio_addr + sc->sc_mmio_size))
return (bus_space_mmap(sc->sc_mem_t,
sc->sc_mmio_addr, off - sc->sc_mmio_addr,



Re: ati(4) not working on 4.4-beta sparc64

2008-08-03 Thread Jasper Valentijn
2008/8/3 Mark Kettenis <[EMAIL PROTECTED]>:
>> Hey misc@,
>>
>> I seem to be unable to get accelerated X running on my old ultra 5,
>> unaccelerated just works(tm).
>> Am I missing something?
>> Did I find something?
>
> Jasper,
>
> Can you post the output of pcidump -v for that Ultra 5?
>
Sure thing.

0:1:0: Sun Simba PCI-PCI
0x: Vendor ID: 108e Product ID: 5000
0x0004: Command: 0147 Status ID: 02a0
0x0008: Class: 06 Subclass: 04 Interface: 00 Revision: 11
0x000c: BIST: 00 Header Type: 81 Latency Timer: 28 Cache Line Size: 10
0x0010: 
0x0014: 
0x0018: Primary Bus: 0 Secondary Bus: 2 Subordinate Bus: 255
Secondary Latency Timer: 28
0x001c: I/O Base: 00 I/O Limit: 00 Secondary Status: 0280
0x0020: Memory Base:  Memory Limit: 
0x0024: Prefetch Memory Base:  Prefetch Memory Limit: 
0x0028: Prefetch Memory Base Upper 32 Bits: 
0x002c: Prefetch Memory Limit Upper 32 Bits: 
0x0030: I/O Base Upper 16 Bits:  I/O Limit Upper 16 Bits: 
0x0038: Expansion ROM Base Address: 
0x003c: Interrupt Pin: 00 Line: 00 Bridge Control: 0002
0:1:1: Sun Simba PCI-PCI
0x: Vendor ID: 108e Product ID: 5000
0x0004: Command: 0147 Status ID: 02a0
0x0008: Class: 06 Subclass: 04 Interface: 00 Revision: 11
0x000c: BIST: 00 Header Type: 81 Latency Timer: 28 Cache Line Size: 10
0x0010: 
0x0014: 
0x0018: Primary Bus: 0 Secondary Bus: 1 Subordinate Bus: 1
Secondary Latency Timer: 28
0x001c: I/O Base: 00 I/O Limit: 00 Secondary Status: 0280
0x0020: Memory Base:  Memory Limit: 
0x0024: Prefetch Memory Base:  Prefetch Memory Limit: 
0x0028: Prefetch Memory Base Upper 32 Bits: 
0x002c: Prefetch Memory Limit Upper 32 Bits: 
0x0030: I/O Base Upper 16 Bits:  I/O Limit Upper 16 Bits: 
0x0038: Expansion ROM Base Address: 
0x003c: Interrupt Pin: 00 Line: 00 Bridge Control: 0002
1:1:0: Sun PCIO EBus2
0x: Vendor ID: 108e Product ID: 1000
0x0004: Command: 0146 Status ID: 0280
0x0008: Class: 06 Subclass: 80 Interface: 00 Revision: 01
0x000c: BIST: 00 Header Type: 80 Latency Timer: 52 Cache Line Size: 40
0x0010: BAR mem 32bit addr: 0xf000
0x0014: BAR mem 32bit addr: 0xf100
0x0018: BAR empty ()
0x001c: BAR empty ()
0x0020: BAR empty ()
0x0024: BAR empty ()
0x0028: Cardbus CIS: 
0x002c: Subsystem Vendor ID:  Product ID: 
0x0030: Expansion ROM Base Address: e000
0x0038: 
0x003c: Interrupt Pin: 00 Line: 00 Min Gnt: 0a Max Lat: 19
1:1:1: Sun HME
0x: Vendor ID: 108e Product ID: 1001
0x0004: Command: 0046 Status ID: 0280
0x0008: Class: 02 Subclass: 00 Interface: 00 Revision: 01
0x000c: BIST: 00 Header Type: 80 Latency Timer: 52 Cache Line Size: 40
0x0010: BAR mem 32bit addr: 0xe000
0x0014: BAR empty ()
0x0018: BAR empty ()
0x001c: BAR empty ()
0x0020: BAR empty ()
0x0024: BAR empty ()
0x0028: Cardbus CIS: 
0x002c: Subsystem Vendor ID:  Product ID: 
0x0030: Expansion ROM Base Address: e100
0x0038: 
0x003c: Interrupt Pin: 00 Line: 00 Min Gnt: 0a Max Lat: 05
1:2:0: ATI Mach64 GT
0x: Vendor ID: 1002 Product ID: 4754
0x0004: Command: 0082 Status ID: 0280
0x0008: Class: 03 Subclass: 00 Interface: 00 Revision: 9a
0x000c: BIST: 00 Header Type: 00 Latency Timer: 42 Cache Line Size: 40
0x0010: BAR mem 32bit addr: 0xe100
0x0014: BAR io addr: 0xff00
0x0018: BAR mem 32bit addr: 0xf000
0x001c: BAR empty ()
0x0020: BAR empty ()
0x0024: BAR empty ()
0x0028: Cardbus CIS: 
0x002c: Subsystem Vendor ID:  Product ID: 
0x0030: Expansion ROM Base Address: e102
0x0038: 
0x003c: Interrupt Pin: 01 Line: 02 Min Gnt: 08 Max Lat: 00
1:3:0: CMD Technology PCI0646
0x: Vendor ID: 1095 Product ID: 0646
0x0004: Command: 0045 Status ID: 0280
0x0008: Class: 01 Subclass: 01 Interface: 8f Revision: 03
0x000c: BIST: 00 Header Type: 00 Latency Timer: 10 Cache Line Size: 00
0x0010: BAR io addr: 0x00c0
0x0014: BAR io addr: 0x00c8
0x0018: BAR io addr: 0x00c00010
0x001c: BAR io addr: 0x00c00018
0x0020: BAR io addr: 0x00c00020
0x0024: BAR empty ()
0x0028: Cardbus CIS: 
0x002c: Subsystem Vendor ID: 1095 Product ID: 0646

Re: ati(4) not working on 4.4-beta sparc64

2008-08-03 Thread Jasper Valentijn
2008/8/3 Matthieu Herrb <[EMAIL PROTECTED]>:
> On Sun, Aug 3, 2008 at 3:38 PM, Jasper Valentijn
> <[EMAIL PROTECTED]> wrote:
>> Hey misc@,
>>
>> I seem to be unable to get accelerated X running on my old ultra 5,
>
> Did you set machdep.allowaperture in /etc/sysctl.conf?
>

$ sysctl machdep.allowaperture
machdep.allowaperture=1

It was set during the install so yes.

My first thought was I needed to set it at 2. But then I saw it wasn't
available on sparc64.

-- 
"We spend the first twelve months of our children's lives teaching
them to walk and talk and the next twelve telling them to sit down and
shut up."



Re: ati(4) not working on 4.4-beta sparc64

2008-08-03 Thread Mark Kettenis
> Hey misc@,
>
> I seem to be unable to get accelerated X running on my old ultra 5,
> unaccelerated just works(tm).
> Am I missing something?
> Did I find something?

Jasper,

Can you post the output of pcidump -v for that Ultra 5?

Thanks,

Mark



Re: ati(4) not working on 4.4-beta sparc64

2008-08-03 Thread Matthieu Herrb
On Sun, Aug 3, 2008 at 3:38 PM, Jasper Valentijn
<[EMAIL PROTECTED]> wrote:
> Hey misc@,
>
> I seem to be unable to get accelerated X running on my old ultra 5,

Did you set machdep.allowaperture in /etc/sysctl.conf?

-- 
Matthieu Herrb



ati(4) not working on 4.4-beta sparc64

2008-08-03 Thread Jasper Valentijn
Hey misc@,

I seem to be unable to get accelerated X running on my old ultra 5,
unaccelerated just works(tm).
Am I missing something?
Did I find something?

I hope it helps.

Thanks in advance for any hints besides buying new hardware.

Jasper



Xorg.0.log
(WW) OS did not count PCI devices, guessing wildly
(--) Using wscons driver

X.Org X Server 1.4.2
Release Date: 11 June 2008
X Protocol Version 11, Revision 0
Build Operating System: OpenBSD 4.4 sparc64
Current Operating System: OpenBSD sparc.thuis.nl 4.4 GENERIC#1702 sparc64
Build Date: 30 July 2008  08:24:46AM

Before reporting problems, check http://wiki.x.org
to make sure that you have the latest version.
Module Loader present
Markers: (--) probed, (**) from config file, (==) default setting,
(++) from command line, (!!) notice, (II) informational,
(WW) warning, (EE) error, (NI) not implemented, (??) unknown.
(==) Log file: "/var/log/Xorg.0.log", Time: Sun Aug  3 14:35:52 2008
(==) Using config file: "/etc/X11/xorg.conf"
(==) ServerLayout "wsfb"
(**) |-->Screen "Screen0" (0)
(**) |   |-->Monitor "Monitor"
(**) |   |-->Device "Card0"
(**) |-->Input Device "commouse0"
(**) |-->Input Device "Keyboard0"
(==) Automatically adding devices
(==) Automatically enabling devices
(WW) The directory "/usr/X11R6/lib/X11/fonts/CID/" does not exist.
Entry deleted from font path.
(WW) The directory "/usr/local/lib/X11/fonts/ghostscript/" does not exist.
Entry deleted from font path.
(==) Including the default font path
/usr/X11R6/lib/X11/fonts/misc/,/usr/X11R6/lib/X11/fonts/TTF/,/usr/X11R6/lib/X11/fonts/OTF,/usr/X11R6/lib/X11/fonts/Type1/,/usr/X11R6/lib/X11/fonts/100dpi/,/usr/X11R6/lib/X11/fonts/75dpi/.
(**) FontPath set to:
/usr/X11R6/lib/X11/fonts/misc/,
/usr/X11R6/lib/X11/fonts/Type1/,
/usr/X11R6/lib/X11/fonts/75dpi/:unscaled,
/usr/X11R6/lib/X11/fonts/misc/,
/usr/X11R6/lib/X11/fonts/TTF/,
/usr/X11R6/lib/X11/fonts/OTF,
/usr/X11R6/lib/X11/fonts/Type1/,
/usr/X11R6/lib/X11/fonts/100dpi/,
/usr/X11R6/lib/X11/fonts/75dpi/
(**) RgbPath set to "/usr/X11R6/lib/X11/rgb"
(==) ModulePath set to "/usr/X11R6/lib/modules"
(II) Loader magic: 0x4b8178
(II) Module ABI versions:
X.Org ANSI C Emulation: 0.3
X.Org Video Driver: 2.0
X.Org XInput driver : 2.0
X.Org Server Extension : 0.3
X.Org Font Renderer : 0.5
(II) Loader running on openbsd
(II) LoadModule: "pcidata"
(II) Loading /usr/X11R6/lib/modules//libpcidata.so
(II) Module pcidata: vendor="X.Org Foundation"
compiled for 1.4.2, module version = 1.0.0
ABI class: X.Org Video Driver, version 2.0
(II) PCI: PCI scan (all values are in hex)
(II) PCI: 00:01:0: chip 108e,5000 card , rev 11 class 06,04,00 hdr 81
(II) PCI: 00:01:1: chip 108e,5000 card , rev 11 class 06,04,00 hdr 81
(II) PCI: 01:01:0: chip 108e,1000 card , rev 01 class 06,80,00 hdr 80
(II) PCI: 01:01:1: chip 108e,1001 card , rev 01 class 02,00,00 hdr 80
(II) PCI: 01:02:0: chip 1002,4754 card , rev 9a class 03,00,00 hdr 00
(II) PCI: 01:03:0: chip 1095,0646 card 1095,0646 rev 03 class 01,01,8f hdr 00
(II) PCI: End of PCI scan
(II) PCI-to-PCI bridge:
(II) Bus 2: bridge is at (0:1:0), (0,2,255), BCTRL: 0x0002 (VGA_EN is cleared)
(II) PCI-to-PCI bridge:
(II) Bus 1: bridge is at (0:1:1), (0,1,1), BCTRL: 0x0002 (VGA_EN is cleared)
(II) Host-to-PCI bridge:
(II) Bus 0: bridge is at (0:0:0), (0,0,0), BCTRL: 0x0008 (VGA_EN is set)
(II) Bus 0 I/O range:
[0] -1  0   0x - 0x (0x1) IX[B]
(II) Bus 0 non-prefetchable memory range:
[0] -1  0   0x - 0x (0x1) MX[B]
(II) Bus 0 prefetchable memory range:
[0] -1  0   0x - 0x (0x1) MX[B]
(--) PCI:*(1:2:0) ATI Technologies Inc 3D Rage I/II 215GT [Mach64 GT]
rev 154, Mem @ 0xe100/24, 0xf000/12, I/O @ 0xff00/8, BIOS
@ 0xe102/17
(II) Addressable bus resource ranges are
[0] -1  0   0x - 0x (0x1) MX[B]
[1] -1  0   0x - 0x (0x1) IX[B]
(II) OS-reported resource ranges:
(II) Active PCI resource ranges:
[0] -1  0   0xe000 - 0x (0x2000) MX[B]E
[1] -1  0   0xf100 - 0xf1ff (0x100) MX[B]E
[2] -1  0   0xf000 - 0x (0x1000) MX[B]E
[3] -1  0   0xe102 - 0xe103 (0x2) MX[B](B)
[4] -1  0   0xf000 - 0x (0x1000) MX[B](B)
[5] -1  0   0xe100 - 0xe1ff (0x100) MX[B](B)
[6] -1  0   0x00c00020 - 0x00c0003f (0x20) IX[B]E
[7] -1  0   0x00c00018 - 0x00c0001f (0x8) IX[B]E
[8] -1  0   0x00c00010 - 0x00c0001f (0x10) IX[B]E
[9] -1  0   0x00c8 - 0x00cf (0x8) IX[B]E
[10] -1 0   0x00c0 - 0x00c000ff (0x100) IX[B]E
[11] -1 0   0xff00 - 0x (