Message ID | 20220420114720.1463473-2-liwang@redhat.com |
---|---|
State | Accepted |
Headers | show |
Series | [1/2] ioctl09: wait for udevd complete the uevent handling | expand |
Hi!
Reviewed-by: Cyril Hrubis <chrubis@suse.cz>
Hi all, > Signed-off-by: Li Wang <liwang@redhat.com> > --- > testcases/commands/mkswap/mkswap01.sh | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > diff --git a/testcases/commands/mkswap/mkswap01.sh b/testcases/commands/mkswap/mkswap01.sh > index f6494f6e3..cb3563b49 100755 > --- a/testcases/commands/mkswap/mkswap01.sh > +++ b/testcases/commands/mkswap/mkswap01.sh > @@ -128,7 +128,7 @@ mkswap_test() > return > fi > - udevadm trigger --name-match=$TST_DEVICE > + udevadm trigger --name-match=$TST_DEVICE --settle > if [ -n "$device" ]; then > mkswap_verify "$mkswap_op" "$op_arg" "$device" "$size" "$dev_file" --settle option for udevadm trigger has been added in v238 (in 2018) [1]. This mean on SLES 12-SP5, RHEL-7.9, 18.04 LTS bionic, ... we get: trigger: unrecognized option '--settle' Do we ignore backward compatibility hoping that all distros aren't tested with newer LTP? Kind regards, Petr [1] https://github.com/systemd/systemd/commit/792cc203a67edb201073351f5c766fce3d5eab45
On Thu, Apr 21, 2022 at 4:56 AM Petr Vorel <pvorel@suse.cz> wrote: > > > - udevadm trigger --name-match=$TST_DEVICE > > + udevadm trigger --name-match=$TST_DEVICE --settle > > > if [ -n "$device" ]; then > > mkswap_verify "$mkswap_op" "$op_arg" "$device" "$size" > "$dev_file" > > --settle option for udevadm trigger has been added in v238 (in 2018) [1]. > This mean on SLES 12-SP5, RHEL-7.9, 18.04 LTS bionic, ... we get: > > trigger: unrecognized option '--settle' > Thanks for pointing out this, Petr. > > Do we ignore backward compatibility hoping that all distros aren't tested > with > newer LTP? > Actually, we only use fixed older-version of LTP for long-term supported distros (e.g RHEL6/7) testing, as it falls into maintaining phase and no new features are added in. So this won't be a problem for us. But if we consider fully backward compatibility of newer LTP for old distros, this is a burden to maintaining work. We might need to make a balance on the patch accept or reject. With regard to this simple patch, if you think it's a problem to SLES 12-SP5, I'm fine to NAK and rewrite with another way (at least for ioctl09 I will do that). But if you're OK with making use of fixed LTP on older distros, feel free to apply this one :).
On Thu, Apr 21, 2022 at 10:18 AM Li Wang <liwang@redhat.com> wrote: > > > On Thu, Apr 21, 2022 at 4:56 AM Petr Vorel <pvorel@suse.cz> wrote: > > >> >> > - udevadm trigger --name-match=$TST_DEVICE >> > + udevadm trigger --name-match=$TST_DEVICE --settle >> >> > if [ -n "$device" ]; then >> > mkswap_verify "$mkswap_op" "$op_arg" "$device" "$size" >> "$dev_file" >> >> --settle option for udevadm trigger has been added in v238 (in 2018) [1]. >> This mean on SLES 12-SP5, RHEL-7.9, 18.04 LTS bionic, ... we get: >> >> trigger: unrecognized option '--settle' >> > > Thanks for pointing out this, Petr. > >> >> Do we ignore backward compatibility hoping that all distros aren't tested >> with >> newer LTP? >> > > Actually, we only use fixed older-version of LTP for long-term supported > distros (e.g RHEL6/7) testing, as it falls into maintaining phase and no > new > features are added in. So this won't be a problem for us. > > But if we consider fully backward compatibility of newer LTP for old > distros, > this is a burden to maintaining work. We might need to make a balance on > the patch accept or reject. > > With regard to this simple patch, if you think it's a problem to SLES > 12-SP5, I'm > fine to NAK and rewrite with another way (at least for ioctl09 I will do > that). > > But if you're OK with making use of fixed LTP on older distros, feel free > to apply this one :). > Or, just go with the traditional way for compatibility: --- a/testcases/commands/mkswap/mkswap01.sh +++ b/testcases/commands/mkswap/mkswap01.sh @@ -128,7 +128,8 @@ mkswap_test() return fi - udevadm trigger --name-match=$TST_DEVICE --settle + udevadm trigger --name-match=$TST_DEVICE + udevadm settle --exit-if-exists==$TST_DEVICE if [ -n "$device" ]; then mkswap_verify "$mkswap_op" "$op_arg" "$device" "$size" "$dev_file"
> On Thu, Apr 21, 2022 at 10:18 AM Li Wang <liwang@redhat.com> wrote: > > On Thu, Apr 21, 2022 at 4:56 AM Petr Vorel <pvorel@suse.cz> wrote: > >> > - udevadm trigger --name-match=$TST_DEVICE > >> > + udevadm trigger --name-match=$TST_DEVICE --settle > >> > if [ -n "$device" ]; then > >> > mkswap_verify "$mkswap_op" "$op_arg" "$device" "$size" > >> "$dev_file" > >> --settle option for udevadm trigger has been added in v238 (in 2018) [1]. > >> This mean on SLES 12-SP5, RHEL-7.9, 18.04 LTS bionic, ... we get: > >> trigger: unrecognized option '--settle' > > Thanks for pointing out this, Petr. > >> Do we ignore backward compatibility hoping that all distros aren't tested > >> with > >> newer LTP? > > Actually, we only use fixed older-version of LTP for long-term supported > > distros (e.g RHEL6/7) testing, as it falls into maintaining phase and no > > new > > features are added in. So this won't be a problem for us. > > But if we consider fully backward compatibility of newer LTP for old > > distros, > > this is a burden to maintaining work. We might need to make a balance on > > the patch accept or reject. > > With regard to this simple patch, if you think it's a problem to SLES > > 12-SP5, I'm > > fine to NAK and rewrite with another way (at least for ioctl09 I will do > > that). > > But if you're OK with making use of fixed LTP on older distros, feel free > > to apply this one :). > Or, just go with the traditional way for compatibility: > --- a/testcases/commands/mkswap/mkswap01.sh > +++ b/testcases/commands/mkswap/mkswap01.sh > @@ -128,7 +128,8 @@ mkswap_test() > return > fi > - udevadm trigger --name-match=$TST_DEVICE --settle > + udevadm trigger --name-match=$TST_DEVICE > + udevadm settle --exit-if-exists==$TST_DEVICE IMHO that'd be better (--exit-if-exists was added in 2009 in udev 174). Reviewed-by: Petr Vorel <pvorel@suse.cz> Kind regards, Petr > if [ -n "$device" ]; then > mkswap_verify "$mkswap_op" "$op_arg" "$device" "$size" > "$dev_file"
diff --git a/testcases/commands/mkswap/mkswap01.sh b/testcases/commands/mkswap/mkswap01.sh index f6494f6e3..cb3563b49 100755 --- a/testcases/commands/mkswap/mkswap01.sh +++ b/testcases/commands/mkswap/mkswap01.sh @@ -128,7 +128,7 @@ mkswap_test() return fi - udevadm trigger --name-match=$TST_DEVICE + udevadm trigger --name-match=$TST_DEVICE --settle if [ -n "$device" ]; then mkswap_verify "$mkswap_op" "$op_arg" "$device" "$size" "$dev_file"
Signed-off-by: Li Wang <liwang@redhat.com> --- testcases/commands/mkswap/mkswap01.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)