forked from openbmc/openpower-vpd-parser
-
Notifications
You must be signed in to change notification settings - Fork 20
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implement vpd-tool dump inventory #498
Draft
souvik1914581
wants to merge
3
commits into
ibm-openbmc:P11_Dev
Choose a base branch
from
souvik1914581:sr_vpdToolDumpInvPR
base: P11_Dev
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Draft
Implement vpd-tool dump inventory #498
souvik1914581
wants to merge
3
commits into
ibm-openbmc:P11_Dev
from
souvik1914581:sr_vpdToolDumpInvPR
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
The API reads the keyword’s value for a given DBus object path or hardware path. Stores the result to user given path if provided otherwise shows the result on console. Only read keyword’s value from DBus and printing result on the console is implemented in this commit. Test result: ''' root@p10bmc:/tmp# ./vpd-tool -O /system/chassis/motherboard -R VSYS -K BR -r { "/system/chassis/motherboard": { "BR": "S0" } } ''' Signed-off-by: Anupama B R <[email protected]>
This commit implements object dump functionality in vpd-tool. For a given Object path, the object dump functionality prints the following properties in a JSON format to the console: 1. Present property, Pretty Name, Location Code, Sub Model 2. SN, PN, CC, FN, DR keywords under VINI record Test: Tested on a rainier2s2u system ''' root@p10bmc:~# ./vpd-tool -o -O \ /xyz/openbmc_project/inventory/system/chassis/motherboard [ { "/xyz/openbmc_project/inventory/system/chassis/motherboard": { "CC": "2E2D", "DR": "SYSTEM BACKPLANE", "FN": "02WG676", "LocationCode": "U78DA.ND0.WZS0042-P0", "PN": "02WG678", "Present": "true", "PrettyName": "System backplane", "SN": "Y131UF07302T" } } ] root@p10bmc:~# ./vpd-tool -o -O \ /xyz/openbmc_project/inventory/system/chassis/motherboard/vdd_vrm0 [ { "/xyz/openbmc_project/inventory/ system/chassis/motherboard/vdd_vrm0": { "CC": "2E32", "DR": "CPU POWER CARD ", "FN": "02CM285", "LocationCode": "U78DA.ND0.WZS0042-P0-C14", "PN": "02CM286", "Present": "true", "PrettyName": "Voltage regulator module for system processor module 0", "SN": "YH30A005M11C" } } ] root@rain104bmctest:~# ./vpd-tool -o -O "InvalidObjectPath" root@rain104bmctest:~# echo $? 255 ''' Change-Id: I4b44bdb03429f7f3341ca0c79317d616f1de3a4f Signed-off-by: Souvik Roy <[email protected]>
This commit implements dump inventory functionality in vpd-tool. Dump inventory option in vpd-tool is used to dump the following properties of all the FRUs in the inventory JSON, in JSON format to the console: - Present property, Pretty Name, Location Code, Sub Model - SN, PN, CC, FN, DR keywords under VINI record. Test: Tested on a rainier2s2u system with two binaries: 1. old vpd-tool copied from another system. 2. vpd-tool is the new binary from this commit ''' root@valid-hostname:/tmp/sr# ./vpd-tool -i > ./newInvDump.json root@valid-hostname:/tmp/sr# ./old-vpd-tool -i > ./oldInvDump.json Compare both JSON files and see that both have 339 FRU entries with following properties populated: - Present property, Pretty Name, Location Code, Sub Model - SN, PN, CC, FN, DR keywords under VINI record. ''' Change-Id: I8aa2e3ac89e37b45c3ebc7b1367d18cdce0a11b5 Signed-off-by: Souvik Roy <[email protected]>
souvik1914581
force-pushed
the
sr_vpdToolDumpInvPR
branch
from
November 21, 2024 10:27
7d3159a
to
e23af01
Compare
souvik1914581
changed the title
Implement vpd-tool dump inventory.
Implement vpd-tool dump inventory
Nov 21, 2024
souvik1914581
requested review from
PriyangaRamasamy,
SunnySrivastava1984,
jinuthomas,
RekhaAparna01 and
branupama
November 21, 2024 10:39
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This commit implements dump inventory functionality in vpd-tool.
Dump inventory option in vpd-tool is used to dump the following
properties of all the FRUs in the inventory JSON, in JSON format
to the console:
newVpdToolDumpInv.json
oldInvDump.json