summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorP. J. McDermott <pj@pehjota.net>2015-10-27 18:02:07 (EDT)
committer P. J. McDermott <pj@pehjota.net>2015-10-27 18:02:07 (EDT)
commite858b1abcc89a0449cc7a53d0532373dedd1450f (patch)
treee4fd3599e9ddcefdb9b38ff89ed239a4a7ea47f8
parent6b715221c57ddbe068c22eddeb454158f049d68d (diff)
downloadfirman.sh-e858b1abcc89a0449cc7a53d0532373dedd1450f.zip
firman.sh-e858b1abcc89a0449cc7a53d0532373dedd1450f.tar.gz
firman.sh-e858b1abcc89a0449cc7a53d0532373dedd1450f.tar.bz2
board_get_chip(): New function
-rw-r--r--src/board.sh9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/board.sh b/src/board.sh
index 12b86cf..42a123d 100644
--- a/src/board.sh
+++ b/src/board.sh
@@ -19,6 +19,8 @@ board_functions='get_name get_id match get_dists'
boards=''
+board_chip=''
+
register_board()
{
local board="${1}"
@@ -46,7 +48,14 @@ find_board()
for fn in ${board_functions}; do
eval "board_${fn}() { board_${board}_${fn} \"\${@}\"; }"
done
+ board_chip="${chip}"
return 0
done
return 1
}
+
+board_get_chip()
+{
+ printf '%s' "${board_chip}"
+ return 0
+}