mei: limit the number of queued writes
authorAlexander Usyskin <alexander.usyskin@intel.com>
Sun, 25 Feb 2018 18:07:05 +0000 (20:07 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 14 Mar 2018 18:33:13 +0000 (19:33 +0100)
commitaf336cabe08363ba8493e7d7e5d070353eb30caa
tree003025b642d6dcfab2a2f5ba220ce69ee69def65
parent257355a44b9929e55d6fd47bfff66971dc4de948
mei: limit the number of queued writes

Limit the number of queued writes per client.
Writes above this threshold are blocked till place
in the transmit queue is available.
The limit is configurable via sysfs and defaults to 50.
The implementation should provide blocking I/O behavior.
Prior to this change one would end up in the hands of OOM.

Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com>
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Documentation/ABI/testing/sysfs-class-mei
drivers/misc/mei/bus.c
drivers/misc/mei/client.c
drivers/misc/mei/debugfs.c
drivers/misc/mei/init.c
drivers/misc/mei/main.c
drivers/misc/mei/mei_dev.h