linux/drivers/s390/net
Julian Wiedmann 5d4f78564c s390/qeth: implement smarter resizing of the RX buffer pool
The RX buffer pool is allocated in qeth_alloc_qdio_queues().
A subsequent pool resizing is then handled in a very simple way:
first free the current pool, then allocate a new pool of the requested
size.

There's two ways where this can go wrong:
1. if the resize action happens _before_ the initial pool was allocated,
   then a subsequent initialization will call qeth_alloc_qdio_queues()
   and fill the pool with a second(!) set of pages. We consume twice the
   planned amount of memory.
   This is easy to fix - just skip the resizing if the queues haven't
   been allocated yet.
2. if the initial pool was created by qeth_alloc_qdio_queues() but a
   subsequent resizing fails, then the device has no(!) RX buffer pool.
   The next initialization will _not_ call qeth_alloc_qdio_queues(), and
   attempting to back the RX buffers with pages in
   qeth_init_qdio_queues() will fail.
   Not very difficult to fix either - instead of re-allocating the whole
   pool, just allocate/free as many entries to match the desired size.

Fixes: 4a71df5004 ("qeth: new qeth device driver")
Signed-off-by: Julian Wiedmann <jwi@linux.ibm.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2020-03-11 23:52:31 -07:00
..
ctcm_dbug.c
ctcm_dbug.h
ctcm_fsms.c s390/ctcm: don't use intparm for channel IO 2019-08-20 13:51:46 -07:00
ctcm_fsms.h
ctcm_main.c s390/ctcm: Delete unnecessary checks before the macro call “dev_kfree_skb” 2019-09-16 21:45:32 +02:00
ctcm_main.h
ctcm_mpc.c s390/ctcm: don't use intparm for channel IO 2019-08-20 13:51:46 -07:00
ctcm_mpc.h
ctcm_sysfs.c
fsm.c Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/s390/linux 2017-11-30 08:13:36 -08:00
fsm.h
ism_drv.c s390/ism: move oddities of device IO to wrapper function 2019-04-29 10:47:01 +02:00
ism.h net/smc: immediate termination for SMCD link groups 2019-11-15 12:28:28 -08:00
Kconfig s390/Kconfig: pedantic cleanups 2019-06-04 15:03:46 +02:00
lcs.c s390/lcs: don't use intparm for channel IO 2019-08-20 13:51:46 -07:00
lcs.h net: convert lcs_reply.refcnt from atomic_t to refcount_t 2017-12-20 15:23:44 -05:00
Makefile s390/qeth: move ethtool code into its own file 2019-02-15 20:35:29 -08:00
netiucv.c s390: drivers: Remove redundant license text 2017-11-24 14:28:47 +01:00
qeth_core_main.c s390/qeth: implement smarter resizing of the RX buffer pool 2020-03-11 23:52:31 -07:00
qeth_core_mpc.c s390/qeth: allow cmd callbacks to return errnos 2019-02-12 13:14:24 -05:00
qeth_core_mpc.h Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2019-12-22 15:15:05 -08:00
qeth_core_sys.c s390/qeth: implement smarter resizing of the RX buffer pool 2020-03-11 23:52:31 -07:00
qeth_core.h s390/qeth: implement smarter resizing of the RX buffer pool 2020-03-11 23:52:31 -07:00
qeth_ethtool.c s390/qeth: guard against runt packets 2019-12-05 12:25:05 -08:00
qeth_l2_main.c s390/qeth: cancel RX reclaim work earlier 2020-03-10 16:07:49 -07:00
qeth_l2_sys.c s390/qeth: shift some bridgeport code around 2020-01-26 15:20:32 +01:00
qeth_l2.h s390/qeth: shift some bridgeport code around 2020-01-26 15:20:32 +01:00
qeth_l3_main.c s390/qeth: cancel RX reclaim work earlier 2020-03-10 16:07:49 -07:00
qeth_l3_sys.c s390/qeth: implement smarter resizing of the RX buffer pool 2020-03-11 23:52:31 -07:00
qeth_l3.h s390/qeth: stop yielding the ip_lock during IPv4 registration 2019-12-18 12:34:56 -08:00
smsgiucv_app.c s390: net: add SPDX identifiers to the remaining files 2017-11-24 14:28:43 +01:00
smsgiucv.c s390/smsgiucv: disable SMSG on module unload 2018-04-16 09:10:17 +02:00
smsgiucv.h