Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F109342342
D42872.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
11 KB
Referenced Files
None
Subscribers
None
D42872.diff
View Options
diff --git a/lib/libc/aarch64/sys/Makefile.inc b/lib/libc/aarch64/sys/Makefile.inc
--- a/lib/libc/aarch64/sys/Makefile.inc
+++ b/lib/libc/aarch64/sys/Makefile.inc
@@ -8,5 +8,4 @@
vfork.S
# Don't generate default code for these syscalls:
-NOASM+= sbrk.o \
- vfork.o
+NOASM+= vfork.o
diff --git a/lib/libc/amd64/sys/Makefile.inc b/lib/libc/amd64/sys/Makefile.inc
--- a/lib/libc/amd64/sys/Makefile.inc
+++ b/lib/libc/amd64/sys/Makefile.inc
@@ -7,4 +7,4 @@
MDASM= vfork.S cerror.S getcontext.S
# Don't generate default code for these syscalls:
-NOASM+= sbrk.o vfork.o
+NOASM+= vfork.o
diff --git a/lib/libc/arm/sys/Makefile.inc b/lib/libc/arm/sys/Makefile.inc
--- a/lib/libc/arm/sys/Makefile.inc
+++ b/lib/libc/arm/sys/Makefile.inc
@@ -4,4 +4,4 @@
MDASM= Ovfork.S cerror.S syscall.S
# Don't generate default code for these syscalls:
-NOASM+= sbrk.o vfork.o
+NOASM+= vfork.o
diff --git a/lib/libc/i386/sys/Makefile.inc b/lib/libc/i386/sys/Makefile.inc
--- a/lib/libc/i386/sys/Makefile.inc
+++ b/lib/libc/i386/sys/Makefile.inc
@@ -4,7 +4,7 @@
MDASM= Ovfork.S cerror.S getcontext.S syscall.S
-NOASM+= sbrk.o vfork.o
+NOASM+= vfork.o
MAN+= i386_get_ioperm.2 i386_get_ldt.2 i386_vm86.2
MAN+= i386_set_watch.3
diff --git a/lib/libc/riscv/sys/Makefile.inc b/lib/libc/riscv/sys/Makefile.inc
--- a/lib/libc/riscv/sys/Makefile.inc
+++ b/lib/libc/riscv/sys/Makefile.inc
@@ -6,4 +6,4 @@
vfork.S
# Don't generate default code for these syscalls:
-NOASM+= sbrk.o vfork.o
+NOASM+= vfork.o
diff --git a/lib/libc/sys/Makefile.inc b/lib/libc/sys/Makefile.inc
--- a/lib/libc/sys/Makefile.inc
+++ b/lib/libc/sys/Makefile.inc
@@ -17,7 +17,6 @@
#
NOASM= exit.o \
getlogin.o \
- sstk.o \
yield.o
PSEUDO= _exit.o \
_getlogin.o
diff --git a/sys/compat/freebsd32/freebsd32_syscall.h b/sys/compat/freebsd32/freebsd32_syscall.h
--- a/sys/compat/freebsd32/freebsd32_syscall.h
+++ b/sys/compat/freebsd32/freebsd32_syscall.h
@@ -73,8 +73,8 @@
#define FREEBSD32_SYS_vfork 66
/* 67 is obsolete vread */
/* 68 is obsolete vwrite */
-#define FREEBSD32_SYS_sbrk 69
-#define FREEBSD32_SYS_sstk 70
+ /* 69 is obsolete sbrk */
+ /* 70 is obsolete sstk */
/* 71 is old freebsd32_mmap */
#define FREEBSD32_SYS_freebsd11_vadvise 72
#define FREEBSD32_SYS_munmap 73
diff --git a/sys/compat/freebsd32/freebsd32_syscalls.c b/sys/compat/freebsd32/freebsd32_syscalls.c
--- a/sys/compat/freebsd32/freebsd32_syscalls.c
+++ b/sys/compat/freebsd32/freebsd32_syscalls.c
@@ -74,8 +74,8 @@
"vfork", /* 66 = vfork */
"obs_vread", /* 67 = obsolete vread */
"obs_vwrite", /* 68 = obsolete vwrite */
- "sbrk", /* 69 = sbrk */
- "sstk", /* 70 = sstk */
+ "obs_sbrk", /* 69 = obsolete sbrk */
+ "obs_sstk", /* 70 = obsolete sstk */
"compat.freebsd32_mmap", /* 71 = old freebsd32_mmap */
"compat11.vadvise", /* 72 = freebsd11 vadvise */
"munmap", /* 73 = munmap */
diff --git a/sys/compat/freebsd32/freebsd32_sysent.c b/sys/compat/freebsd32/freebsd32_sysent.c
--- a/sys/compat/freebsd32/freebsd32_sysent.c
+++ b/sys/compat/freebsd32/freebsd32_sysent.c
@@ -130,8 +130,8 @@
{ .sy_narg = 0, .sy_call = (sy_call_t *)sys_vfork, .sy_auevent = AUE_VFORK, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 66 = vfork */
{ .sy_narg = 0, .sy_call = (sy_call_t *)nosys, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_ABSENT }, /* 67 = obsolete vread */
{ .sy_narg = 0, .sy_call = (sy_call_t *)nosys, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_ABSENT }, /* 68 = obsolete vwrite */
- { .sy_narg = AS(sbrk_args), .sy_call = (sy_call_t *)sys_sbrk, .sy_auevent = AUE_SBRK, .sy_flags = SYF_CAPENABLED, .sy_thrcnt = SY_THR_STATIC }, /* 69 = sbrk */
- { .sy_narg = AS(sstk_args), .sy_call = (sy_call_t *)sys_sstk, .sy_auevent = AUE_SSTK, .sy_flags = SYF_CAPENABLED, .sy_thrcnt = SY_THR_STATIC }, /* 70 = sstk */
+ { .sy_narg = 0, .sy_call = (sy_call_t *)nosys, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_ABSENT }, /* 69 = obsolete sbrk */
+ { .sy_narg = 0, .sy_call = (sy_call_t *)nosys, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_ABSENT }, /* 70 = obsolete sstk */
{ compat(AS(ofreebsd32_mmap_args),freebsd32_mmap), .sy_auevent = AUE_MMAP, .sy_flags = SYF_CAPENABLED, .sy_thrcnt = SY_THR_STATIC }, /* 71 = old freebsd32_mmap */
{ compat11(AS(freebsd11_vadvise_args),vadvise), .sy_auevent = AUE_O_VADVISE, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 72 = freebsd11 vadvise */
{ .sy_narg = AS(munmap_args), .sy_call = (sy_call_t *)sys_munmap, .sy_auevent = AUE_MUNMAP, .sy_flags = SYF_CAPENABLED, .sy_thrcnt = SY_THR_STATIC }, /* 73 = munmap */
diff --git a/sys/compat/freebsd32/freebsd32_systrace_args.c b/sys/compat/freebsd32/freebsd32_systrace_args.c
--- a/sys/compat/freebsd32/freebsd32_systrace_args.c
+++ b/sys/compat/freebsd32/freebsd32_systrace_args.c
@@ -421,20 +421,6 @@
*n_args = 0;
break;
}
- /* sbrk */
- case 69: {
- struct sbrk_args *p = params;
- iarg[a++] = p->incr; /* int */
- *n_args = 1;
- break;
- }
- /* sstk */
- case 70: {
- struct sstk_args *p = params;
- iarg[a++] = p->incr; /* int */
- *n_args = 1;
- break;
- }
/* munmap */
case 73: {
struct munmap_args *p = params;
@@ -4009,26 +3995,6 @@
/* vfork */
case 66:
break;
- /* sbrk */
- case 69:
- switch (ndx) {
- case 0:
- p = "int";
- break;
- default:
- break;
- };
- break;
- /* sstk */
- case 70:
- switch (ndx) {
- case 0:
- p = "int";
- break;
- default:
- break;
- };
- break;
/* munmap */
case 73:
switch (ndx) {
@@ -9347,16 +9313,6 @@
break;
/* vfork */
case 66:
- /* sbrk */
- case 69:
- if (ndx == 0 || ndx == 1)
- p = "int";
- break;
- /* sstk */
- case 70:
- if (ndx == 0 || ndx == 1)
- p = "int";
- break;
/* munmap */
case 73:
if (ndx == 0 || ndx == 1)
diff --git a/sys/kern/init_sysent.c b/sys/kern/init_sysent.c
--- a/sys/kern/init_sysent.c
+++ b/sys/kern/init_sysent.c
@@ -129,8 +129,8 @@
{ .sy_narg = 0, .sy_call = (sy_call_t *)sys_vfork, .sy_auevent = AUE_VFORK, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 66 = vfork */
{ .sy_narg = 0, .sy_call = (sy_call_t *)nosys, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_ABSENT }, /* 67 = obsolete vread */
{ .sy_narg = 0, .sy_call = (sy_call_t *)nosys, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_ABSENT }, /* 68 = obsolete vwrite */
- { .sy_narg = AS(sbrk_args), .sy_call = (sy_call_t *)sys_sbrk, .sy_auevent = AUE_SBRK, .sy_flags = SYF_CAPENABLED, .sy_thrcnt = SY_THR_STATIC }, /* 69 = sbrk */
- { .sy_narg = AS(sstk_args), .sy_call = (sy_call_t *)sys_sstk, .sy_auevent = AUE_SSTK, .sy_flags = SYF_CAPENABLED, .sy_thrcnt = SY_THR_STATIC }, /* 70 = sstk */
+ { .sy_narg = 0, .sy_call = (sy_call_t *)nosys, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_ABSENT }, /* 69 = obsolete sbrk */
+ { .sy_narg = 0, .sy_call = (sy_call_t *)nosys, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_ABSENT }, /* 70 = obsolete sstk */
{ compat(AS(ommap_args),mmap), .sy_auevent = AUE_MMAP, .sy_flags = SYF_CAPENABLED, .sy_thrcnt = SY_THR_STATIC }, /* 71 = old mmap */
{ compat11(AS(freebsd11_vadvise_args),vadvise), .sy_auevent = AUE_O_VADVISE, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 72 = freebsd11 vadvise */
{ .sy_narg = AS(munmap_args), .sy_call = (sy_call_t *)sys_munmap, .sy_auevent = AUE_MUNMAP, .sy_flags = SYF_CAPENABLED, .sy_thrcnt = SY_THR_STATIC }, /* 73 = munmap */
diff --git a/sys/kern/syscalls.c b/sys/kern/syscalls.c
--- a/sys/kern/syscalls.c
+++ b/sys/kern/syscalls.c
@@ -74,8 +74,8 @@
"vfork", /* 66 = vfork */
"obs_vread", /* 67 = obsolete vread */
"obs_vwrite", /* 68 = obsolete vwrite */
- "sbrk", /* 69 = sbrk */
- "sstk", /* 70 = sstk */
+ "obs_sbrk", /* 69 = obsolete sbrk */
+ "obs_sstk", /* 70 = obsolete sstk */
"compat.mmap", /* 71 = old mmap */
"compat11.vadvise", /* 72 = freebsd11 vadvise */
"munmap", /* 73 = munmap */
diff --git a/sys/kern/syscalls.master b/sys/kern/syscalls.master
--- a/sys/kern/syscalls.master
+++ b/sys/kern/syscalls.master
@@ -502,16 +502,8 @@
}
67 AUE_NULL OBSOL vread
68 AUE_NULL OBSOL vwrite
-69 AUE_SBRK STD|CAPENABLED {
- int sbrk(
- int incr
- );
- }
-70 AUE_SSTK STD|CAPENABLED {
- int sstk(
- int incr
- );
- }
+69 AUE_NULL OBSOL sbrk
+70 AUE_NULL OBSOL sstk
71 AUE_MMAP COMPAT|CAPENABLED {
void *mmap(
_In_ void *addr,
diff --git a/sys/kern/systrace_args.c b/sys/kern/systrace_args.c
--- a/sys/kern/systrace_args.c
+++ b/sys/kern/systrace_args.c
@@ -418,20 +418,6 @@
*n_args = 0;
break;
}
- /* sbrk */
- case 69: {
- struct sbrk_args *p = params;
- iarg[a++] = p->incr; /* int */
- *n_args = 1;
- break;
- }
- /* sstk */
- case 70: {
- struct sstk_args *p = params;
- iarg[a++] = p->incr; /* int */
- *n_args = 1;
- break;
- }
/* munmap */
case 73: {
struct munmap_args *p = params;
@@ -4096,26 +4082,6 @@
/* vfork */
case 66:
break;
- /* sbrk */
- case 69:
- switch (ndx) {
- case 0:
- p = "int";
- break;
- default:
- break;
- };
- break;
- /* sstk */
- case 70:
- switch (ndx) {
- case 0:
- p = "int";
- break;
- default:
- break;
- };
- break;
/* munmap */
case 73:
switch (ndx) {
@@ -9492,16 +9458,6 @@
break;
/* vfork */
case 66:
- /* sbrk */
- case 69:
- if (ndx == 0 || ndx == 1)
- p = "int";
- break;
- /* sstk */
- case 70:
- if (ndx == 0 || ndx == 1)
- p = "int";
- break;
/* munmap */
case 73:
if (ndx == 0 || ndx == 1)
diff --git a/sys/sys/syscall.h b/sys/sys/syscall.h
--- a/sys/sys/syscall.h
+++ b/sys/sys/syscall.h
@@ -73,8 +73,8 @@
#define SYS_vfork 66
/* 67 is obsolete vread */
/* 68 is obsolete vwrite */
-#define SYS_sbrk 69
-#define SYS_sstk 70
+ /* 69 is obsolete sbrk */
+ /* 70 is obsolete sstk */
/* 71 is old mmap */
#define SYS_freebsd11_vadvise 72
#define SYS_munmap 73
diff --git a/sys/sys/syscall.mk b/sys/sys/syscall.mk
--- a/sys/sys/syscall.mk
+++ b/sys/sys/syscall.mk
@@ -56,8 +56,6 @@
chroot.o \
msync.o \
vfork.o \
- sbrk.o \
- sstk.o \
freebsd11_vadvise.o \
munmap.o \
mprotect.o \
diff --git a/sys/sys/sysproto.h b/sys/sys/sysproto.h
--- a/sys/sys/sysproto.h
+++ b/sys/sys/sysproto.h
@@ -254,12 +254,6 @@
struct vfork_args {
syscallarg_t dummy;
};
-struct sbrk_args {
- char incr_l_[PADL_(int)]; int incr; char incr_r_[PADR_(int)];
-};
-struct sstk_args {
- char incr_l_[PADL_(int)]; int incr; char incr_r_[PADR_(int)];
-};
struct munmap_args {
char addr_l_[PADL_(void *)]; void * addr; char addr_r_[PADR_(void *)];
char len_l_[PADL_(size_t)]; size_t len; char len_r_[PADR_(size_t)];
@@ -1928,8 +1922,6 @@
int sys_chroot(struct thread *, struct chroot_args *);
int sys_msync(struct thread *, struct msync_args *);
int sys_vfork(struct thread *, struct vfork_args *);
-int sys_sbrk(struct thread *, struct sbrk_args *);
-int sys_sstk(struct thread *, struct sstk_args *);
int sys_munmap(struct thread *, struct munmap_args *);
int sys_mprotect(struct thread *, struct mprotect_args *);
int sys_madvise(struct thread *, struct madvise_args *);
@@ -2838,8 +2830,6 @@
#define SYS_AUE_ogetpagesize AUE_NULL
#define SYS_AUE_msync AUE_MSYNC
#define SYS_AUE_vfork AUE_VFORK
-#define SYS_AUE_sbrk AUE_SBRK
-#define SYS_AUE_sstk AUE_SSTK
#define SYS_AUE_ommap AUE_MMAP
#define SYS_AUE_freebsd11_vadvise AUE_O_VADVISE
#define SYS_AUE_munmap AUE_MUNMAP
diff --git a/sys/vm/vm_mmap.c b/sys/vm/vm_mmap.c
--- a/sys/vm/vm_mmap.c
+++ b/sys/vm/vm_mmap.c
@@ -106,32 +106,6 @@
_Static_assert(MAXPAGESIZES <= 4, "MINCORE_SUPER too narrow");
-#ifndef _SYS_SYSPROTO_H_
-struct sbrk_args {
- int incr;
-};
-#endif
-
-int
-sys_sbrk(struct thread *td, struct sbrk_args *uap)
-{
- /* Not yet implemented */
- return (EOPNOTSUPP);
-}
-
-#ifndef _SYS_SYSPROTO_H_
-struct sstk_args {
- int incr;
-};
-#endif
-
-int
-sys_sstk(struct thread *td, struct sstk_args *uap)
-{
- /* Not yet implemented */
- return (EOPNOTSUPP);
-}
-
#if defined(COMPAT_43)
int
ogetpagesize(struct thread *td, struct ogetpagesize_args *uap)
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Tue, Feb 4, 7:52 PM (20 h, 55 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
16459817
Default Alt Text
D42872.diff (11 KB)
Attached To
Mode
D42872: Remove never implemented sbrk and sstk syscalls
Attached
Detach File
Event Timeline
Log In to Comment