summaryrefslogtreecommitdiff
path: root/test/tx/cmake/module_qemu/tests/harness_checks.h
blob: 19ad68ae42b2ce3a816d1982033ef901d06972da (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
/***************************************************************************
 * Copyright (c) 2026 Eclipse ThreadX contributors
 *
 * This program and the accompanying materials are made available under the
 * terms of the MIT License which is available at
 * https://opensource.org/licenses/MIT.
 *
 * AI Disclosure: This file was largely AI-generated by Claude Code (Opus 5.5).
 * The AI-generated portions may be considered public domain (CC0-1.0)
 * and not subject to the project's licence. The human contributor has
 * reviewed and verified that the code is correct.
 *
 * SPDX-License-Identifier: MIT and CC0-1.0
 **************************************************************************/


/**************************************************************************/
/**************************************************************************/
/**                                                                       */
/** ThreadX Test                                                          */
/**                                                                       */
/**   Module execution harness: checks shared by the test images          */
/**                                                                       */
/**************************************************************************/
/**************************************************************************/

#ifndef HARNESS_CHECKS_H
#define HARNESS_CHECKS_H

#include "harness.h"
#include "module_shared.h"

/* CONTROL.nPRIV: set when a thread runs unprivileged.  */
#define CONTROL_NPRIV           ((ULONG) 1UL)

/* The module's sleep must have lasted at least this many ticks.  */
#define EXPECTED_SLEEP_TICKS    ((ULONG) 5UL)

/* The kernel services part of the test module, common to every image.  */
VOID    harness_check_services(ULONG cycle);

/* Available bytes in the Module Manager's pool.  */
ULONG   harness_module_pool_available(VOID);

#endif