Received: by 2002:ab2:1149:0:b0:1f3:1f8c:d0c6 with SMTP id z9csp1527636lqz; Mon, 1 Apr 2024 08:53:07 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCVba5x88RZh7b64Xgg5E/XhJlPMwCatXCcBZn4zFZhpvXU0TCzD5Kq6OrWZ4s5OVItMbqxTEsBPInYzHaIwZnFdmbMX29/bj+ptyfARWg== X-Google-Smtp-Source: AGHT+IElOEBQ8L8hpJMuWbEUmEDW89WQzeUK+Gc2YB7BQQFq4ac+4hWFYyP4KesYqWQtDEUuA1Vp X-Received: by 2002:a17:903:1211:b0:1e0:b28c:ab with SMTP id l17-20020a170903121100b001e0b28c00abmr12292680plh.13.1711986787006; Mon, 01 Apr 2024 08:53:07 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1711986786; cv=pass; d=google.com; s=arc-20160816; b=q5FvW3aH1NSNsk6FJO1+94zPxJlf6Mh0aSY1wZQizut0b0xTSb6ny9qkvSevye2Enz PPwyK1H5r5bcTOssJMURNX4NHRWQw9QUioa7AKddOveK2hsOA6FbHmccc4r3lPH4vUe0 x18rsJpdnjMllB2yGnQD8jIqXMYB4Pn61I8ALe28Ocq29Gz0K6wpRy+a++bFFjwIS3WB KFYXJrN9OmQ/+fTM9O+/Vp94+ZArbz08WXivMZN0igvzczN1SI363E+yE3LkNz85cBPh zQA/BzgqZuiakpYW86ujPyLnZXeXh/WTYSNIKryyJ3dEWwDY1A3RF86YGNw5ZgiLytIu 7RiQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:list-unsubscribe:list-subscribe:list-id:precedence :subject:date:from:dkim-signature; bh=uDwUmdP1vEU79INAYOHEG2Uv5Heyb/Jl8ipwA/CjTc4=; fh=KKyrgjYrXyW4JfqLk6ATcOM9oVDVlPn3sqNZJG/dnFU=; b=o1B3+A4wTqP9PjTFal0H+D/CvpAnfVW3WrzEXdogFBuJ8bhAT12clGDqBYoHpqkQx7 ssAqNPvRrlOJBe5stF6TPQsCg5ofRaCih2eqXb2l+tu8n7G1wW+/x/qE7nZkDloJuoiP 8fYrz1A6dTqA4gZ5V68A4pRjYtatuIgz5tWPhJ/kD4U1UQYi3qL/vXoZBMTOc4kxTUlm jxiCQxfBFve+XnN/AlmOCuLBmqKD4dNk4/WJU9ceebkKpkYOqzV1HnDHLUPwmzgU3FGS g3U1sNp5mq/nYPuzZoQonmg5/9W5xUN2yXpSyuQGuLJZSGW9431shtR/RgMIopjU+auB y6eQ==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=u4lbsKRr; arc=pass (i=1 spf=pass spfdomain=linaro.org dkim=pass dkdomain=linaro.org dmarc=pass fromdomain=linaro.org); spf=pass (google.com: domain of linux-kernel+bounces-126830-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-126830-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id p23-20020a1709027ed700b001e035bf0f00si9019909plb.513.2024.04.01.08.53.06 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 01 Apr 2024 08:53:06 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-126830-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=u4lbsKRr; arc=pass (i=1 spf=pass spfdomain=linaro.org dkim=pass dkdomain=linaro.org dmarc=pass fromdomain=linaro.org); spf=pass (google.com: domain of linux-kernel+bounces-126830-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-126830-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id A6377283122 for ; Mon, 1 Apr 2024 15:53:06 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 349C5481D7; Mon, 1 Apr 2024 15:51:19 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="u4lbsKRr" Received: from mail-pl1-f175.google.com (mail-pl1-f175.google.com [209.85.214.175]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 4408E53370 for ; Mon, 1 Apr 2024 15:51:15 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.214.175 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1711986677; cv=none; b=Y1Z4N0YDYlS/wX03F9OUZjEwTHCk6SYUhV5LzLZTMs3CbT/AKW+iIAkuM0RJy8nv2SEiSVQ8UwlX1wJXfdNvQcj5JYXTZZqjvJkuxlwBaX9RCjE9PgcKnDd33UIKcwohPXl2kZXfmF6b9U0tVkqgY8li/sUXUZ7Y+cCI7UlAKHY= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1711986677; c=relaxed/simple; bh=Vc/z3bg7iR0DVyjnmsrW91gdlaGDMMW4LWUaKvK6QqA=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=VF1zgZaCVpCVbbRAbPKRzfAEEwRuwTto1hQx6sNwgBYIXRmX23FHCZ61iwAJiOFLzjieG0x+2RTkmohRNBJykPzWa17psdPLYYQhAzAQzQ2jVmauxWrZ6UZvKUK2oWeWZMDl+6uJ95KAy/sgxPEnZT/2Db/jZmzLFDXkIRq14eg= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org; spf=pass smtp.mailfrom=linaro.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b=u4lbsKRr; arc=none smtp.client-ip=209.85.214.175 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linaro.org Received: by mail-pl1-f175.google.com with SMTP id d9443c01a7336-1e0f3052145so39030115ad.2 for ; Mon, 01 Apr 2024 08:51:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1711986675; x=1712591475; darn=vger.kernel.org; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=uDwUmdP1vEU79INAYOHEG2Uv5Heyb/Jl8ipwA/CjTc4=; b=u4lbsKRrlA54HXtvbpomTkl0f6e6nWwCS9j2C9jotwbVppSbukXJmmPIfMy7NFes2P MdFnHVCHPAMdoHkYOrXp4+L+7EfXDNBOV1NSbEsb7UxqVGQzTu9enoIZ0+r5/vWySrxo iVBSoRv8LUHxDgsOJJl1sHMcni2L22eLEeC5tz1CJk7m0FshK5PCw8Dqt1gUh0fhNu3G Yz0SelvQ0K8NsqGJC6Q9AsD9wdM1jYkcVA+qGJ622dJ3Ri90CFTTsJWlTvATkZBGAVUd Jl9Tx7jvTz7ljIAdreJ9fbEMFC4pL+r/GyDLyb0o4OJks+DsufkevUoG2AEKJGSsiRJC D+GA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1711986675; x=1712591475; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=uDwUmdP1vEU79INAYOHEG2Uv5Heyb/Jl8ipwA/CjTc4=; b=nhypZ6CG+3eAR5HuIlhMBORAbauFynqHUUZ76uJa3KgLeAUiIbI2dqE/Qljor+Ytss URnrR1H1jJY8u6GIMjAX9tJuD98vGeL1CYlx5VFx1b2B56HsaKKUKyuFJlGUrmH+XuDr zbJuWqgEn9+qFgf+mRWWKga1dkbw6EW5D/1nzNxDwTcsCJMTh05GiQmEMmUTO8XiS9L8 OMgpk/PAmMpDm+Ew8fmhnFh1BpcnyUZtaViKL3T2fCu6HAhtpv3I9G54L1fske/TFFzf of2TBhgWcv0Wl8WrLunqFNAtGJnJwO/UubjnNoRwow6Dg4QYtapXa21MQGr9BH5RmjVj aG2g== X-Forwarded-Encrypted: i=1; AJvYcCUewlAV9xe9vwK7kmNFCJRCAFFaVQ10zkTFYvF9Li/PqQJeRz8LuWN33qkMfC7tN8TadZlbWMmO4lxjiRdc7PkU7u7oPAcmsWt/b8zz X-Gm-Message-State: AOJu0YzMMeja9sTzIQjHOMyyIaxFlzBZMoD+8UL0Fo9xYPyE7WZcTA8o RiZQUJAeAMaO/Sj43dBBo3joMsx/aj2MkRPqj9YQbygN8ahME2DBUoXmUEOh3A== X-Received: by 2002:a17:902:dac2:b0:1dd:ba2c:c1c7 with SMTP id q2-20020a170902dac200b001ddba2cc1c7mr9986116plx.60.1711986675327; Mon, 01 Apr 2024 08:51:15 -0700 (PDT) Received: from [127.0.1.1] ([103.28.246.102]) by smtp.gmail.com with ESMTPSA id kh6-20020a170903064600b001e21957fecdsm8949076plb.246.2024.04.01.08.51.11 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 01 Apr 2024 08:51:14 -0700 (PDT) From: Manivannan Sadhasivam Date: Mon, 01 Apr 2024 21:20:32 +0530 Subject: [PATCH v2 06/10] PCI: endpoint: Introduce EPC 'deinit' event and notify the EPF drivers Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <20240401-pci-epf-rework-v2-6-970dbe90b99d@linaro.org> References: <20240401-pci-epf-rework-v2-0-970dbe90b99d@linaro.org> In-Reply-To: <20240401-pci-epf-rework-v2-0-970dbe90b99d@linaro.org> To: Lorenzo Pieralisi , =?utf-8?q?Krzysztof_Wilczy=C5=84ski?= , Rob Herring , Bjorn Helgaas , Kishon Vijay Abraham I , Thierry Reding , Jonathan Hunter , Jingoo Han Cc: linux-pci@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org, mhi@lists.linux.dev, linux-tegra@vger.kernel.org, Niklas Cassel , Manivannan Sadhasivam X-Mailer: b4 0.12.4 X-Developer-Signature: v=1; a=openpgp-sha256; l=8443; i=manivannan.sadhasivam@linaro.org; h=from:subject:message-id; bh=Vc/z3bg7iR0DVyjnmsrW91gdlaGDMMW4LWUaKvK6QqA=; b=owEBbQGS/pANAwAKAVWfEeb+kc71AcsmYgBmCtfVC2gNAc4d1W5XxVGJHcgt6DgfU0nRKF4Bk qfVCMA0LJiJATMEAAEKAB0WIQRnpUMqgUjL2KRYJ5dVnxHm/pHO9QUCZgrX1QAKCRBVnxHm/pHO 9XNKB/4n42hVfJ6bcUVIaKI8YyqRrAp6g3FvHapE59XufDq96qaF11CwQrZwaXdPnPCUux9+PLi fp6wmp5Uw63mJSD85Hx5EsoQ1DyxwhygV2BIn4Q3ZFrqIO4xhhF7frh21LYKS9uHRj0pJSWACLD DCbK79DlZul9bLaxhtZYGZZBKGsPYZjkXPJMsbizyc9s8yIwbzsiD1f1mtCbh65DWz707syUIfy WfjOQN76wkSBCARWl4RuneKdg/8AUL2QnDGobGg8vJb3hOb4Z9HCGfg/2xidX25vJZEQRnpnfMe VXsCWAD2NwKmuCoWG9I53fDX5p3nn+idbjMLRhJ3Q4r/hj/W X-Developer-Key: i=manivannan.sadhasivam@linaro.org; a=openpgp; fpr=C668AEC3C3188E4C611465E7488550E901166008 As like the EPC 'init' event, that is used to signal the EPF drivers about the EPC initialization, let's introduce 'deinit' event that is used to signal EPC deinitialization. The EPC deinitialization applies only when any sort of fundamental reset is supported by the endpoint controller as per the PCIe spec. Reference: PCIe Base spec v5.0, sections 4.2.4.9.1 and 6.6.1. Currently, some EPC drivers like pcie-qcom-ep and pcie-tegra194 support PERST# as the fundamental reset. So the 'deinit' event will be notified to the EPF drivers when PERST# assert happens in the above mentioned EPC drivers. The EPF drivers, on receiving the event through the deinit() callback should reset the EPF state machine and also cleanup any configuration that got affected by the fundamental reset like BAR, DMA etc... This change also warrants skipping the cleanups in unbind() if already done in deinit(). Reviewed-by: Niklas Cassel Signed-off-by: Manivannan Sadhasivam --- drivers/pci/controller/dwc/pcie-designware-ep.c | 1 - drivers/pci/controller/dwc/pcie-qcom-ep.c | 1 + drivers/pci/controller/dwc/pcie-tegra194.c | 1 + drivers/pci/endpoint/functions/pci-epf-mhi.c | 19 +++++++++++++++++++ drivers/pci/endpoint/functions/pci-epf-test.c | 17 +++++++++++++++-- drivers/pci/endpoint/pci-epc-core.c | 25 +++++++++++++++++++++++++ include/linux/pci-epc.h | 1 + include/linux/pci-epf.h | 2 ++ 8 files changed, 64 insertions(+), 3 deletions(-) diff --git a/drivers/pci/controller/dwc/pcie-designware-ep.c b/drivers/pci/controller/dwc/pcie-designware-ep.c index 47391d7d3a73..2063cf2049e5 100644 --- a/drivers/pci/controller/dwc/pcie-designware-ep.c +++ b/drivers/pci/controller/dwc/pcie-designware-ep.c @@ -632,7 +632,6 @@ void dw_pcie_ep_cleanup(struct dw_pcie_ep *ep) struct dw_pcie *pci = to_dw_pcie_from_ep(ep); dw_pcie_edma_remove(pci); - ep->epc->init_complete = false; } EXPORT_SYMBOL_GPL(dw_pcie_ep_cleanup); diff --git a/drivers/pci/controller/dwc/pcie-qcom-ep.c b/drivers/pci/controller/dwc/pcie-qcom-ep.c index 50b1635e3cbb..e4b742355d57 100644 --- a/drivers/pci/controller/dwc/pcie-qcom-ep.c +++ b/drivers/pci/controller/dwc/pcie-qcom-ep.c @@ -501,6 +501,7 @@ static void qcom_pcie_perst_assert(struct dw_pcie *pci) { struct qcom_pcie_ep *pcie_ep = to_pcie_ep(pci); + pci_epc_deinit_notify(pci->ep.epc); dw_pcie_ep_cleanup(&pci->ep); qcom_pcie_disable_resources(pcie_ep); pcie_ep->link_status = QCOM_PCIE_EP_LINK_DISABLED; diff --git a/drivers/pci/controller/dwc/pcie-tegra194.c b/drivers/pci/controller/dwc/pcie-tegra194.c index ddc23602eca7..d2223821e122 100644 --- a/drivers/pci/controller/dwc/pcie-tegra194.c +++ b/drivers/pci/controller/dwc/pcie-tegra194.c @@ -1715,6 +1715,7 @@ static void pex_ep_event_pex_rst_assert(struct tegra_pcie_dw *pcie) if (ret) dev_err(pcie->dev, "Failed to go Detect state: %d\n", ret); + pci_epc_deinit_notify(pcie->pci.ep.epc); dw_pcie_ep_cleanup(&pcie->pci.ep); reset_control_assert(pcie->core_rst); diff --git a/drivers/pci/endpoint/functions/pci-epf-mhi.c b/drivers/pci/endpoint/functions/pci-epf-mhi.c index 4d5c638744a1..005916722ede 100644 --- a/drivers/pci/endpoint/functions/pci-epf-mhi.c +++ b/drivers/pci/endpoint/functions/pci-epf-mhi.c @@ -764,6 +764,24 @@ static int pci_epf_mhi_epc_init(struct pci_epf *epf) return 0; } +static void pci_epf_mhi_epc_deinit(struct pci_epf *epf) +{ + struct pci_epf_mhi *epf_mhi = epf_get_drvdata(epf); + const struct pci_epf_mhi_ep_info *info = epf_mhi->info; + struct pci_epf_bar *epf_bar = &epf->bar[info->bar_num]; + struct mhi_ep_cntrl *mhi_cntrl = &epf_mhi->mhi_cntrl; + struct pci_epc *epc = epf->epc; + + if (mhi_cntrl->mhi_dev) { + mhi_ep_power_down(mhi_cntrl); + if (info->flags & MHI_EPF_USE_DMA) + pci_epf_mhi_dma_deinit(epf_mhi); + mhi_ep_unregister_controller(mhi_cntrl); + } + + pci_epc_clear_bar(epc, epf->func_no, epf->vfunc_no, epf_bar); +} + static int pci_epf_mhi_link_up(struct pci_epf *epf) { struct pci_epf_mhi *epf_mhi = epf_get_drvdata(epf); @@ -898,6 +916,7 @@ static void pci_epf_mhi_unbind(struct pci_epf *epf) static const struct pci_epc_event_ops pci_epf_mhi_epc_event_ops = { .init = pci_epf_mhi_epc_init, + .deinit = pci_epf_mhi_epc_deinit, }; static const struct pci_epc_bus_event_ops pci_epf_mhi_bus_event_ops = { diff --git a/drivers/pci/endpoint/functions/pci-epf-test.c b/drivers/pci/endpoint/functions/pci-epf-test.c index 8756ffc5977b..5933788b0e68 100644 --- a/drivers/pci/endpoint/functions/pci-epf-test.c +++ b/drivers/pci/endpoint/functions/pci-epf-test.c @@ -790,6 +790,15 @@ static int pci_epf_test_epc_init(struct pci_epf *epf) return 0; } +static void pci_epf_test_epc_deinit(struct pci_epf *epf) +{ + struct pci_epf_test *epf_test = epf_get_drvdata(epf); + + cancel_delayed_work(&epf_test->cmd_handler); + pci_epf_test_clean_dma_chan(epf_test); + pci_epf_test_clear_bar(epf); +} + static int pci_epf_test_link_up(struct pci_epf *epf) { struct pci_epf_test *epf_test = epf_get_drvdata(epf); @@ -802,6 +811,7 @@ static int pci_epf_test_link_up(struct pci_epf *epf) static const struct pci_epc_event_ops pci_epf_test_epc_event_ops = { .init = pci_epf_test_epc_init, + .deinit = pci_epf_test_epc_deinit, }; static const struct pci_epc_bus_event_ops pci_epf_test_bus_event_ops = { @@ -910,10 +920,13 @@ static int pci_epf_test_bind(struct pci_epf *epf) static void pci_epf_test_unbind(struct pci_epf *epf) { struct pci_epf_test *epf_test = epf_get_drvdata(epf); + struct pci_epc *epc = epf->epc; cancel_delayed_work(&epf_test->cmd_handler); - pci_epf_test_clean_dma_chan(epf_test); - pci_epf_test_clear_bar(epf); + if (epc->init_complete) { + pci_epf_test_clean_dma_chan(epf_test); + pci_epf_test_clear_bar(epf); + } pci_epf_test_free_space(epf); } diff --git a/drivers/pci/endpoint/pci-epc-core.c b/drivers/pci/endpoint/pci-epc-core.c index fe3cb62dd866..05670c10371a 100644 --- a/drivers/pci/endpoint/pci-epc-core.c +++ b/drivers/pci/endpoint/pci-epc-core.c @@ -774,6 +774,31 @@ void pci_epc_notify_pending_init(struct pci_epc *epc, struct pci_epf *epf) } EXPORT_SYMBOL_GPL(pci_epc_notify_pending_init); +/** + * pci_epc_deinit_notify() - Notify the EPF device about EPC deinitialization + * @epc: the EPC device whose deinitialization is completed + * + * Invoke to notify the EPF device that the EPC deinitialization is completed. + */ +void pci_epc_deinit_notify(struct pci_epc *epc) +{ + struct pci_epf *epf; + + if (IS_ERR_OR_NULL(epc)) + return; + + mutex_lock(&epc->list_lock); + list_for_each_entry(epf, &epc->pci_epf, list) { + mutex_lock(&epf->lock); + if (epf->epc_event_ops && epf->epc_event_ops->deinit) + epf->epc_event_ops->deinit(epf); + mutex_unlock(&epf->lock); + } + epc->init_complete = false; + mutex_unlock(&epc->list_lock); +} +EXPORT_SYMBOL_GPL(pci_epc_deinit_notify); + /** * pci_epc_bme_notify() - Notify the EPF device that the EPC device has received * the BME event from the Root complex diff --git a/include/linux/pci-epc.h b/include/linux/pci-epc.h index acc5f96161fe..69dd7246c9db 100644 --- a/include/linux/pci-epc.h +++ b/include/linux/pci-epc.h @@ -226,6 +226,7 @@ void pci_epc_linkup(struct pci_epc *epc); void pci_epc_linkdown(struct pci_epc *epc); void pci_epc_init_notify(struct pci_epc *epc); void pci_epc_notify_pending_init(struct pci_epc *epc, struct pci_epf *epf); +void pci_epc_deinit_notify(struct pci_epc *epc); void pci_epc_bme_notify(struct pci_epc *epc); void pci_epc_remove_epf(struct pci_epc *epc, struct pci_epf *epf, enum pci_epc_interface_type type); diff --git a/include/linux/pci-epf.h b/include/linux/pci-epf.h index f4c2aaa6674c..74a0713661af 100644 --- a/include/linux/pci-epf.h +++ b/include/linux/pci-epf.h @@ -71,9 +71,11 @@ struct pci_epf_ops { /** * struct pci_epc_event_ops - Callbacks for capturing the EPC specific events * @init: Callback for the EPC initialization event + * @deinit: Callback for the EPC deinitialization event */ struct pci_epc_event_ops { int (*init)(struct pci_epf *epf); + void (*deinit)(struct pci_epf *epf); }; /** -- 2.25.1