提交 5c52cbeb 编写于 作者: G Geert Uytterhoeven 提交者: Linus Torvalds

[PATCH] fbdev modedb: allow refresh rates for named video modes

fbdev modedb: Take into account the specified refresh rates for video modes
specified by name, so e.g.  all of `720p', `720p@60', and `720p@50' work.
Signed-off-by: NGeert Uytterhoeven <Geert.Uytterhoeven@sonycom.com>
Cc: James Simmons <jsimmons@infradead.org>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Paul Mackerras <paulus@samba.org>
Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
上级 11227fd1
......@@ -610,10 +610,8 @@ int fb_find_mode(struct fb_var_screeninfo *var,
diff = refresh;
best = -1;
for (i = 0; i < dbsize; i++) {
if ((name_matches(db[i], name, namelen) &&
!fb_try_mode(var, info, &db[i], bpp)))
return 1;
if (res_specified && res_matches(db[i], xres, yres)) {
if (name_matches(db[i], name, namelen) ||
(res_specified && res_matches(db[i], xres, yres))) {
if(!fb_try_mode(var, info, &db[i], bpp)) {
if(!refresh_specified || db[i].refresh == refresh)
return 1;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册