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

Commit d5108131 authored by Shrenuj Bansal's avatar Shrenuj Bansal
Browse files

msm: kgsl: Add __user attribute to usermode pointers



Change the usermode pointers to use an actual pointer type and
add the __user attribute to them

Change-Id: I0b92298d71064dc1be67a30d2a48659a39c0ff3d
Signed-off-by: default avatarShrenuj Bansal <shrenujb@codeaurora.org>
parent 05c308f7
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -458,8 +458,8 @@ const char *adreno_perfcounter_get_name(struct adreno_device *adreno_dev,
 */

int adreno_perfcounter_query_group(struct adreno_device *adreno_dev,
	unsigned int groupid, unsigned int *countables, unsigned int count,
	unsigned int *max_counters)
	unsigned int groupid, unsigned int __user *countables,
	unsigned int count, unsigned int *max_counters)
{
	struct adreno_perfcounters *counters = adreno_dev->gpudev->perfcounters;
	struct adreno_perfcount_group *group;
+6 −6
Original line number Diff line number Diff line
@@ -247,7 +247,7 @@ struct kgsl_version {
/* structure holds list of ibs */
struct kgsl_ibdesc {
	unsigned long gpuaddr;
	void *hostptr;
	unsigned int __pad;
	unsigned int sizedwords;
	unsigned int ctrl;
};
@@ -267,7 +267,7 @@ struct kgsl_ibdesc {
*/
struct kgsl_device_getproperty {
	unsigned int type;
	void  *value;
	void __user *value;
	unsigned int sizebytes;
};

@@ -554,7 +554,7 @@ struct kgsl_timestamp_event {
	int type;                /* Type of event (see list below) */
	unsigned int timestamp;  /* Timestamp to trigger event on */
	unsigned int context_id; /* Context for the timestamp */
	void *priv;		 /* Pointer to the event specific blob */
	void __user *priv;	 /* Pointer to the event specific blob */
	size_t len;              /* Size of the event specific blob */
};

@@ -763,7 +763,7 @@ struct kgsl_perfcounter_put {
struct kgsl_perfcounter_query {
	unsigned int groupid;
	/* Array to return the current countable for up to size counters */
	unsigned int *countables;
	unsigned int __user *countables;
	unsigned int count;
	unsigned int max_counters;
/* private: reserved for future use */
@@ -792,7 +792,7 @@ struct kgsl_perfcounter_read_group {
};

struct kgsl_perfcounter_read {
	struct kgsl_perfcounter_read_group *reads;
	struct kgsl_perfcounter_read_group __user *reads;
	unsigned int count;
/* private: reserved for future use */
	unsigned int __pad[2]; /* For future binary compatibility */
@@ -812,7 +812,7 @@ struct kgsl_perfcounter_read {
 * size of the working set of memory to be managed.
 */
struct kgsl_gpumem_sync_cache_bulk {
	unsigned int *id_list;
	unsigned int __user *id_list;
	unsigned int count;
	unsigned int op;
/* private: reserved for future use */