ReactOS
0.4.16-dev-959-g2ec3a19
Toggle main menu visibility
Main Page
Related Pages
Modules
Namespaces
Namespace List
Namespace Members
All
_
a
b
c
d
e
f
g
h
i
l
m
n
o
p
r
s
t
u
v
w
x
Functions
_
a
b
c
d
e
f
g
h
i
l
m
o
p
r
s
t
u
v
w
Variables
_
c
d
e
f
g
h
i
l
m
n
o
p
s
t
u
x
Typedefs
_
a
b
c
d
e
f
g
h
i
l
m
o
p
r
s
t
u
v
w
x
Enumerations
_
a
b
c
d
f
i
l
m
o
p
s
t
w
x
Enumerator
a
b
c
d
e
f
g
h
i
m
n
o
p
r
s
t
u
v
w
x
Classes
Class List
Class Index
Class Hierarchy
Class Members
All
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
~
Functions
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
~
Variables
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Typedefs
_
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Enumerations
_
a
b
c
d
e
f
h
i
k
l
m
n
o
p
r
s
t
u
v
w
z
Enumerator
_
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Properties
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
z
Related Functions
_
a
b
c
d
e
f
g
h
i
l
m
n
o
p
q
r
s
t
v
x
Files
File List
File Members
All
$
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Functions
$
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Variables
$
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Typedefs
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Enumerations
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Enumerator
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Macros
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Examples
sb16.c
Go to the documentation of this file.
1
/*
2
* COPYRIGHT: See COPYING in the top level directory
3
* PROJECT: ReactOS kernel
4
* FILE: services/dd/sound/sb16.c
5
* PURPOSE: SB16 device driver
6
* PROGRAMMER: Steven Edwards
7
* UPDATE HISTORY:
8
* 19/01/04 Created
9
*
10
*/
11
12
/* INCLUDES ****************************************************************/
13
14
#include <ntddk.h>
15
16
NTSTATUS
NTAPI
17
DriverEntry
(
PDRIVER_OBJECT
DriverObject
,
18
PUNICODE_STRING
RegistryPath
);
19
20
#define NDEBUG
21
#include <debug.h>
22
23
NTSTATUS
NTAPI
24
DriverEntry
(
PDRIVER_OBJECT
DriverObject
,
25
PUNICODE_STRING
RegistryPath
)
26
/*
27
* FUNCTION: Called by the system to initialize the driver
28
* ARGUMENTS:
29
* DriverObject = object describing this driver
30
* RegistryPath = path to our configuration entries
31
* RETURNS: Success or failure
32
*/
33
{
34
PDEVICE_OBJECT
DeviceObject
;
35
UNICODE_STRING
DeviceName
=
RTL_CONSTANT_STRING
(
L
"\\Device\\SNDBLST"
);
36
UNICODE_STRING
SymlinkName =
RTL_CONSTANT_STRING
(
L
"\\??\\SNDBLST"
);
37
NTSTATUS
Status
;
38
39
DPRINT1
(
"Sound Blaster 16 Driver 0.0.1\n"
);
40
41
DriverObject
->Flags = 0;
42
43
Status
=
IoCreateDevice
(
DriverObject
,
44
0,
45
&
DeviceName
,
46
FILE_DEVICE_BEEP
,
47
0,
48
FALSE
,
49
&
DeviceObject
);
50
if
(!
NT_SUCCESS
(
Status
))
51
return
Status
;
52
53
/* Create the dos device link */
54
IoCreateSymbolicLink
(&SymlinkName,
55
&
DeviceName
);
56
57
return
(
STATUS_SUCCESS
);
58
}
59
60
/* EOF */
NTSTATUS
LONG NTSTATUS
Definition:
precomp.h:26
DPRINT1
#define DPRINT1
Definition:
precomp.h:8
FALSE
#define FALSE
Definition:
types.h:117
NT_SUCCESS
#define NT_SUCCESS(StatCode)
Definition:
apphelp.c:33
DriverEntry
DRIVER_INITIALIZE DriverEntry
Definition:
condrv.c:21
Status
Status
Definition:
gdiplustypes.h:25
IoCreateDevice
NTSTATUS NTAPI IoCreateDevice(IN PDRIVER_OBJECT DriverObject, IN ULONG DeviceExtensionSize, IN PUNICODE_STRING DeviceName, IN DEVICE_TYPE DeviceType, IN ULONG DeviceCharacteristics, IN BOOLEAN Exclusive, OUT PDEVICE_OBJECT *DeviceObject)
Definition:
device.c:1031
IoCreateSymbolicLink
NTSTATUS NTAPI IoCreateSymbolicLink(IN PUNICODE_STRING SymbolicLinkName, IN PUNICODE_STRING DeviceName)
Definition:
symlink.c:23
L
#define L(x)
Definition:
ntvdm.h:50
FILE_DEVICE_BEEP
#define FILE_DEVICE_BEEP
Definition:
winioctl.h:46
STATUS_SUCCESS
#define STATUS_SUCCESS
Definition:
shellext.h:65
_DEVICE_OBJECT
Definition:
env_spec_w32.h:413
_DRIVER_OBJECT
Definition:
iotypes.h:2274
_UNICODE_STRING
Definition:
env_spec_w32.h:368
RTL_CONSTANT_STRING
#define RTL_CONSTANT_STRING(s)
Definition:
tunneltest.c:14
NTAPI
#define NTAPI
Definition:
typedefs.h:36
DeviceObject
_In_ PDEVICE_OBJECT DeviceObject
Definition:
wdfdevice.h:2055
DeviceName
_Must_inspect_result_ _In_ PWDFDEVICE_INIT _In_opt_ PCUNICODE_STRING DeviceName
Definition:
wdfdevice.h:3275
RegistryPath
_Must_inspect_result_ _In_ PDRIVER_OBJECT _In_ PCUNICODE_STRING RegistryPath
Definition:
wdfdriver.h:215
DriverObject
_Must_inspect_result_ _In_ PDRIVER_OBJECT DriverObject
Definition:
wdfdriver.h:213
drivers
multimedia
audio
sound
sb16.c
Generated on Sun Apr 6 2025 06:08:29 for ReactOS by
1.9.6