aboutsummaryrefslogtreecommitdiffstats
path: root/android_console.c
diff options
context:
space:
mode:
authorThe Android Open Source Project <initial-contribution@android.com>2008-12-17 18:04:49 -0800
committerThe Android Open Source Project <initial-contribution@android.com>2008-12-17 18:04:49 -0800
commitdf7881f07f53b041dc0568be8528e9dbb74994cc (patch)
tree1b3e036f7df4241bf0c2d527b73198c50e1d7891 /android_console.c
parent55f4e4a5ec657a017e3bf75299ad71fd1c968dd3 (diff)
downloadexternal_qemu-df7881f07f53b041dc0568be8528e9dbb74994cc.zip
external_qemu-df7881f07f53b041dc0568be8528e9dbb74994cc.tar.gz
external_qemu-df7881f07f53b041dc0568be8528e9dbb74994cc.tar.bz2
Code drop from //branches/cupcake/...@124589
Diffstat (limited to 'android_console.c')
-rw-r--r--android_console.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/android_console.c b/android_console.c
index 50af155..a83bb85 100644
--- a/android_console.c
+++ b/android_console.c
@@ -30,6 +30,7 @@
#include "shaper.h"
#include "modem_driver.h"
#include "android_gps.h"
+#include "android/globals.h"
#include <stdlib.h>
#include <stdio.h>
@@ -1853,6 +1854,13 @@ do_vm_status( ControlClient client, char* args )
return 0;
}
+static int
+do_vm_name( ControlClient client, char* args )
+{
+ control_write( client, "%s\r\n", avmInfo_getName(android_vmInfo) );
+ return 0;
+}
+
static const CommandDefRec vm_commands[] =
{
{ "stop", "stop the virtual machine",
@@ -1867,6 +1875,10 @@ static const CommandDefRec vm_commands[] =
"'vm status' will indicate wether the virtual machine is running or not\r\n",
NULL, do_vm_status, NULL },
+ { "name", "query virtual machine name",
+ "'vm name' will return the name of this virtual machine\r\n",
+ NULL, do_vm_name, NULL },
+
{ NULL, NULL, NULL, NULL, NULL, NULL }
};