public inbox for libc-alpha@sourceware.org
 help / color / mirror / Atom feed
From: Steve Ellcey <sellcey@imgtec.com>
To: GNU C Library <libc-alpha@sourceware.org>
Cc: Roland McGrath <roland@hack.frob.com>
Subject: [PATCH] Fix missing err declaration in __pthread_initialize_minimal_internal
Date: Fri, 22 May 2015 17:18:00 -0000	[thread overview]
Message-ID: <1432312942.16668.92.camel@ubuntu-sellcey> (raw)

Roland's patch (https://sourceware.org/ml/libc-alpha/2015-05/msg00464.html)
to set tid field to a unique value removed the declaration of err
[INTERNAL_SYSCALL_DECL (err);] from __pthread_initialize_minimal_internal,
but there are other uses of err in other INTERNAL_SYSCALL's in
__pthread_initialize_minimal_internal so this broke the build glibc build
for MIPS (and presumably other platforms).

Here is a patch to put the declaration back.  I think the only question
is exactly where this declaration should go.   I initially put it right
in front of the first INTERNAL_SYSCALL call but I noticed that that is inside
of an ifdef and there are other INTERNAL_SYSCALL uses (with err) that
are in different ifdef's so I moved the declaration outside of any ifdef's.
This fixed my build problem.  OK to checkin?

Steve Ellcey
sellcey@imgtec.com



2015-05-22  Steve Ellcey  <sellcey@imgtec.com>

	* nptl/nptl-init.c (__pthread_initialize_minimal_internal):
	Add declaration of err that was removed in earlier patch.



diff --git a/nptl/nptl-init.c b/nptl/nptl-init.c
index 5b8d931..3bfb478 100644
--- a/nptl/nptl-init.c
+++ b/nptl/nptl-init.c
@@ -326,6 +326,7 @@ __pthread_initialize_minimal_internal (void)
   pd->robust_prev = &pd->robust_head;
 #endif
   pd->robust_head.list = &pd->robust_head;
+  INTERNAL_SYSCALL_DECL (err);
 #ifdef __NR_set_robust_list
   pd->robust_head.futex_offset = (offsetof (pthread_mutex_t, __data.__lock)
 				  - offsetof (pthread_mutex_t,


             reply	other threads:[~2015-05-22 16:42 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-05-22 17:18 Steve Ellcey [this message]
2015-05-24 15:07 ` Carlos O'Donell
2015-05-25 11:46   ` Khem Raj
2015-05-26 17:18   ` Steve Ellcey
2015-05-26 18:25     ` Carlos O'Donell

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1432312942.16668.92.camel@ubuntu-sellcey \
    --to=sellcey@imgtec.com \
    --cc=libc-alpha@sourceware.org \
    --cc=roland@hack.frob.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).