Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 304385
b: refs/heads/master
c: fdf3480
h: refs/heads/master
i:
  304383: 2ae1124
v: v3
  • Loading branch information
Dan Carpenter authored and Greg Kroah-Hartman committed Apr 18, 2012
1 parent 0ca7559 commit 5d00200
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 7 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 1ae5062a33be13a72d37ec46808490d471b0c1d3
refs/heads/master: fdf3480032fc900075c4bdb18271150aaa8a53a0
11 changes: 5 additions & 6 deletions trunk/drivers/staging/wlags49_h2/wl_util.c
Original file line number Diff line number Diff line change
Expand Up @@ -98,8 +98,7 @@
******************************************************************************/

/* A matrix which maps channels to frequencies */
#define MAX_CHAN_FREQ_MAP_ENTRIES 50
static const long chan_freq_list[][MAX_CHAN_FREQ_MAP_ENTRIES] =
static const long chan_freq_list[][2] =
{
{1,2412},
{2,2417},
Expand Down Expand Up @@ -846,7 +845,7 @@ int wl_is_a_valid_chan( int channel )
}

/* Iterate through the matrix and retrieve the frequency */
for( i = 0; i < MAX_CHAN_FREQ_MAP_ENTRIES; i++ ) {
for( i = 0; i < ARRAY_SIZE(chan_freq_list); i++ ) {
if( chan_freq_list[i][0] == channel ) {
return 1;
}
Expand Down Expand Up @@ -884,7 +883,7 @@ int wl_is_a_valid_freq( long frequency )


/* Iterate through the matrix and retrieve the channel */
for( i = 0; i < MAX_CHAN_FREQ_MAP_ENTRIES; i++ ) {
for( i = 0; i < ARRAY_SIZE(chan_freq_list); i++ ) {
if( chan_freq_list[i][1] == frequency ) {
return 1;
}
Expand Down Expand Up @@ -927,7 +926,7 @@ long wl_get_freq_from_chan( int channel )
}

/* Iterate through the matrix and retrieve the frequency */
for( i = 0; i < MAX_CHAN_FREQ_MAP_ENTRIES; i++ ) {
for( i = 0; i < ARRAY_SIZE(chan_freq_list); i++ ) {
if( chan_freq_list[i][0] == channel ) {
return chan_freq_list[i][1];
}
Expand Down Expand Up @@ -965,7 +964,7 @@ int wl_get_chan_from_freq( long frequency )


/* Iterate through the matrix and retrieve the channel */
for( i = 0; i < MAX_CHAN_FREQ_MAP_ENTRIES; i++ ) {
for( i = 0; i < ARRAY_SIZE(chan_freq_list); i++ ) {
if( chan_freq_list[i][1] == frequency ) {
return chan_freq_list[i][0];
}
Expand Down

0 comments on commit 5d00200

Please sign in to comment.