Coverage Report

Created: 2026-06-15 06:18

next uncovered line (L), next uncovered region (R), next uncovered branch (B)
/src/hostap/wpa_supplicant/pr_supplicant.h
Line
Count
Source
1
/*
2
 * Proxmity Ranging
3
 * Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.
4
 *
5
 * This software may be distributed under the terms of the BSD license.
6
 * See README for more details.
7
 */
8
9
#ifndef PR_SUPPLICANT_H
10
#define PR_SUPPLICANT_H
11
12
#include "common/proximity_ranging.h"
13
14
#ifdef CONFIG_PR
15
16
int wpas_pr_init(struct wpa_global *global, struct wpa_supplicant *wpa_s,
17
     const struct wpa_driver_capa *capa);
18
void wpas_pr_flush(struct wpa_supplicant *wpa_s);
19
void wpas_pr_deinit(struct wpa_supplicant *wpa_s);
20
void wpas_pr_pd_stop(struct wpa_supplicant *wpa_s);
21
void wpas_pr_update_dev_addr(struct wpa_supplicant *wpa_s);
22
void wpas_pr_clear_dev_iks(struct wpa_supplicant *wpa_s);
23
void wpas_pr_set_dev_ik(struct wpa_supplicant *wpa_s, const u8 *dik,
24
      const char *password, const u8 *pmk, size_t pmk_len,
25
      bool own);
26
struct wpabuf * wpas_pr_usd_elems(struct wpa_supplicant *wpa_s,
27
          const u8 *src_addr);
28
void wpas_pr_process_usd_elems(struct wpa_supplicant *wpa_s, const u8 *buf,
29
             u16 buf_len, const u8 *peer_addr,
30
             unsigned int freq);
31
int wpas_pr_initiate_pasn_auth(struct wpa_supplicant *wpa_s,
32
             const u8 *peer_addr, int freq, u8 auth_mode,
33
             u8 ranging_role, u8 ranging_type,
34
             int forced_pr_freq, const u8 *src_addr,
35
             enum pr_pasn_role pasn_role);
36
int wpas_pr_pasn_auth_tx_status(struct wpa_supplicant *wpa_s, const u8 *data,
37
        size_t data_len, bool acked);
38
int wpas_pr_pasn_auth_rx(struct wpa_supplicant *wpa_s,
39
       const struct ieee80211_mgmt *mgmt, size_t len,
40
       int freq);
41
void wpas_pr_cancel_remain_on_channel_cb(struct wpa_supplicant *wpa_s,
42
           unsigned int freq);
43
int wpas_pr_pasn_trigger(struct wpa_supplicant *wpa_s,
44
       struct pr_pasn_ranging_params *pr_pasn_params);
45
void wpas_pr_abort_ranging(struct wpa_supplicant *wpa_s);
46
void wpas_pr_measurement_complete(struct wpa_supplicant *wpa_s,
47
          struct peer_measurement_complete *complete);
48
void wpas_pr_measurement_result(struct wpa_supplicant *wpa_s,
49
        struct peer_measurement_result *result);
50
51
#else /* CONFIG_PR */
52
53
static inline int wpas_pr_init(struct wpa_global *global,
54
             struct wpa_supplicant *wpa_s,
55
             const struct wpa_driver_capa *capa)
56
0
{
57
0
  return 0;
58
0
}
Unexecuted instantiation: events.c:wpas_pr_init
Unexecuted instantiation: wpa_supplicant.c:wpas_pr_init
59
60
static inline void wpas_pr_flush(struct wpa_supplicant *wpa_s)
61
0
{
62
0
}
Unexecuted instantiation: events.c:wpas_pr_flush
Unexecuted instantiation: wpa_supplicant.c:wpas_pr_flush
63
64
static inline void wpas_pr_deinit(struct wpa_supplicant *wpa_s)
65
0
{
66
0
}
Unexecuted instantiation: events.c:wpas_pr_deinit
Unexecuted instantiation: wpa_supplicant.c:wpas_pr_deinit
67
68
static inline void wpas_pr_pd_stop(struct wpa_supplicant *wpa_s)
69
0
{
70
0
}
Unexecuted instantiation: events.c:wpas_pr_pd_stop
Unexecuted instantiation: wpa_supplicant.c:wpas_pr_pd_stop
71
72
static inline void wpas_pr_update_dev_addr(struct wpa_supplicant *wpa_s)
73
0
{
74
0
}
Unexecuted instantiation: events.c:wpas_pr_update_dev_addr
Unexecuted instantiation: wpa_supplicant.c:wpas_pr_update_dev_addr
75
76
static inline void wpas_pr_clear_dev_iks(struct wpa_supplicant *wpa_s)
77
0
{
78
0
}
Unexecuted instantiation: events.c:wpas_pr_clear_dev_iks
Unexecuted instantiation: wpa_supplicant.c:wpas_pr_clear_dev_iks
79
80
static inline void wpas_pr_set_dev_ik(struct wpa_supplicant *wpa_s,
81
              const u8 *dik, const char *password,
82
              const u8 *pmk, size_t pmk_len, bool own)
83
0
{
84
0
}
Unexecuted instantiation: events.c:wpas_pr_set_dev_ik
Unexecuted instantiation: wpa_supplicant.c:wpas_pr_set_dev_ik
85
86
static inline struct wpabuf * wpas_pr_usd_elems(struct wpa_supplicant *wpa_s,
87
            const u8 *src_addr)
88
0
{
89
0
  return NULL;
90
0
}
Unexecuted instantiation: events.c:wpas_pr_usd_elems
Unexecuted instantiation: wpa_supplicant.c:wpas_pr_usd_elems
91
92
static inline int wpas_pr_initiate_pasn_auth(struct wpa_supplicant *wpa_s,
93
               const u8 *peer_addr, int freq,
94
               u8 auth_mode, u8 ranging_role,
95
               u8 ranging_type,
96
               int forced_pr_freq,
97
               const u8 *src_addr,
98
               enum pr_pasn_role pasn_role)
99
0
{
100
0
  return 0;
101
0
}
Unexecuted instantiation: events.c:wpas_pr_initiate_pasn_auth
Unexecuted instantiation: wpa_supplicant.c:wpas_pr_initiate_pasn_auth
102
103
static inline int wpas_pr_pasn_auth_tx_status(struct wpa_supplicant *wpa_s,
104
                const u8 *data, size_t data_len,
105
                bool acked)
106
0
{
107
0
  return 0;
108
0
}
Unexecuted instantiation: events.c:wpas_pr_pasn_auth_tx_status
Unexecuted instantiation: wpa_supplicant.c:wpas_pr_pasn_auth_tx_status
109
110
static inline int wpas_pr_pasn_auth_rx(struct wpa_supplicant *wpa_s,
111
               const struct ieee80211_mgmt *mgmt,
112
               size_t len, int freq)
113
0
{
114
0
  return 0;
115
0
}
Unexecuted instantiation: events.c:wpas_pr_pasn_auth_rx
Unexecuted instantiation: wpa_supplicant.c:wpas_pr_pasn_auth_rx
116
117
static inline void
118
wpas_pr_cancel_remain_on_channel_cb(struct wpa_supplicant *wpa_s,
119
            unsigned int freq)
120
0
{
121
0
}
Unexecuted instantiation: events.c:wpas_pr_cancel_remain_on_channel_cb
Unexecuted instantiation: wpa_supplicant.c:wpas_pr_cancel_remain_on_channel_cb
122
123
static inline int
124
wpas_pr_pasn_trigger(struct wpa_supplicant *wpa_s,
125
         struct pr_pasn_ranging_params *pr_pasn_params)
126
0
{
127
0
  return -1;
128
0
}
Unexecuted instantiation: events.c:wpas_pr_pasn_trigger
Unexecuted instantiation: wpa_supplicant.c:wpas_pr_pasn_trigger
129
130
static inline void wpas_pr_abort_ranging(struct wpa_supplicant *wpa_s)
131
0
{
132
0
}
Unexecuted instantiation: events.c:wpas_pr_abort_ranging
Unexecuted instantiation: wpa_supplicant.c:wpas_pr_abort_ranging
133
134
static inline void
135
wpas_pr_measurement_complete(struct wpa_supplicant *wpa_s,
136
           struct peer_measurement_complete *complete)
137
0
{
138
0
}
Unexecuted instantiation: events.c:wpas_pr_measurement_complete
Unexecuted instantiation: wpa_supplicant.c:wpas_pr_measurement_complete
139
140
static inline void
141
wpas_pr_measurement_result(struct wpa_supplicant *wpa_s,
142
         struct peer_measurement_result *result)
143
0
{
144
0
}
Unexecuted instantiation: events.c:wpas_pr_measurement_result
Unexecuted instantiation: wpa_supplicant.c:wpas_pr_measurement_result
145
146
#endif /* CONFIG_PR */
147
148
#endif /* PR_SUPPLICANT_H */