From patchwork Tue Jan 20 23:43:23 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 1712 Return-Path: X-Original-To: u-boot-concept@u-boot.org Delivered-To: u-boot-concept@u-boot.org DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=u-boot.org; s=default; t=1768952673; bh=gT/wCfI1U7tL+Jq2UAA72aInlKl69S6dCILg0/LH/b0=; h=From:To:Date:In-Reply-To:References:CC:Subject:List-Id: List-Archive:List-Help:List-Owner:List-Post:List-Subscribe: List-Unsubscribe:From; b=fMnJ4RH7W1bFZJkSg+VkrtQMUCp32QMfAJLmWdpvdL3h620OzSftvcy3Uqmejvizh B5eY9065/fPpEFwDfVHPTAZcNVTGUaziXBfjHQXVs6JizcWyNcPBL+psVlbhJgQjh6 KnHuNHcj7Nf3m3zcCbYL+ufoB/70OPM6V0QrDr5AOSzm+UN0qv+BjC+VyB7Sy/cNcE VM4iiUFIFJesdWBBIqpL7lA2lRrDRgX8wgtpULaX/J/DgLGPbRD5nvyZXAYARLIMfr LBeSkg4MPQbp8aKGpAyfG17Zh1/Rn/LqwZKtkEI6abCE6JKJges/ZJF/cY9gum10mL IuxUOJ/OjU7fQ== Received: from localhost (localhost [127.0.0.1]) by mail.u-boot.org (Postfix) with ESMTP id 08AB6695AE for ; Tue, 20 Jan 2026 16:44:33 -0700 (MST) X-Virus-Scanned: Debian amavis at Received: from mail.u-boot.org ([127.0.0.1]) by localhost (mail.u-boot.org [127.0.0.1]) (amavis, port 10024) with ESMTP id S0SS4d-kfchT for ; Tue, 20 Jan 2026 16:44:32 -0700 (MST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=u-boot.org; s=default; t=1768952672; bh=gT/wCfI1U7tL+Jq2UAA72aInlKl69S6dCILg0/LH/b0=; h=From:To:Date:In-Reply-To:References:CC:Subject:List-Id: List-Archive:List-Help:List-Owner:List-Post:List-Subscribe: List-Unsubscribe:From; b=gsxQUzIhjmiUwK7QcCbTIDpZ6jofqQis2r5TCcplDvXfgpQULSuuAI7ewRCOWJdOs hiu9d0yID58mOp+qHG6OAR3AmFK3xy/fjpnsCjWvxY/CKO4Wk3canwBvmLbWzYXxE0 ++mBEsKwGppbKv9A5eOyrMDpw8+n8g9qo94rgf/bdZgSAodx7pEbBz34MpFgvY+sSN AvcI850N3+uQtq14G1xo0DeBS52Xp69sWIHk+AAwy+CumK5RGVYkNzqcErtQ9XM91X hRURbp/ceon/URG1fb6+q23CsmkmU1vIhkxTcVB0TrxkrLE0sPdwNBiGiDbq6aE8cd J7z7P8OI0ykEQ== Received: from mail.u-boot.org (localhost [127.0.0.1]) by mail.u-boot.org (Postfix) with ESMTP id EB468695A6 for ; Tue, 20 Jan 2026 16:44:32 -0700 (MST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=u-boot.org; s=default; t=1768952671; bh=jRPx4cEDkmlAkQUUA5lxe7Al0IO4wI9ibTr6xX2Ctis=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=rD966C9lb7V78oATFXq6hgE1pT7RgmfJr/Ov07DFmPOBPldf46un5nSPL5nHbNYAE mMDqDIq1FwDp/n6q86zMwHbekczTIIz9sxfMIlszxH4aFji+RIwWbbGDVDRii+qsFP Y9jNFlMeJfQPlnUiYIrWNSzeIpRM1xzTJ8UhANk5hh0ohxJomRxlGTgO6beyVjjSsU hmCRUabBrdLnxgSiVAal+AXKIxRlHiYJ+y/ZffDqu+H57m+nZdGpYiDbiKtRVxg/GX 9sGlFRsEsAwiCr6FpYEr4B61d+4si0jAZK4UxdVVzdX2UduKUm7fnBwyQL+5gHprHW 4x/4Y4K9Qd/7w== Received: from localhost (localhost [127.0.0.1]) by mail.u-boot.org (Postfix) with ESMTP id 8E58C69597; Tue, 20 Jan 2026 16:44:31 -0700 (MST) X-Virus-Scanned: Debian amavis at Received: from mail.u-boot.org ([127.0.0.1]) by localhost (mail.u-boot.org [127.0.0.1]) (amavis, port 10026) with ESMTP id 6GKDr8y3fLSG; Tue, 20 Jan 2026 16:44:31 -0700 (MST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=u-boot.org; s=default; t=1768952667; bh=s8e4kUNi1QFw/4/9gl4dXZDVrE1FtMTPnPsNvNWpVUw=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=MXhseLxO9fXYsp4d6APMtWNYqvgxQqG2WNFDgQaSqHUR/wQUGyiF925l6X8fHl1Xg V5JjQTDU062jp34NFexlgRgM+qeP52SnUmJnIcg6RL+aOBHliKzbyzsPvY4RLh5gid Xl3TW1g9iZJOnwZh/i2d2/FXpQCsh+PgbNU9Uba4yaenD5Ezs0TrjwgV0R936HnKPv uJgQ9kT2xTc8FtG8O2mBo1G466NzdZITZc0XBPefTtW7R4dIQBxjhYl1e+C97BBxrI tkrBKx3dESaK4VghmcxiS86FxaWqSlPkBIScPhMqY2yioRb+bcJEw9g6M4iR1Ot0wM 0d2LmTOhuLzKg== Received: from u-boot.org (unknown [73.34.74.121]) by mail.u-boot.org (Postfix) with ESMTPSA id 4651669555; Tue, 20 Jan 2026 16:44:27 -0700 (MST) From: Simon Glass To: U-Boot Concept Date: Tue, 20 Jan 2026 16:43:23 -0700 Message-ID: <20260120234344.495605-4-sjg@u-boot.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20260120234344.495605-1-sjg@u-boot.org> References: <20260120234344.495605-1-sjg@u-boot.org> MIME-Version: 1.0 Message-ID-Hash: Q7FR5QVQGLXKSQ3LPSTPO2KOOBJOPNBD X-Message-ID-Hash: Q7FR5QVQGLXKSQ3LPSTPO2KOOBJOPNBD X-MailFrom: sjg@u-boot.org X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; loop; banned-address; emergency; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header CC: Simon Glass , "Claude Opus 4 . 5" X-Mailman-Version: 3.3.10 Precedence: list Subject: [Concept] [PATCH 03/17] ext4l: Move inode state bits to linux/fs.h List-Id: Discussion and patches related to U-Boot Concept Archived-At: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: From: Simon Glass Move the inode state bit definitions (I_NEW, I_FREEING, I_DIRTY_DATASYNC, I_DIRTY_TIME) to linux/fs.h where they belong in the Linux kernel header hierarchy. Co-developed-by: Claude Opus 4.5 Signed-off-by: Simon Glass --- fs/ext4l/ext4_uboot.h | 10 ++-------- include/linux/fs.h | 6 ++++++ 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/fs/ext4l/ext4_uboot.h b/fs/ext4l/ext4_uboot.h index d21462407a8..2274f24f426 100644 --- a/fs/ext4l/ext4_uboot.h +++ b/fs/ext4l/ext4_uboot.h @@ -410,11 +410,7 @@ static inline int bdev_read_only(struct block_device *bdev) /* kuid_t and kgid_t - from linux/cred.h */ #include -/* Inode state bits */ -#define I_NEW (1 << 0) -#define I_FREEING (1 << 1) -#define I_DIRTY_DATASYNC (1 << 2) - +/* Inode state bits (I_NEW, I_FREEING, etc.) are in linux/fs.h */ /* S_SYNC, S_NOATIME, etc. inode flags are in linux/fs.h */ /* S_IRWXUGO is in linux/fs.h */ @@ -423,9 +419,7 @@ static inline int bdev_read_only(struct block_device *bdev) #define WHITEOUT_MODE 0 /* RENAME_* flags are in linux/fs.h */ - -/* Inode dirty state flags */ -#define I_DIRTY_TIME (1 << 3) +/* I_DIRTY_TIME is in linux/fs.h */ /* SB_LAZYTIME is in linux/fs.h */ /* ATTR_* iattr valid flags are in linux/fs.h */ diff --git a/include/linux/fs.h b/include/linux/fs.h index b6a0596a9de..475085e18ee 100644 --- a/include/linux/fs.h +++ b/include/linux/fs.h @@ -311,6 +311,12 @@ enum { /* is_bad_inode - check if inode is marked bad (always false in U-Boot) */ #define is_bad_inode(inode) (0) +/* Inode state bits for i_state field */ +#define I_NEW (1 << 0) +#define I_FREEING (1 << 1) +#define I_DIRTY_DATASYNC (1 << 2) +#define I_DIRTY_TIME (1 << 3) + /** * struct fstrim_range - fstrim ioctl argument * @start: first byte to trim