| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
| |
Device names changed in 4.13, so update them here.
Change-Id: Ieb92f55499f3577dbfd737ea870a69dd4f351bc2
Signed-off-by: Eddie James <eajames@us.ibm.com>
|
|
|
|
|
|
|
|
|
|
|
| |
OCC communication can get intermittent failures. Retry
all reads 3 times before declaring a failure and exiting
out of the openpower-occ-control application.
Resolves openbmc/openbmc#2805
Change-Id: I34dca5bc3c19a1f88975b427bdb6a683b41dbcb7
Signed-off-by: Andrew Geissler <geissonator@yahoo.com>
|
|
|
|
|
|
|
|
|
|
|
| |
Modified default value for install_error_yaml configure option
to "No"
As the option is set to "yes" during build it is not finding
packages that are required for target build.
Change-Id: I0813bf2c59ecfb63bcb0da3c4a55cc51f378d553
Signed-off-by: Marri Devender Rao <devenrao@in.ibm.com>
|
|
|
|
|
| |
Change-Id: Id7ffc23fbea28f303521bb04faaaa13b931a3e09
Signed-off-by: Marri Devender Rao <devenrao@in.ibm.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
The OCC present count returns the number of OCCs in the system. Before
we have bound the second OCC, this will be greater than the number of
OCCs the Manager has counted as Active, resulting in a mismatch, causing
an error.
Resolves openbmc/openbmc#2733
Change-Id: Ia37a6b152fb073cf3044c601501903bcdfe9d3fe
Signed-off-by: Eddie James <eajames@us.ibm.com>
|
|
|
|
|
|
|
|
|
|
| |
Driver and OCC application should now correctly report errors from the
OCC with no false positives.
Resolves openbmc/openbmc#2285
Change-Id: Ifc4668ab75f26529f071317ead6ab4f77c3a0e7c
Signed-off-by: Edward A. James <eajames@us.ibm.com>
|
|
|
|
|
|
|
|
|
|
| |
P8 uses i2c-occ and powercap is not created.
Add P8 support by creating powercap object with i2c device name.
Fixes openbmc/openbmc#2688
Change-Id: Ia63070d63f4392cc4b084ab628cdbdcf4206c883
Signed-off-by: Lei YU <mine260309@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
| |
Add Error objects to watch the sysfs entries provided by the OCC hwmon
driver that report various types of throttling. Also needed to add a
boolean input to the Error callback interface.
Resolves openbmc/openbmc#1821
Change-Id: I4425770a92ace0f73024b3dc4c577ce46957a62a
Signed-off-by: Eddie James <eajames@us.ibm.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add a Presence child class of Error to handle detecting the number of
OCCs available. Add an instance of this Presence class if the Device
detects that it is the master OCC, since the number of present OCCs is
only reported by the master OCC. When a change to the number of OCCs
reported is detected, compare with the number of OCCs determined to be
active by the Manager, and if there is a mismatch, follow the usual
error path (reset OCC, etc).
Partially resolves openbmc/openbmc#2285
See https://gerrit.openbmc-project.xyz/#/c/7843/
Change-Id: Idbaca52b307992d9b01fe15439ab746ef6d64397
Signed-off-by: Edward A. James <eajames@us.ibm.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This happens with bmc reboot if the host is up. BMC comes back up and
initial fsi load binds the first proc occ-hwmon device. OCC controller
starts and see's its bound, so occActive goes true. FSI rescan occurs
since host is up, unloading the first proc occ-hwmon device... Now we
can't enable it again since occActive is still true.
Resolves openbmc/openbmc#2325
Change-Id: Iac838bc51d1110f502ca0c7c5da78dc5e1780c98
Signed-off-by: Edward A. James <eajames@us.ibm.com>
|
|
|
|
|
|
|
|
| |
Journal entry variable names should be uppercase.
https://www.freedesktop.org/software/systemd/man/sd_journal_print.html
Change-Id: I73f88faec688e2e95a5bad5f974306b005128504
Signed-off-by: Gunnar Mills <gmills@us.ibm.com>
|
|
|
|
|
|
|
|
|
| |
Spelling errors found using github.com/lucasdemarchi/codespell
A tool to fix common misspellings.
This tool is licensed under GNU General Public License, version 2.
Change-Id: Ie5e9c8d7452af232c939ad7716b707bfe19b3c1e
Signed-off-by: Gunnar Mills <gmills@us.ibm.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
I2c occ dbus objects path were their i2c addresses, e.g. 3_0050.
This does not indicate it's occ objects, and it does not work with
op-occ-disable/enable services, which searches "occ" key words in object
path.
So add "occ_" prefix for i2c occ dbus objects, e.g. occ_3_0050, to
indicate it's occ objects and work well with op-occ-disable/enable
services.
Change-Id: I21712f2fb7cf6138248f6986b84f99c90c3fa3a2
Signed-off-by: Lei YU <mine260309@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Previously the app would watch for CPU inventory being created (in
order to create OCC objects) only if no CPU inventory existed when the
app starts. This logic breaks when some of the CPUs exist out of the max
possible, because we would never watch for those missing CPU objects
being potentially created in the next boot.
Instead, always watch for CPU inventory being created via the d-bus
InterfacesAdded signal. This is safe in case a persisted CPU object
existed in the inventory, because the signal would not fire on that
object.
Resolves openbmc/openbmc#2515.
Change-Id: I0b7ae84d98cd05fe355d4ff56ebaa14da3a3098a
Signed-off-by: Deepak Kodihalli <dkodihal@in.ibm.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
OCC d-bus objects are typically created in response to the CPU inventory
being created. At this point of time we just know the CPU is present. It
may not be functional. Of course if the CPU is not functional, then the
host may or may not choose to set the OCC active, but the OCC object
must have been created in response to a present CPU.
This commit employs the same logic for reconstructing OCC objects when
the OCC app restarts. Previously an OCC object would be created only if
corresponding CPU is present and functional. Instead, check only for
presence.
Change-Id: I4f85a644237b5b5aa7dc3e52d266375b786a8c0a
Signed-off-by: Deepak Kodihalli <dkodihal@in.ibm.com>
|
|
|
|
|
|
|
|
| |
occ_manager.hpp is growing and hence this commit splits
into header and source files
Change-Id: I3203520c50910d39055fea98b770de55796bb074
Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Host sends OCC active status command just once as part
of power on operation and when that is sent, occ control
application binds the device. As part of bind, a sysfs
file gets created that would be used to communicate the
occ error status back to user.
If occ control application terminates and restarts, then
it needs some way to set OccActive property and this commit
adds that support.
Solution is to check if the device is already bound by checking
the presence of the OCC_HWMON_PATH/occ<number>-dev0 and set the
property if found
Fixes openbmc/openbmc#2238
Change-Id: I920b52e3970cc91af50b5bc68ead44c66eab8944
Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
|
|
|
|
|
|
|
| |
This is a quick hack until openbmc/openbmc#2285 is resolved
Change-Id: I2cb5f61a258bdfe014df63a0b44e444e13d366a9
Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
|
|
|
|
|
|
|
|
| |
Scanning hub FSI is now moved to a service file since it's
needed prior to power on and hence this change is not needed.
Change-Id: If2d0d8f5c7e1b405d6e858e0f2da8fc7b505cd86
Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
For a fd watching for data in sysfs file, a poll would return
immediately after read unless file is closed and re-opened OR
stream is seeked to 0. This commit chooses latter.
From stackoverflow:
Once poll/select indicates that the value has changed, you need to close and
re-open the file, or seek to 0 and read again.
Also, use EPOLLPRI | EPOLLERR than EPOLLIN as needed by sysfs_inotify
Change-Id: I243cdfd9a09c567eac5e52abd9980ebf90b94f89
Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
getService() has [bus, interface, path] as parameter and
the caller invoked it with [bus, path, interface] and that
resulted in a failure. Although the fix can be put into the
caller to pass the right arguments, better fix would be to
change the signature of getService() to receive path and then
the interface as that is what has been followed all over and
the deviation resulted in this bug.
Change-Id: I3efe7f4f0a2d0bceb7e6e801cd68de6b2624fbe0
Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
|
|
|
|
|
|
|
|
|
|
|
| |
1. Add unit tests for utils;
2. Put the common code shared by app and utest into a library, and link the
library to app and utest.
This eliminates the duplicated compiled objects.
3. Update .gitignore
Change-Id: I05ee93c2b23748a1e038eeec3534d49b94911366
Signed-off-by: Lei YU <mine260309@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
P8 system uses I2C OCC and it uses different driver for occ-hwmon.
Add `--enable-i2c-occ` configure option to enable the support.
It searches i2c device names in sysfs to get all occ-hwmon devices and
use the i2c device name to bind/unbind the driver.
The occ control object path for I2C OCC hwmon becomes something like
/org/open_power/control/3_0050, where 3_0050 is the i2c address.
Change-Id: I8b9d8d4429c563528dc88fb2679b265c53d7a2d5
Signed-off-by: Lei YU <mine260309@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
OCC control application looks at CPU inventory and creates
D-Bus objects. In some of the cases, hostboot marks the CPU
as Not Present but also marks Functional and this results in
creating an OCC object for the CPU which is not present.
Need to filter CPUs based on Present and Functional properties
to address the issue and this commit adds that support.
Fixes openbmc/openbmc#2024
Change-Id: I58a06bfd09131bc3deba8f132547095c53bde5e1
Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
|
|
|
|
|
|
|
|
|
|
| |
occ finder was creating a separate sdbusplus handler
to access the Inventory instead of using the one which
is already available. This commit will enforce using the
bus which is already created.
Change-Id: Ic256f185b67c661ba551139d5e057eee3ac67c7e
Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
|
|
|
|
|
|
|
| |
Fixes openbmc/openbmc#2165
Change-Id: I93f317a32c910f279003fa0fce6ae2d597f90312
Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
|
|
|
|
|
|
|
|
|
|
| |
Need to re-scan the second processors hub chip on
every boot of the system
Resolves openbmc/openbmc#2161
Change-Id: I089140333462d83f66a0ad207fecb679cba79210
Signed-off-by: Andrew Geissler <andrewg@us.ibm.com>
|
|
|
|
|
|
|
| |
Fixes openbmc/openbmc#2118
Change-Id: If9e2610fe7443daa2196b0e5989f81bc544266b2
Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
|
|
|
|
|
|
|
|
|
|
| |
This is needed to make sure that the /dev/occ files are created
that are needed to communicate with OCC device. Also, calling to
this service is needed only when the first call to do OCC bind is
received.
Change-Id: I40466b8b74753b2f2366be385a8b066e912b32e4
Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
|
|
|
|
|
|
|
|
|
|
| |
After detecting the error in the OCC, invokes OccReset command
in Host Control dbus object with the sensor ID of the failing OCC
Fixes openbmc/openbmc#1363
Change-Id: I608dbbb943d3b39d0709d6f350ab799e771a13e9
Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
|
|
|
|
|
| |
Change-Id: I948cc33ef05c2c49353277f4d5df958012a9801f
Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The OCC objects would get created when corresponding CPU inventory items
get added. This doesn't cover a scenario where the OCC app restarts.
If the CPU inventory is already present when the app starts, construct
OCC objects as well.
Resolves openbmc/openbmc#1824.
Change-Id: I4994d93ba6f528ca67977604ccb1da717563092a
Signed-off-by: Deepak Kodihalli <dkodihal@in.ibm.com>
|
|
|
|
|
| |
Change-Id: I98d95020a2d01e281e5c8efa825d6b4bd4c6c160
Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
|
|
|
|
|
|
|
| |
Resolves openbmc/openbmc#2005
Change-Id: I3ce16566f442872b11b10d8db752a29bf803d1e4
Signed-off-by: Andrew Geissler <andrewg@us.ibm.com>
|
|
|
|
|
|
|
| |
Resolves openbmc/openbmc#948
Change-Id: I03193b07ddaf380468bd0c0e62a41220bdeaecce
Signed-off-by: Andrew Geissler <andrewg@us.ibm.com>
|
|
|
|
|
| |
Change-Id: Ie60aac151f5fd8ce091020ce756834e4877cbc93
Signed-off-by: Andrew Geissler <andrewg@us.ibm.com>
|
|
|
|
|
| |
Change-Id: I2d7b3a449e2c9c1d5a0627161f8e85dcaca1e087
Signed-off-by: Andrew Geissler <andrewg@us.ibm.com>
|
|
|
|
|
| |
Change-Id: I39b38a931ffdf260d9ee45f02cdd31e9e884b04d
Signed-off-by: Andrew Geissler <andrewg@us.ibm.com>
|
|
|
|
|
| |
Change-Id: I0637558da8f984af7628fcb44c6d1a2eb6bce4de
Signed-off-by: Andrew Geissler <andrewg@us.ibm.com>
|
|
|
|
|
|
|
| |
Fixes openbmc/openbmc#1698
Change-Id: Iaa33c3065b0358b62e3ec7e39d4b57c6b9d181e1
Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
|
|
|
|
|
| |
Change-Id: I43822cb28bc2d23398fb09352c9876e169c666f7
Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
Currently, only thing that OCC controller does is create PassThrough
objects. However, there is a need now to create OCC Status objects
and hence some restructuring is needed to consume that.
Since OCC control now is doing more than one thing, service name is
changed to map to that.
Change-Id: I466979a873d6f14385eb59d0e9d9f3a8b3f95a9b
Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
|
|
|
|
|
|
|
|
|
|
| |
Create OCC pass-through d-bus objects when corresponding CPU objects are
created in the inventory.
Resolves openbmc/openbmc#1450.
Change-Id: I8da879f51ebef8dcc3d25358def81c5e0dce0617
Signed-off-by: Deepak Kodihalli <dkodihal@in.ibm.com>
|
|
|
|
|
|
|
|
|
|
| |
Initially, the occ fifo devices were named as /dev/occfifo1..N
but it has been renamed to /dev/occ1..N.
Fixes openbmc/openbmc#1696
Change-Id: Ibf37cc3f61a85a46accd678a55e1b2b6019bd6e5
Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Amester and OCC understand only the sequence that is in bytes.
Current OCC pass-through was sending chunk of 4 bytes and that
was breaking the protocol. Since the REST server only handles 4
bytes, OCC pass-through needs to convert array of 4 bytes into
array of 2 bytes prior to sending to OCC driver.
Similarly, pass-through reader now needs to read one byte at a time
than 4 bytes.
Change-Id: Ifc24636f6b1dfb0cc0052362d2982ecfa652fec5
Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
|
|
|
|
|
|
|
|
|
|
|
| |
This application interacts with OCC driver and hence its good to
terminate when there is an error during IO since it would mostly
mean a faulty hardware.
Fixes openbmc/openbmc#1428
Change-Id: I48bc7b2cf19922a7a53dbab78cdd4f2338a7431b
Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
|
|
|
|
|
|
|
|
| |
This will utilize the OCC driver to send Amester payload to OCC and
does a read to get the contents of OCC-SRAM and passes it back.
Change-Id: I68627b21665256df6fabad7768bb139dd6d1b99b
Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
|
|
|
|
|
| |
Change-Id: I8159f71ff3dd087f10cdf3b013e1acb60d4758fb
Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Communicating to OCC from BMC in PassThrough mode involves 2 drivers,
namely;
1) SBE FIFO driver --> Used to communicate with SBE
2) OCC driver --> Which uses FIFO driver to write data to OCC
at a predefined address and reads it back from a predefined
OCC address.
Device entry that is of interest here belongs to #2 above.
This will map occ0 to fifo1, occ2 to fifo2 and so on.
Until the udev rules are in place to make sure that a particular
entry always maps to correct device not caring the probing order,
this change here is a best guess that cpu0 and cpu1 would mostly in
all cases be probed in that order.
Change-Id: I485e0ea4eab1b4c6f59ee4b68c0725f9633cd933
Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
|