diff options
author | Radim Krčmář <rkrcmar@redhat.com> | 2014-08-28 09:13:02 -0400 |
---|---|---|
committer | Paolo Bonzini <pbonzini@redhat.com> | 2014-08-29 10:35:55 -0400 |
commit | 0865e636aef751966e6e0f8950a26bc7391e923c (patch) | |
tree | ebd382925187756575fdbf677fe3a807f7e4d706 /arch/mips/kvm | |
parent | 656473003bc7e056c3bbd4a4d9832dad01e86f76 (diff) |
KVM: static inline empty kvm_arch functions
Using static inline is going to save few bytes and cycles.
For example on powerpc, the difference is 700 B after stripping.
(5 kB before)
This patch also deals with two overlooked empty functions:
kvm_arch_flush_shadow was not removed from arch/mips/kvm/mips.c
2df72e9bc KVM: split kvm_arch_flush_shadow
and kvm_arch_sched_in never made it into arch/ia64/kvm/kvm-ia64.c.
e790d9ef6 KVM: add kvm_arch_sched_in
Signed-off-by: Radim KrÄmář <rkrcmar@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'arch/mips/kvm')
-rw-r--r-- | arch/mips/kvm/mips.c | 42 |
1 files changed, 0 insertions, 42 deletions
diff --git a/arch/mips/kvm/mips.c b/arch/mips/kvm/mips.c index 2362df2a79f9..0ec7490d70bd 100644 --- a/arch/mips/kvm/mips.c +++ b/arch/mips/kvm/mips.c | |||
@@ -82,19 +82,11 @@ int kvm_arch_hardware_enable(void *garbage) | |||
82 | return 0; | 82 | return 0; |
83 | } | 83 | } |
84 | 84 | ||
85 | void kvm_arch_hardware_disable(void *garbage) | ||
86 | { | ||
87 | } | ||
88 | |||
89 | int kvm_arch_hardware_setup(void) | 85 | int kvm_arch_hardware_setup(void) |
90 | { | 86 | { |
91 | return 0; | 87 | return 0; |
92 | } | 88 | } |
93 | 89 | ||
94 | void kvm_arch_hardware_unsetup(void) | ||
95 | { | ||
96 | } | ||
97 | |||
98 | void kvm_arch_check_processor_compat(void *rtn) | 90 | void kvm_arch_check_processor_compat(void *rtn) |
99 | { | 91 | { |
100 | *(int *)rtn = 0; | 92 | *(int *)rtn = 0; |
@@ -163,10 +155,6 @@ void kvm_mips_free_vcpus(struct kvm *kvm) | |||
163 | mutex_unlock(&kvm->lock); | 155 | mutex_unlock(&kvm->lock); |
164 | } | 156 | } |
165 | 157 | ||
166 | void kvm_arch_sync_events(struct kvm *kvm) | ||
167 | { | ||
168 | } | ||
169 | |||
170 | static void kvm_mips_uninit_tlbs(void *arg) | 158 | static void kvm_mips_uninit_tlbs(void *arg) |
171 | { | 159 | { |
172 | /* Restore wired count */ | 160 | /* Restore wired count */ |
@@ -194,21 +182,12 @@ long kvm_arch_dev_ioctl(struct file *filp, unsigned int ioctl, | |||
194 | return -ENOIOCTLCMD; | 182 | return -ENOIOCTLCMD; |
195 | } | 183 | } |
196 | 184 | ||
197 | void kvm_arch_free_memslot(struct kvm *kvm, struct kvm_memory_slot *free, | ||
198 | struct kvm_memory_slot *dont) | ||
199 | { | ||
200 | } | ||
201 | |||
202 | int kvm_arch_create_memslot(struct kvm *kvm, struct kvm_memory_slot *slot, | 185 | int kvm_arch_create_memslot(struct kvm *kvm, struct kvm_memory_slot *slot, |
203 | unsigned long npages) | 186 | unsigned long npages) |
204 | { | 187 | { |
205 | return 0; | 188 | return 0; |
206 | } | 189 | } |
207 | 190 | ||
208 | void kvm_arch_memslots_updated(struct kvm *kvm) | ||
209 | { | ||
210 | } | ||
211 | |||
212 | int kvm_arch_prepare_memory_region(struct kvm *kvm, | 191 | int kvm_arch_prepare_memory_region(struct kvm *kvm, |
213 | struct kvm_memory_slot *memslot, | 192 | struct kvm_memory_slot *memslot, |
214 | struct kvm_userspace_memory_region *mem, | 193 | struct kvm_userspace_memory_region *mem, |
@@ -254,19 +233,6 @@ void kvm_arch_commit_memory_region(struct kvm *kvm, | |||
254 | } | 233 | } |
255 | } | 234 | } |
256 | 235 | ||
257 | void kvm_arch_flush_shadow_all(struct kvm *kvm) | ||
258 | { | ||
259 | } | ||
260 | |||
261 | void kvm_arch_flush_shadow_memslot(struct kvm *kvm, | ||
262 | struct kvm_memory_slot *slot) | ||
263 | { | ||
264 | } | ||
265 | |||
266 | void kvm_arch_flush_shadow(struct kvm *kvm) | ||
267 | { | ||
268 | } | ||
269 | |||
270 | struct kvm_vcpu *kvm_arch_vcpu_create(struct kvm *kvm, unsigned int id) | 236 | struct kvm_vcpu *kvm_arch_vcpu_create(struct kvm *kvm, unsigned int id) |
271 | { | 237 | { |
272 | int err, size, offset; | 238 | int err, size, offset; |
@@ -998,14 +964,6 @@ int kvm_arch_vcpu_init(struct kvm_vcpu *vcpu) | |||
998 | return 0; | 964 | return 0; |
999 | } | 965 | } |
1000 | 966 | ||
1001 | void kvm_arch_vcpu_uninit(struct kvm_vcpu *vcpu) | ||
1002 | { | ||
1003 | } | ||
1004 | |||
1005 | void kvm_arch_sched_in(struct kvm_vcpu *vcpu, int cpu) | ||
1006 | { | ||
1007 | } | ||
1008 | |||
1009 | int kvm_arch_vcpu_ioctl_translate(struct kvm_vcpu *vcpu, | 967 | int kvm_arch_vcpu_ioctl_translate(struct kvm_vcpu *vcpu, |
1010 | struct kvm_translation *tr) | 968 | struct kvm_translation *tr) |
1011 | { | 969 | { |