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
037ed253
Commit
037ed253
authored
May 12, 2003
by
Linus Torvalds
Browse files
Options
Browse Files
Download
Plain Diff
Merge
bk://kernel.bkbits.net/davem/net-2.5
into home.transmeta.com:/home/torvalds/v2.5/linux
parents
f5bda5bc
9630291c
Changes
5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
19 additions
and
18 deletions
+19
-18
arch/i386/kernel/cpu/mtrr/if.c
arch/i386/kernel/cpu/mtrr/if.c
+15
-14
fs/open.c
fs/open.c
+1
-1
include/linux/fs.h
include/linux/fs.h
+1
-1
include/linux/time.h
include/linux/time.h
+1
-1
mm/page_alloc.c
mm/page_alloc.c
+1
-1
No files found.
arch/i386/kernel/cpu/mtrr/if.c
View file @
037ed253
...
...
@@ -70,7 +70,7 @@ mtrr_file_del(unsigned long base, unsigned long size,
/* RED-PEN: seq_file can seek now. this is ignored. */
static
ssize_t
mtrr_write
(
struct
file
*
file
,
const
char
*
buf
,
size_t
len
,
loff_t
*
ppos
)
mtrr_write
(
struct
file
*
file
,
const
char
__user
*
buf
,
size_t
len
,
loff_t
*
ppos
)
/* Format of control line:
"base=%Lx size=%Lx type=%s" OR:
"disable=%d"
...
...
@@ -133,12 +133,13 @@ mtrr_write(struct file *file, const char *buf, size_t len, loff_t * ppos)
static
int
mtrr_ioctl
(
struct
inode
*
inode
,
struct
file
*
file
,
unsigned
int
cmd
,
unsigned
long
arg
)
unsigned
int
cmd
,
unsigned
long
__
arg
)
{
int
err
;
mtrr_type
type
;
struct
mtrr_sentry
sentry
;
struct
mtrr_gentry
gentry
;
void
__user
*
arg
=
(
void
__user
*
)
__arg
;
switch
(
cmd
)
{
default:
...
...
@@ -146,7 +147,7 @@ mtrr_ioctl(struct inode *inode, struct file *file,
case
MTRRIOC_ADD_ENTRY
:
if
(
!
capable
(
CAP_SYS_ADMIN
))
return
-
EPERM
;
if
(
copy_from_user
(
&
sentry
,
(
void
*
)
arg
,
sizeof
sentry
))
if
(
copy_from_user
(
&
sentry
,
arg
,
sizeof
sentry
))
return
-
EFAULT
;
err
=
mtrr_file_add
(
sentry
.
base
,
sentry
.
size
,
sentry
.
type
,
1
,
...
...
@@ -157,7 +158,7 @@ mtrr_ioctl(struct inode *inode, struct file *file,
case
MTRRIOC_SET_ENTRY
:
if
(
!
capable
(
CAP_SYS_ADMIN
))
return
-
EPERM
;
if
(
copy_from_user
(
&
sentry
,
(
void
*
)
arg
,
sizeof
sentry
))
if
(
copy_from_user
(
&
sentry
,
arg
,
sizeof
sentry
))
return
-
EFAULT
;
err
=
mtrr_add
(
sentry
.
base
,
sentry
.
size
,
sentry
.
type
,
0
);
if
(
err
<
0
)
...
...
@@ -166,7 +167,7 @@ mtrr_ioctl(struct inode *inode, struct file *file,
case
MTRRIOC_DEL_ENTRY
:
if
(
!
capable
(
CAP_SYS_ADMIN
))
return
-
EPERM
;
if
(
copy_from_user
(
&
sentry
,
(
void
*
)
arg
,
sizeof
sentry
))
if
(
copy_from_user
(
&
sentry
,
arg
,
sizeof
sentry
))
return
-
EFAULT
;
err
=
mtrr_file_del
(
sentry
.
base
,
sentry
.
size
,
file
,
0
);
if
(
err
<
0
)
...
...
@@ -175,14 +176,14 @@ mtrr_ioctl(struct inode *inode, struct file *file,
case
MTRRIOC_KILL_ENTRY
:
if
(
!
capable
(
CAP_SYS_ADMIN
))
return
-
EPERM
;
if
(
copy_from_user
(
&
sentry
,
(
void
*
)
arg
,
sizeof
sentry
))
if
(
copy_from_user
(
&
sentry
,
arg
,
sizeof
sentry
))
return
-
EFAULT
;
err
=
mtrr_del
(
-
1
,
sentry
.
base
,
sentry
.
size
);
if
(
err
<
0
)
return
err
;
break
;
case
MTRRIOC_GET_ENTRY
:
if
(
copy_from_user
(
&
gentry
,
(
void
*
)
arg
,
sizeof
gentry
))
if
(
copy_from_user
(
&
gentry
,
arg
,
sizeof
gentry
))
return
-
EFAULT
;
if
(
gentry
.
regnum
>=
num_var_ranges
)
return
-
EINVAL
;
...
...
@@ -198,13 +199,13 @@ mtrr_ioctl(struct inode *inode, struct file *file,
gentry
.
type
=
type
;
}
if
(
copy_to_user
(
(
void
*
)
arg
,
&
gentry
,
sizeof
gentry
))
if
(
copy_to_user
(
arg
,
&
gentry
,
sizeof
gentry
))
return
-
EFAULT
;
break
;
case
MTRRIOC_ADD_PAGE_ENTRY
:
if
(
!
capable
(
CAP_SYS_ADMIN
))
return
-
EPERM
;
if
(
copy_from_user
(
&
sentry
,
(
void
*
)
arg
,
sizeof
sentry
))
if
(
copy_from_user
(
&
sentry
,
arg
,
sizeof
sentry
))
return
-
EFAULT
;
err
=
mtrr_file_add
(
sentry
.
base
,
sentry
.
size
,
sentry
.
type
,
1
,
...
...
@@ -215,7 +216,7 @@ mtrr_ioctl(struct inode *inode, struct file *file,
case
MTRRIOC_SET_PAGE_ENTRY
:
if
(
!
capable
(
CAP_SYS_ADMIN
))
return
-
EPERM
;
if
(
copy_from_user
(
&
sentry
,
(
void
*
)
arg
,
sizeof
sentry
))
if
(
copy_from_user
(
&
sentry
,
arg
,
sizeof
sentry
))
return
-
EFAULT
;
err
=
mtrr_add_page
(
sentry
.
base
,
sentry
.
size
,
sentry
.
type
,
0
);
if
(
err
<
0
)
...
...
@@ -224,7 +225,7 @@ mtrr_ioctl(struct inode *inode, struct file *file,
case
MTRRIOC_DEL_PAGE_ENTRY
:
if
(
!
capable
(
CAP_SYS_ADMIN
))
return
-
EPERM
;
if
(
copy_from_user
(
&
sentry
,
(
void
*
)
arg
,
sizeof
sentry
))
if
(
copy_from_user
(
&
sentry
,
arg
,
sizeof
sentry
))
return
-
EFAULT
;
err
=
mtrr_file_del
(
sentry
.
base
,
sentry
.
size
,
file
,
1
);
if
(
err
<
0
)
...
...
@@ -233,21 +234,21 @@ mtrr_ioctl(struct inode *inode, struct file *file,
case
MTRRIOC_KILL_PAGE_ENTRY
:
if
(
!
capable
(
CAP_SYS_ADMIN
))
return
-
EPERM
;
if
(
copy_from_user
(
&
sentry
,
(
void
*
)
arg
,
sizeof
sentry
))
if
(
copy_from_user
(
&
sentry
,
arg
,
sizeof
sentry
))
return
-
EFAULT
;
err
=
mtrr_del_page
(
-
1
,
sentry
.
base
,
sentry
.
size
);
if
(
err
<
0
)
return
err
;
break
;
case
MTRRIOC_GET_PAGE_ENTRY
:
if
(
copy_from_user
(
&
gentry
,
(
void
*
)
arg
,
sizeof
gentry
))
if
(
copy_from_user
(
&
gentry
,
arg
,
sizeof
gentry
))
return
-
EFAULT
;
if
(
gentry
.
regnum
>=
num_var_ranges
)
return
-
EINVAL
;
mtrr_if
->
get
(
gentry
.
regnum
,
&
gentry
.
base
,
&
gentry
.
size
,
&
type
);
gentry
.
type
=
type
;
if
(
copy_to_user
(
(
void
*
)
arg
,
&
gentry
,
sizeof
gentry
))
if
(
copy_to_user
(
arg
,
&
gentry
,
sizeof
gentry
))
return
-
EFAULT
;
break
;
}
...
...
fs/open.c
View file @
037ed253
...
...
@@ -280,7 +280,7 @@ asmlinkage long sys_utime(char __user * filename, struct utimbuf __user * times)
* must be owner or have write permission.
* Else, update from *times, must be owner or super user.
*/
long
do_utimes
(
char
__user
*
filename
,
struct
timeval
__user
*
times
)
long
do_utimes
(
char
__user
*
filename
,
struct
timeval
*
times
)
{
int
error
;
struct
nameidata
nd
;
...
...
include/linux/fs.h
View file @
037ed253
...
...
@@ -1017,7 +1017,7 @@ static inline int break_lease(struct inode *inode, unsigned int mode)
/* fs/open.c */
asmlinkage
long
sys_open
(
const
char
*
,
int
,
int
);
asmlinkage
long
sys_open
(
const
char
__user
*
,
int
,
int
);
asmlinkage
long
sys_close
(
unsigned
int
);
/* yes, it's really unsigned */
extern
int
do_truncate
(
struct
dentry
*
,
loff_t
start
);
...
...
include/linux/time.h
View file @
037ed253
...
...
@@ -204,7 +204,7 @@ extern void do_settimeofday(struct timeval *tv);
extern
int
do_sys_settimeofday
(
struct
timeval
*
tv
,
struct
timezone
*
tz
);
extern
void
clock_was_set
(
void
);
// call when ever the clock is set
extern
long
do_nanosleep
(
struct
timespec
*
t
);
extern
long
do_utimes
(
char
*
filename
,
struct
timeval
*
times
);
extern
long
do_utimes
(
char
__user
*
filename
,
struct
timeval
*
times
);
#endif
#define FD_SETSIZE __FD_SETSIZE
...
...
mm/page_alloc.c
View file @
037ed253
...
...
@@ -792,7 +792,7 @@ unsigned int nr_free_pagecache_pages(void)
return
nr_free_zone_pages
(
GFP_HIGHUSER
&
GFP_ZONEMASK
);
}
#if CONFIG_HIGHMEM
#if
def
CONFIG_HIGHMEM
unsigned
int
nr_free_highpages
(
void
)
{
pg_data_t
*
pgdat
;
...
...
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