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
20400563
Commit
20400563
authored
Mar 03, 2003
by
David S. Miller
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[SBUSFB]: Fix up ioctl helper changes.
parent
c69d3a9c
Changes
9
Show whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
19 additions
and
14 deletions
+19
-14
drivers/video/bw2.c
drivers/video/bw2.c
+1
-1
drivers/video/cg14.c
drivers/video/cg14.c
+1
-1
drivers/video/cg3.c
drivers/video/cg3.c
+1
-1
drivers/video/cg6.c
drivers/video/cg6.c
+1
-1
drivers/video/ffb.c
drivers/video/ffb.c
+1
-1
drivers/video/p9100.c
drivers/video/p9100.c
+1
-1
drivers/video/sbuslib.c
drivers/video/sbuslib.c
+10
-6
drivers/video/sbuslib.h
drivers/video/sbuslib.h
+2
-1
drivers/video/tcx.c
drivers/video/tcx.c
+1
-1
No files found.
drivers/video/bw2.c
View file @
20400563
...
@@ -183,7 +183,7 @@ static int bw2_ioctl(struct inode *inode, struct file *file, unsigned int cmd,
...
@@ -183,7 +183,7 @@ static int bw2_ioctl(struct inode *inode, struct file *file, unsigned int cmd,
{
{
struct
bw2_par
*
par
=
(
struct
bw2_par
*
)
info
->
par
;
struct
bw2_par
*
par
=
(
struct
bw2_par
*
)
info
->
par
;
return
sbusfb_ioctl_helper
(
cmd
,
info
,
return
sbusfb_ioctl_helper
(
cmd
,
arg
,
info
,
FBTYPE_SUN2BW
,
1
,
par
->
fbsize
);
FBTYPE_SUN2BW
,
1
,
par
->
fbsize
);
}
}
...
...
drivers/video/cg14.c
View file @
20400563
...
@@ -321,7 +321,7 @@ static int cg14_ioctl(struct inode *inode, struct file *file, unsigned int cmd,
...
@@ -321,7 +321,7 @@ static int cg14_ioctl(struct inode *inode, struct file *file, unsigned int cmd,
break
;
break
;
default:
default:
ret
=
sbusfb_ioctl_helper
(
cmd
,
info
,
ret
=
sbusfb_ioctl_helper
(
cmd
,
arg
,
info
,
FBTYPE_MDICOLOR
,
24
,
par
->
fbsize
);
FBTYPE_MDICOLOR
,
24
,
par
->
fbsize
);
break
;
break
;
};
};
...
...
drivers/video/cg3.c
View file @
20400563
...
@@ -240,7 +240,7 @@ static int cg3_ioctl(struct inode *inode, struct file *file, unsigned int cmd,
...
@@ -240,7 +240,7 @@ static int cg3_ioctl(struct inode *inode, struct file *file, unsigned int cmd,
{
{
struct
cg3_par
*
par
=
(
struct
cg3_par
*
)
info
->
par
;
struct
cg3_par
*
par
=
(
struct
cg3_par
*
)
info
->
par
;
return
sbusfb_ioctl_helper
(
cmd
,
info
,
return
sbusfb_ioctl_helper
(
cmd
,
arg
,
info
,
FBTYPE_SUN3COLOR
,
8
,
par
->
fbsize
);
FBTYPE_SUN3COLOR
,
8
,
par
->
fbsize
);
}
}
...
...
drivers/video/cg6.c
View file @
20400563
...
@@ -506,7 +506,7 @@ static int cg6_ioctl(struct inode *inode, struct file *file, unsigned int cmd,
...
@@ -506,7 +506,7 @@ static int cg6_ioctl(struct inode *inode, struct file *file, unsigned int cmd,
{
{
struct
cg6_par
*
par
=
(
struct
cg6_par
*
)
info
->
par
;
struct
cg6_par
*
par
=
(
struct
cg6_par
*
)
info
->
par
;
return
sbusfb_ioctl_helper
(
cmd
,
info
,
return
sbusfb_ioctl_helper
(
cmd
,
arg
,
info
,
FBTYPE_SUNFAST_COLOR
,
8
,
par
->
fbsize
);
FBTYPE_SUNFAST_COLOR
,
8
,
par
->
fbsize
);
}
}
...
...
drivers/video/ffb.c
View file @
20400563
...
@@ -788,7 +788,7 @@ static int ffb_ioctl(struct inode *inode, struct file *file, unsigned int cmd,
...
@@ -788,7 +788,7 @@ static int ffb_ioctl(struct inode *inode, struct file *file, unsigned int cmd,
{
{
struct
ffb_par
*
par
=
(
struct
ffb_par
*
)
info
->
par
;
struct
ffb_par
*
par
=
(
struct
ffb_par
*
)
info
->
par
;
return
sbusfb_ioctl_helper
(
cmd
,
info
,
return
sbusfb_ioctl_helper
(
cmd
,
arg
,
info
,
FBTYPE_CREATOR
,
24
,
par
->
fbsize
);
FBTYPE_CREATOR
,
24
,
par
->
fbsize
);
}
}
...
...
drivers/video/p9100.c
View file @
20400563
...
@@ -237,7 +237,7 @@ static int p9100_ioctl(struct inode *inode, struct file *file, unsigned int cmd,
...
@@ -237,7 +237,7 @@ static int p9100_ioctl(struct inode *inode, struct file *file, unsigned int cmd,
struct
p9100_par
*
par
=
(
struct
p9100_par
*
)
info
->
par
;
struct
p9100_par
*
par
=
(
struct
p9100_par
*
)
info
->
par
;
/* Make it look like a cg3. */
/* Make it look like a cg3. */
return
sbusfb_ioctl_helper
(
cmd
,
info
,
return
sbusfb_ioctl_helper
(
cmd
,
arg
,
info
,
FBTYPE_SUN3COLOR
,
8
,
par
->
fbsize
);
FBTYPE_SUN3COLOR
,
8
,
par
->
fbsize
);
}
}
...
...
drivers/video/sbuslib.c
View file @
20400563
...
@@ -9,6 +9,7 @@
...
@@ -9,6 +9,7 @@
#include <linux/fb.h>
#include <linux/fb.h>
#include <asm/oplib.h>
#include <asm/oplib.h>
#include <asm/fbio.h>
#include "sbuslib.h"
#include "sbuslib.h"
...
@@ -85,7 +86,8 @@ int sbusfb_mmap_helper(struct sbus_mmap_map *map,
...
@@ -85,7 +86,8 @@ int sbusfb_mmap_helper(struct sbus_mmap_map *map,
}
}
EXPORT_SYMBOL
(
sbusfb_mmap_helper
);
EXPORT_SYMBOL
(
sbusfb_mmap_helper
);
int
sbusfb_ioctl_helper
(
unsigned
long
cmd
,
struct
fb_info
*
info
,
int
sbusfb_ioctl_helper
(
unsigned
long
cmd
,
unsigned
long
arg
,
struct
fb_info
*
info
,
int
type
,
int
fb_depth
,
unsigned
long
fb_size
)
int
type
,
int
fb_depth
,
unsigned
long
fb_size
)
{
{
switch
(
cmd
)
{
switch
(
cmd
)
{
...
@@ -106,7 +108,7 @@ int sbusfb_ioctl_helper(unsigned long cmd, struct fb_info *info,
...
@@ -106,7 +108,7 @@ int sbusfb_ioctl_helper(unsigned long cmd, struct fb_info *info,
struct
fb_cmap
cmap
;
struct
fb_cmap
cmap
;
u16
red
,
green
,
blue
;
u16
red
,
green
,
blue
;
unsigned
char
*
ured
,
*
ugreen
,
*
ublue
;
unsigned
char
*
ured
,
*
ugreen
,
*
ublue
;
int
index
,
count
,
i
,
err
;
int
index
,
count
,
i
;
if
(
get_user
(
index
,
&
c
->
index
)
||
if
(
get_user
(
index
,
&
c
->
index
)
||
__get_user
(
count
,
&
c
->
count
)
||
__get_user
(
count
,
&
c
->
count
)
||
...
@@ -120,6 +122,8 @@ int sbusfb_ioctl_helper(unsigned long cmd, struct fb_info *info,
...
@@ -120,6 +122,8 @@ int sbusfb_ioctl_helper(unsigned long cmd, struct fb_info *info,
cmap
.
green
=
&
green
;
cmap
.
green
=
&
green
;
cmap
.
blue
=
&
blue
;
cmap
.
blue
=
&
blue
;
for
(
i
=
0
;
i
<
count
;
i
++
)
{
for
(
i
=
0
;
i
<
count
;
i
++
)
{
int
err
;
if
(
get_user
(
red
,
&
ured
[
i
])
||
if
(
get_user
(
red
,
&
ured
[
i
])
||
get_user
(
green
,
&
ugreen
[
i
])
||
get_user
(
green
,
&
ugreen
[
i
])
||
get_user
(
blue
,
&
ublue
[
i
]))
get_user
(
blue
,
&
ublue
[
i
]))
...
@@ -128,15 +132,15 @@ int sbusfb_ioctl_helper(unsigned long cmd, struct fb_info *info,
...
@@ -128,15 +132,15 @@ int sbusfb_ioctl_helper(unsigned long cmd, struct fb_info *info,
cmap
.
start
=
index
+
i
;
cmap
.
start
=
index
+
i
;
err
=
fb_set_cmap
(
&
cmap
,
0
,
info
);
err
=
fb_set_cmap
(
&
cmap
,
0
,
info
);
if
(
err
)
if
(
err
)
break
;
}
return
err
;
return
err
;
}
}
return
0
;
}
case
FBIOGETCMAP_SPARC
:
{
case
FBIOGETCMAP_SPARC
:
{
struct
fbcmap
*
c
=
(
struct
fbcmap
*
)
arg
;
struct
fbcmap
*
c
=
(
struct
fbcmap
*
)
arg
;
unsigned
char
*
ured
,
*
ugreen
,
*
ublue
;
unsigned
char
*
ured
,
*
ugreen
,
*
ublue
;
struct
fb_cmap
*
cmap
=
&
info
->
cmap
;
struct
fb_cmap
*
cmap
=
&
info
->
cmap
;
int
index
,
count
,
i
,
err
;
int
index
,
count
,
i
;
if
(
get_user
(
index
,
&
c
->
index
)
||
if
(
get_user
(
index
,
&
c
->
index
)
||
__get_user
(
count
,
&
c
->
count
)
||
__get_user
(
count
,
&
c
->
count
)
||
...
@@ -154,7 +158,7 @@ int sbusfb_ioctl_helper(unsigned long cmd, struct fb_info *info,
...
@@ -154,7 +158,7 @@ int sbusfb_ioctl_helper(unsigned long cmd, struct fb_info *info,
put_user
(
cmap
->
blue
[
index
+
i
],
&
ublue
[
i
]))
put_user
(
cmap
->
blue
[
index
+
i
],
&
ublue
[
i
]))
return
-
EFAULT
;
return
-
EFAULT
;
}
}
return
err
;
return
0
;
}
}
default:
default:
return
-
EINVAL
;
return
-
EINVAL
;
...
...
drivers/video/sbuslib.h
View file @
20400563
...
@@ -17,7 +17,8 @@ extern int sbusfb_mmap_helper(struct sbus_mmap_map *map,
...
@@ -17,7 +17,8 @@ extern int sbusfb_mmap_helper(struct sbus_mmap_map *map,
unsigned
long
physbase
,
unsigned
long
fbsize
,
unsigned
long
physbase
,
unsigned
long
fbsize
,
unsigned
long
iospace
,
unsigned
long
iospace
,
struct
vm_area_struct
*
vma
);
struct
vm_area_struct
*
vma
);
int
sbusfb_ioctl_helper
(
unsigned
long
cmd
,
struct
fb_info
*
info
,
int
sbusfb_ioctl_helper
(
unsigned
long
cmd
,
unsigned
long
arg
,
struct
fb_info
*
info
,
int
type
,
int
fb_depth
,
unsigned
long
fb_size
);
int
type
,
int
fb_depth
,
unsigned
long
fb_size
);
#endif
/* _SBUSLIB_H */
#endif
/* _SBUSLIB_H */
drivers/video/tcx.c
View file @
20400563
...
@@ -269,7 +269,7 @@ static int tcx_ioctl(struct inode *inode, struct file *file, unsigned int cmd,
...
@@ -269,7 +269,7 @@ static int tcx_ioctl(struct inode *inode, struct file *file, unsigned int cmd,
{
{
struct
tcx_par
*
par
=
(
struct
tcx_par
*
)
info
->
par
;
struct
tcx_par
*
par
=
(
struct
tcx_par
*
)
info
->
par
;
return
sbusfb_ioctl_helper
(
cmd
,
info
,
return
sbusfb_ioctl_helper
(
cmd
,
arg
,
info
,
FBTYPE_TCXCOLOR
,
FBTYPE_TCXCOLOR
,
(
par
->
lowdepth
?
8
:
24
),
(
par
->
lowdepth
?
8
:
24
),
par
->
fbsize
);
par
->
fbsize
);
...
...
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