linux/drivers/net/wireless/morsemicro/mm81x/rc.h
Lachlan Hodges b1906cea00 wifi: mm81x: add mm81x Wi-Fi HaLow driver
mm81x is the first Wi-Fi HaLow driver to support the Morse Micro mm81x
chip family via USB and SDIO.

S1G support in the kernel is only new, and as a result this driver has
been scoped to be simple and only support station and AP interface.
The Wi-Fi specific features only cover the minimum required for basic
use such as powersave, aggregation, rate control and so on. The driver
will be extended into the future as S1G support for operations such as
ACS, channel switching and so on are added into the wireless stack.

The driver has been build tested on a long list of architectures and
compilers via Intels LKP.

The driver currently supports IEEE80211-2024 US channels only, with
AU 2020 also available. In order for this to be expanded additional
non-trivial kernel work is required which will begin once the
driver is upstream.

The driver has had many authors who are listed below in
alphabetical order:

Co-developed-by: Andrew Pope <andrew.pope@morsemicro.com>
Signed-off-by: Andrew Pope <andrew.pope@morsemicro.com>
Co-developed-by: Arien Judge <arien.judge@morsemicro.com>
Signed-off-by: Arien Judge <arien.judge@morsemicro.com>
Co-developed-by: Ayman Grais <ayman.grais@morsemicro.com>
Signed-off-by: Ayman Grais <ayman.grais@morsemicro.com>
Co-developed-by: Bassem Dawood <bassem@morsemicro.com>
Signed-off-by: Bassem Dawood <bassem@morsemicro.com>
Co-developed-by: Chetan Mistry <chetan.mistry@morsemicro.com>
Signed-off-by: Chetan Mistry <chetan.mistry@morsemicro.com>
Co-developed-by: Dan Callaghan <dan.callaghan@morsemicro.com>
Signed-off-by: Dan Callaghan <dan.callaghan@morsemicro.com>
Co-developed-by: James Herbert <james.herbert@morsemicro.com>
Signed-off-by: James Herbert <james.herbert@morsemicro.com>
Co-developed-by: Sahand Maleki <sahand.maleki@morsemicro.com>
Signed-off-by: Sahand Maleki <sahand.maleki@morsemicro.com>
Co-developed-by: Simon Wadsworth <simon@morsemicro.com>
Signed-off-by: Simon Wadsworth <simon@morsemicro.com>
Signed-off-by: Lachlan Hodges <lachlan.hodges@morsemicro.com>
2026-07-08 12:03:50 +10:00

52 lines
1.4 KiB
C

/* SPDX-License-Identifier: GPL-2.0-only */
/*
* Copyright (c) 2017-2026 Morse Micro
*/
#ifndef _MM81X_RC_H_
#define _MM81X_RC_H_
#include <linux/list.h>
#include <linux/workqueue.h>
#include "core.h"
#include "mmrc.h"
struct mm81x_vif;
#define INIT_MAX_RATES_NUM 4
struct mm81x_rc {
/* Serialise rate control queue manipulation and timer functions */
spinlock_t lock;
struct list_head stas;
struct timer_list timer;
struct work_struct work;
struct mm81x *mors;
};
struct mm81x_rc_sta {
struct mmrc_table *tb;
struct list_head list;
unsigned long last_update;
};
void mm81x_rc_init(struct mm81x *mors);
void mm81x_rc_deinit(struct mm81x *mors);
int mm81x_rc_sta_add(struct mm81x *mors, struct ieee80211_vif *vif,
struct ieee80211_sta *sta);
void mm81x_rc_sta_remove(struct mm81x *mors, struct ieee80211_sta *sta);
void mm81x_rc_sta_fill_tx_rates(struct mm81x *mors,
struct mm81x_skb_tx_info *tx_info,
struct sk_buff *skb, struct ieee80211_sta *sta,
int tx_bw, bool rts_allowed);
void mm81x_rc_sta_feedback_rates(struct mm81x *mors, struct sk_buff *skb,
struct ieee80211_sta *sta,
struct mm81x_skb_tx_status *tx_sts,
int tx_attempts);
void mm81x_rc_sta_state_check(struct mm81x *mors, struct ieee80211_vif *vif,
struct ieee80211_sta *sta,
enum ieee80211_sta_state old_state,
enum ieee80211_sta_state new_state);
#endif /* !_MM81X_RC_H_ */