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

Commit 9277a3bb authored by Rahul Shahare's avatar Rahul Shahare Committed by Gerrit - the friendly Code Review server
Browse files

msm: sde: update check flags to handle CONFIG_DEBUG_FS



Add support to handle disabling of CONFIG_DEBUG_FS.

Change-Id: I8c07434afc36edfae9bd9bc7880d07264eca7650
Signed-off-by: default avatarKrishna Manikandan <mkrishn@codeaurora.org>
[rshaha@codeaurora.org: resolve trivial merge conflicts]
Signed-off-by: default avatarRahul Shahare <rshaha@codeaurora.org>
parent 5bbf6676
Loading
Loading
Loading
Loading
+3 −2
Original line number Diff line number Diff line
@@ -47,8 +47,6 @@ msm_drm-y := \
	sde/sde_connector.o \
	sde/sde_color_processing.o \
	sde/sde_vbif.o \
	sde_dbg.o \
	sde_dbg_evtlog.o \
	sde_io_util.o \
	sde/sde_hw_reg_dma_v1_color_proc.o \
	sde/sde_hw_color_proc_v4.o \
@@ -57,6 +55,9 @@ msm_drm-y := \
	sde_hdcp_1x.o \
	sde_hdcp_2x.o

msm_drm-$(CONFIG_DEBUG_FS) += sde_dbg.o \
	sde_dbg_evtlog.o \

msm_drm-$(CONFIG_DRM_MSM_HDMI) += hdmi/hdmi.o \
	hdmi/hdmi_audio.o \
	hdmi/hdmi_bridge.o \
+3 −1
Original line number Diff line number Diff line
/*
 * Copyright (c) 2014-2019 The Linux Foundation. All rights reserved.
 * Copyright (c) 2014-2020 The Linux Foundation. All rights reserved.
 * Copyright (C) 2013 Red Hat
 * Author: Rob Clark <robdclark@gmail.com>
 *
@@ -666,6 +666,7 @@ static void _sde_crtc_deinit_events(struct sde_crtc *sde_crtc)
		return;
}

#ifdef CONFIG_DEBUG_FS
static int _sde_debugfs_fps_status_show(struct seq_file *s, void *data)
{
	struct sde_crtc *sde_crtc;
@@ -712,6 +713,7 @@ static int _sde_debugfs_fps_status(struct inode *inode, struct file *file)
	return single_open(file, _sde_debugfs_fps_status_show,
			inode->i_private);
}
#endif

static ssize_t set_fps_periodicity(struct device *device,
		struct device_attribute *attr, const char *buf, size_t count)
+3 −3
Original line number Diff line number Diff line
@@ -418,7 +418,7 @@ static inline void sde_dbg_destroy(void)
{
}

static inline void sde_dbg_dump(enum sde_dbg_dump_context,
static inline void sde_dbg_dump(enum sde_dbg_dump_context mode,
	const char *name, ...)
{
}
@@ -439,7 +439,7 @@ static inline void sde_dbg_reg_register_dump_range(const char *base_name,
{
}

void sde_dbg_set_sde_top_offset(u32 blk_off)
static inline void sde_dbg_set_sde_top_offset(u32 blk_off)
{
}

@@ -458,7 +458,7 @@ static inline void sde_rsc_debug_dump(u32 mux_sel)
{
}

static inline void dsi_ctrl_debug_dump(u32 entries, u32 size)
static inline void dsi_ctrl_debug_dump(u32 *entries, u32 size)
{
}

+5 −1
Original line number Diff line number Diff line
@@ -1388,7 +1388,6 @@ void sde_rsc_debug_dump(u32 mux_sel)
	if (rsc->hw_ops.debug_dump)
		rsc->hw_ops.debug_dump(rsc, mux_sel);
}
#endif /* defined(CONFIG_DEBUG_FS) */

static int _sde_debugfs_status_show(struct seq_file *s, void *data)
{
@@ -1669,6 +1668,11 @@ static void _sde_rsc_init_debugfs(struct sde_rsc_priv *rsc, char *name)
	debugfs_create_x32("debug_mode", 0600, rsc->debugfs_root,
							&rsc->debug_mode);
}
#else
static void _sde_rsc_init_debugfs(struct sde_rsc_priv *rsc, char *name)
{
}
#endif /* defined(CONFIG_DEBUG_FS) */

static void sde_rsc_deinit(struct platform_device *pdev,
					struct sde_rsc_priv *rsc)