Commit 580a0bd9 authored by Greg Kroah-Hartman's avatar Greg Kroah-Hartman

Staging: brcm80211: s/uchar/unsigned char/

This changes the usage everywhere in the driver, and removes
the definition as it should no longer be used anywhere.

Cc: Brett Rudley <brudley@broadcom.com>
Cc: Henry Ptasinski <henryp@broadcom.com>
Cc: Nohee Ko <noheek@broadcom.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
parent 562c8850
...@@ -42,7 +42,7 @@ ...@@ -42,7 +42,7 @@
#ifdef BCMDRIVER #ifdef BCMDRIVER
/* copy a pkt buffer chain into a buffer */ /* copy a pkt buffer chain into a buffer */
uint pktcopy(osl_t *osh, void *p, uint offset, int len, uchar * buf) uint pktcopy(osl_t *osh, void *p, uint offset, int len, unsigned char * buf)
{ {
uint n, ret = 0; uint n, ret = 0;
...@@ -73,7 +73,7 @@ uint pktcopy(osl_t *osh, void *p, uint offset, int len, uchar * buf) ...@@ -73,7 +73,7 @@ uint pktcopy(osl_t *osh, void *p, uint offset, int len, uchar * buf)
} }
/* copy a buffer into a pkt buffer chain */ /* copy a buffer into a pkt buffer chain */
uint pktfrombuf(osl_t *osh, void *p, uint offset, int len, uchar *buf) uint pktfrombuf(osl_t *osh, void *p, uint offset, int len, unsigned char *buf)
{ {
uint n, ret = 0; uint n, ret = 0;
...@@ -1473,7 +1473,7 @@ int bcm_format_hex(char *str, const void *bytes, int len) ...@@ -1473,7 +1473,7 @@ int bcm_format_hex(char *str, const void *bytes, int len)
} }
/* pretty hex print a contiguous buffer */ /* pretty hex print a contiguous buffer */
void prhex(const char *msg, uchar *buf, uint nbytes) void prhex(const char *msg, unsigned char *buf, uint nbytes)
{ {
char line[128], *p; char line[128], *p;
uint i; uint i;
...@@ -1716,7 +1716,7 @@ int bcm_bprintf(struct bcmstrbuf *b, const char *fmt, ...) ...@@ -1716,7 +1716,7 @@ int bcm_bprintf(struct bcmstrbuf *b, const char *fmt, ...)
return r; return r;
} }
void bcm_inc_bytes(uchar *num, int num_bytes, u8 amount) void bcm_inc_bytes(unsigned char *num, int num_bytes, u8 amount)
{ {
int i; int i;
...@@ -1728,7 +1728,7 @@ void bcm_inc_bytes(uchar *num, int num_bytes, u8 amount) ...@@ -1728,7 +1728,7 @@ void bcm_inc_bytes(uchar *num, int num_bytes, u8 amount)
} }
} }
int bcm_cmp_bytes(uchar *arg1, uchar *arg2, u8 nbytes) int bcm_cmp_bytes(unsigned char *arg1, unsigned char *arg2, u8 nbytes)
{ {
int i; int i;
...@@ -1739,7 +1739,7 @@ int bcm_cmp_bytes(uchar *arg1, uchar *arg2, u8 nbytes) ...@@ -1739,7 +1739,7 @@ int bcm_cmp_bytes(uchar *arg1, uchar *arg2, u8 nbytes)
return 0; return 0;
} }
void bcm_print_bytes(char *name, const uchar *data, int len) void bcm_print_bytes(char *name, const unsigned char *data, int len)
{ {
int i; int i;
int per_line = 0; int per_line = 0;
...@@ -1782,7 +1782,7 @@ char *getvar(char *vars, const char *name) ...@@ -1782,7 +1782,7 @@ char *getvar(char *vars, const char *name)
#if defined(WLTINYDUMP) || defined(WLMSG_INFORM) || defined(WLMSG_ASSOC) || \ #if defined(WLTINYDUMP) || defined(WLMSG_INFORM) || defined(WLMSG_ASSOC) || \
defined(WLMSG_PRPKT) || defined(WLMSG_WSEC) defined(WLMSG_PRPKT) || defined(WLMSG_WSEC)
int bcm_format_ssid(char *buf, const uchar ssid[], uint ssid_len) int bcm_format_ssid(char *buf, const unsigned char ssid[], uint ssid_len)
{ {
uint i, c; uint i, c;
char *p = buf; char *p = buf;
...@@ -1796,7 +1796,7 @@ int bcm_format_ssid(char *buf, const uchar ssid[], uint ssid_len) ...@@ -1796,7 +1796,7 @@ int bcm_format_ssid(char *buf, const uchar ssid[], uint ssid_len)
if (c == '\\') { if (c == '\\') {
*p++ = '\\'; *p++ = '\\';
*p++ = '\\'; *p++ = '\\';
} else if (bcm_isprint((uchar) c)) { } else if (bcm_isprint((unsigned char) c)) {
*p++ = (char)c; *p++ = (char)c;
} else { } else {
p += snprintf(p, (endp - p), "\\x%02X", c); p += snprintf(p, (endp - p), "\\x%02X", c);
......
...@@ -384,7 +384,7 @@ extern void dhd_vif_add(struct dhd_info *dhd, int ifidx, char *name); ...@@ -384,7 +384,7 @@ extern void dhd_vif_add(struct dhd_info *dhd, int ifidx, char *name);
extern void dhd_vif_del(struct dhd_info *dhd, int ifidx); extern void dhd_vif_del(struct dhd_info *dhd, int ifidx);
extern void dhd_event(struct dhd_info *dhd, char *evpkt, int evlen, int ifidx); extern void dhd_event(struct dhd_info *dhd, char *evpkt, int evlen, int ifidx);
extern void dhd_vif_sendup(struct dhd_info *dhd, int ifidx, uchar * cp, extern void dhd_vif_sendup(struct dhd_info *dhd, int ifidx, unsigned char * cp,
int len); int len);
/* Send packet to dongle via data channel */ /* Send packet to dongle via data channel */
......
...@@ -41,15 +41,15 @@ extern int dhd_bus_txdata(struct dhd_bus *bus, void *txp); ...@@ -41,15 +41,15 @@ extern int dhd_bus_txdata(struct dhd_bus *bus, void *txp);
/* Send/receive a control message to/from the dongle. /* Send/receive a control message to/from the dongle.
* Expects caller to enforce a single outstanding transaction. * Expects caller to enforce a single outstanding transaction.
*/ */
extern int dhd_bus_txctl(struct dhd_bus *bus, uchar *msg, uint msglen); extern int dhd_bus_txctl(struct dhd_bus *bus, unsigned char *msg, uint msglen);
extern int dhd_bus_rxctl(struct dhd_bus *bus, uchar *msg, uint msglen); extern int dhd_bus_rxctl(struct dhd_bus *bus, unsigned char *msg, uint msglen);
/* Watchdog timer function */ /* Watchdog timer function */
extern bool dhd_bus_watchdog(dhd_pub_t *dhd); extern bool dhd_bus_watchdog(dhd_pub_t *dhd);
#ifdef DHD_DEBUG #ifdef DHD_DEBUG
/* Device console input function */ /* Device console input function */
extern int dhd_bus_console_in(dhd_pub_t *dhd, uchar *msg, uint msglen); extern int dhd_bus_console_in(dhd_pub_t *dhd, unsigned char *msg, uint msglen);
#endif /* DHD_DEBUG */ #endif /* DHD_DEBUG */
/* Deferred processing for the bus, return TRUE requests reschedule */ /* Deferred processing for the bus, return TRUE requests reschedule */
......
...@@ -75,7 +75,7 @@ static int dhdcdc_msg(dhd_pub_t *dhd) ...@@ -75,7 +75,7 @@ static int dhdcdc_msg(dhd_pub_t *dhd)
len = CDC_MAX_MSG_SIZE; len = CDC_MAX_MSG_SIZE;
/* Send request */ /* Send request */
return dhd_bus_txctl(dhd->bus, (uchar *)&prot->msg, len); return dhd_bus_txctl(dhd->bus, (unsigned char *)&prot->msg, len);
} }
static int dhdcdc_cmplt(dhd_pub_t *dhd, uint32 id, uint32 len) static int dhdcdc_cmplt(dhd_pub_t *dhd, uint32 id, uint32 len)
...@@ -87,7 +87,7 @@ static int dhdcdc_cmplt(dhd_pub_t *dhd, uint32 id, uint32 len) ...@@ -87,7 +87,7 @@ static int dhdcdc_cmplt(dhd_pub_t *dhd, uint32 id, uint32 len)
do { do {
ret = ret =
dhd_bus_rxctl(dhd->bus, (uchar *)&prot->msg, dhd_bus_rxctl(dhd->bus, (unsigned char *)&prot->msg,
len + sizeof(cdc_ioctl_t)); len + sizeof(cdc_ioctl_t));
if (ret < 0) if (ret < 0)
break; break;
......
...@@ -526,7 +526,7 @@ static void wl_show_host_event(wl_event_msg_t *event, void *event_data) ...@@ -526,7 +526,7 @@ static void wl_show_host_event(wl_event_msg_t *event, void *event_data)
uint i, status, reason; uint i, status, reason;
bool group = FALSE, flush_txq = FALSE, link = FALSE; bool group = FALSE, flush_txq = FALSE, link = FALSE;
char *auth_str, *event_name; char *auth_str, *event_name;
uchar *buf; unsigned char *buf;
char err_msg[256], eabuf[ETHER_ADDR_STR_LEN]; char err_msg[256], eabuf[ETHER_ADDR_STR_LEN];
static struct { static struct {
uint event; uint event;
...@@ -599,12 +599,12 @@ static void wl_show_host_event(wl_event_msg_t *event, void *event_data) ...@@ -599,12 +599,12 @@ static void wl_show_host_event(wl_event_msg_t *event, void *event_data)
datalen = ntoh32(event->datalen); datalen = ntoh32(event->datalen);
/* debug dump of event messages */ /* debug dump of event messages */
sprintf(eabuf, "%02x:%02x:%02x:%02x:%02x:%02x", sprintf(eabuf, "%02x:%02x:%02x:%02x:%02x:%02x",
(uchar) event->addr.octet[0] & 0xff, (unsigned char) event->addr.octet[0] & 0xff,
(uchar) event->addr.octet[1] & 0xff, (unsigned char) event->addr.octet[1] & 0xff,
(uchar) event->addr.octet[2] & 0xff, (unsigned char) event->addr.octet[2] & 0xff,
(uchar) event->addr.octet[3] & 0xff, (unsigned char) event->addr.octet[3] & 0xff,
(uchar) event->addr.octet[4] & 0xff, (unsigned char) event->addr.octet[4] & 0xff,
(uchar) event->addr.octet[5] & 0xff); (unsigned char) event->addr.octet[5] & 0xff);
event_name = "UNKNOWN"; event_name = "UNKNOWN";
for (i = 0; i < ARRAYSIZE(event_names); i++) { for (i = 0; i < ARRAYSIZE(event_names); i++) {
...@@ -755,7 +755,7 @@ static void wl_show_host_event(wl_event_msg_t *event, void *event_data) ...@@ -755,7 +755,7 @@ static void wl_show_host_event(wl_event_msg_t *event, void *event_data)
uint32 nblost; uint32 nblost;
char *s, *p; char *s, *p;
buf = (uchar *) event_data; buf = (unsigned char *) event_data;
memcpy(&hdr, buf, MSGTRACE_HDRLEN); memcpy(&hdr, buf, MSGTRACE_HDRLEN);
if (hdr.version != MSGTRACE_VERSION) { if (hdr.version != MSGTRACE_VERSION) {
...@@ -819,7 +819,7 @@ static void wl_show_host_event(wl_event_msg_t *event, void *event_data) ...@@ -819,7 +819,7 @@ static void wl_show_host_event(wl_event_msg_t *event, void *event_data)
/* show any appended data */ /* show any appended data */
if (datalen) { if (datalen) {
buf = (uchar *) event_data; buf = (unsigned char *) event_data;
DHD_EVENT((" data (%d) : ", datalen)); DHD_EVENT((" data (%d) : ", datalen));
for (i = 0; i < datalen; i++) for (i = 0; i < datalen; i++)
DHD_EVENT((" 0x%02x ", *buf++)); DHD_EVENT((" 0x%02x ", *buf++));
...@@ -1507,7 +1507,7 @@ int dhd_iscan_delete_bss(void *dhdp, void *addr, iscan_buf_t *iscan_skip) ...@@ -1507,7 +1507,7 @@ int dhd_iscan_delete_bss(void *dhdp, void *addr, iscan_buf_t *iscan_skip)
wl_scan_results_t *results; wl_scan_results_t *results;
wl_bss_info_t UNALIGNED *bi, *bi_new, *bi_next; wl_bss_info_t UNALIGNED *bi, *bi_new, *bi_next;
uchar *s_addr = addr; unsigned char *s_addr = addr;
dhd_iscan_lock(); dhd_iscan_lock();
DHD_ISCAN(("%s: BSS to remove %X:%X:%X:%X:%X:%X\n", DHD_ISCAN(("%s: BSS to remove %X:%X:%X:%X:%X:%X\n",
...@@ -1818,7 +1818,7 @@ int dhd_pno_enable(dhd_pub_t *dhd, int pfn_enabled) ...@@ -1818,7 +1818,7 @@ int dhd_pno_enable(dhd_pub_t *dhd, int pfn_enabled)
/* Function to execute combined scan */ /* Function to execute combined scan */
int int
dhd_pno_set(dhd_pub_t *dhd, wlc_ssid_t *ssids_local, int nssid, uchar scan_fr) dhd_pno_set(dhd_pub_t *dhd, wlc_ssid_t *ssids_local, int nssid, unsigned char scan_fr)
{ {
int err = -1; int err = -1;
char iovbuf[128]; char iovbuf[128];
......
...@@ -1153,7 +1153,7 @@ void dhd_rx_frame(dhd_pub_t *dhdp, int ifidx, void *pktbuf, int numpkt) ...@@ -1153,7 +1153,7 @@ void dhd_rx_frame(dhd_pub_t *dhdp, int ifidx, void *pktbuf, int numpkt)
{ {
dhd_info_t *dhd = (dhd_info_t *) dhdp->info; dhd_info_t *dhd = (dhd_info_t *) dhdp->info;
struct sk_buff *skb; struct sk_buff *skb;
uchar *eth; unsigned char *eth;
uint len; uint len;
void *data, *pnext, *save_pktbuf; void *data, *pnext, *save_pktbuf;
int i; int i;
...@@ -2898,7 +2898,7 @@ int dhd_dev_pno_enable(struct net_device *dev, int pfn_enabled) ...@@ -2898,7 +2898,7 @@ int dhd_dev_pno_enable(struct net_device *dev, int pfn_enabled)
/* Linux wrapper to call common dhd_pno_set */ /* Linux wrapper to call common dhd_pno_set */
int int
dhd_dev_pno_set(struct net_device *dev, wlc_ssid_t *ssids_local, int nssid, dhd_dev_pno_set(struct net_device *dev, wlc_ssid_t *ssids_local, int nssid,
uchar scan_fr) unsigned char scan_fr)
{ {
dhd_info_t *dhd = *(dhd_info_t **)netdev_priv(dev); dhd_info_t *dhd = *(dhd_info_t **)netdev_priv(dev);
......
...@@ -1219,7 +1219,7 @@ static uint dhdsdio_sendfromq(dhd_bus_t *bus, uint maxframes) ...@@ -1219,7 +1219,7 @@ static uint dhdsdio_sendfromq(dhd_bus_t *bus, uint maxframes)
return cnt; return cnt;
} }
int dhd_bus_txctl(struct dhd_bus *bus, uchar *msg, uint msglen) int dhd_bus_txctl(struct dhd_bus *bus, unsigned char *msg, uint msglen)
{ {
u8 *frame; u8 *frame;
uint16 len; uint16 len;
...@@ -1374,7 +1374,7 @@ int dhd_bus_txctl(struct dhd_bus *bus, uchar *msg, uint msglen) ...@@ -1374,7 +1374,7 @@ int dhd_bus_txctl(struct dhd_bus *bus, uchar *msg, uint msglen)
return ret ? -EIO : 0; return ret ? -EIO : 0;
} }
int dhd_bus_rxctl(struct dhd_bus *bus, uchar *msg, uint msglen) int dhd_bus_rxctl(struct dhd_bus *bus, unsigned char *msg, uint msglen)
{ {
int timeleft; int timeleft;
uint rxlen = 0; uint rxlen = 0;
...@@ -4954,7 +4954,7 @@ extern bool dhd_bus_watchdog(dhd_pub_t *dhdp) ...@@ -4954,7 +4954,7 @@ extern bool dhd_bus_watchdog(dhd_pub_t *dhdp)
} }
#ifdef DHD_DEBUG #ifdef DHD_DEBUG
extern int dhd_bus_console_in(dhd_pub_t *dhdp, uchar *msg, uint msglen) extern int dhd_bus_console_in(dhd_pub_t *dhdp, unsigned char *msg, uint msglen)
{ {
dhd_bus_t *bus = dhdp->bus; dhd_bus_t *bus = dhdp->bus;
uint32 addr, val; uint32 addr, val;
......
...@@ -2592,8 +2592,8 @@ wl_iw_set_encodeext(struct net_device *dev, ...@@ -2592,8 +2592,8 @@ wl_iw_set_encodeext(struct net_device *dev,
} }
if (iwe->ext_flags & IW_ENCODE_EXT_RX_SEQ_VALID) { if (iwe->ext_flags & IW_ENCODE_EXT_RX_SEQ_VALID) {
uchar *ivptr; unsigned char *ivptr;
ivptr = (uchar *) iwe->rx_seq; ivptr = (unsigned char *) iwe->rx_seq;
key.rxiv.hi = (ivptr[5] << 24) | (ivptr[4] << 16) | key.rxiv.hi = (ivptr[5] << 24) | (ivptr[4] << 16) |
(ivptr[3] << 8) | ivptr[2]; (ivptr[3] << 8) | ivptr[2];
key.rxiv.lo = (ivptr[1] << 8) | ivptr[0]; key.rxiv.lo = (ivptr[1] << 8) | ivptr[0];
......
...@@ -129,11 +129,11 @@ extern int net_os_set_packet_filter(struct net_device *dev, int val); ...@@ -129,11 +129,11 @@ extern int net_os_set_packet_filter(struct net_device *dev, int val);
extern int dhd_pno_enable(dhd_pub_t *dhd, int pfn_enabled); extern int dhd_pno_enable(dhd_pub_t *dhd, int pfn_enabled);
extern int dhd_pno_clean(dhd_pub_t *dhd); extern int dhd_pno_clean(dhd_pub_t *dhd);
extern int dhd_pno_set(dhd_pub_t *dhd, wlc_ssid_t *ssids_local, int nssid, extern int dhd_pno_set(dhd_pub_t *dhd, wlc_ssid_t *ssids_local, int nssid,
uchar scan_fr); unsigned char scan_fr);
extern int dhd_pno_get_status(dhd_pub_t *dhd); extern int dhd_pno_get_status(dhd_pub_t *dhd);
extern int dhd_dev_pno_reset(struct net_device *dev); extern int dhd_dev_pno_reset(struct net_device *dev);
extern int dhd_dev_pno_set(struct net_device *dev, wlc_ssid_t *ssids_local, extern int dhd_dev_pno_set(struct net_device *dev, wlc_ssid_t *ssids_local,
int nssid, uchar scan_fr); int nssid, unsigned char scan_fr);
extern int dhd_dev_pno_enable(struct net_device *dev, int pfn_enabled); extern int dhd_dev_pno_enable(struct net_device *dev, int pfn_enabled);
extern int dhd_dev_get_pno_status(struct net_device *dev); extern int dhd_dev_get_pno_status(struct net_device *dev);
......
...@@ -190,9 +190,9 @@ extern "C" { ...@@ -190,9 +190,9 @@ extern "C" {
/* externs */ /* externs */
/* packet */ /* packet */
extern uint pktcopy(osl_t *osh, void *p, uint offset, int len, extern uint pktcopy(osl_t *osh, void *p, uint offset, int len,
uchar *buf); unsigned char *buf);
extern uint pktfrombuf(osl_t *osh, void *p, uint offset, int len, extern uint pktfrombuf(osl_t *osh, void *p, uint offset, int len,
uchar *buf); unsigned char *buf);
extern uint pkttotlen(osl_t *osh, void *p); extern uint pkttotlen(osl_t *osh, void *p);
extern void *pktlast(osl_t *osh, void *p); extern void *pktlast(osl_t *osh, void *p);
extern uint pktsegcnt(osl_t *osh, void *p); extern uint pktsegcnt(osl_t *osh, void *p);
...@@ -284,7 +284,7 @@ extern "C" { ...@@ -284,7 +284,7 @@ extern "C" {
extern int bcm_iovar_lencheck(const bcm_iovar_t *table, void *arg, extern int bcm_iovar_lencheck(const bcm_iovar_t *table, void *arg,
int len, bool set); int len, bool set);
#if defined(BCMDBG) #if defined(BCMDBG)
extern int bcm_format_ssid(char *buf, const uchar ssid[], extern int bcm_format_ssid(char *buf, const unsigned char ssid[],
uint ssid_len); uint ssid_len);
#endif #endif
...@@ -565,7 +565,7 @@ extern "C" { ...@@ -565,7 +565,7 @@ extern "C" {
extern char *bcm_chipname(uint chipid, char *buf, uint len); extern char *bcm_chipname(uint chipid, char *buf, uint len);
extern char *bcm_brev_str(uint32 brev, char *buf); extern char *bcm_brev_str(uint32 brev, char *buf);
extern void printbig(char *buf); extern void printbig(char *buf);
extern void prhex(const char *msg, uchar *buf, uint len); extern void prhex(const char *msg, unsigned char *buf, uint len);
/* IE parsing */ /* IE parsing */
extern bcm_tlv_t *BCMROMFN(bcm_next_tlv) (bcm_tlv_t *elt, int *buflen); extern bcm_tlv_t *BCMROMFN(bcm_next_tlv) (bcm_tlv_t *elt, int *buflen);
...@@ -598,9 +598,9 @@ extern "C" { ...@@ -598,9 +598,9 @@ extern "C" {
extern void bcm_binit(struct bcmstrbuf *b, char *buf, uint size); extern void bcm_binit(struct bcmstrbuf *b, char *buf, uint size);
extern int bcm_bprintf(struct bcmstrbuf *b, const char *fmt, ...); extern int bcm_bprintf(struct bcmstrbuf *b, const char *fmt, ...);
extern void bcm_inc_bytes(uchar *num, int num_bytes, u8 amount); extern void bcm_inc_bytes(unsigned char *num, int num_bytes, u8 amount);
extern int bcm_cmp_bytes(uchar *arg1, uchar *arg2, u8 nbytes); extern int bcm_cmp_bytes(unsigned char *arg1, unsigned char *arg2, u8 nbytes);
extern void bcm_print_bytes(char *name, const uchar *cdata, int len); extern void bcm_print_bytes(char *name, const unsigned char *cdata, int len);
typedef uint32(*bcmutl_rdreg_rtn) (void *arg0, uint arg1, typedef uint32(*bcmutl_rdreg_rtn) (void *arg0, uint arg1,
uint32 offset); uint32 offset);
......
...@@ -46,7 +46,7 @@ ...@@ -46,7 +46,7 @@
struct sbpcieregs; struct sbpcieregs;
extern u8 pcicore_find_pci_capability(osl_t *osh, u8 req_cap_id, extern u8 pcicore_find_pci_capability(osl_t *osh, u8 req_cap_id,
uchar *buf, uint32 *buflen); unsigned char *buf, uint32 *buflen);
extern uint pcie_readreg(osl_t *osh, struct sbpcieregs *pcieregs, extern uint pcie_readreg(osl_t *osh, struct sbpcieregs *pcieregs,
uint addrtype, uint offset); uint addrtype, uint offset);
extern uint pcie_writereg(osl_t *osh, struct sbpcieregs *pcieregs, extern uint pcie_writereg(osl_t *osh, struct sbpcieregs *pcieregs,
......
...@@ -38,11 +38,7 @@ typedef unsigned long long int uintptr; ...@@ -38,11 +38,7 @@ typedef unsigned long long int uintptr;
* Default Typedefs * Default Typedefs
*/ */
/* define uchar, ushort, uint, ulong */ /* define ushort, uint, ulong */
#ifndef TYPEDEF_UCHAR
typedef unsigned char uchar;
#endif
#ifndef TYPEDEF_USHORT #ifndef TYPEDEF_USHORT
typedef unsigned short ushort; typedef unsigned short ushort;
...@@ -98,7 +94,6 @@ typedef signed int int32; ...@@ -98,7 +94,6 @@ typedef signed int int32;
#define AUTO (-1) /* Auto = -1 */ #define AUTO (-1) /* Auto = -1 */
#undef TYPEDEF_UCHAR
#undef TYPEDEF_USHORT #undef TYPEDEF_USHORT
#undef TYPEDEF_UINT #undef TYPEDEF_UINT
#undef TYPEDEF_ULONG #undef TYPEDEF_ULONG
......
...@@ -152,7 +152,7 @@ typedef struct wl_bss_info { ...@@ -152,7 +152,7 @@ typedef struct wl_bss_info {
typedef struct wlc_ssid { typedef struct wlc_ssid {
uint32 SSID_len; uint32 SSID_len;
uchar SSID[32]; unsigned char SSID[32];
} wlc_ssid_t; } wlc_ssid_t;
typedef struct chan_scandata { typedef struct chan_scandata {
......
...@@ -36,11 +36,11 @@ extern CONST dot11lcnphytbl_info_t dot11lcnphytbl_rx_gain_info_extlna_2G_rev2[]; ...@@ -36,11 +36,11 @@ extern CONST dot11lcnphytbl_info_t dot11lcnphytbl_rx_gain_info_extlna_2G_rev2[];
extern CONST dot11lcnphytbl_info_t dot11lcnphytbl_rx_gain_info_extlna_5G_rev2[]; extern CONST dot11lcnphytbl_info_t dot11lcnphytbl_rx_gain_info_extlna_5G_rev2[];
typedef struct { typedef struct {
uchar gm; unsigned char gm;
uchar pga; unsigned char pga;
uchar pad; unsigned char pad;
uchar dac; unsigned char dac;
uchar bb_mult; unsigned char bb_mult;
} lcnphy_tx_gain_tbl_entry; } lcnphy_tx_gain_tbl_entry;
extern CONST lcnphy_tx_gain_tbl_entry dot11lcnphy_2GHz_gaintable_rev0[]; extern CONST lcnphy_tx_gain_tbl_entry dot11lcnphy_2GHz_gaintable_rev0[];
......
...@@ -45,7 +45,7 @@ extern void wl_add_timer(struct wl_info *wl, struct wl_timer *timer, uint ms, ...@@ -45,7 +45,7 @@ extern void wl_add_timer(struct wl_info *wl, struct wl_timer *timer, uint ms,
int periodic); int periodic);
extern bool wl_del_timer(struct wl_info *wl, struct wl_timer *timer); extern bool wl_del_timer(struct wl_info *wl, struct wl_timer *timer);
extern uint wl_buf_to_pktcopy(osl_t *osh, void *p, uchar *buf, int len, extern uint wl_buf_to_pktcopy(osl_t *osh, void *p, unsigned char *buf, int len,
uint offset); uint offset);
extern void *wl_get_pktbuffer(osl_t *osh, int len); extern void *wl_get_pktbuffer(osl_t *osh, int len);
extern int wl_set_pktlen(osl_t *osh, void *p, int len); extern int wl_set_pktlen(osl_t *osh, void *p, int len);
......
...@@ -3527,12 +3527,12 @@ _wlc_ioctl(wlc_info_t *wlc, int cmd, void *arg, int len, struct wlc_if *wlcif) ...@@ -3527,12 +3527,12 @@ _wlc_ioctl(wlc_info_t *wlc, int cmd, void *arg, int len, struct wlc_if *wlcif)
if (r->size == sizeof(uint32)) if (r->size == sizeof(uint32))
r->val = r->val =
R_REG(osh, R_REG(osh,
(uint32 *) ((uchar *) (uintptr) regs + (uint32 *) ((unsigned char *) (uintptr) regs +
r->byteoff)); r->byteoff));
else if (r->size == sizeof(uint16)) else if (r->size == sizeof(uint16))
r->val = r->val =
R_REG(osh, R_REG(osh,
(uint16 *) ((uchar *) (uintptr) regs + (uint16 *) ((unsigned char *) (uintptr) regs +
r->byteoff)); r->byteoff));
else else
bcmerror = BCME_BADADDR; bcmerror = BCME_BADADDR;
...@@ -3562,11 +3562,11 @@ _wlc_ioctl(wlc_info_t *wlc, int cmd, void *arg, int len, struct wlc_if *wlcif) ...@@ -3562,11 +3562,11 @@ _wlc_ioctl(wlc_info_t *wlc, int cmd, void *arg, int len, struct wlc_if *wlcif)
} }
if (r->size == sizeof(uint32)) if (r->size == sizeof(uint32))
W_REG(osh, W_REG(osh,
(uint32 *) ((uchar *) (uintptr) regs + (uint32 *) ((unsigned char *) (uintptr) regs +
r->byteoff), r->val); r->byteoff), r->val);
else if (r->size == sizeof(uint16)) else if (r->size == sizeof(uint16))
W_REG(osh, W_REG(osh,
(uint16 *) ((uchar *) (uintptr) regs + (uint16 *) ((unsigned char *) (uintptr) regs +
r->byteoff), r->val); r->byteoff), r->val);
else else
bcmerror = BCME_BADADDR; bcmerror = BCME_BADADDR;
...@@ -4105,7 +4105,7 @@ _wlc_ioctl(wlc_info_t *wlc, int cmd, void *arg, int len, struct wlc_if *wlcif) ...@@ -4105,7 +4105,7 @@ _wlc_ioctl(wlc_info_t *wlc, int cmd, void *arg, int len, struct wlc_if *wlcif)
case WLC_GET_PHYLIST: case WLC_GET_PHYLIST:
{ {
uchar *cp = arg; unsigned char *cp = arg;
if (len < 3) { if (len < 3) {
bcmerror = BCME_BUFTOOSHORT; bcmerror = BCME_BUFTOOSHORT;
break; break;
...@@ -5081,7 +5081,7 @@ void wlc_print_txdesc(d11txh_t *txh) ...@@ -5081,7 +5081,7 @@ void wlc_print_txdesc(d11txh_t *txh)
char hexbuf[256]; char hexbuf[256];
/* add plcp header along with txh descriptor */ /* add plcp header along with txh descriptor */
prhex("Raw TxDesc + plcp header", (uchar *) txh, sizeof(d11txh_t) + 48); prhex("Raw TxDesc + plcp header", (unsigned char *) txh, sizeof(d11txh_t) + 48);
printf("TxCtlLow: %04x ", mtcl); printf("TxCtlLow: %04x ", mtcl);
printf("TxCtlHigh: %04x ", mtch); printf("TxCtlHigh: %04x ", mtch);
...@@ -5153,7 +5153,7 @@ void wlc_print_rxh(d11rxhdr_t *rxh) ...@@ -5153,7 +5153,7 @@ void wlc_print_rxh(d11rxhdr_t *rxh)
{0, NULL} {0, NULL}
}; };
prhex("Raw RxDesc", (uchar *) rxh, sizeof(d11rxhdr_t)); prhex("Raw RxDesc", (unsigned char *) rxh, sizeof(d11rxhdr_t));
bcm_format_flags(macstat_flags, macstatus1, flagstr, 64); bcm_format_flags(macstat_flags, macstatus1, flagstr, 64);
...@@ -5170,7 +5170,7 @@ void wlc_print_rxh(d11rxhdr_t *rxh) ...@@ -5170,7 +5170,7 @@ void wlc_print_rxh(d11rxhdr_t *rxh)
#endif /* defined(BCMDBG) */ #endif /* defined(BCMDBG) */
#if defined(BCMDBG) #if defined(BCMDBG)
int wlc_format_ssid(char *buf, const uchar ssid[], uint ssid_len) int wlc_format_ssid(char *buf, const unsigned char ssid[], uint ssid_len)
{ {
uint i, c; uint i, c;
char *p = buf; char *p = buf;
...@@ -5184,7 +5184,7 @@ int wlc_format_ssid(char *buf, const uchar ssid[], uint ssid_len) ...@@ -5184,7 +5184,7 @@ int wlc_format_ssid(char *buf, const uchar ssid[], uint ssid_len)
if (c == '\\') { if (c == '\\') {
*p++ = '\\'; *p++ = '\\';
*p++ = '\\'; *p++ = '\\';
} else if (isprint((uchar) c)) { } else if (isprint((unsigned char) c)) {
*p++ = (char)c; *p++ = (char)c;
} else { } else {
p += snprintf(p, (endp - p), "\\x%02X", c); p += snprintf(p, (endp - p), "\\x%02X", c);
...@@ -7051,7 +7051,7 @@ prep_mac80211_status(wlc_info_t *wlc, d11rxhdr_t *rxh, void *p, ...@@ -7051,7 +7051,7 @@ prep_mac80211_status(wlc_info_t *wlc, d11rxhdr_t *rxh, void *p,
int preamble; int preamble;
int channel; int channel;
ratespec_t rspec; ratespec_t rspec;
uchar *plcp; unsigned char *plcp;
wlc_read_tsf(wlc, &tsf_l, &tsf_h); /* mactime */ wlc_read_tsf(wlc, &tsf_l, &tsf_h); /* mactime */
rx_status->mactime = tsf_h; rx_status->mactime = tsf_h;
......
...@@ -603,7 +603,7 @@ extern void wlc_ps_off(struct wlc_info *wlc, struct scb *scb, bool discard); ...@@ -603,7 +603,7 @@ extern void wlc_ps_off(struct wlc_info *wlc, struct scb *scb, bool discard);
extern bool wlc_radio_monitor_stop(struct wlc_info *wlc); extern bool wlc_radio_monitor_stop(struct wlc_info *wlc);
#if defined(BCMDBG) #if defined(BCMDBG)
extern int wlc_format_ssid(char *buf, const uchar ssid[], uint ssid_len); extern int wlc_format_ssid(char *buf, const unsigned char ssid[], uint ssid_len);
#endif #endif
extern void wlc_pmkid_build_cand_list(struct wlc_bsscfg *cfg, bool check_SSID); extern void wlc_pmkid_build_cand_list(struct wlc_bsscfg *cfg, bool check_SSID);
......
...@@ -514,7 +514,7 @@ uint ai_corereg(si_t *sih, uint coreidx, uint regoff, uint mask, uint val) ...@@ -514,7 +514,7 @@ uint ai_corereg(si_t *sih, uint coreidx, uint regoff, uint mask, uint val)
SI_CORE_SIZE); SI_CORE_SIZE);
ASSERT(GOODREGS(sii->regs[coreidx])); ASSERT(GOODREGS(sii->regs[coreidx]));
} }
r = (uint32 *) ((uchar *) sii->regs[coreidx] + regoff); r = (uint32 *) ((unsigned char *) sii->regs[coreidx] + regoff);
} else if (BUSTYPE(sih->bustype) == PCI_BUS) { } else if (BUSTYPE(sih->bustype) == PCI_BUS) {
/* If pci/pcie, we can get at pci/pcie regs and on newer cores to chipc */ /* If pci/pcie, we can get at pci/pcie regs and on newer cores to chipc */
...@@ -549,7 +549,7 @@ uint ai_corereg(si_t *sih, uint coreidx, uint regoff, uint mask, uint val) ...@@ -549,7 +549,7 @@ uint ai_corereg(si_t *sih, uint coreidx, uint regoff, uint mask, uint val)
origidx = si_coreidx(&sii->pub); origidx = si_coreidx(&sii->pub);
/* switch core */ /* switch core */
r = (uint32 *) ((uchar *) ai_setcoreidx(&sii->pub, coreidx) + r = (uint32 *) ((unsigned char *) ai_setcoreidx(&sii->pub, coreidx) +
regoff); regoff);
} }
ASSERT(r != NULL); ASSERT(r != NULL);
......
...@@ -38,7 +38,7 @@ static int vars_len = -1; ...@@ -38,7 +38,7 @@ static int vars_len = -1;
#endif /* WLC_LOW */ #endif /* WLC_LOW */
/* copy a pkt buffer chain into a buffer */ /* copy a pkt buffer chain into a buffer */
uint pktcopy(osl_t *osh, void *p, uint offset, int len, uchar *buf) uint pktcopy(osl_t *osh, void *p, uint offset, int len, unsigned char *buf)
{ {
uint n, ret = 0; uint n, ret = 0;
...@@ -69,7 +69,7 @@ uint pktcopy(osl_t *osh, void *p, uint offset, int len, uchar *buf) ...@@ -69,7 +69,7 @@ uint pktcopy(osl_t *osh, void *p, uint offset, int len, uchar *buf)
} }
/* copy a buffer into a pkt buffer chain */ /* copy a buffer into a pkt buffer chain */
uint pktfrombuf(osl_t *osh, void *p, uint offset, int len, uchar *buf) uint pktfrombuf(osl_t *osh, void *p, uint offset, int len, unsigned char *buf)
{ {
uint n, ret = 0; uint n, ret = 0;
...@@ -1131,7 +1131,7 @@ int bcm_format_hex(char *str, const void *bytes, int len) ...@@ -1131,7 +1131,7 @@ int bcm_format_hex(char *str, const void *bytes, int len)
#endif /* defined(BCMDBG) */ #endif /* defined(BCMDBG) */
/* pretty hex print a contiguous buffer */ /* pretty hex print a contiguous buffer */
void prhex(const char *msg, uchar *buf, uint nbytes) void prhex(const char *msg, unsigned char *buf, uint nbytes)
{ {
char line[128], *p; char line[128], *p;
int len = sizeof(line); int len = sizeof(line);
...@@ -1419,7 +1419,7 @@ int bcm_bprintf(struct bcmstrbuf *b, const char *fmt, ...) ...@@ -1419,7 +1419,7 @@ int bcm_bprintf(struct bcmstrbuf *b, const char *fmt, ...)
return r; return r;
} }
void bcm_inc_bytes(uchar *num, int num_bytes, u8 amount) void bcm_inc_bytes(unsigned char *num, int num_bytes, u8 amount)
{ {
int i; int i;
...@@ -1431,7 +1431,7 @@ void bcm_inc_bytes(uchar *num, int num_bytes, u8 amount) ...@@ -1431,7 +1431,7 @@ void bcm_inc_bytes(uchar *num, int num_bytes, u8 amount)
} }
} }
int bcm_cmp_bytes(uchar *arg1, uchar *arg2, u8 nbytes) int bcm_cmp_bytes(unsigned char *arg1, unsigned char *arg2, u8 nbytes)
{ {
int i; int i;
...@@ -1442,7 +1442,7 @@ int bcm_cmp_bytes(uchar *arg1, uchar *arg2, u8 nbytes) ...@@ -1442,7 +1442,7 @@ int bcm_cmp_bytes(uchar *arg1, uchar *arg2, u8 nbytes)
return 0; return 0;
} }
void bcm_print_bytes(char *name, const uchar *data, int len) void bcm_print_bytes(char *name, const unsigned char *data, int len)
{ {
int i; int i;
int per_line = 0; int per_line = 0;
...@@ -1461,7 +1461,7 @@ void bcm_print_bytes(char *name, const uchar *data, int len) ...@@ -1461,7 +1461,7 @@ void bcm_print_bytes(char *name, const uchar *data, int len)
#if defined(BCMDBG) #if defined(BCMDBG)
#define SSID_FMT_BUF_LEN ((4 * DOT11_MAX_SSID_LEN) + 1) #define SSID_FMT_BUF_LEN ((4 * DOT11_MAX_SSID_LEN) + 1)
int bcm_format_ssid(char *buf, const uchar ssid[], uint ssid_len) int bcm_format_ssid(char *buf, const unsigned char ssid[], uint ssid_len)
{ {
uint i, c; uint i, c;
char *p = buf; char *p = buf;
...@@ -1475,7 +1475,7 @@ int bcm_format_ssid(char *buf, const uchar ssid[], uint ssid_len) ...@@ -1475,7 +1475,7 @@ int bcm_format_ssid(char *buf, const uchar ssid[], uint ssid_len)
if (c == '\\') { if (c == '\\') {
*p++ = '\\'; *p++ = '\\';
*p++ = '\\'; *p++ = '\\';
} else if (isprint((uchar) c)) { } else if (isprint((unsigned char) c)) {
*p++ = (char)c; *p++ = (char)c;
} else { } else {
p += snprintf(p, (endp - p), "\\x%02X", c); p += snprintf(p, (endp - p), "\\x%02X", c);
......
...@@ -1664,7 +1664,7 @@ static bool dma32_txsuspendedidle(dma_info_t *di) ...@@ -1664,7 +1664,7 @@ static bool dma32_txsuspendedidle(dma_info_t *di)
static int dma32_txfast(dma_info_t *di, void *p0, bool commit) static int dma32_txfast(dma_info_t *di, void *p0, bool commit)
{ {
void *p, *next; void *p, *next;
uchar *data; unsigned char *data;
uint len; uint len;
uint16 txout; uint16 txout;
uint32 flags = 0; uint32 flags = 0;
...@@ -2315,7 +2315,7 @@ static int dma64_txunframed(dma_info_t *di, void *buf, uint len, bool commit) ...@@ -2315,7 +2315,7 @@ static int dma64_txunframed(dma_info_t *di, void *buf, uint len, bool commit)
static int BCMFASTPATH dma64_txfast(dma_info_t *di, void *p0, bool commit) static int BCMFASTPATH dma64_txfast(dma_info_t *di, void *p0, bool commit)
{ {
void *p, *next; void *p, *next;
uchar *data; unsigned char *data;
uint len; uint len;
uint16 txout; uint16 txout;
uint32 flags = 0; uint32 flags = 0;
......
...@@ -153,7 +153,7 @@ void pcicore_deinit(void *pch) ...@@ -153,7 +153,7 @@ void pcicore_deinit(void *pch)
/* return cap_offset if requested capability exists in the PCI config space */ /* return cap_offset if requested capability exists in the PCI config space */
/* Note that it's caller's responsibility to make sure it's a pci bus */ /* Note that it's caller's responsibility to make sure it's a pci bus */
u8 u8
pcicore_find_pci_capability(osl_t *osh, u8 req_cap_id, uchar *buf, pcicore_find_pci_capability(osl_t *osh, u8 req_cap_id, unsigned char *buf,
uint32 *buflen) uint32 *buflen)
{ {
u8 cap_id; u8 cap_id;
......
...@@ -164,7 +164,7 @@ uint sb_corereg(si_t *sih, uint coreidx, uint regoff, uint mask, uint val) ...@@ -164,7 +164,7 @@ uint sb_corereg(si_t *sih, uint coreidx, uint regoff, uint mask, uint val)
origidx = si_coreidx(&sii->pub); origidx = si_coreidx(&sii->pub);
/* switch core */ /* switch core */
r = (uint32 *) ((uchar *) sb_setcoreidx(&sii->pub, coreidx) + r = (uint32 *) ((unsigned char *) sb_setcoreidx(&sii->pub, coreidx) +
regoff); regoff);
} }
ASSERT(r != NULL); ASSERT(r != NULL);
......
...@@ -383,7 +383,7 @@ static si_info_t *BCMATTACHFN(si_doattach) (si_info_t *sii, uint devid, ...@@ -383,7 +383,7 @@ static si_info_t *BCMATTACHFN(si_doattach) (si_info_t *sii, uint devid,
ASSERT(GOODREGS(regs)); ASSERT(GOODREGS(regs));
bzero((uchar *) sii, sizeof(si_info_t)); bzero((unsigned char *) sii, sizeof(si_info_t));
savewin = 0; savewin = 0;
...@@ -518,7 +518,7 @@ static si_info_t *BCMATTACHFN(si_doattach) (si_info_t *sii, uint devid, ...@@ -518,7 +518,7 @@ static si_info_t *BCMATTACHFN(si_doattach) (si_info_t *sii, uint devid,
ASSERT(GOODREGS(regs)); ASSERT(GOODREGS(regs));
bzero((uchar *) sii, sizeof(si_info_t)); bzero((unsigned char *) sii, sizeof(si_info_t));
savewin = 0; savewin = 0;
...@@ -913,7 +913,7 @@ uint si_corelist(si_t *sih, uint coreid[]) ...@@ -913,7 +913,7 @@ uint si_corelist(si_t *sih, uint coreid[])
sii = SI_INFO(sih); sii = SI_INFO(sih);
bcopy((uchar *) sii->coreid, (uchar *) coreid, bcopy((unsigned char *) sii->coreid, (unsigned char *) coreid,
(sii->numcores * sizeof(uint))); (sii->numcores * sizeof(uint)));
return sii->numcores; return sii->numcores;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment