hi!
I write a sample network device driver based on MPC860T
but no experience any device driver.
I reference '/kernel/arch/ppc/8xx_io/enet.c' file and I wirte a
program.
when I compile (ppc_8xx-gcc -o network network.c ) , occur error with
following message
============== -error ============================================
~~/network.c : undefined reference to 'printk'
~~/network.c : relocation truncation to fit : R_PPC_REL24 printk
~/network.c : undefined reference to 'kmalloc'
~~/network.c : relocation truncation to fit : R_PPC_REL24 kmalloc
.........
collect2: ld returned 1 exit status
make: ***[all] Error 1
==============================================================
I can't use 'printk()' , kmalloc() etc... function .
I include linux/kernel.h . linux/fs.h , linux/slab.h ...etc ( header
files of need by function)
(reference the book 'linux device driver ' by ALESSANDRO RUBIN )
why i don't use those function?
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
From: Nguyen Trung Thanh <hidden> Date: 2001-07-16 12:43:42
Hi all,
Pls help me, I'm stuck with this card.
Now I used kernel Powerpc Hardhat 2.2.14,
and pcmcia-cs-3.1.21 in a custom board using
MPC823.
I could dial up with this card, but it is not stable,
and I could not transfer data such as ftp....
Furthermore, I must set the maximum value for
psst = 4, psht = 4, and psl = 20.
and add some delay between each time I read from serial port ( in function
receive_chars from file serial.c).
Have anyone done it, before? Or you have any information about thi card
phone, pls give me.
Does this card use 16550A, and follow the standard of this chip?
Is there any special thing about it spec, timing?
Thanks very much,
Jari
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
From: James Petterson <hidden> Date: 2001-07-16 13:10:59
If you're compiling a module, your output file should be 'network.o':
ppc_8xx-gcc -o network.o network.c
James
On Monday 16 July 2001 07:26, hychon wrote:
hi!
I write a sample network device driver based on MPC860T
but no experience any device driver.
I reference '/kernel/arch/ppc/8xx_io/enet.c' file and I wirte a
program.
when I compile (ppc_8xx-gcc -o network network.c ) , occur error with
following message
============== -error ============================================
~~/network.c : undefined reference to 'printk'
~~/network.c : relocation truncation to fit : R_PPC_REL24 printk
~/network.c : undefined reference to 'kmalloc'
~~/network.c : relocation truncation to fit : R_PPC_REL24 kmalloc
.........
collect2: ld returned 1 exit status
make: ***[all] Error 1
==============================================================
I can't use 'printk()' , kmalloc() etc... function .
I include linux/kernel.h . linux/fs.h , linux/slab.h ...etc ( header
files of need by function)
(reference the book 'linux device driver ' by ALESSANDRO RUBIN )
why i don't use those function?
On Mon, Jul 16, 2001 at 10:10:59AM -0300, James Petterson wrote:
If you're compiling a module, your output file should be 'network.o':
ppc_8xx-gcc -o network.o network.c
Along with specifying lots of includes and -D__KERNEL__. And the kernel
you'll be using this on needs modules enabled as well. Run a 'make modules'
in your kernel tree and see what it uses to compile modules.
--
Tom Rini (TR1265)
http://gate.crashing.org/~trini/
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
From: Matthew Locke <hidden> Date: 2001-07-16 17:12:51
Nguyen Trung Thanh wrote:
Hi all,
Pls help me, I'm stuck with this card.
Now I used kernel Powerpc Hardhat 2.2.14,
and pcmcia-cs-3.1.21 in a custom board using
MPC823.
You should consider moving to 3.1.26, many bugs have been fixed.
I could dial up with this card, but it is not stable,
and I could not transfer data such as ftp....
Furthermore, I must set the maximum value for
psst = 4, psht = 4, and psl = 20.
and add some delay between each time I read from serial port ( in function
receive_chars from file serial.c).
In general, there are conflicts between 8xx serial driver (uart.c) and
serial.c. They may be stepping on each other.
Have anyone done it, before? Or you have any information about thi card
phone, pls give me.
Does this card use 16550A, and follow the standard of this chip?
Is there any special thing about it spec, timing?
Thanks very much,
Jari
From: Nguyen Trung Thanh <hidden> Date: 2001-07-17 07:38:39
Hi Matthew Locke,
Thank you very much for your reply.
As you said, I moved to the newest version of Pcmcia Card Service which I
could find from ftp.mvista.com
Its version is 3.1.24.. I don't know it is good enough or not.
Of course, I changed something to avoid conflicts between 8xx serial driver
(uart.c) and serial.c.
I mapped the _IO_BASE 0x80000000, hardcode irq = 9.
Then it worked well with PCMCIA modem such as Xircom.
Now I could use this version with Nokia Cardphone2.0, but the result is the
same.
I just wonder why this PCMCIA cardphone can run smoothly in a Sony VAIO
laptop using this version of linux kernel 2.2.14 and pcmcia-3.1.24, but when
I run it with my board, I must add some delay in function receive_chars in
file: serial.c.
Otherwise, I'd receive a lot of gabage charaters. For example:
I wrote a string "ATZ" , and then received:
"aATZOKaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"
instead of "ATZOK"???
Would you pls tell me what is the problem here?
I think that it is due to the timing of 16550A chip, is it right?
Or it is due to the serial speed?
If you have any idea about my problem, pls tell me...
Thanks for you kindness,
Jari
Nguyen Trung Thanh wrote:
quoted
Hi all,
Pls help me, I'm stuck with this card.
Now I used kernel Powerpc Hardhat 2.2.14,
and pcmcia-cs-3.1.21 in a custom board using
MPC823.
You should consider moving to 3.1.26, many bugs have been fixed.
quoted
I could dial up with this card, but it is not stable,
and I could not transfer data such as ftp....
Furthermore, I must set the maximum value for
psst = 4, psht = 4, and psl = 20.
and add some delay between each time I read from serial port ( in
function
quoted
receive_chars from file serial.c).
In general, there are conflicts between 8xx serial driver (uart.c) and
serial.c. They may be stepping on each other.
quoted
Have anyone done it, before? Or you have any information about thi card
phone, pls give me.
Does this card use 16550A, and follow the standard of this chip?
Is there any special thing about it spec, timing?
Thanks very much,
Jari
From: Matthew Locke <hidden> Date: 2001-07-18 16:55:54
Nguyen Trung Thanh wrote:
Hi Matthew Locke,
Thank you very much for your reply.
As you said, I moved to the newest version of Pcmcia Card Service which I
could find from ftp.mvista.com
Its version is 3.1.24.. I don't know it is good enough or not.
Of course, I changed something to avoid conflicts between 8xx serial driver
(uart.c) and serial.c.
I mapped the _IO_BASE 0x80000000, hardcode irq = 9.
Then it worked well with PCMCIA modem such as Xircom.
Now I could use this version with Nokia Cardphone2.0, but the result is the
same.
I just wonder why this PCMCIA cardphone can run smoothly in a Sony VAIO
laptop using this version of linux kernel 2.2.14 and pcmcia-3.1.24, but when
I run it with my board, I must add some delay in function receive_chars in
file: serial.c.
Otherwise, I'd receive a lot of gabage charaters. For example:
I wrote a string "ATZ" , and then received:
"aATZOKaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"
instead of "ATZOK"???
Would you pls tell me what is the problem here?
I think that it is due to the timing of 16550A chip, is it right?
Or it is due to the serial speed?
yeah, it could be some sort of timing issue, but I am not looking at the
specs for any of those parts.
If you have any idea about my problem, pls tell me...
Thanks for you kindness,
Jari
quoted
Nguyen Trung Thanh wrote:
quoted
Hi all,
Pls help me, I'm stuck with this card.
Now I used kernel Powerpc Hardhat 2.2.14,
and pcmcia-cs-3.1.21 in a custom board using
MPC823.
You should consider moving to 3.1.26, many bugs have been fixed.
quoted
I could dial up with this card, but it is not stable,
and I could not transfer data such as ftp....
Furthermore, I must set the maximum value for
psst = 4, psht = 4, and psl = 20.
and add some delay between each time I read from serial port ( in
function
quoted
quoted
receive_chars from file serial.c).
In general, there are conflicts between 8xx serial driver (uart.c) and
serial.c. They may be stepping on each other.
quoted
Have anyone done it, before? Or you have any information about thi card
phone, pls give me.
Does this card use 16550A, and follow the standard of this chip?
Is there any special thing about it spec, timing?
Thanks very much,
Jari