11e8a1faeSThomas Huth /* 21e8a1faeSThomas Huth * QEMU boot sector testing helpers. 31e8a1faeSThomas Huth * 41e8a1faeSThomas Huth * Copyright (c) 2016 Red Hat Inc. 51e8a1faeSThomas Huth * 61e8a1faeSThomas Huth * Authors: 71e8a1faeSThomas Huth * Michael S. Tsirkin <mst@redhat.com> 81e8a1faeSThomas Huth * Victor Kaplansky <victork@redhat.com> 91e8a1faeSThomas Huth * 101e8a1faeSThomas Huth * This work is licensed under the terms of the GNU GPL, version 2 or later. 111e8a1faeSThomas Huth * See the COPYING file in the top-level directory. 121e8a1faeSThomas Huth */ 131e8a1faeSThomas Huth 141e8a1faeSThomas Huth #ifndef TEST_BOOT_SECTOR_H 151e8a1faeSThomas Huth #define TEST_BOOT_SECTOR_H 161e8a1faeSThomas Huth 17*907b5105SMarc-André Lureau #include "libqtest.h" 181e8a1faeSThomas Huth 191e8a1faeSThomas Huth /* Create boot disk file. fname must be a suitable string for mkstemp() */ 201e8a1faeSThomas Huth int boot_sector_init(char *fname); 211e8a1faeSThomas Huth 221e8a1faeSThomas Huth /* Loop until signature in memory is OK. */ 231e8a1faeSThomas Huth void boot_sector_test(QTestState *qts); 241e8a1faeSThomas Huth 251e8a1faeSThomas Huth /* unlink boot disk file. */ 261e8a1faeSThomas Huth void boot_sector_cleanup(const char *fname); 271e8a1faeSThomas Huth 281e8a1faeSThomas Huth #endif /* TEST_BOOT_SECTOR_H */ 29