Linux virtualization list
 help / color / mirror / Atom feed
From: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
To: Arnd Bergmann <arnd@arndb.de>
Cc: Amit Shah <amit.shah@redhat.com>,
	Sasha Levin <sasha.levin@oracle.com>,
	linux-kernel@vger.kernel.org,
	virtualization@lists.linux-foundation.org
Subject: Re: [PATCH] virtio_console: correct error message on failure of debugfs_create_dir
Date: Mon, 24 Dec 2012 09:39:37 -0800	[thread overview]
Message-ID: <20121224173937.GB14754@kroah.com> (raw)
In-Reply-To: <201212241155.46866.arnd@arndb.de>

On Mon, Dec 24, 2012 at 11:55:46AM +0000, Arnd Bergmann wrote:
> On Friday 21 December 2012, Amit Shah wrote:
> > On (Thu) 20 Dec 2012 [14:11:21], Sasha Levin wrote:
> > > debugfs_create_dir() returns NULL if it fails, there's little point in
> > > calling PTR_ERR on it.
> >
> > debugfs_create_dir() does return an error value if debugfs is not
> > enabled.
> > 
> > This check for !pdrvdata.debugfs_dir should infact use
> > IS_ERR_OR_NULL().  Care to submit a patch for that?
> 
> How about we fix the stub instead to return NULL when debugfs is disabled?

No, please read debugfs.h for why I decided to not do this (i.e. we try
to learn from our mistakes...)

thanks,

greg k-h

  parent reply	other threads:[~2012-12-24 17:39 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <1356030701-16284-1-git-send-email-sasha.levin@oracle.com>
2012-12-20 19:11 ` [PATCH] virtio_console: correct error message on failure of debugfs_create_dir Sasha Levin
     [not found] ` <1356030701-16284-13-git-send-email-sasha.levin@oracle.com>
2012-12-21  7:59   ` Amit Shah
2012-12-24 11:55     ` Arnd Bergmann
     [not found]     ` <201212241155.46866.arnd@arndb.de>
2012-12-24 17:39       ` Greg Kroah-Hartman [this message]
2012-12-24 18:24         ` Sasha Levin
2012-12-24 18:43           ` Greg Kroah-Hartman

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=20121224173937.GB14754@kroah.com \
    --to=gregkh@linuxfoundation.org \
    --cc=amit.shah@redhat.com \
    --cc=arnd@arndb.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=sasha.levin@oracle.com \
    --cc=virtualization@lists.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