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
Kirill Smelkov
linux
Commits
8fe573f2
Commit
8fe573f2
authored
Mar 03, 2003
by
David S. Miller
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[FRAMEBUFFER]: No need for check_var/set_par ops in SBUS fb drivers.
parent
2d3ec1e9
Changes
7
Show whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
0 additions
and
268 deletions
+0
-268
drivers/video/bw2.c
drivers/video/bw2.c
+0
-38
drivers/video/cg14.c
drivers/video/cg14.c
+0
-38
drivers/video/cg3.c
drivers/video/cg3.c
+0
-38
drivers/video/cg6.c
drivers/video/cg6.c
+0
-38
drivers/video/ffb.c
drivers/video/ffb.c
+0
-40
drivers/video/p9100.c
drivers/video/p9100.c
+0
-38
drivers/video/tcx.c
drivers/video/tcx.c
+0
-38
No files found.
drivers/video/bw2.c
View file @
8fe573f2
...
@@ -33,8 +33,6 @@
...
@@ -33,8 +33,6 @@
* Local functions.
* Local functions.
*/
*/
static
int
bw2_check_var
(
struct
fb_var_screeninfo
*
,
struct
fb_info
*
);
static
int
bw2_set_par
(
struct
fb_info
*
);
static
int
bw2_blank
(
int
,
struct
fb_info
*
);
static
int
bw2_blank
(
int
,
struct
fb_info
*
);
static
int
bw2_mmap
(
struct
fb_info
*
,
struct
file
*
,
struct
vm_area_struct
*
);
static
int
bw2_mmap
(
struct
fb_info
*
,
struct
file
*
,
struct
vm_area_struct
*
);
...
@@ -45,8 +43,6 @@ static int bw2_mmap(struct fb_info *, struct file *, struct vm_area_struct *);
...
@@ -45,8 +43,6 @@ static int bw2_mmap(struct fb_info *, struct file *, struct vm_area_struct *);
static
struct
fb_ops
bw2_ops
=
{
static
struct
fb_ops
bw2_ops
=
{
.
owner
=
THIS_MODULE
,
.
owner
=
THIS_MODULE
,
.
fb_check_var
=
bw2_check_var
,
.
fb_set_par
=
bw2_set_par
,
.
fb_blank
=
bw2_blank
,
.
fb_blank
=
bw2_blank
,
.
fb_fillrect
=
cfb_fillrect
,
.
fb_fillrect
=
cfb_fillrect
,
.
fb_copyarea
=
cfb_copyarea
,
.
fb_copyarea
=
cfb_copyarea
,
...
@@ -123,39 +119,6 @@ struct bw2_par {
...
@@ -123,39 +119,6 @@ struct bw2_par {
struct
list_head
list
;
struct
list_head
list
;
};
};
/**
* bw2_check_var - Optional function. Validates a var passed in.
* @var: frame buffer variable screen structure
* @info: frame buffer structure that represents a single frame buffer
*/
static
int
bw2_check_var
(
struct
fb_var_screeninfo
*
var
,
struct
fb_info
*
info
)
{
if
(
var
->
bits_per_pixel
!=
8
)
return
-
EINVAL
;
if
(
var
->
xres_virtual
!=
var
->
xres
||
var
->
yres_virtual
!=
var
->
yres
)
return
-
EINVAL
;
if
(
var
->
nonstd
)
return
-
EINVAL
;
if
((
var
->
vmode
&
FB_VMODE_MASK
)
!=
FB_VMODE_NONINTERLACED
)
return
-
EINVAL
;
if
(
var
->
xres
!=
info
->
var
.
xres
||
var
->
yres
!=
info
->
var
.
yres
)
return
-
EINVAL
;
return
0
;
}
/**
* bw2_set_par - Optional function. Alters the hardware state.
* @info: frame buffer structure that represents a single frame buffer
*/
static
int
bw2_set_par
(
struct
fb_info
*
info
)
{
return
0
;
}
/**
/**
* bw2_blank - Optional function. Blanks the display.
* bw2_blank - Optional function. Blanks the display.
* @blank_mode: the blank mode we want.
* @blank_mode: the blank mode we want.
...
@@ -387,7 +350,6 @@ static void bw2_init_one(struct sbus_dev *sdev)
...
@@ -387,7 +350,6 @@ static void bw2_init_one(struct sbus_dev *sdev)
bw2_blank
(
0
,
&
all
->
info
);
bw2_blank
(
0
,
&
all
->
info
);
bw2_set_par
(
&
all
->
info
);
bw2_init_fix
(
&
all
->
info
,
linebytes
);
bw2_init_fix
(
&
all
->
info
,
linebytes
);
if
(
register_framebuffer
(
&
all
->
info
)
<
0
)
{
if
(
register_framebuffer
(
&
all
->
info
)
<
0
)
{
...
...
drivers/video/cg14.c
View file @
8fe573f2
...
@@ -28,8 +28,6 @@
...
@@ -28,8 +28,6 @@
* Local functions.
* Local functions.
*/
*/
static
int
cg14_check_var
(
struct
fb_var_screeninfo
*
,
struct
fb_info
*
);
static
int
cg14_set_par
(
struct
fb_info
*
);
static
int
cg14_setcolreg
(
unsigned
,
unsigned
,
unsigned
,
unsigned
,
static
int
cg14_setcolreg
(
unsigned
,
unsigned
,
unsigned
,
unsigned
,
unsigned
,
struct
fb_info
*
);
unsigned
,
struct
fb_info
*
);
...
@@ -43,8 +41,6 @@ static int cg14_ioctl(struct inode *, struct file *, unsigned int,
...
@@ -43,8 +41,6 @@ static int cg14_ioctl(struct inode *, struct file *, unsigned int,
static
struct
fb_ops
cg14_ops
=
{
static
struct
fb_ops
cg14_ops
=
{
.
owner
=
THIS_MODULE
,
.
owner
=
THIS_MODULE
,
.
fb_check_var
=
cg14_check_var
,
.
fb_set_par
=
cg14_set_par
,
.
fb_setcolreg
=
cg14_setcolreg
,
.
fb_setcolreg
=
cg14_setcolreg
,
.
fb_fillrect
=
cfb_fillrect
,
.
fb_fillrect
=
cfb_fillrect
,
.
fb_copyarea
=
cfb_copyarea
,
.
fb_copyarea
=
cfb_copyarea
,
...
@@ -219,39 +215,6 @@ static void __cg14_reset(struct cg14_par *par)
...
@@ -219,39 +215,6 @@ static void __cg14_reset(struct cg14_par *par)
sbus_writeb
(
val
,
&
regs
->
mcr
);
sbus_writeb
(
val
,
&
regs
->
mcr
);
}
}
/**
* cg14_check_var - Optional function. Validates a var passed in.
* @var: frame buffer variable screen structure
* @info: frame buffer structure that represents a single frame buffer
*/
static
int
cg14_check_var
(
struct
fb_var_screeninfo
*
var
,
struct
fb_info
*
info
)
{
if
(
var
->
bits_per_pixel
!=
8
)
return
-
EINVAL
;
if
(
var
->
xres_virtual
!=
var
->
xres
||
var
->
yres_virtual
!=
var
->
yres
)
return
-
EINVAL
;
if
(
var
->
nonstd
)
return
-
EINVAL
;
if
((
var
->
vmode
&
FB_VMODE_MASK
)
!=
FB_VMODE_NONINTERLACED
)
return
-
EINVAL
;
if
(
var
->
xres
!=
info
->
var
.
xres
||
var
->
yres
!=
info
->
var
.
yres
)
return
-
EINVAL
;
return
0
;
}
/**
* cg14_set_par - Optional function. Alters the hardware state.
* @info: frame buffer structure that represents a single frame buffer
*/
static
int
cg14_set_par
(
struct
fb_info
*
info
)
{
return
0
;
}
/**
/**
* cg14_setcolreg - Optional function. Sets a color register.
* cg14_setcolreg - Optional function. Sets a color register.
* @regno: boolean, 0 copy local, 1 get_user() function
* @regno: boolean, 0 copy local, 1 get_user() function
...
@@ -523,7 +486,6 @@ static void cg14_init_one(struct sbus_dev *sdev, int node, int parent_node)
...
@@ -523,7 +486,6 @@ static void cg14_init_one(struct sbus_dev *sdev, int node, int parent_node)
return
;
return
;
}
}
cg14_set_par
(
&
all
->
info
);
cg14_init_fix
(
&
all
->
info
,
linebytes
);
cg14_init_fix
(
&
all
->
info
,
linebytes
);
if
(
register_framebuffer
(
&
all
->
info
)
<
0
)
{
if
(
register_framebuffer
(
&
all
->
info
)
<
0
)
{
...
...
drivers/video/cg3.c
View file @
8fe573f2
...
@@ -29,8 +29,6 @@
...
@@ -29,8 +29,6 @@
* Local functions.
* Local functions.
*/
*/
static
int
cg3_check_var
(
struct
fb_var_screeninfo
*
,
struct
fb_info
*
);
static
int
cg3_set_par
(
struct
fb_info
*
);
static
int
cg3_setcolreg
(
unsigned
,
unsigned
,
unsigned
,
unsigned
,
static
int
cg3_setcolreg
(
unsigned
,
unsigned
,
unsigned
,
unsigned
,
unsigned
,
struct
fb_info
*
);
unsigned
,
struct
fb_info
*
);
static
int
cg3_blank
(
int
,
struct
fb_info
*
);
static
int
cg3_blank
(
int
,
struct
fb_info
*
);
...
@@ -43,8 +41,6 @@ static int cg3_mmap(struct fb_info *, struct file *, struct vm_area_struct *);
...
@@ -43,8 +41,6 @@ static int cg3_mmap(struct fb_info *, struct file *, struct vm_area_struct *);
static
struct
fb_ops
cg3_ops
=
{
static
struct
fb_ops
cg3_ops
=
{
.
owner
=
THIS_MODULE
,
.
owner
=
THIS_MODULE
,
.
fb_check_var
=
cg3_check_var
,
.
fb_set_par
=
cg3_set_par
,
.
fb_setcolreg
=
cg3_setcolreg
,
.
fb_setcolreg
=
cg3_setcolreg
,
.
fb_blank
=
cg3_blank
,
.
fb_blank
=
cg3_blank
,
.
fb_fillrect
=
cfb_fillrect
,
.
fb_fillrect
=
cfb_fillrect
,
...
@@ -126,39 +122,6 @@ struct cg3_par {
...
@@ -126,39 +122,6 @@ struct cg3_par {
struct
list_head
list
;
struct
list_head
list
;
};
};
/**
* cg3_check_var - Optional function. Validates a var passed in.
* @var: frame buffer variable screen structure
* @info: frame buffer structure that represents a single frame buffer
*/
static
int
cg3_check_var
(
struct
fb_var_screeninfo
*
var
,
struct
fb_info
*
info
)
{
if
(
var
->
bits_per_pixel
!=
8
)
return
-
EINVAL
;
if
(
var
->
xres_virtual
!=
var
->
xres
||
var
->
yres_virtual
!=
var
->
yres
)
return
-
EINVAL
;
if
(
var
->
nonstd
)
return
-
EINVAL
;
if
((
var
->
vmode
&
FB_VMODE_MASK
)
!=
FB_VMODE_NONINTERLACED
)
return
-
EINVAL
;
if
(
var
->
xres
!=
info
->
var
.
xres
||
var
->
yres
!=
info
->
var
.
yres
)
return
-
EINVAL
;
return
0
;
}
/**
* cg3_set_par - Optional function. Alters the hardware state.
* @info: frame buffer structure that represents a single frame buffer
*/
static
int
cg3_set_par
(
struct
fb_info
*
info
)
{
return
0
;
}
/**
/**
* cg3_setcolreg - Optional function. Sets a color register.
* cg3_setcolreg - Optional function. Sets a color register.
* @regno: boolean, 0 copy local, 1 get_user() function
* @regno: boolean, 0 copy local, 1 get_user() function
...
@@ -445,7 +408,6 @@ static void cg3_init_one(struct sbus_dev *sdev)
...
@@ -445,7 +408,6 @@ static void cg3_init_one(struct sbus_dev *sdev)
return
;
return
;
}
}
cg3_set_par
(
&
all
->
info
);
cg3_init_fix
(
&
all
->
info
,
linebytes
);
cg3_init_fix
(
&
all
->
info
,
linebytes
);
if
(
register_framebuffer
(
&
all
->
info
)
<
0
)
{
if
(
register_framebuffer
(
&
all
->
info
)
<
0
)
{
...
...
drivers/video/cg6.c
View file @
8fe573f2
...
@@ -29,8 +29,6 @@
...
@@ -29,8 +29,6 @@
* Local functions.
* Local functions.
*/
*/
static
int
cg6_check_var
(
struct
fb_var_screeninfo
*
,
struct
fb_info
*
);
static
int
cg6_set_par
(
struct
fb_info
*
);
static
int
cg6_setcolreg
(
unsigned
,
unsigned
,
unsigned
,
unsigned
,
static
int
cg6_setcolreg
(
unsigned
,
unsigned
,
unsigned
,
unsigned
,
unsigned
,
struct
fb_info
*
);
unsigned
,
struct
fb_info
*
);
static
int
cg6_blank
(
int
,
struct
fb_info
*
);
static
int
cg6_blank
(
int
,
struct
fb_info
*
);
...
@@ -46,8 +44,6 @@ static int cg6_mmap(struct fb_info *, struct file *, struct vm_area_struct *);
...
@@ -46,8 +44,6 @@ static int cg6_mmap(struct fb_info *, struct file *, struct vm_area_struct *);
static
struct
fb_ops
cg6_ops
=
{
static
struct
fb_ops
cg6_ops
=
{
.
owner
=
THIS_MODULE
,
.
owner
=
THIS_MODULE
,
.
fb_check_var
=
cg6_check_var
,
.
fb_set_par
=
cg6_set_par
,
.
fb_setcolreg
=
cg6_setcolreg
,
.
fb_setcolreg
=
cg6_setcolreg
,
.
fb_blank
=
cg6_blank
,
.
fb_blank
=
cg6_blank
,
.
fb_fillrect
=
cg6_fillrect
,
.
fb_fillrect
=
cg6_fillrect
,
...
@@ -405,39 +401,6 @@ static void cg6_imageblit(struct fb_info *info, struct fb_image *image)
...
@@ -405,39 +401,6 @@ static void cg6_imageblit(struct fb_info *info, struct fb_image *image)
spin_unlock_irqrestore
(
&
par
->
lock
,
flags
);
spin_unlock_irqrestore
(
&
par
->
lock
,
flags
);
}
}
/**
* cg6_check_var - Optional function. Validates a var passed in.
* @var: frame buffer variable screen structure
* @info: frame buffer structure that represents a single frame buffer
*/
static
int
cg6_check_var
(
struct
fb_var_screeninfo
*
var
,
struct
fb_info
*
info
)
{
if
(
var
->
bits_per_pixel
!=
8
)
return
-
EINVAL
;
if
(
var
->
xres_virtual
!=
var
->
xres
||
var
->
yres_virtual
!=
var
->
yres
)
return
-
EINVAL
;
if
(
var
->
nonstd
)
return
-
EINVAL
;
if
((
var
->
vmode
&
FB_VMODE_MASK
)
!=
FB_VMODE_NONINTERLACED
)
return
-
EINVAL
;
if
(
var
->
xres
!=
info
->
var
.
xres
||
var
->
yres
!=
info
->
var
.
yres
)
return
-
EINVAL
;
return
0
;
}
/**
* cg6_set_par - Optional function. Alters the hardware state.
* @info: frame buffer structure that represents a single frame buffer
*/
static
int
cg6_set_par
(
struct
fb_info
*
info
)
{
return
0
;
}
/**
/**
* cg6_setcolreg - Optional function. Sets a color register.
* cg6_setcolreg - Optional function. Sets a color register.
* @regno: boolean, 0 copy local, 1 get_user() function
* @regno: boolean, 0 copy local, 1 get_user() function
...
@@ -731,7 +694,6 @@ static void cg6_init_one(struct sbus_dev *sdev)
...
@@ -731,7 +694,6 @@ static void cg6_init_one(struct sbus_dev *sdev)
return
;
return
;
}
}
cg6_set_par
(
&
all
->
info
);
cg6_init_fix
(
&
all
->
info
,
linebytes
);
cg6_init_fix
(
&
all
->
info
,
linebytes
);
if
(
register_framebuffer
(
&
all
->
info
)
<
0
)
{
if
(
register_framebuffer
(
&
all
->
info
)
<
0
)
{
...
...
drivers/video/ffb.c
View file @
8fe573f2
...
@@ -27,8 +27,6 @@
...
@@ -27,8 +27,6 @@
* Local functions.
* Local functions.
*/
*/
static
int
ffb_check_var
(
struct
fb_var_screeninfo
*
,
struct
fb_info
*
);
static
int
ffb_set_par
(
struct
fb_info
*
);
static
int
ffb_setcolreg
(
unsigned
,
unsigned
,
unsigned
,
unsigned
,
static
int
ffb_setcolreg
(
unsigned
,
unsigned
,
unsigned
,
unsigned
,
unsigned
,
struct
fb_info
*
);
unsigned
,
struct
fb_info
*
);
static
int
ffb_blank
(
int
,
struct
fb_info
*
);
static
int
ffb_blank
(
int
,
struct
fb_info
*
);
...
@@ -46,8 +44,6 @@ static int ffb_mmap(struct fb_info *, struct file *, struct vm_area_struct *);
...
@@ -46,8 +44,6 @@ static int ffb_mmap(struct fb_info *, struct file *, struct vm_area_struct *);
static
struct
fb_ops
ffb_ops
=
{
static
struct
fb_ops
ffb_ops
=
{
.
owner
=
THIS_MODULE
,
.
owner
=
THIS_MODULE
,
.
fb_check_var
=
ffb_check_var
,
.
fb_set_par
=
ffb_set_par
,
.
fb_setcolreg
=
ffb_setcolreg
,
.
fb_setcolreg
=
ffb_setcolreg
,
.
fb_blank
=
ffb_blank
,
.
fb_blank
=
ffb_blank
,
.
fb_fillrect
=
ffb_fillrect
,
.
fb_fillrect
=
ffb_fillrect
,
...
@@ -672,41 +668,6 @@ static void ffb_fixup_var_rgb(struct fb_var_screeninfo *var)
...
@@ -672,41 +668,6 @@ static void ffb_fixup_var_rgb(struct fb_var_screeninfo *var)
var
->
transp
.
length
=
0
;
var
->
transp
.
length
=
0
;
}
}
/**
* ffb_check_var - Optional function. Validates a var passed in.
* @var: frame buffer variable screen structure
* @info: frame buffer structure that represents a single frame buffer
*/
static
int
ffb_check_var
(
struct
fb_var_screeninfo
*
var
,
struct
fb_info
*
info
)
{
if
(
var
->
bits_per_pixel
!=
32
)
return
-
EINVAL
;
if
(
var
->
xres_virtual
!=
var
->
xres
||
var
->
yres_virtual
!=
var
->
yres
)
return
-
EINVAL
;
if
(
var
->
nonstd
)
return
-
EINVAL
;
if
((
var
->
vmode
&
FB_VMODE_MASK
)
!=
FB_VMODE_NONINTERLACED
)
return
-
EINVAL
;
if
(
var
->
xres
!=
info
->
var
.
xres
||
var
->
yres
!=
info
->
var
.
yres
)
return
-
EINVAL
;
ffb_fixup_var_rgb
(
var
);
return
0
;
}
/**
* ffb_set_par - Optional function. Alters the hardware state.
* @info: frame buffer structure that represents a single frame buffer
*/
static
int
ffb_set_par
(
struct
fb_info
*
info
)
{
return
0
;
}
/**
/**
* ffb_setcolreg - Optional function. Sets a color register.
* ffb_setcolreg - Optional function. Sets a color register.
* @regno: boolean, 0 copy local, 1 get_user() function
* @regno: boolean, 0 copy local, 1 get_user() function
...
@@ -972,7 +933,6 @@ static void ffb_init_one(int node, int parent)
...
@@ -972,7 +933,6 @@ static void ffb_init_one(int node, int parent)
return
;
return
;
}
}
ffb_set_par
(
&
all
->
info
);
ffb_init_fix
(
&
all
->
info
);
ffb_init_fix
(
&
all
->
info
);
if
(
register_framebuffer
(
&
all
->
info
)
<
0
)
{
if
(
register_framebuffer
(
&
all
->
info
)
<
0
)
{
...
...
drivers/video/p9100.c
View file @
8fe573f2
...
@@ -27,8 +27,6 @@
...
@@ -27,8 +27,6 @@
* Local functions.
* Local functions.
*/
*/
static
int
p9100_check_var
(
struct
fb_var_screeninfo
*
,
struct
fb_info
*
);
static
int
p9100_set_par
(
struct
fb_info
*
);
static
int
p9100_setcolreg
(
unsigned
,
unsigned
,
unsigned
,
unsigned
,
static
int
p9100_setcolreg
(
unsigned
,
unsigned
,
unsigned
,
unsigned
,
unsigned
,
struct
fb_info
*
);
unsigned
,
struct
fb_info
*
);
static
int
p9100_blank
(
int
,
struct
fb_info
*
);
static
int
p9100_blank
(
int
,
struct
fb_info
*
);
...
@@ -41,8 +39,6 @@ static int p9100_mmap(struct fb_info *, struct file *, struct vm_area_struct *);
...
@@ -41,8 +39,6 @@ static int p9100_mmap(struct fb_info *, struct file *, struct vm_area_struct *);
static
struct
fb_ops
p9100_ops
=
{
static
struct
fb_ops
p9100_ops
=
{
.
owner
=
THIS_MODULE
,
.
owner
=
THIS_MODULE
,
.
fb_check_var
=
p9100_check_var
,
.
fb_set_par
=
p9100_set_par
,
.
fb_setcolreg
=
p9100_setcolreg
,
.
fb_setcolreg
=
p9100_setcolreg
,
.
fb_blank
=
p9100_blank
,
.
fb_blank
=
p9100_blank
,
.
fb_fillrect
=
cfb_fillrect
,
.
fb_fillrect
=
cfb_fillrect
,
...
@@ -142,39 +138,6 @@ struct p9100_par {
...
@@ -142,39 +138,6 @@ struct p9100_par {
struct
list_head
list
;
struct
list_head
list
;
};
};
/**
* p9100_check_var - Optional function. Validates a var passed in.
* @var: frame buffer variable screen structure
* @info: frame buffer structure that represents a single frame buffer
*/
static
int
p9100_check_var
(
struct
fb_var_screeninfo
*
var
,
struct
fb_info
*
info
)
{
if
(
var
->
bits_per_pixel
!=
8
)
return
-
EINVAL
;
if
(
var
->
xres_virtual
!=
var
->
xres
||
var
->
yres_virtual
!=
var
->
yres
)
return
-
EINVAL
;
if
(
var
->
nonstd
)
return
-
EINVAL
;
if
((
var
->
vmode
&
FB_VMODE_MASK
)
!=
FB_VMODE_NONINTERLACED
)
return
-
EINVAL
;
if
(
var
->
xres
!=
info
->
var
.
xres
||
var
->
yres
!=
info
->
var
.
yres
)
return
-
EINVAL
;
return
0
;
}
/**
* p9100_set_par - Optional function. Alters the hardware state.
* @info: frame buffer structure that represents a single frame buffer
*/
static
int
p9100_set_par
(
struct
fb_info
*
info
)
{
return
0
;
}
/**
/**
* p9100_setcolreg - Optional function. Sets a color register.
* p9100_setcolreg - Optional function. Sets a color register.
* @regno: boolean, 0 copy local, 1 get_user() function
* @regno: boolean, 0 copy local, 1 get_user() function
...
@@ -344,7 +307,6 @@ static void p9100_init_one(struct sbus_dev *sdev)
...
@@ -344,7 +307,6 @@ static void p9100_init_one(struct sbus_dev *sdev)
return
;
return
;
}
}
p9100_set_par
(
&
all
->
info
);
p9100_init_fix
(
&
all
->
info
,
linebytes
);
p9100_init_fix
(
&
all
->
info
,
linebytes
);
if
(
register_framebuffer
(
&
all
->
info
)
<
0
)
{
if
(
register_framebuffer
(
&
all
->
info
)
<
0
)
{
...
...
drivers/video/tcx.c
View file @
8fe573f2
...
@@ -29,8 +29,6 @@
...
@@ -29,8 +29,6 @@
* Local functions.
* Local functions.
*/
*/
static
int
tcx_check_var
(
struct
fb_var_screeninfo
*
,
struct
fb_info
*
);
static
int
tcx_set_par
(
struct
fb_info
*
);
static
int
tcx_setcolreg
(
unsigned
,
unsigned
,
unsigned
,
unsigned
,
static
int
tcx_setcolreg
(
unsigned
,
unsigned
,
unsigned
,
unsigned
,
unsigned
,
struct
fb_info
*
);
unsigned
,
struct
fb_info
*
);
static
int
tcx_blank
(
int
,
struct
fb_info
*
);
static
int
tcx_blank
(
int
,
struct
fb_info
*
);
...
@@ -43,8 +41,6 @@ static int tcx_mmap(struct fb_info *, struct file *, struct vm_area_struct *);
...
@@ -43,8 +41,6 @@ static int tcx_mmap(struct fb_info *, struct file *, struct vm_area_struct *);
static
struct
fb_ops
tcx_ops
=
{
static
struct
fb_ops
tcx_ops
=
{
.
owner
=
THIS_MODULE
,
.
owner
=
THIS_MODULE
,
.
fb_check_var
=
tcx_check_var
,
.
fb_set_par
=
tcx_set_par
,
.
fb_setcolreg
=
tcx_setcolreg
,
.
fb_setcolreg
=
tcx_setcolreg
,
.
fb_blank
=
tcx_blank
,
.
fb_blank
=
tcx_blank
,
.
fb_fillrect
=
cfb_fillrect
,
.
fb_fillrect
=
cfb_fillrect
,
...
@@ -154,39 +150,6 @@ static void tcx_reset (struct fb_info *info)
...
@@ -154,39 +150,6 @@ static void tcx_reset (struct fb_info *info)
spin_unlock_irqrestore
(
&
par
->
lock
,
flags
);
spin_unlock_irqrestore
(
&
par
->
lock
,
flags
);
}
}
/**
* tcx_check_var - Optional function. Validates a var passed in.
* @var: frame buffer variable screen structure
* @info: frame buffer structure that represents a single frame buffer
*/
static
int
tcx_check_var
(
struct
fb_var_screeninfo
*
var
,
struct
fb_info
*
info
)
{
if
(
var
->
bits_per_pixel
!=
8
)
return
-
EINVAL
;
if
(
var
->
xres_virtual
!=
var
->
xres
||
var
->
yres_virtual
!=
var
->
yres
)
return
-
EINVAL
;
if
(
var
->
nonstd
)
return
-
EINVAL
;
if
((
var
->
vmode
&
FB_VMODE_MASK
)
!=
FB_VMODE_NONINTERLACED
)
return
-
EINVAL
;
if
(
var
->
xres
!=
info
->
var
.
xres
||
var
->
yres
!=
info
->
var
.
yres
)
return
-
EINVAL
;
return
0
;
}
/**
* tcx_set_par - Optional function. Alters the hardware state.
* @info: frame buffer structure that represents a single frame buffer
*/
static
int
tcx_set_par
(
struct
fb_info
*
info
)
{
return
0
;
}
/**
/**
* tcx_setcolreg - Optional function. Sets a color register.
* tcx_setcolreg - Optional function. Sets a color register.
* @regno: boolean, 0 copy local, 1 get_user() function
* @regno: boolean, 0 copy local, 1 get_user() function
...
@@ -431,7 +394,6 @@ static void tcx_init_one(struct sbus_dev *sdev)
...
@@ -431,7 +394,6 @@ static void tcx_init_one(struct sbus_dev *sdev)
return
;
return
;
}
}
tcx_set_par
(
&
all
->
info
);
tcx_init_fix
(
&
all
->
info
,
linebytes
);
tcx_init_fix
(
&
all
->
info
,
linebytes
);
if
(
register_framebuffer
(
&
all
->
info
)
<
0
)
{
if
(
register_framebuffer
(
&
all
->
info
)
<
0
)
{
...
...
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