Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openeuler
Kernel
提交
37811fcc
K
Kernel
项目概览
openeuler
/
Kernel
大约 1 年 前同步成功
通知
5
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
K
Kernel
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
37811fcc
编写于
8月 25, 2010
作者:
C
Chris Wilson
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
drm/i915: Show framebuffer info in debugfs
Signed-off-by:
N
Chris Wilson
<
chris@chris-wilson.co.uk
>
上级
70d39fe4
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
73 addition
and
25 deletion
+73
-25
drivers/gpu/drm/i915/i915_debugfs.c
drivers/gpu/drm/i915/i915_debugfs.c
+66
-17
drivers/gpu/drm/i915/intel_drv.h
drivers/gpu/drm/i915/intel_drv.h
+7
-1
drivers/gpu/drm/i915/intel_fb.c
drivers/gpu/drm/i915/intel_fb.c
+0
-7
未找到文件。
drivers/gpu/drm/i915/i915_debugfs.c
浏览文件 @
37811fcc
...
...
@@ -104,6 +104,27 @@ static const char *get_tiling_flag(struct drm_i915_gem_object *obj_priv)
}
}
static
void
describe_obj
(
struct
seq_file
*
m
,
struct
drm_i915_gem_object
*
obj
)
{
seq_printf
(
m
,
"%p: %s%s %8zd %08x %08x %d%s%s"
,
&
obj
->
base
,
get_pin_flag
(
obj
),
get_tiling_flag
(
obj
),
obj
->
base
.
size
,
obj
->
base
.
read_domains
,
obj
->
base
.
write_domain
,
obj
->
last_rendering_seqno
,
obj
->
dirty
?
" dirty"
:
""
,
obj
->
madv
==
I915_MADV_DONTNEED
?
" purgeable"
:
""
);
if
(
obj
->
base
.
name
)
seq_printf
(
m
,
" (name: %d)"
,
obj
->
base
.
name
);
if
(
obj
->
fence_reg
!=
I915_FENCE_REG_NONE
)
seq_printf
(
m
,
" (fence: %d)"
,
obj
->
fence_reg
);
if
(
obj
->
gtt_space
!=
NULL
)
seq_printf
(
m
,
" (gtt_offset: %08x)"
,
obj
->
gtt_offset
);
}
static
int
i915_gem_object_list_info
(
struct
seq_file
*
m
,
void
*
data
)
{
struct
drm_info_node
*
node
=
(
struct
drm_info_node
*
)
m
->
private
;
...
...
@@ -137,23 +158,8 @@ static int i915_gem_object_list_info(struct seq_file *m, void *data)
}
list_for_each_entry
(
obj_priv
,
head
,
list
)
{
seq_printf
(
m
,
" %p: %s %8zd %08x %08x %d%s%s"
,
&
obj_priv
->
base
,
get_pin_flag
(
obj_priv
),
obj_priv
->
base
.
size
,
obj_priv
->
base
.
read_domains
,
obj_priv
->
base
.
write_domain
,
obj_priv
->
last_rendering_seqno
,
obj_priv
->
dirty
?
" dirty"
:
""
,
obj_priv
->
madv
==
I915_MADV_DONTNEED
?
" purgeable"
:
""
);
if
(
obj_priv
->
base
.
name
)
seq_printf
(
m
,
" (name: %d)"
,
obj_priv
->
base
.
name
);
if
(
obj_priv
->
fence_reg
!=
I915_FENCE_REG_NONE
)
seq_printf
(
m
,
" (fence: %d)"
,
obj_priv
->
fence_reg
);
if
(
obj_priv
->
gtt_space
!=
NULL
)
seq_printf
(
m
,
" (gtt_offset: %08x)"
,
obj_priv
->
gtt_offset
);
seq_printf
(
m
,
" "
);
describe_obj
(
m
,
obj_priv
);
seq_printf
(
m
,
"
\n
"
);
}
...
...
@@ -815,6 +821,48 @@ static int i915_opregion(struct seq_file *m, void *unused)
return
0
;
}
static
int
i915_gem_framebuffer_info
(
struct
seq_file
*
m
,
void
*
data
)
{
struct
drm_info_node
*
node
=
(
struct
drm_info_node
*
)
m
->
private
;
struct
drm_device
*
dev
=
node
->
minor
->
dev
;
drm_i915_private_t
*
dev_priv
=
dev
->
dev_private
;
struct
intel_fbdev
*
ifbdev
;
struct
intel_framebuffer
*
fb
;
int
ret
;
ret
=
mutex_lock_interruptible
(
&
dev
->
mode_config
.
mutex
);
if
(
ret
)
return
ret
;
ifbdev
=
dev_priv
->
fbdev
;
fb
=
to_intel_framebuffer
(
ifbdev
->
helper
.
fb
);
seq_printf
(
m
,
"fbcon size: %d x %d, depth %d, %d bpp, obj "
,
fb
->
base
.
width
,
fb
->
base
.
height
,
fb
->
base
.
depth
,
fb
->
base
.
bits_per_pixel
);
describe_obj
(
m
,
to_intel_bo
(
fb
->
obj
));
seq_printf
(
m
,
"
\n
"
);
list_for_each_entry
(
fb
,
&
dev
->
mode_config
.
fb_list
,
base
.
head
)
{
if
(
&
fb
->
base
==
ifbdev
->
helper
.
fb
)
continue
;
seq_printf
(
m
,
"user size: %d x %d, depth %d, %d bpp, obj "
,
fb
->
base
.
width
,
fb
->
base
.
height
,
fb
->
base
.
depth
,
fb
->
base
.
bits_per_pixel
);
describe_obj
(
m
,
to_intel_bo
(
fb
->
obj
));
seq_printf
(
m
,
"
\n
"
);
}
mutex_unlock
(
&
dev
->
mode_config
.
mutex
);
return
0
;
}
static
int
i915_wedged_open
(
struct
inode
*
inode
,
struct
file
*
filp
)
...
...
@@ -944,6 +992,7 @@ static struct drm_info_list i915_debugfs_list[] = {
{
"i915_fbc_status"
,
i915_fbc_status
,
0
},
{
"i915_sr_status"
,
i915_sr_status
,
0
},
{
"i915_opregion"
,
i915_opregion
,
0
},
{
"i915_gem_framebuffer"
,
i915_gem_framebuffer_info
,
0
},
};
#define I915_DEBUGFS_ENTRIES ARRAY_SIZE(i915_debugfs_list)
...
...
drivers/gpu/drm/i915/intel_drv.h
浏览文件 @
37811fcc
...
...
@@ -30,8 +30,8 @@
#include <linux/i2c-algo-bit.h>
#include "i915_drv.h"
#include "drm_crtc.h"
#include "drm_crtc_helper.h"
#include "drm_fb_helper.h"
#define _wait_for(COND, MS, W) ({ \
unsigned long timeout__ = jiffies + msecs_to_jiffies(MS); \
...
...
@@ -129,6 +129,12 @@ struct intel_framebuffer {
struct
drm_gem_object
*
obj
;
};
struct
intel_fbdev
{
struct
drm_fb_helper
helper
;
struct
intel_framebuffer
ifb
;
struct
list_head
fbdev_list
;
struct
drm_display_mode
*
our_mode
;
};
struct
intel_encoder
{
struct
drm_encoder
enc
;
...
...
drivers/gpu/drm/i915/intel_fb.c
浏览文件 @
37811fcc
...
...
@@ -44,13 +44,6 @@
#include "i915_drm.h"
#include "i915_drv.h"
struct
intel_fbdev
{
struct
drm_fb_helper
helper
;
struct
intel_framebuffer
ifb
;
struct
list_head
fbdev_list
;
struct
drm_display_mode
*
our_mode
;
};
static
struct
fb_ops
intelfb_ops
=
{
.
owner
=
THIS_MODULE
,
.
fb_check_var
=
drm_fb_helper_check_var
,
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录