[libvirt] [PATCH 1/4] virWaitForDevices: Drop untrue part of comment

Michal Privoznik posted 4 patches 6 years, 8 months ago
[libvirt] [PATCH 1/4] virWaitForDevices: Drop untrue part of comment
Posted by Michal Privoznik 6 years, 8 months ago
It's not true that there is a backup loop. There isn't. Drop this
part of the comment to not confuse anybody.

Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
---
 src/util/virutil.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/src/util/virutil.c b/src/util/virutil.c
index e5917d33de..6123741756 100644
--- a/src/util/virutil.c
+++ b/src/util/virutil.c
@@ -1495,8 +1495,6 @@ void virWaitForDevices(void)
     /*
      * NOTE: we ignore errors here; this is just to make sure that any device
      * nodes that are being created finish before we try to scan them.
-     * If this fails for any reason, we still have the backup of polling for
-     * 5 seconds for device nodes.
      */
     ignore_value(virRun(settleprog, &exitstatus));
 }
-- 
2.21.0

--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list
Re: [libvirt] [PATCH 1/4] virWaitForDevices: Drop untrue part of comment
Posted by Ján Tomko 6 years, 8 months ago
On Fri, May 17, 2019 at 11:54:14AM +0200, Michal Privoznik wrote:
>It's not true that there is a backup loop. There isn't. Drop this

There is one in nodeDeviceFindNewDevice. So:
s/untrue/confusing/

>part of the comment to not confuse anybody.
>
>Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
>---
> src/util/virutil.c | 2 --
> 1 file changed, 2 deletions(-)
>
>diff --git a/src/util/virutil.c b/src/util/virutil.c
>index e5917d33de..6123741756 100644
>--- a/src/util/virutil.c
>+++ b/src/util/virutil.c
>@@ -1495,8 +1495,6 @@ void virWaitForDevices(void)
>     /*
>      * NOTE: we ignore errors here; this is just to make sure that any device
>      * nodes that are being created finish before we try to scan them.
>-     * If this fails for any reason, we still have the backup of polling for
>-     * 5 seconds for device nodes.

Documenting what the callers do here in this helper seems strange.

Reviewed-by: Ján Tomko <jtomko@redhat.com>

Jano
--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list