This patch allows plug-ins to access output format enums and
its helper by moving the enum definition and helper declaration
to the header file.
Signed-off-by: Chaitanya Kulkarni <chaitanya.kulkarni@hgst.com>
static const char *output_format = "Output format: normal|json|binary";
-enum {
- NORMAL,
- JSON,
- BINARY,
-};
-
-static int validate_output_format(char *format)
+int validate_output_format(char *format)
{
if (!format)
return -EINVAL;
unsigned block;
};
+enum {
+ NORMAL,
+ JSON,
+ BINARY,
+};
+
void register_extension(struct plugin *plugin);
#include "argconfig.h"
extern const char *devicename;
int __id_ctrl(int argc, char **argv, struct command *cmd, struct plugin *plugin, void (*vs)(__u8 *vs, struct json_object *root));
+int validate_output_format(char *format);
#endif /* _NVME_H */