• Eric W. Biederman's avatar
    coredump: Don't compile flat_core_dump when coredumps are disabled · f833116a
    Eric W. Biederman authored
    Recently the kernel test robot reported:
    > In file included from include/linux/kernel.h:29,
    >                     from fs/binfmt_flat.c:21:
    >    fs/binfmt_flat.c: In function 'flat_core_dump':
    > >> fs/binfmt_flat.c:121:50: error: invalid use of undefined type 'struct coredump_params'
    >      121 |                 current->comm, current->pid, cprm->siginfo->si_signo);
    >          |                                                  ^~
    >    include/linux/printk.h:418:33: note: in definition of macro 'printk_index_wrap'
    >      418 |                 _p_func(_fmt, ##__VA_ARGS__);                           \
    >          |                                 ^~~~~~~~~~~
    >    include/linux/printk.h:499:9: note: in expansion of macro 'printk'
    >      499 |         printk(KERN_WARNING pr_fmt(fmt), ##__VA_ARGS__)
    >          |         ^~~~~~
    >    fs/binfmt_flat.c:120:9: note: in expansion of macro 'pr_warn'
    >      120 |         pr_warn("Process %s:%d received s...
    f833116a
binfmt_flat.c 28.6 KB