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

Commit 03fd70b2 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: Fix the KGSL driver to compile when CONFIG_DEBUG_FS=n"

parents 14c1c690 c493fc53
Loading
Loading
Loading
Loading
+6 −1
Original line number Diff line number Diff line
@@ -62,7 +62,6 @@
#define ADRENO_DEFAULT_PWRSCALE_POLICY  NULL
#endif

void adreno_debugfs_init(struct kgsl_device *device);

#define ADRENO_ISTORE_START 0x5000 /* Istore offset */

@@ -897,4 +896,10 @@ static inline void adreno_vbif_start(struct kgsl_device *device,
	}
}

#ifdef CONFIG_DEBUG_FS
void adreno_debugfs_init(struct kgsl_device *device);
#else
static inline void adreno_debugfs_init(struct kgsl_device *device) { }
#endif

#endif /*__ADRENO_H */
+0 −2
Original line number Diff line number Diff line
@@ -23,8 +23,6 @@

#include "a2xx_reg.h"

unsigned int kgsl_cff_dump_enable;

DEFINE_SIMPLE_ATTRIBUTE(kgsl_cff_dump_enable_fops, kgsl_cff_dump_enable_get,
			kgsl_cff_dump_enable_set, "%llu\n");

+17 −0
Original line number Diff line number Diff line
@@ -61,6 +61,7 @@ struct adreno_profile {
#define ADRENO_PROFILE_LOG_BUF_SIZE_DWORDS  (ADRENO_PROFILE_LOG_BUF_SIZE / \
						sizeof(unsigned int))

#ifdef CONFIG_DEBUG_FS
void adreno_profile_init(struct kgsl_device *device);
void adreno_profile_close(struct kgsl_device *device);
int adreno_profile_process_results(struct kgsl_device *device);
@@ -70,6 +71,22 @@ void adreno_profile_preib_processing(struct kgsl_device *device,
void adreno_profile_postib_processing(struct kgsl_device *device,
		unsigned int *cmd_flags, unsigned int **rbptr,
		unsigned int *cmds_gpu);
#else
static inline void adreno_profile_init(struct kgsl_device *device) { }
static inline void adreno_profile_close(struct kgsl_device *device) { }
static inline int adreno_profile_process_results(struct kgsl_device *device)
{
	return 0;
}

static inline void adreno_profile_preib_processing(struct kgsl_device *device,
		unsigned int context_id, unsigned int *cmd_flags,
		unsigned int **rbptr, unsigned int *cmds_gpu) { }

static inline void adreno_profile_postib_processing(struct kgsl_device *device,
		unsigned int *cmd_flags, unsigned int **rbptr,
		unsigned int *cmds_gpu) { }
#endif

static inline bool adreno_profile_enabled(struct adreno_profile *profile)
{
+3 −5
Original line number Diff line number Diff line
@@ -865,11 +865,7 @@ kgsl_get_process_private(struct kgsl_device_private *cur_dev_priv)

	mutex_lock(&private->process_private_mutex);

	/*
	 * If debug root initialized then it means the rest of the fields
	 * are also initialized
	 */
	if (private->debug_root)
	if (test_bit(KGSL_PROCESS_INIT, &private->priv))
		goto done;

	private->mem_rb = RB_ROOT;
@@ -890,6 +886,8 @@ kgsl_get_process_private(struct kgsl_device_private *cur_dev_priv)
	if (kgsl_process_init_debugfs(private))
		goto error;

	set_bit(KGSL_PROCESS_INIT, &private->priv);

done:
	mutex_unlock(&private->process_private_mutex);
	return private;
+2 −2
Original line number Diff line number Diff line
/* Copyright (c) 2002,2008-2011, The Linux Foundation. All rights reserved.
/* Copyright (c) 2002,2008-2011,2013, 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
@@ -35,7 +35,7 @@ static inline void kgsl_core_debugfs_init(void) { }
static inline void kgsl_device_debugfs_init(struct kgsl_device *device) { }
static inline void kgsl_core_debugfs_close(void) { }
static inline struct dentry *kgsl_get_debugfs_dir(void) { return NULL; }
static inline int kgsl_process_init_debugfs(struct kgsl_process_private *)
static inline int kgsl_process_init_debugfs(struct kgsl_process_private *priv)
{
	return 0;
}
Loading