Received: by 2002:a05:6a10:2785:0:0:0:0 with SMTP id ia5csp2280673pxb; Mon, 11 Jan 2021 05:58:53 -0800 (PST) X-Google-Smtp-Source: ABdhPJx+uUmT8t7LpBQGO1WmrjhSsD1OFg6Wv0yPldjB297kE6SLqsjKGeXMo7MiLrC+VD5dRvTk X-Received: by 2002:a17:907:111c:: with SMTP id qu28mr10667019ejb.540.1610373533381; Mon, 11 Jan 2021 05:58:53 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1610373533; cv=none; d=google.com; s=arc-20160816; b=mUAiKHNWcNoVxetSyse8jJjy0F6lLxrBrRpQ+5Gvyi06q1Mase7mqaFs1KqT0CeYYr 3yDVz1Jo2iYw0uPUh1HyGySfTyeM2NGebciRxGfhEcAUUGP1BgpOJ8DANhwhwYXK9OdI 8e4fwHWTwpk9AYGTLB/IltCfjwb+clKEbZMEslG1BZ1H4FJLJi0X9WNqxM0h7WesXESl elsW57ZmrdwEearF9IsWftPtC0C5Nu5tzlW0hLibZtw4i4bT/SRyV0nmdCvPd0Gj6yDD b6vjWML/WtsBCcP18tl+5MdwoXEQOKvRr6bJhgsoLGLlMWb9JQT/4koSfAmcxCgcuhpE 8T7A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=EKiXSl+nvDZk2Slr+vVaZbsztC9LFWx+WhLLlcQlsDw=; b=tup28bI2f4S1V4fE/DgwHc4dntBxgolx024k1VWJHLClQlg69Z2YUYLRNkMwLEY1Yd PmMkorkiDypMFbdgz7kQu6x0yplcW0RWS73Fw9U9zjcwQ8sam5t0UDJGuZ/vpcCX4nAo C7K0Z6ychIuqpVzizvTWIyv/fi5BBOWn9Ar8XZQByH0V6er7uaGmMd3J0gSdLf/mNEFt 1ZpuxlTpmdPheurJ1bnt9ggMHSl+gsB5CzX5R0w4q20HtPMOzPX3nifi9ctnYwXbF2Sp Mjvih/KqIs7ZSt/lqcH2TO/FtX4I/1c5r+vwrzMOq3tPBhn75/idLoYNWaxo8GHeJ47Y YVUw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=n5aELTZy; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id h17si6524805ejc.592.2021.01.11.05.58.29; Mon, 11 Jan 2021 05:58:53 -0800 (PST) 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; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=n5aELTZy; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2387989AbhAKN4B (ORCPT + 99 others); Mon, 11 Jan 2021 08:56:01 -0500 Received: from mail.kernel.org ([198.145.29.99]:54440 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728969AbhAKNHT (ORCPT ); Mon, 11 Jan 2021 08:07:19 -0500 Received: by mail.kernel.org (Postfix) with ESMTPSA id A9A92229C4; Mon, 11 Jan 2021 13:07:03 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1610370424; bh=0pvycBJoN4waGColndHYcZmO8vQD+V3btAXV0Gvctl0=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=n5aELTZyRfxBzJzywa28vliNbxjh6EnlwA/NDa7o1QSokjvxhyjo2yVz/RrdKpuab a8Xq8ryJoqy9J3C5qonRAr0D3PSzDM+lGZkaTy8ZIzjeyG1kTG4bQe2xzGalZKvQyi ekPXu3Q2H5Mo82IZMlHm5XAIXMzJ6XXBqtVyUp3c= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Dan Carpenter , Jakub Kicinski Subject: [PATCH 4.19 16/77] atm: idt77252: call pci_disable_device() on error path Date: Mon, 11 Jan 2021 14:01:25 +0100 Message-Id: <20210111130037.196535447@linuxfoundation.org> X-Mailer: git-send-email 2.30.0 In-Reply-To: <20210111130036.414620026@linuxfoundation.org> References: <20210111130036.414620026@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Dan Carpenter [ Upstream commit 8df66af5c1e5f80562fe728db5ec069b21810144 ] This error path needs to disable the pci device before returning. Fixes: ede58ef28e10 ("atm: remove deprecated use of pci api") Signed-off-by: Dan Carpenter Link: https://lore.kernel.org/r/X93dmC4NX0vbTpGp@mwanda Signed-off-by: Jakub Kicinski Signed-off-by: Greg Kroah-Hartman --- drivers/atm/idt77252.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/drivers/atm/idt77252.c +++ b/drivers/atm/idt77252.c @@ -3607,7 +3607,7 @@ static int idt77252_init_one(struct pci_ if ((err = dma_set_mask_and_coherent(&pcidev->dev, DMA_BIT_MASK(32)))) { printk("idt77252: can't enable DMA for PCI device at %s\n", pci_name(pcidev)); - return err; + goto err_out_disable_pdev; } card = kzalloc(sizeof(struct idt77252_dev), GFP_KERNEL);