Link: https://lore.kernel.org/r/20260217200002.683975158@linuxfoundation.org Tested-by: Florian Fainelli <florian.fainelli@broadcom.com> Tested-by: Takeshi Ogasawara <takeshi.ogasawara@futuring-girl.com> Tested-by: Peter Schneider <pschneider1968@googlemail.com> Tested-by: Jon Hunter <jonathanh@nvidia.com> Tested-by: Salvatore Bonaccorso <carnil@debian.org> Tested-by: Brett A C Sheffield <bacs@librecast.net> Tested-by: Mark Brown <broonie@kernel.org> Tested-by: Luna Jernberg <droidbittin@gmail.com> Tested-by: Ronald Warsow <rwarsow@gmx.de> Tested-by: Justin M. Forbes <jforbes@fedoraproject.org> Tested-by: Ron Economos <re@w6rz.net> Tested-by: Miguel Ojeda <ojeda@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
41 lines
1.2 KiB
C
41 lines
1.2 KiB
C
/* SPDX-License-Identifier: GPL-2.0 OR BSD-3-Clause */
|
|
/* Copyright(c) 2018-2019 Realtek Corporation
|
|
*/
|
|
|
|
#ifndef __RTW_SEC_H_
|
|
#define __RTW_SEC_H_
|
|
|
|
#define RTW_SEC_CMD_REG 0x670
|
|
#define RTW_SEC_WRITE_REG 0x674
|
|
#define RTW_SEC_READ_REG 0x678
|
|
#define RTW_SEC_CONFIG 0x680
|
|
|
|
#define RTW_SEC_CAM_ENTRY_SHIFT 3
|
|
#define RTW_SEC_DEFAULT_KEY_NUM 4
|
|
#define RTW_SEC_CMD_WRITE_ENABLE BIT(16)
|
|
#define RTW_SEC_CMD_CLEAR BIT(30)
|
|
#define RTW_SEC_CMD_POLLING BIT(31)
|
|
|
|
#define RTW_SEC_TX_UNI_USE_DK BIT(0)
|
|
#define RTW_SEC_RX_UNI_USE_DK BIT(1)
|
|
#define RTW_SEC_TX_DEC_EN BIT(2)
|
|
#define RTW_SEC_RX_DEC_EN BIT(3)
|
|
#define RTW_SEC_TX_BC_USE_DK BIT(6)
|
|
#define RTW_SEC_RX_BC_USE_DK BIT(7)
|
|
|
|
#define RTW_SEC_ENGINE_EN BIT(9)
|
|
|
|
int rtw_sec_get_free_cam(struct rtw_sec_desc *sec);
|
|
void rtw_sec_write_cam(struct rtw_dev *rtwdev,
|
|
struct rtw_sec_desc *sec,
|
|
struct ieee80211_sta *sta,
|
|
struct ieee80211_key_conf *key,
|
|
u8 hw_key_type, u8 hw_key_idx);
|
|
void rtw_sec_clear_cam(struct rtw_dev *rtwdev,
|
|
struct rtw_sec_desc *sec,
|
|
u8 hw_key_idx);
|
|
u8 rtw_sec_cam_pg_backup(struct rtw_dev *rtwdev, u8 *used_cam);
|
|
void rtw_sec_enable_sec_engine(struct rtw_dev *rtwdev);
|
|
|
|
#endif
|