All of lore.kernel.org
 help / color / mirror / Atom feed
From: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
To: Marc Gonzalez <marc.w.gonzalez@free.fr>
Cc: LKML <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] msm: no need to check return value of debugfs_create functions
Date: Thu, 13 Jun 2019 15:01:10 +0200	[thread overview]
Message-ID: <20190613130110.GA803@kroah.com> (raw)
In-Reply-To: <0c09e99e-5cce-5899-d1c6-98791fbd82e0@free.fr>

On Thu, Jun 13, 2019 at 02:37:46PM +0200, Marc Gonzalez wrote:
> On 13/06/2019 14:24, Greg Kroah-Hartman wrote:
> 
> > When calling debugfs functions, there is no need to ever check the
> > return value.  The function can work or not, but the code logic should
> > never do something different based on this.
> 
> Naive question: if callers are supposed to ignore the return value,
> why not change the prototype to void (no return value) ?

I am trying to do that, but sometimes you need the return value (like
for debugfs_create_dir()).  I have removed the return value from a
number of debugfs calls already, but the kernel is vast and big, and the
tendrils of debugfs use is deep, it is taking a while :)

Don't worry, there are more patches to come, this is just the first
wave.

thanks,

greg k-h

      reply	other threads:[~2019-06-13 15:19 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-06-13 12:24 [PATCH] msm: no need to check return value of debugfs_create functions Greg Kroah-Hartman
2019-06-13 12:24 ` Greg Kroah-Hartman
2019-06-13 12:37 ` Marc Gonzalez
2019-06-13 13:01   ` Greg Kroah-Hartman [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=20190613130110.GA803@kroah.com \
    --to=gregkh@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=marc.w.gonzalez@free.fr \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.