Skip to content
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

service group: Combine return format as array #34

Merged
merged 2 commits into from
Sep 4, 2024

Conversation

yeongjoshua
Copy link

Combine return format as single array.

src/srvgrp-clock.adoc Outdated Show resolved Hide resolved
src/srvgrp-clock.adoc Outdated Show resolved Hide resolved
src/srvgrp-clock.adoc Outdated Show resolved Hide resolved
3+| *Linear Format*
| *Word* | *Name* | *Description*
| 0 | min_Hz | lowest physical rate
| 1 | max_Hz | highest physical rate
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Change to "Highest clock rate in Hz"

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, we should remove metric from the field name and mention it either in description of the field or in the service group description, applicable for all service groups which deals with physical quantity

src/srvgrp-clock.adoc Outdated Show resolved Hide resolved
src/srvgrp-clock.adoc Outdated Show resolved Hide resolved
src/srvgrp-performance.adoc Outdated Show resolved Hide resolved
src/srvgrp-performance.adoc Outdated Show resolved Hide resolved
src/srvgrp-performance.adoc Outdated Show resolved Hide resolved
src/srvgrp-performance.adoc Outdated Show resolved Hide resolved
src/srvgrp-voltage.adoc Outdated Show resolved Hide resolved
src/srvgrp-voltage.adoc Outdated Show resolved Hide resolved
src/srvgrp-voltage.adoc Outdated Show resolved Hide resolved
src/srvgrp-clock.adoc Outdated Show resolved Hide resolved
src/srvgrp-clock.adoc Outdated Show resolved Hide resolved
src/srvgrp-clock.adoc Outdated Show resolved Hide resolved
| 1 | FLAGS | uint32 | _Reserved_ and must be `0`.
| 2 | REMAINING | uint32 | Remaining number of clock rates. (number of arrays)
| 3 | RETURNED | uint32 | Number of clock rates returned. (number of arrays)
| 4 | CLOCK_RATE[N] | struct | Clock rate. (Refer to <<table_clock_rate>>)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Introducing struct is going to create more confusion in representing words index. We should only use the primitive datatypes. Effectively its an array, though code can use struct.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Everyplace where the struct will be will require that struct definition also with fields having primitive types.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

using it as uint32[] then ?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@pathakraul Joshua suggestion to use unint32[] is okay?

Copy link
Collaborator

@pathakraul pathakraul Aug 12, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

uint32[2] also minor modification are required in Clock Rate Format section in this service group renaming tuple to array.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

how about the other service group that I had used 'struct' but it could be with different size?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Lets go through them case by case. Which other cases are there apart from Voltage levels. I can see in spec that PERFORMANCE group also follows what we are thinking for Clock.

What other cases are there?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

performance have the same size for array, i guess its only voltage having different size

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Description in VOLT_GET_SUPPORTED_LEVELS is missing the case when the format is Multi Linear. Since in this format its possible that there are multiple ranges and any range may not fit in the DATA and overflow. What will happen in this case. Message must contain complete range and if a range is supposed to hit the DATA boundary then that range must be left for another call of this service.

Each item in the triplet is a clock rate value.
CLOCK_RATE[0] = min_Hz (lowest physical rate that the clock can synthesize)
CLOCK_RATE[1] = max_Hz (highest physical rate that the clock can synthesize)
CLOCK_RATE[2] = step_Hz (Step between two successive rates)
----
! [29:0] ! _Reserved_
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Check the point 4. in this #37. Please take care of these points highlighted in this issue in this PR and wherever possible.

@pathakraul
Copy link
Collaborator

@yeongjoshua Updates?

@yeongjoshua
Copy link
Author

@yeongjoshua Updates?

Sorry, been working on some urgent task. Still working on it.

Joshua Yeong added 2 commits September 3, 2024 18:49
Combine return format as single array.

Signed-off-by: Joshua Yeong <[email protected]>
Update power state matching ACPI's device power
management object definition.

Signed-off-by: Joshua Yeong <[email protected]>
@yeongjoshua
Copy link
Author

@pathakraul i remove the part where we mentioned that AP/Application Processor and PuC/Platform microcontroller can be use interchangeably.

@lftan
Copy link
Collaborator

lftan commented Sep 3, 2024

@pathakraul i remove the part where we mentioned that AP/Application Processor and PuC/Platform microcontroller can be use interchangeably.

I also remove this in my PR #42:
a0016bf#diff-6cfbac511c6b470ee23118d2c6fd770dca77d5c4ed51d689d8675bf24acbdf0a

@yeongjoshua
Copy link
Author

I dropped the last 2 patches as covered in #42

@pathakraul pathakraul merged commit ce19e01 into riscv-non-isa:main Sep 4, 2024
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants