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

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

Merge "msm: vidc: initialize venus hfi locks during hfi creation"

parents 87cb6efa cc093476
Loading
Loading
Loading
Loading
+5 −4
Original line number Diff line number Diff line
@@ -1707,9 +1707,6 @@ static int venus_hfi_core_init(void *device)

	dev->intr_status = 0;
	INIT_LIST_HEAD(&dev->sess_head);
	mutex_init(&dev->read_lock);
	mutex_init(&dev->write_lock);
	mutex_init(&dev->session_lock);
	venus_hfi_set_registers(dev);

	if (!dev->hal_client) {
@@ -3535,7 +3532,6 @@ static int venus_hfi_load_fw(void *dev)
		return -EINVAL;
	}

	mutex_init(&device->clk_pwr_lock);
	rc = venus_hfi_iommu_attach(device);
	if (rc) {
		dprintk(VIDC_ERR, "Failed to attach iommu\n");
@@ -3767,6 +3763,11 @@ static void *venus_hfi_add_device(u32 device_id,
		goto error_createq_pm;
	}

	mutex_init(&hdevice->read_lock);
	mutex_init(&hdevice->write_lock);
	mutex_init(&hdevice->session_lock);
	mutex_init(&hdevice->clk_pwr_lock);

	if (hal_ctxt.dev_count == 0)
		INIT_LIST_HEAD(&hal_ctxt.dev_head);