From patchwork Sat Dec 20 23:23:42 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 996 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=1766273055; bh=AvRh1P1uHtBNzjZU7hHufwPjInVdFzj1SrMbg53o4WI=; 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=fCQofaCjJ5AffcMiG9muEdqQ5CyzzQu5iXP0n0aoeCa8tTSvLkba3XbnYZad5wVbR HmXwkZm3Ch8Xsff012R0piie+9Eg75B1NViMxSURxt8FxVGOzt4AvlcU7/YPy1RUJq O31N+yZjHEbzuGhs9dLu+/tH/h5ANmoeG9sfQGgNbNR8pzUiqHzA8AXn7l0adAb9Ie avAAdKqQm9tmkamZo00nDCrxBV8esmDEpfFemncyb2frmZDuZbK9qCxPH4D7cOzt4l dV0fpUPslit97A+bn8C2DsCOWtkNIMaUZioJP7ezr6pbWNZ97a4ao2Yg4cUIKdo2Vw 8BlJZylfiET3Q== Received: from localhost (localhost [127.0.0.1]) by mail.u-boot.org (Postfix) with ESMTP id AE85964C60 for ; Sat, 20 Dec 2025 16:24:15 -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 o0ZhD_LN3C8k for ; Sat, 20 Dec 2025 16:24:15 -0700 (MST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=u-boot.org; s=default; t=1766273055; bh=AvRh1P1uHtBNzjZU7hHufwPjInVdFzj1SrMbg53o4WI=; 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=fCQofaCjJ5AffcMiG9muEdqQ5CyzzQu5iXP0n0aoeCa8tTSvLkba3XbnYZad5wVbR HmXwkZm3Ch8Xsff012R0piie+9Eg75B1NViMxSURxt8FxVGOzt4AvlcU7/YPy1RUJq O31N+yZjHEbzuGhs9dLu+/tH/h5ANmoeG9sfQGgNbNR8pzUiqHzA8AXn7l0adAb9Ie avAAdKqQm9tmkamZo00nDCrxBV8esmDEpfFemncyb2frmZDuZbK9qCxPH4D7cOzt4l dV0fpUPslit97A+bn8C2DsCOWtkNIMaUZioJP7ezr6pbWNZ97a4ao2Yg4cUIKdo2Vw 8BlJZylfiET3Q== Received: from mail.u-boot.org (localhost [127.0.0.1]) by mail.u-boot.org (Postfix) with ESMTP id 9EB7764C57 for ; Sat, 20 Dec 2025 16:24:15 -0700 (MST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=u-boot.org; s=default; t=1766273054; bh=JfeZ9UG6zlq3fFFWi8DTsuVnoOl1EiaPzFgpdvOU5Cw=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=KboDYUKGde4wcu+58YivIkEHERDPPi61+px1D80l6QGVhnWZWKmnhwLxFlo1+VUb6 7gvAbXshfdQOvjaVd6sIkT3FdCrU3V64hHSr1Q3FaYP3CbqTXS9PisOhhVI6I/2pGa hwt7R27/HUg4lOlNStEw8iMeoiRQ7ciZ1rMApFrUrSggXbWJxTqQmKB6RH21XX1SOk FSB1Oqjt6EYWCRypEpq2D8CKyrfNzk2cwDhmhNEzG2oJgSEFkRoROVAdcyX5PMZ+6A Z8H9lXiffpHIRu4uzSYDf80R4gj1c2tj4/5t5R1HqJR+6CRcDVNqBn83d0C6/dGkcL hOVbQWv7decOQ== Received: from localhost (localhost [127.0.0.1]) by mail.u-boot.org (Postfix) with ESMTP id A311C64C29; Sat, 20 Dec 2025 16:24:14 -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 SesJA7BjMpf0; Sat, 20 Dec 2025 16:24:14 -0700 (MST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=u-boot.org; s=default; t=1766273050; bh=x5dQximWjNkMmjZBKA8fCjbnZYyjOGmgeLDXUMW22I8=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Q/aoaPv5/wNVcxN5q4FcJLQYp0tZJdAKoEy3kwNsDnR1VW0747F4S2BJhwo2xqouz LfA/EfgUowpddXIA8f8KCh+s5WJq7n+uiED/0cC7447l5qgBxOxTfxnM2jfgx/AH9U MCHPbND39mFxxMBktB5LYLLjBcQjotXaKsvsf6+imY/ed5/ephma6ddO6vUxrVC/4t XAqOV1jUdGjEmo2X0baa/sNTK6VGKv1bgZHQdVrwEPPb5z8HlPDAve5ii/9VS/QJs4 wF16Vj2hZ/thVwe+NQ5ypoXw5bIWHq8WLDIEG77KDd1HytOxtH3SWQgSS7RVnBADPu kCZspnjOjWetg== Received: from u-boot.org (unknown [73.34.74.121]) by mail.u-boot.org (Postfix) with ESMTPSA id 2FB5964C25; Sat, 20 Dec 2025 16:24:10 -0700 (MST) From: Simon Glass To: U-Boot Concept Date: Sat, 20 Dec 2025 16:23:42 -0700 Message-ID: <20251220232355.845414-3-sjg@u-boot.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20251220232355.845414-1-sjg@u-boot.org> References: <20251220232355.845414-1-sjg@u-boot.org> MIME-Version: 1.0 Message-ID-Hash: QW4UYAAS6SGZ4W5PWP3KN3J5E63MZSER X-Message-ID-Hash: QW4UYAAS6SGZ4W5PWP3KN3J5E63MZSER 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 02/10] ext4l: Add stubs for xattr functions used by ialloc.c 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 Add stub declarations and implementations for xattr functions that ialloc.c calls but which are defined in xattr.c (not yet compiled): - __ext4_xattr_set_credits - ext4_init_security Add declarations to ext4_uboot.h and implementations to stub.c. Co-developed-by: Claude Opus 4.5 Signed-off-by: Simon Glass --- fs/ext4l/ext4_uboot.h | 10 ++++++++-- fs/ext4l/stub.c | 18 ++++++++++++++++++ 2 files changed, 26 insertions(+), 2 deletions(-) diff --git a/fs/ext4l/ext4_uboot.h b/fs/ext4l/ext4_uboot.h index 41de40b4ee0..943b474cdc8 100644 --- a/fs/ext4l/ext4_uboot.h +++ b/fs/ext4l/ext4_uboot.h @@ -366,9 +366,15 @@ extern struct user_namespace init_user_ns; #ifndef _FS_EXT4_ACL_H #define ext4_init_acl(h, i, d) ({ (void)(h); (void)(i); (void)(d); 0; }) #endif -/* Note: ext4_init_security is already handled in xattr.h */ +/* xattr stubs for files that don't include xattr.h */ +struct super_block; +struct buffer_head; +struct qstr; -/* xattr stubs - __ext4_xattr_set_credits is declared in xattr.h */ +int __ext4_xattr_set_credits(struct super_block *sb, struct inode *inode, + struct buffer_head *block_bh, size_t value_len, + bool is_create); +/* ext4_init_security is declared in xattr.h */ /* inode state stubs */ #define is_bad_inode(inode) (0) diff --git a/fs/ext4l/stub.c b/fs/ext4l/stub.c index 04e6cbb680a..44cc4b7f52e 100644 --- a/fs/ext4l/stub.c +++ b/fs/ext4l/stub.c @@ -377,3 +377,21 @@ struct buffer_head *ext4_sb_bread_nofail(struct super_block *sb, { return NULL; } + +/* + * Stubs for ialloc.c - xattr functions + */ +int __ext4_xattr_set_credits(struct super_block *sb, struct inode *inode, + struct buffer_head *block_bh, size_t value_len, + bool is_create) +{ + return 0; +} + +struct qstr; + +int ext4_init_security(void *handle, struct inode *inode, struct inode *dir, + const struct qstr *qstr) +{ + return 0; +}