[ltp] Re: [Linux-IrDA] [PATCH] nsc-ircc

Thomas Hood linux-thinkpad@www.bm-soft.com
Wed, 28 Feb 2001 03:16:41 +0000 (GMT)


--- Tom Grydeland <Tom.Grydeland@phys.uit.no> wrote: 
> 
> After applying the patch, I was able to load the module, but I was not
> seeing any traffic on the link (irdadump was not showing any traffic,
> and the Palm did not react to anything), but this might be a resource
> allocation problem (my fault) on the thinkpad.
> 
> ---------------------------------------------------
> Feb 27 04:51:43 ska kernel: IrDA (tm) Protocols for Linux-2.2 (Dag Brattli) 
> Feb 27 04:51:43 ska kernel: nsc-ircc, Found chip at io base 0x02e 
> Feb 27 04:51:43 ska kernel: nsc-ircc, Driver loaded (Dag Brattli) 
> Feb 27 04:51:43 ska kernel: IrDA: Registered device irda0 
> Feb 27 04:51:43 ska kernel: nsc-ircc, Using dongle: IBM31T1100 or Temic
> TFDS6000/TFDS6500 
> Feb 27 04:52:06 ska irattach: executing: '/sbin/modprobe irda0'
> Feb 27 04:52:06 ska irattach: executing: 'echo 1 >
> /proc/sys/net/irda/discovery'
> Feb 27 04:52:06 ska irattach: Starting device irda0
> Feb 27 04:52:06 ska kernel: nsc-ircc, Request for irq 4 was refused 
> Feb 27 04:52:06 ska irattach: executing: 'echo ska >
> /proc/sys/net/irda/devname'
> ---------------------------------------------------
> 
> I'm not sure I believe the 'Request for irq 4 was refused' message --
> IRQ 4 was registered as in use by irda at this point.

I was able to load the nsc-ircc module and it successfully
grabbed irq 4:

root@thanatos:/etc/irda# modprobe nsc-ircc
root@thanatos:/etc/irda# lsmod | head
Module                  Size  Used by
nsc-ircc               10128   0  (unused)
irda                   75632   0  [nsc-ircc]
serial                 42608   1  (autoclean)
[...]

root@thanatos:/etc/irda# cat /var/log/messages
[...]
Feb 27 22:02:33 thanatos kernel: nsc-ircc, Found chip at io base 0x02e
Feb 27 22:02:33 thanatos kernel: nsc-ircc, Driver loaded (Dag Brattli)
Feb 27 22:02:33 thanatos kernel: IrDA: Registered device irda0
Feb 27 22:02:33 thanatos kernel: nsc-ircc, Using dongle: IBM31T1100 or Temic
TFDS6000/TFDS6500
[...]

root@thanatos:/etc/irda# cat /proc/ioports
[...]
03e8-03ef : nsc-ircc
[...]

root@thanatos:/etc/irda# ifconfig irda0 up  
root@thanatos:/etc/irda# cat /proc/interrupts
           CPU0       
  0:    3176386          XT-PIC  timer
  1:      49162          XT-PIC  keyboard
  2:          0          XT-PIC  cascade
  3:     547428          XT-PIC  serial
  4:      24159          XT-PIC  irda0
  5:       4323          XT-PIC  CS4236+
  8:          7          XT-PIC  rtc
 10:        139          XT-PIC  mwavedsp
 11:          8          XT-PIC  i82365
 12:     942880          XT-PIC  PS/2 Mouse
 14:      46001          XT-PIC  ide0
 15:          3          XT-PIC  ide1
NMI:          0 
ERR:          0


(Note that the interrupt is not used if the irda0
interface is not up.)

> HOWEVER, after having stopped trying FIR, I killed irattach and was going to
> try SIR again.  Now, setserial was no longer able to correctly identify
> the UART of the IR port:
> 
> Feb 27 10:12:45 ska kernel: ttyS02 at 0x03e8 (irq = 4) is a 8250 

root@thanatos:/etc/irda# ifconfig irda0 down
root@thanatos:/etc/irda# modprobe -r nsc-ircc
root@thanatos:/etc/irda# setserial /dev/ttyS2 auto_irq autoconfig
root@thanatos:/etc/irda# setserial -g /dev/ttyS?
/dev/ttyS0, UART: 16550A, Port: 0x03f8, IRQ: 4
/dev/ttyS1, UART: 16550A, Port: 0x02f8, IRQ: 3
/dev/ttyS2, UART: 16550A, Port: 0x03e8, IRQ: 4
/dev/ttyS3, UART: unknown, Port: 0x02e8, IRQ: 3

> and when I tried (using tpctl) to disable the IR port, the machine
> froze.  According to Till Straumann, this has been a problem with the
> nsc-ircc driver previously, and it seems this patch does not fix it
> entirely.

I'm not going to try disabling the ir port.  :)

Thomas

____________________________________________________________
Do You Yahoo!?
Get your free @yahoo.co.uk address at http://mail.yahoo.co.uk
or your free @yahoo.ie address at http://mail.yahoo.ie

----- The Linux ThinkPad mailing list -----
The linux-thinkpad mailing list home page is at:
http://www.bm-soft.com/~bm/tp_mailing.html