1 #include "check_debug.h"
3 int copy_from_user(void *dest
, void *src
, int size
);
10 int returns_user_data(void)
14 copy_from_user(&x
, src
, sizeof(int));
19 struct ear
*returns_user_member(void)
21 copy_from_user(&dest
->x
, src
, sizeof(int));
29 x
= returns_user_data();
31 p
= returns_user_member();
33 __smatch_user_rl(p
->x
);
37 * check-name: smatch user data #4
38 * check-command: smatch -p=kernel -I.. sm_user_data4.c
41 sm_user_data4.c:30 test() user rl: 'x' = 's32min-s32max'
42 sm_user_data4.c:32 test() user rl: 'p' = ''
43 sm_user_data4.c:33 test() user rl: 'p->x' = 's32min-s32max'