Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 228282
b: refs/heads/master
c: 411ee44
h: refs/heads/master
v: v3
  • Loading branch information
Brett Rudley authored and Greg Kroah-Hartman committed Dec 7, 2010
1 parent 7d1e4a1 commit 5509dd1
Show file tree
Hide file tree
Showing 4 changed files with 36 additions and 38 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: ec7957049668b4fcf755cd8a085cfe258d77fc9b
refs/heads/master: 411ee44ad30b2a8c99c3b225a3cf381ec37b000e
9 changes: 9 additions & 0 deletions trunk/drivers/staging/brcm80211/brcmfmac/dhd_cdc.c
Original file line number Diff line number Diff line change
Expand Up @@ -298,6 +298,15 @@ dhd_prot_ioctl(dhd_pub_t *dhd, int ifidx, wl_ioctl_t *ioc, void *buf, int len)
return ret;
}

#define PKTSUMNEEDED(skb) \
(((struct sk_buff *)(skb))->ip_summed == CHECKSUM_PARTIAL)
#define PKTSETSUMGOOD(skb, x) \
(((struct sk_buff *)(skb))->ip_summed = \
((x) ? CHECKSUM_UNNECESSARY : CHECKSUM_NONE))

/* PKTSETSUMNEEDED and PKTSUMGOOD are not possible because
skb->ip_summed is overloaded */

int
dhd_prot_iovar_op(dhd_pub_t *dhdp, const char *name,
void *params, int plen, void *arg, int len, bool set)
Expand Down
26 changes: 26 additions & 0 deletions trunk/drivers/staging/brcm80211/brcmfmac/dhd_linux.c
Original file line number Diff line number Diff line change
Expand Up @@ -1052,6 +1052,32 @@ int dhd_sendpkt(dhd_pub_t *dhdp, int ifidx, struct sk_buff *pktbuf)
return ret;
}

static inline void *
osl_pkt_frmnative(struct osl_info *osh, struct sk_buff *skb)
{
struct sk_buff *nskb;

for (nskb = skb; nskb; nskb = nskb->next)
osh->pktalloced++;

return (void *)skb;
}
#define PKTFRMNATIVE(osh, skb) \
osl_pkt_frmnative((osh), (struct sk_buff *)(skb))

static inline struct sk_buff *
osl_pkt_tonative(struct osl_info *osh, void *pkt)
{
struct sk_buff *nskb;

for (nskb = (struct sk_buff *)pkt; nskb; nskb = nskb->next)
osh->pktalloced--;

return (struct sk_buff *)pkt;
}
#define PKTTONATIVE(osh, pkt) \
osl_pkt_tonative((osh), (pkt))

static int dhd_start_xmit(struct sk_buff *skb, struct net_device *net)
{
int ret;
Expand Down
37 changes: 0 additions & 37 deletions trunk/drivers/staging/brcm80211/include/osl.h
Original file line number Diff line number Diff line change
Expand Up @@ -249,43 +249,6 @@ extern void osl_dma_unmap(struct osl_info *osh, uint pa, uint size,
extern void *osl_pktget(struct osl_info *osh, uint len);
extern void osl_pktfree(struct osl_info *osh, void *skb, bool send);

#ifdef BRCM_FULLMAC
static inline void *
osl_pkt_frmnative(struct osl_info *osh, struct sk_buff *skb)
{
struct sk_buff *nskb;

for (nskb = skb; nskb; nskb = nskb->next)
osh->pktalloced++;

return (void *)skb;
}
#define PKTFRMNATIVE(osh, skb) \
osl_pkt_frmnative((osh), (struct sk_buff *)(skb))

static inline struct sk_buff *
osl_pkt_tonative(struct osl_info *osh, void *pkt)
{
struct sk_buff *nskb;

for (nskb = (struct sk_buff *)pkt; nskb; nskb = nskb->next)
osh->pktalloced--;

return (struct sk_buff *)pkt;
}
#define PKTTONATIVE(osh, pkt) \
osl_pkt_tonative((osh), (pkt))
#endif /* BRCM_FULLMAC */

#define PKTSUMNEEDED(skb) \
(((struct sk_buff *)(skb))->ip_summed == CHECKSUM_PARTIAL)
#define PKTSETSUMGOOD(skb, x) \
(((struct sk_buff *)(skb))->ip_summed = \
((x) ? CHECKSUM_UNNECESSARY : CHECKSUM_NONE))
/* PKTSETSUMNEEDED and PKTSUMGOOD are not possible because
skb->ip_summed is overloaded */


#define SET_REG(osh, r, mask, val) \
W_REG((osh), (r), ((R_REG((osh), r) & ~(mask)) | (val)))

Expand Down

0 comments on commit 5509dd1

Please sign in to comment.