Message ID | 20240212115500.2078463-19-max.kellermann@ionos.com |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel+bounces-61478-ouuuleilei=gmail.com@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:7300:50ea:b0:106:860b:bbdd with SMTP id r10csp2378311dyd; Mon, 12 Feb 2024 03:59:06 -0800 (PST) X-Google-Smtp-Source: AGHT+IEIHvW67ElyP+mmL5XDO/4ZZ7CQcwOj7wFWnhPn/a0K9yIur56nqws3lOV5Qv1l/yDIEzt+ X-Received: by 2002:a05:6a20:e617:b0:19e:3a8e:e73f with SMTP id my23-20020a056a20e61700b0019e3a8ee73fmr8521015pzb.26.1707739145887; Mon, 12 Feb 2024 03:59:05 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1707739145; cv=pass; d=google.com; s=arc-20160816; b=ABk/opdmDG18pk1HTbgWcM7nzxgsq+IJ6Oo8atR3BEoNHDuTcSAkBmJ8jjY5okehTE duYNUwuWbMEeVsN8SivDIOp2e9Qv9smQpKXeaJ9RpV955EM8LICVWslXOiJ/juSgzdU3 iTuXOb0Me2odU6Fj5zFz0Y+1N25Ix90wub0bDIwpSHDsPoA0HkXb1Wq8YN5c6mobEVYC 4r8piYeeK9aTHIoIGEgkNLGpkWEnVOBem8uhtwlHupg/HfQQOlrCgGIj+QmZvO3BFyxU NHsqU9yUblWvB2QCfO+4xvpYT/yqNkhp5QhmAnB7E/5aGjKmQmhRwQnjtnnAk0Ls+87P MU6g== 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=jYWONKEfyypsQx26Swj5H3vXFHTxMGTOOr2K1QsNu0M=; fh=xRyqcUs+a542028QB3uOYzo/cGSVzU4ObbCcmZjT7ks=; b=qIyM2l9NSIItUJbSaZEk/K7J57+NxHfgl6JD6MP2fFmhUvkcadtXiNE5RZZr/QoJ3R rSJTi8uHxdtXMq94fAHhxMEmzRjuLEavRX+LjmQrI9zLVj1X5MCiWpLSPWDyUwMHXjBR qr7QAlDHKYE5Ns6WtAzILLmz8DeyOdGjyWQVCqziyvC6UFI9DjHwe0A9/wPbMVQgbhWb 0r1dtAVVqkue+PkEKgYoTWmvn/MEf+Iu77XOguZyddCl6VcwlVCnHc5mickaGl8oy6SP EPIhQHGTJSdqBh/ejnF5yNaljMjdPJ/o8mhHmQZDh1xpiox4tSoKH07y36WBNYx5zVE6 4tNw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@ionos.com header.s=google header.b=WUR+egWe; 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-61478-ouuuleilei=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-61478-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=ionos.com X-Forwarded-Encrypted: i=2; AJvYcCX4Gras3kTrXL48S1pC2XMkLNMUyTRNd2sIY5vGGjqDWwPpHEcJB4ADkb7nfkUeORSBDthuWghtfOuXYmeH/qIun1dSBA== Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id k5-20020a633d05000000b005dc36761ae8si135892pga.351.2024.02.12.03.59.05 for <ouuuleilei@gmail.com> (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 12 Feb 2024 03:59:05 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-61478-ouuuleilei=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=WUR+egWe; 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-61478-ouuuleilei=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-61478-ouuuleilei=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 A23F1283E9F for <ouuuleilei@gmail.com>; Mon, 12 Feb 2024 11:59:05 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 0C7D93CF5B; Mon, 12 Feb 2024 11:55:45 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=ionos.com header.i=@ionos.com header.b="WUR+egWe" Received: from mail-ej1-f47.google.com (mail-ej1-f47.google.com [209.85.218.47]) (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 EEAA43A8DB for <linux-kernel@vger.kernel.org>; Mon, 12 Feb 2024 11:55:33 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.218.47 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707738936; cv=none; b=kI1U1DmTTjR2/xxd9pEfjZvjOXcKI7yTN78G15OsSJEe0WdTfiUGbW60xzEg2T9lo6qKgw48hlFYJa6UOg3KnArrRGO0Jz94iMq13lfMewYlxGI01Ijis27yF5ipE8yD5TRfyzHMzAa0aiR1AfhySw4srl+ilrArHTXNBRemCU0= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707738936; c=relaxed/simple; bh=3EMwRWQVmXFpMULqT0KRcNauX3dUmEoNi+TxEAuDB/E=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=Z5Ckzifaqg2nGKlWOXae3hC+y19qYGPE0Yc08GhXu3zwF4arfVEPou2urfstVxGiYl+6pYd3aSKZ7KWKOYKUu7XtDzooJ0RVigggysU7VT8sYhw44VdWANvvBLeVpfyzSR08+lvsSkf7EBwuV8sl+cwAlHfa6EAjT8oJk+jPk9U= 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=WUR+egWe; arc=none smtp.client-ip=209.85.218.47 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-ej1-f47.google.com with SMTP id a640c23a62f3a-a3ca40db065so76974766b.2 for <linux-kernel@vger.kernel.org>; Mon, 12 Feb 2024 03:55:33 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ionos.com; s=google; t=1707738932; x=1708343732; 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=jYWONKEfyypsQx26Swj5H3vXFHTxMGTOOr2K1QsNu0M=; b=WUR+egWeUsyUe4XxZWMHNGZx79eFhW/o/6UA/Cz4MID0LftctkEiea7sb3CXK8toBo 8Y2GAlPxp1hZ0N1VgknaY84ehWDHgShaaFr1U+ku/2uouQv8KecxCCSuqRFvwqj7Nl3+ fNAiK5YEIEIdwWDgiNGBd54XqHVwhWS08qesc+yj1LaijyEJI/2yVsLdzmWTb1N8pzyp +uTuFV/oXDaGTEBLStzRZDaOf39PxRngeURIvJ6xNrYmKFV/EmC6fzMXWeUs4jfQUekK vxidH2L06kQkca3w1J22LavnST4ddlfxLo/JQf/gdQaApc0ZCyWpT6+DA/d0xANeDi1e hTnA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1707738932; x=1708343732; 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=jYWONKEfyypsQx26Swj5H3vXFHTxMGTOOr2K1QsNu0M=; b=MQosWC1p6Exai8e224orI/7QDX4wNLDvR+hsPtJcQkjRLTM61k1qmsBmfRE/Q0wIX5 5zTc/k6s/E5aK/RBUUkkx2GiNfjLMJviftHviK+hyQLBv/tIKgfggmMmLM+8ViCwwkya lgr2piPkp/0jpteaYXg0Zs4Bqon0CgE6iRfvaAyqQvWaAMeWtBrflxbW0EFzHcaQlqP8 7XbPWTkQdLSzMCR2lxLDHsrnJIqHEHCJGeVYjM57JYzC0W2WlJAVLhb8ukJsPcu6wYRN CyF/oZRn40mXyw83Z1dJkSoOw5tyOh3EyRctQDJu4qkk0jkG8shGhe72EL5LeHX9Q4Cl 2Z4A== X-Gm-Message-State: AOJu0YyJjD5UfSzcGhbsEfNMti5a3/fpWJwgiqSYu3sNYK2HnoYjEmJc naBdjialz9wj6JYbJ8rowgoAjTr/VoF6HosrY6nmr4a3WGDHUZ7Nyy1ysHIE/7YTHCvFdshKoOI Q X-Received: by 2002:a17:906:d96f:b0:a3c:ccf7:5fda with SMTP id rp15-20020a170906d96f00b00a3cccf75fdamr687984ejb.46.1707738932239; Mon, 12 Feb 2024 03:55:32 -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 m1-20020a17090607c100b00a36c3e2e52dsm139203ejc.61.2024.02.12.03.55.30 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 12 Feb 2024 03:55:30 -0800 (PST) From: Max Kellermann <max.kellermann@ionos.com> To: linux-kernel@vger.kernel.org Cc: Max Kellermann <max.kellermann@ionos.com> Subject: [PATCH v5 18/35] blkdev.h: move blk_op_is_passthrough() to blk_types.h Date: Mon, 12 Feb 2024 12:54:43 +0100 Message-Id: <20240212115500.2078463-19-max.kellermann@ionos.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240212115500.2078463-1-max.kellermann@ionos.com> References: <20240212115500.2078463-1-max.kellermann@ionos.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: <linux-kernel.vger.kernel.org> List-Subscribe: <mailto:linux-kernel+subscribe@vger.kernel.org> List-Unsubscribe: <mailto:linux-kernel+unsubscribe@vger.kernel.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1790694282580909069 X-GMAIL-MSGID: 1790694282580909069 |
Series |
Fast kernel headers: reduce header dependencies
|
|
Commit Message
Max Kellermann
Feb. 12, 2024, 11:54 a.m. UTC
This is a very low-level function without any additional dependencies,
and moving it will allow certain sources to omit the "blkdev.h"
dependency.
Signed-off-by: Max Kellermann <max.kellermann@ionos.com>
---
include/linux/blk_types.h | 6 ++++++
include/linux/blkdev.h | 6 ------
2 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/include/linux/blk_types.h b/include/linux/blk_types.h index 96a37f399928..ad48c3f5ddd6 100644 --- a/include/linux/blk_types.h +++ b/include/linux/blk_types.h @@ -434,6 +434,12 @@ static inline enum req_op bio_op(const struct bio *bio) return bio->bi_opf & REQ_OP_MASK; } +static inline bool blk_op_is_passthrough(blk_opf_t op) +{ + op &= REQ_OP_MASK; + return op == REQ_OP_DRV_IN || op == REQ_OP_DRV_OUT; +} + static inline bool op_is_write(blk_opf_t op) { return !!(op & (__force blk_opf_t)1); diff --git a/include/linux/blkdev.h b/include/linux/blkdev.h index e67298984913..6bfa4b92bb32 100644 --- a/include/linux/blkdev.h +++ b/include/linux/blkdev.h @@ -260,12 +260,6 @@ static inline int blk_validate_block_size(unsigned long bsize) return 0; } -static inline bool blk_op_is_passthrough(blk_opf_t op) -{ - op &= REQ_OP_MASK; - return op == REQ_OP_DRV_IN || op == REQ_OP_DRV_OUT; -} - /* * BLK_BOUNCE_NONE: never bounce (default) * BLK_BOUNCE_HIGH: bounce all highmem pages