aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/sfc/net_driver.h
diff options
context:
space:
mode:
authorBen Hutchings <bhutchings@solarflare.com>2008-09-01 07:43:39 -0400
committerJeff Garzik <jgarzik@redhat.com>2008-09-03 09:53:42 -0400
commit18c2fc0478d5eff08d78bf28635004ec9a9b3946 (patch)
treefd7895fdcf5ede6647c1f2a94c974b729a8e244f /drivers/net/sfc/net_driver.h
parent767e468c06fc0e88f95881c1056437688b37c7c6 (diff)
sfc: Change first parameter type of {set,clear}_bit_le() to unsigned
This means the compiler doesn't need to use real division instructions. Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
Diffstat (limited to 'drivers/net/sfc/net_driver.h')
-rw-r--r--drivers/net/sfc/net_driver.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/sfc/net_driver.h b/drivers/net/sfc/net_driver.h
index 219c74a772c3..ab318f759b81 100644
--- a/drivers/net/sfc/net_driver.h
+++ b/drivers/net/sfc/net_driver.h
@@ -886,13 +886,13 @@ static inline struct efx_rx_buffer *efx_rx_buffer(struct efx_rx_queue *rx_queue,
886} 886}
887 887
888/* Set bit in a little-endian bitfield */ 888/* Set bit in a little-endian bitfield */
889static inline void set_bit_le(int nr, unsigned char *addr) 889static inline void set_bit_le(unsigned nr, unsigned char *addr)
890{ 890{
891 addr[nr / 8] |= (1 << (nr % 8)); 891 addr[nr / 8] |= (1 << (nr % 8));
892} 892}
893 893
894/* Clear bit in a little-endian bitfield */ 894/* Clear bit in a little-endian bitfield */
895static inline void clear_bit_le(int nr, unsigned char *addr) 895static inline void clear_bit_le(unsigned nr, unsigned char *addr)
896{ 896{
897 addr[nr / 8] &= ~(1 << (nr % 8)); 897 addr[nr / 8] &= ~(1 << (nr % 8));
898} 898}