4 * Copyright (C) 2002, 2003, 2004 ReactOS Team
6 * This library is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Library General Public
8 * License as published by the Free Software Foundation; either
9 * version 2 of the License, or (at your option) any later version.
11 * This library is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 * Library General Public License for more details.
16 * You should have received a copy of the GNU Library General Public
17 * License along with this library; see the file COPYING.LIB.
18 * If not, write to the Free Software Foundation,
19 * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
25 /* PUBLIC FUNCTIONS ***********************************************************/
33 IN PVOID HwDeviceExtension
,
40 (*Event
) = ExAllocatePoolWithTag(
46 return ERROR_NOT_ENOUGH_MEMORY
;
48 if (EventFlag
& NOTIFICATION_EVENT
)
49 Type
= NotificationEvent
;
51 Type
= SynchronizationEvent
;
53 KeInitializeEvent((PKEVENT
)*Event
, Type
, EventFlag
& INITIAL_EVENT_SIGNALED
);
63 IN PVOID HwDeviceExtension
,
76 IN PVOID HwDeviceExtension
,
79 return KeSetEvent((PKEVENT
)Event
, IO_NO_INCREMENT
, FALSE
);
88 IN PVOID HwDeviceExtension
,
91 KeClearEvent((PKEVENT
)Event
);
99 VideoPortWaitForSingleObject(
100 IN PVOID HwDeviceExtension
,
102 IN PLARGE_INTEGER Timeout OPTIONAL
)
104 return KeWaitForSingleObject(