From patchwork Mon Jun 15 09:11:13 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pengpeng Hou X-Patchwork-Id: 2436 Return-Path: X-Original-To: noreply@patchwork.local Delivered-To: noreply@patchwork.local Received: from sto.lore.kernel.org (sto.lore.kernel.org [172.232.135.74]) by mxe881.netcup.net (Postfix) with ESMTPS id 9C9461C0266 for ; Mon, 15 Jun 2026 11:12:35 +0200 (CEST) Authentication-Results: mxe881; spf=pass (sender IP is 172.232.135.74) smtp.mailfrom=linux-sunxi+bounces-23834-noreply=patchwork.local@lists.linux.dev smtp.helo=sto.lore.kernel.org Received-SPF: pass (mxe881: domain of lists.linux.dev designates 172.232.135.74 as permitted sender) client-ip=172.232.135.74; envelope-from=linux-sunxi+bounces-23834-noreply=patchwork.local@lists.linux.dev; helo=sto.lore.kernel.org; Received: from smtp.subspace.kernel.org (conduit.subspace.kernel.org [100.90.174.1]) by sto.lore.kernel.org (Postfix) with ESMTP id 5DDE93009F6B for ; Mon, 15 Jun 2026 09:12:00 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id E17793D3333; Mon, 15 Jun 2026 09:11:27 +0000 (UTC) X-Original-To: linux-sunxi@lists.linux.dev Received: from cstnet.cn (smtp81.cstnet.cn [159.226.251.81]) (using TLSv1.2 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 683A13D3D1C for ; Mon, 15 Jun 2026 09:11:23 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=159.226.251.81 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1781514687; cv=none; b=pB5yztAbCvIAXFasmyTe5E4dWVT0xgmsSc22M+j6Vc6IW8vVw/NwPIjdnEmyiHqgjpwEEsRh5qhduBlTk6eAbzse/CdyzX1ImlZdtuqn0lWQn9fjflFBhPFVzfs4JK02Q3DUaeg7MgPxYpBes//BF0moMAeoljle6LJ841Q5YnY= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1781514687; c=relaxed/simple; bh=NOZlCSEv3F8FwatBQ8BSA4difxWE5jFw5B7XM5Jh0/I=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=kxtkMcF+lTp6b5hNmSOHNKJZtF1bnEByLA95dtEQe2S00TXc0i1Fw1QfrpjewIWxqGBJqteKl1rigDAt+5VT0uq1/gUOkPAPnZTcUlWBYd/4BgghxJVcvbEM3GHuuvw1JG06M10AIzYExKGx14fr84PB7hoyeHOO/XGHb2Ozovc= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=iscas.ac.cn; spf=pass smtp.mailfrom=iscas.ac.cn; arc=none smtp.client-ip=159.226.251.81 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=iscas.ac.cn Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=iscas.ac.cn Received: from localhost.localdomain (unknown [111.196.245.140]) by APP-03 (Coremail) with SMTP id rQCowACXt96zwS9qdl7LFA--.28827S2; Mon, 15 Jun 2026 17:11:16 +0800 (CST) From: Pengpeng Hou To: Corentin Labbe , Herbert Xu , "David S. Miller" , Chen-Yu Tsai , Jernej Skrabec , Samuel Holland , linux-crypto@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-sunxi@lists.linux.dev, linux-kernel@vger.kernel.org Cc: Pengpeng Hou Subject: [PATCH] crypto: sun4i-ss: remove debugfs directory on teardown Date: Mon, 15 Jun 2026 17:11:13 +0800 Message-ID: <20260615091114.97190-1-pengpeng@iscas.ac.cn> X-Mailer: git-send-email 2.50.1 Precedence: bulk X-Mailing-List: linux-sunxi@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-CM-TRANSID: rQCowACXt96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f9x0JUQZ2fUUUUU= X-CM-SenderInfo: pshqw1xhqjqxpvfd2hldfou0/ X-MORS-Enabled: yes X-MORS-DOMAIN: patchwork.local X-MORS-HOSTING: hosting172546 X-MORS-USER: hosting172546 X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= sun4i_ss_probe() creates a debugfs directory and a stats file with struct sun4i_ss_ctx as private data. The remove path unregisters the crypto algorithms and tears down runtime PM but leaves the debugfs entries published. Remove the debugfs subtree before tearing down the driver state used by the stats show callback. Signed-off-by: Pengpeng Hou --- drivers/crypto/allwinner/sun4i-ss/sun4i-ss-core.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/crypto/allwinner/sun4i-ss/sun4i-ss-core.c b/drivers/crypto/allwinner/sun4i-ss/sun4i-ss-core.c index 58a76e2ba64e..bcaddf1b83ca 100644 --- a/drivers/crypto/allwinner/sun4i-ss/sun4i-ss-core.c +++ b/drivers/crypto/allwinner/sun4i-ss/sun4i-ss-core.c @@ -512,6 +512,8 @@ static void sun4i_ss_remove(struct platform_device *pdev) int i; struct sun4i_ss_ctx *ss = platform_get_drvdata(pdev); + debugfs_remove_recursive(ss->dbgfs_dir); + for (i = 0; i < ARRAY_SIZE(ss_algs); i++) { switch (ss_algs[i].type) { case CRYPTO_ALG_TYPE_SKCIPHER: