dect
/
linux-2.6
Archived
13
0
Fork 0
Commit Graph

97 Commits

Author SHA1 Message Date
Franky Lin bbfd6a66ff brcmfmac: restrict dongle txglom disable to old SDIO core
txglomming is a firmware feature for sdio bus interface. For SDIO
device cores newer than revision 11, the default setting of
firmware should be used instead of disabling it from the host side.

Reviewed-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: Franky Lin <frankyl@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2012-06-27 15:23:17 -04:00
Arend van Spriel 8dc01811da brcmfmac: make inclusion of vmalloc.h explicit fixing linux-next build
This patch fixes problem detected in linux-next build for powerpc
allyesconfig. The error message below is no longer observed:

  CC      drivers/net/wireless/brcm80211/brcmfmac/dhd_sdio.o
drivers/net/wireless/brcm80211/brcmfmac/dhd_sdio.c: In function 'brcmf_sdio_dump_console':
drivers/net/wireless/brcm80211/brcmfmac/dhd_sdio.c:3085: error: implicit declaration of function 'vzalloc'
drivers/net/wireless/brcm80211/brcmfmac/dhd_sdio.c:3085: warning: assignment makes pointer from integer without a cast
drivers/net/wireless/brcm80211/brcmfmac/dhd_sdio.c:3113: error: implicit declaration of function 'vfree'
make[2]: *** [drivers/net/wireless/brcm80211/brcmfmac/dhd_sdio.o] Error 1

Reported-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2012-06-22 14:44:05 -04:00
Arend van Spriel 4fc0d0160d brcmfmac: introduce checkdied debugfs functionality
The checkdied functionality provides useful information for analyzing
firmware crashes. By exposing this information to a debugfs file users
can easily provide its content in bug reports. The functionality is
available only when CONFIG_BRCMDBG is selected.

Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Franky (Zhenhui) Lin <frankyl@broadcom.com>
Signed-off-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2012-06-20 14:41:49 -04:00
Arend van Spriel 80969836a7 brcmfmac: expose sdio internal counters in debugfs
The structure brcmf_sdio contains a number of counters that are useful
for debugging. These were not available in user-space. This patch
exposes them in debugfs under the filename 'counters'.

Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Franky (Zhenhui) Lin <frankyl@broadcom.com>
Signed-off-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2012-06-13 14:35:50 -04:00
Franky Lin 5c15c23a7b brcmfmac: remove function brcmf_sdcard_regfail
The new interface brcmf_sdio_regr/w provides result of access
attempts. It is no longer necessary to use dedicated variable
and function to provide enquiry for failure.

Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: Franky Lin <frankyl@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2012-05-15 17:27:58 -04:00
Franky Lin 5869275050 brcmfmac: remove redundant retries for SDIO core register access
The new brcmf_sdio_regrl/regwl interface has already performed
retries on failed attempts. It is no longer necessary to have the
retry mechanism in r_sdreg32/w_sdreg32.

Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: Franky Lin <frankyl@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2012-05-15 17:27:58 -04:00
Franky Lin e13ce26bd5 brcmfmac: replace brcmf_sdcard_reg_write with brcmf_sdio_regwl
Use the newly introduced brcmf_sdio_regwl to replace
brcmf_sdcard_reg_write as part of the SDIO WiFi dongle register
access interface clean up.

Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: Franky Lin <frankyl@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2012-05-15 17:27:57 -04:00
Franky Lin 79ae39570f brcmfmac: replace brcmf_sdcard_reg_read with brcmf_sdio_regrl
Use the newly introduced brcmf_sdio_regrl to replace
brcmf_sdcard_reg_read as part of the SDIO WiFi dongle register
access interface clean up.

Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: Franky Lin <frankyl@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2012-05-15 17:27:57 -04:00
Franky Lin 3bba829f63 brcmfmac: replace brcmf_sdcard_cfg_write with brcmf_sdio_regwb
Use the newly introduced brcmf_sdio_regwb to replace
brcmf_sdcard_cfg_write as part of the SDIO WiFi dongle register
access interface clean up.

Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: Franky Lin <frankyl@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2012-05-15 17:27:57 -04:00
Franky Lin 45db339cd2 brcmfmac: replace brcmf_sdcard_cfg_read with brcmf_sdio_regrb
Use the newly introduced brcmf_sdio_regrb to replace
brcmf_sdcard_cfg_read as part of the SDIO WiFi dongle register
access interface clean up.

Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: Franky Lin <frankyl@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2012-05-15 17:27:56 -04:00
Franky Lin ce454e8828 brcmfmac: remove unused parameter of brcmf_sdcard_reg_write
The size parameter for brcmf_sdcard_reg_write is always 4. Remove it
to make the code cleaner.

Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: Franky Lin <frankyl@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2012-05-15 17:27:55 -04:00
Franky Lin abb7fbb4a7 brcmfmac: remove unused parameter of brcmf_sdcard_reg_read
The size parameter for brcmf_sdcard_reg_read is always 4. Remove it
to make the code neat.

Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: Franky Lin <frankyl@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2012-05-15 17:27:55 -04:00
Franky Lin ba89bf1961 brcmfmac: add out of band interrupt support
Some sdio host controllers do not support real in band interrupt.
Software polling mode as a replacement is not fast enough for
high throughput and new features. Also some in band interrupts
do not support host wake up on embedded platform even when they
are real physical interrupts. Therefore out of band (oob)
interrupt mechanism is implemented for these scenarios.

To provide oob irq number and flags used for irq registration in
brcmfmac, a platform device contains irq resource must be
registered in board specific code.

Here is an example of platform device structure:
struct resource brcmf_sdio_res[] = {
	{
		.start	= GPIO_BRCMF_SDIO_OOB_NUM,
		.end	= GPIO_BRCMF_SDIO_OOB_NUM,
		.flags  = IORESOURCE_IRQ | IORESOURCE_IRQ_HIGHLEVEL,
	}
};
struct platform_device brcmf_sdio_device = {
	.name		= "brcmf_sdio_pd",
	.id		= -1,
	.num_resources	= ARRAY_SIZE(brcmf_sdio_res),
	.resource	= brcmf_sdio_res,
};

Reviewed-by: pieter-paul giesberts <pieterpg@broadcom.com>
Reviewed-by: arend van spriel <arend@broadcom.com>
Signed-off-by: franky lin <frankyl@broadcom.com>
Signed-off-by: Franky Lin <frankyl@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2012-05-08 21:53:55 -04:00
Franky Lin e2f93cc321 brcmfmac: postpone interrupt register function
For out of band interrupt which is going to be introduced shortly,
the interrupt register function must be called after firmware is
downloaded. This patch moves it from brcmf_sdbrcm_probe to
brcmf_sdbrcm_bus_init.

Reviewed-by: pieter-paul giesberts <pieterpg@broadcom.com>
Reviewed-by: arend van spriel <arend@broadcom.com>
Signed-off-by: franky lin <frankyl@broadcom.com>
Signed-off-by: Franky Lin <frankyl@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2012-05-08 21:53:54 -04:00
Franky Lin d9126e0c42 brcmfmac: check bus state for status
Bus state should be the correct flag for bus status. Use it instead
of result from previous function call for backplane clock switch.

Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: Franky Lin <frankyl@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2012-05-08 21:53:54 -04:00
David S. Miller 0d6c4a2e46 Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
Conflicts:
	drivers/net/ethernet/intel/e1000e/param.c
	drivers/net/wireless/iwlwifi/iwl-agn-rx.c
	drivers/net/wireless/iwlwifi/iwl-trans-pcie-rx.c
	drivers/net/wireless/iwlwifi/iwl-trans.h

Resolved the iwlwifi conflict with mainline using 3-way diff posted
by John Linville and Stephen Rothwell.  In 'net' we added a bug
fix to make iwlwifi report a more accurate skb->truesize but this
conflicted with RX path changes that happened meanwhile in net-next.

In e1000e a conflict arose in the validation code for settings of
adapter->itr.  'net-next' had more sophisticated logic so that
logic was used.

Signed-off-by: David S. Miller <davem@davemloft.net>
2012-05-07 23:35:40 -04:00
Franky Lin cf04317227 brcmfmac: fix a double spin_unlock_irqrestore issue in dpc
dpc_tl_lock is not acquired in the error handle code for bus down.
But it's unlocked using spin_unlock_irqrestore after finishing task
list walk down. Grab the lock before breaking the loop to avoid a
double unlock.

Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Franky Lin <frankyl@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2012-05-02 14:02:03 -04:00
Franky Lin b948a85c1f brcm80211: fmac: fix missing completion events issue
dpc takes care of all data packets transmissions for sdio function
2. It is possible that it misses some completion events when the
traffic is heavy or it's running on a slow cpu. A linked list is
introduced to make sure dpc is invoked whenever needed.

Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: Franky Lin <frankyl@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2012-04-27 15:20:39 -04:00
Arend van Spriel 474a64c80e brcm80211: fmac: register primary net device with device mac address
The primary net device was registered with a primary mac address and
upon IFUP it was set to match the actual mac address from the device.
This patch changes that and moves the brcmf_add_if() call to the common
part of the driver.

Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Franky (Zhenhui) Lin <frankyl@broadcom.com>
Signed-off-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2012-04-13 14:32:52 -04:00
John W. Linville 051d3b5043 Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-next into for-davem 2012-03-05 15:05:54 -05:00
Arend van Spriel 52e1409f72 brcm80211: fmac: make sdio firmware filename specific
The sdio driver part uses firmware name brcmfmac.bin. With addition
of usb this name is too generic. This patch renames the filename
to brcmfmac-sdio.bin.

Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Alwin Beukers <alwin@broadcom.com>
Reviewed-by: Franky (Zhenhui) Lin <frankyl@broadcom.com>
Signed-off-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2012-02-22 14:48:53 -05:00
Arend van Spriel 1bb1f38462 brcm80211: fmac: update bus state in common driver part
The bus state is updated in the sdio bus init function, but it is
better to do it when the brcmf_bus_start() function is completed
successfully. The brcmf_netdev_open() function will return -EAGAIN
until the state is updated instead of calling brcmf_bus_start() to
avoid reentering that function.

Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Franky (Zhenhui) Lin <frankyl@broadcom.com>
Signed-off-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2012-02-22 14:48:52 -05:00
Arend van Spriel c0e89f084b brcm80211: fmac: only return success in brcmf_sdbrcm_bus_init() when true
The function brcmf_sdbrcm_bus_init() always returned success except for
firmware download failure. However, also when enabling SDIO function 2
is failing the function should return failure. This patch fixes that.

Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Franky (Zhenhui) Lin <frankyl@broadcom.com>
Signed-off-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2012-02-22 14:48:51 -05:00
Arend van Spriel 0a332e4678 brcm80211: fmac: use specific types in struct brcmf_bus
The fields bus_priv and drvr are defined as void pointer. It is
preferred to have specific types for compiler type checking. To
prepare for other bus types the bus_priv field is defined as a
union containing the sdio bus private structure reference.

Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Franky (Zhenhui) Lin <frankyl@broadcom.com>
Signed-off-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2012-02-22 14:48:51 -05:00
Joe Perches 23677ce317 drivers/net: Remove boolean comparisons to true/false
Booleans should not be compared to true or false
but be directly tested or tested with !.

Done via cocci script:

@@
bool t;
@@
- t == true
+ t
@@
bool t;
@@
- t != true
+ !t
@@
bool t;
@@
- t == false
+ !t
@@
bool t;
@@
- t != false
+ t

Signed-off-by: Joe Perches <joe@perches.com>
Reviewed-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2012-02-13 00:47:40 -05:00
Joe Perches 02f77195db brcm80211: Use pr_fmt and pr_<level>
Convert printks to pr_<level>
Prefix logging with pr_fmt.
Use ##__VA_ARGS__ in some WL_ logging macros.

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2012-01-24 14:21:14 -05:00
Joe Perches 18aad4f8e1 brcm80211: Convert printk(KERN_DEBUG to pr_debug
Use pr_debug to allow dynamic debugging to work.

Move an #endif to allow brcmf_dbg_hex_dump
to be outside the #if/#endif block.
Move a const char* declaration to be inside a
pr_debug so the function doesn't need a #if/#endif
block.
Don't use temporaries in debugging functions so
the code can be optimized away.

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2012-01-24 14:21:14 -05:00
Joe Perches 8fb1eb8b22 brcmfmac: Remove useless #ifdef DEBUG
This doesn't do anything anymore.

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2012-01-24 14:21:14 -05:00
Joe Perches 1e02382979 brcm80211: Add and use brcmX_dbg_dump_hex
Reduce the number of #ifdef DEBUG uses by
adding a dbg_hex_dump routine which has the
appropriate #ifdef DEBUG test.

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2012-01-24 14:21:13 -05:00
Joe Perches 8ae746543c brcm80211: Use normal DEBUG define
Current CONFIG_BRCMDBG flag when enabled does not
necessarily enable proper pr_debug output when
DEBUG is not also enabled.

Remove BCMDBG define and just use DEBUG instead.

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2012-01-24 14:21:13 -05:00
Jesper Juhl c40701eacb brcm80211: Don't leak 'vbuffer' in brcmf_sdbrcm_write_vars()
If the memory allocation 'nvram_ularray = kmalloc(varsize,
GFP_ATOMIC);' fails we'll leak the memory allocated to 'vbuffer' when
we return -ENOMEM from the function.

This patch resolves the leak by kfree()'ing the allocated memory
before the return.

Signed-off-by: Jesper Juhl <jj@chaosbits.net>
Acked-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2012-01-10 15:46:40 -05:00
Franky Lin 54a86cc596 brcm80211: fmac: exclude unnecessary header files
This patch removes some headers files include lines from sdio layer
code. This is part of the fullmac bus interface refactoring.

Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Arend van Spriel <arend@broadcom.com>
Reviewed-by: Alwin Beukers <alwin@broadcom.com>
Signed-off-by: Franky Lin <frankyl@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-12-19 14:40:47 -05:00
Franky Lin 382a9e0f31 brcm80211: fmac: move idle macros to dhd_sdio.c
The idle macros are only used by dhd_sdio.c. It's more appropriate
to place them in dhd_sdio.c instead of dhd.h.

Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Arend van Spriel <arend@broadcom.com>
Reviewed-by: Alwin Beukers <alwin@broadcom.com>
Signed-off-by: Franky Lin <frankyl@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-12-19 14:40:47 -05:00
Franky Lin fcf094f414 brcm80211: fmac: abstract ctrl frames interface function pointers
Abstract bus layer brcmf_bus_txctl/brcmf_bus_rxctl function
pointers for common layer. This patch is part of the fullmac bus
interface refactoring.

Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Arend van Spriel <arend@broadcom.com>
Reviewed-by: Alwin Beukers <alwin@broadcom.com>
Signed-off-by: Franky Lin <frankyl@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-12-19 14:40:47 -05:00
Franky Lin b9692d17e8 brcm80211: fmac: abstract bus_txdata interface function pointer
Abstract bus layer brcmf_bus_txdata function pointer for common
layer. This patch is part of the fullmac bus interface refactoring.

Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Arend van Spriel <arend@broadcom.com>
Reviewed-by: Alwin Beukers <alwin@broadcom.com>
Signed-off-by: Franky Lin <frankyl@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-12-19 14:40:47 -05:00
Franky Lin 99a0b8ff91 brcm80211: fmac: abstract bus_init interface function pointer
Abstract bus layer brcmf_bus_init function pointer for common
layer. This patch is part of the fullmac bus interface refactoring.

Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Arend van Spriel <arend@broadcom.com>
Reviewed-by: Alwin Beukers <alwin@broadcom.com>
Signed-off-by: Franky Lin <frankyl@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-12-19 14:40:47 -05:00
Franky Lin a9ffda88be brcm80211: fmac: abstract bus_stop interface function pointer
Common layer should use interface function pointer stored in
brcmf_bus to invoke corresponding interface function in bus layer.
This patch is part of the fullmac bus interface refactoring.

Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Arend van Spriel <arend@broadcom.com>
Reviewed-by: Alwin Beukers <alwin@broadcom.com>
Signed-off-by: Franky Lin <frankyl@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-12-19 14:40:46 -05:00
Franky Lin 2447ffb0bd brcm80211: fmac: stop referencing brcmf_sdio in common layer
brcmf_sdio is the data structure for sdio bus layer. Stop
referencing brcmf_sdio from common layer. This patch is part of
the fullmac bus interface refactoring.

Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Arend van Spriel <arend@broadcom.com>
Reviewed-by: Alwin Beukers <alwin@broadcom.com>
Signed-off-by: Franky Lin <frankyl@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-12-19 14:40:46 -05:00
Franky Lin 712ac5b37a brcm80211: fmac: stop referencing brcmf_pub in bus layer
brcmf_pub is the data structure for common layer. Since brcmf_bus
should be the only structure shared by common layer and bus layer,
stop referencing brcmf_pub from bus layer. This patch is part of
the fullmac bus interface refactoring.

Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Arend van Spriel <arend@broadcom.com>
Reviewed-by: Alwin Beukers <alwin@broadcom.com>
Signed-off-by: Franky Lin <frankyl@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-12-19 14:40:46 -05:00
Franky Lin c8bf34849f brcm80211: fmac: move tx flow ctrl flag to bus layer
txoff is the flow control flag for transmit used in sdio layer.
Move it to bus layer data structure brcmf_sdio. Also flag
management code is moved out of brcmf_txflowcontrol(). This is
part of the fullmac bus interface refactoring.

Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Arend van Spriel <arend@broadcom.com>
Reviewed-by: Alwin Beukers <alwin@broadcom.com>
Signed-off-by: Franky Lin <frankyl@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-12-19 14:40:45 -05:00
Franky Lin 9c1a043ae6 brcm80211: fmac: move packet realloc stats to struct brcmf_bus
tx_realloc is used by both common layer and bus layer. This patch
moves it to interface structure brcmf_bus as part of the fullmac
bus interface refactoring.

Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Arend van Spriel <arend@broadcom.com>
Reviewed-by: Alwin Beukers <alwin@broadcom.com>
Signed-off-by: Franky Lin <frankyl@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-12-19 14:40:45 -05:00
Franky Lin 719f2733ba brcm80211: fmac: move dongle statistics to struct brcmf_bus
Dongle statistics are shared data between common layer and bus
layer. This patch places them in bus interface structure brcmf_bus
as part of the fullmac bus interface refactoring.

Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Arend van Spriel <arend@broadcom.com>
Reviewed-by: Alwin Beukers <alwin@broadcom.com>
Signed-off-by: Franky Lin <frankyl@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-12-19 14:40:45 -05:00
Franky Lin 4033927cb8 brcm80211: fmac: remove duplicate statistics from driver data structure
Some dongle statistics are stored in two places and synced when net
device status inquired. There is no need to do it this way any more.
Direct all usage to dongle stats structure in order to increase
readability.

Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Arend van Spriel <arend@broadcom.com>
Reviewed-by: Alwin Beukers <alwin@broadcom.com>
Signed-off-by: Franky Lin <frankyl@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-12-19 14:40:45 -05:00
Franky Lin 3fb1d8d2da brcm80211: fmac: move driver up status to struct brcmf_bus
Driver up/down status to network interface need to be shared by
common layer and bus layer. Move it to bus interface structure
brcmf_bus as part of the fullmac bus interface refactoring.

Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Arend van Spriel <arend@broadcom.com>
Reviewed-by: Alwin Beukers <alwin@broadcom.com>
Signed-off-by: Franky Lin <frankyl@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-12-19 14:40:45 -05:00
Franky Lin b01a6b3ca7 brcm80211: fmac: move maxctl to struct brcmf_bus
maxctl is the max size of rxctl request from protocol layer to bus
layer. Move it to bus interface structure brcmf_bus. This is part
of the fullmac bus interface refactoring.

Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Arend van Spriel <arend@broadcom.com>
Reviewed-by: Alwin Beukers <alwin@broadcom.com>
Signed-off-by: Franky Lin <frankyl@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-12-19 14:40:45 -05:00
Franky Lin 28a1a3bdaf brcm80211: fmac: move sdio used statistics to struct brcmf_sdio
Some statistics only used by sdio modules. Move them to sdio layer
private structure brcmf_sdio. This is part of the fullmac bus
interface refactoring.

Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Arend van Spriel <arend@broadcom.com>
Reviewed-by: Alwin Beukers <alwin@broadcom.com>
Signed-off-by: Franky Lin <frankyl@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-12-19 14:40:44 -05:00
Franky Lin d5625ee66f brcm80211: fmac: change function proto_hdrpull parameter
Change parameter to device pointer for bus layer interface function
brcmf_proto_hdrpull This is part of the fullmac bus interface
refactoring.

Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Arend van Spriel <arend@broadcom.com>
Reviewed-by: Alwin Beukers <alwin@broadcom.com>
Signed-off-by: Franky Lin <frankyl@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-12-19 14:40:44 -05:00
Franky Lin 228bb43d5d brcm80211: fmac: change function rx_frame parameter
Change parameter to device pointer for bus layer interface function
brcmf_rx_frame. This is part of the fullmac bus interface
refactoring.

Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Arend van Spriel <arend@broadcom.com>
Reviewed-by: Alwin Beukers <alwin@broadcom.com>
Signed-off-by: Franky Lin <frankyl@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-12-19 14:40:44 -05:00
Franky Lin b63487ed3d brcm80211: fmac: change function brcmf_c_prec_enq parameter
Change parameter to device pointer for bus layer interface function
brcmf_c_prec_enq. This is part of the fullmac bus interface
refactoring.

Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Arend van Spriel <arend@broadcom.com>
Reviewed-by: Alwin Beukers <alwin@broadcom.com>
Signed-off-by: Franky Lin <frankyl@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-12-19 14:40:44 -05:00
Franky Lin c995788f47 brcm80211: fmac: change function txcomplete parameter
Change parameter to device pointer for bus layer interface function
brcmf_txcomplete. This is part of the fullmac bus interface
refactoring.

Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Arend van Spriel <arend@broadcom.com>
Reviewed-by: Alwin Beukers <alwin@broadcom.com>
Signed-off-by: Franky Lin <frankyl@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-12-19 14:40:44 -05:00