* [PATCH] net: hamradio: remove unused hweight*() defines
@ 2019-02-18 6:35 Masahiro Yamada
2019-02-18 20:10 ` David Miller
0 siblings, 1 reply; 2+ messages in thread
From: Masahiro Yamada @ 2019-02-18 6:35 UTC (permalink / raw)
To: David S . Miller, netdev
Cc: Masahiro Yamada, linux-hams, Thomas Sailer, linux-kernel
This file does not use hweight*() at all, and the definition is
surrounded by #if 0 ... #endif.
Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
---
drivers/net/hamradio/baycom_ser_fdx.c | 26 --------------------------
1 file changed, 26 deletions(-)
diff --git a/drivers/net/hamradio/baycom_ser_fdx.c b/drivers/net/hamradio/baycom_ser_fdx.c
index 190f66c..ed08416 100644
--- a/drivers/net/hamradio/baycom_ser_fdx.c
+++ b/drivers/net/hamradio/baycom_ser_fdx.c
@@ -203,32 +203,6 @@ static inline void ser12_set_divisor(struct net_device *dev,
*/
}
-/* --------------------------------------------------------------------- */
-
-#if 0
-static inline unsigned int hweight16(unsigned int w)
- __attribute__ ((unused));
-static inline unsigned int hweight8(unsigned int w)
- __attribute__ ((unused));
-
-static inline unsigned int hweight16(unsigned int w)
-{
- unsigned short res = (w & 0x5555) + ((w >> 1) & 0x5555);
- res = (res & 0x3333) + ((res >> 2) & 0x3333);
- res = (res & 0x0F0F) + ((res >> 4) & 0x0F0F);
- return (res & 0x00FF) + ((res >> 8) & 0x00FF);
-}
-
-static inline unsigned int hweight8(unsigned int w)
-{
- unsigned short res = (w & 0x55) + ((w >> 1) & 0x55);
- res = (res & 0x33) + ((res >> 2) & 0x33);
- return (res & 0x0F) + ((res >> 4) & 0x0F);
-}
-#endif
-
-/* --------------------------------------------------------------------- */
-
static __inline__ void ser12_rx(struct net_device *dev, struct baycom_state *bc, struct timespec64 *ts, unsigned char curs)
{
int timediff;
--
2.7.4
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] net: hamradio: remove unused hweight*() defines
2019-02-18 6:35 [PATCH] net: hamradio: remove unused hweight*() defines Masahiro Yamada
@ 2019-02-18 20:10 ` David Miller
0 siblings, 0 replies; 2+ messages in thread
From: David Miller @ 2019-02-18 20:10 UTC (permalink / raw)
To: yamada.masahiro; +Cc: netdev, linux-hams, t.sailer, linux-kernel
From: Masahiro Yamada <yamada.masahiro@socionext.com>
Date: Mon, 18 Feb 2019 15:35:25 +0900
> This file does not use hweight*() at all, and the definition is
> surrounded by #if 0 ... #endif.
>
> Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Applied to net-next, thanks.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2019-02-18 20:10 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-02-18 6:35 [PATCH] net: hamradio: remove unused hweight*() defines Masahiro Yamada
2019-02-18 20:10 ` David Miller
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.