blob: c2b565ff84c384d9444dcde04f9e782ed4cd6e9d [file] [log] [blame]
// WARNING: suspicious RCU usage in shmem_add_seals
// https://syzkaller.appspot.com/bug?id=e4f035eaf9aaffc5dc8609e4fcf4f35ffb6a0f96
// status:fixed
// autogenerated by syzkaller (https://github.com/google/syzkaller)
#define _GNU_SOURCE
#include <endian.h>
#include <stdint.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <sys/syscall.h>
#include <sys/types.h>
#include <unistd.h>
#ifndef __NR_memfd_create
#define __NR_memfd_create 319
#endif
uint64_t r[1] = {0xffffffffffffffff};
int main(void)
{
syscall(__NR_mmap, 0x20000000, 0x1000000, 3, 0x32, -1, 0);
intptr_t res = 0;
memcpy((void*)0x200000c0, "procppp0posix_acl_access$systemselinux\000", 39);
res = syscall(__NR_memfd_create, 0x200000c0, 2);
if (res != -1)
r[0] = res;
*(uint32_t*)0x20000c40 = -1;
syscall(__NR_write, r[0], 0x20000c40, 0xff67);
syscall(__NR_fcntl, r[0], 0x409, 9);
return 0;
}