Skip to content

Commit

Permalink
sparc64: vio: Kill BUILD_BUG_ON() in vio_dring_avail().
Browse files Browse the repository at this point in the history
GCC can't see the 'constant' properly as computed by
is_power_of_2() etc.

Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
David S. Miller committed Sep 18, 2009
1 parent 0a375d7 commit 87ba005
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions arch/sparc/include/asm/vio.h
Original file line number Diff line number Diff line change
Expand Up @@ -258,8 +258,6 @@ static inline void *vio_dring_entry(struct vio_dring_state *dr,
static inline u32 vio_dring_avail(struct vio_dring_state *dr,
unsigned int ring_size)
{
BUILD_BUG_ON(!is_power_of_2(ring_size));

return (dr->pending -
((dr->prod - dr->cons) & (ring_size - 1)));
}
Expand Down

0 comments on commit 87ba005

Please sign in to comment.