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

i3c: Start basic driver #32

Merged
merged 2 commits into from
Nov 26, 2024
Merged

i3c: Start basic driver #32

merged 2 commits into from
Nov 26, 2024

Conversation

swenson
Copy link
Collaborator

@swenson swenson commented Nov 22, 2024

This does the initialization sequence, routes interrupts, and does passes reads and writes to the clients.

I haven't had a chance to do much testing yet, but that will be easier once the peripheral is more complete.

This does the initialization sequence, routes interrupts, and does
passes reads and writes to the clients.

I haven't had a chance to do much testing yet, but that will be easier
once the peripheral is more complete.
fn disable(&self);

/// Get the maximum transmission unit (MTU) size.
fn get_mtu_size(&self) -> usize;
Copy link
Collaborator

Choose a reason for hiding this comment

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

I think MTU would not be an appropriate term for the I3C target device (sorry for misleading). Instead, we should provide an interface that gives that following device information:
dynamic_addr: u8
max_read_len: u16
max_write_len: u16

a possible interface could be:
fn get_device_info(&self) -> I3CTargetInfo

}

fn get_mtu_size(&self) -> usize {
250
Copy link
Collaborator

Choose a reason for hiding this comment

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

we should define a constant that specifies the maximum size for the read/write lengths that the I3C target can receive. This is needed to allocate static Tx and Rx packet buffers for the MCTP stack

@swenson
Copy link
Collaborator Author

swenson commented Nov 26, 2024

Thanks!

@swenson swenson merged commit cd976a5 into main Nov 26, 2024
1 check passed
@swenson swenson deleted the i3c-driver branch November 26, 2024 17:53
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.

2 participants