[POWERPC] spufs: Don't return -ENOSYS as extra notes size if spufs is not loaded
[POWERPC] spufs: Don't return -ENOSYS as extra notes size if spufs is not loaded

Because the SPU coredump code might be built as part of a module (spufs),
we have a stub which is called by the coredump code, this routine then calls
into spufs if it's loaded.

Unfortunately the stub returns -ENOSYS if spufs is not loaded, which is
interpreted by the coredump code as an extra note size of -38 bytes. This
leads to a corrupt core dump.

If spufs is not loaded there will be no SPU ELF notes to write, and so the
extra notes size will be == 0.

Signed-off-by: Michael Ellerman <17b9e1c64588c7fa6419b4d29dc1f4426279ba01@ellerman.id.au>
Signed-off-by: Jeremy Kerr <68a658b44bbaefab3ef5cd231967195fc0ff9d69@ozlabs.org>
Acked-by: Arnd Bergmann <31ce0e01d6a887319e98c2278af71350d5f64c4f@de.ibm.com>
Signed-off-by: Paul Mackerras <19a0ba370c443ba08d20b5061586430ab449ee8c@samba.org>

TeamVee-Kanas/android_kernel_samsung_kanas,KristFoundation/Programs,TeamVee-Kanas/android_kernel_samsung_kanas,KristFoundation/Programs,TeamVee-Kanas/android_kernel_samsung_kanas,KristFoundation/Programs,KristFoundation/Programs,KristFoundation/Programs,KristFoundation/Programs,TeamVee-Kanas/android_kernel_samsung_kanas,TeamVee-Kanas/android_kernel_samsung_kanas