On 10/22/2012 05:13 PM, Eddie Wai wrote:
>  
> @@ -920,6 +921,28 @@ int iscsi_sysfs_get_sessioninfo_by_id(struct 
> session_info *info, char *session)
>  
>       iscsi_sysfs_read_iface(&info->iface, host_no, session, NULL);
>  
> +     ret = sysfs_get_str(session, ISCSI_SESSION_SUBSYS, "boot_nic",
> +                         boot_nic, NAME_SIZE);
> +     if (!ret) {
> +             /* If boot_nic exist, then extract the info from the boot nic */
> +             ret = sysfs_get_str(boot_nic, ISCSI_IBFT_SUBSYS,
> +                                 "vlan", id, NAME_SIZE);
> +             if (ret)
> +                     log_debug(5, "could not read %s/vlan: %d",
> +                               boot_nic, ret);
> +             else
> +                     info->iface.vlan_id = atoi(id);
> +
> +             ret = sysfs_get_str(boot_nic, ISCSI_IBFT_SUBSYS,
> +                                 "subnet-mask", info->iface.subnet_mask,
> +                                 NI_MAXHOST);
> +             if (ret)
> +                     log_debug(5, "could not read %s/subnet: %d",
> +                               boot_nic, ret);
> +     } else {
> +             log_debug(5, "could not read boot_nic: %d", ret);
> +     }
> +

It seems like this should go in iscsi_sysfs_read_iface.

Why only boot nic? Why don't we also export the boot target and initiator?

-- 
You received this message because you are subscribed to the Google Groups 
"open-iscsi" group.
To post to this group, send email to open-iscsi@googlegroups.com.
To unsubscribe from this group, send email to 
open-iscsi+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/open-iscsi?hl=en.

Reply via email to