Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit e3dda6df authored by Linux Build Service Account's avatar Linux Build Service Account Committed by Gerrit - the friendly Code Review server
Browse files

Merge "ASoC: msm: qdsp6v2: Fix memory allocation issues in audio_cal_utils"

parents 8a745689 f2e2e35b
Loading
Loading
Loading
Loading
+2 −3
Original line number Diff line number Diff line
@@ -595,14 +595,13 @@ static struct cal_block_data *create_cal_block(struct cal_type_data *cal_type,
		goto done;
	}

	cal_block = kmalloc(sizeof(*cal_type),
	cal_block = kzalloc(sizeof(*cal_block),
		GFP_KERNEL);
	if (cal_block == NULL) {
		pr_err("%s: could not allocate cal_block!\n", __func__);
		goto done;
	}

	memset(cal_block, 0, sizeof(*cal_block));
	INIT_LIST_HEAD(&cal_block->list);
	list_add_tail(&cal_block->list, &cal_type->cal_blocks);

@@ -627,7 +626,7 @@ static struct cal_block_data *create_cal_block(struct cal_type_data *cal_type,
				client_info_size);
	}

	cal_block->cal_info = kmalloc(
	cal_block->cal_info = kzalloc(
		get_cal_info_size(cal_type->info.reg.cal_type),
		GFP_KERNEL);
	if (cal_block->cal_info == NULL) {