1 /* SPDX-License-Identifier: GPL-2.0 */
2 /*
3 * Copyright (C) 2022 Huawei Technologies Co., Ltd. All rights reserved.
4 */
5
6 #ifndef DFX_HUNGTASK_USER_H
7 #define DFX_HUNGTASK_USER_H
8
9 #include <linux/types.h>
10
11 #ifdef CONFIG_DFX_HUNGTASK_USER
12 void htuser_post_process_userlist(void);
13 ssize_t htuser_list_store(struct kobject *kobj,
14 struct kobj_attribute *attr, const char *buf, size_t count);
15 ssize_t htuser_list_show(struct kobject *kobj,
16 struct kobj_attribute *attr, char *buf);
17 #else
htuser_post_process_userlist(void)18 static inline void htuser_post_process_userlist(void)
19 {
20 }
21
htuser_list_store(struct kobject * kobj,struct kobj_attribute * attr,const char * buf,size_t count)22 static inline ssize_t htuser_list_store(struct kobject *kobj,
23 struct kobj_attribute *attr,
24 const char *buf, size_t count)
25 {
26 return 0;
27 }
htuser_list_show(struct kobject * kobj,struct kobj_attribute * attr,char * buf)28 static inline ssize_t htuser_list_show(struct kobject *kobj,
29 struct kobj_attribute *attr,
30 char *buf)
31 {
32 return 0;
33 }
34
35 #endif
36
37 #endif /* DFX_HUNGTASK_USER_H */
38