Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 7021
b: refs/heads/master
c: 0221575
h: refs/heads/master
i:
  7019: 59cf0f6
v: v3
  • Loading branch information
Paolo 'Blaisorblade' Giarrusso authored and Linus Torvalds committed Sep 5, 2005
1 parent 12f64f9 commit c528faf
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 5 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 640aa46e25922a00b805e6b0d0b5181ad9cf736a
refs/heads/master: 0221575903ad68debea57679b5b46575bf57afb1
11 changes: 11 additions & 0 deletions trunk/arch/um/Kconfig.debug
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,17 @@ menu "Kernel hacking"

source "lib/Kconfig.debug"

config CMDLINE_ON_HOST
bool "Show command line arguments on the host in TT mode"
depends on MODE_TT
default !DEBUG_INFO
help
This controls whether arguments in guest processes should be shown on
the host's ps output.
Enabling this option hinders debugging on some recent GDB versions
(because GDB gets "confused" when we do an execvp()). So probably you
should disable it.

config PT_PROXY
bool "Enable ptrace proxy"
depends on XTERM_CHAN && DEBUG_INFO && MODE_TT
Expand Down
2 changes: 1 addition & 1 deletion trunk/arch/um/kernel/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ int main(int argc, char **argv, char **envp)
exit(1);
}

#ifdef UML_CONFIG_MODE_TT
#ifdef UML_CONFIG_CMDLINE_ON_HOST
/* Allocate memory for thread command lines */
if(argc < 2 || strlen(argv[1]) < THREAD_NAME_LEN - 1){

Expand Down
6 changes: 3 additions & 3 deletions trunk/arch/um/kernel/um_arch.c
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ unsigned long start_vm;
unsigned long end_vm;
int ncpus = 1;

#ifdef CONFIG_MODE_TT
#ifdef CONFIG_CMDLINE_ON_HOST
/* Pointer set in linux_main, the array itself is private to each thread,
* and changed at address space creation time so this poses no concurrency
* problems.
Expand All @@ -141,7 +141,7 @@ long physmem_size = 32 * 1024 * 1024;

void set_cmdline(char *cmd)
{
#ifdef CONFIG_MODE_TT
#ifdef CONFIG_CMDLINE_ON_HOST
char *umid, *ptr;

if(CHOOSE_MODE(honeypot, 0)) return;
Expand Down Expand Up @@ -385,7 +385,7 @@ int linux_main(int argc, char **argv)

setup_machinename(system_utsname.machine);

#ifdef CONFIG_MODE_TT
#ifdef CONFIG_CMDLINE_ON_HOST
argv1_begin = argv[1];
argv1_end = &argv[1][strlen(argv[1])];
#endif
Expand Down

0 comments on commit c528faf

Please sign in to comment.