public inbox for libc-alpha@sourceware.org
 help / color / mirror / Atom feed
From: Adhemerval Zanella <adhemerval.zanella@linaro.org>
To: libc-alpha@sourceware.org
Subject: Re: [PATCH] crypt: Use internal names for the SHA-2 block functions
Date: Fri, 28 Oct 2016 13:32:00 -0000	[thread overview]
Message-ID: <a513364d-c2d8-9a68-99e7-8f233ca0b266@linaro.org> (raw)
In-Reply-To: <e9d4595b-01f8-afca-2265-9e2c2ed38d72@redhat.com>



On 28/10/2016 10:57, Florian Weimer wrote:
> I have not been able to test the SPARC bits so far, but they look reasonably safe to me.

> --- a/sysdeps/sparc/sparc64/multiarch/sha256-block.c
> +++ b/sysdeps/sparc/sparc64/multiarch/sha256-block.c
> @@ -1,12 +1,12 @@
>  #include <sparc-ifunc.h>
>  
> -#define sha256_process_block sha256_process_block_generic
> -extern void sha256_process_block_generic (const void *buffer, size_t len,
> -					  struct sha256_ctx *ctx);
> +#define __sha256_process_block __sha256_process_block_generic
> +extern void __sha256_process_block_generic (const void *buffer, size_t len,
> +					    struct sha256_ctx *ctx);
>  
>  #include <crypt/sha256-block.c>
>  
> -#undef sha256_process_block
> +#undef __sha256_process_block
>  
>  extern void __sha256_process_block_crop (const void *buffer, size_t len,
>  					 struct sha256_ctx *ctx);
> @@ -25,6 +25,8 @@ static bool cpu_supports_sha256(int hwcap)
>    return false;
>  }
>  
> -extern void sha256_process_block (const void *buffer, size_t len,
> -				  struct sha256_ctx *ctx);
> -sparc_libc_ifunc(sha256_process_block, cpu_supports_sha256(hwcap) ? __sha256_process_block_crop : sha256_process_block_generic);
> +extern void __sha256_process_block (const void *buffer, size_t len,
> +				    struct sha256_ctx *ctx);
> +sparc_libc_ifunc (__sha256_process_block,
> +		  cpu_supports_sha256(hwcap) ? __sha256_process_block_crop
> +		    : sha256_process_block_generic);

It should __sha256_process_block_generic here.  Also, if we now aiming
for namespace clean shouldn't we also add a conform test for crypt.h
header?

  reply	other threads:[~2016-10-28 13:32 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-10-28 12:57 Florian Weimer
2016-10-28 13:32 ` Adhemerval Zanella [this message]
2016-10-28 17:09   ` Joseph Myers
2016-10-28 17:57     ` Adhemerval Zanella
2016-10-28 18:07       ` Joseph Myers
2016-10-28 20:05   ` Florian Weimer

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=a513364d-c2d8-9a68-99e7-8f233ca0b266@linaro.org \
    --to=adhemerval.zanella@linaro.org \
    --cc=libc-alpha@sourceware.org \
    /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).