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-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1bc1c5da-2810-60d3-4e76-8d0b73fdd521@kernel.org>
Date:   Fri, 6 Sep 2019 20:33:33 -0600
From:   shuah <shuah@...nel.org>
To:     Brendan Higgins <brendanhiggins@...gle.com>,
        SeongJae Park <sj38.park@...il.com>
Cc:     "open list:KERNEL SELFTEST FRAMEWORK" 
        <linux-kselftest@...r.kernel.org>, kunit-dev@...glegroups.com,
        Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
        shuah <shuah@...nel.org>
Subject: Re: [PATCH] kunit: Fix '--build_dir' option

On 9/6/19 7:16 PM, Brendan Higgins wrote:
> On Fri, Sep 6, 2019 at 9:12 AM SeongJae Park <sj38.park@...il.com> wrote:
>>
>> Running kunit with '--build_dir' option gives following error message:
>>
>> ```
>> $ ./tools/testing/kunit/kunit.py run --build_dir ../linux.out.kunit/
>> [00:57:24] Building KUnit Kernel ...
>> [00:57:29] Starting KUnit Kernel ...
>> Traceback (most recent call last):
>>    File "./tools/testing/kunit/kunit.py", line 136, in <module>
>>      main(sys.argv[1:])
>>    File "./tools/testing/kunit/kunit.py", line 129, in main
>>      result = run_tests(linux, request)
>>    File "./tools/testing/kunit/kunit.py", line 68, in run_tests
>>      test_result = kunit_parser.parse_run_tests(kunit_output)
>>    File "/home/sjpark/linux/tools/testing/kunit/kunit_parser.py", line
>> 283, in parse_run_tests
>>      test_result =
>> parse_test_result(list(isolate_kunit_output(kernel_output)))
>>    File "/home/sjpark/linux/tools/testing/kunit/kunit_parser.py", line
>> 54, in isolate_kunit_output
>>      for line in kernel_output:
>>    File "/home/sjpark/linux/tools/testing/kunit/kunit_kernel.py", line
>> 145, in run_kernel
>>      process = self._ops.linux_bin(args, timeout, build_dir)
>>    File "/home/sjpark/linux/tools/testing/kunit/kunit_kernel.py", line
>> 69, in linux_bin
>>      stderr=subprocess.PIPE)
>>    File "/usr/lib/python3.5/subprocess.py", line 947, in __init__
>>      restore_signals, start_new_session)
>>    File "/usr/lib/python3.5/subprocess.py", line 1551, in _execute_child
>>      raise child_exception_type(errno_num, err_msg)
>> FileNotFoundError: [Errno 2] No such file or directory: './linux'
>> ```
>>
>> This error occurs because the '--build_dir' option value is not passed
>> to the 'run_kernel()' function.  Consequently, the function assumes
>> the kernel image that built for the tests, which is under the
>> '--build_dir' directory, is in kernel source directory and finally raises
>> the 'FileNotFoundError'.
>>
>> This commit fixes the problem by properly passing the '--build_dir'
>> option value to the 'run_kernel()'.
>>
>> Signed-off-by: SeongJae Park <sj38.park@...il.com>
> 
> Reviewed-by: Brendan Higgins <brendanhiggins@...gle.com>
> Tested-by: Brendan Higgins <brendanhiggins@...gle.com>
> 
> Thanks!
> 

Thanks Brendan! I will apply the patch for 5.4-rc1.

SeongJae Park! In the future, please send tag versions. This should
have been [PATCH v2].

thanks,
-- Shuah

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ