linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
* PCMCIA Modem/Serial Cards and MPC8xx?
@ 2003-08-26 10:40 Steven Scholz
  2003-08-26 11:14 ` Magnus Damm
  2003-08-27 10:37 ` Wolfgang Denk
  0 siblings, 2 replies; 9+ messages in thread
From: Steven Scholz @ 2003-08-26 10:40 UTC (permalink / raw)
  To: LinuxPPC


Hi there,

is someone using a PCMCIA Modem or Serial Port card with an MPC8xx system?

I build a kernel for a TQM860L based board enabeling CONFIG_SERIAL=y
as the PCMCIA HowTo states. (I also have CONFIG_SERIAL_CONSOLE=y). But
while booting (or insmod serial.o) I get :

CPM UART driver version 0.04
ttyS0 on SMC1 at 0x0280, BRG1
ttyS1 on SMC2 at 0x0380, BRG2
pty: 256 Unix98 ptys configured
Serial driver version 5.05c (2001-07-08) with no serial options enabled
Oops: kernel access of bad area, sig: 11
NIP: C009FA6C XER: 00000000 LR: C00A4174 SP: C01D7E80 REGS: c01d7dd0
TRAP: 0300    Not tainted
MSR: 00001032 EE: 0 PR: 0 FP: 0 ME: 1 IR/DR: 11
DAR: 800003F9, DSISR: 00000469
TASK = c01d6000[1] 'swapper' Last syscall: 120
last math 00000000 last altivec 00000000
GPR00: 00000000 C01D7E80 C01D6000 C01D7E88 00000001 00000000 C01CC3D8
000003F8
GPR08: 00000000 800003F9 00000000 00000000 00000001 100B0020 C00A37C8
C00A301C
GPR16: C00A1B68 C00A2834 C00A3138 C009FC10 C009FB84 C00A2CAC C00A1C38
C00A1BB0
GPR24: C00A28BC C00A1AE8 C00A1AD0 C0151FD8 C0151FD8 C017C130 C017C1F4
C01D7E88
Call backtrace:
C000FE44 C0161A00 C015B588 C015B5D0 C000227C C0004BA0
Kernel panic: Attempted to kill init!

Backtrace is:
0xc000fe44 -- 0xc000fd78 + 0x00cc   release_console_sem
0xc0161a00 -- 0xc0161630 + 0x03d0   rs_init
0xc015b588 -- 0xc015b558 + 0x0030   do_initcalls
0xc015b5d0 -- 0xc015b5a8 + 0x0028   do_basic_setup
0xc000227c -- 0xc0002268 + 0x0014   init
0xc0004ba0 -- 0xc0004b74 + 0x002c   kernel_thread

Any ideas?

Thanks a million!

Steven


** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/

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

* Re: PCMCIA Modem/Serial Cards and MPC8xx?
  2003-08-26 10:40 PCMCIA Modem/Serial Cards and MPC8xx? Steven Scholz
@ 2003-08-26 11:14 ` Magnus Damm
  2003-08-27 10:38   ` Wolfgang Denk
  2003-08-27 10:37 ` Wolfgang Denk
  1 sibling, 1 reply; 9+ messages in thread
From: Magnus Damm @ 2003-08-26 11:14 UTC (permalink / raw)
  To: Steven Scholz; +Cc: linuxppc-embedded


I don't know how things are today, but there was a collision between
the mpc8xx-uart code and the standard "pc" uart-code once upon a time.

I think the mpc8xx-uart code used the same struct as the other uart code,
but overloaded some values... But that was Linux-2.2.x, things have
probably changed - I hope... =)

/ magnus

On Tue, 26 Aug 2003 12:40:13 +0200
Steven Scholz <steven.scholz@imc-berlin.de> wrote:

>
> Hi there,
>
> is someone using a PCMCIA Modem or Serial Port card with an MPC8xx system?
>
> I build a kernel for a TQM860L based board enabeling CONFIG_SERIAL=y
> as the PCMCIA HowTo states. (I also have CONFIG_SERIAL_CONSOLE=y). But
> while booting (or insmod serial.o) I get :
>
> CPM UART driver version 0.04
> ttyS0 on SMC1 at 0x0280, BRG1
> ttyS1 on SMC2 at 0x0380, BRG2
> pty: 256 Unix98 ptys configured
> Serial driver version 5.05c (2001-07-08) with no serial options enabled
> Oops: kernel access of bad area, sig: 11
> NIP: C009FA6C XER: 00000000 LR: C00A4174 SP: C01D7E80 REGS: c01d7dd0
> TRAP: 0300    Not tainted
> MSR: 00001032 EE: 0 PR: 0 FP: 0 ME: 1 IR/DR: 11
> DAR: 800003F9, DSISR: 00000469
> TASK = c01d6000[1] 'swapper' Last syscall: 120
> last math 00000000 last altivec 00000000
> GPR00: 00000000 C01D7E80 C01D6000 C01D7E88 00000001 00000000 C01CC3D8
> 000003F8
> GPR08: 00000000 800003F9 00000000 00000000 00000001 100B0020 C00A37C8
> C00A301C
> GPR16: C00A1B68 C00A2834 C00A3138 C009FC10 C009FB84 C00A2CAC C00A1C38
> C00A1BB0
> GPR24: C00A28BC C00A1AE8 C00A1AD0 C0151FD8 C0151FD8 C017C130 C017C1F4
> C01D7E88
> Call backtrace:
> C000FE44 C0161A00 C015B588 C015B5D0 C000227C C0004BA0
> Kernel panic: Attempted to kill init!
>
> Backtrace is:
> 0xc000fe44 -- 0xc000fd78 + 0x00cc   release_console_sem
> 0xc0161a00 -- 0xc0161630 + 0x03d0   rs_init
> 0xc015b588 -- 0xc015b558 + 0x0030   do_initcalls
> 0xc015b5d0 -- 0xc015b5a8 + 0x0028   do_basic_setup
> 0xc000227c -- 0xc0002268 + 0x0014   init
> 0xc0004ba0 -- 0xc0004b74 + 0x002c   kernel_thread
>
> Any ideas?
>
> Thanks a million!
>
> Steven
>
>
>


** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/

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

* RE: PCMCIA Modem/Serial Cards and MPC8xx?
@ 2003-08-26 21:40 Rod Boyce
  2003-08-27  9:17 ` Steven Scholz
  0 siblings, 1 reply; 9+ messages in thread
From: Rod Boyce @ 2003-08-26 21:40 UTC (permalink / raw)
  To: 'Steven Scholz ', 'LinuxPPC '


Steve,

I am not at my desk but can tell you that you will have to change the
options for serial driver.  I have use the PCMCIA for serial ports but I
have setup both the MPC8xx uarts and a standard 16550 uart chip to work in
the same Linux kernel.  from the look of your kernel output you have not
emabled any serial options so your driver is looking for a build in 16550
and failing to find one.  there is a file in <kernel root>/include/asm
called serial.h this fle contains the devines for the serial ports used
butthe kernel.  There are not used by the MPC8xx uart driver. You are going
to have to figure out what you want to definein there for your PCMCIA serial
port.
I hoe this helps you.

Regards,
Rod Boyce

-----Original Message-----
From: Steven Scholz
To: LinuxPPC
Sent: 8/26/2003 10:40 PM
Subject: PCMCIA Modem/Serial Cards and MPC8xx?


Hi there,

is someone using a PCMCIA Modem or Serial Port card with an MPC8xx
system?

I build a kernel for a TQM860L based board enabeling CONFIG_SERIAL=y
as the PCMCIA HowTo states. (I also have CONFIG_SERIAL_CONSOLE=y). But
while booting (or insmod serial.o) I get :

CPM UART driver version 0.04
ttyS0 on SMC1 at 0x0280, BRG1
ttyS1 on SMC2 at 0x0380, BRG2
pty: 256 Unix98 ptys configured
Serial driver version 5.05c (2001-07-08) with no serial options enabled
Oops: kernel access of bad area, sig: 11
NIP: C009FA6C XER: 00000000 LR: C00A4174 SP: C01D7E80 REGS: c01d7dd0
TRAP: 0300    Not tainted
MSR: 00001032 EE: 0 PR: 0 FP: 0 ME: 1 IR/DR: 11
DAR: 800003F9, DSISR: 00000469
TASK = c01d6000[1] 'swapper' Last syscall: 120
last math 00000000 last altivec 00000000
GPR00: 00000000 C01D7E80 C01D6000 C01D7E88 00000001 00000000 C01CC3D8
000003F8
GPR08: 00000000 800003F9 00000000 00000000 00000001 100B0020 C00A37C8
C00A301C
GPR16: C00A1B68 C00A2834 C00A3138 C009FC10 C009FB84 C00A2CAC C00A1C38
C00A1BB0
GPR24: C00A28BC C00A1AE8 C00A1AD0 C0151FD8 C0151FD8 C017C130 C017C1F4
C01D7E88
Call backtrace:
C000FE44 C0161A00 C015B588 C015B5D0 C000227C C0004BA0
Kernel panic: Attempted to kill init!

Backtrace is:
0xc000fe44 -- 0xc000fd78 + 0x00cc   release_console_sem
0xc0161a00 -- 0xc0161630 + 0x03d0   rs_init
0xc015b588 -- 0xc015b558 + 0x0030   do_initcalls
0xc015b5d0 -- 0xc015b5a8 + 0x0028   do_basic_setup
0xc000227c -- 0xc0002268 + 0x0014   init
0xc0004ba0 -- 0xc0004b74 + 0x002c   kernel_thread

Any ideas?

Thanks a million!

Steven


** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/

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

* Re: PCMCIA Modem/Serial Cards and MPC8xx?
  2003-08-26 21:40 Rod Boyce
@ 2003-08-27  9:17 ` Steven Scholz
  2003-08-27 10:44   ` Wolfgang Denk
  0 siblings, 1 reply; 9+ messages in thread
From: Steven Scholz @ 2003-08-27  9:17 UTC (permalink / raw)
  To: Rod Boyce; +Cc: 'LinuxPPC '


Rod,

Thanks for your reply.

> I am not at my desk but can tell you that you will have to change the
> options for serial driver.  I have use the PCMCIA for serial ports but I
> have setup both the MPC8xx uarts and a standard 16550 uart chip to work in
> the same Linux kernel.
Could you please give my a pointer how you did that?
Did you have MPC8xx uarts _and_ a standard 16550 uart _and_ PCMCIA?

>  from the look of your kernel output you have not
> emabled any serial options so your driver is looking for a build in 16550
> and failing to find one.
Hmm. But even if I define one. The kernel won't find a UART if it's on
PCMCIA since PCMCIA is started much later... ?

>there is a file in <kernel root>/include/asm
> called serial.h this fle contains the devines for the serial ports used
> butthe kernel.  There are not used by the MPC8xx uart driver. You are going
> to have to figure out what you want to definein there for your PCMCIA serial
> port.
Any hints?

Thanks,

Steven


** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/

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

* Re: PCMCIA Modem/Serial Cards and MPC8xx?
  2003-08-26 10:40 PCMCIA Modem/Serial Cards and MPC8xx? Steven Scholz
  2003-08-26 11:14 ` Magnus Damm
@ 2003-08-27 10:37 ` Wolfgang Denk
  1 sibling, 0 replies; 9+ messages in thread
From: Wolfgang Denk @ 2003-08-27 10:37 UTC (permalink / raw)
  To: Steven Scholz; +Cc: LinuxPPC


Dear Steven,

in message <3F4B390D.1060101@imc-berlin.de> you wrote:
>
> is someone using a PCMCIA Modem or Serial Port card with an MPC8xx system?

Yes, we tested this on a couple of boards, including a TQM8xxL board.

> I build a kernel for a TQM860L based board enabeling CONFIG_SERIAL=y
> as the PCMCIA HowTo states. (I also have CONFIG_SERIAL_CONSOLE=y). But
> while booting (or insmod serial.o) I get :

So far, this is only supported by our linux-2.4 kernel (normally, the
8xx UART driver and the standard serial driver  [as  needed  for  the
modem] will cause conflicts; these are trivially to fix, though).

Best regards,

Wolfgang Denk

--
Software Engineering:  Embedded and Realtime Systems,  Embedded Linux
Phone: (+49)-8142-4596-87  Fax: (+49)-8142-4596-88  Email: wd@denx.de
Bus error -- driver executed.

** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/

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

* Re: PCMCIA Modem/Serial Cards and MPC8xx?
  2003-08-26 11:14 ` Magnus Damm
@ 2003-08-27 10:38   ` Wolfgang Denk
  0 siblings, 0 replies; 9+ messages in thread
From: Wolfgang Denk @ 2003-08-27 10:38 UTC (permalink / raw)
  To: Magnus Damm; +Cc: Steven Scholz, linuxppc-embedded


In message <20030826131440.031012f5.damm@opensource.se> you wrote:
>
> I don't know how things are today, but there was a collision between
> the mpc8xx-uart code and the standard "pc" uart-code once upon a time.

Correct.

> I think the mpc8xx-uart code used the same struct as the other uart code,
> but overloaded some values... But that was Linux-2.2.x, things have
> probably changed - I hope... =)

Not in the official trees, I'm afraid.

Best regards,

Wolfgang Denk

--
Software Engineering:  Embedded and Realtime Systems,  Embedded Linux
Phone: (+49)-8142-4596-87  Fax: (+49)-8142-4596-88  Email: wd@denx.de
War is never imperative.
	-- McCoy, "Balance of Terror", stardate 1709.2

** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/

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

* Re: PCMCIA Modem/Serial Cards and MPC8xx?
  2003-08-27  9:17 ` Steven Scholz
@ 2003-08-27 10:44   ` Wolfgang Denk
  2003-08-27 11:12     ` Steven Scholz
  0 siblings, 1 reply; 9+ messages in thread
From: Wolfgang Denk @ 2003-08-27 10:44 UTC (permalink / raw)
  To: Steven Scholz; +Cc: Rod Boyce, 'LinuxPPC '


Dear Steven,

in message <3F4C7713.2030703@imc-berlin.de> you wrote:
>
> > I am not at my desk but can tell you that you will have to change the
> > options for serial driver.  I have use the PCMCIA for serial ports but I
> > have setup both the MPC8xx uarts and a standard 16550 uart chip to work in
> > the same Linux kernel.
> Could you please give my a pointer how you did that?
> Did you have MPC8xx uarts _and_ a standard 16550 uart _and_ PCMCIA?

Yes, we support MPX8xx UART, standard serial driver  including  16550
UART,  and  PCMCIA.  See our linux-2.4 kernel tree. It should be very
easy to extract the relevant patch and  to  apply  it  to  any  other
kernel.

> Hmm. But even if I define one. The kernel won't find a UART if it's on
> PCMCIA since PCMCIA is started much later... ?

The PCMCIA Card Services will take care of that.

> Any hints?

See http://www.denx.de/twiki/bin/view/DULG/KernelConfigurationForPCMCIA

Best regards,

Wolfgang Denk

--
Software Engineering:  Embedded and Realtime Systems,  Embedded Linux
Phone: (+49)-8142-4596-87  Fax: (+49)-8142-4596-88  Email: wd@denx.de
"The whole problem with the world is  that  fools  and  fanatics  are
always so certain of themselves, but wiser people so full of doubts."
- Bertrand Russell

** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/

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

* Re: PCMCIA Modem/Serial Cards and MPC8xx?
  2003-08-27 10:44   ` Wolfgang Denk
@ 2003-08-27 11:12     ` Steven Scholz
  2003-08-27 11:50       ` Wolfgang Denk
  0 siblings, 1 reply; 9+ messages in thread
From: Steven Scholz @ 2003-08-27 11:12 UTC (permalink / raw)
  To: Wolfgang Denk; +Cc: 'LinuxPPC '


Dear Wolfgang,

 >>Did you have MPC8xx uarts _and_ a standard 16550 uart _and_ PCMCIA?
 >
 > Yes, we support MPX8xx UART, standard serial driver  including  16550
 > UART,  and  PCMCIA.  See our linux-2.4 kernel tree. It should be very
 > easy to extract the relevant patch and  to  apply  it  to  any  other
 > kernel.

I am getting closer though:

I changed
#define RS_TABLE_SIZE 3

and added a dummy line in my dab4k_serial.h:

#define SERIAL_PORT_DFNS \
          { 0, (UART_BASE_BAUD/16), UARTA_ADDR, SIU_IRQ3, STD_COM_FLAGS, \
            iomem_base: (u8 *) UARTA_ADDR, \
            iomem_reg_shift:0, \
            io_type: SERIAL_IO_MEM }, \
          { 0, (UART_BASE_BAUD/16), UARTB_ADDR, SIU_IRQ4, STD_COM_FLAGS, \
            iomem_base: (u8 *) UARTB_ADDR, \
            iomem_reg_shift:0, \
            io_type: SERIAL_IO_MEM }, \
          { 0, 0, 0, 0, STD_COM_FLAG}

Now I do get

CPM UART driver version 0.04
ttyS0 on SMC1 at 0x0280, BRG1
ttyS1 on SMC2 at 0x0380, BRG2
ttyS2 on SCC1 at 0x0000, BRG3

Serial driver version 5.05c (2001-07-08) with SHARE_IRQ enabled
ttyS00 at 0xc3071000 (irq = 6) is a ST16654
ttyS01 at 0xc3071080 (irq = 8) is a ST16654

And PCMCIA CS tells me

cardmgr[80]: socket 0: Serial or Modem
cardmgr[80]: BEEP_OK
cardmgr[80]:   product info: "Intelligent", "PCMCIA FAX+MODEM"
cardmgr[80]:   manfid: 0x0200, 0x0001  function: 2 (serial)
cardmgr[80]: executing: 'modprobe serial_cs'
cardmgr[80]: + Using /lib/modules/2.4.20/pcmcia/pcmcia_core.o
cardmgr[80]: + Using /lib/modules/2.4.20/pcmcia/ds.o
cardmgr[80]: + Using /lib/modules/2.4.20/pcmcia/serial_cs.o
ttyS02 at port 0x03f8 (irq = 9) is a 16550A
cardmgr[80]: executing: './serial start ttyS2'
cardmgr[80]: + Default modem setup
cardmgr[80]: BEEP_OK
cardmgr[80]: BEEP_OK

So why is it ttyS02. Why is it ./serial start ttyS2?
It's also ttyS2 if I don't enable SCC1 as UART!

 > See http://www.denx.de/twiki/bin/view/DULG/KernelConfigurationForPCMCIA

I read this. But where does the MAJOR number 240 come from???

Steven


** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/

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

* Re: PCMCIA Modem/Serial Cards and MPC8xx?
  2003-08-27 11:12     ` Steven Scholz
@ 2003-08-27 11:50       ` Wolfgang Denk
  0 siblings, 0 replies; 9+ messages in thread
From: Wolfgang Denk @ 2003-08-27 11:50 UTC (permalink / raw)
  To: Steven Scholz; +Cc: 'LinuxPPC '


Dear Steven,

in message <3F4C9209.8050301@imc-berlin.de> you wrote:
>
> Now I do get
...
> Serial driver version 5.05c (2001-07-08) with SHARE_IRQ enabled
> ttyS00 at 0xc3071000 (irq = 6) is a ST16654
> ttyS01 at 0xc3071080 (irq = 8) is a ST16654

ttyS00 and ttyS01 are already in use?

> And PCMCIA CS tells me
...
> cardmgr[80]: + Using /lib/modules/2.4.20/pcmcia/serial_cs.o
> ttyS02 at port 0x03f8 (irq = 9) is a 16550A
...
> So why is it ttyS02. Why is it ./serial start ttyS2?

Because ttyS00 and ttyS01 are already in use.

> It's also ttyS2 if I don't enable SCC1 as UART!

ttyS2 or ttyS02?

> I read this. But where does the MAJOR number 240 come from???

See Documentation/devices.txt: LOCAL/EXPERIMENTAL USE

Based on previous experience I saw little chance to get the  resource
conflict solved by the Powers That Be.

Best regards,

Wolfgang Denk

--
Software Engineering:  Embedded and Realtime Systems,  Embedded Linux
Phone: (+49)-8142-4596-87  Fax: (+49)-8142-4596-88  Email: wd@denx.de
We are drowning in information but starved for knowledge.
                                         -- John Naisbitt, Megatrends

** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/

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

end of thread, other threads:[~2003-08-27 11:50 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-08-26 10:40 PCMCIA Modem/Serial Cards and MPC8xx? Steven Scholz
2003-08-26 11:14 ` Magnus Damm
2003-08-27 10:38   ` Wolfgang Denk
2003-08-27 10:37 ` Wolfgang Denk
  -- strict thread matches above, loose matches on Subject: below --
2003-08-26 21:40 Rod Boyce
2003-08-27  9:17 ` Steven Scholz
2003-08-27 10:44   ` Wolfgang Denk
2003-08-27 11:12     ` Steven Scholz
2003-08-27 11:50       ` Wolfgang Denk

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).