[PATCH v3 08/13] nds32: Linux ABI
Arnd Bergmann
arnd@arndb.de
Thu Sep 13 12:06:00 GMT 2018
On Thu, Jun 14, 2018 at 9:26 AM Vincent Chen <vincentc@andestech.com> wrote:
> diff --git a/sysdeps/unix/sysv/linux/nds32/sys/procfs.h b/sysdeps/unix/sysv/linux/nds32/sys/procfs.h
> new file mode 100644
> index 0000000..06dce6b
> --- /dev/null
> +++ b/sysdeps/unix/sysv/linux/nds32/sys/procfs.h
....
> +#define ELF_PRARGSZ (80) /* Number of chars for args. */
> +
> +struct elf_prpsinfo
> + {
> + char pr_state; /* Numeric process state. */
> + char pr_sname; /* Char for pr_state. */
> + char pr_zomb; /* Zombie. */
> + char pr_nice; /* Nice val. */
> + unsigned long int pr_flag; /* Flags. */
> + unsigned short int pr_uid;
> + unsigned short int pr_gid;
> + int pr_pid, pr_ppid, pr_pgrp, pr_sid;
> + char pr_fname[16]; /* Filename of executable. */
> + char pr_psargs[ELF_PRARGSZ]; /* Initial part of arg list. */
> + };
I just checked this one and found the same bug that was mentioned in the
csky review thread for a few architectures (not csky):
pr_uid/pr_gid are 'unsigned int' in the kernel, not 'unsigned short int'.
Arnd
More information about the Libc-alpha
mailing list