Received: by 2002:a05:7412:3b8b:b0:fc:a2b0:25d7 with SMTP id nd11csp2171311rdb; Sun, 11 Feb 2024 15:17:34 -0800 (PST) X-Google-Smtp-Source: AGHT+IGrpkYIb7vVCk2TNvZe5JrM45HAeYZR0brx2wSGqG8FP1UxQVXbAOTYvaA0xhASeh4ITNbs X-Received: by 2002:a05:6359:4129:b0:176:543c:8ef0 with SMTP id kh41-20020a056359412900b00176543c8ef0mr4884905rwc.21.1707693454324; Sun, 11 Feb 2024 15:17:34 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1707693454; cv=pass; d=google.com; s=arc-20160816; b=To9XAVKMmprAY99bccsYddI1zqPcMYxpHdcpiqb9dHq/c7wMe9Ewf+hP/UqA7UCXIN 0HaSmypQGvBs7FZPbkg+Wyfe3jwe8yut7BpDy5wd8cME1HiPmf+4unnz81UtBmYl8+ZZ qfCOMoaEu7732qeNrR/KeGAfHd6cXVBjFfUmxdSk7IPjGmhLQy4K07v49aiwwLtqTpIr q5pHic99t4gUXotf7OmoApLKzab/YSmj/M09JiEzAKHQvMbT5xOvblP7fVWTaFyMIofp JfLBStom+WFFIUpPd1s4mTkb0HNn51+feIRz80bSNU9hOJwKTpygaL4o1MnTB7jWF5nA m0aw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=SjsOhN8aSrNAMTgfG/Xy/2KiT6HC8gp9GBm4gpWbj44=; fh=fS2KchsX8HE7fE36zuwRhgW1uIFT77mW/X5KABEMlc0=; b=D9UDIpACIjMrxJihcUq94uBpmTTxyD7cRt1AKljT4zBxij7hxDHenfJaZ6pcLZx7Mm xT0YyXXSrCMxEhB9piPUFIQclYYd/FlGsarldZ9+dnWRcI3fiiRtWaMY00p7cQp5a8FW DpwBQFWhBzipPRVQpRDJYDu54+eN1/EGqAx6OJjPCTIlFDCalrqmTb6l4YpkyFJQqbTk JnOgd7aP+x72TRQe4YKRqgshuvdVqOTgLtXFrPKVMNeICNsG1zrJc/EESxNsR0AT29Id Xf3VILGp+Zpn9VWmCoriEXCnWre5rsCK/OGYmn8oj6P6tDxT+UKHvCb+maDtAMgkiM2O 10/A==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@ionos.com header.s=google header.b=fTsUXvP0; arc=pass (i=1 spf=pass spfdomain=ionos.com dkim=pass dkdomain=ionos.com dmarc=pass fromdomain=ionos.com); spf=pass (google.com: domain of linux-kernel+bounces-60994-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-60994-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=ionos.com X-Forwarded-Encrypted: i=2; AJvYcCXkWCBF9Z43dyWjnY0IstOeCniPUR0MKIhjqPx9ekALMPASv/8v69LJTQ504/WEEZKVsDVU1hB68N87OMFa3gicX5QwecPQ0btV1dgbUg== Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id cu22-20020a17090afa9600b00296dc470775si5260093pjb.128.2024.02.11.15.17.34 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 11 Feb 2024 15:17:34 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-60994-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=@ionos.com header.s=google header.b=fTsUXvP0; arc=pass (i=1 spf=pass spfdomain=ionos.com dkim=pass dkdomain=ionos.com dmarc=pass fromdomain=ionos.com); spf=pass (google.com: domain of linux-kernel+bounces-60994-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-60994-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=ionos.com 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 CE35728220E for ; Sun, 11 Feb 2024 23:17:33 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 5226C20B2C; Sun, 11 Feb 2024 23:15:59 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=ionos.com header.i=@ionos.com header.b="fTsUXvP0" Received: from mail-lf1-f50.google.com (mail-lf1-f50.google.com [209.85.167.50]) (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 248B617BA4 for ; Sun, 11 Feb 2024 23:15:47 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.167.50 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707693350; cv=none; b=RDlG9sDsuIFwno0TaMOYIQjcBUd4AGQtbHdCTX+kFVMxCaZRSW2RukT04Wrwf1L+tn0QWm4hu+oayI+XPkzCW7msBbWqOF2T/6VAndHSN70daal4pgY0g48pgG6X/7oSWsidJR1f1sRYQl03kIKVHBkBgJ/u4Z6ax2eBOX5f0no= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707693350; c=relaxed/simple; bh=8E0JnpIDpqJTAIa7eziWdB8a1njbnn7OwwrjBeNl/Hc=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=SJ2AyLYknpXiUHkYy0CYAZkCB2ulZFSzt105ekVpYD43+LJ01joBOnl/NW11sP7qD7JJ0rMuRK3q8WC3NWw8ZinKnqmM/q7nQlKrHSgn0YAFGkge/W8OPMKJl924FBeAM5cvtgg9Iv+zf3wtOaN97Qbi/wSiv0kbZVfQWJPc2R0= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=ionos.com; spf=pass smtp.mailfrom=ionos.com; dkim=pass (2048-bit key) header.d=ionos.com header.i=@ionos.com header.b=fTsUXvP0; arc=none smtp.client-ip=209.85.167.50 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=ionos.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=ionos.com Received: by mail-lf1-f50.google.com with SMTP id 2adb3069b0e04-51186925925so912771e87.0 for ; Sun, 11 Feb 2024 15:15:47 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ionos.com; s=google; t=1707693346; x=1708298146; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=SjsOhN8aSrNAMTgfG/Xy/2KiT6HC8gp9GBm4gpWbj44=; b=fTsUXvP0w87TyqsT0jwBQdC+Oi68Ad8/npPArItiOf7Rj003JOhoDeF7ACesyGE7VW qUL+5pInAwC9gEk1YzNJO6yqG4CrSCm26xJA73H0WzozS6oyuox2Vs9NGfc5Y3vuZzZ6 sX3nHOnKx6mSeGHnaKtA9ABqOAItHmTAEQKawGLR7F+4iGEmbGVbGEWigxZ0uwKsZJFY iiMJX8Uu9biawYrZXOkce4he1lGhpUhF+DNyMjtG75dckcJR3UMFvvHzaI+YBXf2Ec2a fxTwAwwG7sZWOU2vD/XvUaRcTc6i1UOOWX0H7gR0agVYDJNN2wgNg2SsBPJKOK5Nn0lX htVQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1707693346; x=1708298146; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=SjsOhN8aSrNAMTgfG/Xy/2KiT6HC8gp9GBm4gpWbj44=; b=w4mQLNHDte9pLtpE1nTjcPA8q6WIg2nh9w4qsvLA6sQKkrCRYOE40ZYMxGFhZTps1l iALleyqouLsGq4eWxymfnignzZmcJgtRzlghC3HmeQF26bz3c6ByhpBJ8qgTK7f86TH9 Hfqv521AoqZ8ii3YbSYgLStMuJ9+ETDKk3m75Lje5kYQHVDqXkWgPqjgguYQgQdOhap0 NXjkzDMASGho+D8yxDW6JFtxMEM35BG1Hoxqbe2AzRWr3LDl2S+6YLHSccbeIHrFn0Sm 2iYpvX28Ho8gzp0EvG61PYmsY33pFYEHSZ9lvJ+Ci+mRwCTxyPa7mBATI8eEy9HAgwin jC/A== X-Gm-Message-State: AOJu0YyIdaxKA0LurJeSLI0sQUcRb8TtHXmihwWJGZh37ztJiMQLl5wI WauRudujw6YuCiRADU8qQh3bj86JWw4YB1QGRn0Le4JPBESRYCbEIJPcnSHf9tGa17Ttd1KiKKL s X-Received: by 2002:ac2:5607:0:b0:511:769b:f0ac with SMTP id v7-20020ac25607000000b00511769bf0acmr2941770lfd.31.1707693345989; Sun, 11 Feb 2024 15:15:45 -0800 (PST) Received: from raven.blarg.de (p200300dc6f267100023064fffe740809.dip0.t-ipconnect.de. [2003:dc:6f26:7100:230:64ff:fe74:809]) by smtp.gmail.com with ESMTPSA id et13-20020a056402378d00b0055d19c9daf2sm2170180edb.15.2024.02.11.15.15.45 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 11 Feb 2024 15:15:45 -0800 (PST) From: Max Kellermann To: linux-kernel@vger.kernel.org Cc: Max Kellermann Subject: [PATCH v4 14/35] swait.h: move declarations to swait_types.h Date: Mon, 12 Feb 2024 00:14:57 +0100 Message-Id: <20240211231518.349442-15-max.kellermann@ionos.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240211231518.349442-1-max.kellermann@ionos.com> References: <20240211231518.349442-1-max.kellermann@ionos.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit By providing declarations in a lean header, we can reduce header dependencies. Signed-off-by: Max Kellermann --- include/linux/swait.h | 13 +------------ include/linux/swait_types.h | 20 ++++++++++++++++++++ 2 files changed, 21 insertions(+), 12 deletions(-) create mode 100644 include/linux/swait_types.h diff --git a/include/linux/swait.h b/include/linux/swait.h index 68c2e30edb1c..4a4a240b337e 100644 --- a/include/linux/swait.h +++ b/include/linux/swait.h @@ -2,6 +2,7 @@ #ifndef _LINUX_SWAIT_H #define _LINUX_SWAIT_H +#include #include #include #include @@ -38,18 +39,6 @@ * wait queues in most cases. */ -struct task_struct; - -struct swait_queue_head { - raw_spinlock_t lock; - struct list_head task_list; -}; - -struct swait_queue { - struct task_struct *task; - struct list_head task_list; -}; - #define __SWAITQUEUE_INITIALIZER(name) { \ .task = current, \ .task_list = LIST_HEAD_INIT((name).task_list), \ diff --git a/include/linux/swait_types.h b/include/linux/swait_types.h new file mode 100644 index 000000000000..316038879a37 --- /dev/null +++ b/include/linux/swait_types.h @@ -0,0 +1,20 @@ +/* SPDX-License-Identifier: GPL-2.0 */ +#ifndef _LINUX_SWAIT_TYPES_H +#define _LINUX_SWAIT_TYPES_H + +#include +#include + +struct task_struct; + +struct swait_queue_head { + raw_spinlock_t lock; + struct list_head task_list; +}; + +struct swait_queue { + struct task_struct *task; + struct list_head task_list; +}; + +#endif /* _LINUX_SWAIT_TYPES_H */ -- 2.39.2