Skip to contentSkip to conversation

ceph: include linux/crush/mapper.h in crush/mapper.c

PATCH Applied Tobias Klauser 2 participants 2 messages Oct 28, 2016 – Nov 7, 2016 Ceph common code (libceph)

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 ceph: include linux/crush/mapper.h in crush/mapper.c

Include linux/crush/mapper.h in crush/mapper.c to get the prototypes of crush_find_rule and crush_do_rule which are defined there. This fixes the following GCC warnings when building with 'W=1':

net/ceph/crush/mapper.c:40:5: warning: no previous prototype for ‘crush_find_rule’ [-Wmissing-prototypes] net/ceph/crush/mapper.c:793:5: warning: no previous prototype for ‘crush_do_rule’ [-Wmissing-prototypes]

---
 net/ceph/crush/mapper.c | 1 +
 1 file changed, 1 insertion(+)
net/ceph/crush/mapper.c +1 -0
index a421e905331a..407bd146ba9e 100644
@@ -17,6 +17,7 @@
 # include <linux/kernel.h>
 # include <linux/crush/crush.h>
 # include <linux/crush/hash.h>
+# include <linux/crush/mapper.h>
 #else
 # include "crush_compat.h"
 # include "crush.h"
Signature · 1 line
2.9.0
maintainer Applied
#1 lore raw
Quoted 17 lines · Tobias Klauser

Include linux/crush/mapper.h in crush/mapper.c to get the prototypes of crush_find_rule and crush_do_rule which are defined there. This fixes the following GCC warnings when building with 'W=1':

net/ceph/crush/mapper.c:40:5: warning: no previous prototype for ‘crush_find_rule’ [-Wmissing-prototypes] net/ceph/crush/mapper.c:793:5: warning: no previous prototype for ‘crush_do_rule’ [-Wmissing-prototypes]

---
 net/ceph/crush/mapper.c | 1 +
 1 file changed, 1 insertion(+)
net/ceph/crush/mapper.c +0 -0
index a421e905331a..407bd146ba9e 100644

net/ceph/crush/mapper.c line 23

Quoted 7 lines
net/ceph/crush/mapper.c +1 -0
@@ -17,6 +17,7 @@
 # include <linux/kernel.h>
 # include <linux/crush/crush.h>
 # include <linux/crush/hash.h>
+# include <linux/crush/mapper.h>
 #else
 # include "crush_compat.h"
 # include "crush.h"

Applied.

Thanks,

Ilya