Received: by 2002:a25:6193:0:0:0:0:0 with SMTP id v141csp3485363ybb; Mon, 23 Mar 2020 01:53:35 -0700 (PDT) X-Google-Smtp-Source: ADFU+vsDGe6dqb6cf6v5T3G1ibk/SZIcwPlFUSHbD4VGTynq9fxkD7SDNkjnz+8pSXNYQ1cD3VFq X-Received: by 2002:a05:6820:319:: with SMTP id l25mr45912ooe.88.1584953615476; Mon, 23 Mar 2020 01:53:35 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1584953615; cv=none; d=google.com; s=arc-20160816; b=aQGlsFeZugfrGCrwsETDOYHI0bVkdtjBQd71hp3vZ2DBSsKGU3hHQWfgzueG/0ysgX L/wmvid7DS3e/e6pRLscfYA/HXUUYj3GO1nHnQkR59YQLTNodf+DP20RbYW7MhO42WvK +rZshR1xUMffGhJGyQgFT2onIiS//HIw0cp2efG8QYsPqMHRPzb8Npndn1HHPaxPYHED 6iDvJ1G6/47HoX9NFvK2L4kc7nT1lPYN9q0C7b8eumA54L5S6/S1gpL7qYoJQB5pHZUT hkacSpkUVrs3Fslyx5pbEW9wRqUU9eEPj2zAWCpu0h3zMvE8q/cUDRHVqSfCY6YKp7S9 m24A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=L55RKhiobKDIEmH2Y4bEZR40/dZxSN5Jdj9dpFi288E=; b=BISULM9PjWHG4r1znqg/tDj9B8z/PXjsfjaOz2vqolQwtu5OGKsHU6dg52bq/Gbo87 t2g5pitownX02x8705nxzwKmckvFzPnCxjX+unpi3WEvUFDBrIMwzr7AFDD18ZwtZvUF Y9FcFM9nueoWYZ08FwS5F+rzLf/Jj+qwT6ks//y+KmTRkN2GKv3SFXxNik3gwPLeAaSS Eu2fumPnnpZFHkhkZBNbo4pwV75A7d0wjML1X8VuBu2LrttpmrGt9P7O7KwHx506p4aB bcSneZlSomJu7oCdBaQRTUSNxfR2abHzXP8Gb+xVgdFfgwpN2MczAQquFrLethgPuved 0flA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=Gq+D2qpl; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id r187si594529oig.168.2020.03.23.01.53.22; Mon, 23 Mar 2020 01:53:35 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=Gq+D2qpl; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727649AbgCWIwp (ORCPT + 99 others); Mon, 23 Mar 2020 04:52:45 -0400 Received: from mail.kernel.org ([198.145.29.99]:59404 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727477AbgCWIwp (ORCPT ); Mon, 23 Mar 2020 04:52:45 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id AA4F620663; Mon, 23 Mar 2020 08:52:44 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1584953565; bh=wG7SF/RkUIf8rHHlON28AbIfMYRx4lCr5muY2st+zok=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=Gq+D2qplejpaEEiqKBfPUZfVoc8f0nWfIMvoK4uhIVehr0T/u9irhCLTM2abpYyqa uYZrJ5wH8dMpTNMiXi3rPw6df1vFI09lZs8uYQzwYDpy+5sd9tHI5NPmrj+fwn69KL 7tEpDPkAnv77Ttj1cv/3do6EiivOo2aeo0AC0lzk= Date: Mon, 23 Mar 2020 09:52:41 +0100 From: Greg Kroah-Hartman To: Xiyu Yang Cc: Arnd Bergmann , Alexios Zavras , Allison Randal , Adit Ranadive , Jorgen Hansen , Thomas Gleixner , Vishnu DASA , linux-kernel@vger.kernel.org, yuanxzhang@fudan.edu.cn, kjlu@umn.edu, Xin Tan Subject: Re: [PATCH v2] VMCI: Fix NULL pointer dereference on context ptr Message-ID: <20200323085241.GA342330@kroah.com> References: <1584951832-120773-1-git-send-email-xiyuyang19@fudan.edu.cn> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1584951832-120773-1-git-send-email-xiyuyang19@fudan.edu.cn> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Mar 23, 2020 at 04:22:33PM +0800, Xiyu Yang wrote: > A NULL vmci_ctx object may pass to vmci_ctx_put() from its callers. Are you sure this can happen? > Add a NULL check to prevent NULL pointer dereference. > > Signed-off-by: Xiyu Yang > Signed-off-by: Xin Tan > --- > drivers/misc/vmw_vmci/vmci_context.c | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) What changed from v1? Always put that below the --- line. Please fix up and send a v3. thanks, greg k-h