resctl, client: emulate sucessful resource allocation if Murphy is down.
authorKrisztian Litkey <krisztian.litkey@intel.com>
Wed, 4 Jun 2014 17:07:33 +0000 (20:07 +0300)
committerKrisztian Litkey <krisztian.litkey@intel.com>
Thu, 5 Jun 2014 14:16:38 +0000 (17:16 +0300)
commitf2765cf279042fed0a839183ecd72477e383dec3
treee4236143fa2c04f9337de164d28e201eab576d45
parent216a4703e990166dfb0c64bcb86f696987d51317
resctl, client: emulate sucessful resource allocation if Murphy is down.

With this patch in place, the server will now try to emulate resource
allocation (acquire/release) handling whenever the resource connection
(IOW connection to Murphy) is down.

This is the first shot at such an emulation. Hence, there are probably
bugs lingering in there... At least there are a few known issues with
handling the corner cases of the murphy-down -> murphy-up transition
with active grants. When murphy comes up we ask for the handed out
resources on behalf of the clients. However at the moment we can't
filter out the resulting focus change events even if there's no change
from the clients point of view. I suspect there might be a few more
serious issues hiding in there as well... more testing required.

As a final note, it might be a good idea to make this configurable at
least that much that those who want can completely turn off emulated
resource acquisition and opt for always failing when the connection
is down.
src/daemon/client.c
src/daemon/resctl.c
src/daemon/resctl.h