Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp8088605imu; Fri, 28 Dec 2018 10:15:42 -0800 (PST) X-Google-Smtp-Source: ALg8bN7KACvvXWSKJVv6on8MH1wLm5vtJ/BdwLyYMr5+MarnQ362Xs52Zv+N1b18Fqnlo6CXdZt5 X-Received: by 2002:a62:18ce:: with SMTP id 197mr29962428pfy.88.1546020942752; Fri, 28 Dec 2018 10:15:42 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1546020942; cv=none; d=google.com; s=arc-20160816; b=NQuLn4Xi4KrqlCjUQI7fBk4HVEeKFZV3I6jBpsMxtbCQlAVk3iXZgABB+AcF0capkq zuOYzC1PkH9QQ5XcZNwzQ9w/UTpOA7QwbVWE/oTvwkFnjk6P7jbhLKHddrVSLiV4KnJk JWDJ8udXIa54SJJbTQmgbvDtvbdaKhZfb1NwwilmCEh/XQMxOMUMPmTyGx3FpCLQXrBR 0uJV0SkpUJ5WUvK8W0ur9hVEShgE/HbpOX0Mg/mH/qory/TKrRtU3vIVAwwUOPMakXAc EEW/EVnHLZsD/rsewR6lOnKa72ah32ALIYbE0P82ADFOkhsqUfTBbNOqR4IJM8qd4Rz/ beig== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:message-id:date:subject:cc :to:from; bh=Vg0DBh7Ht0Nso2wQvpCGf4BSwoHZi2JQcRJrKHtoxn4=; b=oJtUQwWDuR8de1fkHzYCOzYFwfYBxTI17idfXbZGFWslNVODHbCFIRlETjZMZL4un/ mfKY45Xqn4jrUJN3dx/oEWUbfc8gzg7XokZlVBCyhjOiXCBD/16D0fAY4cxJZ3IfmMOC YovQH5AmzFG+cSs8s0xCm3mAIhp1p8S+T5BlCCXe5FpFwHKmc34sGB0Eo2k3tQiOG082 oR65PVG2xe6QgyO6yvNK8Vqd6sCO/gTspHfmyAtygFS1ppJd6Nie4ML91uXZ4R+stsyg J60ofbArgviah2DLF6a+QJgEtdL90PvG0UTL4GH0WWnN7ykN4TQ4UtkxMAKDSsJyHnd4 87rA== 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 f189si38858955pfg.123.2018.12.28.10.15.26; Fri, 28 Dec 2018 10:15:42 -0800 (PST) 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 S1730324AbeL1IPA (ORCPT + 99 others); Fri, 28 Dec 2018 03:15:00 -0500 Received: from szxga06-in.huawei.com ([45.249.212.32]:55773 "EHLO huawei.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1728006AbeL1IPA (ORCPT ); Fri, 28 Dec 2018 03:15:00 -0500 Received: from DGGEMS411-HUB.china.huawei.com (unknown [172.30.72.58]) by Forcepoint Email with ESMTP id CD35548501178; Fri, 28 Dec 2018 16:14:55 +0800 (CST) Received: from localhost.localdomain (10.175.34.53) by DGGEMS411-HUB.china.huawei.com (10.3.19.211) with Microsoft SMTP Server id 14.3.408.0; Fri, 28 Dec 2018 16:14:47 +0800 From: Xue Chaojing To: CC: , , , , , , , Subject: [PATCH 1/1] net-next/hinic:add shutdown callback Date: Fri, 28 Dec 2018 00:20:40 +0000 Message-ID: <20181228002040.1256-1-xuechaojing@huawei.com> X-Mailer: git-send-email 2.17.1 MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [10.175.34.53] X-CFilter-Loop: Reflected Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org This patch add shutdown callback for hinic. Signed-off-by: Xue Chaojing --- drivers/net/ethernet/huawei/hinic/hinic_main.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/drivers/net/ethernet/huawei/hinic/hinic_main.c b/drivers/net/ethernet/huawei/hinic/hinic_main.c index 6d48dc62a44b..76ca8a518dca 100644 --- a/drivers/net/ethernet/huawei/hinic/hinic_main.c +++ b/drivers/net/ethernet/huawei/hinic/hinic_main.c @@ -1106,6 +1106,13 @@ static void hinic_remove(struct pci_dev *pdev) dev_info(&pdev->dev, "HiNIC driver - removed\n"); } +static void hinic_shutdown(struct pci_dev *pdev) +{ + pci_disable_device(pdev); + + dev_info(&pdev->dev, "HiNIC driver - shutdown\n"); +} + static const struct pci_device_id hinic_pci_table[] = { { PCI_VDEVICE(HUAWEI, HINIC_DEV_ID_QUAD_PORT_25GE), 0}, { PCI_VDEVICE(HUAWEI, HINIC_DEV_ID_DUAL_PORT_25GE), 0}, @@ -1119,6 +1126,7 @@ static struct pci_driver hinic_driver = { .id_table = hinic_pci_table, .probe = hinic_probe, .remove = hinic_remove, + .shutdown = hinic_shutdown, }; module_pci_driver(hinic_driver); -- 2.17.1