Attention is currently required from: Hung-Te Lin, Jarried Lin, Paul Menzel, Yidi Lin.
Yu-Ping Wu has posted comments on this change by Jarried Lin. ( https://review.coreboot.org/c/coreboot/+/85978?usp=email )
Change subject: soc/mediatek/mt8196: Add RTC driver ......................................................................
Patch Set 1:
(9 comments)
Patchset:
PS1: Partial review. src/soc/mediatek/mt8196/mt6685_rtc.c is not reviewed yet.
Commit Message:
https://review.coreboot.org/c/coreboot/+/85978/comment/c8c97fd7_f06354c1?usp... : PS1, Line 9: rtc RTC
File src/soc/mediatek/common/include/soc/rtc_common.h:
https://review.coreboot.org/c/coreboot/+/85978/comment/1b6ed322_2db3abb1?usp... : PS1, Line 107: /* The return result of the clock calibration : * The result is relationship coefficient between 26M and 32K, : * which is non-unit. : */ Okay, I think this explains nothing. If the return value is NOT a unit, let's remove this comment (and remove the blank line above).
File src/soc/mediatek/common/rtc_osc_init.c:
https://review.coreboot.org/c/coreboot/+/85978/comment/45087dce_6dfaca48?usp... : PS1, Line 7: u16
Why limit the length?
Because the data width for rtc_read/rtc_write API is u16.
File src/soc/mediatek/mt8196/include/soc/mt6685_rtc_hw.h:
https://review.coreboot.org/c/coreboot/+/85978/comment/62237abf_d3792be8?usp... : PS1, Line 24: Remove this extra space. Same for other values below.
https://review.coreboot.org/c/coreboot/+/85978/comment/ef6b5e9c_a3936cab?usp... : PS1, Line 89: mask masks
File src/soc/mediatek/mt8196/include/soc/rtc.h:
https://review.coreboot.org/c/coreboot/+/85978/comment/40e3cf96_1ec03b60?usp... : PS1, Line 58: WATCH_INIT_EXPIRED_TIME Can we have a more descriptive name? `XXX_US`
https://review.coreboot.org/c/coreboot/+/85978/comment/e4f94527_7eb065a7?usp... : PS1, Line 59: WAIT_TIME_US Same here. Wait for what?
Also change these two to enum for consistency.
File src/soc/mediatek/mt8196/mt6685_rtc.c:
https://review.coreboot.org/c/coreboot/+/85978/comment/c2e0d743_9748dc5e?usp... : PS1, Line 43: freq Can we name these 3 fields instead of using an array?