From patchwork Mon Feb 13 18:26:21 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: tip-bot2 for Thomas Gleixner X-Patchwork-Id: 56430 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:eb09:0:0:0:0:0 with SMTP id s9csp2502546wrn; Mon, 13 Feb 2023 10:30:01 -0800 (PST) X-Google-Smtp-Source: AK7set/N500yTJVgCArEkTIGMlIGl8N195xq+Msxei/3bptqKdxmJAzfX7kcBvfInUk6TfuusKJU X-Received: by 2002:a50:ab01:0:b0:492:8c77:7dad with SMTP id s1-20020a50ab01000000b004928c777dadmr26072702edc.8.1676313001042; Mon, 13 Feb 2023 10:30:01 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1676313001; cv=none; d=google.com; s=arc-20160816; b=ETX979wruIJc/Jx7Ds4hvZQNSumJb5iBC1WEm4ACwrxZktMbrZdAG3aIwfc0wzZAG1 /J8m2WqkdAfLaCM1xmUnjCfzcgDP6mJxN9y6JmACQ+twVPQAnepg4lgRk/ylfhWagR3s 1NsomCVMBJIEpV+zs8odCtGcm/lZ8/EH7rzNIDMN/IJ6xYnjaGY/68YLdu3tr9xq+VXG n1oHYvu4gltqNyw2kKqEQIv0wt+w+x0lqhizoXPTJmOnlVO7c34Fzb0l2fqOfBfIC/mH 7FEB7eeqqOaJLty2ind9ADMKKECvOlJPRxaZcoW1DhueTlJbaeoe4RKZbJ7fWc7XmkYG lpRg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:robot-unsubscribe :robot-id:message-id:mime-version:references:in-reply-to:cc:subject :to:reply-to:sender:from:dkim-signature:dkim-signature:date; bh=iGg2QXQKl2CgLX1ZcBsVOjfuAPw42Vx4U2RONkij9ec=; b=S3VZxoLNVEwpeWYcyqvofI2UoydVaincHzR4SRNtsJ0VQ4t0Edn14TpF16IOt0jUgK WGb3qWXfB7V6/I3FA5PTI/siWbu/OKIPA22i78pfvuiZS6CahG2iaGjBh/qWVPPaCuW1 4M2zuSv2jZHll3ibYL2KNxgofeWZ+Br80OPMUOGIGErwlTRGRWi4/AV9fDH3Rx+1aBNj Nip9806Gd1aCPf6i9iIGU9qUTgN/QO1pjQZ3DgffFIFo72cl6gdEevu2uAOW+A1IYKwy UsFKxaT5tnkx4vFN/xh/0QliSG3gW/JbVe+0XOdIKIdvlfrnvH9+yOSE6RSxIp91JxXN dViQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=CH9GC2WF; dkim=neutral (no key) header.i=@linutronix.de header.s=2020e header.b=E78YwoE8; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id g4-20020aa7c584000000b004a241619690si13836904edq.369.2023.02.13.10.29.36; Mon, 13 Feb 2023 10:30:01 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=CH9GC2WF; dkim=neutral (no key) header.i=@linutronix.de header.s=2020e header.b=E78YwoE8; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230289AbjBMS0c (ORCPT + 99 others); Mon, 13 Feb 2023 13:26:32 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46576 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229747AbjBMS00 (ORCPT ); Mon, 13 Feb 2023 13:26:26 -0500 Received: from galois.linutronix.de (Galois.linutronix.de [IPv6:2a0a:51c0:0:12e:550::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1AABA6EB5; Mon, 13 Feb 2023 10:26:24 -0800 (PST) Date: Mon, 13 Feb 2023 18:26:21 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1676312782; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=iGg2QXQKl2CgLX1ZcBsVOjfuAPw42Vx4U2RONkij9ec=; b=CH9GC2WFCixUvaf78/HF1IpsR8TXSjL9De8kbUDOw9sD/IsupvEpMUZX92zfoju9x9LXAF Fz0ILrWr/J99jYmTr12TcuGBaUjIFSVF8QKfsfiEHgsQ4jU1B2YcTrCyQ7tg5zHzeHSWgs Npzc8Fpxc8Tp0E7Nsi3utqBImi9EMb7cJqUFvqMBTkJYMDHGHBDLkyjqRvR0QILLo8sUxW 017Csp3lcXBMAKgQYzEF07mJaelJqE/WKNnyAOqCSXk/pnEXoO8o6SCGCllW+zddEORGVj RcmJloeCC6XSD9PY2rbW9JEcBi7Xn6R1OTbYUjKhRsuKYEMaEhfAsFlqWwihgQ== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1676312782; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=iGg2QXQKl2CgLX1ZcBsVOjfuAPw42Vx4U2RONkij9ec=; b=E78YwoE8OdA/N1opVM1T3RKE3AhF1uQfswOyd/IaxZ21qzOODbNq6G83u+bsrgRFjPyHbI n8hKJoe+U79ZQDDA== From: tip-bot2 for Uwe =?utf-8?q?Kleine-K=C3=B6nig?= Sender: tip-bot2@linutronix.de Reply-to: linux-kernel@vger.kernel.org To: linux-tip-commits@vger.kernel.org Subject: [tip: timers/core] clocksource/drivers/sh_tmu: Mark driver as non-removable Cc: u.kleine-koenig@pengutronix.de, Daniel Lezcano , x86@kernel.org, linux-kernel@vger.kernel.org In-Reply-To: <20230207193614.472060-1-u.kleine-koenig@pengutronix.de> References: <20230207193614.472060-1-u.kleine-koenig@pengutronix.de> MIME-Version: 1.0 Message-ID: <167631278189.4906.11559302770332050280.tip-bot2@tip-bot2> Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED,SPF_HELO_NONE, SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1757741581484557699?= X-GMAIL-MSGID: =?utf-8?q?1757741581484557699?= The following commit has been merged into the timers/core branch of tip: Commit-ID: d8c695d310a8607fd1d6a2750368467c4e0cef6a Gitweb: https://git.kernel.org/tip/d8c695d310a8607fd1d6a2750368467c4e0cef6a Author: Uwe Kleine-König AuthorDate: Tue, 07 Feb 2023 20:36:14 +01:00 Committer: Daniel Lezcano CommitterDate: Mon, 13 Feb 2023 13:10:17 +01:00 clocksource/drivers/sh_tmu: Mark driver as non-removable The comment in the remove callback suggests that the driver is not supposed to be unbound. However returning an error code in the remove callback doesn't accomplish that. Instead set the suppress_bind_attrs property (which makes it impossible to unbind the driver via sysfs). The only remaining way to unbind a sh_tmu device would be module unloading, but that doesn't apply here, as the driver cannot be built as a module. Also drop the useless remove callback. Signed-off-by: Uwe Kleine-König Link: https://lore.kernel.org/r/20230207193614.472060-1-u.kleine-koenig@pengutronix.de Signed-off-by: Daniel Lezcano --- drivers/clocksource/sh_tmu.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/drivers/clocksource/sh_tmu.c b/drivers/clocksource/sh_tmu.c index b00dec0..932f31a 100644 --- a/drivers/clocksource/sh_tmu.c +++ b/drivers/clocksource/sh_tmu.c @@ -632,11 +632,6 @@ static int sh_tmu_probe(struct platform_device *pdev) return 0; } -static int sh_tmu_remove(struct platform_device *pdev) -{ - return -EBUSY; /* cannot unregister clockevent and clocksource */ -} - static const struct platform_device_id sh_tmu_id_table[] = { { "sh-tmu", SH_TMU }, { "sh-tmu-sh3", SH_TMU_SH3 }, @@ -652,10 +647,10 @@ MODULE_DEVICE_TABLE(of, sh_tmu_of_table); static struct platform_driver sh_tmu_device_driver = { .probe = sh_tmu_probe, - .remove = sh_tmu_remove, .driver = { .name = "sh_tmu", .of_match_table = of_match_ptr(sh_tmu_of_table), + .suppress_bind_attrs = true, }, .id_table = sh_tmu_id_table, };