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

Commit dc1728e3 authored by qctecmdr's avatar qctecmdr Committed by Gerrit - the friendly Code Review server
Browse files

Merge "asoc: add more return when msm_audio_ion_alloc failed"

parents 09f30ee1 f733b217
Loading
Loading
Loading
Loading
+10 −6
Original line number Diff line number Diff line
@@ -8526,10 +8526,11 @@ static int voice_alloc_oob_shared_mem(void)
			bufsz * bufcnt,
			&phys, &len,
			&mem_addr);
	if (rc < 0) {
	if (rc) {
		pr_err("%s: audio ION alloc failed, rc = %d\n",
			__func__, rc);

		rc = -EINVAL;
		goto done;
	}

@@ -8578,10 +8579,11 @@ static int voice_alloc_oob_mem_table(void)
				&v->shmem_info.memtbl.phys,
				&len,
				&(v->shmem_info.memtbl.data));
	if (rc < 0) {
	if (rc) {
		pr_err("%s: audio ION alloc failed, rc = %d\n",
			__func__, rc);

		rc = -EINVAL;
		goto done;
	}

@@ -8964,9 +8966,10 @@ static int voice_alloc_cal_mem_map_table(void)
				&common.cal_mem_map_table.phys,
				&len,
				&(common.cal_mem_map_table.data));
	if ((ret < 0) && (ret != -EPROBE_DEFER)) {
	if ((ret) && (ret != -EPROBE_DEFER)) {
		pr_err("%s: audio ION alloc failed, rc = %d\n",
			__func__, ret);
		ret = -EINVAL;
		goto done;
	}

@@ -8990,9 +8993,10 @@ static int voice_alloc_rtac_mem_map_table(void)
			&common.rtac_mem_map_table.phys,
			&len,
			&(common.rtac_mem_map_table.data));
	if (ret < 0) {
	if (ret) {
		pr_err("%s: audio ION alloc failed, rc = %d\n",
			__func__, ret);
		ret = -EINVAL;
		goto done;
	}

@@ -9722,7 +9726,7 @@ static int voice_alloc_source_tracking_shared_memory(void)
		&(common.source_tracking_sh_mem.sh_mem_block.phys),
		(size_t *)&(common.source_tracking_sh_mem.sh_mem_block.size),
		&(common.source_tracking_sh_mem.sh_mem_block.data));
	if (ret < 0) {
	if (ret) {
		pr_err("%s: audio ION alloc failed for sh_mem block, ret = %d\n",
			__func__, ret);

@@ -9744,7 +9748,7 @@ static int voice_alloc_source_tracking_shared_memory(void)
		&(common.source_tracking_sh_mem.sh_mem_table.phys),
		(size_t *)&(common.source_tracking_sh_mem.sh_mem_table.size),
		&(common.source_tracking_sh_mem.sh_mem_table.data));
	if (ret < 0) {
	if (ret) {
		pr_err("%s: audio ION alloc failed for sh_mem table, ret = %d\n",
			__func__, ret);

+2 −1
Original line number Diff line number Diff line
@@ -159,9 +159,10 @@ int rtac_allocate_cal_buffer(uint32_t cal_type)
		&rtac_cal[cal_type].cal_data.paddr,
		&len,
		&rtac_cal[cal_type].cal_data.kvaddr);
	if (result < 0) {
	if (result) {
		pr_err("%s: ION create client for RTAC failed\n",
		       __func__);
		result = -EINVAL;
		goto done;
	}