History log of /openbmc/bmcweb/redfish-core/lib/pcie.hpp (Results 1 – 25 of 88)
Revision Date Author Comments
# deae6a78 11-Nov-2024 Ed Tanous <etanous@nvidia.com>

Move getProperty calls to utility

Having all dbus calls run through the same utility reduces the amount of
generated code, and more importantly, gives us a place where we can log
the requests and re

Move getProperty calls to utility

Having all dbus calls run through the same utility reduces the amount of
generated code, and more importantly, gives us a place where we can log
the requests and responses to help with debugging.

Tested: Redfish service validator passes.

Change-Id: Ic1bf45130b5069cd57f7af26e12c8d3159c87c67
Signed-off-by: Ed Tanous <etanous@nvidia.com>

show more ...


# 6be832e2 10-Sep-2024 Ed Tanous <etanous@nvidia.com>

Remove duplicated block comments

Static analysis flags that these two comments are redundant[1], which
seem to be duplicated a lot in copyright headers. Although there is a
larger discussion that c

Remove duplicated block comments

Static analysis flags that these two comments are redundant[1], which
seem to be duplicated a lot in copyright headers. Although there is a
larger discussion that can likely be had.

[1] https://sonarcloud.io/project/issues?issueStatuses=OPEN%2CCONFIRMED&id=edtanous_bmcweb&open=AY9_HYjgKXKyw1ZFwgVP

Tested: Comment change only. Code compiles.

Change-Id: Ia960317761f558a87842347ca0b5f3da63f8e730
Signed-off-by: Ed Tanous <etanous@nvidia.com>

show more ...


# 4ff0f1f4 04-Sep-2024 Ed Tanous <etanous@nvidia.com>

static -> inline

Declaring a function static in a header makes no sense, because a header
isn't a compile unit. Find all the issues and replace them with inline.

Change-Id: Icfc2b72d94b41a3a880da1

static -> inline

Declaring a function static in a header makes no sense, because a header
isn't a compile unit. Find all the issues and replace them with inline.

Change-Id: Icfc2b72d94b41a3a880da1ae6975beaa30a6792b
Signed-off-by: Ed Tanous <etanous@nvidia.com>

show more ...


# 3a58c5a8 05-Aug-2024 Konstantin Aladyshev <aladyshev22@gmail.com>

Require Inventory.Item.PCIeDevice for PCIe objects

Currently when bmcweb tries to get PCIe device service it checks only
path and doesn't limit search by any required interface.
This can lead to wro

Require Inventory.Item.PCIeDevice for PCIe objects

Currently when bmcweb tries to get PCIe device service it checks only
path and doesn't limit search by any required interface.
This can lead to wrong result if the 'xyz.openbmc_project.ObjectMapper'
for example have object with the same path.
To fix the issue require xyz.openbmc_project.Inventory.Item.PCIeDevice
interface to be present in the object.

Tested:
Patchest was tested on the system with a DBUS service that has objects
with the "xyz.openbmc_project.Inventory.Item.PCIeDevice" interface.

Before the change request to the PCIe device endpoint like
/redfish/v1/Systems/system/PCIeDevices/Bus_00_Device_00
outputs internal error message.

After the change request to the PCIe device endpoint like
/redfish/v1/Systems/system/PCIeDevices/Bus_00_Device_00
outputs detailed PCIe device info including all the relevant links
to its PCIe functions.

Change-Id: I25d60533fa8f7bdda26c81bde1fa0a88c25365f6
Signed-off-by: Konstantin Aladyshev <aladyshev22@gmail.com>

show more ...


# bd79bce8 16-Aug-2024 Patrick Williams <patrick@stwcx.xyz>

clang-format: re-format for clang-18

clang-format-18 isn't compatible with the clang-format-17 output, so we
need to reformat the code with the latest version. The way clang-18
handles lambda forma

clang-format: re-format for clang-18

clang-format-18 isn't compatible with the clang-format-17 output, so we
need to reformat the code with the latest version. The way clang-18
handles lambda formatting also changed, so we have made changes to the
organization default style format to better handle lambda formatting.

See I5e08687e696dd240402a2780158664b7113def0e for updated style.
See Iea0776aaa7edd483fa395e23de25ebf5a6288f71 for clang-18 enablement.

Change-Id: Iceec1dc95b6c908ec6c21fb40093de9dd18bf11a
Signed-off-by: Patrick Williams <patrick@stwcx.xyz>

show more ...


# 22a1b15a 05-Aug-2024 Konstantin Aladyshev <aladyshev22@gmail.com>

Remove "Function wasn't a string?" messages for PCIe

Currently for every PCIe function bmcweb checks every property of the
"xyz.openbmc_project.Inventory.Item.PCIeDevice" interface if it is a
string

Remove "Function wasn't a string?" messages for PCIe

Currently for every PCIe function bmcweb checks every property of the
"xyz.openbmc_project.Inventory.Item.PCIeDevice" interface if it is a
string. And if it is not the message "Function wasn't a string?" is
produced.
This is wrong since the properties "MaxLanes" and "LanesInUse" are not
strings but integers.
Drop the error print statement to remove the false error messages.

Change-Id: I1cc082e5aaf392b0cc4c051ab0bc6d8418aed0f9
Signed-off-by: Konstantin Aladyshev <aladyshev22@gmail.com>

show more ...


# 539d8c6b 19-Jun-2024 Ed Tanous <ed@tanous.net>

Consistently use generated enumerations

This commit causes all of Redfish to use generated enum values for enum
types. Using generated code prevents problems, and makes it more clear
what types are

Consistently use generated enumerations

This commit causes all of Redfish to use generated enum values for enum
types. Using generated code prevents problems, and makes it more clear
what types are allowed.

Doing this found two places where we had structs that didn't fulfill the
schema. They have been commented, but will be fixed with a breaking
change at some point in the future.

Tested: WIP

Change-Id: I5fdd2f2dfb6ec05606a522e1f4e331f982c8e476
Signed-off-by: Ed Tanous <ed@tanous.net>

show more ...


# 8c1d0549 12-Mar-2024 Myung Bae <myungbae@us.ibm.com>

Fix handling of lanesInUse default value

phophor-dbus-interfaces changes the default of lanesInUse to MAXINT by
https://gerrit.openbmc.org/c/openbmc/phosphor-dbus-interfaces/+/53650

Thus bmcweb als

Fix handling of lanesInUse default value

phophor-dbus-interfaces changes the default of lanesInUse to MAXINT by
https://gerrit.openbmc.org/c/openbmc/phosphor-dbus-interfaces/+/53650

Thus bmcweb also changes the logic to show the field as null if it is
MAXINT.

Change-Id: Ib229112374eb5a65e0a8ac97669c09c498ac26c7
Signed-off-by: Myung Bae <myungbae@us.ibm.com>

show more ...


# 253f11b8 16-May-2024 Ed Tanous <ed@tanous.net>

Allow configuring "bmc" and "system"

In the early days of bmcweb, we made two pretty critical assumptions;
First, is that a given platform would only have a single BMC instance
(represented as "bmc"

Allow configuring "bmc" and "system"

In the early days of bmcweb, we made two pretty critical assumptions;
First, is that a given platform would only have a single BMC instance
(represented as "bmc") and a single host instance (represented as
"system").
Second we assumed that, given that Redfish suggests against hardcoding
URIs in client implementation and leaves them freeform, clients would
code to the standard.

Our own webui-vue hardcodes Redfish URIs [1], and the documentation is
littered with examples of hardcoded curl examples of hardcoding these
URIs. That bug was filed in 2020, and the issue has only gotten worse
over time.

This patchset is an attempt to give a target that we can start solving
these issues, without trying to boil the ocean and fix all clients in
parallel.

This commit adds the meson options
redfish-manager-uri-name
and
redfish-system-uri-name

These are used to control the "name" that bmcweb places in the fixed
locations in the ManagerCollection and ComputerSystemCollection schemas.

Note, managers is added, but is not currently testable. It will be
iterated on over time.

Tested:
Changed the URL options to "edsbmc" and "edssystem" in meson options.

Redfish service validator passes.
URLs appear changed when walking the tree.

[1] https://github.com/openbmc/webui-vue/issues/43

Change-Id: I4b44685067051512bd065da8c2e3db68ae5ce23a
Signed-off-by: Ed Tanous <ed@tanous.net>

show more ...


# 25b54dba 17-Apr-2024 Ed Tanous <ed@tanous.net>

Bring consistency to config options

The configuration options that exist in bmcweb are an amalgimation of
CROW options, CMAKE options using #define, pre-bmcweb ifdef mechanisms
and meson options usi

Bring consistency to config options

The configuration options that exist in bmcweb are an amalgimation of
CROW options, CMAKE options using #define, pre-bmcweb ifdef mechanisms
and meson options using a config file. This history has led to a lot of
different ways to configure code in the codebase itself, which has led
to problems, and issues in consistency.

ifdef options do no compile time checking of code not within the branch.
This is good when you have optional dependencies, but not great when
you're trying to ensure both options compile.

This commit moves all internal configuration options to:
1. A namespace called bmcweb
2. A naming scheme matching the meson option. hyphens are replaced with
underscores, and the option is uppercased. This consistent transform
allows matching up option keys with their code counterparts, without
naming changes.
3. All options are bool true = enabled, and any options with _ENABLED or
_DISABLED postfixes have those postfixes removed. (note, there are
still some options with disable in the name, those are left as-is)
4. All options are now constexpr booleans, without an explicit compare.

To accomplish this, unfortunately an option list in config/meson.build
is required, given that meson doesn't provide a way to dump all options,
as is a manual entry in bmcweb_config.h.in, in addition to the
meson_options. This obsoletes the map in the main meson.build, which
helps some of the complexity.

Now that we've done this, we have some rules that will be documented.
1. Runtime behavior changes should be added as a constexpr bool to
bmcweb_config.h
2. Options that require optionally pulling in a dependency shall use an
ifdef, defined in the primary meson.build. (note, there are no
options that currently meet this class, but it's included for
completeness.)

Note, that this consolidation means that at configure time, all options
are printed. This is a good thing and allows direct comparison of
configs in log files.

Tested: Code compiles
Server boots, and shows options configured in the default build. (HTTPS,
log level, etc)

Change-Id: I94e79a56bcdc01755036e4e7278c7e69e25809ce
Signed-off-by: Ed Tanous <ed@tanous.net>

show more ...


# dc8cfa66 07-Apr-2024 Ed Tanous <ed@tanous.net>

Add nullptr check

Change-Id: If511f1210cca7bd1da3a8c5152688487d3036e2f
Signed-off-by: Ed Tanous <ed@tanous.net>


# 8cb2c024 27-Mar-2024 Ed Tanous <ed@tanous.net>

Fix moves/forward

Clang has new checks for std::move/std::forward correctness, which
catches quite a few "wrong" things where we were making copies of
callback handlers.

Unfortunately, the lambda s

Fix moves/forward

Clang has new checks for std::move/std::forward correctness, which
catches quite a few "wrong" things where we were making copies of
callback handlers.

Unfortunately, the lambda syntax of

callback{std::forward<Callback>(callback)}

in a capture confuses it, so change usages to
callback = std::forward<Callback>(callback)

to be consistent.

Tested: Redfish service validator passes.

Change-Id: I7a111ec00cf78ecb7d5f5b102c786c1c14d74384
Signed-off-by: Ed Tanous <ed@tanous.net>

show more ...


# 70c4d545 08-Jun-2023 Lakshmi Yadlapati <lakshmiy@us.ibm.com>

Refactor PCIeDeviceList to use getCollectionMembers

This commit refactors the code in the PCIeDeviceList function to use the
getCollectionMembers function for retrieving collection members.
Addition

Refactor PCIeDeviceList to use getCollectionMembers

This commit refactors the code in the PCIeDeviceList function to use the
getCollectionMembers function for retrieving collection members.
Additionally, a new function getCollectionToKey() is added to
handle the retrieval of collection members with custom key name.

Tested: Validator passed

'''
Test1: Redfish query of PCI devices on a system that does not have
any PCIe devices

curl -k https://$bmc/redfish/v1/Systems/system/PCIeDevices
{
"@odata.id": "/redfish/v1/Systems/system/PCIeDevices",
"@odata.type": "#PCIeDeviceCollection.PCIeDeviceCollection",
"Description": "Collection of PCIe Devices",
"Members": [],
"Members@odata.count": 0,
"Name": "PCIe Device Collection"
}

Test2: Redfish query of PCIe devices on a system that has PCIe devices

curl -k https://$bmc/redfish/v1/Systems/system/PCIeDevices
{
"@odata.id": "/redfish/v1/Systems/system/PCIeDevices",
"@odata.type": "#PCIeDeviceCollection.PCIeDeviceCollection",
"Description": "Collection of PCIe Devices",
"Members": [
{
"@odata.id": "/redfish/v1/Systems/system/PCIeDevices/drive0"
},
.......
{
"@odata.id": "/redfish/v1/Systems/system/PCIeDevices/pcie_card1"
},
{
"@odata.id": "/redfish/v1/Systems/system/PCIeDevices/pcie_card2"
},
.......
{
"@odata.id": "/redfish/v1/Systems/system/PCIeDevices/pcie_card12"
}
],
"Members@odata.count": 22,
"Name": "PCIe Device Collection"
}

Test3: Redfish query of system with PCIe devices
curl -k https://$bmc/redfish/v1/Systems/system
{
"@odata.id": "/redfish/v1/Systems/system",
"@odata.type": "#ComputerSystem.v1_16_0.ComputerSystem",
"Actions": {
"#ComputerSystem.Reset": {
"@Redfish.ActionInfo": "/redfish/v1/Systems/system/ResetActionInfo",
"target": "/redfish/v1/Systems/system/Actions/ComputerSystem.Reset"
}
},
......
"PCIeDevices": [
{
"@odata.id": "/redfish/v1/Systems/system/PCIeDevices/drive0"
},
.......
{
"@odata.id": "/redfish/v1/Systems/system/PCIeDevices/pcie_card1"
},
....
],
"PCIeDevices@odata.count": 22,
"PartNumber": "",
....
"SubModel": "S0",
"SystemType": "Physical"
}
'''

Change-Id: Icb38945a2c7bc5219ff3917fbbc8a9986c9c6155
Signed-off-by: Lakshmi Yadlapati <lakshmiy@us.ibm.com>

show more ...


# 5a39f77a 20-Oct-2023 Patrick Williams <patrick@stwcx.xyz>

clang-format: copy latest and re-format

clang-format-17 has some backwards incompatible changes that require
additional settings for best compatibility and re-running the formatter.
Copy the latest

clang-format: copy latest and re-format

clang-format-17 has some backwards incompatible changes that require
additional settings for best compatibility and re-running the formatter.
Copy the latest .clang-format from the docs repository and reformat the
repository.

Change-Id: I2f9540cf0d545a2da4d6289fc87b754f684bc9a7
Signed-off-by: Patrick Williams <patrick@stwcx.xyz>

show more ...


# 62598e31 17-Jul-2023 Ed Tanous <ed@tanous.net>

Replace logging with std::format

std::format is a much more modern logging solution, and gives us a lot
more flexibility, and better compile times when doing logging.

Unfortunately, given its level

Replace logging with std::format

std::format is a much more modern logging solution, and gives us a lot
more flexibility, and better compile times when doing logging.

Unfortunately, given its level of compile time checks, it needs to be a
method, instead of the stream style logging we had before. This
requires a pretty substantial change. Fortunately, this change can be
largely automated, via the script included in this commit under
scripts/replace_logs.py. This is to aid people in moving their
patchsets over to the new form in the short period where old patches
will be based on the old logging. The intention is that this script
eventually goes away.

The old style logging (stream based) looked like.

BMCWEB_LOG_DEBUG << "Foo " << foo;

The new equivalent of the above would be:
BMCWEB_LOG_DEBUG("Foo {}", foo);

In the course of doing this, this also cleans up several ignored linter
errors, including macro usage, and array to pointer deconstruction.

Note, This patchset does remove the timestamp from the log message. In
practice, this was duplicated between journald and bmcweb, and there's
no need for both to exist.

One design decision of note is the addition of logPtr. Because the
compiler can't disambiguate between const char* and const MyThing*, it's
necessary to add an explicit cast to void*. This is identical to how
fmt handled it.

Tested: compiled with logging meson_option enabled, and launched bmcweb

Saw the usual logging, similar to what was present before:
```
[Error include/webassets.hpp:60] Unable to find or open /usr/share/www/ static file hosting disabled
[Debug include/persistent_data.hpp:133] Restored Session Timeout: 1800
[Debug redfish-core/include/event_service_manager.hpp:671] Old eventService config not exist
[Info src/webserver_main.cpp:59] Starting webserver on port 18080
[Error redfish-core/include/event_service_manager.hpp:1301] inotify_add_watch failed for redfish log file.
[Info src/webserver_main.cpp:137] Start Hostname Monitor Service...
```
Signed-off-by: Ed Tanous <ed@tanous.net>

Change-Id: I86a46aa2454be7fe80df608cb7e5573ca4029ec8

show more ...


# 609ba4c9 11-Jul-2023 Ed Tanous <edtanous@google.com>

Remove PCIeInterface DeviceType

This code was added in 543f9a75a0819ca9e3541b2c48fe8b4d5cf6c4f7, which
in the description claimed to only be a refactor, but moved the
DeviceType record.

Because Dev

Remove PCIeInterface DeviceType

This code was added in 543f9a75a0819ca9e3541b2c48fe8b4d5cf6c4f7, which
in the description claimed to only be a refactor, but moved the
DeviceType record.

Because DeviceType is an enum in Redfish, and a string in PDI, some
amount of conversion is required, so this code can't be corrected
easily.

Remove the property for the moment.

Tested: Redfish Validator passes.

Change-Id: I60a68e45a69370112f454b1c520fde5b70ca8591
Signed-off-by: Ed Tanous <edtanous@google.com>

show more ...


# 814bf20a 04-Jul-2023 Konstantin Aladyshev <aladyshev22@gmail.com>

Add MaxLanes and MaxPCIeType properties to the PCIeInterface

According to the Redfish Data Model specification PCIeInterface (v1.3+)
of the PCIeDevice model contains the following properties:

MaxLa

Add MaxLanes and MaxPCIeType properties to the PCIeInterface

According to the Redfish Data Model specification PCIeInterface (v1.3+)
of the PCIeDevice model contains the following properties:

MaxLanes (v1.3+)
The number of PCIe lanes supported by this device.
- This property shall contain the maximum number of
PCIe lanes supported by this device.

MaxPCIeType (v1.3+)
The highest version of the PCIe specification supported by
this device.
- This property shall contain the maximum PCIe
specification that this device supports.

Since PCIeDevice interface from the phosphor-dbus-interfaces has these
values in the 'MaxLanes' and 'GenerationSupported' properties, populate
the fields to Redfish.

Tested: Redfish validator passed

Before:
redfish/v1/Systems/system/PCIeDevices/Bus_c3_Device_00
{
"@odata.id": "/redfish/v1/Systems/system/PCIeDevices/Bus_c3_Device_00",
"@odata.type": "#PCIeDevice.v1_9_0.PCIeDevice",
...
"PCIeInterface": {
"LanesInUse": 4,
"PCIeType": "Gen3"
},
...
}

After:
redfish/v1/Systems/system/PCIeDevices/Bus_c3_Device_00
{
"@odata.id": "/redfish/v1/Systems/system/PCIeDevices/Bus_c3_Device_00",
"@odata.type": "#PCIeDevice.v1_9_0.PCIeDevice",
...
"PCIeInterface": {
"LanesInUse": 4,
"MaxLanes": 4,
"MaxPCIeType": "Gen3",
"PCIeType": "Gen3"
},
...
}

Change-Id: Iec786e376cea8fd2aa516b5b2a3da4286e59627a
Signed-off-by: Konstantin Aladyshev <aladyshev22@gmail.com>

show more ...


# 82f80326 10-Jul-2023 Konstantin Aladyshev <aladyshev22@gmail.com>

Omit Slot "Lanes" property if it is equal to 0

In the context of a PCIeSlot the 0 value for the 'Lanes' property
means undefined. According to the bmcweb guidelines, DBus properties
with "unknown"/"

Omit Slot "Lanes" property if it is equal to 0

In the context of a PCIeSlot the 0 value for the 'Lanes' property
means undefined. According to the bmcweb guidelines, DBus properties
with "unknown"/"unspecified" values should be omitted from the Redfish
tree. Therefore don't populate 'Lanes' property if it is equal to 0.

Tested: validator passed

Change-Id: Ic3d142dd8b10da2367d73c370d5480208ba1510a
Signed-off-by: Konstantin Aladyshev <aladyshev22@gmail.com>

show more ...


# 9bb0a7fe 04-Jul-2023 Konstantin Aladyshev <aladyshev22@gmail.com>

Correct type for the lanesInUse property

According to the phosphor-dbus-interfaces 'LanesInUse' property in the
PCIeDevice interface has a 'size_t' type. But the current bmcweb code
uses 'int64_t' f

Correct type for the lanesInUse property

According to the phosphor-dbus-interfaces 'LanesInUse' property in the
PCIeDevice interface has a 'size_t' type. But the current bmcweb code
uses 'int64_t' for that variable in the 'unpackPropertiesNoThrow' call.
This causes function to fail. Correct variable type to fix the issue.

Tested: validator passed

Before:
redfish/v1/Systems/system/PCIeDevices/Bus_c3_Device_00
{
"@odata.id": "/redfish/v1/Systems/system/PCIeDevices/Bus_c3_Device_00",
"@odata.type": "#PCIeDevice.v1_9_0.PCIeDevice",
"Id": "Bus_c3_Device_00",
"Manufacturer": "Intel Corporation",
"Model": "",
"Name": "PCIe Device",
"PartNumber": "",
"SerialNumber": "",
"Status": {
"Health": "OK",
"State": "Enabled"
},
"error": {
"@Message.ExtendedInfo": [
{
"@odata.type": "#Message.v1_1_1.Message",
"Message": "The request failed due to an internal service
error. The service is still operational.",
"MessageArgs": [],
"MessageId": "Base.1.16.0.InternalError",
"MessageSeverity": "Critical",
"Resolution": "Resubmit the request. If the problem persists,
consider resetting the service."
}
],
"code": "Base.1.16.0.InternalError",
"message": "The request failed due to an internal service error.
The service is still operational."
}
}

After:
redfish/v1/Systems/system/PCIeDevices/Bus_c3_Device_00
{
"@odata.id": "/redfish/v1/Systems/system/PCIeDevices/
Bus_c3_Device_00",
"@odata.type": "#PCIeDevice.v1_9_0.PCIeDevice",
"Id": "Bus_c3_Device_00",
"Manufacturer": "Intel Corporation",
"Model": "",
"Name": "PCIe Device",
"PCIeFunctions": {
"@odata.id": "/redfish/v1/Systems/system/PCIeDevices/
Bus_c3_Device_00/PCIeFunctions"
},
"PCIeInterface": {
"DeviceType": "MultiFunction",
"LanesInUse": 4,
"PCIeType": "Gen3"
},
"PartNumber": "",
"SerialNumber": "",
"Status": {
"Health": "OK",
"State": "Enabled"
}
}

Change-Id: I3c7cda6027814ded5e85cfe3d37dbac1bbbc2044
Signed-off-by: Konstantin Aladyshev <aladyshev22@gmail.com>

show more ...


# a5409991 20-Apr-2023 Lakshmi Yadlapati <lakshmiy@us.ibm.com>

Add PCIe Slot information to PCIeDevice schema

To align with Redfish's transition from using the PCIeSlot schema to
including the Slot within the PCIeDevice schema, this commit adds PCIe
Slot inform

Add PCIe Slot information to PCIeDevice schema

To align with Redfish's transition from using the PCIeSlot schema to
including the Slot within the PCIeDevice schema, this commit adds PCIe
Slot information to the PCIeDevice schema. The corresponding PCIe Slot
is retrieved using the 'contained_by' association, which establishes a
link from the PCIeDevice object to the PCIeSlot object. If there is no
PCIeSlot associated with the PCIeDevice, the Slot properties will not
be returned.

Directed associations, ‘containing’ and ‘contained_by’, are used to
establish a link between PCIeDevice and PCIeSlot. The 'containing'
association establishes a link from a PCIeSlot to the PCIeDevice it
contains, while the 'contained_by' association establishes a link from
a PCIeDevice to the PCIeSlot that contains it.

Additionally, this commit refactors the PCIeDevice schema to improve
its structure, readability, and adherence to best practices.

Redfish commit:
https://redfish.dmtf.org/schemas/v1/PCIeDevice.v1_11_0.json

Tested: Validator Passed
'''
curl -k https://$bmc/redfish/v1/Systems/system/PCIeDevices/pcie_card7
{
"@odata.id": "/redfish/v1/Systems/system/PCIeDevices/pcie_card7",
"@odata.type": "#PCIeDevice.v1_9_0.PCIeDevice",
"Id": "pcie_card7",
"Name": "PCIe Device",
"PCIeFunctions": {
"@odata.id": "/redfish/v1/Systems/system/PCIeDevices/pcie_card7/PCIeFunctions"
},
"PCIeInterface": {
"LanesInUse": -1
},
"Slot": {
"Lanes": 0,
"SlotType": "FullLength"
},
"Status": {
"Health": "OK",
"State": "Absent"
}
}

PCIeDevice with no association:

curl -k https://$bmc/redfish/v1/Systems/system/PCIeDevices/pcie_card0
{
"@odata.id": "/redfish/v1/Systems/system/PCIeDevices/pcie_card0",
"@odata.type": "#PCIeDevice.v1_9_0.PCIeDevice",
"Id": "pcie_card0",
"Name": "PCIe Device",
"PCIeFunctions": {
"@odata.id": "/redfish/v1/Systems/system/PCIeDevices/pcie_card0/PCIeFunctions"
},
"PCIeInterface": {
"LanesInUse": -1
},
"Status": {
"Health": "OK",
"State": "Absent"
}
}

'''

Change-Id: I15ac33be0035721f44c60fded795092896bce9bd
Signed-off-by: Lakshmi Yadlapati <lakshmiy@us.ibm.com>
Signed-off-by: Ed Tanous <edtanous@google.com>

show more ...


# cf3b484e 27-Jun-2023 Lakshmi Yadlapati <lakshmiy@us.ibm.com>

Refactor redfishPcieGenerationFromDbus and redfishSlotType

This commit refactors the redfishPcieGenerationFromDbus and
redfishSlotType functions by changing their return types. The return
value std:

Refactor redfishPcieGenerationFromDbus and redfishSlotType

This commit refactors the redfishPcieGenerationFromDbus and
redfishSlotType functions by changing their return types. The return
value std::nullopt indicates that there is no output, while the return
value pcie_device::PCIeTypes::Invalid indicates that the input was
invalid and returns an internal error. Additionally, the code that calls
these functions has been updated to accommodate the changes.

Tested: Validator passed

Change-Id: I3f7c1a3c8c6b53fd9a39928e3ad9a5fed9be97ff
Signed-off-by: Lakshmi Yadlapati <lakshmiy@us.ibm.com>

show more ...


# 9e9325e6 02-May-2023 Lakshmi Yadlapati <lakshmiy@us.ibm.com>

Use getPCIeDeviceList in PCIeDeviceCollection

The current implementation of PCIeDeviceCollection uses
getCollectionMembers to obtain the list of PCIe devices, but this method
does not include empty

Use getPCIeDeviceList in PCIeDeviceCollection

The current implementation of PCIeDeviceCollection uses
getCollectionMembers to obtain the list of PCIe devices, but this method
does not include empty PCIe slots. To address this limitation and to
prepare for future changes that will include PCIe slot information,
this commit updates PCIeDeviceCollection to use getPCIeDeviceList instead.

While getPCIeDeviceList currently does the same as getCollectionMembers,
moving forward it will be expanded to include PCIe slot information.

Tested: Validator passed

Change-Id: I3ef9fbfa45acd782e99d31136469993a64616710
Signed-off-by: Lakshmi Yadlapati <lakshmiy@us.ibm.com>

show more ...


# 7f3e84a1 28-Dec-2022 Ed Tanous <ed@tanous.net>

Add an option flag for multi-computersystem

A number of discussions have occurred, and it's clear that
multi-computer system is not a transition that can be done in a single
series of commits, and n

Add an option flag for multi-computersystem

A number of discussions have occurred, and it's clear that
multi-computer system is not a transition that can be done in a single
series of commits, and needs to be done incrementally over time. This
commit adds the initial option for multi-computer system support, with
an option flag that can be enabled when the new behavior is desired.
This is to prevent needing a long-lived fork.

This option operatates such that if enabled, all ComputerSystem route
options will now return 404. This is to allow the redfish service
validator to pass, and to be used for incremental development. As the
routes are moved over, they will be enabled, and service validator
re-run.

Per the description in the meson options, this option flag, and all code
beneath of it will be removed on 9/1/23. The expectation is that by
this date, given the appropriate level of effort in implementation,
there will be no code remaining under that option flag. After this
date, code beneath this option flag will be removed.

Tested: No functional changes without option.

With option enabled, /redfish/v1/Systems produces no entries.
Spot check of various routes returns 404.

Redfish service validator passes.

Change-Id: I3b58642cb76d61df668076c2e0f1e7bed110ae25
Signed-off-by: Ed Tanous <ed@tanous.net>

show more ...


# 768a143d 14-Jun-2023 Lakshmi Yadlapati <lakshmiy@us.ibm.com>

Fix Redfish validator failure in PCIeFunction

This commit addresses the Redfish validator failure related to the URI
mismatch in PCIeFunction. The error reported that the URI
"/redfish/v1/Systems/sy

Fix Redfish validator failure in PCIeFunction

This commit addresses the Redfish validator failure related to the URI
mismatch in PCIeFunction. The error reported that the URI
"/redfish/v1/Systems/system/PCIeDevices/pcie_card1/PCIeFunctions/" does
not match the required URI in the PCIeFunction schema.

Commit that introduced the Redfish validator failure:
https://gerrit.openbmc.org/c/openbmc/bmcweb/+/63853

Tested: validator passed

Change-Id: Ie96b7461ad64f9b1c6392e4905276a4fe7799781
Signed-off-by: Lakshmi Yadlapati <lakshmiy@us.ibm.com>

show more ...


# e164f1b6 12-Apr-2023 Lakshmi Yadlapati <lakshmiy@us.ibm.com>

Add Health information for PCIeDevice

This commit is to add Health information according to the Redfish
PCIeDevice schema.
ref: https://redfish.dmtf.org/schemas/v1/PCIeDevice.v1_9_0.json

Code that

Add Health information for PCIeDevice

This commit is to add Health information according to the Redfish
PCIeDevice schema.
ref: https://redfish.dmtf.org/schemas/v1/PCIeDevice.v1_9_0.json

Code that updates the OperationalStatus for all the inventory
https://github.com/openbmc/openpower-vpd-parser/blob/ \
3fb026386546cfd288ab4f86156c9aa0ffa145d6/ibm_vpd_app.cpp#L620

Tested: Validator passed

'''
curl -k https://$bmc/redfish/v1/Systems/system/PCIeDevices/pcie_card8
{
"@odata.id": "/redfish/v1/Systems/system/PCIeDevices/pcie_card8",
"@odata.type": "#PCIeDevice.v1_9_0.PCIeDevice",
"Id": "pcie_card8",
"Manufacturer": "",
"Model": "6B87",
"Name": "PCIe Device",
"PCIeFunctions": {
"@odata.id": "/redfish/v1/Systems/system/PCIeDevices/pcie_card8/PCIeFunctions"
},
"PCIeInterface": {
"LanesInUse": -1
},
"PartNumber": "03FL194",
"SerialNumber": "Y131UF09S00J",
"Slot": {
"Location": {
"PartLocation": {
"ServiceLabel": "U78DB.ND0.WZS0018-P0-C8"
}
}
},
"SparePartNumber": "03FL195",
"Status": {
"Health": "OK",
"State": "Enabled"
}
}
'''

Change-Id: I53026792d0c223c10065c58aef9f3b9dc04a24ed
Signed-off-by: Lakshmi Yadlapati <lakshmiy@us.ibm.com>

show more ...


1234