- 
                Notifications
    
You must be signed in to change notification settings  - Fork 65
 
Support OneShot APIC timer for windows #802
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
Conversation
        
          
                td-payload/src/arch/x86_64/apic.rs
              
                Outdated
          
        
      | pub const DIVIDE_CONFIGURATION_REGISTER: u32 = 0xfee0_03e0; | ||
| 
               | 
          ||
| // APIC Frequency | ||
| pub const APIC_FREQUENCY: u32 = 200000000; | 
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.
why we need to define it here? It is NOT used anywhere.
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.
Hi Jiewen, I am using this to calculate oneshot timer "initialcount/duration" in the migtd timer driver code. I have defined it here to maintain all definitions at one place in TDSHIM. Just now, I created PR for MigTD as well. Thanks!
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.
APIC_FREQUENCY is not defined in SDM spec.
If APIC_FREQUENCY is only for MigTD, I suggest to move this definition to MigTD project.
The rest is OK, because they are following the SDM spec.
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.
Got it, I have updated the branch and moved APIC frequency to MigTD.
| 
           Please add "Signed-off-by:" tag to pass the DCO.  | 
    
          
 Thanks Jiewen, I have fixed it and pushed the change.  | 
    
Signed-off-by: Gudaram, Meghana <[email protected]>
This commit adds OneShot APIC timer support. APIC divider (DCR) set to 1.