oxidecomputer / oxidecomputer/transceiver-control
`xcvradm` flags could be better
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 9
- Forks
- 0
- Avg merge
- 57m
- Merged PRs (30d)
- 3
Description
The xcvradm flags for read/write operations currently require that the caller specify the kind of memory map for the module. E.g., xcvradm -i igb0 read-lower --sff 0 4 to read the first four bytes of an SFF-8636 module. That is enforced in teh argument parsing and used here to construct a Memory{Read,Write} of the correct kind. That's OK, but it's not really necessary. We could instead fetch the management interface for the addressed modules, and create the memory access of the right kind depending on what we get back.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start in controller/src/bin/xcvradm.rs, especially the argument parsing and the Memory{Read,Write} construction around lines 393-412. Trace how the addressed module's management interface is fetched and determine how it should select the memory access kind. Done means read/write commands no longer require callers to specify the memory-map kind and still construct the correct access.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- cli
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100