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

Commit cfd42c3b 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: Add property to determine GPU bitness"

parents 45c9d895 7dafc10c
Loading
Loading
Loading
Loading
+20 −0
Original line number Diff line number Diff line
@@ -1856,6 +1856,26 @@ static int adreno_getproperty(struct kgsl_device *device,
		}
		status = 0;
		break;
	case KGSL_PROP_DEVICE_BITNESS:
	{
		unsigned int bitness = 32;

		if (sizebytes != sizeof(unsigned int)) {
			status = -EINVAL;
			break;
		}
		/* No of bits used by the GPU */
		if (adreno_support_64bit(adreno_dev))
			bitness = 48;

		if (copy_to_user(value, &bitness,
				sizeof(unsigned int))) {
			status = -EFAULT;
			break;
		}
		status = 0;
	}
	break;

	default:
		status = -EINVAL;
+1 −0
Original line number Diff line number Diff line
@@ -307,6 +307,7 @@ enum kgsl_timestamp_type {
#define KGSL_PROP_UCODE_VERSION		0x15
#define KGSL_PROP_GPMU_VERSION		0x16
#define KGSL_PROP_HIGHEST_BANK_BIT	0x17
#define KGSL_PROP_DEVICE_BITNESS	0x18

struct kgsl_shadowprop {
	unsigned long gpuaddr;