Add stub headers for various Linux kernel interfaces that ext4 code expects: - sched.h: scheduler stubs (task_struct, cond_resched, yield) - wait.h: wait queue stubs - rwsem.h: read-write semaphore stubs - percpu_counter.h: percpu counter implementation (single-threaded) - random.h: random number stubs - quotaops.h: disk quota operation stubs - part_stat.h: partition statistics stubs - prefetch.h: prefetch operation stubs - sort.h: sort wrapper using stdlib qsort - swap.h: swap/memory management stubs Update compat.h to include new headers and remove duplicate definitions. Co-developed-by: Claude Opus 4.5 <noreply@anthropic.com> Signed-off-by: Simon Glass <simon.glass@canonical.com> Series-to: concept Cover-letter: ext4l: Add Linux compatibility headers This series extracts Linux kernel compatibility declarations from include/linux/compat.h into their own header files, matching the Linux kernel's organization. This makes it easier to port Linux filesystem code to U-Boot and keeps the compatibility layer maintainable. The headers come from Linux v6.18 Headers added: - export.h: EXPORT_SYMBOL macros - stddef.h: sizeof_field() macro - uaccess.h: copy_to/from_user stubs - capability.h, cred.h, file.h, path.h, security.h, seq_file.h - freezer.h: process freezer stubs - slab.h, vmalloc.h: memory allocation - module.h: kernel module stubs - init.h: initcall macros - kthread.h: kernel thread stubs - timer.h, workqueue.h: timer and workqueue stubs - sched.h, wait.h, rwsem.h: scheduler and synchronization - percpu_counter.h, random.h, quotaops.h, part_stat.h, prefetch.h, sort.h, swap.h All headers include appropriate copyright/author information from the original Linux sources. END Series-links: 1:77 Series-version: 2 Signed-off-by: Simon Glass <simon.glass@canonical.com>
39 lines
1.2 KiB
C
39 lines
1.2 KiB
C
/* SPDX-License-Identifier: GPL-2.0 */
|
|
/*
|
|
* Definitions for diskquota-operations. When diskquota is configured these
|
|
* macros expand to the right source-code.
|
|
*
|
|
* Author: Marco van Wieringen <mvw@planets.elm.net>
|
|
*
|
|
* Stub definitions for quota operations.
|
|
* U-Boot doesn't support disk quotas.
|
|
*/
|
|
#ifndef _LINUX_QUOTAOPS_H
|
|
#define _LINUX_QUOTAOPS_H
|
|
|
|
struct inode;
|
|
struct dentry;
|
|
struct kqid;
|
|
|
|
#define dquot_initialize(inode) 0
|
|
#define dquot_drop(inode) do { } while (0)
|
|
#define dquot_alloc_inode(inode) 0
|
|
#define dquot_free_inode(inode) do { } while (0)
|
|
#define dquot_transfer(inode, attr) 0
|
|
#define dquot_claim_space_nodirty(inode, nr) 0
|
|
#define dquot_reclaim_space_nodirty(inode, nr) do { } while (0)
|
|
#define dquot_disable(sb, type, flags) 0
|
|
#define dquot_suspend(sb, type) 0
|
|
#define dquot_resume(sb, type) 0
|
|
#define dquot_file_open(inode, file) 0
|
|
|
|
#define sb_has_quota_usage_enabled(sb, type) 0
|
|
#define sb_has_quota_limits_enabled(sb, type) 0
|
|
#define sb_has_quota_suspended(sb, type) 0
|
|
#define sb_has_quota_loaded(sb, type) 0
|
|
#define sb_has_quota_active(sb, type) 0
|
|
#define sb_any_quota_loaded(sb) 0
|
|
#define sb_any_quota_active(sb) 0
|
|
|
|
#endif /* _LINUX_QUOTAOPS_H */
|