LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
From: Antoine Martin <antoine@nagafix.co.uk>
To: Geert Uytterhoeven <geert@linux-m68k.org>
Cc: Jeff Dike <jdike@addtoit.com>,
	Blaisorblade <blaisorblade@yahoo.it>,
	devzero@web.de,
	User-mode Linux Kernel Development 
	<user-mode-linux-devel@lists.sourceforge.net>,
	Linux Kernel Development <linux-kernel@vger.kernel.org>,
	kraxel@suse.de
Subject: Re: [uml-devel] [RFC] UML kernel & rootfs bundle with every kernel release ?
Date: Wed, 04 Apr 2007 21:27:22 +0100	[thread overview]
Message-ID: <46140A2A.9050609@nagafix.co.uk> (raw)
In-Reply-To: <Pine.LNX.4.64.0704040834450.20803@anakin>

Geert Uytterhoeven wrote:
> On Wed, 4 Apr 2007, Antoine Martin wrote:
>> and this one:
>> http://www.suse.de/~kraxel/uml/patches/2.6.18-rc4/uml-x11-fb
>> which applied cleanly, but is not letting me set the option - Kconfig is
>> beyond me:
>>
>> arch/um/Kconfig:144:warning: 'select' used by config symbol 'X11_FB' refer to
>> undefined symbol 'FB_CFB_FILLRECT'
>> arch/um/Kconfig:145:warning: 'select' used by config symbol 'X11_FB' refer to
>> undefined symbol 'FB_CFB_COPYAREA'
>> arch/um/Kconfig:146:warning: 'select' used by config symbol 'X11_FB' refer to
>> undefined symbol 'FB_CFB_IMAGEBLIT'
> 
> Try adding
> 
>     source "drivers/video/Kconfig"
> 
> to arch/um/Kconfig.
Ahh, thanks for that, it did the trick.

I also needed to add this to include/asm-um/pgtable.h:
#define io_remap_pfn_range(vma, vaddr, pfn, size, prot)         \
                 remap_pfn_range(vma, vaddr, pfn, size, prot)

And replace config.h with autoconf.h in arch/um/drivers/x11_kern.c

Then I hit:
arch/um/drivers/built-in.o:include/linux/input.h:1168: more undefined 
references to `input_event' follow
So I added: "select INPUT" to Kconfig
(starting with a defconfig might have done the trick too)

Then I hit:
arch/um/drivers/built-in.o: In function `x11_probe':
arch/um/drivers/x11_kern.c:442: undefined reference to `init_input_dev'
So I replaced:
         init_input_dev(kd->mouse);
with:
	kd->mouse = input_allocate_device();

That gave me a working kernel, but no x11 window appeared....
(I tried adding x11=640x480 to the command line too - no effect)

I then tried this patch:
http://user-mode-linux.sourceforge.net/work/current/2.6/2.6.21-rc1/patches/x11-fb
(fixing similar issues)

I had to comment out the line containing "soft_cursor" (couldn't figure 
out where to get it from)
It also required a lot of search and replace to change all instances of:
	kd->mouse.XXX
to
	kd->mouse->XXX
(same for kbd and changes to the initialization code)


Looks like the CONFIG_FB_CFB_FILLRECT and friends should not be set:
   LD      .tmp_vmlinux1
drivers/built-in.o: In function `cfb_copyarea':
drivers/video/cfbcopyarea.c:344: multiple definition of `cfb_copyarea'
arch/um/drivers/built-in.o:arch/um/drivers/../../../drivers/video/cfbcopyarea.c:344: 
first defined here
drivers/built-in.o: In function `cfb_imageblit':
drivers/video/cfbimgblt.c:263: multiple definition of `cfb_imageblit'
arch/um/drivers/built-in.o:arch/um/drivers/../../../drivers/video/cfbimgblt.c:263: 
first defined here
drivers/built-in.o: In function `cfb_fillrect':
drivers/video/cfbfillrect.c:345: multiple definition of `cfb_fillrect'
arch/um/drivers/built-in.o:arch/um/drivers/../../../drivers/video/cfbfillrect.c:345: 


Finally, this one pops up an X11 window, but it dies instantly:
[...]
Checking syscall emulation patch for ptrace...missing

Program received signal SIGSEGV, Segmentation fault.
kref_get (kref=0x5a5a5a5a5a5a5aa6) at lib/kref.c:32
32              WARN_ON(!atomic_read(&kref->refcount));
(gdb) bt
#0  kref_get (kref=0x5a5a5a5a5a5a5aa6) at lib/kref.c:32
#1  0x00000000600f4aa2 in kobject_get (kobj=0x5a5a5a5a5a5a5a8a) at 
lib/kobject.c:394
#2  0x0000000060109a95 in class_get (cls=<value optimized out>) at 
include/linux/kobject.h:145
#3  0x000000006010a3e5 in class_device_add (class_dev=0x602c9b38) at 
drivers/base/class.c:594
#4  0x000000006010ff5d in input_register_device (dev=0x602c9488) at 
drivers/input/input.c:987
#5  0x000000006001ed60 in x11_probe () at arch/um/drivers/x11_kern.c:482
#6  0x000000006000444d in x11_init () at arch/um/drivers/x11_kern.c:504
#7  0x00000000600015a6 in do_initcalls () at init/main.c:651
#8  0x0000000060001690 in do_basic_setup () at init/main.c:695
#9  0x000000006000f9ce in init (unused=<value optimized out>) at 
init/main.c:744
#10 0x00000000600241ca in run_kernel_thread (fn=0x6000f985 <init>, 
arg=0x0, jmp_ptr=<value optimized out>)
     at arch/um/os-Linux/process.c:289
#11 0x00000000600149b8 in new_thread_handler () at 
arch/um/kernel/skas/process.c:64
#12 0xa55a5a5a5a5a5a5a in ?? ()
#13 0x00000000602bd100 in ?? ()
#14 0x0000000060205f40 in ident_map ()
#15 0x0000000000000000 in ?? ()

And I am now completely out of my depth!

Antoine

> 
> Gr{oetje,eeting}s,
> 
> 						Geert
> 
> --
> Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org
> 
> In personal conversations with technical people, I call myself a hacker. But
> when I'm talking to journalists I just say "programmer" or something like that.
> 							    -- Linus Torvalds
> 


  reply	other threads:[~2007-04-04 20:27 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-03-31 22:58 devzero
2007-04-01  0:01 ` Parag Warudkar
2007-04-01 19:08 ` Blaisorblade
2007-04-01 19:58   ` [uml-devel] " Antoine Martin
2007-04-02  2:05     ` Jeff Dike
2007-04-02 10:21       ` Antoine Martin
2007-04-02 11:22         ` Geert Uytterhoeven
2007-04-02 12:50           ` Geert Uytterhoeven
2007-04-02 14:53           ` Jeff Dike
2007-04-02 15:43             ` Antoine Martin
2007-04-03 23:49               ` Antoine Martin
2007-04-04  6:35                 ` Geert Uytterhoeven
2007-04-04 20:27                   ` Antoine Martin [this message]
2007-04-02 14:55         ` Jeff Dike
2007-04-02 15:43           ` Antoine Martin
2007-04-02 20:40         ` roland
2007-04-02 21:44           ` Jeff Dike
2007-04-03  4:44             ` Jason Lunz
2007-04-03 17:43         ` Blaisorblade
2007-04-03 17:53           ` Antoine Martin
2007-04-03  8:28 roland
2007-04-03 18:01 ` Jason Lunz

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=46140A2A.9050609@nagafix.co.uk \
    --to=antoine@nagafix.co.uk \
    --cc=blaisorblade@yahoo.it \
    --cc=devzero@web.de \
    --cc=geert@linux-m68k.org \
    --cc=jdike@addtoit.com \
    --cc=kraxel@suse.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=user-mode-linux-devel@lists.sourceforge.net \
    --subject='Re: [uml-devel] [RFC] UML kernel & rootfs bundle with every kernel release ?' \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

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