Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
linux
Commits
d9468289
Commit
d9468289
authored
Jul 18, 2003
by
Arnaldo Carvalho de Melo
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
o wl3501: cleanup types
parent
1cdf8ca1
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
208 additions
and
207 deletions
+208
-207
drivers/net/wireless/wl3501.h
drivers/net/wireless/wl3501.h
+173
-173
drivers/net/wireless/wl3501_cs.c
drivers/net/wireless/wl3501_cs.c
+35
-34
No files found.
drivers/net/wireless/wl3501.h
View file @
d9468289
...
@@ -207,147 +207,147 @@ enum wl3501_status {
...
@@ -207,147 +207,147 @@ enum wl3501_status {
struct
wl3501_tx_hdr
{
struct
wl3501_tx_hdr
{
u16
tx_cnt
;
u16
tx_cnt
;
u
nsigned
char
sync
[
16
];
u
8
sync
[
16
];
u16
sfd
;
u16
sfd
;
u
nsigned
char
signal
;
u
8
signal
;
u
nsigned
char
service
;
u
8
service
;
u16
len
;
u16
len
;
u16
crc16
;
u16
crc16
;
u16
frame_ctrl
;
u16
frame_ctrl
;
u16
duration_id
;
u16
duration_id
;
u
nsigned
char
addr1
[
ETH_ALEN
];
u
8
addr1
[
ETH_ALEN
];
u
nsigned
char
addr2
[
ETH_ALEN
];
u
8
addr2
[
ETH_ALEN
];
u
nsigned
char
addr3
[
ETH_ALEN
];
u
8
addr3
[
ETH_ALEN
];
u16
seq_ctrl
;
u16
seq_ctrl
;
u
nsigned
char
addr4
[
ETH_ALEN
];
u
8
addr4
[
ETH_ALEN
];
};
};
struct
wl3501_rx_hdr
{
struct
wl3501_rx_hdr
{
u16
rx_next_blk
;
u16
rx_next_blk
;
u16
rc_next_frame_blk
;
u16
rc_next_frame_blk
;
u
nsigned
char
rx_blk_ctrl
;
u
8
rx_blk_ctrl
;
u
nsigned
char
rx_next_frame
;
u
8
rx_next_frame
;
u
nsigned
char
rx_next_frame1
;
u
8
rx_next_frame1
;
u
nsigned
char
rssi
;
u
8
rssi
;
unsigned
char
time
[
8
];
char
time
[
8
];
u
nsigned
char
signal
;
u
8
signal
;
u
nsigned
char
service
;
u
8
service
;
u16
len
;
u16
len
;
u16
crc16
;
u16
crc16
;
u16
frame_ctrl
;
u16
frame_ctrl
;
u16
duration
;
u16
duration
;
u
nsigned
char
addr1
[
ETH_ALEN
];
u
8
addr1
[
ETH_ALEN
];
u
nsigned
char
addr2
[
ETH_ALEN
];
u
8
addr2
[
ETH_ALEN
];
u
nsigned
char
addr3
[
ETH_ALEN
];
u
8
addr3
[
ETH_ALEN
];
u16
seq
;
u16
seq
;
u
nsigned
char
addr4
[
ETH_ALEN
];
u
8
addr4
[
ETH_ALEN
];
};
};
struct
wl3501_start_req
{
struct
wl3501_start_req
{
u16
next_blk
;
u16
next_blk
;
u
nsigned
char
sig_id
;
u
8
sig_id
;
u
nsigned
char
bss_type
;
u
8
bss_type
;
u16
beacon_period
;
u16
beacon_period
;
u16
dtim_period
;
u16
dtim_period
;
u16
probe_delay
;
u16
probe_delay
;
u16
cap_info
;
u16
cap_info
;
unsigned
char
ssid
[
WL3501_ESSID_MAX_LEN
];
char
ssid
[
WL3501_ESSID_MAX_LEN
];
u
nsigned
char
bss_basic_rate_set
[
10
];
u
8
bss_basic_rate_set
[
10
];
u
nsigned
char
operational_rate_set
[
10
];
u
8
operational_rate_set
[
10
];
u
nsigned
char
cf_pset
[
8
];
u
8
cf_pset
[
8
];
u
nsigned
char
phy_pset
[
3
];
u
8
phy_pset
[
3
];
u
nsigned
char
ibss_pset
[
4
];
u
8
ibss_pset
[
4
];
};
};
struct
wl3501_assoc_req
{
struct
wl3501_assoc_req
{
u16
next_blk
;
u16
next_blk
;
u
nsigned
char
sig_id
;
u
8
sig_id
;
u
nsigned
char
reserved
;
u
8
reserved
;
u16
timeout
;
u16
timeout
;
u16
cap_info
;
u16
cap_info
;
u16
listen_interval
;
u16
listen_interval
;
u
nsigned
char
mac_addr
[
ETH_ALEN
];
u
8
mac_addr
[
ETH_ALEN
];
};
};
struct
wl3501_assoc_confirm
{
struct
wl3501_assoc_confirm
{
u16
next_blk
;
u16
next_blk
;
u
nsigned
char
sig_id
;
u
8
sig_id
;
u
nsigned
char
reserved
;
u
8
reserved
;
u16
status
;
u16
status
;
};
};
struct
wl3501_assoc_ind
{
struct
wl3501_assoc_ind
{
u16
next_blk
;
u16
next_blk
;
u
nsigned
char
sig_id
;
u
8
sig_id
;
u
nsigned
char
mac_addr
[
ETH_ALEN
];
u
8
mac_addr
[
ETH_ALEN
];
};
};
struct
wl3501_auth_req
{
struct
wl3501_auth_req
{
u16
next_blk
;
u16
next_blk
;
u
nsigned
char
sig_id
;
u
8
sig_id
;
u
nsigned
char
reserved
;
u
8
reserved
;
u16
type
;
u16
type
;
u16
timeout
;
u16
timeout
;
u
nsigned
char
mac_addr
[
ETH_ALEN
];
u
8
mac_addr
[
ETH_ALEN
];
};
};
struct
wl3501_auth_confirm
{
struct
wl3501_auth_confirm
{
u16
next_blk
;
u16
next_blk
;
u
nsigned
char
sig_id
;
u
8
sig_id
;
u
nsigned
char
reserved
;
u
8
reserved
;
u16
type
;
u16
type
;
u16
status
;
u16
status
;
u
nsigned
char
mac_addr
[
ETH_ALEN
];
u
8
mac_addr
[
ETH_ALEN
];
};
};
struct
wl3501_get_req
{
struct
wl3501_get_req
{
u16
next_blk
;
u16
next_blk
;
u
nsigned
char
sig_id
;
u
8
sig_id
;
u
nsigned
char
reserved
;
u
8
reserved
;
u16
mib_attrib
;
u16
mib_attrib
;
};
};
struct
wl3501_get_confirm
{
struct
wl3501_get_confirm
{
u16
next_blk
;
u16
next_blk
;
u
nsigned
char
sig_id
;
u
8
sig_id
;
u
nsigned
char
reserved
;
u
8
reserved
;
u16
mib_status
;
u16
mib_status
;
u16
mib_attrib
;
u16
mib_attrib
;
u
nsigned
char
mib_value
[
100
];
u
8
mib_value
[
100
];
};
};
struct
wl3501_join_req
{
struct
wl3501_join_req
{
u16
next_blk
;
u16
next_blk
;
u
nsigned
char
sig_id
;
u
8
sig_id
;
u
nsigned
char
reserved
;
u
8
reserved
;
u
nsigned
char
operational_rate_set
[
10
];
u
8
operational_rate_set
[
10
];
u16
reserved2
;
u16
reserved2
;
u16
timeout
;
u16
timeout
;
u16
probe_delay
;
u16
probe_delay
;
u
nsigned
char
timestamp
[
8
];
u
8
timestamp
[
8
];
u
nsigned
char
local_time
[
8
];
u
8
local_time
[
8
];
u16
beacon_period
;
u16
beacon_period
;
u16
dtim_period
;
u16
dtim_period
;
u16
cap_info
;
u16
cap_info
;
u
nsigned
char
bss_type
;
u
8
bss_type
;
u
nsigned
char
bssid
[
ETH_ALEN
];
u
8
bssid
[
ETH_ALEN
];
unsigned
char
ssid
[
WL3501_ESSID_MAX_LEN
];
char
ssid
[
WL3501_ESSID_MAX_LEN
];
u
nsigned
char
phy_pset
[
3
];
u
8
phy_pset
[
3
];
u
nsigned
char
cf_pset
[
8
];
u
8
cf_pset
[
8
];
u
nsigned
char
ibss_pset
[
4
];
u
8
ibss_pset
[
4
];
u
nsigned
char
bss_basic_rate_set
[
10
];
u
8
bss_basic_rate_set
[
10
];
};
};
struct
wl3501_join_confirm
{
struct
wl3501_join_confirm
{
u16
next_blk
;
u16
next_blk
;
u
nsigned
char
sig_id
;
u
8
sig_id
;
u
nsigned
char
reserved
;
u
8
reserved
;
u16
status
;
u16
status
;
};
};
struct
wl3501_pwr_mgmt_req
{
struct
wl3501_pwr_mgmt_req
{
u16
next_blk
;
u16
next_blk
;
u
nsigned
char
sig_id
;
u
8
sig_id
;
u8
pwr_save
;
u8
pwr_save
;
u8
wake_up
;
u8
wake_up
;
u8
receive_dtims
;
u8
receive_dtims
;
...
@@ -355,89 +355,89 @@ struct wl3501_pwr_mgmt_req {
...
@@ -355,89 +355,89 @@ struct wl3501_pwr_mgmt_req {
struct
wl3501_pwr_mgmt_confirm
{
struct
wl3501_pwr_mgmt_confirm
{
u16
next_blk
;
u16
next_blk
;
u
nsigned
char
sig_id
;
u
8
sig_id
;
u
nsigned
char
reserved
;
u
8
reserved
;
u16
status
;
u16
status
;
};
};
struct
wl3501_scan_req
{
struct
wl3501_scan_req
{
u16
next_blk
;
u16
next_blk
;
u
nsigned
char
sig_id
;
u
8
sig_id
;
u
nsigned
char
bss_type
;
u
8
bss_type
;
u16
probe_delay
;
u16
probe_delay
;
u16
min_chan_time
;
u16
min_chan_time
;
u16
max_chan_time
;
u16
max_chan_time
;
u
nsigned
char
chan_list
[
14
];
u
8
chan_list
[
14
];
u
nsigned
char
bssid
[
ETH_ALEN
];
u
8
bssid
[
ETH_ALEN
];
unsigned
char
ssid
[
WL3501_ESSID_MAX_LEN
];
char
ssid
[
WL3501_ESSID_MAX_LEN
];
enum
wl3501_scan_type
scan_type
;
enum
wl3501_scan_type
scan_type
;
};
};
struct
wl3501_scan_confirm
{
struct
wl3501_scan_confirm
{
u16
next_blk
;
u16
next_blk
;
u
nsigned
char
sig_id
;
u
8
sig_id
;
u
nsigned
char
reserved
;
u
8
reserved
;
u16
status
;
u16
status
;
unsigned
char
timestamp
[
8
];
char
timestamp
[
8
];
unsigned
char
localtime
[
8
];
char
localtime
[
8
];
u16
beacon_period
;
u16
beacon_period
;
u16
dtim_period
;
u16
dtim_period
;
u16
cap_info
;
u16
cap_info
;
u
nsigned
char
bss_type
;
u
8
bss_type
;
u
nsigned
char
bssid
[
ETH_ALEN
];
u
8
bssid
[
ETH_ALEN
];
unsigned
char
ssid
[
WL3501_ESSID_MAX_LEN
];
char
ssid
[
WL3501_ESSID_MAX_LEN
];
u
nsigned
char
phy_pset
[
3
];
u
8
phy_pset
[
3
];
u
nsigned
char
cf_pset
[
8
];
u
8
cf_pset
[
8
];
u
nsigned
char
ibss_pset
[
4
];
u
8
ibss_pset
[
4
];
u
nsigned
char
bss_basic_rate_set
[
10
];
u
8
bss_basic_rate_set
[
10
];
u
nsigned
char
rssi
;
u
8
rssi
;
};
};
struct
wl3501_start_confirm
{
struct
wl3501_start_confirm
{
u16
next_blk
;
u16
next_blk
;
u
nsigned
char
sig_id
;
u
8
sig_id
;
u
nsigned
char
reserved
;
u
8
reserved
;
u16
status
;
u16
status
;
};
};
struct
wl3501_md_req
{
struct
wl3501_md_req
{
u16
next_blk
;
u16
next_blk
;
u
nsigned
char
sig_id
;
u
8
sig_id
;
u
nsigned
char
routing
;
u
8
routing
;
u16
data
;
u16
data
;
u16
size
;
u16
size
;
u
nsigned
char
pri
;
u
8
pri
;
u
nsigned
char
service_class
;
u
8
service_class
;
u
nsigned
char
daddr
[
ETH_ALEN
];
u
8
daddr
[
ETH_ALEN
];
u
nsigned
char
saddr
[
ETH_ALEN
];
u
8
saddr
[
ETH_ALEN
];
};
};
struct
wl3501_md_ind
{
struct
wl3501_md_ind
{
u16
next_blk
;
u16
next_blk
;
u
nsigned
char
sig_id
;
u
8
sig_id
;
u
nsigned
char
routing
;
u
8
routing
;
u16
data
;
u16
data
;
u16
size
;
u16
size
;
u
nsigned
char
reception
;
u
8
reception
;
u
nsigned
char
pri
;
u
8
pri
;
u
nsigned
char
service_class
;
u
8
service_class
;
u
nsigned
char
daddr
[
ETH_ALEN
];
u
8
daddr
[
ETH_ALEN
];
u
nsigned
char
saddr
[
ETH_ALEN
];
u
8
saddr
[
ETH_ALEN
];
};
};
struct
wl3501_md_confirm
{
struct
wl3501_md_confirm
{
u16
next_blk
;
u16
next_blk
;
u
nsigned
char
sig_id
;
u
8
sig_id
;
u
nsigned
char
reserved
;
u
8
reserved
;
u16
data
;
u16
data
;
u
nsigned
char
status
;
u
8
status
;
u
nsigned
char
pri
;
u
8
pri
;
u
nsigned
char
service_class
;
u
8
service_class
;
};
};
struct
wl3501_resync_req
{
struct
wl3501_resync_req
{
u16
next_blk
;
u16
next_blk
;
u
nsigned
char
sig_id
;
u
8
sig_id
;
};
};
/* Definitions for supporting clone adapters. */
/* Definitions for supporting clone adapters. */
...
@@ -511,7 +511,7 @@ struct wl3501_80211_tx_hdr {
...
@@ -511,7 +511,7 @@ struct wl3501_80211_tx_hdr {
struct
wl3501_card
{
struct
wl3501_card
{
int
base_addr
;
int
base_addr
;
u
nsigned
char
mac_addr
[
ETH_ALEN
];
u
8
mac_addr
[
ETH_ALEN
];
spinlock_t
lock
;
spinlock_t
lock
;
wait_queue_head_t
wait
;
wait_queue_head_t
wait
;
struct
wl3501_get_confirm
sig_get_confirm
;
struct
wl3501_get_confirm
sig_get_confirm
;
...
@@ -528,18 +528,18 @@ struct wl3501_card {
...
@@ -528,18 +528,18 @@ struct wl3501_card {
u16
esbq_confirm_end
;
u16
esbq_confirm_end
;
u16
esbq_confirm
;
u16
esbq_confirm
;
u8
essid
[
WL3501_ESSID_MAX_LEN
];
u8
essid
[
WL3501_ESSID_MAX_LEN
];
u
nsigned
char
bssid
[
ETH_ALEN
];
u
8
bssid
[
ETH_ALEN
];
int
net_type
;
int
net_type
;
u8
keep_essid
[
WL3501_ESSID_MAX_LEN
];
u8
keep_essid
[
WL3501_ESSID_MAX_LEN
];
unsigned
char
nick
[
32
];
char
nick
[
32
];
unsigned
char
card_name
[
32
];
char
card_name
[
32
];
unsigned
char
firmware_date
[
32
];
char
firmware_date
[
32
];
u8
chan
;
u8
chan
;
u8
cap_info
;
u8
cap_info
;
u16
start_seg
;
u16
start_seg
;
u16
bss_cnt
;
u16
bss_cnt
;
u16
join_sta_bss
;
u16
join_sta_bss
;
u
nsigned
char
rssi
;
u
8
rssi
;
u8
adhoc_times
;
u8
adhoc_times
;
u8
reg_domain
;
u8
reg_domain
;
u8
version
[
2
];
u8
version
[
2
];
...
...
drivers/net/wireless/wl3501_cs.c
View file @
d9468289
...
@@ -523,7 +523,7 @@ static int wl3501_send_pkt(struct wl3501_card *this, u8 *data, u16 len)
...
@@ -523,7 +523,7 @@ static int wl3501_send_pkt(struct wl3501_card *this, u8 *data, u16 len)
pdata
+=
12
;
pdata
+=
12
;
sig
.
data
=
bf
;
sig
.
data
=
bf
;
if
(((
*
pdata
)
*
256
+
(
*
(
pdata
+
1
)))
>
1500
)
{
if
(((
*
pdata
)
*
256
+
(
*
(
pdata
+
1
)))
>
1500
)
{
u
nsigned
char
addr4
[
ETH_ALEN
]
=
{
u
8
addr4
[
ETH_ALEN
]
=
{
[
0
]
=
0xAA
,
[
1
]
=
0xAA
,
[
2
]
=
0x03
,
[
4
]
=
0x00
,
[
0
]
=
0xAA
,
[
1
]
=
0xAA
,
[
2
]
=
0x03
,
[
4
]
=
0x00
,
};
};
...
@@ -956,7 +956,7 @@ static inline void wl3501_md_ind_interrupt(struct net_device *dev,
...
@@ -956,7 +956,7 @@ static inline void wl3501_md_ind_interrupt(struct net_device *dev,
{
{
struct
wl3501_md_ind
sig
;
struct
wl3501_md_ind
sig
;
struct
sk_buff
*
skb
;
struct
sk_buff
*
skb
;
u
nsigned
char
rssi
,
addr4
[
ETH_ALEN
];
u
8
rssi
,
addr4
[
ETH_ALEN
];
u16
pkt_len
;
u16
pkt_len
;
wl3501_get_from_wla
(
this
,
addr
,
&
sig
,
sizeof
(
sig
));
wl3501_get_from_wla
(
this
,
addr
,
&
sig
,
sizeof
(
sig
));
...
@@ -1662,8 +1662,7 @@ static int wl3501_set_wap(struct net_device *dev, struct iw_request_info *info,
...
@@ -1662,8 +1662,7 @@ static int wl3501_set_wap(struct net_device *dev, struct iw_request_info *info,
union
iwreq_data
*
wrqu
,
char
*
extra
)
union
iwreq_data
*
wrqu
,
char
*
extra
)
{
{
struct
wl3501_card
*
this
=
dev
->
priv
;
struct
wl3501_card
*
this
=
dev
->
priv
;
static
const
unsigned
char
bcast
[
ETH_ALEN
]
=
static
const
u8
bcast
[
ETH_ALEN
]
=
{
255
,
255
,
255
,
255
,
255
,
255
};
{
255
,
255
,
255
,
255
,
255
,
255
};
int
rc
=
-
EINVAL
;
int
rc
=
-
EINVAL
;
/* FIXME: we support other ARPHRDs...*/
/* FIXME: we support other ARPHRDs...*/
...
@@ -1993,8 +1992,10 @@ static dev_link_t *wl3501_attach(void)
...
@@ -1993,8 +1992,10 @@ static dev_link_t *wl3501_attach(void)
client_reg
.
Attributes
=
INFO_IO_CLIENT
|
INFO_CARD_SHARE
;
client_reg
.
Attributes
=
INFO_IO_CLIENT
|
INFO_CARD_SHARE
;
client_reg
.
EventMask
=
CS_EVENT_CARD_INSERTION
|
client_reg
.
EventMask
=
CS_EVENT_CARD_INSERTION
|
CS_EVENT_RESET_PHYSICAL
|
CS_EVENT_RESET_PHYSICAL
|
CS_EVENT_CARD_RESET
|
CS_EVENT_CARD_REMOVAL
|
CS_EVENT_CARD_RESET
|
CS_EVENT_PM_SUSPEND
|
CS_EVENT_PM_RESUME
;
CS_EVENT_CARD_REMOVAL
|
CS_EVENT_PM_SUSPEND
|
CS_EVENT_PM_RESUME
;
client_reg
.
event_handler
=
wl3501_event
;
client_reg
.
event_handler
=
wl3501_event
;
client_reg
.
Version
=
0x0210
;
client_reg
.
Version
=
0x0210
;
client_reg
.
event_callback_args
.
client_data
=
link
;
client_reg
.
event_callback_args
.
client_data
=
link
;
...
@@ -2030,15 +2031,15 @@ static void wl3501_config(dev_link_t *link)
...
@@ -2030,15 +2031,15 @@ static void wl3501_config(dev_link_t *link)
client_handle_t
handle
=
link
->
handle
;
client_handle_t
handle
=
link
->
handle
;
struct
net_device
*
dev
=
link
->
priv
;
struct
net_device
*
dev
=
link
->
priv
;
int
i
=
0
,
j
,
last_fn
,
last_ret
;
int
i
=
0
,
j
,
last_fn
,
last_ret
;
unsigned
char
b
u
f
[
64
];
unsigned
char
bf
[
64
];
struct
wl3501_card
*
this
;
struct
wl3501_card
*
this
;
/* This reads the card's CONFIG tuple to find its config registers. */
/* This reads the card's CONFIG tuple to find its config registers. */
tuple
.
Attributes
=
0
;
tuple
.
Attributes
=
0
;
tuple
.
DesiredTuple
=
CISTPL_CONFIG
;
tuple
.
DesiredTuple
=
CISTPL_CONFIG
;
CS_CHECK
(
GetFirstTuple
,
handle
,
&
tuple
);
CS_CHECK
(
GetFirstTuple
,
handle
,
&
tuple
);
tuple
.
TupleData
=
bu
f
;
tuple
.
TupleData
=
b
f
;
tuple
.
TupleDataMax
=
64
;
tuple
.
TupleDataMax
=
sizeof
(
bf
)
;
tuple
.
TupleOffset
=
0
;
tuple
.
TupleOffset
=
0
;
CS_CHECK
(
GetTupleData
,
handle
,
&
tuple
);
CS_CHECK
(
GetTupleData
,
handle
,
&
tuple
);
CS_CHECK
(
ParseTuple
,
handle
,
&
tuple
,
&
parse
);
CS_CHECK
(
ParseTuple
,
handle
,
&
tuple
,
&
parse
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment