|
@@ -3286,17 +3286,11 @@ static struct d40_base * __init d40_hw_detect_init(struct platform_device *pdev)
|
|
|
if (!base->lookup_phy_chans)
|
|
|
goto failure;
|
|
|
|
|
|
- if (num_log_chans + ARRAY_SIZE(dma40_memcpy_channels)) {
|
|
|
- /*
|
|
|
- * The max number of logical channels are event lines for all
|
|
|
- * src devices and dst devices
|
|
|
- */
|
|
|
- base->lookup_log_chans = kzalloc(num_log_chans *
|
|
|
- sizeof(struct d40_chan *),
|
|
|
- GFP_KERNEL);
|
|
|
- if (!base->lookup_log_chans)
|
|
|
- goto failure;
|
|
|
- }
|
|
|
+ base->lookup_log_chans = kzalloc(num_log_chans *
|
|
|
+ sizeof(struct d40_chan *),
|
|
|
+ GFP_KERNEL);
|
|
|
+ if (!base->lookup_log_chans)
|
|
|
+ goto failure;
|
|
|
|
|
|
base->reg_val_backup_chan = kmalloc(base->num_phy_chans *
|
|
|
sizeof(d40_backup_regs_chan),
|