Received: by 2002:a05:6a10:6744:0:0:0:0 with SMTP id w4csp4891420pxu; Tue, 13 Oct 2020 09:28:12 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxh/P2KIjRTpPO1+NqLzK1Pu93Ap8rjtklob+Jj26ppprXDPX4WFWmiCncCDC7SE8mQpprN X-Received: by 2002:a17:906:d782:: with SMTP id pj2mr593317ejb.380.1602606492628; Tue, 13 Oct 2020 09:28:12 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1602606492; cv=none; d=google.com; s=arc-20160816; b=JqtIANaLBl5BZ14wNqhEa9tRT6W/YZ1JSp5EtvPCq5ZmeIMSoA+puXleFwt3sMThqg ERHtfJp3Q1uB4+FblWf/1WUfpeU5PWLazH6/23jKNrng1X3BH5IBdaFIXNYRqv3WmjJ1 zWhWXI8yNKjZInJ1E1zdc/f4hwINtGoVUBseqhOHqW+nyP6pK5BH3ZLFIXKgyU9DD6rK RlPvkmZ/24hJPyPjv17VuArGkczM/1RBt4prGenCtWfHkldLiBUHf1W9pElZDmF94UvV YdVAlL7JF42Bs+CZ0Ijmavn/vkGLnH+MB1aCCj3XW9u6mSUi2MFrGI4qSC181eFYlesJ b/+w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to :mime-version:user-agent:date:message-id:from:cc:references:to :subject; bh=GHqyP56sX84KVvN4lxHV6w1ojm8OMhSva5BPXtIOl4o=; b=Y+ASbM9r7SrqOE3BzGcKeT8IfMLGWvVdvy7VZxktNjqTW3PQfkbkbZ+PgQWMbQva2f v2dbuCKY8zskB+uasx0vsENrOmUFIyaE7zKxJ+broDNcGknkuv/uc33yXzSKtCKawuaL ImdVxo7xYY4s8pUfiAyEkdWesAnwXxvnp9sFLF7RwguWMIJxg2H5tdkc592NFCdNPrKK jFQJnSV5ezcLs0urxSXeK5kXuUFjn8o8KwEBKBlO3lBCyqzR3N4lqfs02mVy6knwLG6k 9YHYpwDC8zZlSHxlS3b+qz74/njFkSJNR84n5GksasO0YmGIoBmc0Z/2js1N2OnWpTII 3ipA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id dg11si128954edb.246.2020.10.13.09.27.49; Tue, 13 Oct 2020 09:28:12 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727617AbgJMMdg (ORCPT + 99 others); Tue, 13 Oct 2020 08:33:36 -0400 Received: from szxga07-in.huawei.com ([45.249.212.35]:50414 "EHLO huawei.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1727395AbgJMMdf (ORCPT ); Tue, 13 Oct 2020 08:33:35 -0400 Received: from DGGEMS406-HUB.china.huawei.com (unknown [172.30.72.59]) by Forcepoint Email with ESMTP id 9D7A01669E8BDD336A8F; Tue, 13 Oct 2020 20:33:31 +0800 (CST) Received: from [10.174.178.67] (10.174.178.67) by smtp.huawei.com (10.3.19.206) with Microsoft SMTP Server (TLS) id 14.3.487.0; Tue, 13 Oct 2020 20:33:29 +0800 Subject: Re: [PATCH] thunderbolt: Add the missed ida_simple_remove() in ring_request_msix() To: Andy Shevchenko References: <20201013024518.195557-1-jingxiangfeng@huawei.com> <20201013114325.GK4077@smile.fi.intel.com> CC: , , , , , , From: Jing Xiangfeng Message-ID: <5F859E98.5080506@huawei.com> Date: Tue, 13 Oct 2020 20:33:28 +0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:38.0) Gecko/20100101 Thunderbird/38.1.0 MIME-Version: 1.0 In-Reply-To: <20201013114325.GK4077@smile.fi.intel.com> Content-Type: text/plain; charset="windows-1252"; format=flowed Content-Transfer-Encoding: 7bit X-Originating-IP: [10.174.178.67] X-CFilter-Loop: Reflected Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2020/10/13 19:43, Andy Shevchenko wrote: > On Tue, Oct 13, 2020 at 10:45:18AM +0800, Jing Xiangfeng wrote: >> ring_request_msix() misses to call ida_simple_remove() in an error path. >> Add the missed function call to fix it. > ... > >> ring->irq = pci_irq_vector(ring->nhi->pdev, ring->vector); >> - if (ring->irq < 0) >> + if (ring->irq < 0) { >> + ida_simple_remove(&nhi->msix_ida, ret); >> return ring->irq; >> + } >> >> irqflags = no_suspend ? IRQF_NO_SUSPEND : 0; >> return request_irq(ring->irq, ring_msix, irqflags, "thunderbolt", ring); > According to your logic don't you need it here as well? Hm indeed. Will fix too. Thanks for your review. >