Subject: Re: X on Asus M6000
To: None <port-i386@netbsd.org>
From: Ray Phillips <r.phillips@uq.edu.au>
List: port-i386
Date: 09/28/2007 19:02:34
Thanks for replying Piotr.

>Please find /usr/src/sys/dev/pci/agp_i810.c, edit it and find such block for
>830/855GM/915G/other. Please comment such block as I did below and compile the
>kernel. I think that your choice is to comment the section for i915 (but I'm
>not sure).

I commented out those lines in all three sections:

# diff -u agp_i810.c.orig agp_i810.c
--- agp_i810.c.orig     2007-09-28 12:41:15.000000000 +1000
+++ agp_i810.c  2007-09-28 13:57:41.000000000 +1000
@@ -289,11 +289,11 @@
                 case AGP_I830_GCC1_GMS_STOLEN_8192:
                         isc->stolen = (8192 - 132) * 1024 / 4096;
                         break;
-               default:
+/*             default:
                         isc->stolen = 0;
                         aprint_error(
                             ": unknown memory configuration, disabling\n");
-                       agp_generic_detach(sc);
+                       agp_generic_detach(sc);*/
                         return EINVAL;
                 }
                 if (isc->stolen > 0) {
@@ -331,11 +331,11 @@
                 case AGP_I855_GCC1_GMS_STOLEN_32M:
                         isc->stolen = (32768 - 132) * 1024 / 4096;
                         break;
-               default:
+/*             default:
                         isc->stolen = 0;
                         aprint_error(
                             ": unknown memory configuration, disabling\n");
-                       agp_generic_detach(sc);
+                       agp_generic_detach(sc);*/
                         return EINVAL;
                 }
                 if (isc->stolen > 0) {
@@ -367,11 +367,11 @@
                 case AGP_I915_GCC1_GMS_STOLEN_8M:
                         isc->stolen = (8192 - 260) * 1024 / 4096;
                         break;
-               default:
+/*             default:
                         isc->stolen = 0;
                         aprint_error(
                             ": unknown memory configuration, disabling\n");
-                       agp_generic_detach(sc);
+                       agp_generic_detach(sc);*/
                         return EINVAL;
                 }
                 if (isc->stolen > 0) {
#


>And please note, that this block comes from 4.0_RC1, so in 3.1 sources it may
>vary a bit.

Those parts of agp_i810.c are identical in 3.1 and 4.0_RC1.

How come you didn't comment out the 'return EINVAL;' lines too--they 
can't be executed once the others have been commented out can they? 
Perhaps my C is rustier than I thought and they can be.

I've appended the hacked kernel's dmesg output to this email.

Unfortunately, booting from it and using the i810 driver instead of 
vesa in /etc/X11/XF86Config produced a black screen when startx was 
executed.


Ray



# dmesg
NetBSD 3.1 (GENERIC.agp-hack) #3: Fri Sep 28 14:00:08 EST 2007
 
root@yicai.jkmrc.uq.edu.au:/usr/src/sys/arch/i386/compile/GENERIC.agp-hack
total memory = 495 MB
avail memory = 476 MB
BIOS32 rev. 0 found at 0xf0010
mainbus0 (root)
cpu0 at mainbus0: (uniprocessor)
cpu0: Intel Pentium M (Dothan) (686-class), 1862.10 MHz, id 0x6d8
cpu0: features afe9fbff<FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR>
cpu0: features afe9fbff<PGE,MCA,CMOV,PAT,CFLUSH,DS,ACPI,MMX>
cpu0: features afe9fbff<FXSR,SSE,SSE2,SS,TM,SBF>
cpu0: features2 180<EST,TM2>
cpu0: "Intel(R) Pentium(R) M processor 1.86GHz"
cpu0: I-cache 32 KB 64B/line 8-way, D-cache 32 KB 64B/line 8-way
cpu0: L2 cache 2 MB 64B/line 8-way
cpu0: using thermal monitor 2
cpu0: Enhanced SpeedStep (1308 mV) 1867 MHz
cpu0: Enhanced SpeedStep frequencies available (MHz): 1867 1600 1333 1067 800
cpu0: 64 page colors
pci0 at mainbus0 bus 0: configuration mode 1
pci0: i/o space, memory space enabled, rd/line, rd/mult, wr/inv ok
pchb0 at pci0 dev 0 function 0
pchb0: Intel 82915PM/GM/GMS,82910GML Host Bridge (rev. 0x03)
agp0 at pchb0: aperture at 0xd0000000, size 0x10000000
ppb0 at pci0 dev 1 function 0: Intel 82915PM/GM PCI Express Bridge (rev. 0x03)
pci1 at ppb0 bus 3
pci1: no spaces enabled!
vga1 at pci0 dev 2 function 0: Intel 82915GM/GMS Integrated Graphics 
Device (rev. 0x03)
wsdisplay0 at vga1 kbdmux 1: console (80x25, vt100 emulation)
wsmux1: connecting to wsdisplay0
Intel 82915GM/GMS IGD Companion (miscellaneous display, revision 
0x03) at pci0 dev 2 function 1 not configured
azalia0 at pci0 dev 27 function 0: Generic High Definition Audio Controller
azalia0: interrupting at irq 5
azalia0: host: Intel 82801FB/FR High Definition Audio Controller (rev. 4)
azalia0: host: High Definition Audio rev. 1.0
uhci0 at pci0 dev 29 function 0: Intel 82801FB/FR USB UHCI Controller 
(rev. 0x04)
uhci0: interrupting at irq 4
usb0 at uhci0: USB revision 1.0
uhub0 at usb0
uhub0: Intel UHCI root hub, class 9/0, rev 1.00/1.00, addr 1
uhub0: 2 ports with 2 removable, self powered
uhci1 at pci0 dev 29 function 1: Intel 82801FB/FR USB UHCI Controller 
(rev. 0x04)
uhci1: interrupting at irq 5
usb1 at uhci1: USB revision 1.0
uhub1 at usb1
uhub1: Intel UHCI root hub, class 9/0, rev 1.00/1.00, addr 1
uhub1: 2 ports with 2 removable, self powered
uhci2 at pci0 dev 29 function 2: Intel 82801FB/FR USB UHCI Controller 
(rev. 0x04)
uhci2: interrupting at irq 6
usb2 at uhci2: USB revision 1.0
uhub2 at usb2
uhub2: Intel UHCI root hub, class 9/0, rev 1.00/1.00, addr 1
uhub2: 2 ports with 2 removable, self powered
uhci3 at pci0 dev 29 function 3: Intel 82801FB/FR USB UHCI Controller 
(rev. 0x04)
uhci3: interrupting at irq 5
usb3 at uhci3: USB revision 1.0
uhub3 at usb3
uhub3: Intel UHCI root hub, class 9/0, rev 1.00/1.00, addr 1
uhub3: 2 ports with 2 removable, self powered
ehci0 at pci0 dev 29 function 7: Intel 82801FB/FR USB EHCI Controller 
(rev. 0x04)
ehci0: interrupting at irq 4
ehci0: BIOS has given up ownership
ehci0: EHCI version 1.0
ehci0: companion controllers, 2 ports each: uhci0 uhci1 uhci2 uhci3
usb4 at ehci0: USB revision 2.0
uhub4 at usb4
uhub4: Intel EHCI root hub, class 9/0, rev 2.00/1.00, addr 1
uhub4: single transaction translator
uhub4: 8 ports with 8 removable, self powered
ppb1 at pci0 dev 30 function 0: Intel 82801BAM Hub-PCI Bridge (rev. 0xd4)
pci2 at ppb1 bus 1
pci2: i/o space, memory space enabled
skc0 at pci2 dev 0 function 0: irq 6
skc0: interrupt moderation is 0 us
skc0: Marvell Yukon Lite Gigabit Ethernet rev. A3(0x7)
sk0 at skc0 port A: Ethernet address 00:11:d8:7d:9d:1d
makphy0 at sk0 phy 0: Marvell 88E1011 Gigabit PHY, rev. 5
makphy0: 10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, 1000baseT, 
1000baseT-FDX, auto
cbb0 at pci2 dev 1 function 0: Ricoh 5C476 PCI-CardBus bridge (rev. 0xb3)
cbb0: NOT USED because of unconfigured interrupt
Ricoh 5C552 PCI-CardBus bridge/Firewire (Firewire serial bus, 
interface 0x10, revision 0x08) at pci2 dev 1 function 1 not configured
Ricoh product 0x0822 (system subclass 0x05, revision 0x17) at pci2 
dev 1 function 2 not configured
Ricoh product 0x0592 (miscellaneous system, revision 0x08) at pci2 
dev 1 function 3 not configured
Ricoh product 0x0852 (miscellaneous system, revision 0x03) at pci2 
dev 1 function 4 not configured
iwi0 at pci2 dev 2 function 0: Intel PRO/Wireless LAN 2200BG Mini-PCI 
Adapter (rev. 0x05)
iwi0: interrupting at irq 5
iwi0: 802.11 address 00:0e:35:c8:5d:35
iwi0: 11b rates: 1Mbps 2Mbps 5.5Mbps 11Mbps
iwi0: 11g rates: 1Mbps 2Mbps 5.5Mbps 11Mbps 6Mbps 9Mbps 12Mbps 18Mbps 
24Mbps 36Mbps 48Mbps 54Mbps
pcib0 at pci0 dev 31 function 0
pcib0: Intel product 0x2641 (rev. 0x04)
piixide0 at pci0 dev 31 function 1
piixide0: Intel 82801FB IDE Controller (ICH6) (rev. 0x04)
piixide0: bus-master DMA support present
piixide0: primary channel configured to compatibility mode
piixide0: primary channel interrupting at irq 14
atabus0 at piixide0 channel 0
piixide0: secondary channel configured to compatibility mode
piixide0: secondary channel interrupting at irq 15
atabus1 at piixide0 channel 1
isa0 at pcib0
lpt0 at isa0 port 0x378-0x37b irq 7
com1 at isa0 port 0x2f8-0x2ff irq 3: ns16550a, working fifo
pckbc0 at isa0 port 0x60-0x64
pckbd0 at pckbc0 (kbd slot)
pckbc0: using irq 1 for kbd slot
wskbd0 at pckbd0: console keyboard, using wsdisplay0
pms0 at pckbc0 (aux slot)
pckbc0: using irq 12 for aux slot
wsmouse0 at pms0 mux 0
pcppi0 at isa0 port 0x61
midi0 at pcppi0: PC speaker
sysbeep0 at pcppi0
isapnp0 at isa0 port 0x279: ISA Plug 'n Play device support
npx0 at isa0 port 0xf0-0xff: using exception 16
pcic0 at isa0 port 0x3e0-0x3e1 iomem 0xd0000-0xdffff irq
pcic0: controller 0 (Intel 82365SL Revision 1) has socket A only
pcmcia0 at pcic0 controller 0 socket 0
isapnp0: no ISA Plug 'n Play devices found
azalia0: codec[0]: Realtek ALC880 (rev. 5.0)
azalia0: codec[0]: High Definition Audio rev. 0.9
azalia0: playback: max channels=8, encodings=1<PCM>
azalia0: playback: PCM 
formats=e0560<24bit,20bit,16bit,192kHz,96kHz,48kHz,44.1kHz>
azalia0: recording: max channels=4, encodings=1<PCM>
azalia0: recording: PCM formats=60160<20bit,16bit,96kHz,48kHz,44.1kHz>
azalia0: codec[1]: 0x14f1/0x2bfa (rev. 0.0)
azalia0: codec[1]: High Definition Audio rev. 0.9
azalia0: codec[1]: No support for modem function groups
azalia0: codec[1] has no audio function groups
audio0 at azalia0: full duplex, independent
pcic0: controller 0 detecting irqs with mask 0xdeb8: none
pcic0: no available irq; polling for socket events
Kernelized RAIDframe activated
atapibus0 at atabus0: 2 targets
cd0 at atapibus0 drive 1: <TSSTcorpCD/DVDW TS-L532A, Z4GL701000, 
TC51> cdrom removable
cd0: 32-bit data port
cd0: drive supports PIO mode 4, DMA mode 2, Ultra-DMA mode 2 (Ultra/33)
wd0 at atabus0 drive 0: <IC25N060ATMR04-0>
wd0: drive supports 16-sector PIO transfers, LBA48 addressing
wd0: 57231 MB, 116280 cyl, 16 head, 63 sec, 512 bytes/sect x 117210240 sectors
wd0: 32-bit data port
wd0: drive supports PIO mode 4, DMA mode 2, Ultra-DMA mode 5 (Ultra/100)
wd0(piixide0:0:0): using PIO mode 4, Ultra-DMA mode 5 (Ultra/100) (using DMA)
cd0(piixide0:0:1): using PIO mode 4, Ultra-DMA mode 2 (Ultra/33) (using DMA)
boot device: wd0
root on wd0a dumps on wd0b
root file system type: ffs
uhidev0 at uhub0 port 1 configuration 1 interface 0
uhidev0: Logitech Optical USB Mouse, rev 2.00/3.40, addr 2, iclass 3/1
ums0 at uhidev0: 3 buttons and Z dir.
wsmouse1 at ums0 mux 0
skc0: interrupt moderation is 100 us
wsdisplay0: screen 1 added (80x25, vt100 emulation)
wsdisplay0: screen 2 added (80x25, vt100 emulation)
wsdisplay0: screen 3 added (80x25, vt100 emulation)
wsdisplay0: screen 4 added (80x25, vt100 emulation)
#