| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The current code only allowed the MODE_<type><Num> env var
to be "label" when doing DBus naming indirection.
Add support to allow it to be anything, and then use that value
to do the lookup.
For example, if MODE_temp1 = "foo", then the code will read the
temp1_foo file to find the value to append to LABEL to find the
DBus object name. So if temp1_foo contained a 42, then the code
will use the LABEL_temp42 var to find the object name.
Tested: Test on the OpenPower OCC device which use 'label' and now
'function_id' for the indirections.
Change-Id: I1f3115a2d37d008efca74748ac7eff8434d8320a
Signed-off-by: Matt Spinler <spinler@us.ibm.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
Wrapped the cstdlib::getenv() call into env::getEnv
so that it can be tested by mocking the env namespace,
by just dropping in test_env.cpp which implements those
methods and tying them a singleton upon which we can set
expectations.
Note: regardless of the approach taken to mock this, wrapping
this method is a good fix.
Change-Id: I65d22da08fc3dd76e6860f728c54e6c847ed07de
Signed-off-by: Patrick Venture <venture@google.com>
|
| |
|
|
|
|
|
|
| |
Move the getEnv(...) methods into the env namespace,
for consistency.
Change-Id: I4055d9456c17f8b20071cdee1b8e531c10fb0c7e
Signed-off-by: Patrick Venture <venture@google.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
The current daemon only supports RPM-based fan control, whereas the
hwmon interface for PWM is often present. This implements the Fan
Control PWM dbus interface.
This CL is not the complete solution, but if mixed with a follow-on CL
that does this, I think it'll be ideal. For instance, this assumes the
pwm number matches, whereas the other CL lets you specify the
corresponding PWM target for the fan.
Change-Id: I23aaa0619cdefba0a004ac0d26dc6b928e78f1e8
Signed-off-by: Patrick Venture <venture@google.com>
|
| |
|
|
|
|
|
| |
It is no longer used.
Change-Id: I4713fbd9232dfeed045125cbb827b4fe98c53717
Signed-off-by: Matt Spinler <spinler@us.ibm.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
This function will look up the sensor ID for a sensor when
it is specified in a label file in hwmon sysfs.
This functionality was previously all contained in
getIndirectlLabelEnv(). A future commit will remove this
function entirely and just use getIndirectID() and getEnv()
to look up the label for the indirect case.
Change-Id: Ifeb636eb0e58a6204f782f64e9aba839b812a967
Signed-off-by: Matt Spinler <spinler@us.ibm.com>
|
| |
|
|
|
|
|
|
| |
The new version takes the type and ID parameters
separately as opposed to together in a key_type.
Change-Id: I7796e8e6d680ffb640028e91eb3dcc8e7d99bc2e
Signed-off-by: Matt Spinler <spinler@us.ibm.com>
|
| |
|
|
|
|
|
|
|
|
|
|
| |
The current design ignores the itemX_label sysfs attribute, if the
environment variable is populated with the MODE_itemX="label", then
fetch the label from itemX_label file.The actual label for the dbus
object is fetched from the environment variable LABEL_item<label>.
Resolves openbmc/openbmc#1633
Change-Id: I0d4baaa91073dd5db75ac62277d78ad9b3065e64
Signed-off-by: Tom Joseph <tomjoseph@in.ibm.com>
|
|
|
Sensor configuration is passed to the application via the enviroment.
Create a map of environment values for a given sensor.
Change-Id: I8369eda27798fd9472166e898b8d6166c6997392
Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
|