summaryrefslogtreecommitdiffstats
path: root/drivers/staging/brcm80211/util
diff options
context:
space:
mode:
authorGreg Kroah-Hartman2010-10-21 19:50:21 +0200
committerGreg Kroah-Hartman2010-10-21 19:50:21 +0200
commitf024c48a77c3c20d99de8f3424e8d3a061896885 (patch)
tree500bbcb1d1dc6d0e8f5872877b1f88fd090eb901 /drivers/staging/brcm80211/util
parentStaging: hv: remove struct vmbus_channel_interface (diff)
downloadkernel-qcow2-linux-f024c48a77c3c20d99de8f3424e8d3a061896885.tar.gz
kernel-qcow2-linux-f024c48a77c3c20d99de8f3424e8d3a061896885.tar.xz
kernel-qcow2-linux-f024c48a77c3c20d99de8f3424e8d3a061896885.zip
Staging: brcm80211: remove uintptr typedef usage
Use a unsigned long, that is the proper type for this type of thing on Linux. Cc: Brett Rudley <brudley@broadcom.com> Cc: Henry Ptasinski <henryp@broadcom.com> Cc: Nohee Ko <noheek@broadcom.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/staging/brcm80211/util')
-rw-r--r--drivers/staging/brcm80211/util/aiutils.c2
-rw-r--r--drivers/staging/brcm80211/util/bcmutils.c2
-rw-r--r--drivers/staging/brcm80211/util/hnddma.c24
-rw-r--r--drivers/staging/brcm80211/util/sbutils.c2
4 files changed, 15 insertions, 15 deletions
diff --git a/drivers/staging/brcm80211/util/aiutils.c b/drivers/staging/brcm80211/util/aiutils.c
index 512f4127ab9a..65461d0d91da 100644
--- a/drivers/staging/brcm80211/util/aiutils.c
+++ b/drivers/staging/brcm80211/util/aiutils.c
@@ -123,7 +123,7 @@ void ai_scan(si_t *sih, void *regs, uint devid)
case PCI_BUS:
/* Set wrappers address */
- sii->curwrap = (void *)((uintptr) regs + SI_CORE_SIZE);
+ sii->curwrap = (void *)((unsigned long)regs + SI_CORE_SIZE);
/* Now point the window at the erom */
OSL_PCI_WRITE_CONFIG(sii->osh, PCI_BAR0_WIN, 4, erombase);
diff --git a/drivers/staging/brcm80211/util/bcmutils.c b/drivers/staging/brcm80211/util/bcmutils.c
index c4c0136526c0..5635e8698acc 100644
--- a/drivers/staging/brcm80211/util/bcmutils.c
+++ b/drivers/staging/brcm80211/util/bcmutils.c
@@ -432,7 +432,7 @@ uint pktsetprio(void *pkt, bool update_vtag)
int rc = 0;
pktdata = (u8 *) PKTDATA(pkt);
- ASSERT(IS_ALIGNED((uintptr) pktdata, sizeof(u16)));
+ ASSERT(IS_ALIGNED((unsigned long)pktdata, sizeof(u16)));
eh = (struct ether_header *)pktdata;
diff --git a/drivers/staging/brcm80211/util/hnddma.c b/drivers/staging/brcm80211/util/hnddma.c
index 8526a4e6750f..3edef39962a7 100644
--- a/drivers/staging/brcm80211/util/hnddma.c
+++ b/drivers/staging/brcm80211/util/hnddma.c
@@ -218,7 +218,7 @@ static uint _dma_txcommitted(dma_info_t *di);
static void *_dma_peeknexttxp(dma_info_t *di);
static void *_dma_peeknextrxp(dma_info_t *di);
-static uintptr _dma_getvar(dma_info_t *di, const char *name);
+static unsigned long _dma_getvar(dma_info_t *di, const char *name);
static void _dma_counterreset(dma_info_t *di);
static void _dma_fifoloopbackenable(dma_info_t *di);
static uint _dma_ctrlflags(dma_info_t *di, uint mask, uint flags);
@@ -1363,10 +1363,10 @@ static uint _dma_ctrlflags(dma_info_t *di, uint mask, uint flags)
}
/* get the address of the var in order to change later */
-static uintptr _dma_getvar(dma_info_t *di, const char *name)
+static unsigned long _dma_getvar(dma_info_t *di, const char *name)
{
if (!strcmp(name, "&txavail"))
- return (uintptr) &(di->hnddma.txavail);
+ return (unsigned long)&(di->hnddma.txavail);
else {
ASSERT(0);
}
@@ -1409,7 +1409,7 @@ static void *dma_ringalloc(osl_t *osh, u32 boundary, uint size,
if (NULL == va)
return NULL;
- desc_strtaddr = (u32) roundup((uintptr) va, alignbytes);
+ desc_strtaddr = (u32) roundup((unsigned long)va, alignbytes);
if (((desc_strtaddr + size - 1) & boundary) != (desc_strtaddr
& boundary)) {
*alignbits = dma_align_sizetobits(size);
@@ -1534,7 +1534,7 @@ static bool dma32_alloc(dma_info_t *di, uint direction)
PHYSADDRHISET(di->txdpa, 0);
ASSERT(PHYSADDRHI(di->txdpaorig) == 0);
- di->txd32 = (dma32dd_t *) roundup((uintptr) va, align);
+ di->txd32 = (dma32dd_t *) roundup((unsigned long)va, align);
di->txdalign =
(uint) ((s8 *)di->txd32 - (s8 *) va);
@@ -1544,7 +1544,7 @@ static bool dma32_alloc(dma_info_t *di, uint direction)
ASSERT(PHYSADDRLO(di->txdpa) >= PHYSADDRLO(di->txdpaorig));
di->txdalloc = alloced;
- ASSERT(IS_ALIGNED((uintptr) di->txd32, align));
+ ASSERT(IS_ALIGNED((unsigned long)di->txd32, align));
} else {
va = dma_ringalloc(di->osh, D32RINGALIGN, size, &align_bits,
&alloced, &di->rxdpaorig, &di->rx_dmah);
@@ -1555,7 +1555,7 @@ static bool dma32_alloc(dma_info_t *di, uint direction)
PHYSADDRHISET(di->rxdpa, 0);
ASSERT(PHYSADDRHI(di->rxdpaorig) == 0);
- di->rxd32 = (dma32dd_t *) roundup((uintptr) va, align);
+ di->rxd32 = (dma32dd_t *) roundup((unsigned long)va, align);
di->rxdalign =
(uint) ((s8 *)di->rxd32 - (s8 *) va);
@@ -1564,7 +1564,7 @@ static bool dma32_alloc(dma_info_t *di, uint direction)
/* Make sure that alignment didn't overflow */
ASSERT(PHYSADDRLO(di->rxdpa) >= PHYSADDRLO(di->rxdpaorig));
di->rxdalloc = alloced;
- ASSERT(IS_ALIGNED((uintptr) di->rxd32, align));
+ ASSERT(IS_ALIGNED((unsigned long)di->rxd32, align));
}
return true;
@@ -2100,7 +2100,7 @@ static bool dma64_alloc(dma_info_t *di, uint direction)
return false;
}
align = (1 << align_bits);
- di->txd64 = (dma64dd_t *) roundup((uintptr) va, align);
+ di->txd64 = (dma64dd_t *) roundup((unsigned long)va, align);
di->txdalign = (uint) ((s8 *)di->txd64 - (s8 *) va);
PHYSADDRLOSET(di->txdpa,
PHYSADDRLO(di->txdpaorig) + di->txdalign);
@@ -2109,7 +2109,7 @@ static bool dma64_alloc(dma_info_t *di, uint direction)
PHYSADDRHISET(di->txdpa, PHYSADDRHI(di->txdpaorig));
di->txdalloc = alloced;
- ASSERT(IS_ALIGNED((uintptr) di->txd64, align));
+ ASSERT(IS_ALIGNED((unsigned long)di->txd64, align));
} else {
va = dma_ringalloc(di->osh, D64RINGALIGN, size, &align_bits,
&alloced, &di->rxdpaorig, &di->rx_dmah);
@@ -2118,7 +2118,7 @@ static bool dma64_alloc(dma_info_t *di, uint direction)
return false;
}
align = (1 << align_bits);
- di->rxd64 = (dma64dd_t *) roundup((uintptr) va, align);
+ di->rxd64 = (dma64dd_t *) roundup((unsigned long)va, align);
di->rxdalign = (uint) ((s8 *)di->rxd64 - (s8 *) va);
PHYSADDRLOSET(di->rxdpa,
PHYSADDRLO(di->rxdpaorig) + di->rxdalign);
@@ -2127,7 +2127,7 @@ static bool dma64_alloc(dma_info_t *di, uint direction)
PHYSADDRHISET(di->rxdpa, PHYSADDRHI(di->rxdpaorig));
di->rxdalloc = alloced;
- ASSERT(IS_ALIGNED((uintptr) di->rxd64, align));
+ ASSERT(IS_ALIGNED((unsigned long)di->rxd64, align));
}
return true;
diff --git a/drivers/staging/brcm80211/util/sbutils.c b/drivers/staging/brcm80211/util/sbutils.c
index 7b07513f0daf..ca49a805c996 100644
--- a/drivers/staging/brcm80211/util/sbutils.c
+++ b/drivers/staging/brcm80211/util/sbutils.c
@@ -90,7 +90,7 @@ static u32 _sb_coresba(si_info_t *sii)
switch (BUSTYPE(sii->pub.bustype)) {
case SPI_BUS:
case SDIO_BUS:
- sbaddr = (u32) (uintptr) sii->curmap;
+ sbaddr = (u32)(unsigned long)sii->curmap;
break;
default:
ASSERT(0);