diff options
Diffstat (limited to 'sound/pci/ctxfi/ctsrc.c')
| -rw-r--r-- | sound/pci/ctxfi/ctsrc.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/sound/pci/ctxfi/ctsrc.c b/sound/pci/ctxfi/ctsrc.c index e1c145d8b702..df43a5cd3938 100644 --- a/sound/pci/ctxfi/ctsrc.c +++ b/sound/pci/ctxfi/ctsrc.c | |||
| @@ -724,12 +724,11 @@ static int get_srcimp_rsc(struct srcimp_mgr *mgr, | |||
| 724 | 724 | ||
| 725 | /* Allocate mem for SRCIMP resource */ | 725 | /* Allocate mem for SRCIMP resource */ |
| 726 | srcimp = kzalloc(sizeof(*srcimp), GFP_KERNEL); | 726 | srcimp = kzalloc(sizeof(*srcimp), GFP_KERNEL); |
| 727 | if (NULL == srcimp) { | 727 | if (!srcimp) |
| 728 | err = -ENOMEM; | 728 | return -ENOMEM; |
| 729 | return err; | ||
| 730 | } | ||
| 731 | 729 | ||
| 732 | /* Check whether there are sufficient SRCIMP resources. */ | 730 | /* Check whether there are sufficient SRCIMP resources. */ |
| 731 | err = 0; | ||
| 733 | spin_lock_irqsave(&mgr->mgr_lock, flags); | 732 | spin_lock_irqsave(&mgr->mgr_lock, flags); |
| 734 | for (i = 0; i < desc->msr; i++) { | 733 | for (i = 0; i < desc->msr; i++) { |
| 735 | err = mgr_get_resource(&mgr->mgr, 1, &idx); | 734 | err = mgr_get_resource(&mgr->mgr, 1, &idx); |
