Commit 534859ac6b2fecb631457736e77e9d0df1e57616

Authored by Patrick Delaunay
Committed by Sean Anderson
1 parent afcc26140b
Exists in emb_lf_v2022.04

cmd: clk: update result of do_clk_setfreq

Update the result of do_clk_setfreq and always returns a CMD_RET_ value
(-EINVAL was a possible result).

This patch avoid the CLI output "exit not allowed from main input shell."

Fixes: 7ab418fbe612 ("clk: add support for setting clk rate from cmdline")
Signed-off-by: Patrick Delaunay <patrick.delaunay@foss.st.com>
Reviewed-by: Sean Anderson <seanga2@gmail.com>
Link: https://lore.kernel.org/r/20220131172131.3.Iec2029edb7fc0b29e13bcb86058ad2f614f62779@changeid

Showing 1 changed file with 1 additions and 1 deletions Side-by-side Diff

... ... @@ -116,7 +116,7 @@
116 116  
117 117 if (!clk) {
118 118 printf("clock '%s' not found.\n", argv[1]);
119   - return -EINVAL;
  119 + return CMD_RET_FAILURE;
120 120 }
121 121  
122 122 freq = clk_set_rate(clk, freq);