diff options
author | Patrick Williams <iawillia@us.ibm.com> | 2013-08-28 15:18:05 -0500 |
---|---|---|
committer | A. Patrick Williams III <iawillia@us.ibm.com> | 2013-09-11 14:44:18 -0500 |
commit | 79ce78da45859a79044a377dd18b15920fcd9542 (patch) | |
tree | 79a2670d585a76729d79e54b85da27f036e58fbe /src/usr/scan | |
parent | 2283a24d0273ae66ec0b826a7b9ed567bba1f0ef (diff) | |
download | talos-hostboot-79ce78da45859a79044a377dd18b15920fcd9542.tar.gz talos-hostboot-79ce78da45859a79044a377dd18b15920fcd9542.zip |
Add mutex to SCAN device driver.
Change-Id: I3c2b1e184c28779871b2e273b22b4a50b5e21a26
Reviewed-on: http://gfw160.austin.ibm.com:8080/gerrit/5978
Tested-by: Jenkins Server
Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com>
Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
Diffstat (limited to 'src/usr/scan')
-rw-r--r-- | src/usr/scan/scandd.C | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/usr/scan/scandd.C b/src/usr/scan/scandd.C index 4ea77d0e0..4b5d891b8 100644 --- a/src/usr/scan/scandd.C +++ b/src/usr/scan/scandd.C @@ -5,7 +5,7 @@ /* */ /* IBM CONFIDENTIAL */ /* */ -/* COPYRIGHT International Business Machines Corp. 2011,2012 */ +/* COPYRIGHT International Business Machines Corp. 2011,2013 */ /* */ /* p1 */ /* */ @@ -224,6 +224,9 @@ errlHndl_t scanDoScan( DeviceFW::OperationType i_opType, size_t op_size = sizeof(uint64_t); uint32_t l_buffer[2]; // local scom buffer + mutex_t* l_mutex = i_target->getHbMutexAttr<TARGETING::ATTR_SCAN_MUTEX>(); + mutex_lock(l_mutex); + do { @@ -647,6 +650,7 @@ errlHndl_t scanDoScan( DeviceFW::OperationType i_opType, } }while(0); + mutex_unlock(l_mutex); return l_err; } |