Page MenuHomeFreeBSD

if_cgem: Rewrite clock part
ClosedPublic

Authored by manu on Sep 14 2023, 9:50 AM.
Tags
None
Referenced Files
Unknown Object (File)
Mar 21 2024, 12:08 PM
Unknown Object (File)
Mar 21 2024, 11:48 AM
Unknown Object (File)
Mar 21 2024, 11:48 AM
Unknown Object (File)
Mar 20 2024, 10:58 AM
Unknown Object (File)
Jan 26 2024, 3:40 PM
Unknown Object (File)
Jan 12 2024, 7:35 AM
Unknown Object (File)
Jan 11 2024, 8:43 AM
Unknown Object (File)
Dec 23 2023, 3:22 AM
Subscribers

Details

Summary
  • pclk and hclk are mandatory so always try to get them. Don't make it fatal if it fails as some platform (like Zynq) don't have a proper clock driver.
  • Always use pclk for the reference clock.
  • Try to get all the possible clocks and enable them.

Sponsored by: Beckhoff Automation GmbH & Co. KG

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

manu requested review of this revision.Sep 14 2023, 9:50 AM
mhorne added a subscriber: mhorne.

Seems good to me. It will be a couple of weeks before I have the chance to test on riscv.

This and the other review is to cope with DTS changes I guess?

sys/dev/cadence/if_cgem.c
1748–1749
1754–1758

Consider adding braces like this, or making the second part an else if.

1883

style(9) preferred here, and below.

This revision is now accepted and ready to land.Sep 15 2023, 5:57 PM

Seems good to me. It will be a couple of weeks before I have the chance to test on riscv.

I won't mfc before a month or two so this will give you (and others) to test on riscv.

This and the other review is to cope with DTS changes I guess?

No this is just me doing zynqmp bringup and looking at all the drivers :)

sys/dev/cadence/if_cgem.c
1754–1758

Will do before commit.

1883

Will change before commit

Tested on Zybo Z7 with sources from June 1st, 2023 and patch applied (partially) manually, system boots and everything seems to work as before. (First chunk - I forgot to apply D41856 first, my bad.)
Test on riscv64 (Microchip PolarFire SoC) should not be problem, just more time is necessary to prepare and conduct the test :(

This revision was automatically updated to reflect the committed changes.