From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 969A5E63F1C for ; Sun, 15 Feb 2026 22:55:50 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:Content-Transfer-Encoding: MIME-Version:References:In-Reply-To:Message-ID:Date:Subject:Cc:To:From: Reply-To:Content-Type:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=FsJWFDua2E4VYcmf2pdKCeoU+PWx+kDwobw5R2iufLI=; b=uX/XLcd2/cLfoVdgJCe0igCFzF mC58A3EOsxps0M3oiNUmDQgZWvxemuq/QCAzPcexUV4RRGc0kK2dE44oyW6uyoKyJIhEss59YQzev 63GgVikz84+UBgGLXM7MgctDv+k+T+W/o6r1/KLzrmEp3BbmeEy9zi1GSSKcD7Gpt+VCFsEWTVAR2 vOlXjmlcvbqO/bcQxnfrQ22J6100q70bQ45HdQ7CnGfSl70VOWFvG+H9O7cOaFW77W1AazlvarOIO Wtv6T69SpdIZm4BcSC9oPptRMzPMn38yeWPEKQNjmYD4V/0Bu5x0eQnR6LygTRjGg0WDeK9xaLQKU iUmmcyqA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.98.2 #2 (Red Hat Linux)) id 1vrl1i-00000005jdK-20FR; Sun, 15 Feb 2026 22:55:42 +0000 Received: from zeus03.de ([194.117.254.33] helo=mail.zeus03.de) by bombadil.infradead.org with esmtps (Exim 4.98.2 #2 (Red Hat Linux)) id 1vrl1c-00000005jTH-32bv for linux-arm-kernel@lists.infradead.org; Sun, 15 Feb 2026 22:55:38 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= sang-engineering.com; h=from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; s=k1; bh=FsJWFDua2E4VYcmf2pdKCeoU+PWx+kDwobw5R2iufLI=; b=hLhCnQ euhtV/jxY4f6LKLbNi1MXzcLYstlKOb2w5Z5COu9Zendzk4SF2JcA897dta8kBW2 TgeDH46NLhyn/OuEj7OoX+bXhErngmuRNCRaFihw1wDeRHEuPvbQEKn5VOD3PLoK EfKlPGUjS4zpnjYAnO2OKfun0DeXj4aattu9he8xUfJWXTdNqzbC3YJw05y52Y68 M43L88b7cg1MFLN27OsF2kLzeAMTjl9O3YTf39YrLam9FYXwx7HuQ2FtS5JmdY+o I5jyb60xEaG2MetBYS0UoTurK0lYWDr4JONnpUGu14KNFxCEdtmFwMiEAPxksfsj ylpkBYOpss34EgGA== Received: (qmail 3011603 invoked from network); 15 Feb 2026 23:55:17 +0100 Received: by mail.zeus03.de with ESMTPSA (TLS_AES_256_GCM_SHA384 encrypted, authenticated); 15 Feb 2026 23:55:17 +0100 X-UD-Smtp-Session: l3s3148p1@5f5fu+RKBsEujns5 From: Wolfram Sang To: linux-renesas-soc@vger.kernel.org Cc: Andy Shevchenko , linux-arm-kernel@lists.infradead.org, Wolfram Sang , Bjorn Andersson , Baolin Wang , linux-remoteproc@vger.kernel.org Subject: [RFC PATCH v2 10/13] hwspinlock: remove internal header Date: Sun, 15 Feb 2026 23:54:50 +0100 Message-ID: <20260215225501.6365-11-wsa+renesas@sang-engineering.com> X-Mailer: git-send-email 2.51.0 In-Reply-To: <20260215225501.6365-1-wsa+renesas@sang-engineering.com> References: <20260215225501.6365-1-wsa+renesas@sang-engineering.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20260215_145537_203331_55525AB7 X-CRM114-Status: GOOD ( 15.70 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Because the internal header is now used by the core only, it can also be moved its source code. The header was small enough. Signed-off-by: Wolfram Sang --- drivers/hwspinlock/hwspinlock_core.c | 31 +++++++++++++++- drivers/hwspinlock/hwspinlock_internal.h | 46 ------------------------ 2 files changed, 30 insertions(+), 47 deletions(-) delete mode 100644 drivers/hwspinlock/hwspinlock_internal.h diff --git a/drivers/hwspinlock/hwspinlock_core.c b/drivers/hwspinlock/hwspinlock_core.c index e0227d027cf2..838bb2ab5eba 100644 --- a/drivers/hwspinlock/hwspinlock_core.c +++ b/drivers/hwspinlock/hwspinlock_core.c @@ -10,6 +10,7 @@ #define pr_fmt(fmt) "%s: " fmt, __func__ #include +#include #include #include #include @@ -23,7 +24,35 @@ #include #include -#include "hwspinlock_internal.h" +struct hwspinlock_device; + +/** + * struct hwspinlock - this struct represents a single hwspinlock instance + * @bank: the hwspinlock_device structure which owns this lock + * @lock: initialized and used by hwspinlock core + * @priv: private data, owned by the underlying platform-specific hwspinlock drv + */ +struct hwspinlock { + struct hwspinlock_device *bank; + spinlock_t lock; + void *priv; +}; + +/** + * struct hwspinlock_device - a device which usually spans numerous hwspinlocks + * @dev: underlying device, will be used to invoke runtime PM api + * @ops: platform-specific hwspinlock handlers + * @base_id: id index of the first lock in this device + * @num_locks: number of locks in this device + * @lock: dynamically allocated array of 'struct hwspinlock' + */ +struct hwspinlock_device { + struct device *dev; + const struct hwspinlock_ops *ops; + int base_id; + int num_locks; + struct hwspinlock lock[]; +}; /* retry delay used in atomic context */ #define HWSPINLOCK_RETRY_DELAY_US 100 diff --git a/drivers/hwspinlock/hwspinlock_internal.h b/drivers/hwspinlock/hwspinlock_internal.h deleted file mode 100644 index 20ae531fc389..000000000000 --- a/drivers/hwspinlock/hwspinlock_internal.h +++ /dev/null @@ -1,46 +0,0 @@ -/* SPDX-License-Identifier: GPL-2.0 */ -/* - * Hardware spinlocks internal header - * - * Copyright (C) 2010 Texas Instruments Incorporated - http://www.ti.com - * - * Contact: Ohad Ben-Cohen - */ - -#ifndef __HWSPINLOCK_HWSPINLOCK_H -#define __HWSPINLOCK_HWSPINLOCK_H - -#include -#include - -struct hwspinlock_device; - -/** - * struct hwspinlock - this struct represents a single hwspinlock instance - * @bank: the hwspinlock_device structure which owns this lock - * @lock: initialized and used by hwspinlock core - * @priv: private data, owned by the underlying platform-specific hwspinlock drv - */ -struct hwspinlock { - struct hwspinlock_device *bank; - spinlock_t lock; - void *priv; -}; - -/** - * struct hwspinlock_device - a device which usually spans numerous hwspinlocks - * @dev: underlying device, will be used to invoke runtime PM api - * @ops: platform-specific hwspinlock handlers - * @base_id: id index of the first lock in this device - * @num_locks: number of locks in this device - * @lock: dynamically allocated array of 'struct hwspinlock' - */ -struct hwspinlock_device { - struct device *dev; - const struct hwspinlock_ops *ops; - int base_id; - int num_locks; - struct hwspinlock lock[]; -}; - -#endif /* __HWSPINLOCK_HWSPINLOCK_H */ -- 2.51.0