Compare commits

..

3 Commits

Author SHA1 Message Date
SpacingBat3
825556e195 Linux 6.18 compat: Drop hmac_sha256 symbol (#277)
* Linux 6.18 compat: Drop `hmac_sha256` symbol

It looks like it is a backwards compatibility code piece, I could find any
occurence of it outside of the core/crypto/sha256.{c,h} and it looks like
driver uses `hmac_sha256_vector` directly anyway that this function was a
(legacy?) wrapper for.

Signed-off-by: SpacingBat3 <spacingbat3@gmail.com>

* chore: update README.md

Signed-off-by: SpacingBat3 <spacingbat3@gmail.com>

---------

Signed-off-by: SpacingBat3 <spacingbat3@gmail.com>
2025-12-03 16:33:29 +09:00
471877314b Linux 6.17 compat: radio_idx
Signed-off-by: Rin Cat (鈴猫) <rincat@rincat.dev>
2025-10-09 00:50:24 +09:00
77a82dbac7 Linux 6.16 compat: more timers name change
Signed-off-by: Rin Cat (鈴猫) <rincat@rincat.dev>
2025-06-11 03:20:47 -04:00
5 changed files with 16 additions and 21 deletions

View File

@@ -1,6 +1,6 @@
# REALTEK RTL88x2B USB Linux Driver
**Current Driver Version**: 5.13.1-30
**Support Kernel**: 2.6.24 ~ 6.15 (with unofficial patches)
**Support Kernel**: 2.6.24 ~ 6.18 (with unofficial patches)
Linux in-tree rtw8822bu driver is a work in progress. Check [this](https://lore.kernel.org/lkml/20220518082318.3898514-1-s.hauer@pengutronix.de/) patchset.

View File

@@ -86,19 +86,3 @@ int hmac_sha256_vector(const u8 *key, size_t key_len, size_t num_elem,
_len[1] = SHA256_MAC_LEN;
return sha256_vector(2, _addr, _len, mac);
}
/**
* hmac_sha256 - HMAC-SHA256 over data buffer (RFC 2104)
* @key: Key for HMAC operations
* @key_len: Length of the key in bytes
* @data: Pointers to the data area
* @data_len: Length of the data area
* @mac: Buffer for the hash (32 bytes)
* Returns: 0 on success, -1 on failure
*/
int hmac_sha256(const u8 *key, size_t key_len, const u8 *data,
size_t data_len, u8 *mac)
{
return hmac_sha256_vector(key, key_len, 1, &data, &data_len, mac);
}

View File

@@ -13,8 +13,6 @@
int hmac_sha256_vector(const u8 *key, size_t key_len, size_t num_elem,
const u8 *addr[], const size_t *len, u8 *mac);
int hmac_sha256(const u8 *key, size_t key_len, const u8 *data,
size_t data_len, u8 *mac);
int sha256_prf(const u8 *key, size_t key_len, const char *label,
const u8 *data, size_t data_len, u8 *buf, size_t buf_len);
int sha256_prf_bits(const u8 *key, size_t key_len, const char *label,

View File

@@ -357,7 +357,9 @@ static inline void timer_hdl(struct timer_list *in_timer)
static inline void timer_hdl(unsigned long cntx)
#endif
{
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(4, 14, 0))
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(6, 16, 0))
_timer *ptimer = timer_container_of(ptimer, in_timer, timer);
#elif (LINUX_VERSION_CODE >= KERNEL_VERSION(4, 14, 0))
_timer *ptimer = from_timer(ptimer, in_timer, timer);
#else
_timer *ptimer = (_timer *)cntx;

View File

@@ -3592,7 +3592,12 @@ static void cfg80211_rtw_abort_scan(struct wiphy *wiphy,
}
#endif
static int cfg80211_rtw_set_wiphy_params(struct wiphy *wiphy, u32 changed)
static int cfg80211_rtw_set_wiphy_params(
struct wiphy *wiphy,
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(6, 17, 0))
int radio_idx,
#endif
u32 changed)
{
#if 0
struct iwm_priv *iwm = wiphy_to_iwm(wiphy);
@@ -4597,6 +4602,9 @@ static int cfg80211_rtw_set_txpower(struct wiphy *wiphy,
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3, 8, 0))
struct wireless_dev *wdev,
#endif
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(6, 17, 0))
int radio_idx,
#endif
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 36)) || defined(COMPAT_KERNEL_RELEASE)
enum nl80211_tx_power_setting type, int mbm)
#else
@@ -4659,6 +4667,9 @@ static int cfg80211_rtw_get_txpower(struct wiphy *wiphy,
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3, 8, 0))
struct wireless_dev *wdev,
#endif
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(6, 17, 0))
int radio_idx,
#endif
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(6, 14, 0))
unsigned int link_id,
#endif