diff options
Diffstat (limited to 'arch/powerpc/sysdev/qe_lib/ucc_fast.c')
-rw-r--r-- | arch/powerpc/sysdev/qe_lib/ucc_fast.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/arch/powerpc/sysdev/qe_lib/ucc_fast.c b/arch/powerpc/sysdev/qe_lib/ucc_fast.c index 1aecb075a72..25fbbfaa837 100644 --- a/arch/powerpc/sysdev/qe_lib/ucc_fast.c +++ b/arch/powerpc/sysdev/qe_lib/ucc_fast.c | |||
@@ -208,6 +208,7 @@ int ucc_fast_init(struct ucc_fast_info * uf_info, struct ucc_fast_private ** ucc | |||
208 | uccf->uf_regs = ioremap(uf_info->regs, sizeof(struct ucc_fast)); | 208 | uccf->uf_regs = ioremap(uf_info->regs, sizeof(struct ucc_fast)); |
209 | if (uccf->uf_regs == NULL) { | 209 | if (uccf->uf_regs == NULL) { |
210 | printk(KERN_ERR "%s: Cannot map UCC registers\n", __func__); | 210 | printk(KERN_ERR "%s: Cannot map UCC registers\n", __func__); |
211 | kfree(uccf); | ||
211 | return -ENOMEM; | 212 | return -ENOMEM; |
212 | } | 213 | } |
213 | 214 | ||
@@ -355,6 +356,9 @@ void ucc_fast_free(struct ucc_fast_private * uccf) | |||
355 | if (uccf->ucc_fast_rx_virtual_fifo_base_offset) | 356 | if (uccf->ucc_fast_rx_virtual_fifo_base_offset) |
356 | qe_muram_free(uccf->ucc_fast_rx_virtual_fifo_base_offset); | 357 | qe_muram_free(uccf->ucc_fast_rx_virtual_fifo_base_offset); |
357 | 358 | ||
359 | if (uccf->uf_regs) | ||
360 | iounmap(uccf->uf_regs); | ||
361 | |||
358 | kfree(uccf); | 362 | kfree(uccf); |
359 | } | 363 | } |
360 | EXPORT_SYMBOL(ucc_fast_free); | 364 | EXPORT_SYMBOL(ucc_fast_free); |