From d31cbb26caa5dfe15b0fa34e10c7ac8df9e5f4f6 Mon Sep 17 00:00:00 2001 From: zhao_zhen_fang Date: Tue, 28 Nov 2023 13:46:23 +0800 Subject: [PATCH] Define mutex lock structure --- vmlinux/loongarch/vmlinux.h | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) diff --git a/vmlinux/loongarch/vmlinux.h b/vmlinux/loongarch/vmlinux.h index 4a0ad422..ab8fd061 100644 --- a/vmlinux/loongarch/vmlinux.h +++ b/vmlinux/loongarch/vmlinux.h @@ -269,3 +269,37 @@ struct kobject { struct module_param_attrs; struct completion; + +struct module_kobject { + struct kobject kobj; + struct module *mod; + struct kobject *drivers_dir; + struct module_param_attrs *mp; + struct completion *kobj_completion; +}; + +struct optimistic_spin_queue { + atomic_t tail; +}; + +struct mutex { + atomic_long_t owner; + raw_spinlock_t wait_lock; + struct optimistic_spin_queue osq; + struct list_head wait_list; +}; + +struct rb_node { + long unsigned int __rb_parent_color; + struct rb_node *rb_right; + struct rb_node *rb_left; +}; + +struct latch_tree_node { + struct rb_node node[2]; +}; + +struct mod_tree_node { + struct module *mod; + struct latch_tree_node node; +}; -- Gitee