blob: de976bfd18325b7d7186a9834e560dba22bcdeba [file] [log] [blame]
rjw6c1fd8f2022-11-30 14:33:01 +08001/*****************************************************************************
2* Copyright Statement:
3* --------------------
4* This software is protected by Copyright and the information contained
5* herein is confidential. The software may not be copied and the information
6* contained herein may not be used or disclosed except with the written
7* permission of MediaTek Inc. (C) 2012
8*
9* BY OPENING THIS FILE, BUYER HEREBY UNEQUIVOCALLY ACKNOWLEDGES AND AGREES
10* THAT THE SOFTWARE/FIRMWARE AND ITS DOCUMENTATIONS ("MEDIATEK SOFTWARE")
11* RECEIVED FROM MEDIATEK AND/OR ITS REPRESENTATIVES ARE PROVIDED TO BUYER ON
12* AN "AS-IS" BASIS ONLY. MEDIATEK EXPRESSLY DISCLAIMS ANY AND ALL WARRANTIES,
13* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE IMPLIED WARRANTIES OF
14* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE OR NONINFRINGEMENT.
15* NEITHER DOES MEDIATEK PROVIDE ANY WARRANTY WHATSOEVER WITH RESPECT TO THE
16* SOFTWARE OF ANY THIRD PARTY WHICH MAY BE USED BY, INCORPORATED IN, OR
17* SUPPLIED WITH THE MEDIATEK SOFTWARE, AND BUYER AGREES TO LOOK ONLY TO SUCH
18* THIRD PARTY FOR ANY WARRANTY CLAIM RELATING THERETO. MEDIATEK SHALL ALSO
19* NOT BE RESPONSIBLE FOR ANY MEDIATEK SOFTWARE RELEASES MADE TO BUYER'S
20* SPECIFICATION OR TO CONFORM TO A PARTICULAR STANDARD OR OPEN FORUM.
21*
22* BUYER'S SOLE AND EXCLUSIVE REMEDY AND MEDIATEK'S ENTIRE AND CUMULATIVE
23* LIABILITY WITH RESPECT TO THE MEDIATEK SOFTWARE RELEASED HEREUNDER WILL BE,
24* AT MEDIATEK'S OPTION, TO REVISE OR REPLACE THE MEDIATEK SOFTWARE AT ISSUE,
25* OR REFUND ANY SOFTWARE LICENSE FEES OR SERVICE CHARGE PAID BY BUYER TO
26* MEDIATEK FOR SUCH MEDIATEK SOFTWARE AT ISSUE.
27*
28* THE TRANSACTION CONTEMPLATED HEREUNDER SHALL BE CONSTRUED IN ACCORDANCE
29* WITH THE LAWS OF THE STATE OF CALIFORNIA, USA, EXCLUDING ITS CONFLICT OF
30* LAWS PRINCIPLES. ANY DISPUTES, CONTROVERSIES OR CLAIMS ARISING THEREOF AND
31* RELATED THERETO SHALL BE SETTLED BY ARBITRATION IN SAN FRANCISCO, CA, UNDER
32* THE RULES OF THE INTERNATIONAL CHAMBER OF COMMERCE (ICC).
33*
34*****************************************************************************/
35
36/*******************************************************************************
37 * Filename:
38 * ---------
39 * l1sp_el2_struct.h
40 *
41 * Project:
42 * --------
43 * MOLY
44 *
45 * Description:
46 * ------------
47 * message and common structure definition between LTM and EL2 modules.
48 *
49 * Author:
50 * -------
51 * -------
52 *
53 * ==========================================================================
54 * $Log$
55 *
56 * 08 24 2017 jia-shi.lin
57 * [MOLY00273519] [MT6763] volte data prediction design change
58 * volte data prediction design change
59 *
60 * 07 26 2017 jia-shi.lin
61 * [MOLY00266995] [MT6763] add normal mode for AAM report
62 * add normal mode for AAM report
63 *
64 * 05 23 2017 fu-shing.ju
65 * [MOLY00241210] [6293][Speech Driver]EVS Speech Driver
66 * EVS speech driver.
67 *
68 * 10 28 2016 jia-shi.lin
69 * [MOLY00194987] [MT6293][UMOLYA/PS DEV] EMAC maintenance
70 * emac timing report for volte dsp
71 *
72 * 10 28 2016 fu-shing.ju
73 * [MOLY00210308] [93MD]early porting.
74 * Modify AAM interface.
75 *
76 * 06 10 2015 fu-shing.ju
77 * [MOLY00091627] TK6291 development
78 * Add time information in l1sp_emac_volte_timing_info_struct.
79 ****************************************************************************/
80
81
82#ifndef _L1SP_EL2_STRUCT_H_
83#define _L1SP_EL2_STRUCT_H_
84
85/*
862017/03/14 Add comment to clarify interface
87
881. drx_period
89This field is same with long cycle period defined in 3GPP spec.
90The value means how often UE need to wake-up, 0 = no DRX configuration, possible value are 10,20,32,40,64,80,128,160,256,320,512,640,1024,1280,2048,2560.
91
922. sr_period
93The value means how often UE can send SR, possible value are 1,2,5,10,20,40,80.
94This field value will be modified when this change will reduce UE power-consumption.
95When VSR is trigger, sr_period will possibly change into 20/40 ms in silence mode and 20ms in talking mode.
96When EVSR is trigger, sr_period will possibly change into 40ms in talking mode.
97
98 a. VSR
99 If DRX cycle < 20 ms || DRX cycle < SR period
100 Do not trigger VSR. use original SR period.
101 If DRX cycle < 40ms
102 If SR period >= 20 then use SR period, otherwise set period=20
103 If DRX cycle >= 40ms
104 Silence: if SR period >= 40 then use SR period, otherwise set period=40
105 Talking: if SR period >= 20 then use SR period, otherwise set period=20
106 b. eVSR
107 b.1 Base condition
108 CDRX cycle length == 40ms && SR periodicity < 40ms
109 b.2 Dynamic start condition
110 UL grant received in on duration && UL grant TBS > threshold for consecutive NSTART times
111 b.3 Dynamic stop condition
112 Data exists in VoLTE RB > 30ms
113
114 If (b.1 && b.2 && !b.3)
115 Talking mode will also set SR period = 40.
116
1173. time_to_next_on
118Define as the time duration between current time and next DRX on duration (wake-up).
119
1204. time_to_trigger_sr
121Define as the time duration between current time and next SR.
122
1235. current_time_us
124Define as current time that use ust_get_current_time to get.
125*/
126#include "kal_public_api.h"
127
128typedef enum{
129 SP4G_AAMPLUS_STA_SILENCE = 0,
130 SP4G_AAMPLUS_STA_TALK,
131 SP4G_AAMPLUS_STA_SID_FIRST
132}SP4G_AAMPlus_State_t;
133
134typedef enum{
135 L1SP_EMAC_REPORT_MODE_SR_0_AFTER_HO = 0,
136 L1SP_EMAC_REPORT_MODE_NORMAL = 1
137}l1sp_emac_report_mode_e;
138
139typedef struct{
140 LOCAL_PARA_HDR
141 //raw information from speech driver
142 SP4G_AAMPlus_State_t silence_talk;
143 kal_uint32 notify_to_data_ms;
144 kal_uint32 issue_time;
145}l1sp_emac_volte_notify_mode_change_struct;
146
147
148typedef struct{
149 LOCAL_PARA_HDR
150 //raw information from eMAC
151 kal_uint32 RX_period; //ms
152 kal_uint32 TX_period; //ms
153 kal_uint32 time2nextRX; //ms
154 kal_uint32 time2nextTX; //ms
155 kal_uint32 issueTime; //ms
156}l1sp_emac_resync_info_struct;
157
158
159typedef struct{
160 kal_uint32 drx_period;
161 kal_uint32 sr_period;
162 kal_uint32 time_to_next_on;
163 kal_uint32 time_to_trig_sr;
164 kal_uint32 current_time_us;
165}l1sp_emac_volte_timing_info_struct;
166
167#endif /* ----- #ifndef _L1SP_EL2_STRUCT_H_ ----- */
168