Received: by 2002:ab2:7903:0:b0:1fb:b500:807b with SMTP id a3csp1465758lqj; Tue, 4 Jun 2024 02:22:29 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCVxdmB45Oknf9TJZ0v+uZcLCxokw1I5PowZfUS4yGLjRi2zi/AL7OElL7hXzKEQsl6e3X4ehcaUKyKVc9H6YIFpY0vS5EtroyF2U1BxtA== X-Google-Smtp-Source: AGHT+IFm33d5JLRgTJV4P6hE/ivXLh3QeDP7LzdFjeZbk1YNesONUhVfGSB5HQSBbwHrQhtGrEOx X-Received: by 2002:a05:6820:82c:b0:5aa:596c:52d0 with SMTP id 006d021491bc7-5ba05dd62a1mr12532419eaf.6.1717492949701; Tue, 04 Jun 2024 02:22:29 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1717492949; cv=pass; d=google.com; s=arc-20160816; b=WErNeqlDD7oaIk4YilAhDjpqtY3/TU6U5Z54nVPKAjFRys4ZQjyeQOje3LAzCDN107 +V0pgyM1n7Wd0rp3+qOTSuMcl3hBtc7u7VmbElAZjE1a55Sai/zF6zK8ydGNgy+8d3Ot Ma/xi8TVRlkZlZd06QxvrP7mcfCA4xnHbdDRJx0Z8ccVyTVBCzId/QW6qTQCPIxWPwLx CgRBbxwB2zBMk9tptTBBaLhkXUJwz3+Kn+ZMmb42h0Tz7RjjeqvkCU7gX7b8amoNnPto EZJT+GtuRoHN3dV+xDgIfQ6InraoiEuGxgQXDcV80Yvs5cI7U9hkU7Iy9xSsnw0SZ8oP GeAQ== 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=i89wEAwGLV+FFt8LVEfujtav/wRlt8aIRY/CjDWyxYI=; fh=eBOm5WG/skwudCKY3SRVuK3g20MKUJXJTygz9RrauXg=; b=DACWbN56KojV9Umc0BUVWIqb0yecoPUUShlBkvpRVc+B46jBBaXxYm0cGNrV+VXsJl fqd0Dwfbufvxy+r2wsg/DxX/Up9RMvMfYa40x+g79qg3oGmc7wkg6Yz6Uzg8DYPO2Ozs A7FU++3gPsfsnvmn0Kx4Mw5YwaEprWTFLj8T/WZXNRheyT5yJ6pUidb3Ps+i7DULpi09 mp3LBloUP9xerSXk2VEVOw/f9CrDc5oql0B37iiwPczE1clT/fxdD2/AmnBnm2Ac0pcP lEQ52zqeWYvmZ1qgiTKiggjSnzpYZVCL+Br0cs1kO79/PMjvgh5OgHMYe2IeGsYOxZ2N SRqw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@ionos.com header.s=google header.b=dmwAWrFv; 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-200325-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-200325-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=ionos.com Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [2604:1380:40f1:3f00::1]) by mx.google.com with ESMTPS id 41be03b00d2f7-6c35a0e6c78si7842334a12.373.2024.06.04.02.22.29 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 04 Jun 2024 02:22:29 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-200325-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) client-ip=2604:1380:40f1:3f00::1; Authentication-Results: mx.google.com; dkim=pass header.i=@ionos.com header.s=google header.b=dmwAWrFv; 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-200325-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-200325-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 sy.mirrors.kernel.org (Postfix) with ESMTPS id DBCF0B23E2D for ; Tue, 4 Jun 2024 09:12:11 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 3D119145A1E; Tue, 4 Jun 2024 09:09:30 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=ionos.com header.i=@ionos.com header.b="dmwAWrFv" Received: from mail-ed1-f53.google.com (mail-ed1-f53.google.com [209.85.208.53]) (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 F02BD145A14 for ; Tue, 4 Jun 2024 09:09:26 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.208.53 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1717492169; cv=none; b=kK4p++bSl/BCD/iHhTkQASVq9giBIHdMjwd6MJW7nX6lCn/VFe6X8LMObbIhx9zsVrAd3unbhv+2Del8iEfKVmscFFpmffdVLwENypaqmit122COlV+63wWrZdiD4Byyq6b8VMJKz8Pp/IFv8YVW9n1//VEcKDH1wLFy0fMW08U= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1717492169; c=relaxed/simple; bh=HD/XTIQjEizEu0O4MOPQDcGyqhajbjK+uDvPpK4p2jo=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=SsqlqXQrfN9GE9iyIn8BcRc77N9tnLCJ+2+5OVi4YvtEMv6bH7qjYRna3TnW07noO37T6n4YJL0yWpddUsJb8CH0D8bBGxVR1lzyWG/90c94USwh6XSDv/aPlxbPjsacyjKHHloMT8PzKIFZ/SkjXX3KKsDEKJeq8swsHk82rPM= 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=dmwAWrFv; arc=none smtp.client-ip=209.85.208.53 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-ed1-f53.google.com with SMTP id 4fb4d7f45d1cf-57a7dc13aabso850991a12.0 for ; Tue, 04 Jun 2024 02:09:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ionos.com; s=google; t=1717492165; x=1718096965; 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=i89wEAwGLV+FFt8LVEfujtav/wRlt8aIRY/CjDWyxYI=; b=dmwAWrFvkCM29wyBVVBcY6ITOhiCvnXkhdkN8fMYSQoSPlik7Sai9Vd8rrxy/FrnHV m3VrLVGlqFzGRj8PTJggPT7QDSurjqMXgla0/Fq4JJZrzT+V6TK8s0ze7PsAaopsqzwI GXLG0/rYizSaOZ4lsefcNpg7mXtY5LigBC/XJTvl2nM5qNgV08yOOzTdb01fEIMjV6Hj hQLE6SnzMdk87WMpazTU1b7RxOzN9kL7QIrFHA35HPDDfwa8dLe2N7BzqONtlEWC5VhU 8p/QWK366aGz36tYgONqgYvpIm5XEgtN+VwKfC0dXMyZiWXyMj8C/RFeYDdBHohQyb+i WtGw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1717492165; x=1718096965; 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=i89wEAwGLV+FFt8LVEfujtav/wRlt8aIRY/CjDWyxYI=; b=X7R7zvMQ1ov+/48uldsMAxpN9ZqGCwoH8VlcV9d0ASxQ1H93ipUwOqfNI1THMGEZuA vJUAOlCDzANRv2JpSBVmhq+5+HFdKKTqrThiJnBN3iEbR300mSZvlmYY+8KT447AHcJo Ix/HhmeT42s6d70SjRCj5XHPLMWMjAD5qNkroWw1kvO2PDYUKUy4RBA+9vzaBmEm7KS+ SRs2eWmeow4ssk0s32hK9X98rNxeyIit9WjRHyBbOqq3Sc5ho8eP1snv/mF5FX4uPguT fc6kyXaVbUQLLx2oWU66Sp5Fi2iyZtPaGSIuVZrNHKvFZNVRPg8I+Fbizse1hg/wacuM CnAA== X-Forwarded-Encrypted: i=1; AJvYcCWmpSfjoSWSr7OOkOY1p4KfpS9ljcjz3z+fm/hpkozmUZXItSE0cIcH1x6tY4W2mK9sO6bVOhvTzI1XA0SuCLLhWTAAaanhFRTL1jSi X-Gm-Message-State: AOJu0YzmOkpxWgb2Oxi7wGro7TgP2XCZbcdHKqY+OK+69C1CDzewNuod z1vhwPGD3D2V8oIfXL9aUgzeJeCScEDB0ZPN016pdGeLcQiNlHu3739xoO0mr/s= X-Received: by 2002:a17:907:970e:b0:a69:228:8a6e with SMTP id a640c23a62f3a-a690228939dmr414530066b.44.1717492165278; Tue, 04 Jun 2024 02:09:25 -0700 (PDT) Received: from raven.blarg.de (p200300dc6f4f9200023064fffe740809.dip0.t-ipconnect.de. [2003:dc:6f4f:9200:230:64ff:fe74:809]) by smtp.gmail.com with ESMTPSA id a640c23a62f3a-a68fa49e66fsm328376766b.129.2024.06.04.02.09.24 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 04 Jun 2024 02:09:24 -0700 (PDT) From: Max Kellermann To: akpm@linux-foundation.org, linux-mm@kvack.org, linux-kernel@vger.kernel.org Cc: willy@infradead.org, sfr@canb.auug.org.au, david@redhat.com, Max Kellermann Subject: [PATCH v6 15/15] include: reduce dependencies on linux/mm.h Date: Tue, 4 Jun 2024 11:08:45 +0200 Message-Id: <20240604090845.2182265-16-max.kellermann@ionos.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240604090845.2182265-1-max.kellermann@ionos.com> References: <20240604090845.2182265-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 Replace with the smaller pieces that were just splitted out. This affects a few headers that are included by many, e.g. bio.h and highmem.h, which now no longer depend on the fat header. For this, several missing includes need to be added because they are no longer indirectly included, e.g. . Signed-off-by: Max Kellermann --- include/linux/bio.h | 2 ++ include/linux/bpfptr.h | 1 - include/linux/dma-mapping.h | 1 + include/linux/highmem-internal.h | 2 ++ include/linux/highmem.h | 4 +++- include/linux/net.h | 2 +- include/linux/oom.h | 2 +- include/linux/pagemap.h | 2 +- include/linux/scatterlist.h | 2 +- include/linux/skbuff.h | 4 ++++ include/linux/vmstat.h | 3 ++- lib/scatterlist.c | 1 + 12 files changed, 19 insertions(+), 7 deletions(-) diff --git a/include/linux/bio.h b/include/linux/bio.h index d5379548d684..ddb0c831557b 100644 --- a/include/linux/bio.h +++ b/include/linux/bio.h @@ -5,7 +5,9 @@ #ifndef __LINUX_BIO_H #define __LINUX_BIO_H +#include // for struct kiocb, IOCB_NOWAIT #include +#include /* struct bio, bio_vec and BIO_* flags are defined in blk_types.h */ #include #include diff --git a/include/linux/bpfptr.h b/include/linux/bpfptr.h index 1af241525a17..19967a0e510c 100644 --- a/include/linux/bpfptr.h +++ b/include/linux/bpfptr.h @@ -3,7 +3,6 @@ #ifndef _LINUX_BPFPTR_H #define _LINUX_BPFPTR_H -#include #include typedef sockptr_t bpfptr_t; diff --git a/include/linux/dma-mapping.h b/include/linux/dma-mapping.h index f693aafe221f..5a66ade2ddf8 100644 --- a/include/linux/dma-mapping.h +++ b/include/linux/dma-mapping.h @@ -11,6 +11,7 @@ #include #include #include +#include /** * List of possible attributes associated with a DMA mapping. The semantics diff --git a/include/linux/highmem-internal.h b/include/linux/highmem-internal.h index a3028e400a9c..a479e6b7c54c 100644 --- a/include/linux/highmem-internal.h +++ b/include/linux/highmem-internal.h @@ -2,6 +2,8 @@ #ifndef _LINUX_HIGHMEM_INTERNAL_H #define _LINUX_HIGHMEM_INTERNAL_H +#include + /* * Outside of CONFIG_HIGHMEM to support X86 32bit iomap_atomic() cruft. */ diff --git a/include/linux/highmem.h b/include/linux/highmem.h index 00341b56d291..10a165a913ad 100644 --- a/include/linux/highmem.h +++ b/include/linux/highmem.h @@ -7,7 +7,9 @@ #include #include #include -#include +#include // for page_size() +#include // for folio_put() +#include #include #include diff --git a/include/linux/net.h b/include/linux/net.h index 688320b79fcc..481fd7e831af 100644 --- a/include/linux/net.h +++ b/include/linux/net.h @@ -21,7 +21,7 @@ #include #include #include -#include +#include // for page_count() #include #include diff --git a/include/linux/oom.h b/include/linux/oom.h index 7d0c9c48a0c5..518426e092d0 100644 --- a/include/linux/oom.h +++ b/include/linux/oom.h @@ -8,7 +8,7 @@ #include #include #include /* MMF_* */ -#include /* VM_FAULT* */ +#include /* VM_FAULT* */ struct zonelist; struct notifier_block; diff --git a/include/linux/pagemap.h b/include/linux/pagemap.h index 8f09ed4a4451..43e233c998d2 100644 --- a/include/linux/pagemap.h +++ b/include/linux/pagemap.h @@ -5,7 +5,7 @@ /* * Copyright 1995 Linus Torvalds */ -#include +#include #include #include #include diff --git a/include/linux/scatterlist.h b/include/linux/scatterlist.h index 0516e64dc03e..9221bba82b23 100644 --- a/include/linux/scatterlist.h +++ b/include/linux/scatterlist.h @@ -5,7 +5,7 @@ #include #include #include -#include +#include #include #ifdef CONFIG_UML diff --git a/include/linux/skbuff.h b/include/linux/skbuff.h index fe7d8dbef77e..09d020d5a6f4 100644 --- a/include/linux/skbuff.h +++ b/include/linux/skbuff.h @@ -16,6 +16,10 @@ #include #include #include +#include // for alloc_pages_node() +#include // for get_page(), put_page() +#include // for page_to_nid() +#include // for page_is_pfmemalloc() #include #include #include diff --git a/include/linux/vmstat.h b/include/linux/vmstat.h index 67c2505d3b78..b9ad7fa932e0 100644 --- a/include/linux/vmstat.h +++ b/include/linux/vmstat.h @@ -4,7 +4,8 @@ #include #include -#include // for folio_zone(), folio_nr_pages() +#include // for folio_nr_pages() +#include // for folio_zone() #include #include #include diff --git a/lib/scatterlist.c b/lib/scatterlist.c index 7bc2220fea80..775bad99fcd9 100644 --- a/lib/scatterlist.c +++ b/lib/scatterlist.c @@ -9,6 +9,7 @@ #include #include #include +#include #include #include -- 2.39.2