diff options
-rw-r--r-- | drivers/dahdi/wcte12xp/base.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/dahdi/wcte12xp/base.c b/drivers/dahdi/wcte12xp/base.c index 46cd955..f67c3b6 100644 --- a/drivers/dahdi/wcte12xp/base.c +++ b/drivers/dahdi/wcte12xp/base.c @@ -1452,12 +1452,13 @@ static int check_and_load_vpm(struct t1 *wc) res = vpmadt032_init(wc->vpmadt032, &wc->vb); if (-ENODEV == res) { + struct vpmadt032 *vpm = wc->vpmadt032; /* There does not appear to be a VPMADT032 installed. */ clear_bit(4, &wc->ctlreg); spin_lock_irqsave(&wc->reglock, flags); wc->vpmadt032 = NULL; spin_unlock_irqrestore(&wc->reglock, flags); - vpmadt032_free(wc->vpmadt032); + vpmadt032_free(vpm); return res; } else if (res) { |