rt2x00: Use ieee80211_channel_to_frequency()

No need to perform the calculation ourselves when
wireless provides a helper function for it.

Signed-off-by: Ivo van Doorn <IvDoorn@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
This commit is contained in:
Ivo van Doorn 2008-02-03 15:52:45 +01:00 committed by John W. Linville
parent f5507ce90b
commit f2a3c7f5c8
1 changed files with 1 additions and 4 deletions

View File

@ -827,10 +827,7 @@ static void rt2x00lib_channel(struct ieee80211_channel *entry,
const int channel, const int tx_power,
const int value)
{
if (channel <= 14)
entry->center_freq = 2407 + (5 * channel);
else
entry->center_freq = 5000 + (5 * channel);
entry->center_freq = ieee80211_channel_to_frequency(channel);
entry->hw_value = value;
entry->max_power = tx_power;
entry->max_antenna_gain = 0xff;