From 7d9fbd2b5864049b9efc4d99cbce80019b704ea6 Mon Sep 17 00:00:00 2001 From: Mike Christie Date: Wed, 25 Jul 2007 19:23:24 -0500 Subject: Finish hooking into tool Instead of having each parser print its output, make it common in fw_entry.c and make that use the same format and fields as the rest of the tools. Kept the ibft dump code, because it may be use for compat tools for suse. Let me know and I can help on that if you need it. With the hook in though the format for ibft is the same as normal iscsiadm node info so you can just reuse your parsing login for that. --- include/fw_context.h | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'include') diff --git a/include/fw_context.h b/include/fw_context.h index 4307509..47ac6ae 100644 --- a/include/fw_context.h +++ b/include/fw_context.h @@ -22,7 +22,7 @@ #define FWPARAM_CONTEXT_H_ struct boot_context { -#define IQNSZ (223) +#define IQNSZ (223+1) int target_port; char initiatorname[IQNSZ]; char targetname[IQNSZ]; @@ -31,16 +31,16 @@ struct boot_context { char chap_password[16]; char chap_name_in[127]; char chap_password_in[16]; - char mac[16]; char iface[42]; + char mac[18]; + char ipaddr[18]; + char mask[18]; char lun[17]; char vlan[15]; char isid[10]; }; -int fw_entry_init(struct boot_context *context, int option); - -#define FW_CONNECT 0 -#define FW_PRINT 1 +extern int fw_get_entry(struct boot_context *context, const char *filepath); +extern void fw_print_entry(struct boot_context *context); #endif /* FWPARAM_CONTEXT_H_ */ -- cgit v1.2.1