[LTP] [PATCH v2] Add test case to cover the setting resource limit64 for process

Petr Vorel pvorel@suse.cz
Thu Feb 20 10:35:00 CET 2025


Hi Li, Chunfu Wen,
...
> > > +static int setrlimit_u64(int resource, const struct rlimit64 *rlim)
> > > +{
> > > +        return tst_syscall(__NR_prlimit64, 0, resource, rlim, NULL);
> > I suppose using raw syscall is really needed, right?

> Yes, using the raw syscall for prlimit64 is necessary in this case.

> From what I know, Chufu is working oin an environment where glibc's
> wrapper might interfere, using tst_syscall(__NR_prlimit64, ...) ensures
> that the raw syscall is executed without relying on glibc behavior.

Li, thanks for info.

> @chuwen, this new case is quite similar to setrlimit06.c, maybe we
> can combine into one and use .test_variants to traverse all syscalls.
> e.g. syscalls/stime/stime_var.h.

+1

Kind regards,
Petr


More information about the ltp mailing list