From: Rusty Russell Date: Wed, 1 Aug 2007 00:12:22 +0000 (+1000) Subject: KVM: Remove stat_set from debugfs X-Git-Tag: v2.6.24-rc1~1365^2~59 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3dea7ca7160f80dd6d31c0bbeb2d871e51b567b6;p=linux-2.6 KVM: Remove stat_set from debugfs We shouldn't define stat_set on the debug attributes, since that will cause silent failure on writing: without a set argument, userspace will get -EACCESS. Signed-off-by: Rusty Russell Signed-off-by: Avi Kivity --- diff --git a/drivers/kvm/kvm_main.c b/drivers/kvm/kvm_main.c index 55639aceca..25d76a5a99 100644 --- a/drivers/kvm/kvm_main.c +++ b/drivers/kvm/kvm_main.c @@ -3017,11 +3017,7 @@ static u64 stat_get(void *_offset) return total; } -static void stat_set(void *offset, u64 val) -{ -} - -DEFINE_SIMPLE_ATTRIBUTE(stat_fops, stat_get, stat_set, "%llu\n"); +DEFINE_SIMPLE_ATTRIBUTE(stat_fops, stat_get, NULL, "%llu\n"); static __init void kvm_init_debug(void) {