linux-um archives
 help / color / mirror / Atom feed
From: "roland" <for_spam@gmx.de>
To: Henrik Nordstrom <hno@marasystems.com>
Cc: user-mode-linux-devel@lists.sourceforge.net,
	uml-user <user-mode-linux-user@lists.sourceforge.net>
Subject: [uml-devel] Re: bug in COW? -  Re: [uml-user] uml 2.6.0-test9 crash
Date: Sun, 30 Nov 2003 03:29:41 +0100	[thread overview]
Message-ID: <035a01c3b6e9$cfee1df0$2000000a@schlepptopp> (raw)
In-Reply-To: Pine.LNX.4.44.0311282234040.10367-100000@filer.marasystems.com

hi,
i have 2.6.0-test11-um running - as expected the error is still there.
i compiled a debug version and attached a debugger to the "hanging" uml-process:

linux:/uml/suse9 # gdb linux-2.6.0-test11-um-debug 2234
GNU gdb 5.3.92
Copyright 2003 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "i586-suse-linux"...
Attaching to program: /uml/suse9/linux-2.6.0-test11-um-debug, process 2234
0xa0002091 in munmap ()
(gdb) cont
Continuing.

Program received signal SIGSEGV, Segmentation fault.
0xa002a80b in cowify_req (req=0xa02236e4, dev=0xa022ab40)
    at arch/um/drivers/ubd_kern.c:820
820     arch/um/drivers/ubd_kern.c: No such file or directory.  <- ???
        in arch/um/drivers/ubd_kern.c
(gdb) cont
Continuing.

Program received signal SIGSEGV, Segmentation fault.
0xa002a80b in cowify_req (req=0xa02236e4, dev=0xa022ab40)
    at arch/um/drivers/ubd_kern.c:820
820     in arch/um/drivers/ubd_kern.c
(gdb) cont
Continuing.

Program received signal SIGSEGV, Segmentation fault.
0xa002a80b in cowify_req (req=0xa02236e4, dev=0xa022ab40)
    at arch/um/drivers/ubd_kern.c:820
820     in arch/um/drivers/ubd_kern.c
(gdb) 


so my speculation seems affirmed, that the bug is "somewhere inside COW".

here is the appropriate code snippet from ubd_kern.c :


    790 void cowify_req(struct io_thread_req *req, struct ubd *dev)
    791 {
    792         int i, update_bitmap, sector = req->offset >> 9;
    793
    794         if(req->length > (sizeof(req->sector_mask) * 8) << 9)
    795                 panic("Operation too long");
    796         if(req->op == UBD_READ) {
    797                 for(i = 0; i < req->length >> 9; i++){
    798                         if(ubd_test_bit(sector + i, (unsigned char *)
    799                                         dev->cow.bitmap)){
    800                                 ubd_set_bit(i, (unsigned char *)
    801                                             &req->sector_mask);
    802                         }
    803                 }
    804         }
    805         else {
    806                 update_bitmap = 0;
    807                 for(i = 0; i < req->length >> 9; i++){
    808                         ubd_set_bit(i, (unsigned char *)
    809                                     &req->sector_mask);
    810                         if(!ubd_test_bit(sector + i, (unsigned char *)
    811                                          dev->cow.bitmap))
    812                                 update_bitmap = 1;
    813                         ubd_set_bit(sector + i, (unsigned char *)
    814                                     dev->cow.bitmap);
    815                 }
    816                 if(update_bitmap){
    817                         req->cow_offset = sector / (sizeof(unsigned long) * 8);
    818                         req->bitmap_words[0] =
    819                                 dev->cow.bitmap[req->cow_offset];
    820                         req->bitmap_words[1] =
    821                                 dev->cow.bitmap[req->cow_offset + 1];
    822                         req->cow_offset *= sizeof(unsigned long);
    823                         req->cow_offset += dev->cow.bitmap_offset;
    824                 }
    825         }
    826 }


sorry, i have no real experience in debugging with gdb, nor am i a good c programmer.
does anybody have a clue whats going wrong here ?

regards
roland







----- Original Message ----- 
From: "Henrik Nordstrom" <hno@marasystems.com>
To: "roland" <for_spam@gmx.de>
Cc: <user-mode-linux-devel@lists.sourceforge.net>; "uml-user" <user-mode-linux-user@lists.sourceforge.net>
Sent: Friday, November 28, 2003 10:35 PM
Subject: Re: bug in COW? - Re: [uml-user] uml 2.6.0-test9 crash


> On Fri, 28 Nov 2003, roland wrote:
> 
> > thanks - will give it a try. i already were aware of bonnie, but i thought it
> > was just a benchmark program.
> 
> It is, by trying to stress the I/O as hard as possible in different 
> conditions.
> 
> > here is the output. 
> > the i/o stops, but uml still consumes cpu.
> 
> Then there most likely is a UML problem. Recommended action is to attach a
> debugger an look what the UML kernel is doing.
> 
> Regards
> Henrik
> 


-------------------------------------------------------
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
_______________________________________________
User-mode-linux-devel mailing list
User-mode-linux-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/user-mode-linux-devel

  reply	other threads:[~2003-11-30  2:25 UTC|newest]

Thread overview: 34+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <5.1.0.14.2.20031127102518.02675b90@mail.inboxprotection.com>
2003-11-27 21:06 ` [uml-devel] uml 2.6.0-test9 crash roland
2003-11-27 21:33   ` [uml-devel] Re: [uml-user] " Sven 'Darkman' Michels
2003-11-27 21:54     ` roland
2003-11-27 23:50     ` Henrik Nordstrom
2003-11-28  1:18       ` [uml-devel] bug in COW? - " roland
2003-11-28  1:28         ` [uml-devel] " Erik Walthinsen
2003-11-28  2:11           ` [uml-devel] How to copy COW files to another machine across the network? Shao-Lin Joseph Chung
2003-11-28  8:49             ` Henrik Nordstrom
2003-11-30 21:22               ` roland
2003-11-30 21:37                 ` Henrik Nordstrom
2003-11-30 23:31                   ` Nigel Cunningham
2003-12-01  9:12                     ` roland
2003-12-06  0:04                 ` [uml-user] " Jeff Dike
2003-12-06  0:05               ` Jeff Dike
2003-11-28  9:13             ` Geert Uytterhoeven
2003-11-29  9:24               ` Richard Potter
2003-12-06  0:05           ` [uml-devel] Re: bug in COW? - Re: [uml-user] uml 2.6.0-test9 crash Jeff Dike
2003-11-28  8:39         ` Henrik Nordstrom
2003-11-28 20:42           ` roland
2003-11-28 21:35             ` Henrik Nordstrom
2003-11-30  2:29               ` roland [this message]
2003-11-30  7:47                 ` Henrik Nordstrom
2003-11-30  8:23                 ` Lynn Kerby
2003-11-30 11:36                   ` roland
2003-12-06  0:05                     ` Jeff Dike
2003-12-06  9:41                       ` Henrik Nordstrom
2003-12-06 18:18                         ` Jeff Dike
2003-12-06 23:32                           ` Henrik Nordstrom
2003-12-08  1:20                             ` roland
2003-12-08 19:21                               ` Jeff Dike
2003-12-07 10:53                         ` [uml-devel] updating 2.6 to merge 2.4 changes(was: Re: bug in COW? - Re: [uml-user] uml 2.6.0-test9 crash) BlaisorBlade
2003-12-08 20:42                           ` Jeff Dike
2003-12-08 21:32                             ` Henrik Nordstrom
2003-12-08 23:50                               ` Jeff Dike

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='035a01c3b6e9$cfee1df0$2000000a@schlepptopp' \
    --to=for_spam@gmx.de \
    --cc=hno@marasystems.com \
    --cc=user-mode-linux-devel@lists.sourceforge.net \
    --cc=user-mode-linux-user@lists.sourceforge.net \
    /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
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox