ReactOS 0.4.15-dev-7907-g95bf896
IoReadWrite.h File Reference
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define TEST_FILE_SIZE   17
 
#define KEY_SUCCEED   0x00
 
#define KEY_SUCCESS_WAIT1   0x01
 
#define KEY_INFO_EXISTS   0x41
 
#define KEY_FAIL_MISALIGNED   0x81
 
#define KEY_FAIL_OVERFLOW   0x82
 
#define KEY_FAIL_PARTIAL   0x83
 
#define KEY_FAIL_BUSY   0x84
 
#define KEY_FAIL_VERIFY_REQUIRED   0x85
 
#define KEY_FAIL_UNSUCCESSFUL   0xc1
 
#define KEY_FAIL_NOT_IMPLEMENTED   0xc2
 
#define KEY_FAIL_ACCESS_VIOLATION   0xc3
 
#define KEY_FAIL_IN_PAGE_ERROR   0xc4
 
#define KEY_FAIL_EOF   0xc5
 
#define KEY_FAIL_ACCESS_DENIED   0xc6
 
#define KEY_FAIL_MISALIGNED_ERROR   0xc7
 
#define KEY_RESULT_MASK   0xff
 
#define KEY_NEXT(key)
 
#define KEY_ERROR(key)   (((key) & 0xc0) == 0xc0)
 
#define KEY_USE_FASTIO   0x100
 
#define KEY_RETURN_PENDING   0x200
 
#define KEY_DATA(c)   (((c) & 0xff) << 24)
 
#define KEY_GET_DATA(key)   ((key) >> 24)
 

Functions

static NTSTATUS TestGetReturnStatus (_In_ ULONG LockKey)
 

Macro Definition Documentation

◆ KEY_DATA

#define KEY_DATA (   c)    (((c) & 0xff) << 24)

Definition at line 88 of file IoReadWrite.h.

◆ KEY_ERROR

#define KEY_ERROR (   key)    (((key) & 0xc0) == 0xc0)

Definition at line 38 of file IoReadWrite.h.

◆ KEY_FAIL_ACCESS_DENIED

#define KEY_FAIL_ACCESS_DENIED   0xc6

Definition at line 29 of file IoReadWrite.h.

◆ KEY_FAIL_ACCESS_VIOLATION

#define KEY_FAIL_ACCESS_VIOLATION   0xc3

Definition at line 26 of file IoReadWrite.h.

◆ KEY_FAIL_BUSY

#define KEY_FAIL_BUSY   0x84

Definition at line 21 of file IoReadWrite.h.

◆ KEY_FAIL_EOF

#define KEY_FAIL_EOF   0xc5

Definition at line 28 of file IoReadWrite.h.

◆ KEY_FAIL_IN_PAGE_ERROR

#define KEY_FAIL_IN_PAGE_ERROR   0xc4

Definition at line 27 of file IoReadWrite.h.

◆ KEY_FAIL_MISALIGNED

#define KEY_FAIL_MISALIGNED   0x81

Definition at line 18 of file IoReadWrite.h.

◆ KEY_FAIL_MISALIGNED_ERROR

#define KEY_FAIL_MISALIGNED_ERROR   0xc7

Definition at line 30 of file IoReadWrite.h.

◆ KEY_FAIL_NOT_IMPLEMENTED

#define KEY_FAIL_NOT_IMPLEMENTED   0xc2

Definition at line 25 of file IoReadWrite.h.

◆ KEY_FAIL_OVERFLOW

#define KEY_FAIL_OVERFLOW   0x82

Definition at line 19 of file IoReadWrite.h.

◆ KEY_FAIL_PARTIAL

#define KEY_FAIL_PARTIAL   0x83

Definition at line 20 of file IoReadWrite.h.

◆ KEY_FAIL_UNSUCCESSFUL

#define KEY_FAIL_UNSUCCESSFUL   0xc1

Definition at line 24 of file IoReadWrite.h.

◆ KEY_FAIL_VERIFY_REQUIRED

#define KEY_FAIL_VERIFY_REQUIRED   0x85

Definition at line 22 of file IoReadWrite.h.

◆ KEY_GET_DATA

#define KEY_GET_DATA (   key)    ((key) >> 24)

Definition at line 89 of file IoReadWrite.h.

◆ KEY_INFO_EXISTS

#define KEY_INFO_EXISTS   0x41

Definition at line 16 of file IoReadWrite.h.

◆ KEY_NEXT

#define KEY_NEXT (   key)
Value:
( (key) == KEY_FAIL_MISALIGNED_ERROR ? 0xff : \
(key) + 1 )
#define KEY_FAIL_VERIFY_REQUIRED
Definition: IoReadWrite.h:22
#define KEY_FAIL_MISALIGNED_ERROR
Definition: IoReadWrite.h:30
#define KEY_FAIL_UNSUCCESSFUL
Definition: IoReadWrite.h:24
#define KEY_FAIL_MISALIGNED
Definition: IoReadWrite.h:18
#define KEY_SUCCESS_WAIT1
Definition: IoReadWrite.h:14
#define KEY_INFO_EXISTS
Definition: IoReadWrite.h:16
Definition: copy.c:22

Definition at line 33 of file IoReadWrite.h.

◆ KEY_RESULT_MASK

#define KEY_RESULT_MASK   0xff

Definition at line 31 of file IoReadWrite.h.

◆ KEY_RETURN_PENDING

#define KEY_RETURN_PENDING   0x200

Definition at line 86 of file IoReadWrite.h.

◆ KEY_SUCCEED

#define KEY_SUCCEED   0x00

Definition at line 13 of file IoReadWrite.h.

◆ KEY_SUCCESS_WAIT1

#define KEY_SUCCESS_WAIT1   0x01

Definition at line 14 of file IoReadWrite.h.

◆ KEY_USE_FASTIO

#define KEY_USE_FASTIO   0x100

Definition at line 85 of file IoReadWrite.h.

◆ TEST_FILE_SIZE

#define TEST_FILE_SIZE   17

Definition at line 11 of file IoReadWrite.h.

Function Documentation

◆ TestGetReturnStatus()

static NTSTATUS TestGetReturnStatus ( _In_ ULONG  LockKey)
static

Definition at line 41 of file IoReadWrite.h.

43{
44 switch (LockKey & KEY_RESULT_MASK)
45 {
46 case KEY_SUCCEED:
47 return STATUS_SUCCESS;
49 return STATUS_WAIT_1;
50
51 case KEY_INFO_EXISTS:
53
60 case KEY_FAIL_BUSY:
61 return STATUS_DEVICE_BUSY;
64
73 case KEY_FAIL_EOF:
74 return STATUS_END_OF_FILE;
79 default:
80 ok(0, "Key = %lx\n", LockKey);
82 }
83}
#define KEY_FAIL_ACCESS_VIOLATION
Definition: IoReadWrite.h:26
#define KEY_SUCCEED
Definition: IoReadWrite.h:13
#define KEY_FAIL_IN_PAGE_ERROR
Definition: IoReadWrite.h:27
#define KEY_FAIL_OVERFLOW
Definition: IoReadWrite.h:19
#define KEY_FAIL_EOF
Definition: IoReadWrite.h:28
#define KEY_FAIL_BUSY
Definition: IoReadWrite.h:21
#define KEY_FAIL_ACCESS_DENIED
Definition: IoReadWrite.h:29
#define KEY_FAIL_NOT_IMPLEMENTED
Definition: IoReadWrite.h:25
#define KEY_FAIL_PARTIAL
Definition: IoReadWrite.h:20
#define KEY_RESULT_MASK
Definition: IoReadWrite.h:31
#define ok(value,...)
Definition: atltest.h:57
IN PLARGE_INTEGER IN ULONG IN BOOLEAN IN ULONG LockKey
Definition: fatprocs.h:2665
#define STATUS_WAIT_1
Definition: ntstatus.h:71
#define STATUS_OBJECT_NAME_EXISTS
Definition: ntstatus.h:114
#define STATUS_DATATYPE_MISALIGNMENT_ERROR
Definition: ntstatus.h:817
#define STATUS_ACCESS_VIOLATION
Definition: ntstatus.h:242
#define STATUS_NOT_IMPLEMENTED
Definition: ntstatus.h:239
#define STATUS_IN_PAGE_ERROR
Definition: ntstatus.h:243
#define STATUS_DATATYPE_MISALIGNMENT
Definition: ntstatus.h:183
#define STATUS_PARTIAL_COPY
Definition: ntstatus.h:193
#define STATUS_END_OF_FILE
Definition: shellext.h:67
#define STATUS_SUCCESS
Definition: shellext.h:65
#define STATUS_BUFFER_OVERFLOW
Definition: shellext.h:66
#define STATUS_ACCESS_DENIED
Definition: udferr_usr.h:145
#define STATUS_INVALID_PARAMETER
Definition: udferr_usr.h:135
#define STATUS_UNSUCCESSFUL
Definition: udferr_usr.h:132
#define STATUS_DEVICE_BUSY
Definition: udferr_usr.h:129
#define STATUS_VERIFY_REQUIRED
Definition: udferr_usr.h:130

Referenced by TestCommonRead(), TestCommonWrite(), TestRead(), and TestWrite().