lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <e6f0ab85-5bbe-41c1-8976-5ba00044998c@roeck-us.net>
Date: Sun, 4 Feb 2024 22:53:46 -0800
From: Guenter Roeck <linux@...ck-us.net>
To: Yury Norov <yury.norov@...il.com>
Cc: James.Bottomley@...senpartnership.com, Helge Deller <deller@....de>,
	linux-parisc@...r.kernel.org,
	Andy Shevchenko <andriy.shevchenko@...ux.intel.com>,
	Rasmus Villemoes <linux@...musvillemoes.dk>,
	linux-kernel@...r.kernel.org
Subject: Kunit test failures with cpumask tests on parisc

Hi,

when running cpumask Kunit tests on parisc/parisc64 in qemu,
I get the following errors.

      KTAP version 1
      # Subtest: cpumask
      # module: cpumask_kunit
      1..6
      # test_cpumask_weight: EXPECTATION FAILED at lib/cpumask_kunit.c:68
      Expected nr_cpu_ids == cpumask_weight(((const struct cpumask *)&__cpu_possible_mask)), but
          nr_cpu_ids == 16 (0x10)
          cpumask_weight(((const struct cpumask *)&__cpu_possible_mask)) == 1 (0x1)
  cpu_possible_mask contains CPUs 0
      not ok 1 test_cpumask_weight
      # test_cpumask_first: EXPECTATION FAILED at lib/cpumask_kunit.c:79
      Expected nr_cpu_ids <= cpumask_first_zero(((const struct cpumask *)&__cpu_possible_mask)), but
          nr_cpu_ids == 16 (0x10)
          cpumask_first_zero(((const struct cpumask *)&__cpu_possible_mask)) == 1 (0x1)
  cpu_possible_mask contains CPUs 0
      not ok 2 test_cpumask_first
      # test_cpumask_last: EXPECTATION FAILED at lib/cpumask_kunit.c:87
      Expected nr_cpu_ids - 1 == cpumask_last(((const struct cpumask *)&__cpu_possible_mask)), but
          nr_cpu_ids - 1 == 15 (0xf)
          cpumask_last(((const struct cpumask *)&__cpu_possible_mask)) == 0 (0x0)
  cpu_possible_mask contains CPUs 0
      not ok 3 test_cpumask_last
      # test_cpumask_next: EXPECTATION FAILED at lib/cpumask_kunit.c:94
      Expected nr_cpu_ids <= cpumask_next_zero(-1, ((const struct cpumask *)&__cpu_possible_mask)), but
          nr_cpu_ids == 16 (0x10)
          cpumask_next_zero(-1, ((const struct cpumask *)&__cpu_possible_mask)) == 1 (0x1)
  cpu_possible_mask contains CPUs 0
      not ok 4 test_cpumask_next
      ok 5 test_cpumask_iterators
      ok 6 test_cpumask_iterators_builtin
  # cpumask: pass:2 fail:4 skip:0 total:6
  # Totals: pass:2 fail:4 skip:0 total:6
  not ok 5 cpumask

It appears that parisc sets __cpu_possible_mask to the number of online CPUs,
which is limited in qemu and doesn't match CONFIG_NR_CPUS. Is this a problem
with the unit test or with the parisc architecture, or does the unit test
simply not apply for parisc ?

Thanks,
Guenter

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ