Skip to content

Commit

Permalink
[IA64] unwind: remove preprocesser noise, and correct comment
Browse files Browse the repository at this point in the history
The expression in the comment was mis-bracketted.
There was also no need to introduce a coding-style breaking
macro for a single use, so just made it a static const.

Signed-off-by: Phil Carmody <ext-phil.2.carmody@nokia.com>
Signed-off-by: Tony Luck <tony.luck@intel.com>
  • Loading branch information
Phil Carmody authored and Tony Luck committed Sep 14, 2010
1 parent bfa88ea commit 747584b
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions arch/ia64/kernel/unwind.c
Original file line number Diff line number Diff line change
Expand Up @@ -1204,10 +1204,10 @@ desc_spill_sprel_p (unsigned char qp, unw_word t, unsigned char abreg, unw_word
static inline unw_hash_index_t
hash (unsigned long ip)
{
# define hashmagic 0x9e3779b97f4a7c16UL /* based on (sqrt(5)/2-1)*2^64 */
/* magic number = ((sqrt(5)-1)/2)*2^64 */
static const unsigned long hashmagic = 0x9e3779b97f4a7c16UL;

return (ip >> 4)*hashmagic >> (64 - UNW_LOG_HASH_SIZE);
#undef hashmagic
return (ip >> 4) * hashmagic >> (64 - UNW_LOG_HASH_SIZE);
}

static inline long
Expand Down

0 comments on commit 747584b

Please sign in to comment.