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

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

Merge "msm: kgsl: Dump snapshot on device start failure"

parents 804bc29c 32f5d164
Loading
Loading
Loading
Loading
+7 −1
Original line number Diff line number Diff line
@@ -1096,6 +1096,9 @@ static int _adreno_start(struct adreno_device *adreno_dev)
	unsigned int pmqos_wakeup_vote = device->pwrctrl.pm_qos_wakeup_latency;
	unsigned int pmqos_active_vote = device->pwrctrl.pm_qos_active_latency;

	/* make sure ADRENO_DEVICE_STARTED is not set here */
	BUG_ON(test_bit(ADRENO_DEVICE_STARTED, &adreno_dev->priv));

	pm_qos_update_request(&device->pwrctrl.pm_qos_req_dma,
			pmqos_wakeup_vote);

@@ -1168,7 +1171,10 @@ static int _adreno_start(struct adreno_device *adreno_dev)
	kgsl_pwrctrl_irq(device, KGSL_PWRFLAGS_ON);
	adreno_irqctrl(adreno_dev, 1);

	adreno_perfcounter_start(adreno_dev);
	status = adreno_perfcounter_start(adreno_dev);

	if (status)
		goto error_irq_off;

	status = adreno_ringbuffer_cold_start(adreno_dev);

+5 −1
Original line number Diff line number Diff line
/* Copyright (c) 2012-2014, The Linux Foundation. All rights reserved.
/* Copyright (c) 2012-2015, The Linux Foundation. All rights reserved.
 *
 * This program is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 2 and
@@ -1065,6 +1065,10 @@ int a3xx_perfcounter_enable(struct adreno_device *adreno_dev,
		/* wait for the above commands submitted to complete */
		ret = adreno_ringbuffer_waittimestamp(rb, rb->timestamp,
				ADRENO_IDLE_TIMEOUT);
		if (ret)
			KGSL_DRV_ERR(rb->device,
			"Perfcounter %u/%u/%u start via commands failed %d\n",
			group, counter, countable, ret);
	} else {
		/* Select the desired perfcounter */
		kgsl_regwrite(&adreno_dev->dev, reg->select, countable);
+14 −2
Original line number Diff line number Diff line
/* Copyright (c) 2002,2007-2014, The Linux Foundation. All rights reserved.
/* Copyright (c) 2002,2007-2015, The Linux Foundation. All rights reserved.
 *
 * This program is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 2 and
@@ -477,6 +477,12 @@ static int _ringbuffer_bootstrap_ucode(struct adreno_ringbuffer *rb,
	/* idle device to validate bootstrap */
	ret = adreno_spin_idle(device);

	if (ret) {
		KGSL_DRV_ERR(rb->device,
		"microcode bootstrap failed to idle\n");
		kgsl_device_snapshot(device, NULL);
	}

	/* Clear the chicken bit for speed up on A430 cores */
	if (adreno_is_a430(adreno_dev))
		kgsl_regwrite(device, A4XX_CP_DEBUG,
@@ -551,7 +557,13 @@ static int _ringbuffer_start_common(struct adreno_ringbuffer *rb)
		return status;

	/* idle device to validate ME INIT */
	return adreno_spin_idle(device);
	status = adreno_spin_idle(device);
	if (status) {
		KGSL_DRV_ERR(rb->device,
		"ringbuffer initialization failed to idle\n");
		kgsl_device_snapshot(device, NULL);
	}
	return status;
}

/**