lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:	Thu, 13 May 2010 09:33:16 -0700
From:	Greg KH <gregkh@...e.de>
To:	Haiyang Zhang <haiyangz@...rosoft.com>,
	Bill Pemberton <wfp5p@...ginia.edu>
Cc:	"'linux-kernel@...r.kernel.org'" <linux-kernel@...r.kernel.org>,
	"'devel@...verdev.osuosl.org'" <devel@...verdev.osuosl.org>,
	"'virtualization@...ts.osdl.org'" <virtualization@...ts.osdl.org>,
	Hank Janssen <hjanssen@...rosoft.com>
Subject: Re: [PATCH 1/1]  staging: hv: Fix error checking in channel.c

On Thu, May 13, 2010 at 03:56:30PM +0000, Haiyang Zhang wrote:
> From: Haiyang Zhang <haiyangz@...rosoft.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
> 


--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ