public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Gleb Natapov <gleb@redhat.com>
To: Paolo Bonzini <pbonzini@redhat.com>
Cc: linux-kernel@vger.kernel.org, kvm@vger.kernel.org,
	tim.gardner@canonical.com, torvalds@linux-foundation.org
Subject: Re: [PATCH] KVM: use a more sensible error number when debugfs directory creation fails
Date: Wed, 30 Oct 2013 13:20:50 +0200	[thread overview]
Message-ID: <20131030112050.GF4651@redhat.com> (raw)
In-Reply-To: <1383131852-5566-1-git-send-email-pbonzini@redhat.com>

On Wed, Oct 30, 2013 at 12:17:32PM +0100, Paolo Bonzini wrote:
> I don't know if this was due to cut and paste, or somebody was really
> using a D20 to pick the error code for kvm_init_debugfs as suggested by
> Linus (EFAULT is 14, so the possibility cannot be entirely ruled out).
> 
Heh.

> In any case, this patch fixes it.
> 
Acked-by: Gleb Natapov <gleb@redhat.com>

> Reported-by: Tim Gardner <tim.gardner@canonical.com>
> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
> ---
>  virt/kvm/kvm_main.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/virt/kvm/kvm_main.c b/virt/kvm/kvm_main.c
> index a9dd682cf5e3..1cf9ccb01013 100644
> --- a/virt/kvm/kvm_main.c
> +++ b/virt/kvm/kvm_main.c
> @@ -3091,7 +3091,7 @@ static const struct file_operations *stat_fops[] = {
>  
>  static int kvm_init_debug(void)
>  {
> -	int r = -EFAULT;
> +	int r = -EEXIST;
>  	struct kvm_stats_debugfs_item *p;
>  
>  	kvm_debugfs_dir = debugfs_create_dir("kvm", NULL);
> -- 
> 1.8.3.1

--
			Gleb.

      reply	other threads:[~2013-10-30 11:21 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-10-30 11:17 [PATCH] KVM: use a more sensible error number when debugfs directory creation fails Paolo Bonzini
2013-10-30 11:20 ` Gleb Natapov [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20131030112050.GF4651@redhat.com \
    --to=gleb@redhat.com \
    --cc=kvm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=pbonzini@redhat.com \
    --cc=tim.gardner@canonical.com \
    --cc=torvalds@linux-foundation.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox