diff options
author | Gary Mills <gary_mills@fastmail.fm> | 2016-03-07 08:40:30 -0600 |
---|---|---|
committer | Dan McDonald <danmcd@omniti.com> | 2016-03-14 15:08:03 -0400 |
commit | 8b2aab4fb2ee21a9076eb25068178246a12470b7 (patch) | |
tree | 44c4ad07db45d7e9768c6a3b6279bc2ab379538a | |
parent | a1b1a2a0aac3d3c0533efa646a9d7a7dca91fc7c (diff) | |
download | illumos-joyent-8b2aab4fb2ee21a9076eb25068178246a12470b7.tar.gz |
6436 156 lint errors in common/crypto/edonr/edonr.c
Reviewed by: Gordon Ross <gordon.w.ross@gmail.com>
Reviewed by: Toomas Soome <tsoome@me.com>
Approved by: Dan McDonald <danmcd@omniti.com>
-rw-r--r-- | usr/src/common/crypto/edonr/edonr.c | 6 | ||||
-rw-r--r-- | usr/src/common/crypto/edonr/edonr_byteorder.h | 7 |
2 files changed, 9 insertions, 4 deletions
diff --git a/usr/src/common/crypto/edonr/edonr.c b/usr/src/common/crypto/edonr/edonr.c index afc4361e26..912e8c083f 100644 --- a/usr/src/common/crypto/edonr/edonr.c +++ b/usr/src/common/crypto/edonr/edonr.c @@ -23,10 +23,10 @@ * Copyright (C) 2009, 2010, Jorn Amundsen <jorn.amundsen@ntnu.no> * Tweaked Edon-R implementation for SUPERCOP, based on NIST API. * - * $Id: edonr.c 517 2013-02-17 20:34:39Z joern $ */ /* * Portions copyright (c) 2013, Saso Kiselkov, All rights reserved + * Copyright 2016 Gary Mills */ /* determine where we can get bcopy/bzero declarations */ @@ -659,6 +659,7 @@ EdonRFinal(EdonRState *state, uint8_t *hashval) switch (state->hashbitlen) { case 224: { #if defined(MACHINE_IS_BIG_ENDIAN) + /* LINTED: pointer cast may result in improper alignment */ uint32_t *d32 = (uint32_t *)hashval; uint32_t *s32 = hashState224(state)->DoublePipe + 9; int j; @@ -673,6 +674,7 @@ EdonRFinal(EdonRState *state, uint8_t *hashval) } case 256: { #if defined(MACHINE_IS_BIG_ENDIAN) + /* LINTED: pointer cast may result in improper alignment */ uint32_t *d32 = (uint32_t *)hashval; uint32_t *s32 = hashState224(state)->DoublePipe + 8; int j; @@ -687,6 +689,7 @@ EdonRFinal(EdonRState *state, uint8_t *hashval) } case 384: { #if defined(MACHINE_IS_BIG_ENDIAN) + /* LINTED: pointer cast may result in improper alignment */ uint64_t *d64 = (uint64_t *)hashval; uint64_t *s64 = hashState384(state)->DoublePipe + 10; int j; @@ -701,6 +704,7 @@ EdonRFinal(EdonRState *state, uint8_t *hashval) } case 512: { #if defined(MACHINE_IS_BIG_ENDIAN) + /* LINTED: pointer cast may result in improper alignment */ uint64_t *d64 = (uint64_t *)hashval; uint64_t *s64 = hashState512(state)->DoublePipe + 8; int j; diff --git a/usr/src/common/crypto/edonr/edonr_byteorder.h b/usr/src/common/crypto/edonr/edonr_byteorder.h index 9fdf2b3de4..4ac0bb4be3 100644 --- a/usr/src/common/crypto/edonr/edonr_byteorder.h +++ b/usr/src/common/crypto/edonr/edonr_byteorder.h @@ -25,10 +25,10 @@ * C header file to determine compile machine byte order. Take care when cross * compiling. * - * $Id: byteorder.h 517 2013-02-17 20:34:39Z joern $ */ /* * Portions copyright (c) 2013, Saso Kiselkov, All rights reserved + * Copyright 2016 Gary Mills */ #ifndef _CRYPTO_EDONR_BYTEORDER_H @@ -134,8 +134,9 @@ #if !defined(__arch64__) && !defined(__sparcv8) && defined(__sparcv9) #define __arch64__ #endif -#if defined(__GNUC__) || (defined(__SUNPRO_C) && __SUNPRO_C > 0x590) -/* need Sun Studio C 5.10 and above for GNU inline assembly */ +#if defined(__GNUC__) || (defined(__SUNPRO_C) && __SUNPRO_C > 0x590 && \ + !defined(__lint)) +/* need Sun Studio C 5.10 and above for GNU inline assembly, but not lint */ #if defined(__arch64__) #define sparc_ld_swap64(s64, d64) \ __asm__("ldxa [%1]0x88,%0" : "=r"(d64) : "r"(s64)) |