public inbox for libc-alpha@sourceware.org
 help / color / mirror / Atom feed
From: Florian Weimer <fw@deneb.enyo.de>
To: "Maciej W. Rozycki" <macro@mips.com>
Cc: <libc-alpha@sourceware.org>,  Alan Modra <amodra@gmail.com>
Subject: Re: [PATCH 1/2] elf: Accept absolute (SHN_ABS) symbols whose value is zero [BZ #23307]
Date: Mon, 25 Jun 2018 20:25:00 -0000	[thread overview]
Message-ID: <87woum3977.fsf@mid.deneb.enyo.de> (raw)
In-Reply-To: <alpine.DEB.2.00.1806181716230.20622@tp.orcam.me.uk> (Maciej W. Rozycki's message of "Mon, 18 Jun 2018 19:07:03 +0100")

* Maciej W. Rozycki:

> --- glibc.orig/elf/dl-lookup.c	2018-06-17 09:06:30.202407070 +0100
> +++ glibc/elf/dl-lookup.c	2018-06-18 18:12:36.138114433 +0100
> @@ -76,6 +76,7 @@ check_match (const char *const undef_nam
>    unsigned int stt = ELFW(ST_TYPE) (sym->st_info);
>    assert (ELF_RTYPE_CLASS_PLT == 1);
>    if (__glibc_unlikely ((sym->st_value == 0 /* No value.  */
> +			 && sym->st_shndx != SHN_ABS
>  			 && stt != STT_TLS)
>  			|| ELF_MACHINE_SYM_NO_MATCH (sym)
>  			|| (type_class & (sym->st_shndx == SHN_UNDEF))))

Context here:

  unsigned int stt = ELFW(ST_TYPE) (sym->st_info);
  assert (ELF_RTYPE_CLASS_PLT == 1);
  if (__glibc_unlikely ((sym->st_value == 0 /* No value.  */
			 && stt != STT_TLS)
			|| ELF_MACHINE_SYM_NO_MATCH (sym)
			|| (type_class & (sym->st_shndx == SHN_UNDEF))))
    return NULL;

So this looks good.

> Index: glibc/elf/tst-absolute-zero-lib.c
> ===================================================================
> --- /dev/null	1970-01-01 00:00:00.000000000 +0000
> +++ glibc/elf/tst-absolute-zero-lib.c	2018-06-18 18:12:40.102324540 +0100
> @@ -0,0 +1,25 @@
> +/* BZ #xxxxx absolute zero symbol calculation shared module.

Needs Bugzilla number.

> Index: glibc/elf/tst-absolute-zero.c
> ===================================================================
> --- /dev/null	1970-01-01 00:00:00.000000000 +0000
> +++ glibc/elf/tst-absolute-zero.c	2018-06-18 18:12:40.147611912 +0100
> @@ -0,0 +1,38 @@
> +/* BZ #xxxxx absolute zero symbol calculation main executable.

Likewise.

  reply	other threads:[~2018-06-25 20:25 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-06-18 18:06 [PATCH 0/2] Accept absolute " Maciej W. Rozycki
2018-06-18 18:08 ` [PATCH 1/2] elf: Accept absolute (SHN_ABS) " Maciej W. Rozycki
2018-06-25 20:25   ` Florian Weimer [this message]
2018-06-29 16:13     ` [committed v2 " Maciej W. Rozycki
2018-06-29 17:41       ` Joseph Myers
2018-06-29 18:05         ` Maciej W. Rozycki
2018-06-18 18:08 ` [PATCH 2/2] libc-abis: Define ABSOLUTE ABI [BZ #19818][BZ #23307] Maciej W. Rozycki
2018-06-25 20:33   ` Florian Weimer
2018-06-27 22:08     ` Maciej W. Rozycki
2018-06-28  6:59       ` Florian Weimer
2018-06-28 13:49         ` Maciej W. Rozycki
2018-06-28 13:54           ` Florian Weimer
2018-06-28 14:54             ` Maciej W. Rozycki
2018-06-29 16:29               ` Maciej W. Rozycki
2018-07-03 13:53                 ` Carlos O'Donell
2018-07-05 15:42                   ` [PATCH v2 " Maciej W. Rozycki
2018-07-05 16:29                     ` Carlos O'Donell
2018-07-05 17:10                       ` Maciej W. Rozycki
2018-07-05 18:02                         ` Carlos O'Donell
2018-06-25 19:14 ` [PING][PATCH 0/2] Accept absolute symbols whose value is zero [BZ #23307] Maciej W. Rozycki

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=87woum3977.fsf@mid.deneb.enyo.de \
    --to=fw@deneb.enyo.de \
    --cc=amodra@gmail.com \
    --cc=libc-alpha@sourceware.org \
    --cc=macro@mips.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).