]> git.ipfire.org Git - thirdparty/kmod.git/commit
testsuite: depmod: check netsted loops reporting
authorYauheni Kaliuta <yauheni.kaliuta@redhat.com>
Wed, 22 Feb 2017 09:41:58 +0000 (11:41 +0200)
committerLucas De Marchi <lucas.demarchi@intel.com>
Wed, 22 Feb 2017 12:50:22 +0000 (04:50 -0800)
commit9be03c52ccae073745f46e857296f2c21be10e03
tree44221480121ab032c07e9c14781abb1f468eb070
parent31dd40a6b8fd66127496fc0772b6dbe0a3e5b823
testsuite: depmod: check netsted loops reporting

The patch adds nested loops configuration for the loop test:

mod-loop-h -> mod-loop-i -> mod-loop-j -> mod-loop-k
   ^                           |               |
    ---------------------------                |
   |                                           |
    -------------------------------------------

making 2 loops with common edges:

mod-loop-h -> mod-loop-i -> mod-loop-j -> mod-loop-h
mod-loop-h -> mod-loop-i -> mod-loop-j -> mod-loop-k -> mod-loop-h

The actual output for the loops is:

depmod: ERROR: Cycle detected: mod_loop_h -> mod_loop_h
depmod: ERROR: Cycle detected: mod_loop_i -> mod_loop_j -> mod_loop_k -> mod_loop_h -> mod_loop_i

(the order in the second doesn't matter, but the first one is
incorrect)

Signed-off-by: Yauheni Kaliuta <yauheni.kaliuta@redhat.com>
13 files changed:
Makefile.am
testsuite/module-playground/Makefile
testsuite/module-playground/cache/mod-loop-h.ko [new file with mode: 0644]
testsuite/module-playground/cache/mod-loop-i.ko [new file with mode: 0644]
testsuite/module-playground/cache/mod-loop-j.ko [new file with mode: 0644]
testsuite/module-playground/cache/mod-loop-k.ko [new file with mode: 0644]
testsuite/module-playground/mod-loop-h.c [new file with mode: 0644]
testsuite/module-playground/mod-loop-i.c [new file with mode: 0644]
testsuite/module-playground/mod-loop-j.c [new file with mode: 0644]
testsuite/module-playground/mod-loop-k.c [new file with mode: 0644]
testsuite/module-playground/mod-loop.h
testsuite/populate-modules.sh
testsuite/rootfs-pristine/test-depmod/detect-loop/correct.txt