commit | 38772ab4864f64842e42871e12d4c0c09595aec1 | [log] [tgz] |
---|---|---|
author | Andrew Scull <ascull@google.com> | Thu Jan 24 15:16:50 2019 +0000 |
committer | Andrew Scull <ascull@google.com> | Thu Jan 24 15:16:50 2019 +0000 |
tree | 3144d91c50ac35366f0fde0625fbd4206ae8effd | |
parent | 2e7a76dbc9e6ecc15fa94f318298f448c2e11a39 [diff] [blame] |
Re-constify pointer to current. It doesn't actually get modified so can remain const. Change-Id: I861a438b55a377496dc7794e25592fd5a02555c3
diff --git a/src/cpu.c b/src/cpu.c index f87d78d..03e0074 100644 --- a/src/cpu.c +++ b/src/cpu.c
@@ -156,7 +156,7 @@ sl_unlock(&vcpu->lock); } -size_t vcpu_index(struct vcpu *vcpu) +size_t vcpu_index(const struct vcpu *vcpu) { return vcpu - vcpu->vm->vcpus; }