Added new private API to get more information on a team:

* Userland interface: get_extended_team_info().
* Syscall: _kern_get_extended_team_info.

Only partially implemented yet.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@39453 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Ingo Weinhold
2010-11-16 19:42:08 +00:00
parent f31ab90a8d
commit 56d734a1aa
6 changed files with 140 additions and 0 deletions
+2
View File
@@ -84,6 +84,8 @@ status_t _user_get_team_info(team_id id, team_info *info);
status_t _user_get_next_team_info(int32 *cookie, team_info *info);
status_t _user_get_team_usage_info(team_id team, int32 who,
team_usage_info *info, size_t size);
status_t _user_get_extended_team_info(team_id teamID, uint32 flags,
void* buffer, size_t size, size_t* _sizeNeeded);
#ifdef __cplusplus
}
@@ -0,0 +1,31 @@
/*
* Copyright 2010, Ingo Weinhold, [email protected].
* Distributed under the terms of the MIT License.
*/
#ifndef _LIBROOT_EXTENDED_SYSTEM_INFO_H
#define _LIBROOT_EXTENDED_SYSTEM_INFO_H
/* This is C++ only API. */
#ifdef __cplusplus
#include <OS.h>
namespace BPrivate {
struct KMessage;
status_t get_extended_team_info(team_id teamID, uint32 flags, KMessage& info);
} // namespace BPrivate
#endif /* __cplusplus */
#endif /* _LIBROOT_EXTENDED_SYSTEM_INFO_H */
@@ -0,0 +1,20 @@
/*
* Copyright 2010, Ingo Weinhold, [email protected].
* Distributed under the terms of the MIT License.
*/
#ifndef _SYSTEM_EXTENDED_SYSTEM_INFO_DEFS_H
#define _SYSTEM_EXTENDED_SYSTEM_INFO_DEFS_H
enum {
B_TEAM_INFO_BASIC = 0x01, // basic general info
B_TEAM_INFO_THREADS = 0x02, // list of threads
B_TEAM_INFO_IMAGES = 0x04, // list of images
B_TEAM_INFO_AREAS = 0x08, // list of areas
B_TEAM_INFO_SEMAPHORES = 0x10, // list of semaphores
B_TEAM_INFO_PORTS = 0x20, // list of ports
B_TEAM_INFO_FILE_DESCRIPTORS = 0x40 // list of file descriptors
};
#endif /* _SYSTEM_EXTENDED_SYSTEM_INFO_DEFS_H */
+2
View File
@@ -171,6 +171,8 @@ extern status_t _kern_get_team_info(team_id id, team_info *info);
extern status_t _kern_get_next_team_info(int32 *cookie, team_info *info);
extern status_t _kern_get_team_usage_info(team_id team, int32 who,
team_usage_info *info, size_t size);
extern status_t _kern_get_extended_team_info(team_id teamID, uint32 flags,
void* buffer, size_t size, size_t* _sizeNeeded);
extern status_t _kern_block_thread(uint32 flags, bigtime_t timeout);
extern status_t _kern_unblock_thread(thread_id thread, status_t status);