Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 997dd24f authored by Brett Rudley's avatar Brett Rudley Committed by Greg Kroah-Hartman
Browse files

staging: brcm80211: Remove pkttag from osl

parent df0d8bb8
Loading
Loading
Loading
Loading
+3 −3
Original line number Original line Diff line number Diff line
@@ -188,7 +188,7 @@ int bcmsdh_probe(struct device *dev)
	}
	}
#endif				/* defined(OOB_INTR_ONLY) */
#endif				/* defined(OOB_INTR_ONLY) */
	/* allocate SDIO Host Controller state info */
	/* allocate SDIO Host Controller state info */
	osh = osl_attach(dev, PCI_BUS, false);
	osh = osl_attach(dev, PCI_BUS);
	if (!osh) {
	if (!osh) {
		SDLX_MSG(("%s: osl_attach failed\n", __func__));
		SDLX_MSG(("%s: osl_attach failed\n", __func__));
		goto err;
		goto err;
@@ -384,7 +384,7 @@ bcmsdh_pci_probe(struct pci_dev *pdev, const struct pci_device_id *ent)


		SDLX_MSG(("%s: Disabling TI FlashMedia Controller.\n",
		SDLX_MSG(("%s: Disabling TI FlashMedia Controller.\n",
			  __func__));
			  __func__));
		osh = osl_attach(pdev, PCI_BUS, false);
		osh = osl_attach(pdev, PCI_BUS);
		if (!osh) {
		if (!osh) {
			SDLX_MSG(("%s: osl_attach failed\n", __func__));
			SDLX_MSG(("%s: osl_attach failed\n", __func__));
			goto err;
			goto err;
@@ -419,7 +419,7 @@ bcmsdh_pci_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
	 */
	 */


	/* allocate SDIO Host Controller state info */
	/* allocate SDIO Host Controller state info */
	osh = osl_attach(pdev, PCI_BUS, false);
	osh = osl_attach(pdev, PCI_BUS);
	if (!osh) {
	if (!osh) {
		SDLX_MSG(("%s: osl_attach failed\n", __func__));
		SDLX_MSG(("%s: osl_attach failed\n", __func__));
		goto err;
		goto err;
+1 −1
Original line number Original line Diff line number Diff line
@@ -1865,7 +1865,7 @@ static int dhd_open(struct net_device *net)


osl_t *dhd_osl_attach(void *pdev, uint bustype)
osl_t *dhd_osl_attach(void *pdev, uint bustype)
{
{
	return osl_attach(pdev, bustype, true);
	return osl_attach(pdev, bustype);
}
}


void dhd_osl_detach(osl_t *osh)
void dhd_osl_detach(osl_t *osh)
+1 −9
Original line number Original line Diff line number Diff line
@@ -18,7 +18,7 @@
#define _linux_osl_h_
#define _linux_osl_h_




extern osl_t *osl_attach(void *pdev, uint bustype, bool pkttag);
extern osl_t *osl_attach(void *pdev, uint bustype);
extern void osl_detach(osl_t *osh);
extern void osl_detach(osl_t *osh);


extern u32 g_assert_type;
extern u32 g_assert_type;
@@ -56,7 +56,6 @@ extern uint osl_pci_slot(osl_t *osh);


/* Pkttag flag should be part of public information */
/* Pkttag flag should be part of public information */
typedef struct {
typedef struct {
	bool pkttag;
	uint pktalloced;	/* Number of allocated packet buffers */
	uint pktalloced;	/* Number of allocated packet buffers */
	bool mmbus;		/* Bus supports memory-mapped register accesses */
	bool mmbus;		/* Bus supports memory-mapped register accesses */
	pktfree_cb_fn_t tx_fn;	/* Callback function for PKTFREE */
	pktfree_cb_fn_t tx_fn;	/* Callback function for PKTFREE */
@@ -285,7 +284,6 @@ extern void osl_dma_unmap(osl_t *osh, uint pa, uint size, int direction);
#define	PKTSETLEN(skb, len)	__skb_trim((struct sk_buff *)(skb), (len))
#define	PKTSETLEN(skb, len)	__skb_trim((struct sk_buff *)(skb), (len))
#define	PKTPUSH(skb, bytes)	skb_push((struct sk_buff *)(skb), (bytes))
#define	PKTPUSH(skb, bytes)	skb_push((struct sk_buff *)(skb), (bytes))
#define	PKTPULL(skb, bytes)	skb_pull((struct sk_buff *)(skb), (bytes))
#define	PKTPULL(skb, bytes)	skb_pull((struct sk_buff *)(skb), (bytes))
#define	PKTTAG(skb)		((void *)(((struct sk_buff *)(skb))->cb))
#define PKTALLOCED(osh)		(((osl_pubinfo_t *)(osh))->pktalloced)
#define PKTALLOCED(osh)		(((osl_pubinfo_t *)(osh))->pktalloced)
#define PKTSETPOOL(osh, skb, x, y)	do {} while (0)
#define PKTSETPOOL(osh, skb, x, y)	do {} while (0)
#define PKTPOOL(osh, skb)		false
#define PKTPOOL(osh, skb)		false
@@ -301,9 +299,6 @@ osl_pkt_frmnative(osl_pubinfo_t *osh, struct sk_buff *skb)
{
{
	struct sk_buff *nskb;
	struct sk_buff *nskb;


	if (osh->pkttag)
		bzero((void *)skb->cb, OSL_PKTTAG_SZ);

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


@@ -317,9 +312,6 @@ osl_pkt_tonative(osl_pubinfo_t *osh, void *pkt)
{
{
	struct sk_buff *nskb;
	struct sk_buff *nskb;


	if (osh->pkttag)
		bzero(((struct sk_buff *)pkt)->cb, OSL_PKTTAG_SZ);

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


+0 −2
Original line number Original line Diff line number Diff line
@@ -21,8 +21,6 @@
typedef struct osl_info osl_t;
typedef struct osl_info osl_t;
typedef struct osl_dmainfo osldma_t;
typedef struct osl_dmainfo osldma_t;


#define OSL_PKTTAG_SZ	32	/* Size of PktTag */

/* Drivers use PKTFREESETCB to register a callback function when a packet is freed by OSL */
/* Drivers use PKTFREESETCB to register a callback function when a packet is freed by OSL */
typedef void (*pktfree_cb_fn_t) (void *ctx, void *pkt, unsigned int status);
typedef void (*pktfree_cb_fn_t) (void *ctx, void *pkt, unsigned int status);


+1 −2
Original line number Original line Diff line number Diff line
@@ -789,8 +789,7 @@ static wl_info_t *wl_attach(u16 vendor, u16 device, unsigned long regs,
		return NULL;
		return NULL;
	}
	}


	/* Requires pkttag feature */
	osh = osl_attach(btparam, bustype);
	osh = osl_attach(btparam, bustype, true);
	ASSERT(osh);
	ASSERT(osh);


#ifdef WLC_HIGH_ONLY
#ifdef WLC_HIGH_ONLY
Loading