From: Greg KH <gregkh@suse.de>
To: Haiyang Zhang <haiyangz@microsoft.com>,
Bill Pemberton <wfp5p@virginia.edu>
Cc: "'linux-kernel@vger.kernel.org'" <linux-kernel@vger.kernel.org>,
"'devel@driverdev.osuosl.org'" <devel@driverdev.osuosl.org>,
"'virtualization@lists.osdl.org'" <virtualization@lists.osdl.org>,
Hank Janssen <hjanssen@microsoft.com>
Subject: Re: [PATCH 1/1] staging: hv: Fix error checking in channel.c
Date: Thu, 13 May 2010 09:33:16 -0700 [thread overview]
Message-ID: <20100513163316.GA24649@suse.de> (raw)
In-Reply-To: <1FB5E1D5CA062146B38059374562DF72662AB0C9@TK5EX14MBXC130.redmond.corp.microsoft.com>
On Thu, May 13, 2010 at 03:56:30PM +0000, Haiyang Zhang wrote:
> From: Haiyang Zhang <haiyangz@microsoft.com>
>
> Subject: staging: hv: Fix error checking in channel.c
> Fixed errors in return value checking code, which caused vmbus channel
> not functioning.
Doh, sorry about that. Bill, be a bit more careful in the future
please, this came in on your ASSERT cleanup patch.
thanks,
greg k-h
> ---
> drivers/staging/hv/channel.c | 8 ++++----
> 1 files changed, 4 insertions(+), 4 deletions(-)
>
> diff --git a/drivers/staging/hv/channel.c b/drivers/staging/hv/channel.c
> index 12c351e..f047c5a 100644
> --- a/drivers/staging/hv/channel.c
> +++ b/drivers/staging/hv/channel.c
> @@ -204,13 +204,13 @@ int VmbusChannelOpen(struct vmbus_channel *NewChannel, u32 SendRingBufferSize,
> RecvRingBufferSize) >> PAGE_SHIFT;
>
> ret = RingBufferInit(&NewChannel->Outbound, out, SendRingBufferSize);
> - if (!ret) {
> + if (ret != 0) {
> err = ret;
> goto errorout;
> }
>
> ret = RingBufferInit(&NewChannel->Inbound, in, RecvRingBufferSize);
> - if (!ret) {
> + if (ret != 0) {
> err = ret;
> goto errorout;
> }
> @@ -228,7 +228,7 @@ int VmbusChannelOpen(struct vmbus_channel *NewChannel, u32 SendRingBufferSize,
> RecvRingBufferSize,
> &NewChannel->RingBufferGpadlHandle);
>
> - if (!ret) {
> + if (ret != 0) {
> err = ret;
> goto errorout;
> }
> @@ -569,7 +569,7 @@ int VmbusChannelEstablishGpadl(struct vmbus_channel *Channel, void *Kbuffer,
> ret = VmbusPostMessage(gpadlBody,
> subMsgInfo->MessageSize -
> sizeof(*subMsgInfo));
> - if (!ret)
> + if (ret != 0)
> goto Cleanup;
>
> }
> --
> 1.6.3.2
>
next prev parent reply other threads:[~2010-05-13 16:33 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-05-13 15:56 [PATCH 1/1] staging: hv: Fix error checking in channel.c Haiyang Zhang
2010-05-13 16:33 ` Greg KH [this message]
-- strict thread matches above, loose matches on Subject: below --
2010-05-13 15:56 Haiyang Zhang
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=20100513163316.GA24649@suse.de \
--to=gregkh@suse.de \
--cc=devel@driverdev.osuosl.org \
--cc=haiyangz@microsoft.com \
--cc=hjanssen@microsoft.com \
--cc=linux-kernel@vger.kernel.org \
--cc=virtualization@lists.osdl.org \
--cc=wfp5p@virginia.edu \
/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.