Fix error message as currently error message doesn't
have enough details which could suggest that -s failed due
to fcoe stack not loaded. Currently error message is:-

Starting FCoE on interface eth1.228
fipvlan: fcoe_instance_start: error 2 No such file or directory
fipvlan: fcoe_instance_start: failed to open fcoe create file
Starting FCoE on interface eth2.172
fipvlan: fcoe_instance_start: error 2 No such file or directory
fipvlan: fcoe_instance_start: failed to open fcoe create file
Starting FCoE on interface eth3.216
fipvlan: fcoe_instance_start: error 2 No such file or directory
fipvlan: fcoe_instance_start: failed to open fcoe create file
Starting FCoE on interface eth4.228
fipvlan: fcoe_instance_start: error 2 No such file or directory
fipvlan: fcoe_instance_start: failed to open fcoe create file

Signed-off-by: Vasu Dev <[email protected]>
Tested-by: Ross Brattain <[email protected]>
---

 fipvlan.c |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)

diff --git a/fipvlan.c b/fipvlan.c
index 35de2c3..74d69cb 100644
--- a/fipvlan.c
+++ b/fipvlan.c
@@ -544,7 +544,9 @@ int fcoe_instance_start(char *ifname)
        FIP_LOG_DBG("%s on %s\n", __func__, ifname);
        fd = open(SYSFS_FCOE "/create", O_WRONLY);
        if (fd < 0) {
-               FIP_LOG_ERRNO("failed to open fcoe create file");
+               FIP_LOG_ERRNO("Failed to open file:%s", SYSFS_FCOE "/create");
+               FIP_LOG_ERRNO("May be fcoe stack not loaded, starting"
+                              " fcoe service will fix that");
                return fd;
        }
        rc = write(fd, ifname, strlen(ifname));

_______________________________________________
devel mailing list
[email protected]
https://lists.open-fcoe.org/mailman/listinfo/devel

Reply via email to