summaryrefslogtreecommitdiff
path: root/cesar/cp/sta/action/handover.h
blob: 29b45a625f37b03b14592cbddedea8b3333b4cf2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
#ifndef cp_sta_action_handover_h
#define cp_sta_action_handover_h
/* Cesar project {{{
 *
 * Copyright (C) 2009 Spidcom
 *
 * <<<Licence>>>
 *
 * }}} */
/**
 * \file    cp/sta/action/handover.h
 * \brief   STA action Handover
 * \ingroup cp_sta_action
 *
 * All the function to handover.
 */
#include "cp/types.h"
#include "cp/mme.h"

BEGIN_DECLS

/**
 * Starts the handover process.
 * \param  ctx  control plane context
 * \param  mme  the MMe received.
 *
 * This is called by the FSM on a cc_handover_req MME.
 */
void
cp_sta_action_handover__handover (cp_t *ctx, cp_mme_rx_t *mme);

/**
 * Starts the handover process.
 * \param  ctx  control plane context
 * \param  mme  the MMe received.
 */
void
cp_sta_action_handover__start (cp_t *ctx, cp_mme_rx_t *mme);

/**
 * Received the cc_handover_info_ind MME.
 * \param  ctx  control plane context.
 * \param  mme  the MMe received.
 *
 * The handover procedure is done, now wait the expiration countdown in the
 * central beacon to become CCo.
 */
void
cp_sta_action_handover__handover_info_ind_receive (cp_t *ctx,
                                                   cp_mme_rx_t *mme);

/**
 * The countdown handover in the central beacon ended.
 * \param  ctx  control plane context.
 *
 * The station is shall now start acting as CCo.
 */
void
cp_sta_action_handover__handover_ended (cp_t *ctx);

/**
 * The countdown handover in the central beacon ended.
 * \param  ctx  control plane context.
 * \param  net  our network.
 * \param  sta  the New CCo.
 *
 * The new CCo took its functionalities.
 */
void
cp_sta_action_handover__sta_handover (cp_t *ctx, cp_net_t *net,
                                      cp_sta_t *sta);

/**
 * The handover procedure failed.
 * \param  ctx  control plane context.
 */
void
cp_sta_action_handover__failure (cp_t *ctx);

END_DECLS

#endif /* cp_sta_action_handover_h */