From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail.linuxfoundation.org ([140.211.169.12]:34305 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752047AbcIINjh (ORCPT ); Fri, 9 Sep 2016 09:39:37 -0400 Subject: Patch "[PATCH 037/135] Drivers: hv: util: catch allocation errors" has been added to the 4.4-stable tree To: olaf@aepfle.de, alexander.levin@verizon.com, gregkh@linuxfoundation.org, kys@microsoft.com Cc: , From: Date: Fri, 09 Sep 2016 15:38:01 +0200 Message-ID: <147342828149221@kroah.com> MIME-Version: 1.0 Content-Type: text/plain; charset=ANSI_X3.4-1968 Content-Transfer-Encoding: 8bit Sender: stable-owner@vger.kernel.org List-ID: This is a note to let you know that I've just added the patch titled [PATCH 037/135] Drivers: hv: util: catch allocation errors to the 4.4-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of the patch is: 0037-Drivers-hv-util-catch-allocation-errors.patch and it can be found in the queue-4.4 subdirectory. If you, or anyone else, feels it should not be added to the stable tree, please let know about it. >>From 9435330bd885600bb666af6bb111834a8e475ba5 Mon Sep 17 00:00:00 2001 From: Olaf Hering Date: Mon, 14 Dec 2015 16:01:36 -0800 Subject: [PATCH 037/135] Drivers: hv: util: catch allocation errors [ Upstream commit cdc0c0c94e4e6dfa371d497a3130f83349b6ead6 ] Catch allocation errors in hvutil_transport_send. Fixes: 14b50f80c32d ('Drivers: hv: util: introduce hv_utils_transport abstraction') Signed-off-by: Olaf Hering Signed-off-by: K. Y. Srinivasan Signed-off-by: Greg Kroah-Hartman Signed-off-by: Sasha Levin Signed-off-by: Greg Kroah-Hartman --- drivers/hv/hv_utils_transport.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) --- a/drivers/hv/hv_utils_transport.c +++ b/drivers/hv/hv_utils_transport.c @@ -204,9 +204,12 @@ int hvutil_transport_send(struct hvutil_ goto out_unlock; } hvt->outmsg = kzalloc(len, GFP_KERNEL); - memcpy(hvt->outmsg, msg, len); - hvt->outmsg_len = len; - wake_up_interruptible(&hvt->outmsg_q); + if (hvt->outmsg) { + memcpy(hvt->outmsg, msg, len); + hvt->outmsg_len = len; + wake_up_interruptible(&hvt->outmsg_q); + } else + ret = -ENOMEM; out_unlock: mutex_unlock(&hvt->outmsg_lock); return ret; Patches currently in stable-queue which might be from olaf@aepfle.de are queue-4.4/0036-tools-hv-report-ENOSPC-errors-in-hv_fcopy_daemon.patch queue-4.4/0035-Drivers-hv-utils-run-polling-callback-always-in-inte.patch queue-4.4/0037-Drivers-hv-util-catch-allocation-errors.patch queue-4.4/0039-Drivers-hv-vss-run-only-on-supported-host-versions.patch