From: Werner Almesberger <werner@almesberger.net>
To: jdike@addtoit.com
Cc: user-mode-linux-devel@lists.sourceforge.net
Subject: [uml-devel] patch/RFC: add bypass for "debug" parameter
Date: Sun, 8 Feb 2004 18:53:34 -0300 [thread overview]
Message-ID: <20040208185334.H9021@almesberger.net> (raw)
Since UML ursurps the "debug" parameter, we can't make the kernel
more verbose before user space runs. This patch adds a new option
"kernel" that has the same effect as the original "debug".
Slightly kludgy, but gets the job done :-)
The patch is for 2.6.1 with uml-patch-2.6.1-1.
- Werner
--- linux-2.6.1/arch/um/kernel/tt/tracer.c.orig Sun Feb 8 18:15:18 2004
+++ linux-2.6.1/arch/um/kernel/tt/tracer.c Sun Feb 8 18:44:51 2004
@@ -391,10 +391,19 @@
{
char *next;
- debug = 1;
- *add = 0;
- if(*line != '=') return(0);
- line++;
+ if (!strncmp(line, "=kernel", 7)) {
+ *line = 0;
+ if (line[7] != ',')
+ return 0;
+ line += 8;
+ debug = 1;
+ }
+ else {
+ debug = 1;
+ *add = 0;
+ if(*line != '=') return(0);
+ line++;
+ }
while(line != NULL){
next = strchr(line, ',');
@@ -410,10 +419,15 @@
}
__uml_setup("debug", uml_debug_setup,
-"debug\n"
-" Starts up the kernel under the control of gdb. See the \n"
-" kernel debugging tutorial and the debugging session pages\n"
-" at http://user-mode-linux.sourceforge.net/ for more information.\n\n"
+"debug[=kernel,go,parent]\n"
+" \"debug=kernel\" changes the kernel log level such that debugging\n"
+" printks are printed on the console. This is equivalent to the \"debug\"\n"
+" option in a non-UML kernel. If \"debug=kernel\" is used with other\n"
+" options, it must be the first option in the list.\n"
+" The other options (or just plain \"debug\") start up the kernel under\n"
+" the control of gdb. See the kernel debugging tutorial and the\n"
+" debugging session pages at http://user-mode-linux.sourceforge.net/\n"
+" for more information.\n\n"
);
static int __init uml_debugtrace_setup(char *line, int *add)
--
_________________________________________________________________________
/ Werner Almesberger, Buenos Aires, Argentina werner@almesberger.net /
/_http://www.almesberger.net/____________________________________________/
-------------------------------------------------------
The SF.Net email is sponsored by EclipseCon 2004
Premiere Conference on Open Tools Development and Integration
See the breadth of Eclipse activity. February 3-5 in Anaheim, CA.
http://www.eclipsecon.org/osdn
_______________________________________________
User-mode-linux-devel mailing list
User-mode-linux-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/user-mode-linux-devel
next reply other threads:[~2004-02-08 21:53 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-02-08 21:53 Werner Almesberger [this message]
2004-02-12 15:49 ` [uml-devel] Re: patch/RFC: add bypass for "debug" parameter Jeff Dike
2004-02-13 0:40 ` Werner Almesberger
2004-02-13 9:53 ` Geert Uytterhoeven
2004-02-13 17:15 ` Werner Almesberger
2004-02-13 17:18 ` Geert Uytterhoeven
2004-02-13 18:43 ` Werner Almesberger
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=20040208185334.H9021@almesberger.net \
--to=werner@almesberger.net \
--cc=jdike@addtoit.com \
--cc=user-mode-linux-devel@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