2 * Copyright 2006 Haiku Inc. All rights reserved.
3 * Distributed under the terms of the MIT License.
6 * Jerome Duval (listdev)
15 #include <drivers/device_manager.h>
16 #include <device_manager_defs.h>
17 #include <generic_syscall_defs.h>
21 #include "dm_wrapper.h"
28 return _kern_generic_syscall(DEVICE_MANAGER_SYSCALLS
, B_SYSCALL_INFO
,
29 &version
, sizeof(version
));
34 uninit_dm_wrapper(void)
41 get_root(device_node_cookie
*cookie
)
43 return _kern_generic_syscall(DEVICE_MANAGER_SYSCALLS
, DM_GET_ROOT
, cookie
,
44 sizeof(device_node_cookie
));
49 get_child(device_node_cookie
*device
)
51 return _kern_generic_syscall(DEVICE_MANAGER_SYSCALLS
, DM_GET_CHILD
, device
,
52 sizeof(device_node_cookie
));
57 get_next_child(device_node_cookie
*device
)
59 return _kern_generic_syscall(DEVICE_MANAGER_SYSCALLS
, DM_GET_NEXT_CHILD
,
60 device
, sizeof(device_node_cookie
));
65 dm_get_next_attr(struct device_attr_info
*attr
)
67 return _kern_generic_syscall(DEVICE_MANAGER_SYSCALLS
,
68 DM_GET_NEXT_ATTRIBUTE
, attr
, sizeof(struct device_attr_info
));