ps3-hvcall.master (9b4fcf851a73554063d4a2de9a4f10cd23a0a4f6) ps3-hvcall.master (67de2cd33040bc06e481ad4ebfc9afea626be3a4)
1/*
2 * Playstation 3 LV1 hypercall interface
3 *
4 * $FreeBSD$
5 */
6
7#include <sys/types.h>
8
9enum lpar_id {
10 PS3_LPAR_ID_CURRENT = 0x00,
11 PS3_LPAR_ID_PME = 0x01,
12};
13
1/*
2 * Playstation 3 LV1 hypercall interface
3 *
4 * $FreeBSD$
5 */
6
7#include <sys/types.h>
8
9enum lpar_id {
10 PS3_LPAR_ID_CURRENT = 0x00,
11 PS3_LPAR_ID_PME = 0x01,
12};
13
14/* Return codes from hypercalls */
15#define LV1_SUCCESS 0
16#define LV1_RESOURCE_SHORTAGE -2
17#define LV1_NO_PRIVILEGE -3
18#define LV1_DENIED_BY_POLICY -4
19#define LV1_ACCESS_VIOLATION -5
20#define LV1_NO_ENTRY -6
21#define LV1_DUPLICATE_ENTRY -7
22#define LV1_TYPE_MISMATCH -8
23#define LV1_BUSY -9
24#define LV1_EMPTY -10
25#define LV1_WRONG_STATE -11
26#define LV1_NO_MATCH -13
27#define LV1_ALREADY_CONNECTED -14
28#define LV1_UNSUPPORTED_PARAMETER_VALUE -15
29#define LV1_CONDITION_NOT_SATISFIED -16
30#define LV1_ILLEGAL_PARAMETER_VALUE -17
31#define LV1_BAD_OPTION -18
32#define LV1_IMPLEMENTATION_LIMITATION -19
33#define LV1_NOT_IMPLEMENTED -20
34#define LV1_INVALID_CLASS_ID -21
35#define LV1_CONSTRAINT_NOT_SATISFIED -22
36#define LV1_ALIGNMENT_ERROR -23
37#define LV1_HARDWARE_ERROR -24
38#define LV1_INVALID_DATA_FORMAT -25
39#define LV1_INVALID_OPERATION -26
40#define LV1_INTERNAL_ERROR -32768
41
14static inline uint64_t
15lv1_repository_string(const char *str)
16{
17 uint64_t ret = 0;
18 strncpy((char *)&ret, str, sizeof(ret));
19 return (ret);
20}
21

--- 90 unchanged lines hidden ---
42static inline uint64_t
43lv1_repository_string(const char *str)
44{
45 uint64_t ret = 0;
46 strncpy((char *)&ret, str, sizeof(ret));
47 return (ret);
48}
49

--- 90 unchanged lines hidden ---