* Framebuffer problems
@ 2004-05-22 0:57 Christopher E Cordahi
2004-05-22 7:25 ` Module Compiling Problem Song Sam
0 siblings, 1 reply; 9+ messages in thread
From: Christopher E Cordahi @ 2004-05-22 0:57 UTC (permalink / raw)
To: linuxppc-embedded
Hello all,
I'm having problems with a framebuffer on /dev/fb0 using the DENX 2.4.24
kernel
I have added the Linux Console Driver for the Epson S1D13806
http://www.erd.epson.com/vdc/RelSoft/generic/s1d13xxx_linux.zip
which prints the following to the console as it is initialized
Console: switching to frame buffer device
S1D13xxx: fb0: s1d13xxx frame buffer device
S1D13xxx: Display 240 x 320 8Bpp
Whenever the framebuffer is accessed a call is made to the
function PROC_CONSOLE in fbcon.c which always returns -1
because the info->display_fg pointer is NULL
None of the functions that call PROC_CONSOLE test for this error value.
Some commands seem to work because later functions test for con == -1.
(FBIOGET_FSCREENINFO works because fbgen_get_fix tests for it)
Ofher commands fail because later functions assume the con passed is
correct and use it as an index into the fb_display array.
(FBIOGETCMAP fails because fbgen_get_cmap doesn't test for it)
I guess I'm lucky the whole O/S is not crashing.
Is there a way to have PROC_CONSOLE always return a valid value?
Or should all the functions in fbgen.c be fixed to handle con == -1?
I would like to leave the serial port (/dev/ttyS0) as the console
and I don't actually want the framebuffer as the console.
I would prefer that only Konqueror/Embedded with Qt/Embedded
use the framebuffer.
Any assistance would be greatly appreciated.
Chris
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
^ permalink raw reply [flat|nested] 9+ messages in thread
* Module Compiling Problem
2004-05-22 0:57 Framebuffer problems Christopher E Cordahi
@ 2004-05-22 7:25 ` Song Sam
2004-05-23 2:00 ` Song Sam
0 siblings, 1 reply; 9+ messages in thread
From: Song Sam @ 2004-05-22 7:25 UTC (permalink / raw)
To: linuxppc-embedded
Hi,
A error happened when I compiled a module.Could any
warmhearted person figure it out for me?
[root@sam ic]# make
ppc_8xx-gcc -D__KERNEL__ -D_REENTRANT
-I/workspace/keep/dmt201-test/kernel/include -Wall
-Wstrict-prototypes -Wno-trigraphs -O2
-fomit-frame-pointer -fno-strict-aliasing -fno-common
-g -I/workspace/keep/dmt201-test/kernel/arch/ppc
-fsigned-char -msoft-float -pipe -ffixed-r2
-Wno-uninitialized -mmultiple -mstring -DMODULE
-DKBUILD_BASENAME=ic -c ic.c
In file included from ic.c:57:
/workspace/keep/dmt201-test/kernel/include/linux/tty_flip.h:
In function `tty_schedule_flip':
/workspace/keep/dmt201-test/kernel/include/linux/tty_flip.h:22:
`tq_timer_Rfa3e9acc' undeclared (first use in this
function)
/workspace/keep/dmt201-test/kernel/include/linux/tty_flip.h:22:
(Each undeclared identifier is reported only once
/workspace/keep/dmt201-test/kernel/include/linux/tty_flip.h:22:
for each function it appears in.)
ic.c: In function `service_timer':
ic.c:851: `tq_immediate_R0da0dcd1' undeclared (first
use in this function)
ic.c: In function `timer_do_tasklet':
ic.c:944: warning: implicit declaration of function
`__wake_up_Rf0f2f792'
ic.c: In function `m8xx_timer_setup':
ic.c:1032: `__res_Rd7dfb463' undeclared (first use in
this function)
ic.c: In function `initicdata':
ic.c:1360: warning: implicit declaration of function
`kmalloc_R93d4cfe6'
ic.c:1360: warning: assignment makes pointer from
integer without a cast
ic.c:1363: warning: assignment makes pointer from
integer without a cast
ic.c: In function `icread':
ic.c:1389: warning: implicit declaration of function
`printk_Rdd132261'
ic.c: In function `init_ic':
ic.c:1659: warning: implicit declaration of function
`register_chrdev_R6c9c715e'
ic.c: In function `remove_ic':
ic.c:1724: warning: implicit declaration of function
`unregister_chrdev_Rc192d491'
make: *** [ic.o] Error 1
Thanks a lot for any input!
Sam
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: Module Compiling Problem
2004-05-22 7:25 ` Module Compiling Problem Song Sam
@ 2004-05-23 2:00 ` Song Sam
2004-05-23 18:34 ` Sam Ravnborg
0 siblings, 1 reply; 9+ messages in thread
From: Song Sam @ 2004-05-23 2:00 UTC (permalink / raw)
To: linuxppc-embedded
Song Sam <samlinuxppc@yahoo.com.cn> wrote
> A error happened when I compiled a module.Could any warmhearted person
> figure it out for me?
OK,I did it by myself.:-)
It turned out to be the fact that I enabled
CONFIG_MODVERSIONS=y in kernel configuration
and MODVERSIONS option in my module like
#if defined(CONFIG_MODVERSIONS)
#define MODVERSIONS
#include <linux/modversions.h>
#endif
at the same time.They conflicted against each other.Is
that so?A newbie error on module...
Best regards,
Sam
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: Module Compiling Problem
2004-05-23 2:00 ` Song Sam
@ 2004-05-23 18:34 ` Sam Ravnborg
2004-05-24 1:49 ` Song Sam
0 siblings, 1 reply; 9+ messages in thread
From: Sam Ravnborg @ 2004-05-23 18:34 UTC (permalink / raw)
To: Song Sam; +Cc: linuxppc-embedded
On Sun, May 23, 2004 at 10:00:29AM +0800, Song Sam wrote:
>
> Song Sam <samlinuxppc@yahoo.com.cn> wrote
>
> > A error happened when I compiled a module.Could any warmhearted person
> > figure it out for me?
>
> OK,I did it by myself.:-)
> It turned out to be the fact that I enabled
> CONFIG_MODVERSIONS=y in kernel configuration
> and MODVERSIONS option in my module like
> #if defined(CONFIG_MODVERSIONS)
> #define MODVERSIONS
> #include <linux/modversions.h>
> #endif
> at the same time.They conflicted against each other.Is
> that so?A newbie error on module...
Looks wrong.
When compiling an external module use:
for 2.4:
make -C $ERNELSRC SUBDIRS=$PWD modules
for 2.6: (2.6.6 onwards)
make -C $KERNELSRC M=$PWD
Sam
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: Module Compiling Problem
2004-05-23 18:34 ` Sam Ravnborg
@ 2004-05-24 1:49 ` Song Sam
2004-05-24 5:06 ` Sam Ravnborg
0 siblings, 1 reply; 9+ messages in thread
From: Song Sam @ 2004-05-24 1:49 UTC (permalink / raw)
To: Sam Ravnborg; +Cc: linuxppc-embedded
Dear Mr. Sam,
Nice to meet you!
Sam Ravnborg <sam@ravnborg.org> you wrote:
> Looks wrong.
> When compiling an external module use:
> for 2.4:
> make -C $ERNELSRC SUBDIRS=$PWD modules
Uh,$ERNELSRC or $KERNELSRC?
I use 2.4.18 for the moment.But after following your
instruction,module compiling didn't get through.Pls
see my making process and Makefile below.Did I do
anything wrong or miss what?
-------------------------------------------------
[root@sgj ic]# make -C $KERNELSRC SUBDIRS=$PWD modules
make: ***
SUBDIRS=/workspace/myfilesystem/target/workdir/ic: No
such file or directory. Stop.
[root@sgj ic]# make -C $ERNELSRC SUBDIRS=$PWD modules
make: ***
SUBDIRS=/workspace/myfilesystem/target/workdir/ic: No
such file or directory. Stop.
[Makefile]
CC = ppc_8xx-gcc
# TOPDIR := $(shell /bin/pwd)
FILENAME = myic
MYPATH = /workspace/keep/dmt201/kernel
CPPFLAGS := -D__KERNEL__ -D_REENTRANT
-I$(MYPATH)/include
CFLAGS := $(CPPFLAGS) -Wall -Wstrict-prototypes
-Wno-trigraphs -O2 -fomit-frame-pointer \
-fno-strict-aliasing -fno-common -g
-I$(MYPATH)/arch/ppc -fsigned-char -msoft-float -pipe
\
-ffixed-r2 -Wno-uninitialized -mmultiple -mstring
all : $(FILENAME).o
clean :
rm $(FILENAME).o
$(FILENAME).o : $(FILENAME).c
$(CC) $(CFLAGS) -DMODULE
-DKBUILD_BASENAME=$(FILENAME) -c $(FILENAME).c
Thanks a million for your notes.
Sam
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
^ permalink raw reply [flat|nested] 9+ messages in thread* Re: Module Compiling Problem
2004-05-24 1:49 ` Song Sam
@ 2004-05-24 5:06 ` Sam Ravnborg
2004-05-24 7:22 ` Query about KERNELLOAD Venkatesh Savithri Mahesh
2004-05-24 15:17 ` Module Compiling Problem Song Sam
0 siblings, 2 replies; 9+ messages in thread
From: Sam Ravnborg @ 2004-05-24 5:06 UTC (permalink / raw)
To: Song Sam; +Cc: Sam Ravnborg, linuxppc-embedded
On Mon, May 24, 2004 at 09:49:47AM +0800, Song Sam wrote:
> > When compiling an external module use:
> > for 2.4:
> > make -C $ERNELSRC SUBDIRS=$PWD modules
>
> Uh,$ERNELSRC or $KERNELSRC?
When compiling modules you better use the kbuild infrastructure, and
then also a kbuild makefile.
The way to use the kbuild infrastructure is to build your
modules with the above command, where $KERNELSRC is
the directory where you have the kernelsrc.
So you should use something like:
make -C /home/sam/src/kernel/v2.4.18/ SUBDIRS=$PWD modules
assuming the src of the kernel is located in
/home/sam/src/kernel/v2.4.18/
> [Makefile]
> CC = ppc_8xx-gcc
>
> # TOPDIR := $(shell /bin/pwd)
>
> FILENAME = myic
>
> MYPATH = /workspace/keep/dmt201/kernel
>
> CPPFLAGS := -D__KERNEL__ -D_REENTRANT
> -I$(MYPATH)/include
>
> CFLAGS := $(CPPFLAGS) -Wall -Wstrict-prototypes
> -Wno-trigraphs -O2 -fomit-frame-pointer \
> -fno-strict-aliasing -fno-common -g
> -I$(MYPATH)/arch/ppc -fsigned-char -msoft-float -pipe
> \
> -ffixed-r2 -Wno-uninitialized -mmultiple -mstring
>
> all : $(FILENAME).o
>
> clean :
> rm $(FILENAME).o
> $(FILENAME).o : $(FILENAME).c
> $(CC) $(CFLAGS) -DMODULE
> -DKBUILD_BASENAME=$(FILENAME) -c $(FILENAME).c
>
> Thanks a million for your notes.
Try with a Makefile like this:
[Makefile]
obj-m := myic.o
That should do it.
[Later you can add the clean stuff]
Sam
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
^ permalink raw reply [flat|nested] 9+ messages in thread
* Query about KERNELLOAD.
2004-05-24 5:06 ` Sam Ravnborg
@ 2004-05-24 7:22 ` Venkatesh Savithri Mahesh
2004-05-24 12:09 ` Mark Chambers
2004-05-24 15:17 ` Module Compiling Problem Song Sam
1 sibling, 1 reply; 9+ messages in thread
From: Venkatesh Savithri Mahesh @ 2004-05-24 7:22 UTC (permalink / raw)
To: linuxppc-embedded
Hi,
I am a novice, please forgive me if this is very trivial.
I am trying to run 2.4.16 kernel on a custom 8260 board with 128MB
sdram. I am using the TRACE32 JTAG emulator from Lauterbach.
I am unable to load with KERNELLOAD=0xc0000000.
When the KERNELLOAD is changed to some other value, say 0x06000000
kernel gets relocated to 0x0 succesfully but reaches a undef instruction
after a few instuctions after emtering the MMU_init function.
Please advise me. Thanks for any information.
>> V S Mahesh.
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
^ permalink raw reply [flat|nested] 9+ messages in thread* Re: Query about KERNELLOAD.
2004-05-24 7:22 ` Query about KERNELLOAD Venkatesh Savithri Mahesh
@ 2004-05-24 12:09 ` Mark Chambers
0 siblings, 0 replies; 9+ messages in thread
From: Mark Chambers @ 2004-05-24 12:09 UTC (permalink / raw)
To: Venkatesh Savithri Mahesh, linuxppc-embedded
Hi Venkatesh,
I think your problem is with the emulator setup. You don't ever want to
change KERNELLOAD unless you are a very advanced user. 0xc0000000 is a
virtual address - when the processor puts out an address in this range it is
translated by the MMU to an actual memory address. So when you change to
0x0600000 you are running without the MMU translation. So some things work,
but the kernel will never work properly this way.
Your emulator has to be smart enough to know how to translate
virtual-to-physical addresses in the linux kernel. Not all emulators can do
this, I don't think TRACE32 does (but check with manufacturer!). The
emulator that has the most support from linux is Abatron: www.abatron.ch
Also, once you get your kernel to boot, don't forget that you can use gdb
and gdbserver. You may be able to do some debugging by just realizing that
the physical address is usually the virtual address minus 0xc0000000. So if
the debugger shows 0xc0012345 the physical address is 0x12345.
Good luck,
Mark Chambers
> I am a novice, please forgive me if this is very trivial.
>
> I am trying to run 2.4.16 kernel on a custom 8260 board with 128MB
> sdram. I am using the TRACE32 JTAG emulator from Lauterbach.
>
> I am unable to load with KERNELLOAD=0xc0000000.
>
> When the KERNELLOAD is changed to some other value, say 0x06000000
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: Module Compiling Problem
2004-05-24 5:06 ` Sam Ravnborg
2004-05-24 7:22 ` Query about KERNELLOAD Venkatesh Savithri Mahesh
@ 2004-05-24 15:17 ` Song Sam
1 sibling, 0 replies; 9+ messages in thread
From: Song Sam @ 2004-05-24 15:17 UTC (permalink / raw)
To: Sam Ravnborg; +Cc: linuxppc-embedded
Sam Ravnborg <sam@ravnborg.org> you wrote:
> When compiling modules you better use the kbuild infrastructure,
> and then also a kbuild makefile. The way to use the kbuild
> infrastructure is to build your modules with the above command,
> where $KERNELSRC is the directory where you have the kernelsrc.So
> you should use something like: make -C /home/sam/src/kernel/v2.4.18/
> SUBDIRS=$PWD modules assuming the src of the kernel is located in
> /home/sam/src/kernel/v2.4.18/
Thanks for your detailed explaination.I should be
blamed to take $KERNELSRC as a command parameter.:-)
> Try with a Makefile like this:
> [Makefile]
> obj-m := myic.o
>
> That should do it.
Yeah,it did work right.When using it with "make -C
/workspace/keep/dmt201/kernel/ SUBDIRS=$PWD modules"
command,it found myic.c real problem as following:
myic.c:65:1: warning: "MODVERSIONS" redefined
<command line>:1:1: warning: this is the location of
the previous definition
make[1]: Leaving directory
`/workspace/myfilesystem/target/workdir/ic'
make: Leaving directory
`/workspace/keep/dmt201/kernel'
After removing "#define MODVERSIONS" in myic.c,module
compiling work well without any warning.
> [Later you can add the clean stuff]
OK,I added the clean staff in my Makefile like
clean :
rm myic.o
But I got the mess message as well.
[root@sam ic]# make clean
make: /scripts/pathdown.sh: Command not found
/usr/share/locale/en_US.iso885915/LC_MESSAGES/make.morm
myic.o
It did remove myic.o.Could there any better way to
clean myic.o?
I appreciated your instruction very much.The making
module method is better than my former one.:-)
Sam
** 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:[~2004-05-24 15:17 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-05-22 0:57 Framebuffer problems Christopher E Cordahi
2004-05-22 7:25 ` Module Compiling Problem Song Sam
2004-05-23 2:00 ` Song Sam
2004-05-23 18:34 ` Sam Ravnborg
2004-05-24 1:49 ` Song Sam
2004-05-24 5:06 ` Sam Ravnborg
2004-05-24 7:22 ` Query about KERNELLOAD Venkatesh Savithri Mahesh
2004-05-24 12:09 ` Mark Chambers
2004-05-24 15:17 ` Module Compiling Problem Song Sam
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).