Create OCC objects on app startup

Previously OCC objects would be created either in response (D-Bus
signals) to CPU inventory objects being created, or if the CPU objects
were already present when the openpower-occ-control app starts. We've
had few issues where it has seemed like the OCC objects never got
created, or did not get created in time; the CPU objects were created
though. This is suggestive of either a race, or the D-Bus signal being
missed altogether.

Simplify by creating OCC objects when the app starts (we know how many
OCC objects to create based on system specific config), instead of doing
it reactively. The OCC objects will be marked active only when we're
sent a sensor from the host asking to do so. That's not changing.

Change-Id: I782ea4f120292542e3c7b32b1e0acfa8efb5e8e6
Signed-off-by: Deepak Kodihalli <dkodihal@in.ibm.com>
1 file changed