Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
linux
Commits
fa514fbc
Commit
fa514fbc
authored
Jul 21, 2011
by
Paul Mundt
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'viafb-next' of
git://github.com/schandinat/linux-2.6
parents
4af358f8
936a3f77
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
16 additions
and
5 deletions
+16
-5
drivers/video/via/via_modesetting.h
drivers/video/via/via_modesetting.h
+5
-0
drivers/video/via/viafbdev.c
drivers/video/via/viafbdev.c
+11
-5
No files found.
drivers/video/via/via_modesetting.h
View file @
fa514fbc
...
...
@@ -28,6 +28,11 @@
#include <linux/types.h>
#define VIA_PITCH_SIZE (1<<3)
#define VIA_PITCH_MAX 0x3FF8
void
via_set_primary_address
(
u32
addr
);
void
via_set_secondary_address
(
u32
addr
);
void
via_set_primary_pitch
(
u32
pitch
);
...
...
drivers/video/via/viafbdev.c
View file @
fa514fbc
...
...
@@ -151,7 +151,8 @@ static void viafb_update_fix(struct fb_info *info)
info
->
fix
.
visual
=
bpp
==
8
?
FB_VISUAL_PSEUDOCOLOR
:
FB_VISUAL_TRUECOLOR
;
info
->
fix
.
line_length
=
(
info
->
var
.
xres_virtual
*
bpp
/
8
+
7
)
&
~
7
;
info
->
fix
.
line_length
=
ALIGN
(
info
->
var
.
xres_virtual
*
bpp
/
8
,
VIA_PITCH_SIZE
);
}
static
void
viafb_setup_fixinfo
(
struct
fb_fix_screeninfo
*
fix
,
...
...
@@ -238,8 +239,12 @@ static int viafb_check_var(struct fb_var_screeninfo *var,
depth
=
24
;
viafb_fill_var_color_info
(
var
,
depth
);
line
=
(
var
->
xres_virtual
*
var
->
bits_per_pixel
/
8
+
7
)
&
~
7
;
if
(
line
*
var
->
yres_virtual
>
ppar
->
memsize
)
if
(
var
->
xres_virtual
<
var
->
xres
)
var
->
xres_virtual
=
var
->
xres
;
line
=
ALIGN
(
var
->
xres_virtual
*
var
->
bits_per_pixel
/
8
,
VIA_PITCH_SIZE
);
if
(
line
>
VIA_PITCH_MAX
||
line
*
var
->
yres_virtual
>
ppar
->
memsize
)
return
-
EINVAL
;
/* Based on var passed in to calculate the refresh,
...
...
@@ -348,8 +353,9 @@ static int viafb_pan_display(struct fb_var_screeninfo *var,
struct
fb_info
*
info
)
{
struct
viafb_par
*
viapar
=
info
->
par
;
u32
vram_addr
=
(
var
->
yoffset
*
var
->
xres_virtual
+
var
->
xoffset
)
*
(
var
->
bits_per_pixel
/
8
)
+
viapar
->
vram_addr
;
u32
vram_addr
=
viapar
->
vram_addr
+
var
->
yoffset
*
info
->
fix
.
line_length
+
var
->
xoffset
*
info
->
var
.
bits_per_pixel
/
8
;
DEBUG_MSG
(
KERN_DEBUG
"viafb_pan_display, address = %d
\n
"
,
vram_addr
);
if
(
!
viafb_dual_fb
)
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment