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

Commit c8ff026e 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: Change gpuaddr to unsigned long everywhere"

parents 2fbb2b43 05c308f7
Loading
Loading
Loading
Loading
+5 −5
Original line number Original line Diff line number Diff line
@@ -1828,7 +1828,7 @@ static bool _kgsl_cmdbatch_verify(struct kgsl_device_private *dev_priv,
	for (i = 0; i < cmdbatch->ibcount; i++) {
	for (i = 0; i < cmdbatch->ibcount; i++) {
		if (cmdbatch->ibdesc[i].sizedwords == 0) {
		if (cmdbatch->ibdesc[i].sizedwords == 0) {
			KGSL_DRV_ERR(dev_priv->device,
			KGSL_DRV_ERR(dev_priv->device,
				"invalid size ctx %d ib(%d) %X/%X\n",
				"invalid size ctx %d ib(%d) %lX/%X\n",
				cmdbatch->context->id, i,
				cmdbatch->context->id, i,
				cmdbatch->ibdesc[i].gpuaddr,
				cmdbatch->ibdesc[i].gpuaddr,
				cmdbatch->ibdesc[i].sizedwords);
				cmdbatch->ibdesc[i].sizedwords);
@@ -1839,7 +1839,7 @@ static bool _kgsl_cmdbatch_verify(struct kgsl_device_private *dev_priv,
		if (!kgsl_mmu_gpuaddr_in_range(private->pagetable,
		if (!kgsl_mmu_gpuaddr_in_range(private->pagetable,
			cmdbatch->ibdesc[i].gpuaddr)) {
			cmdbatch->ibdesc[i].gpuaddr)) {
			KGSL_DRV_ERR(dev_priv->device,
			KGSL_DRV_ERR(dev_priv->device,
				"Invalid address ctx %d ib(%d) %X/%X\n",
				"Invalid address ctx %d ib(%d) %lX/%X\n",
				cmdbatch->context->id, i,
				cmdbatch->context->id, i,
				cmdbatch->ibdesc[i].gpuaddr,
				cmdbatch->ibdesc[i].gpuaddr,
				cmdbatch->ibdesc[i].sizedwords);
				cmdbatch->ibdesc[i].sizedwords);
@@ -2207,7 +2207,7 @@ static long kgsl_ioctl_sharedmem_free(struct kgsl_device_private *dev_priv,


	entry = kgsl_sharedmem_find(private, param->gpuaddr);
	entry = kgsl_sharedmem_find(private, param->gpuaddr);
	if (!entry) {
	if (!entry) {
		KGSL_MEM_INFO(dev_priv->device, "invalid gpuaddr %08x\n",
		KGSL_MEM_INFO(dev_priv->device, "invalid gpuaddr %08lx\n",
				param->gpuaddr);
				param->gpuaddr);
		return -EINVAL;
		return -EINVAL;
	}
	}
@@ -2855,7 +2855,7 @@ kgsl_ioctl_gpumem_sync_cache(struct kgsl_device_private *dev_priv,
		entry = kgsl_sharedmem_find(private, param->gpuaddr);
		entry = kgsl_sharedmem_find(private, param->gpuaddr);
		if (entry == NULL) {
		if (entry == NULL) {
			KGSL_MEM_INFO(dev_priv->device,
			KGSL_MEM_INFO(dev_priv->device,
					"can't find gpuaddr %x\n",
					"can't find gpuaddr %lx\n",
					param->gpuaddr);
					param->gpuaddr);
			return -EINVAL;
			return -EINVAL;
		}
		}
@@ -2974,7 +2974,7 @@ kgsl_ioctl_sharedmem_flush_cache(struct kgsl_device_private *dev_priv,
	entry = kgsl_sharedmem_find(private, param->gpuaddr);
	entry = kgsl_sharedmem_find(private, param->gpuaddr);
	if (entry == NULL) {
	if (entry == NULL) {
		KGSL_MEM_INFO(dev_priv->device,
		KGSL_MEM_INFO(dev_priv->device,
				"can't find gpuaddr %x\n",
				"can't find gpuaddr %lx\n",
				param->gpuaddr);
				param->gpuaddr);
		return -EINVAL;
		return -EINVAL;
	}
	}
+14 −14
Original line number Original line Diff line number Diff line
@@ -200,7 +200,7 @@ enum kgsl_property_type {
};
};


struct kgsl_shadowprop {
struct kgsl_shadowprop {
	unsigned int gpuaddr;
	unsigned long gpuaddr;
	unsigned int size;
	unsigned int size;
	unsigned int flags; /* contains KGSL_FLAGS_ values */
	unsigned int flags; /* contains KGSL_FLAGS_ values */
};
};
@@ -246,7 +246,7 @@ struct kgsl_version {


/* structure holds list of ibs */
/* structure holds list of ibs */
struct kgsl_ibdesc {
struct kgsl_ibdesc {
	unsigned int gpuaddr;
	unsigned long gpuaddr;
	void *hostptr;
	void *hostptr;
	unsigned int sizedwords;
	unsigned int sizedwords;
	unsigned int ctrl;
	unsigned int ctrl;
@@ -340,7 +340,7 @@ struct kgsl_cmdstream_readtimestamp {
 * type should be a value from enum kgsl_timestamp_type
 * type should be a value from enum kgsl_timestamp_type
 */
 */
struct kgsl_cmdstream_freememontimestamp {
struct kgsl_cmdstream_freememontimestamp {
	unsigned int gpuaddr;
	unsigned long gpuaddr;
	unsigned int type;
	unsigned int type;
	unsigned int timestamp;
	unsigned int timestamp;
};
};
@@ -380,10 +380,10 @@ struct kgsl_drawctxt_destroy {
 * into the GPU address space */
 * into the GPU address space */
struct kgsl_map_user_mem {
struct kgsl_map_user_mem {
	int fd;
	int fd;
	unsigned int gpuaddr;   /*output param */
	unsigned long gpuaddr;   /*output param */
	unsigned int len;
	unsigned int len;
	unsigned int offset;
	unsigned int offset;
	unsigned int hostptr;   /*input param */
	unsigned long hostptr;   /*input param */
	enum kgsl_user_mem_type memtype;
	enum kgsl_user_mem_type memtype;
	unsigned int flags;
	unsigned int flags;
};
};
@@ -402,7 +402,7 @@ struct kgsl_cmdstream_readtimestamp_ctxtid {


struct kgsl_cmdstream_freememontimestamp_ctxtid {
struct kgsl_cmdstream_freememontimestamp_ctxtid {
	unsigned int context_id;
	unsigned int context_id;
	unsigned int gpuaddr;
	unsigned long gpuaddr;
	unsigned int type;
	unsigned int type;
	unsigned int timestamp;
	unsigned int timestamp;
};
};
@@ -414,7 +414,7 @@ struct kgsl_cmdstream_freememontimestamp_ctxtid {
/* add a block of pmem or fb into the GPU address space */
/* add a block of pmem or fb into the GPU address space */
struct kgsl_sharedmem_from_pmem {
struct kgsl_sharedmem_from_pmem {
	int pmem_fd;
	int pmem_fd;
	unsigned int gpuaddr;	/*output param */
	unsigned long gpuaddr;	/*output param */
	unsigned int len;
	unsigned int len;
	unsigned int offset;
	unsigned int offset;
};
};
@@ -424,7 +424,7 @@ struct kgsl_sharedmem_from_pmem {


/* remove memory from the GPU's address space */
/* remove memory from the GPU's address space */
struct kgsl_sharedmem_free {
struct kgsl_sharedmem_free {
	unsigned int gpuaddr;
	unsigned long gpuaddr;
};
};


#define IOCTL_KGSL_SHAREDMEM_FREE \
#define IOCTL_KGSL_SHAREDMEM_FREE \
@@ -453,7 +453,7 @@ struct kgsl_gmem_desc {


struct kgsl_buffer_desc {
struct kgsl_buffer_desc {
	void 			*hostptr;
	void 			*hostptr;
	unsigned int	gpuaddr;
	unsigned long	gpuaddr;
	int				size;
	int				size;
	unsigned int	format;
	unsigned int	format;
	unsigned int  	pitch;
	unsigned int  	pitch;
@@ -480,7 +480,7 @@ struct kgsl_bind_gmem_shadow {
 */
 */


struct kgsl_sharedmem_from_vmalloc {
struct kgsl_sharedmem_from_vmalloc {
	unsigned int gpuaddr;	/*output param */
	unsigned long gpuaddr;	/*output param */
	unsigned int hostptr;
	unsigned int hostptr;
	unsigned int flags;
	unsigned int flags;
};
};
@@ -527,7 +527,7 @@ struct kgsl_cmdwindow_write {
	_IOW(KGSL_IOC_TYPE, 0x2e, struct kgsl_cmdwindow_write)
	_IOW(KGSL_IOC_TYPE, 0x2e, struct kgsl_cmdwindow_write)


struct kgsl_gpumem_alloc {
struct kgsl_gpumem_alloc {
	unsigned long gpuaddr;
	unsigned long gpuaddr; /* output param */
	size_t size;
	size_t size;
	unsigned int flags;
	unsigned int flags;
};
};
@@ -536,7 +536,7 @@ struct kgsl_gpumem_alloc {
	_IOWR(KGSL_IOC_TYPE, 0x2f, struct kgsl_gpumem_alloc)
	_IOWR(KGSL_IOC_TYPE, 0x2f, struct kgsl_gpumem_alloc)


struct kgsl_cff_syncmem {
struct kgsl_cff_syncmem {
	unsigned int gpuaddr;
	unsigned long gpuaddr;
	unsigned int len;
	unsigned int len;
	unsigned int __pad[2]; /* For future binary compatibility */
	unsigned int __pad[2]; /* For future binary compatibility */
};
};
@@ -678,7 +678,7 @@ struct kgsl_gpumem_get_info {
 *
 *
 */
 */
struct kgsl_gpumem_sync_cache {
struct kgsl_gpumem_sync_cache {
	unsigned int gpuaddr;
	unsigned long gpuaddr;
	unsigned int id;
	unsigned int id;
	unsigned int op;
	unsigned int op;
/* private: reserved for future use*/
/* private: reserved for future use*/