Skip to contentSkip to conversation

9pfs: make pdu_marshal() and pdu_unmarshal() static functions

PATCH In review Greg Kurz 2 participants 2 messages Dec 15, 2017 – Dec 20, 2017

lore
Share & tools
lore

Greg Kurz

author
#0 lore raw

PATCH 1/1 9pfs: make pdu_marshal() and pdu_unmarshal() static functions

They're only used by the 9p core code.

---
 hw/9pfs/9p.c |    4 ++--
 hw/9pfs/9p.h |    2 --
 2 files changed, 2 insertions(+), 4 deletions(-)
hw/9pfs/9p.c +2 -2
index 558efb41defd..1e4ebbe57687 100644
@@ -41,7 +41,7 @@ enum {
     Oappend = 0x80,
 };
 
-ssize_t pdu_marshal(V9fsPDU *pdu, size_t offset, const char *fmt, ...)
+static ssize_t pdu_marshal(V9fsPDU *pdu, size_t offset, const char *fmt, ...)
 {
     ssize_t ret;
     va_list ap;
@@ -53,7 +53,7 @@ ssize_t pdu_marshal(V9fsPDU *pdu, size_t offset, const char *fmt, ...)
     return ret;
 }
 
-ssize_t pdu_unmarshal(V9fsPDU *pdu, size_t offset, const char *fmt, ...)
+static ssize_t pdu_unmarshal(V9fsPDU *pdu, size_t offset, const char *fmt, ...)
 {
     ssize_t ret;
     va_list ap;
hw/9pfs/9p.h +0 -2
index 6e3b48391788..ffe658ab8975 100644
@@ -349,8 +349,6 @@ int v9fs_name_to_path(V9fsState *s, V9fsPath *dirpath,
 int v9fs_device_realize_common(V9fsState *s, Error **errp);
 void v9fs_device_unrealize_common(V9fsState *s, Error **errp);
 
-ssize_t pdu_marshal(V9fsPDU *pdu, size_t offset, const char *fmt, ...);
-ssize_t pdu_unmarshal(V9fsPDU *pdu, size_t offset, const char *fmt, ...);
 V9fsPDU *pdu_alloc(V9fsState *s);
 void pdu_free(V9fsPDU *pdu);
 void pdu_submit(V9fsPDU *pdu, P9MsgHeader *hdr);
Reviewed-by on v1 1/1
#1 lore raw
Quoted 7 lines · Greg Kurz

They're only used by the 9p core code.

---
  hw/9pfs/9p.c |    4 ++--
  hw/9pfs/9p.h |    2 --
  2 files changed, 2 insertions(+), 4 deletions(-)
Signature · 3 lines
Eric Blake, Principal Software Engineer
Red Hat, Inc.           +1-919-301-3266
Virtualization:  qemu.org | libvirt.org