Skip to content

Commit

Permalink
dtb-xml: remove prefix '0x' on command value
Browse files Browse the repository at this point in the history
fdtget does not include this prefix for type hex and compare will fail
  • Loading branch information
Portisch committed Apr 28, 2021
1 parent 0b334c2 commit 0e72fc8
Showing 1 changed file with 2 additions and 0 deletions.
Expand Up @@ -79,6 +79,7 @@ function update_migrated_xml() {
if [ "$?" == 0 ]; then
cmd_value=$(xmlstarlet sel -t -m "//$update_node/$option" -m "cmd[$cnt]/value" -v "concat(.,' ')" $xml_file)
[ -n "$cmd_value" ] && cmd_value=${cmd_value::-1}
[ -n "$cmd_value" ] && cmd_value=${cmd_value#"0x"}
if [ "$act_value" != "$cmd_value" ]; then
continue 2
fi
Expand Down Expand Up @@ -136,6 +137,7 @@ function migrate_dtb_to_xml() {
if [ "$?" == 0 ]; then
cmd_value=$(xmlstarlet sel -t -m "//$node/$option" -m "cmd[$cnt]/value" -v "concat(.,' ')" $xml_file)
[ -n "$cmd_value" ] && cmd_value=${cmd_value::-1}
[ -n "$cmd_value" ] && cmd_value=${cmd_value#"0x"}
if [ "$act_value" != "$cmd_value" ]; then
continue 2
fi
Expand Down

0 comments on commit 0e72fc8

Please sign in to comment.