Skip to content

Commit

Permalink
Staging: sxg: fix compiler warnings.
Browse files Browse the repository at this point in the history
sizeof() isn't an unsigned long :(

Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  • Loading branch information
Greg Kroah-Hartman committed Oct 22, 2008
1 parent c6c25ed commit d78404c
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions drivers/staging/sxg/sxg.c
Original file line number Diff line number Diff line change
Expand Up @@ -460,8 +460,8 @@ static int sxg_allocate_resources(p_adapter_t adapter)
/* fails. If we hit a minimum, fail. */

for (;;) {
DBG_ERROR("%s Allocate XmtRings size[%lx]\n", __func__,
(sizeof(SXG_XMT_RING) * 1));
DBG_ERROR("%s Allocate XmtRings size[%x]\n", __func__,
(unsigned int)(sizeof(SXG_XMT_RING) * 1));

/* Start with big items first - receive and transmit rings. At the moment */
/* I'm going to keep the ring size fixed and adjust the number of */
Expand All @@ -477,8 +477,8 @@ static int sxg_allocate_resources(p_adapter_t adapter)
}
memset(adapter->XmtRings, 0, sizeof(SXG_XMT_RING) * 1);

DBG_ERROR("%s Allocate RcvRings size[%lx]\n", __func__,
(sizeof(SXG_RCV_RING) * 1));
DBG_ERROR("%s Allocate RcvRings size[%x]\n", __func__,
(unsigned int)(sizeof(SXG_RCV_RING) * 1));
adapter->RcvRings =
pci_alloc_consistent(adapter->pcidev,
sizeof(SXG_RCV_RING) * 1,
Expand Down Expand Up @@ -538,8 +538,8 @@ static int sxg_allocate_resources(p_adapter_t adapter)
return (STATUS_RESOURCES);
}

DBG_ERROR("%s Allocate EventRings size[%lx]\n", __func__,
(sizeof(SXG_EVENT_RING) * RssIds));
DBG_ERROR("%s Allocate EventRings size[%x]\n", __func__,
(unsigned int)(sizeof(SXG_EVENT_RING) * RssIds));

/* Allocate event queues. */
adapter->EventRings = pci_alloc_consistent(adapter->pcidev,
Expand Down Expand Up @@ -569,8 +569,8 @@ static int sxg_allocate_resources(p_adapter_t adapter)
}
memset(adapter->Isr, 0, sizeof(u32) * IsrCount);

DBG_ERROR("%s Allocate shared XMT ring zero index location size[%lx]\n",
__func__, sizeof(u32));
DBG_ERROR("%s Allocate shared XMT ring zero index location size[%x]\n",
__func__, (unsigned int)sizeof(u32));

/* Allocate shared XMT ring zero index location */
adapter->XmtRingZeroIndex = pci_alloc_consistent(adapter->pcidev,
Expand Down

0 comments on commit d78404c

Please sign in to comment.