.. | .. |
---|
8 | 8 | * Copyright(c) 2012 - 2014 Intel Corporation. All rights reserved. |
---|
9 | 9 | * Copyright(c) 2013 - 2015 Intel Mobile Communications GmbH |
---|
10 | 10 | * Copyright(c) 2016 - 2017 Intel Deutschland GmbH |
---|
11 | | - * Copyright (C) 2018 Intel Corporation |
---|
| 11 | + * Copyright(C) 2018 - 2020 Intel Corporation |
---|
12 | 12 | * |
---|
13 | 13 | * This program is free software; you can redistribute it and/or modify |
---|
14 | 14 | * it under the terms of version 2 of the GNU General Public License as |
---|
.. | .. |
---|
31 | 31 | * Copyright(c) 2012 - 2014 Intel Corporation. All rights reserved. |
---|
32 | 32 | * Copyright(c) 2013 - 2015 Intel Mobile Communications GmbH |
---|
33 | 33 | * Copyright(c) 2016 - 2017 Intel Deutschland GmbH |
---|
34 | | - * Copyright (C) 2018 Intel Corporation |
---|
| 34 | + * Copyright(C) 2018 - 2020 Intel Corporation |
---|
35 | 35 | * All rights reserved. |
---|
36 | 36 | * |
---|
37 | 37 | * Redistribution and use in source and binary forms, with or without |
---|
.. | .. |
---|
75 | 75 | NVM_ACCESS_COMPLETE = 0x0, |
---|
76 | 76 | |
---|
77 | 77 | /** |
---|
| 78 | + * @LARI_CONFIG_CHANGE: &struct iwl_lari_config_change_cmd |
---|
| 79 | + */ |
---|
| 80 | + LARI_CONFIG_CHANGE = 0x1, |
---|
| 81 | + |
---|
| 82 | + /** |
---|
78 | 83 | * @NVM_GET_INFO: |
---|
79 | 84 | * Command is &struct iwl_nvm_get_info, |
---|
80 | 85 | * response is &struct iwl_nvm_get_info_rsp |
---|
81 | 86 | */ |
---|
82 | 87 | NVM_GET_INFO = 0x2, |
---|
| 88 | + |
---|
| 89 | + /** |
---|
| 90 | + * @TAS_CONFIG: &struct iwl_tas_config_cmd |
---|
| 91 | + */ |
---|
| 92 | + TAS_CONFIG = 0x3, |
---|
| 93 | + |
---|
| 94 | + /** |
---|
| 95 | + * @PNVM_INIT_COMPLETE_NTFY: &struct iwl_pnvm_init_complete_ntfy |
---|
| 96 | + */ |
---|
| 97 | + PNVM_INIT_COMPLETE_NTFY = 0xFE, |
---|
83 | 98 | }; |
---|
84 | 99 | |
---|
85 | 100 | /** |
---|
.. | .. |
---|
233 | 248 | __le32 rx_chains; |
---|
234 | 249 | } __packed; /* REGULATORY_NVM_GET_INFO_PHY_SKU_SECTION_S_VER_1 */ |
---|
235 | 250 | |
---|
236 | | -#define IWL_NUM_CHANNELS (51) |
---|
| 251 | +#define IWL_NUM_CHANNELS_V1 51 |
---|
| 252 | +#define IWL_NUM_CHANNELS 110 |
---|
237 | 253 | |
---|
238 | 254 | /** |
---|
239 | 255 | * struct iwl_nvm_get_info_regulatory - regulatory information |
---|
.. | .. |
---|
241 | 257 | * @channel_profile: regulatory data of this channel |
---|
242 | 258 | * @reserved: reserved |
---|
243 | 259 | */ |
---|
244 | | -struct iwl_nvm_get_info_regulatory { |
---|
| 260 | +struct iwl_nvm_get_info_regulatory_v1 { |
---|
245 | 261 | __le32 lar_enabled; |
---|
246 | | - __le16 channel_profile[IWL_NUM_CHANNELS]; |
---|
| 262 | + __le16 channel_profile[IWL_NUM_CHANNELS_V1]; |
---|
247 | 263 | __le16 reserved; |
---|
248 | 264 | } __packed; /* REGULATORY_NVM_GET_INFO_REGULATORY_S_VER_1 */ |
---|
| 265 | + |
---|
| 266 | +/** |
---|
| 267 | + * struct iwl_nvm_get_info_regulatory - regulatory information |
---|
| 268 | + * @lar_enabled: is LAR enabled |
---|
| 269 | + * @n_channels: number of valid channels in the array |
---|
| 270 | + * @channel_profile: regulatory data of this channel |
---|
| 271 | + */ |
---|
| 272 | +struct iwl_nvm_get_info_regulatory { |
---|
| 273 | + __le32 lar_enabled; |
---|
| 274 | + __le32 n_channels; |
---|
| 275 | + __le32 channel_profile[IWL_NUM_CHANNELS]; |
---|
| 276 | +} __packed; /* REGULATORY_NVM_GET_INFO_REGULATORY_S_VER_2 */ |
---|
| 277 | + |
---|
| 278 | +/** |
---|
| 279 | + * struct iwl_nvm_get_info_rsp_v3 - response to get NVM data |
---|
| 280 | + * @general: general NVM data |
---|
| 281 | + * @mac_sku: data relating to MAC sku |
---|
| 282 | + * @phy_sku: data relating to PHY sku |
---|
| 283 | + * @regulatory: regulatory data |
---|
| 284 | + */ |
---|
| 285 | +struct iwl_nvm_get_info_rsp_v3 { |
---|
| 286 | + struct iwl_nvm_get_info_general general; |
---|
| 287 | + struct iwl_nvm_get_info_sku mac_sku; |
---|
| 288 | + struct iwl_nvm_get_info_phy phy_sku; |
---|
| 289 | + struct iwl_nvm_get_info_regulatory_v1 regulatory; |
---|
| 290 | +} __packed; /* REGULATORY_NVM_GET_INFO_RSP_API_S_VER_3 */ |
---|
249 | 291 | |
---|
250 | 292 | /** |
---|
251 | 293 | * struct iwl_nvm_get_info_rsp - response to get NVM data |
---|
.. | .. |
---|
259 | 301 | struct iwl_nvm_get_info_sku mac_sku; |
---|
260 | 302 | struct iwl_nvm_get_info_phy phy_sku; |
---|
261 | 303 | struct iwl_nvm_get_info_regulatory regulatory; |
---|
262 | | -} __packed; /* REGULATORY_NVM_GET_INFO_RSP_API_S_VER_3 */ |
---|
| 304 | +} __packed; /* REGULATORY_NVM_GET_INFO_RSP_API_S_VER_4 */ |
---|
263 | 305 | |
---|
264 | 306 | /** |
---|
265 | 307 | * struct iwl_nvm_access_complete_cmd - NVM_ACCESS commands are completed |
---|
.. | .. |
---|
268 | 310 | struct iwl_nvm_access_complete_cmd { |
---|
269 | 311 | __le32 reserved; |
---|
270 | 312 | } __packed; /* NVM_ACCESS_COMPLETE_CMD_API_S_VER_1 */ |
---|
271 | | - |
---|
272 | | -/** |
---|
273 | | - * struct iwl_mcc_update_cmd_v1 - Request the device to update geographic |
---|
274 | | - * regulatory profile according to the given MCC (Mobile Country Code). |
---|
275 | | - * The MCC is two letter-code, ascii upper case[A-Z] or '00' for world domain. |
---|
276 | | - * 'ZZ' MCC will be used to switch to NVM default profile; in this case, the |
---|
277 | | - * MCC in the cmd response will be the relevant MCC in the NVM. |
---|
278 | | - * @mcc: given mobile country code |
---|
279 | | - * @source_id: the source from where we got the MCC, see iwl_mcc_source |
---|
280 | | - * @reserved: reserved for alignment |
---|
281 | | - */ |
---|
282 | | -struct iwl_mcc_update_cmd_v1 { |
---|
283 | | - __le16 mcc; |
---|
284 | | - u8 source_id; |
---|
285 | | - u8 reserved; |
---|
286 | | -} __packed; /* LAR_UPDATE_MCC_CMD_API_S_VER_1 */ |
---|
287 | 313 | |
---|
288 | 314 | /** |
---|
289 | 315 | * struct iwl_mcc_update_cmd - Request the device to update geographic |
---|
.. | .. |
---|
306 | 332 | } __packed; /* LAR_UPDATE_MCC_CMD_API_S_VER_2 */ |
---|
307 | 333 | |
---|
308 | 334 | /** |
---|
309 | | - * struct iwl_mcc_update_resp_v1 - response to MCC_UPDATE_CMD. |
---|
310 | | - * Contains the new channel control profile map, if changed, and the new MCC |
---|
311 | | - * (mobile country code). |
---|
312 | | - * The new MCC may be different than what was requested in MCC_UPDATE_CMD. |
---|
313 | | - * @status: see &enum iwl_mcc_update_status |
---|
314 | | - * @mcc: the new applied MCC |
---|
315 | | - * @cap: capabilities for all channels which matches the MCC |
---|
316 | | - * @source_id: the MCC source, see iwl_mcc_source |
---|
317 | | - * @n_channels: number of channels in @channels_data (may be 14, 39, 50 or 51 |
---|
318 | | - * channels, depending on platform) |
---|
319 | | - * @channels: channel control data map, DWORD for each channel. Only the first |
---|
320 | | - * 16bits are used. |
---|
321 | | - */ |
---|
322 | | -struct iwl_mcc_update_resp_v1 { |
---|
323 | | - __le32 status; |
---|
324 | | - __le16 mcc; |
---|
325 | | - u8 cap; |
---|
326 | | - u8 source_id; |
---|
327 | | - __le32 n_channels; |
---|
328 | | - __le32 channels[0]; |
---|
329 | | -} __packed; /* LAR_UPDATE_MCC_CMD_RESP_S_VER_1 */ |
---|
330 | | - |
---|
331 | | -/** |
---|
332 | 335 | * enum iwl_geo_information - geographic information. |
---|
333 | 336 | * @GEO_NO_INFO: no special info for this geo profile. |
---|
334 | 337 | * @GEO_WMM_ETSI_5GHZ_INFO: this geo profile limits the WMM params |
---|
.. | .. |
---|
340 | 343 | }; |
---|
341 | 344 | |
---|
342 | 345 | /** |
---|
343 | | - * struct iwl_mcc_update_resp - response to MCC_UPDATE_CMD. |
---|
| 346 | + * struct iwl_mcc_update_resp_v3 - response to MCC_UPDATE_CMD. |
---|
344 | 347 | * Contains the new channel control profile map, if changed, and the new MCC |
---|
345 | 348 | * (mobile country code). |
---|
346 | 349 | * The new MCC may be different than what was requested in MCC_UPDATE_CMD. |
---|
.. | .. |
---|
348 | 351 | * @mcc: the new applied MCC |
---|
349 | 352 | * @cap: capabilities for all channels which matches the MCC |
---|
350 | 353 | * @source_id: the MCC source, see iwl_mcc_source |
---|
351 | | - * @time: time elapsed from the MCC test start (in 30 seconds TU) |
---|
| 354 | + * @time: time elapsed from the MCC test start (in units of 30 seconds) |
---|
352 | 355 | * @geo_info: geographic specific profile information |
---|
353 | 356 | * see &enum iwl_geo_information. |
---|
354 | | - * @n_channels: number of channels in @channels_data (may be 14, 39, 50 or 51 |
---|
355 | | - * channels, depending on platform) |
---|
| 357 | + * @n_channels: number of channels in @channels_data. |
---|
356 | 358 | * @channels: channel control data map, DWORD for each channel. Only the first |
---|
357 | 359 | * 16bits are used. |
---|
358 | 360 | */ |
---|
359 | | -struct iwl_mcc_update_resp { |
---|
| 361 | +struct iwl_mcc_update_resp_v3 { |
---|
360 | 362 | __le32 status; |
---|
361 | 363 | __le16 mcc; |
---|
362 | 364 | u8 cap; |
---|
.. | .. |
---|
364 | 366 | __le16 time; |
---|
365 | 367 | __le16 geo_info; |
---|
366 | 368 | __le32 n_channels; |
---|
367 | | - __le32 channels[0]; |
---|
| 369 | + __le32 channels[]; |
---|
368 | 370 | } __packed; /* LAR_UPDATE_MCC_CMD_RESP_S_VER_3 */ |
---|
| 371 | + |
---|
| 372 | +/** |
---|
| 373 | + * struct iwl_mcc_update_resp - response to MCC_UPDATE_CMD. |
---|
| 374 | + * Contains the new channel control profile map, if changed, and the new MCC |
---|
| 375 | + * (mobile country code). |
---|
| 376 | + * The new MCC may be different than what was requested in MCC_UPDATE_CMD. |
---|
| 377 | + * @status: see &enum iwl_mcc_update_status |
---|
| 378 | + * @mcc: the new applied MCC |
---|
| 379 | + * @cap: capabilities for all channels which matches the MCC |
---|
| 380 | + * @time: time elapsed from the MCC test start (in units of 30 seconds) |
---|
| 381 | + * @geo_info: geographic specific profile information |
---|
| 382 | + * see &enum iwl_geo_information. |
---|
| 383 | + * @source_id: the MCC source, see iwl_mcc_source |
---|
| 384 | + * @reserved: for four bytes alignment. |
---|
| 385 | + * @n_channels: number of channels in @channels_data. |
---|
| 386 | + * @channels: channel control data map, DWORD for each channel. Only the first |
---|
| 387 | + * 16bits are used. |
---|
| 388 | + */ |
---|
| 389 | +struct iwl_mcc_update_resp { |
---|
| 390 | + __le32 status; |
---|
| 391 | + __le16 mcc; |
---|
| 392 | + __le16 cap; |
---|
| 393 | + __le16 time; |
---|
| 394 | + __le16 geo_info; |
---|
| 395 | + u8 source_id; |
---|
| 396 | + u8 reserved[3]; |
---|
| 397 | + __le32 n_channels; |
---|
| 398 | + __le32 channels[]; |
---|
| 399 | +} __packed; /* LAR_UPDATE_MCC_CMD_RESP_S_VER_4 */ |
---|
369 | 400 | |
---|
370 | 401 | /** |
---|
371 | 402 | * struct iwl_mcc_chub_notif - chub notifies of mcc change |
---|
.. | .. |
---|
415 | 446 | MCC_SOURCE_GETTING_MCC_TEST_MODE = 0x11, |
---|
416 | 447 | }; |
---|
417 | 448 | |
---|
| 449 | +#define IWL_TAS_BLACK_LIST_MAX 16 |
---|
| 450 | +/** |
---|
| 451 | + * struct iwl_tas_config_cmd - configures the TAS |
---|
| 452 | + * @block_list_size: size of relevant field in block_list_array |
---|
| 453 | + * @block_list_array: block list countries (without TAS) |
---|
| 454 | + */ |
---|
| 455 | +struct iwl_tas_config_cmd { |
---|
| 456 | + __le32 block_list_size; |
---|
| 457 | + __le32 block_list_array[IWL_TAS_BLACK_LIST_MAX]; |
---|
| 458 | +} __packed; /* TAS_CONFIG_CMD_API_S_VER_2 */ |
---|
| 459 | + |
---|
| 460 | +/** |
---|
| 461 | + * enum iwl_lari_configs - bit masks for the various LARI config operations |
---|
| 462 | + * @LARI_CONFIG_DISABLE_11AC_UKRAINE_MSK: disable 11ac in ukraine |
---|
| 463 | + * @LARI_CONFIG_CHANGE_ETSI_TO_PASSIVE_MSK: ETSI 5.8GHz SRD passive scan |
---|
| 464 | + * @LARI_CONFIG_CHANGE_ETSI_TO_DISABLED_MSK: ETSI 5.8GHz SRD disabled |
---|
| 465 | + * @LARI_CONFIG_ENABLE_5G2_IN_INDONESIA_MSK: enable 5.15/5.35GHz bands in |
---|
| 466 | + * Indonesia |
---|
| 467 | + */ |
---|
| 468 | +enum iwl_lari_config_masks { |
---|
| 469 | + LARI_CONFIG_DISABLE_11AC_UKRAINE_MSK = BIT(0), |
---|
| 470 | + LARI_CONFIG_CHANGE_ETSI_TO_PASSIVE_MSK = BIT(1), |
---|
| 471 | + LARI_CONFIG_CHANGE_ETSI_TO_DISABLED_MSK = BIT(2), |
---|
| 472 | + LARI_CONFIG_ENABLE_5G2_IN_INDONESIA_MSK = BIT(3), |
---|
| 473 | +}; |
---|
| 474 | + |
---|
| 475 | +/** |
---|
| 476 | + * struct iwl_lari_config_change_cmd - change LARI configuration |
---|
| 477 | + * @config_bitmap: bit map of the config commands. each bit will trigger a |
---|
| 478 | + * different predefined FW config operation |
---|
| 479 | + */ |
---|
| 480 | +struct iwl_lari_config_change_cmd { |
---|
| 481 | + __le32 config_bitmap; |
---|
| 482 | +} __packed; /* LARI_CHANGE_CONF_CMD_S_VER_1 */ |
---|
| 483 | + |
---|
| 484 | +/** |
---|
| 485 | + * struct iwl_pnvm_init_complete_ntfy - PNVM initialization complete |
---|
| 486 | + * @status: PNVM image loading status |
---|
| 487 | + */ |
---|
| 488 | +struct iwl_pnvm_init_complete_ntfy { |
---|
| 489 | + __le32 status; |
---|
| 490 | +} __packed; /* PNVM_INIT_COMPLETE_NTFY_S_VER_1 */ |
---|
| 491 | + |
---|
418 | 492 | #endif /* __iwl_fw_api_nvm_reg_h__ */ |
---|