From: Joel Becker <Joel.Becker@oracle.com>
To: Ingo Molnar <mingo@elte.hu>
Cc: Randy Dunlap <randy.dunlap@oracle.com>,
"Stephen M. Cameron" <scameron@beardog.cca.cpqcorp.net>,
Mike Christie <michaelc@cs.wisc.edu>,
David Airlie <airlied@linux.ie>,
James Bottomley <James.Bottomley@HansenPartnership.com>,
Jens Axboe <jens.axboe@oracle.com>,
Evgeniy Polyakov <zbr@ioremap.net>,
iss_storagedev@hp.com, Eric Dumazet <eric.dumazet@gmail.com>,
Andy Whitcroft <apw@shadowen.org>,
Dave Airlie <airlied@redhat.com>,
Hannes Eder <hannes@hanneseder.net>,
dri-devel@lists.sourceforge.net,
Alexey Dobriyan <adobriyan@gmail.com>,
Mike Miller <mike.miller@hp.com>, Mark Fasheh <mfasheh@suse.com>,
Karsten Keil <isdn@linux-pingi.de>,
rostedt@goodmis.org, Karen Xie <kxie@chelsio.com>,
"James E.J. Bottomley" <James.Bottomley@suse.de>,
Hannes Reinecke <hare@suse.de>,
Andreas
Subject: Re: [patch] Fix: 'return -ENOMEM' instead of 'return ENOMEM'
Date: Fri, 13 Nov 2009 03:56:10 -0800 [thread overview]
Message-ID: <20091113115610.GB28530@mail.oracle.com> (raw)
In-Reply-To: <20091113075306.GB2775@elte.hu>
On Fri, Nov 13, 2009 at 08:53:06AM +0100, Ingo Molnar wrote:
> > Sorry, I read the code wrong. This function is just a handler. The
> > caller, dlm_send_begin_reco_message(), expects the positive EAGAIN as
> > a non-error case.
>
> Well, at minimum the error code usage is very confused. The
> dlm_begin_reco_handler gets registered via o2net_register_handler().
> Here's where dlm_begin_reco_handler gets registered, followed by
> dlm_finalize_reco_handler right afterwards:
<snip>
> A negative error code right there. The other event handlers are seem to
> be similar - dlm_begin_reco_handler() is the odd one out.
The usage of the handlers - 'status' is the return code of the
handler - is pretty straightforward. Once you're in the mindset of the
o2net code, of course. This is old stuff, from the earliest days of
ocfs2 development, so we haven't had to spelunk in here for a while ;-)
Sunil and I both thought while looking at this code that we
could probably return -EAGAIN just as easily, though. We'll probably
clean it that way at some point.
Joel
--
There are morethings in heaven and earth, Horatio,
Than are dreamt of in your philosophy.
Joel Becker
Principal Software Developer
Oracle
E-mail: joel.becker@oracle.com
Phone: (650) 506-8127
WARNING: multiple messages have this Message-ID (diff)
From: Joel Becker <Joel.Becker@oracle.com>
To: Ingo Molnar <mingo@elte.hu>
Cc: Randy Dunlap <randy.dunlap@oracle.com>,
"Stephen M. Cameron" <scameron@beardog.cca.cpqcorp.net>,
Mike Christie <michaelc@cs.wisc.edu>,
David Airlie <airlied@linux.ie>,
James Bottomley <James.Bottomley@HansenPartnership.com>,
Jens Axboe <jens.axboe@oracle.com>,
Evgeniy Polyakov <zbr@ioremap.net>,
iss_storagedev@hp.com, Eric Dumazet <eric.dumazet@gmail.com>,
Andy Whitcroft <apw@shadowen.org>,
Dave Airlie <airlied@redhat.com>,
Hannes Eder <hannes@hanneseder.net>,
dri-devel@lists.sourceforge.net,
Alexey Dobriyan <adobriyan@gmail.com>,
Mike Miller <mike.miller@hp.com>, Mark Fasheh <mfasheh@suse.com>,
Karsten Keil <isdn@linux-pingi.de>,
rostedt@goodmis.org, Karen Xie <kxie@chelsio.com>,
"James E.J. Bottomley" <James.Bottomley@suse.de>,
Hannes Reinecke <hare@suse.de>,
Andreas
Subject: [Ocfs2-devel] [patch] Fix: 'return -ENOMEM' instead of 'return ENOMEM'
Date: Fri, 13 Nov 2009 03:56:10 -0800 [thread overview]
Message-ID: <20091113115610.GB28530@mail.oracle.com> (raw)
In-Reply-To: <20091113075306.GB2775@elte.hu>
On Fri, Nov 13, 2009 at 08:53:06AM +0100, Ingo Molnar wrote:
> > Sorry, I read the code wrong. This function is just a handler. The
> > caller, dlm_send_begin_reco_message(), expects the positive EAGAIN as
> > a non-error case.
>
> Well, at minimum the error code usage is very confused. The
> dlm_begin_reco_handler gets registered via o2net_register_handler().
> Here's where dlm_begin_reco_handler gets registered, followed by
> dlm_finalize_reco_handler right afterwards:
<snip>
> A negative error code right there. The other event handlers are seem to
> be similar - dlm_begin_reco_handler() is the odd one out.
The usage of the handlers - 'status' is the return code of the
handler - is pretty straightforward. Once you're in the mindset of the
o2net code, of course. This is old stuff, from the earliest days of
ocfs2 development, so we haven't had to spelunk in here for a while ;-)
Sunil and I both thought while looking at this code that we
could probably return -EAGAIN just as easily, though. We'll probably
clean it that way at some point.
Joel
--
There are morethings in heaven and earth, Horatio,
Than are dreamt of in your philosophy.
Joel Becker
Principal Software Developer
Oracle
E-mail: joel.becker at oracle.com
Phone: (650) 506-8127
WARNING: multiple messages have this Message-ID (diff)
From: Joel Becker <Joel.Becker@oracle.com>
To: Ingo Molnar <mingo@elte.hu>
Cc: Randy Dunlap <randy.dunlap@oracle.com>,
"Stephen M. Cameron" <scameron@beardog.cca.cpqcorp.net>,
Mike Christie <michaelc@cs.wisc.edu>,
David Airlie <airlied@linux.ie>,
James Bottomley <James.Bottomley@HansenPartnership.com>,
Jens Axboe <jens.axboe@oracle.com>,
Evgeniy Polyakov <zbr@ioremap.net>,
iss_storagedev@hp.com, Eric Dumazet <eric.dumazet@gmail.com>,
Andy Whitcroft <apw@shadowen.org>,
Dave Airlie <airlied@redhat.com>,
Hannes Eder <hannes@hanneseder.net>,
dri-devel@lists.sourceforge.net,
Alexey Dobriyan <adobriyan@gmail.com>,
Mike Miller <mike.miller@hp.com>, Mark Fasheh <mfasheh@suse.com>,
Karsten Keil <isdn@linux-pingi.de>,
rostedt@goodmis.org, Karen Xie <kxie@chelsio.com>,
"James E.J. Bottomley" <James.Bottomley@suse.de>,
Hannes Reinecke <hare@suse.de>,
Andreas Ever
Subject: Re: [patch] Fix: 'return -ENOMEM' instead of 'return ENOMEM'
Date: Fri, 13 Nov 2009 03:56:10 -0800 [thread overview]
Message-ID: <20091113115610.GB28530@mail.oracle.com> (raw)
In-Reply-To: <20091113075306.GB2775@elte.hu>
On Fri, Nov 13, 2009 at 08:53:06AM +0100, Ingo Molnar wrote:
> > Sorry, I read the code wrong. This function is just a handler. The
> > caller, dlm_send_begin_reco_message(), expects the positive EAGAIN as
> > a non-error case.
>
> Well, at minimum the error code usage is very confused. The
> dlm_begin_reco_handler gets registered via o2net_register_handler().
> Here's where dlm_begin_reco_handler gets registered, followed by
> dlm_finalize_reco_handler right afterwards:
<snip>
> A negative error code right there. The other event handlers are seem to
> be similar - dlm_begin_reco_handler() is the odd one out.
The usage of the handlers - 'status' is the return code of the
handler - is pretty straightforward. Once you're in the mindset of the
o2net code, of course. This is old stuff, from the earliest days of
ocfs2 development, so we haven't had to spelunk in here for a while ;-)
Sunil and I both thought while looking at this code that we
could probably return -EAGAIN just as easily, though. We'll probably
clean it that way at some point.
Joel
--
There are morethings in heaven and earth, Horatio,
Than are dreamt of in your philosophy.
Joel Becker
Principal Software Developer
Oracle
E-mail: joel.becker@oracle.com
Phone: (650) 506-8127
next prev parent reply other threads:[~2009-11-13 11:56 UTC|newest]
Thread overview: 34+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-11-11 21:26 [PATCH] ftrace: return error instead of 12 bytes read Roel Kluin
2009-11-11 21:47 ` Andrew Morton
2009-11-11 21:58 ` Steven Rostedt
2009-11-12 8:10 ` [patch] Fix: 'return -ENOMEM' instead of 'return ENOMEM' Ingo Molnar
2009-11-12 8:10 ` Ingo Molnar
2009-11-12 8:10 ` [Ocfs2-devel] " Ingo Molnar
2009-11-12 8:43 ` Dave Airlie
2009-11-12 8:43 ` Dave Airlie
2009-11-12 8:43 ` [Ocfs2-devel] " Dave Airlie
2009-11-12 9:31 ` roel kluin
2009-11-12 9:31 ` roel kluin
2009-11-12 9:31 ` [Ocfs2-devel] " roel kluin
2009-11-12 15:10 ` Mike Christie
2009-11-12 15:10 ` [Ocfs2-devel] " Mike Christie
2009-11-12 9:47 ` Alexey Dobriyan
2009-11-12 19:17 ` Joel Becker
2009-11-12 19:17 ` Joel Becker
2009-11-12 19:17 ` [Ocfs2-devel] " Joel Becker
2009-11-12 20:27 ` Joel Becker
2009-11-12 20:27 ` Joel Becker
2009-11-12 20:27 ` [Ocfs2-devel] " Joel Becker
2009-11-13 7:53 ` Ingo Molnar
2009-11-13 11:56 ` Joel Becker [this message]
2009-11-13 11:56 ` Joel Becker
2009-11-13 11:56 ` [Ocfs2-devel] " Joel Becker
2009-11-12 13:31 ` [PATCH] ftrace: return error instead of 12 bytes read Andy Whitcroft
2009-11-12 13:45 ` Ingo Molnar
2009-11-12 14:10 ` Andy Whitcroft
2009-11-18 10:18 ` Dan Merillat
2009-11-18 17:15 ` scameron
2009-11-11 21:57 ` Steven Rostedt
2009-11-12 2:33 ` [PATCH][GIT PULL][v2.6.32] tracing: Fix return value of tracing_stats_read() Steven Rostedt
2009-11-12 7:50 ` Ingo Molnar
2009-11-12 8:21 ` [tip:tracing/urgent] " tip-bot for Roel Kluin
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=20091113115610.GB28530@mail.oracle.com \
--to=joel.becker@oracle.com \
--cc=James.Bottomley@HansenPartnership.com \
--cc=James.Bottomley@suse.de \
--cc=adobriyan@gmail.com \
--cc=airlied@linux.ie \
--cc=airlied@redhat.com \
--cc=apw@shadowen.org \
--cc=dri-devel@lists.sourceforge.net \
--cc=eric.dumazet@gmail.com \
--cc=hannes@hanneseder.net \
--cc=hare@suse.de \
--cc=isdn@linux-pingi.de \
--cc=iss_storagedev@hp.com \
--cc=jens.axboe@oracle.com \
--cc=kxie@chelsio.com \
--cc=mfasheh@suse.com \
--cc=michaelc@cs.wisc.edu \
--cc=mike.miller@hp.com \
--cc=mingo@elte.hu \
--cc=randy.dunlap@oracle.com \
--cc=rostedt@goodmis.org \
--cc=scameron@beardog.cca.cpqcorp.net \
--cc=zbr@ioremap.net \
/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.