Commit 132390c7 authored by Andy Gross's avatar Andy Gross Committed by Greg Kroah-Hartman

staging: drm/omap: Disable DMM debugfs for OMAP3

OMAP3 does not contain a DMM/Tiler block.  As such, we should not
be exposing any DMM debugfs entries on OMAP3 platforms.

Added inline helper function to verify existence of DMM.
Signed-off-by: default avatarAndy Gross <andy.gross@ti.com>
Signed-off-by: default avatarRob Clark <rob@ti.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent f6b6036e
......@@ -112,9 +112,7 @@ int omap_debugfs_init(struct drm_minor *minor)
return ret;
}
/* TODO: only do this if has_dmm.. but this fxn gets called before
* dev_load() so we don't know this yet..
*/
if (dmm_is_available())
ret = drm_debugfs_create_files(omap_dmm_debugfs_list,
ARRAY_SIZE(omap_dmm_debugfs_list),
minor->debugfs_root, minor);
......@@ -131,6 +129,7 @@ void omap_debugfs_cleanup(struct drm_minor *minor)
{
drm_debugfs_remove_files(omap_debugfs_list,
ARRAY_SIZE(omap_debugfs_list), minor);
if (dmm_is_available())
drm_debugfs_remove_files(omap_dmm_debugfs_list,
ARRAY_SIZE(omap_dmm_debugfs_list), minor);
}
......
......@@ -16,6 +16,7 @@
#ifndef OMAP_DMM_TILER_H
#define OMAP_DMM_TILER_H
#include <plat/cpu.h>
#include "omap_drv.h"
#include "tcm.h"
......@@ -132,4 +133,9 @@ struct omap_dmm_platform_data {
int irq;
};
static inline int dmm_is_available(void)
{
return cpu_is_omap44xx();
}
#endif
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment