]> git.karo-electronics.de Git - karo-tx-linux.git/commit
KVM: s390: fix and enforce return code handling for irq injections
authorHeiko Carstens <heiko.carstens@de.ibm.com>
Mon, 25 Mar 2013 16:22:53 +0000 (17:22 +0100)
committerGleb Natapov <gleb@redhat.com>
Tue, 2 Apr 2013 13:14:39 +0000 (16:14 +0300)
commitdb4a29cb6ac7b2fda505923bdbc58fc35a719f62
treefdd5a066cf77e511e6d28d79e525a6a23638487e
parent3736b874a39a1df2a94186c357aabeb6a7d7d4f6
KVM: s390: fix and enforce return code handling for irq injections

kvm_s390_inject_program_int() and friends may fail if no memory is available.
This must be reported to the calling functions, so that this gets passed
down to user space which should fix the situation.
Alternatively we end up with guest state corruption.

So fix this and enforce return value checking by adding a __must_check
annotation to all of these function prototypes.

Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
Acked-by: Cornelia Huck <cornelia.huck@de.ibm.com>
Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com>
Signed-off-by: Gleb Natapov <gleb@redhat.com>
arch/s390/kvm/intercept.c
arch/s390/kvm/kvm-s390.c
arch/s390/kvm/kvm-s390.h
arch/s390/kvm/priv.c