]> git.baikalelectronics.ru Git - kernel.git/commit
qed: Optimize execution time for nvm attributes configuration.
authorSudarsana Reddy Kalluru <skalluru@marvell.com>
Wed, 30 Oct 2019 08:39:58 +0000 (01:39 -0700)
committerDavid S. Miller <davem@davemloft.net>
Wed, 30 Oct 2019 18:57:14 +0000 (11:57 -0700)
commitc63b0968946b2d72178a92793bcc9439e19b385f
tree4540a2a91a2e35b660452f994dafcd75f6534eef
parentc6761cf521f9bffbdcbb619dba665ebf3bcefb1e
qed: Optimize execution time for nvm attributes configuration.

Current implementation for nvm_attr configuration instructs the management
FW to load/unload the nvm-cfg image for each user-provided attribute in
the input file. This consumes lot of cycles even for few tens of
attributes.
This patch updates the implementation to perform load/commit of the config
for every 50 attributes. After loading the nvm-image, MFW expects that
config should be committed in a predefined timer value (5 sec), hence it's
not possible to write large number of attributes in a single load/commit
window. Hence performing the commits in chunks.

Fixes: 0dabbe1bb3a4 ("qed: Add driver API for flashing the config attributes.")
Signed-off-by: Sudarsana Reddy Kalluru <skalluru@marvell.com>
Signed-off-by: Ariel Elior <aelior@marvell.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/qlogic/qed/qed_main.c