aboutsummaryrefslogtreecommitdiffhomepage
path: root/tools
diff options
context:
space:
mode:
authorjohannst <johannst@users.noreply.github.com>2021-06-20 22:11:42 +0000
committerjohannst <johannst@users.noreply.github.com>2021-06-20 22:11:42 +0000
commit7dd27f2a72395e51db76ee344ffba56279d5c6ff (patch)
treefc08e7a7dae829716b715786b8d9ce009c515479 /tools
parentc665746d56789eba694af507429337ac54f3cd23 (diff)
downloadnotes-7dd27f2a72395e51db76ee344ffba56279d5c6ff.tar.gz
notes-7dd27f2a72395e51db76ee344ffba56279d5c6ff.zip
deploy: 97c6252800e020af05f0e0d7afc037c04753bc83
Diffstat (limited to 'tools')
-rw-r--r--tools/qemu.html11
1 files changed, 11 insertions, 0 deletions
diff --git a/tools/qemu.html b/tools/qemu.html
index 418a9fe..03fd8bc 100644
--- a/tools/qemu.html
+++ b/tools/qemu.html
@@ -156,11 +156,17 @@
<p>All the examples &amp; notes use <code>qemu-system-x86_64</code> but in most cases
this can be swapped with the system emulator for other architectures.</p>
<h2><a class="header" href="#keybindings" id="keybindings">Keybindings</a></h2>
+<p>Graphic mode:</p>
<pre><code class="language-markdown">Ctrl+Alt+g release mouse capture from VM
Ctrl+Alt+1 switch to display of VM
Ctrl+Alt+2 switch to qemu monitor
</code></pre>
+<p>No graphic mode:</p>
+<pre><code class="language-markdown">Ctrl+a h print help
+Ctrl+a x exit emulator
+Ctrl+a c switch between monitor and console
+</code></pre>
<h2><a class="header" href="#vm-config-snippet" id="vm-config-snippet">VM config snippet</a></h2>
<p>Following command-line gives a good starting point to assemble a VM:</p>
<pre><code class="language-bash">qemu-system-x86_64 \
@@ -232,6 +238,11 @@ lsblk -f /dev/sda
<ul>
<li><code>-device usb-host,bus=xhci.0,vendorid=0x05e1,productid=0x0408</code> pass-through USB device from host identified by vendorid &amp; productid and attach to usb bus <code>xhci.0</code> (defined with controller <code>id</code>)</li>
</ul>
+<h2><a class="header" href="#debugging" id="debugging">Debugging</a></h2>
+<ul>
+<li><code>-gdb tcp::&lt;port&gt;</code> open gdbstub on tcp <code>&lt;port&gt;</code> (<code>-s</code> shorthand for <code>-gdb tcp::1234</code>).</li>
+<li><code>-S</code> freeze CPU at startup.</li>
+</ul>
<h2><a class="header" href="#references" id="references">References</a></h2>
<ul>
<li><a href="https://github.com/qemu/qemu/blob/master/docs/usb2.txt">QEMU USB</a></li>