Lines Matching refs:base
28 int *base, *again; in lkdtm_WRITE_AFTER_FREE() local
35 size_t offset = (len / sizeof(*base)) / 2; in lkdtm_WRITE_AFTER_FREE()
37 base = kmalloc(len, GFP_KERNEL); in lkdtm_WRITE_AFTER_FREE()
38 if (!base) in lkdtm_WRITE_AFTER_FREE()
40 pr_info("Allocated memory %p-%p\n", base, &base[offset * 2]); in lkdtm_WRITE_AFTER_FREE()
42 &base[offset]); in lkdtm_WRITE_AFTER_FREE()
43 kfree(base); in lkdtm_WRITE_AFTER_FREE()
44 base[offset] = 0x0abcdef0; in lkdtm_WRITE_AFTER_FREE()
48 if (again != base) in lkdtm_WRITE_AFTER_FREE()
54 int *base, *val, saw; in lkdtm_READ_AFTER_FREE() local
61 size_t offset = (len / sizeof(*base)) / 2; in lkdtm_READ_AFTER_FREE()
63 base = kmalloc(len, GFP_KERNEL); in lkdtm_READ_AFTER_FREE()
64 if (!base) { in lkdtm_READ_AFTER_FREE()
72 kfree(base); in lkdtm_READ_AFTER_FREE()
77 base[offset] = *val; in lkdtm_READ_AFTER_FREE()
78 pr_info("Value in memory before free: %x\n", base[offset]); in lkdtm_READ_AFTER_FREE()
80 kfree(base); in lkdtm_READ_AFTER_FREE()
83 saw = base[offset]; in lkdtm_READ_AFTER_FREE()
118 int *base; in lkdtm_READ_BUDDY_AFTER_FREE() local
132 base = (int *)p; in lkdtm_READ_BUDDY_AFTER_FREE()
135 base[0] = *val; in lkdtm_READ_BUDDY_AFTER_FREE()
136 pr_info("Value in memory before free: %x\n", base[0]); in lkdtm_READ_BUDDY_AFTER_FREE()
139 saw = base[0]; in lkdtm_READ_BUDDY_AFTER_FREE()