Skip to content

fix: rw1c_bit macro #128

New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Closed
wants to merge 1 commit into from
Closed

fix: rw1c_bit macro #128

wants to merge 1 commit into from

Conversation

noi
Copy link

@noi noi commented Aug 23, 2021

Hi, I'm Nobuki.

I've been trying this crate to use it lately. In the process, I had one question.
rw1c_bit macro generate the method named as clear_* but the generated method will set the bit to true.
And another methods named as clear_* will set the bit to false.

Is that correct? If I'm wrong, I'm sorry for disturbing you and please close this pull-request.

Thank you!

@toku-sa-n
Copy link
Member

Thank you for your PR, but the current implementation is correct. Clearing the RW1C bit needs to write 1 to the bit. Refer to table 5-3 of the xHCI specification for the detail.

@toku-sa-n toku-sa-n closed this Aug 24, 2021
@noi
Copy link
Author

noi commented Aug 24, 2021

@toku-sa-n
Than you for your answer and I'm sorry I took your time by my misunderstanding.

I misunderstood the meaning of "clear" as reverting to default.
I read the description of IP of Table 5-38 again and it properly said "RW1C". I had only looked at "Default = '0'" before.

I learned a lot. Thank you so much!

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants