]> git.baikalelectronics.ru Git - uboot.git/commit
net: mvpp2: simplify mvpp2_bm_bufs_add()
authorThomas Petazzoni <thomas.petazzoni@free-electrons.com>
Wed, 15 Feb 2017 11:13:43 +0000 (12:13 +0100)
committerStefan Roese <sr@denx.de>
Wed, 29 Mar 2017 05:39:49 +0000 (07:39 +0200)
commite3d5b7fa0adfd83d14aa2979272611ad97b06c7b
treef8564e1ed949152fdedaa3e8ee9e5d9492ab8207
parent3ecdc381ee58e121dfe5095ab4b5603875c1ab88
net: mvpp2: simplify mvpp2_bm_bufs_add()

The mvpp2_bm_bufs_add() currently creates a fake cookie by calling
mvpp2_bm_cookie_pool_set(), just to be able to call
mvpp2_pool_refill(). But all what mvpp2_pool_refill() does is extract
the pool ID from the cookie, and call mvpp2_bm_pool_put() with this ID.

Instead of doing this convoluted thing, just call mvpp2_bm_pool_put()
directly, since we have the BM pool ID.

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Signed-off-by: Stefan Roese <sr@denx.de>
Acked-by: Joe Hershberger <joe.hershberger@ni.com>
drivers/net/mvpp2.c