-
Notifications
You must be signed in to change notification settings - Fork 3
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
Add specific cases to device specification #94
base: main
Are you sure you want to change the base?
Conversation
aacuevas
commented
Mar 5, 2025
- Add the specific special case of the NULL device
- Add a specification for detachable devices
- Fixes Create spec for "detachable devices" #77
- Add the specific special case of the NULL device - Add a specification for detachable devices
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have some pending text changes, but ill wait for the responses to my comments before committing them.
(e.g.: a circuit driving an active probe that can be swapped). | ||
In these cases: | ||
|
||
- The driver MUST check for the presence of all required hardware elements |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
When must it check?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
on reset? Detect when its detacted?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good point. On soft reset (as defined in #91), before sending the device table. I'll clarify this.
@@ -22,3 +22,11 @@ Device ID. Devices sharing an ID are assumed to be the same and share the same | |||
optionally be divided in two 8-bit values so long as the resulting 16-bit | |||
integer is unique within a particular “Company” (there is no need for unary | |||
or monotonic increments when new devices are introduced). | |||
|
|||
|
|||
.. _null-dev-id: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should this go into special devices?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a very good point. I did not think of it as this is not really a device per se, but an indicator of a lack of device.
But on the register map file I mentioned that null devices are the sole exception to devices requiring a register interface.
So maybe it would be better to add all the requirements as a "special device". I would still mention here the special meaning of devid = 0, as it is important enough.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
After reading the current text, I am not so sure right now. The special devices page starts with "There are ... devices that are required to exist". The page defines a couple of things that MUST be present.
However, the null device is a special case to declare a non-device. but it might not necessarily appear.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
maybe its just "special" should be replaced with "required" then.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think that we should change "Special Devices" to "Required Devices". I think there should be a short page called Null Device with this description in it. In addition, the text from the Device descriptor page can be moved there as well:
Null Devices
In the special case of :ref:
null devices <null-dev-id>
, represented by adevice_id
of 0, all other fields MUST be 0 as these devices MUST NOT produce or consume any kind
of data.
The information on the registers page
.. _null-dev-reg:
Null Devices
An exception to the previously stated register map are :ref:`null devices<null-dev-desc>`, those with a ``device_id`` of :ref:`all zeros <null-dev-id>`. A null device MUST NOT implement any register interface. Any attempt to access a null device MUST return the same error as accessing a non-existing register.
Can be turned into an admonition that references this new null device page.
I made some edits the the detachable devices page, please review and change as you wish. |
Ok, I think it should be done now. Please review the last changes, I followed the earlier comments. On the detachable devices page, I do reference the soft reset, we need to link it to the appropriate tag once #91 is merged |