Page MenuHomeFreeBSD

ufshci: Support ACPI
Needs ReviewPublic

Authored by jaeyoon on Fri, Mar 20, 7:25 AM.

Details

Reviewers
imp
Summary

Supports UFS host controller attachment via ACPI. Tested on the
Samsung Galaxy Book 4 Edge using Qualcomm Snapdragon X Elite.
Additionally, a quirk related to power mode change has been added.

For reference, it doesn't reach maximum speed yet. I plan to improve
it later.

Sponsored by: Samsung Electronics

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Skipped
Unit
Tests Skipped
Build Status
Buildable 71578
Build 68461: arc lint + arc unit

Event Timeline

jaeyoon created this revision.
sys/dev/ufshci/ufshci_acpi.c
85

why is 0 treated special here? Generically, 0 is a fine UID number. Is there some guarantee that we won't need to match on UID 0, but no others (the way the code is now is 0 matches all UID, which seems sensible... though I wonder why we ever care about the UID to do quirk matching).

sys/dev/ufshci/ufshci_ctrlr.c
125

Would this code be better in its own function, even if it is a singleton?

358

This might be better on one line, even if it pushes past 80 columns. The alignment shown in phab is weird, we usually just indent 4 extra spaces.

360

Here I'd definitely fold the lines. Going over 80 columns by 1 or 2 characters is preferable.