/* * Copyright 2016, Cyril Bur, IBM Corp. * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version * 2 of the License, or (at your option) any later version. * * Syscalls can be performed provided the transactions are suspended. * The exec() class of syscall is unique as a new process is loaded. * * It makes little sense for after an exec() call for the previously * suspended transaction to still exist. */ #define _GNU_SOURCE #include #include #include #include #include #include #include #include #include "utils.h" #include "tm.h" static char *path; static int test_exec(void) { SKIP_IF(!have_htm()); asm __volatile__( "tbegin.;" "blt 1f; " "tsuspend.;" "1: ;" : : : "memory"); execl(path, "tm-exec", "--child", NULL); /* Shouldn't get here */ perror("execl() failed"); return 1; } static int after_exec(void) { asm __volatile__( "tbegin.;" "blt 1f;" "tsuspend.;" "1: ;" : : : "memory"); FAIL_IF(failure_is_nesting()); return 0; } int main(int argc, char *argv[]) { path = argv[0]; if (argc > 1 && strcmp(argv[1], "--child") == 0) return after_exec(); return test_harness(test_exec, "tm_exec"); } ght'>Tobias Klauser
summaryrefslogtreecommitdiff
bmit();'>
AgeCommit message (Expand)AuthorFilesLines
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2017-02-08 09:56:15 -0800
committerLinus Torvalds <torvalds@linux-foundation.org>2017-02-08 09:56:15 -0800
commit23fbe2cdc1de80120cf9ccd478ac57c3a3a0764b (patch)
tree4aff32d5f2f6fe2f54028bfd4d1b66fdd2f8d281 /net/tipc/link.c
parent926af6273fc683cd98cd0ce7bf0d04a02eed6742 (diff)
parenteeeefd41843218c55a8782a6920f044d9bf6207a (diff)
Merge branch 'for-linus' of git://git.kernel.dk/linux-block
Pull block fix from Jens Axboe: "A single fix that should go into 4.10, fixing a regression on some devices with the WRITE_SAME command" * 'for-linus' of git://git.kernel.dk/linux-block: block: don't try Write Same from __blkdev_issue_zeroout
Diffstat (limited to 'net/tipc/link.c')