Received: by 2002:ac0:a582:0:0:0:0:0 with SMTP id m2-v6csp3666570imm; Mon, 15 Oct 2018 01:57:59 -0700 (PDT) X-Google-Smtp-Source: ACcGV61HSTBto90+lyj5h3HNb7GETQmEpO8/filOgvYiCHgA6GVzL5JxeBaqWDIsXzl/bqL5zo0V X-Received: by 2002:a62:215b:: with SMTP id h88-v6mr16561966pfh.233.1539593879796; Mon, 15 Oct 2018 01:57:59 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1539593879; cv=none; d=google.com; s=arc-20160816; b=c+NozVCBWwVEDR7E7TUFGR+aPGFYoGKQ0wTMhxhe5VdbAni/UuB53GMv6rOhJcf0bA TWJKVrIr6tH2Hv0BSVPpGwMqFf6NSJKUuZASFYeuEiu8ftIVI766J3qqntUXI60LLyD/ Ih1LtxNSiVo4YZIlKcFE8T4T/Xs3g6jmOD0rZJlbgq2RPW42UHh+EGtiqa+6VpAQSAiu vY1tIXqPJg/6O4xo4A4D1bDeJdt2Njo3ax/HcOFtJz+qb9+OmX+88gK1Vuw2mQnZaz6j dVuePtdG0avohwoyQaZLQGUuei4L5w0SwOmG7KLmfNJ8wkXNoCTo9Hm2PsgF09suCGRx 2UDA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:date:cc:to:from:subject:message-id; bh=c85CgRPGH2YIpALbRXGFbRSDn8Lcmbraooj5/jHmcdY=; b=U2Fu6w/udSGkq7NVSqIm4WZrvbVr68lxbchZjJaSLp8NsqyFCKIVMWkj6qSWxRitVN Xer/I0VULQtuOpvfbSTW8gE5CjpW4zPUM55SM0FAcoR9s++IR7UP5WsdEbWbcHKw0NsQ R7O/4mnVECetVJ6aXzqFdhwrjB5L7uwAfV+Go17SsO1MKeRrnIGXTBKgPd1kwdzjKjaK Hi8nhAhMoT1iNv+Yf7ra9Fuh8GMzA7ooeYHGKp7OWkDJQBr3h3N/owO5bILDjSLk7pz3 eCaXGd6fw7Tdk0PIhFrWi8sCsOaA9kFIw7kft0ZBTCKyvZdHL6NQYDIL7eOjrUcDczcN 45/w== ARC-Authentication-Results: i=1; mx.google.com; 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 k5-v6si9922686pgr.511.2018.10.15.01.57.45; Mon, 15 Oct 2018 01:57:59 -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; 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 S1726781AbeJOQkb (ORCPT + 99 others); Mon, 15 Oct 2018 12:40:31 -0400 Received: from smtp.nue.novell.com ([195.135.221.5]:48450 "EHLO smtp.nue.novell.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726273AbeJOQkb (ORCPT ); Mon, 15 Oct 2018 12:40:31 -0400 Received: from emea4-mta.ukb.novell.com ([10.120.13.87]) by smtp.nue.novell.com with ESMTP (TLS encrypted); Mon, 15 Oct 2018 10:56:09 +0200 Received: from [192.168.1.2] (nwb-a10-snat.microfocus.com [10.120.13.201]) by emea4-mta.ukb.novell.com with ESMTP (TLS encrypted); Mon, 15 Oct 2018 09:56:03 +0100 Message-ID: <886d0f79d59d2d35ca75f9d2d79cdb45c1628c78.camel@suse.com> Subject: Re: [Xen-devel] [PATCH] xen/blkfront: avoid NULL blkfront_info dereference on device removal From: Vasilis Liaskovitis To: Roger Pau =?ISO-8859-1?Q?Monn=E9?= Cc: axboe@kernel.dk, jgross@suse.com, konrad.wilk@oracle.com, linux-kernel@vger.kernel.org, linux-block@vger.kernel.org, xen-devel@lists.xenproject.org, boris.ostrovsky@oracle.com Date: Mon, 15 Oct 2018 10:55:54 +0200 In-Reply-To: <20181011163427.ilpsl4hxb2y3hcfp@mac.bytemobile.com> References: <20181011162000.19191-1-vliaskovitis@suse.com> <20181011163427.ilpsl4hxb2y3hcfp@mac.bytemobile.com> Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.28.5 Mime-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, 2018-10-11 at 18:34 +0200, Roger Pau Monné wrote: > --- a/drivers/block/xen-blkfront.c > > +++ b/drivers/block/xen-blkfront.c > > @@ -2493,6 +2493,9 @@ static int blkfront_remove(struct > > xenbus_device *xbdev) > > > > dev_dbg(&xbdev->dev, "%s removed", xbdev->nodename); > > > > + if (!info) > > + goto out; > > I don't see the point in adding the 'out' label. Can you just return > 0 > here? of course, I will send a second version. thanks for the review, - Vasilis > > Thanks, Roger. > > _______________________________________________ > Xen-devel mailing list > Xen-devel@lists.xenproject.org > https://lists.xenproject.org/mailman/listinfo/xen-devel