summaryrefslogtreecommitdiffstats
path: root/classes
diff options
context:
space:
mode:
authorTodor Minchev <todor.minchev@linux.intel.com>2017-06-07 22:24:23 (GMT)
committerSaul Wold <sgw@linux.intel.com>2017-06-08 04:27:29 (GMT)
commitac83d7c7261fb11db8d798fc0d63d7e42ad56313 (patch)
tree00425edb67021855c6fab3eba4894ee2bbc525c8 /classes
parent489a7864697000117b6479cc3d6269e9eba3858e (diff)
downloadmeta-intel-ac83d7c7261fb11db8d798fc0d63d7e42ad56313.tar.gz
rmc-db: allow multiple fingerprint per board directory
Different firmware revisions often result in different fingerprints for the same hardware platform. This change allows multiple fingerprints to be stored in the same board directory to avoid having to duplicate the data for each record. Signed-off-by: Todor Minchev <todor.minchev@linux.intel.com> Signed-off-by: Saul Wold <sgw@linux.intel.com>
Diffstat (limited to 'classes')
-rw-r--r--classes/rmc-db.bbclass14
1 files changed, 7 insertions, 7 deletions
diff --git a/classes/rmc-db.bbclass b/classes/rmc-db.bbclass
index 0fb4c27..72594d6 100644
--- a/classes/rmc-db.bbclass
+++ b/classes/rmc-db.bbclass
@@ -60,7 +60,6 @@ rmc_generate_db () {
60 # For all board dirs in a topdir: 60 # For all board dirs in a topdir:
61 CUR_BOARD_DIRS=$(find ${topdir}/* -type d) 61 CUR_BOARD_DIRS=$(find ${topdir}/* -type d)
62 for board_dir in ${CUR_BOARD_DIRS}; do 62 for board_dir in ${CUR_BOARD_DIRS}; do
63 # FIXME: we shall fail when having more than one .fp file
64 CUR_FINGERPRINT=$(find ${board_dir}/ -name "*.fp") 63 CUR_FINGERPRINT=$(find ${board_dir}/ -name "*.fp")
65 64
66 # disallow a board directory without any fingerprint file in it. 65 # disallow a board directory without any fingerprint file in it.
@@ -77,12 +76,13 @@ rmc_generate_db () {
77 continue 76 continue
78 fi 77 fi
79 78
80 CUR_TAG=$(echo "${board_dir}"|sed 's/\//-/g') 79 for fp in ${CUR_FINGERPRINT}; do
81 CUR_RECORD=${RMC_DB_DIR}/rmc${CUR_TAG}.rec 80 fullname=$(basename ${fp})
82 81 CUR_TAG="${fullname%.*}"
83 rmc -R -f ${CUR_FINGERPRINT} -b ${CUR_FILES} -o ${CUR_RECORD} 82 CUR_RECORD=${RMC_DB_DIR}/${CUR_TAG}.rec
84 83 rmc -R -f ${fp} -b ${CUR_FILES} -o ${CUR_RECORD}
85 RMC_RECORDS="${RMC_RECORDS} ${CUR_RECORD}" 84 RMC_RECORDS="${RMC_RECORDS} ${CUR_RECORD}"
85 done
86 done 86 done
87 done 87 done
88 88