* [PATCH net-next] net: am79c961a: Omit check for multicast bit in netdev_for_each_mc_addr
@ 2011-06-29 12:14 Tobias Klauser
2011-06-30 9:23 ` Russell King - ARM Linux
2011-07-01 6:56 ` David Miller
0 siblings, 2 replies; 3+ messages in thread
From: Tobias Klauser @ 2011-06-29 12:14 UTC (permalink / raw)
To: linux-arm-kernel
There is no need to check for the address being a multicast address in
the netdev_for_each_mc_addr loop, so remove it.
Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
---
drivers/net/arm/am79c961a.c | 14 ++++++--------
1 files changed, 6 insertions(+), 8 deletions(-)
diff --git a/drivers/net/arm/am79c961a.c b/drivers/net/arm/am79c961a.c
index 7b3e23f..52fe21e 100644
--- a/drivers/net/arm/am79c961a.c
+++ b/drivers/net/arm/am79c961a.c
@@ -199,17 +199,15 @@ am79c961_ramtest(struct net_device *dev, unsigned int val)
static void am79c961_mc_hash(char *addr, u16 *hash)
{
- if (addr[0] & 0x01) {
- int idx, bit;
- u32 crc;
+ int idx, bit;
+ u32 crc;
- crc = ether_crc_le(ETH_ALEN, addr);
+ crc = ether_crc_le(ETH_ALEN, addr);
- idx = crc >> 30;
- bit = (crc >> 26) & 15;
+ idx = crc >> 30;
+ bit = (crc >> 26) & 15;
- hash[idx] |= 1 << bit;
- }
+ hash[idx] |= 1 << bit;
}
static unsigned int am79c961_get_rx_mode(struct net_device *dev, u16 *hash)
--
1.7.5.4
^ permalink raw reply related [flat|nested] 3+ messages in thread* [PATCH net-next] net: am79c961a: Omit check for multicast bit in netdev_for_each_mc_addr
2011-06-29 12:14 [PATCH net-next] net: am79c961a: Omit check for multicast bit in netdev_for_each_mc_addr Tobias Klauser
@ 2011-06-30 9:23 ` Russell King - ARM Linux
2011-07-01 6:56 ` David Miller
1 sibling, 0 replies; 3+ messages in thread
From: Russell King - ARM Linux @ 2011-06-30 9:23 UTC (permalink / raw)
To: linux-arm-kernel
On Wed, Jun 29, 2011 at 02:14:46PM +0200, Tobias Klauser wrote:
> There is no need to check for the address being a multicast address in
> the netdev_for_each_mc_addr loop, so remove it.
>
> Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
Thanks.
Acked-by: Russell King <rmk+kernel@arm.linux.org.uk>
> ---
> drivers/net/arm/am79c961a.c | 14 ++++++--------
> 1 files changed, 6 insertions(+), 8 deletions(-)
>
> diff --git a/drivers/net/arm/am79c961a.c b/drivers/net/arm/am79c961a.c
> index 7b3e23f..52fe21e 100644
> --- a/drivers/net/arm/am79c961a.c
> +++ b/drivers/net/arm/am79c961a.c
> @@ -199,17 +199,15 @@ am79c961_ramtest(struct net_device *dev, unsigned int val)
>
> static void am79c961_mc_hash(char *addr, u16 *hash)
> {
> - if (addr[0] & 0x01) {
> - int idx, bit;
> - u32 crc;
> + int idx, bit;
> + u32 crc;
>
> - crc = ether_crc_le(ETH_ALEN, addr);
> + crc = ether_crc_le(ETH_ALEN, addr);
>
> - idx = crc >> 30;
> - bit = (crc >> 26) & 15;
> + idx = crc >> 30;
> + bit = (crc >> 26) & 15;
>
> - hash[idx] |= 1 << bit;
> - }
> + hash[idx] |= 1 << bit;
> }
>
> static unsigned int am79c961_get_rx_mode(struct net_device *dev, u16 *hash)
> --
> 1.7.5.4
>
>
> _______________________________________________
> linux-arm-kernel mailing list
> linux-arm-kernel at lists.infradead.org
> http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
^ permalink raw reply [flat|nested] 3+ messages in thread* [PATCH net-next] net: am79c961a: Omit check for multicast bit in netdev_for_each_mc_addr
2011-06-29 12:14 [PATCH net-next] net: am79c961a: Omit check for multicast bit in netdev_for_each_mc_addr Tobias Klauser
2011-06-30 9:23 ` Russell King - ARM Linux
@ 2011-07-01 6:56 ` David Miller
1 sibling, 0 replies; 3+ messages in thread
From: David Miller @ 2011-07-01 6:56 UTC (permalink / raw)
To: linux-arm-kernel
From: Tobias Klauser <tklauser@distanz.ch>
Date: Wed, 29 Jun 2011 14:14:46 +0200
> There is no need to check for the address being a multicast address in
> the netdev_for_each_mc_addr loop, so remove it.
>
> Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
Applied.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2011-07-01 6:56 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-06-29 12:14 [PATCH net-next] net: am79c961a: Omit check for multicast bit in netdev_for_each_mc_addr Tobias Klauser
2011-06-30 9:23 ` Russell King - ARM Linux
2011-07-01 6:56 ` David Miller
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 NNTP newsgroup(s).