[v5,3/5] GLIBC_PRIVATE: Export __clone_internal

Message ID 20210515123442.1432385-4-hjl.tools@gmail.com
State New
Headers show
Series
  • Add an internal wrapper for clone, clone2 and clone3
Related show

Commit Message

naohirot--- via Libc-alpha May 15, 2021, 12:34 p.m.
Export __clone_internal for libpthread.so and __clone_internal tests.
---
 sysdeps/unix/sysv/linux/Versions | 1 +
 1 file changed, 1 insertion(+)

-- 
2.31.1

Comments

Andreas Schwab May 17, 2021, 1:54 p.m. | #1
On Mai 15 2021, H.J. Lu via Libc-alpha wrote:

> diff --git a/sysdeps/unix/sysv/linux/Versions b/sysdeps/unix/sysv/linux/Versions

> index 220bb2dffe..299d4fef9c 100644

> --- a/sysdeps/unix/sysv/linux/Versions

> +++ b/sysdeps/unix/sysv/linux/Versions

> @@ -179,6 +179,7 @@ libc {

>      __sigtimedwait;

>      # functions used by nscd

>      __netlink_assert_response;

> +    __clone_internal;


The comment doesn't fit here.

Andreas.

-- 
Andreas Schwab, schwab@linux-m68k.org
GPG Key fingerprint = 7578 EB47 D4E5 4D69 2510  2552 DF73 E780 A9DA AEC1
"And now for something completely different."
naohirot--- via Libc-alpha May 20, 2021, 2:24 p.m. | #2
* H. J. Lu:

> Export __clone_internal for libpthread.so and __clone_internal tests.

> ---

>  sysdeps/unix/sysv/linux/Versions | 1 +

>  1 file changed, 1 insertion(+)

>

> diff --git a/sysdeps/unix/sysv/linux/Versions b/sysdeps/unix/sysv/linux/Versions

> index 220bb2dffe..299d4fef9c 100644

> --- a/sysdeps/unix/sysv/linux/Versions

> +++ b/sysdeps/unix/sysv/linux/Versions

> @@ -179,6 +179,7 @@ libc {

>      __sigtimedwait;

>      # functions used by nscd

>      __netlink_assert_response;

> +    __clone_internal;

>    }

>  }


I think this won't be necessary after the libpthread move.

We can test the function directly by linking statically.  We already do
this in a few other cases.

Thanks,
Florian
naohirot--- via Libc-alpha May 22, 2021, 1:55 a.m. | #3
On Thu, May 20, 2021 at 7:24 AM Florian Weimer <fweimer@redhat.com> wrote:
>

> * H. J. Lu:

>

> > Export __clone_internal for libpthread.so and __clone_internal tests.

> > ---

> >  sysdeps/unix/sysv/linux/Versions | 1 +

> >  1 file changed, 1 insertion(+)

> >

> > diff --git a/sysdeps/unix/sysv/linux/Versions b/sysdeps/unix/sysv/linux/Versions

> > index 220bb2dffe..299d4fef9c 100644

> > --- a/sysdeps/unix/sysv/linux/Versions

> > +++ b/sysdeps/unix/sysv/linux/Versions

> > @@ -179,6 +179,7 @@ libc {

> >      __sigtimedwait;

> >      # functions used by nscd

> >      __netlink_assert_response;

> > +    __clone_internal;

> >    }

> >  }

>

> I think this won't be necessary after the libpthread move.


This patch has been dropped.

> We can test the function directly by linking statically.  We already do

> this in a few other cases.


That is in the v6 patch.

Thanks.

-- 
H.J.

Patch

diff --git a/sysdeps/unix/sysv/linux/Versions b/sysdeps/unix/sysv/linux/Versions
index 220bb2dffe..299d4fef9c 100644
--- a/sysdeps/unix/sysv/linux/Versions
+++ b/sysdeps/unix/sysv/linux/Versions
@@ -179,6 +179,7 @@  libc {
     __sigtimedwait;
     # functions used by nscd
     __netlink_assert_response;
+    __clone_internal;
   }
 }