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: <635c8f9d-8378-519a-6003-a04c2f999d2d@redhat.com>
Date:   Mon, 15 Oct 2018 15:46:59 -0400
From:   Joe Lawrence <joe.lawrence@...hat.com>
To:     Petr Mladek <pmladek@...e.com>, Jiri Kosina <jikos@...nel.org>,
        Josh Poimboeuf <jpoimboe@...hat.com>,
        Miroslav Benes <mbenes@...e.cz>
Cc:     Jason Baron <jbaron@...mai.com>,
        Evgenii Shatokhin <eshatokhin@...tuozzo.com>,
        live-patching@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH v13 12/12] selftests/livepatch: introduce tests

On 10/15/2018 08:37 AM, Petr Mladek wrote:
> From: Joe Lawrence <joe.lawrence@...hat.com>
> 
> Add a few livepatch modules and simple target modules that the included
> regression suite can run tests against:
> 
>   - basic livepatching (multiple patches, atomic replace)
>   - pre/post (un)patch callbacks
>   - shadow variable API
> 
> Signed-off-by: Joe Lawrence <joe.lawrence@...hat.com>
> ---
>
> [ ... snip ... ]
>
> diff --git a/tools/testing/selftests/livepatch/functions.sh b/tools/testing/selftests/livepatch/functions.sh
> new file mode 100644
> index 000000000000..d448b115f06c
> --- /dev/null
> +++ b/tools/testing/selftests/livepatch/functions.sh
>
> [ ... snip ... ]
>
> +# disable_lp(modname) - disable a livepatch
> +#	modname - module name to unload
> +function disable_lp() {
> +	local mod="$1"
> +
> +	log "% echo 0 > /sys/kernel/livepatch/$mod/enabled"
> +	echo 0 > /sys/kernel/livepatch/"$mod"/enabled
> +
> + 	# Wait until the transition finishes and the livepatch gets
> +	# removed from sysfs...
> +	loop_until '[[ ! -e "/sys/kernel/livepatch/$mod" ]]' ||
> +		die "failed to disable livepatch $mod"

small nit in case there is a v14:

Applying: selftests/livepatch: introduce tests
/root/linux/.git/rebase-apply/patch:1513: space before tab in indent.
        # Wait until the transition finishes and the livepatch gets

And FWIW v13's selftests ran just fine on ppc64le over here.

-- Joe

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ