netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] af_packet: fix warnings due to mismatched prototypes
@ 2011-11-02 20:34 Olof Johansson
  2011-11-02 20:36 ` David Miller
  0 siblings, 1 reply; 4+ messages in thread
From: Olof Johansson @ 2011-11-02 20:34 UTC (permalink / raw)
  To: davem; +Cc: netdev, Olof Johansson, Chetan Loke

Trivial prototype mismatch fixes:

net/packet/af_packet.c:252: warning: 'prb_curr_blk_in_use' declared inline after being called
net/packet/af_packet.c:252: warning: previous declaration of 'prb_curr_blk_in_use' was here
net/packet/af_packet.c:258: warning: 'prb_queue_frozen' declared inline after being called
net/packet/af_packet.c:258: warning: previous declaration of 'prb_queue_frozen' was here
net/packet/af_packet.c:248: warning: 'packet_previous_frame' declared inline after being called
net/packet/af_packet.c:248: warning: previous declaration of 'packet_previous_frame' was here
net/packet/af_packet.c:251: warning: 'packet_increment_head' declared inline after being called
net/packet/af_packet.c:251: warning: previous declaration of 'packet_increment_head' was here

Signed-off-by: Olof Johansson <olof@lixom.net>
Cc: Chetan Loke <loke.chetan@gmail.com>
---

Dave, let me know if you prefer to shuffle code around and move the
inline helpers to the top instead -- I went with the smaller change by
default.


 net/packet/af_packet.c |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/net/packet/af_packet.c b/net/packet/af_packet.c
index 03bb45a..9f4de7c 100644
--- a/net/packet/af_packet.c
+++ b/net/packet/af_packet.c
@@ -245,17 +245,17 @@ struct packet_ring_buffer {
 struct packet_sock;
 static int tpacket_snd(struct packet_sock *po, struct msghdr *msg);
 
-static void *packet_previous_frame(struct packet_sock *po,
+static inline void *packet_previous_frame(struct packet_sock *po,
 		struct packet_ring_buffer *rb,
 		int status);
-static void packet_increment_head(struct packet_ring_buffer *buff);
-static int prb_curr_blk_in_use(struct tpacket_kbdq_core *,
+static inline void packet_increment_head(struct packet_ring_buffer *buff);
+static inline int prb_curr_blk_in_use(struct tpacket_kbdq_core *,
 			struct tpacket_block_desc *);
 static void *prb_dispatch_next_block(struct tpacket_kbdq_core *,
 			struct packet_sock *);
 static void prb_retire_current_block(struct tpacket_kbdq_core *,
 		struct packet_sock *, unsigned int status);
-static int prb_queue_frozen(struct tpacket_kbdq_core *);
+static inline int prb_queue_frozen(struct tpacket_kbdq_core *);
 static void prb_open_block(struct tpacket_kbdq_core *,
 		struct tpacket_block_desc *);
 static void prb_retire_rx_blk_timer_expired(unsigned long);
-- 
1.7.4.1

^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2011-11-03 22:12 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-11-02 20:34 [PATCH] af_packet: fix warnings due to mismatched prototypes Olof Johansson
2011-11-02 20:36 ` David Miller
2011-11-02 21:00   ` [PATCH] af_packet: de-inline some helper functions Olof Johansson
2011-11-03 22:12     ` 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).