9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
* [9fans] JVC Netbook works fine, except PCMCIA
@ 2009-12-30 13:54 Frederik Caulier
  2009-12-30 18:25 ` Tim Newsham
  2009-12-31  5:10 ` Dave Eckhardt
  0 siblings, 2 replies; 9+ messages in thread
From: Frederik Caulier @ 2009-12-30 13:54 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

Hello 9fans

Just wanted to let you know that Plan 9 runs fine (except for a
PCMCIA-related problem, see below) on my JVC MP-XP3 Netbook.

I installed Plan 9 using the latest ISO-Image ("Dec 14 2009") which I
downloaded yesterday.

System: JVC MP-XP3

Intel Pentium III (750 MHz)
SIS 630 with VGA, LAN* and onboard AC'97 sound (on chip it says "SIS
630 ST", RAM shares up to 64MB with VGA)
256 MB RAM (can be upgraded to more)
Ricoh 475 PCMCIA Controller (recognized on boot)
80 GB Fujitsu IDE-HDD (5200 RPM)
8,9" display with native resolution of 1024x600 pixels

(*LAN is recognized as "ns83815" on port d400/d4ff, but it's broken
because my predecessor plugged in a bad cable.)

The ps2 trackpoint and the three onboard mouse buttons work just fine
out of the box.

The following resolutions work with the VESA driver:

800x600x32
800x600x16
800x600x8

I tried using 1024x600x8 but it didn't work, rio complains about
something with the vgadb.

Is there a way how I can nevertheless use this resolution?


Right now I'm trying to use my D-Link DFE-690TXD PCMCIA-Card (Realtek
rtl8139) but I encounter some difficulties. According to the Wiki it
should be supported.

First problem:
------------------

% ip/ipconfig
ipconfig: /net/ipifc/clone: bind ether /net/ether0: '/net/ether0' cs:
file does not exist

Second problem:
----------------------

The system boots fine with the PCMCIA card in the slot only once, on
the following boot it always does the usual startup but then hangs at
"init: /bin/rc". (Note that it is not related to the device waiting
for a DHCP offer as I once waited a long time and still nothing
happened.) So I have to reboot, edit and save ANY setting in the BIOS
and then boot again, now the system will work again and boot with the
PCMCIA card.

% cat /n/9fat/plan.ini
bootfile=sdC0!9fat!9pcf
bootargs=local!#S/sdC0/fossil
bootdisk=local!#S/sdC0/fossil

pcmcia0=type=rtl8139 port=0x400 irq=10
ether0=rtl8139

# *debugload=1
# *noahciload=1
# [debug]
*nobiosload=1
*nodumpstack=1
*nomp=1

dmamode=ask
partition=new
mouseport=ps2
vgasize=800x600x32
monitor=vesa

Notes: Whether I change the port/irq, remove port/irq, remove the
complete pcmcia0= line doesn't change anything. Also, whether trying
with or without ether0=rtl8139 doesn't change anything.

The following is what I get on boot:

[...]
cpu0: 748MHz GenuineIntel Pentium III/Xon (cpuid: AX 0x06B1 DX 0x383F9FF)
ELCR: 08B0
#Y0: Ricoh 475 PCI/Cardbus brigde, 000DE000 intl 11
PCI.32.0.0 mem[1] 0e000000 512
rtl8139: port 0x400 in use	# Note: This always appears no matter what
I do in plan9.ini
ns83815: auto neg timed out
224M memory: 92M kernel data, 132M user, 507M swap
root is from (tcp, local)[local!#S/sdC0/fossil]:
[...]

% cat /dev/ioalloc
0	f dma
20	21 i8259.0
40	43 i8253
60	60 kbd
61	61 i8253.cntr2c
64	64 kbd
70	71 rtc/nvr
80	8f dma
a0	a1 i8259.1
d0	df dma
1f0	1f7 atacmd
2b0	2df vga
378	37a lpt0
3c0	3da vga
3e0	3e1 i82365.0
3f0	3f5 floppy
3f6	3f6 atactl
3f7	3f7 floppy
400	5ff cardbus # This is the concerned card.
fff	fff dummy
d400	d4ff ns83815

Notes: The card always appears on port 400 and the settings in
plan9.ini are ignored. For example, if I write port=0x380 in plan9.ini
this will still appear on port 400.

I found a few messages with similar issues on 9fans but they didn't
really help me.

http://marc.info/?l=9fans&w=2&r=1&s=realtek8139&q=b
http://marc.info/?l=9fans&w=2&r=1&s=pcmcia%2Fcardbus+rtl8139+support&q=b


Any ideas and suggestions on how to solve this are very much welcome!

Best regards,
F. Caulier

PS: Please tell me if you need any further information on the system.
(e.g. output of % ns)



^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [9fans] JVC Netbook works fine, except PCMCIA
  2009-12-30 13:54 [9fans] JVC Netbook works fine, except PCMCIA Frederik Caulier
@ 2009-12-30 18:25 ` Tim Newsham
  2009-12-31  5:10 ` Dave Eckhardt
  1 sibling, 0 replies; 9+ messages in thread
From: Tim Newsham @ 2009-12-30 18:25 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

> The following resolutions work with the VESA driver:
>
> 800x600x32
> 800x600x16
> 800x600x8
>
> I tried using 1024x600x8 but it didn't work, rio complains about
> something with the vgadb.
>
> Is there a way how I can nevertheless use this resolution?

Try editing /lib/vgadb and adding "xga=1024x600"

> Best regards,
> F. Caulier

Tim Newsham | www.thenewsh.com/~newsham | thenewsh.blogspot.com



^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [9fans] JVC Netbook works fine, except PCMCIA
  2009-12-30 13:54 [9fans] JVC Netbook works fine, except PCMCIA Frederik Caulier
  2009-12-30 18:25 ` Tim Newsham
@ 2009-12-31  5:10 ` Dave Eckhardt
  2009-12-31  5:38   ` erik quanstrom
  2009-12-31  5:51   ` Frederik Caulier
  1 sibling, 2 replies; 9+ messages in thread
From: Dave Eckhardt @ 2009-12-31  5:10 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

> pcmcia0=type=rtl8139 port=0x400 irq=10

Nope.  "pcmcia0" tells the kernel what kind of PCMCIA
bridge you have; since you have CardBus (which is better),
you shouldn't have one of those lines unless you need to
disable the CardBus driver and use the old PCMCIA code
instead.  One reason to do that, by the way, is that the
PCMCIA bridge driver accepts an IRQ override (for the
bridge itself) and the CardBus driver doesn't.  I have
one Sony Vaio whose BIOS sets *all* IRQ's to 9, which
results in sadness, so I use the PCMCIA driver instead
of the CardBus driver.

> ether0=rtl8139

This is also wrong.  You want "ether0=type=rtl8319".

Can you send us the output of "aux/pcmcia"?  Also of
"cat /dev/ioalloc"?

Dave Eckhardt



^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [9fans] JVC Netbook works fine, except PCMCIA
  2009-12-31  5:10 ` Dave Eckhardt
@ 2009-12-31  5:38   ` erik quanstrom
  2009-12-31  6:02     ` Frederik Caulier
  2009-12-31  5:51   ` Frederik Caulier
  1 sibling, 1 reply; 9+ messages in thread
From: erik quanstrom @ 2009-12-31  5:38 UTC (permalink / raw)
  To: 9fans

> > ether0=rtl8139
>
> This is also wrong.  You want "ether0=type=rtl8319".

good catch.  it should be "ether0=type=rtl8139"
though.  one should not need this oft mis-typed
line unless
- you wish to force the a particular ordering of controller
types.  say you want the rtl8139 to be the first controller
and, say, a 83815 to be the second.  i use this on some machines
to force the myricom card to be eth0.
- you need to specify more information, like an ea or
an irq.
- you're using ken's fileserver.

- erik



^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [9fans] JVC Netbook works fine, except PCMCIA
  2009-12-31  5:10 ` Dave Eckhardt
  2009-12-31  5:38   ` erik quanstrom
@ 2009-12-31  5:51   ` Frederik Caulier
  2010-01-01  1:58     ` Dave Eckhardt
  1 sibling, 1 reply; 9+ messages in thread
From: Frederik Caulier @ 2009-12-31  5:51 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

I appreciate your help very much.

On 12/31/09, Dave Eckhardt <davide+p9@cs.cmu.edu> wrote:
>> pcmcia0=type=rtl8139 port=0x400 irq=10
>
> Nope.  "pcmcia0" tells the kernel what kind of PCMCIA
> bridge you have; since you have CardBus (which is better),
> you shouldn't have one of those lines unless you need to
> disable the CardBus driver and use the old PCMCIA code
> instead.  One reason to do that, by the way, is that the
> PCMCIA bridge driver accepts an IRQ override (for the
> bridge itself) and the CardBus driver doesn't.  I have
> one Sony Vaio whose BIOS sets *all* IRQ's to 9, which
> results in sadness, so I use the PCMCIA driver instead
> of the CardBus driver.
>
>> ether0=rtl8139
>
> This is also wrong.  You want "ether0=type=rtl8319".

Ok, I completely removed the "pcmcia0=" entry and booted only with
"ether0=type=rtl8139" as you told me.

This is what I get on boot, note that the the change is that now I get
"rtl8139: port 0x400 in use" two times.

[...]
cpu0: 748MHz GenuineIntel Pentium III/Xon (cpuid: AX 0x06B1 DX 0x383F9FF)
ELCR: 08B0
#Y0: Ricoh 475 PCI/Cardbus brigde, 000DE000 intl 11
PCI.32.0.0 mem[1] 0e000000 512
rtl8139: port 0x400 in use
rtl8139: port 0x400 in use
ns83815: auto neg timed out
224M memory: 92M kernel data, 132M user, 507M swap
root is from (tcp, local)[local!#S/sdC0/fossil]:
[...]

I still get the same error message when I run ip/ipconfig.

> Can you send us the output of "aux/pcmcia"?  Also of
> "cat /dev/ioalloc"?

% aux/pcmcia
pcmcia: opening #y/pcm0attr: '#y/pcm0attr' file does not exist

% cat /dev/ioalloc
0       f dma
20      21 i8259.0
40      43 i8253
60      60 kbd
61      61 i8253.cntr2c
64      64 kbd
70      71 rtc/nvr
80      8f dma
a0      a1 i8259.1
d0      df dma
1f0     1f7 atacmd
2b0     2df vga
378     37a lpt0
3c0     3da vga
3e0     3e1 i82365.0
3f0     3f5 floppy
3f6     3f6 atactl
3f7     3f7 floppy
400     5ff cardbus # This is the concerned card.
fff     fff dummy
d400    d4ff ns83815

> Dave Eckhardt
Best regards,
F. Caulier



^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [9fans] JVC Netbook works fine, except PCMCIA
  2009-12-31  5:38   ` erik quanstrom
@ 2009-12-31  6:02     ` Frederik Caulier
  0 siblings, 0 replies; 9+ messages in thread
From: Frederik Caulier @ 2009-12-31  6:02 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

I just booted without any "ether0=" and "pcmcia0=" lines and the
problem persists.

Only change is that on boot I see "rtl8139: port 0x400 in use" only
once and not two times as I mentioned in my previous message.

Best regards,
F. Caulier

On 12/31/09, erik quanstrom <quanstro@coraid.com> wrote:
>> > ether0=rtl8139
>>
>> This is also wrong.  You want "ether0=type=rtl8319".
>
> good catch.  it should be "ether0=type=rtl8139"
> though.  one should not need this oft mis-typed
> line unless
> - you wish to force the a particular ordering of controller
> types.  say you want the rtl8139 to be the first controller
> and, say, a 83815 to be the second.  i use this on some machines
> to force the myricom card to be eth0.
> - you need to specify more information, like an ea or
> an irq.
> - you're using ken's fileserver.
>
> - erik
>
>



^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [9fans] JVC Netbook works fine, except PCMCIA
  2009-12-31  5:51   ` Frederik Caulier
@ 2010-01-01  1:58     ` Dave Eckhardt
  2010-01-09  5:21       ` Frederik Caulier
  0 siblings, 1 reply; 9+ messages in thread
From: Dave Eckhardt @ 2010-01-01  1:58 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

> % cat /dev/ioalloc
> [...]
> 400     5ff cardbus # This is the concerned card.

I think I've seen this before.  A year ago I was trying to get
a LinkSys pseudo-Tulip CardBus card working.  Before I gave up,
I ran into a situation where the CardBus driver was allocating
a hunk of I/O space for the card but the card was later unable
to use the space.  At that time I convinced myself that the
problem was in ioalloc(), around line 230 of devarch.c.  This
is what I did at the time, though I never submitted it as a
patch since I wasn't able to prove it was right by getting the
card to work, plus which I wasn't sure I was fully understanding
the code.

-  if(m->reserved && m->start == port && m->end == port + size) {
+  if(m->reserved && m->start == port && m->end >= port + size) {

Dave Eckhardt



^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [9fans] JVC Netbook works fine, except PCMCIA
  2010-01-01  1:58     ` Dave Eckhardt
@ 2010-01-09  5:21       ` Frederik Caulier
  0 siblings, 0 replies; 9+ messages in thread
From: Frederik Caulier @ 2010-01-09  5:21 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

Hello

I just recompiled the kernel with your suggested modification in line
239 of the /sys/src/9/pc/devarch.c file.

Good news:
The "port 0x400 in use" disappeared and the rtl8139 PC Card is now
correctly recognized as:
#l0: rtl8139: 10Mbps port 0x400 irq 11: 001b1159be56
(LEDs are active)

Bad news:
When booting the system with the rtl8139 PC Card plugged in the kernel
crashes on boot.

Here's what I get on boot when the card is plugged in:

[...]
cpu0: 748MHz GenuineIntel Pentium III/Xon (cpuid: AX 0x06B1 DX 0x383F9FF)
ELCR: 08B0
#Y0: Ricoh 475 PCI/Cardbus brigde, 000DE000 intl 11
PCI.32.0.0 mem[1] 0e000000 512
#l0: rtl8139: 10Mbps port 0x400 irq 11: 001b1159be56       # the said pc card
ns83815: auto neg timed out
224M memory: 92M kernel data, 132M user, 507M swap
cpu0: registers for *init* 1
FLAGS=10046 TRAP=0 ECODE=F0100674 PC=F0142306 SS=6FE3 USP=438
  AX 00010000  BX 00000000  CX F004B240  DX 00000000
  SI F041F008  DI 00000000  BP F041F008
  CS 0010  DS 0008  ES 0008 FS 0008  GS 0008
  CR0 80010039 CR2 00000000 CR3 00012000 CR4 000000d0
  MCA 00000000 MCT 00000000
  ur 0xf004d028 up 0xf041f008
dumpstack disabled
panic: divide error
panic: divide error
dumpstack disabled
cpu0: exciting

When booting the new, modified kernel without the rtl8139 pc card
being plugged in the system boots just fine.

Help on how to fix this is very welcome.

Best regards,
F. Caulier



^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [9fans] JVC Netbook works fine, except PCMCIA
       [not found] <<Pine.BSI.4.64.0912300824050.5454@malasada.lava.net>
@ 2009-12-31  3:31 ` erik quanstrom
  0 siblings, 0 replies; 9+ messages in thread
From: erik quanstrom @ 2009-12-31  3:31 UTC (permalink / raw)
  To: 9fans

On Wed Dec 30 13:30:12 EST 2009, newsham@lava.net wrote:
> > The following resolutions work with the VESA driver:
> >
> > 800x600x32
> > 800x600x16
> > 800x600x8
> >
> > I tried using 1024x600x8 but it didn't work, rio complains about
> > something with the vgadb.
> >
> > Is there a way how I can nevertheless use this resolution?
>
> Try editing /lib/vgadb and adding "xga=1024x600"

i'm pretty sure that vesa gets its modes from the vesa bios.
i think the setting monitor=vesa might solve this problem.

- erik



^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2010-01-09  5:21 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-12-30 13:54 [9fans] JVC Netbook works fine, except PCMCIA Frederik Caulier
2009-12-30 18:25 ` Tim Newsham
2009-12-31  5:10 ` Dave Eckhardt
2009-12-31  5:38   ` erik quanstrom
2009-12-31  6:02     ` Frederik Caulier
2009-12-31  5:51   ` Frederik Caulier
2010-01-01  1:58     ` Dave Eckhardt
2010-01-09  5:21       ` Frederik Caulier
     [not found] <<Pine.BSI.4.64.0912300824050.5454@malasada.lava.net>
2009-12-31  3:31 ` erik quanstrom

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).