2008/7/17 Bruno Randolf <[EMAIL PROTECTED]>:
> hi!
>
> this is just a preview and a RFC. i would like to know what you think about 
> the
> general approach and will send a cleaned up version for final review later.
>

I fully agree, i wanted to clean this stuff for a long time (that's
why i marked it as a TODO).

> i am trying to cleanup the rates structures for ath5k. there was a lot of
> useless junk and complication in the code which was not used.
>
> i replaced that all with a static ieee80211_rate array which we index 
> according
> to the band. no conversion between ath5k_rates and ieee80211_rates has to be
> done any more.
>

+++

> what i left out is control_rates. it would be good if we could get that
> information from mac80211 somehow but if that is not possible we can set up a
> small table for them. they are the same for a given rate in any mode.
>

Control_rates is not difficult to implement, it's used together with
ack rate stuff...

> i also left out XR rates in the table. will we support XR already or anytime
> soon?
>

Haven't worked on XR yet and i don't plan working on it anytime soon...

> also i think i figured a way for reverse conversion from hw code to rate 
> index.
>

Have you tested it ?

> bruno
>

>  /* adding this flag to rate_code enables short preamble, see ar5212_reg.h */
>  #define AR5K_SET_SHORT_PREAMBLE 0x04
>

Can we please make use of this flag ? (see below)

> +/* B */
> +#define ATH5K_RATE_CODE_1M     27
> +#define ATH5K_RATE_CODE_2M     26
> +#define ATH5K_RATE_CODE_5_5M   25
> +#define ATH5K_RATE_CODE_11M    24
> +/* A and G */
> +#define ATH5K_RATE_CODE_6M     11
> +#define ATH5K_RATE_CODE_9M     15
> +#define ATH5K_RATE_CODE_12M    10
> +#define ATH5K_RATE_CODE_18M    14
> +#define ATH5K_RATE_CODE_24M    9
> +#define ATH5K_RATE_CODE_36M    13
> +#define ATH5K_RATE_CODE_48M    8
> +#define ATH5K_RATE_CODE_54M    12
> +/* XR */
> +#define ATH5K_RATE_CODE_XR_500K        7
> +#define ATH5K_RATE_CODE_XR_1M  2
> +#define ATH5K_RATE_CODE_XR_2M  6
> +#define ATH5K_RATE_CODE_XR_3M  1
>

I think it's better if we have them in hex (it's a hw value)...

> +static struct ieee80211_rate ath5k_rates[] = {
> +       { .bitrate = 10,
> +         .hw_value = ATH5K_RATE_CODE_1M, },
> +       { .bitrate = 20,
> +         .hw_value = ATH5K_RATE_CODE_2M,
> +         .hw_value_short = ATH5K_RATE_CODE_2M,
> +         .flags = IEEE80211_RATE_SHORT_PREAMBLE },

I mean here, we should have ATH5K_RATE_CODE_2M | AR5K_SET_SHORT_PREAMBLE...




-- 
GPG ID: 0xD21DB2DB
As you read this post global entropy rises. Have Fun ;-)
Nick
_______________________________________________
ath5k-devel mailing list
ath5k-devel@lists.ath5k.org
https://lists.ath5k.org/mailman/listinfo/ath5k-devel

Reply via email to