Commit 9e65f80ec9943790891a533dc8996d9d97a18cc6
Committed by
Joe Hershberger
1 parent
6c636514d4
Exists in
smarc_8mq_lf_v2020.04
and in
11 other branches
net: macb: add support for faster clk rates
add support for clock rates higher than 2.4Mhz Signed-off-by: Ramon Fried <rfried.dev@gmail.com> Reviewed-by: Anup Patel <anup.patel@wdc.com> Tested-by: Anup Patel <anup.patel@wdc.com> Acked-by: Joe Hershberger <joe.hershberger@ni.com>
Showing 2 changed files with 7 additions and 1 deletions Side-by-side Diff
drivers/net/macb.c
... | ... | @@ -903,8 +903,12 @@ |
903 | 903 | config = GEM_BF(CLK, GEM_CLK_DIV48); |
904 | 904 | else if (macb_hz < 160000000) |
905 | 905 | config = GEM_BF(CLK, GEM_CLK_DIV64); |
906 | - else | |
906 | + else if (macb_hz < 240000000) | |
907 | 907 | config = GEM_BF(CLK, GEM_CLK_DIV96); |
908 | + else if (macb_hz < 320000000) | |
909 | + config = GEM_BF(CLK, GEM_CLK_DIV128); | |
910 | + else | |
911 | + config = GEM_BF(CLK, GEM_CLK_DIV224); | |
908 | 912 | |
909 | 913 | return config; |
910 | 914 | } |
drivers/net/macb.h