.. | .. |
---|
8 | 8 | * Copyright(c) 2007 - 2014 Intel Corporation. All rights reserved. |
---|
9 | 9 | * Copyright(c) 2013 - 2014 Intel Mobile Communications GmbH |
---|
10 | 10 | * Copyright(c) 2015 Intel Deutschland GmbH |
---|
| 11 | + * Copyright(c) 2018 - 2019 Intel Corporation |
---|
11 | 12 | * |
---|
12 | 13 | * This program is free software; you can redistribute it and/or modify |
---|
13 | 14 | * it under the terms of version 2 of the GNU General Public License as |
---|
.. | .. |
---|
17 | 18 | * WITHOUT ANY WARRANTY; without even the implied warranty of |
---|
18 | 19 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
---|
19 | 20 | * General Public License for more details. |
---|
20 | | - * |
---|
21 | | - * You should have received a copy of the GNU General Public License |
---|
22 | | - * along with this program; if not, write to the Free Software |
---|
23 | | - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110, |
---|
24 | | - * USA |
---|
25 | 21 | * |
---|
26 | 22 | * The full GNU General Public License is included in this distribution |
---|
27 | 23 | * in the file called COPYING. |
---|
.. | .. |
---|
35 | 31 | * Copyright(c) 2005 - 2014 Intel Corporation. All rights reserved. |
---|
36 | 32 | * Copyright(c) 2013 - 2014 Intel Mobile Communications GmbH |
---|
37 | 33 | * Copyright(c) 2015 Intel Deutschland GmbH |
---|
| 34 | + * Copyright(c) 2018 - 2019 Intel Corporation |
---|
38 | 35 | * All rights reserved. |
---|
39 | 36 | * |
---|
40 | 37 | * Redistribution and use in source and binary forms, with or without |
---|
.. | .. |
---|
143 | 140 | * @nic_config: configure NIC, called before firmware is started. |
---|
144 | 141 | * May sleep |
---|
145 | 142 | * @wimax_active: invoked when WiMax becomes active. May sleep |
---|
146 | | - * @enter_d0i3: configure the fw to enter d0i3. return 1 to indicate d0i3 |
---|
147 | | - * entrance is aborted (e.g. due to held reference). May sleep. |
---|
148 | | - * @exit_d0i3: configure the fw to exit d0i3. May sleep. |
---|
149 | 143 | */ |
---|
150 | 144 | struct iwl_op_mode_ops { |
---|
151 | 145 | struct iwl_op_mode *(*start)(struct iwl_trans *trans, |
---|
.. | .. |
---|
167 | 161 | void (*cmd_queue_full)(struct iwl_op_mode *op_mode); |
---|
168 | 162 | void (*nic_config)(struct iwl_op_mode *op_mode); |
---|
169 | 163 | void (*wimax_active)(struct iwl_op_mode *op_mode); |
---|
170 | | - int (*enter_d0i3)(struct iwl_op_mode *op_mode); |
---|
171 | | - int (*exit_d0i3)(struct iwl_op_mode *op_mode); |
---|
172 | 164 | }; |
---|
173 | 165 | |
---|
174 | 166 | int iwl_opmode_register(const char *name, const struct iwl_op_mode_ops *ops); |
---|
.. | .. |
---|
183 | 175 | struct iwl_op_mode { |
---|
184 | 176 | const struct iwl_op_mode_ops *ops; |
---|
185 | 177 | |
---|
186 | | - char op_mode_specific[0] __aligned(sizeof(void *)); |
---|
| 178 | + char op_mode_specific[] __aligned(sizeof(void *)); |
---|
187 | 179 | }; |
---|
188 | 180 | |
---|
189 | 181 | static inline void iwl_op_mode_stop(struct iwl_op_mode *op_mode) |
---|
.. | .. |
---|
259 | 251 | { |
---|
260 | 252 | might_sleep(); |
---|
261 | 253 | op_mode->ops->wimax_active(op_mode); |
---|
262 | | -} |
---|
263 | | - |
---|
264 | | -static inline int iwl_op_mode_enter_d0i3(struct iwl_op_mode *op_mode) |
---|
265 | | -{ |
---|
266 | | - might_sleep(); |
---|
267 | | - |
---|
268 | | - if (!op_mode->ops->enter_d0i3) |
---|
269 | | - return 0; |
---|
270 | | - return op_mode->ops->enter_d0i3(op_mode); |
---|
271 | | -} |
---|
272 | | - |
---|
273 | | -static inline int iwl_op_mode_exit_d0i3(struct iwl_op_mode *op_mode) |
---|
274 | | -{ |
---|
275 | | - might_sleep(); |
---|
276 | | - |
---|
277 | | - if (!op_mode->ops->exit_d0i3) |
---|
278 | | - return 0; |
---|
279 | | - return op_mode->ops->exit_d0i3(op_mode); |
---|
280 | 254 | } |
---|
281 | 255 | |
---|
282 | 256 | #endif /* __iwl_op_mode_h__ */ |
---|