summaryrefslogtreecommitdiff
path: root/drivers/dahdi/wctdm24xxp/GpakCust.c
diff options
context:
space:
mode:
authorShaun Ruffell <sruffell@digium.com>2008-11-05 20:11:03 +0000
committerShaun Ruffell <sruffell@digium.com>2008-11-05 20:11:03 +0000
commit3711d123b0053a1ee0b16edc96bc18cbd728abb8 (patch)
tree715b0ab3ba90f1de34cbfec63250982cf62336b3 /drivers/dahdi/wctdm24xxp/GpakCust.c
parentb15ca2e17016040cd83be0749b8c06c8e75b806a (diff)
Check the return value of the down_interruptible call in order to quiet a
warning. This semaphore does not protect any host data structures, but only accesses to the VPMADT032 module. The worse thing that could happen is that the internal state of the VPM module is corrupted, and then would only happen on module loading because otherwise access because that is the only time this function is called in the context of a user process. In this case, the module would need to be reloaded again anyway. (Closes issue #13742) Reported by smurfix git-svn-id: http://svn.asterisk.org/svn/dahdi/linux/trunk@5236 a0bf4364-ded3-4de4-8d8a-66a801d63aff
Diffstat (limited to 'drivers/dahdi/wctdm24xxp/GpakCust.c')
-rw-r--r--drivers/dahdi/wctdm24xxp/GpakCust.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/drivers/dahdi/wctdm24xxp/GpakCust.c b/drivers/dahdi/wctdm24xxp/GpakCust.c
index ea77e0d..a32fb96 100644
--- a/drivers/dahdi/wctdm24xxp/GpakCust.c
+++ b/drivers/dahdi/wctdm24xxp/GpakCust.c
@@ -407,8 +407,11 @@ void gpakLockAccess(unsigned short DspId)
if (wc) {
struct vpm150m *vpm = wc->vpm150m;
- if (vpm)
- down_interruptible(&vpm->sem);
+ if (vpm) {
+ if (down_interruptible(&vpm->sem)) {
+ return;
+ }
+ }
}
}