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

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

Merge "fbdev: msm: Correct ion sequence for splash and pan display"

parents 40502d47 fc9f422c
Loading
Loading
Loading
Loading
+0 −8
Original line number Diff line number Diff line
@@ -2171,14 +2171,6 @@ int mdss_fb_alloc_fb_ion_memory(struct msm_fb_data_type *mfd, size_t fb_size)
	}

	if (mfd->mdp.fb_mem_get_iommu_domain) {
		fd = dma_buf_fd(mfd->fbmem_buf, 0);
		if (IS_ERR(mfd->fbmem_buf)) {
			rc = PTR_ERR(mfd->fbmem_buf);
			goto fb_mmap_failed;
		}

		mfd->fbmem_buf = dma_buf_get(fd);

		domain = mfd->mdp.fb_mem_get_iommu_domain();

		mfd->fb_attachment = mdss_smmu_dma_buf_attach(mfd->fbmem_buf,
+3 −14
Original line number Diff line number Diff line
@@ -39,8 +39,6 @@ static int mdss_mdp_splash_alloc_memory(struct msm_fb_data_type *mfd,
	struct msm_fb_splash_info *sinfo;
	unsigned long buf_size = size;
	struct mdss_data_type *mdata;
	struct dma_buf *dma_buf = NULL;
	int fd = 0;

	if (!mfd || !size)
		return -EINVAL;
@@ -51,19 +49,10 @@ static int mdss_mdp_splash_alloc_memory(struct msm_fb_data_type *mfd,
	if (!mdata || sinfo->splash_buffer)
		return -EINVAL;

	dma_buf = ion_alloc(size, ION_HEAP(ION_SYSTEM_HEAP_ID), 0);
	if (IS_ERR_OR_NULL(dma_buf)) {
	sinfo->dma_buf = ion_alloc(size, ION_HEAP(ION_SYSTEM_HEAP_ID), 0);
	if (IS_ERR_OR_NULL(sinfo->dma_buf)) {
		pr_err("ion memory allocation failed\n");
		rc = PTR_RET(dma_buf);
		goto end;
	}

	fd = dma_buf_fd(dma_buf, 0);

	sinfo->size = size;
	sinfo->dma_buf = dma_buf_get(fd);
	if (IS_ERR(sinfo->dma_buf)) {
		rc = PTR_ERR(sinfo->dma_buf);
		rc = PTR_RET(sinfo->dma_buf);
		goto end;
	}