From 69a27a5f4a433ae22d00e6195c69b629372b0682 Mon Sep 17 00:00:00 2001 From: Stephen Hemminger Date: Fri, 21 Jun 2019 15:08:24 -0700 Subject: [PATCH] net/failsafe: skip devargs if not present in secondary When secondary process is run was noticing that the log always contained complaints about unable to parse devargs. It turns out that an empty devargs turns into "" and this value is not parsable. Change the failsafe secondary to just skip doing devargs if it empty. Signed-off-by: Stephen Hemminger Acked-by: Gaetan Rivet --- drivers/net/failsafe/failsafe.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/drivers/net/failsafe/failsafe.c b/drivers/net/failsafe/failsafe.c index 19dd71d4e3..8af31d71b3 100644 --- a/drivers/net/failsafe/failsafe.c +++ b/drivers/net/failsafe/failsafe.c @@ -364,6 +364,10 @@ rte_pmd_failsafe_probe(struct rte_vdev_device *vdev) * A sub-device can be plugged later. */ FOREACH_SUBDEV(sdev, i, eth_dev) { + /* skip empty devargs */ + if (sdev->devargs.name[0] == '\0') + continue; + /* rebuild devargs to be able to get the bus name. */ ret = rte_devargs_parse(&devargs, sdev->devargs.name); -- 2.20.1