History log of /freebsd/sys/kern/sysv_shm.c (Results 301 – 325 of 397)
Revision (<<< Hide revision tags) (Show revision tags >>>) Date Author Comments
# 921d05b9 12-Nov-2004 Robert Watson <rwatson@FreeBSD.org>

Second of several commits to allow kernel System V IPC data structures
to be modified and extended without breaking the user space ABI:

Use _kernel variants on _ds structures for System V sempahores

Second of several commits to allow kernel System V IPC data structures
to be modified and extended without breaking the user space ABI:

Use _kernel variants on _ds structures for System V sempahores, message
queues, and shared memory. When interfacing with userspace, export
only the _ds subsets of the _kernel data structures. A lot of search
and replace.

Define the message structure in the _KERNEL portion of msg.h so that it
can be used by other kernel consumers, but not exposed to user space.

Submitted by: Dandekar Hrishikesh <rishi_dandekar at sbcglobal dot net>
Obtained from: TrustedBSD Project
Sponsored by: DARPA, SPAWAR, McAfee Research

show more ...


Revision tags: release/5.3.0_cvs, release/5.3.0
# 94ddc707 03-Sep-2004 Alan Cox <alc@FreeBSD.org>

Push Giant deep into vm_forkproc(), acquiring it only if the process has
mapped System V shared memory segments (see shmfork_myhook()) or requires
the allocation of an ldt (see vm_fault_wire()).


# 00fbcda8 28-Jul-2004 Alexander Kabaev <kan@FreeBSD.org>

Avoid casts as lvalues.


# 1a276a3f 27-Jul-2004 Alan Cox <alc@FreeBSD.org>

- Use atomic ops for updating the vmspace's refcnt and exitingcnt.
- Push down Giant into shmexit(). (Giant is acquired only if the vmspace
contains shm segments.)
- Eliminate the acquisition o

- Use atomic ops for updating the vmspace's refcnt and exitingcnt.
- Push down Giant into shmexit(). (Giant is acquired only if the vmspace
contains shm segments.)
- Eliminate the acquisition of Giant from proc_rwmem().
- Reduce the scope of Giant in exit1(), uncovering the destruction of the
address space.

show more ...


# 0049f8b2 09-Jul-2004 Alan Cox <alc@FreeBSD.org>

Eliminate struct shm_handle. It is an unnecessary level of indirection to
a vm_object.


# 68ba7a1d 19-Jun-2004 Tim J. Robbins <tjr@FreeBSD.org>

When no fixed address is given in a shmat() request, pass a hint address
to vm_map_find() that is less likely to be outside of addressable memory
for 32-bit processes: just past the end of the larges

When no fixed address is given in a shmat() request, pass a hint address
to vm_map_find() that is less likely to be outside of addressable memory
for 32-bit processes: just past the end of the largest possible heap.
This is the same hint that mmap() uses.

show more ...


# 77409fe1 30-May-2004 Poul-Henning Kamp <phk@FreeBSD.org>

Add missing #include <sys/module.h>


Revision tags: release/4.10.0_cvs, release/4.10.0, release/5.2.1_cvs, release/5.2.1
# b00a3c85 05-Feb-2004 Jacques Vidrine <nectar@FreeBSD.org>

Correct a reference counting bug in shmat(2). If vm_map_find(9)
failed, the reference count for the virtual memory object referenced
by the specified shared memory segment would have been erroneousl

Correct a reference counting bug in shmat(2). If vm_map_find(9)
failed, the reference count for the virtual memory object referenced
by the specified shared memory segment would have been erroneously
incremented.

Reported by: Joost Pol <joost@pine.nl>

show more ...


Revision tags: release/5.2.0_cvs, release/5.2.0
# a2f88a8b 07-Nov-2003 Robert Watson <rwatson@FreeBSD.org>

Slight whitespace consistency improvement:
Trim trailing whitespace.
Remove unmatched " " before ")".


# 2332251c 05-Nov-2003 Max Khon <fjoe@FreeBSD.org>

Back out the following revisions:

1.36 +73 -60 src/sys/compat/linux/linux_ipc.c
1.83 +102 -48 src/sys/kern/sysv_shm.c
1.8 +4 -0 src/sys/sys/syscallsubr.h

That change was i

Back out the following revisions:

1.36 +73 -60 src/sys/compat/linux/linux_ipc.c
1.83 +102 -48 src/sys/kern/sysv_shm.c
1.8 +4 -0 src/sys/sys/syscallsubr.h

That change was intended to support vmware3, but
wantrem parameter is useless because vmware3 uses SYSV shared memory
to talk with X server and X server is native application.
The patch worked because check for wantrem was not valid
(wantrem and SHMSEG_REMOVED was never checked for SHMSEG_ALLOCATED segments).

Add kern.ipc.shm_allow_removed (integer, rw) sysctl (default 0) which when set
to 1 allows to return removed segments in
shm_find_segment_by_shmid() and shm_find_segment_by_shmidx().

MFC after: 1 week

show more ...


Revision tags: release/4.9.0_cvs, release/4.9.0
# 184dcdc7 21-Oct-2003 Mike Silbersack <silby@FreeBSD.org>

Change all SYSCTLS which are readonly and have a related TUNABLE
from CTLFLAG_RD to CTLFLAG_RDTUN so that sysctl(8) can provide
more useful error messages.


# 01b9dc96 07-Aug-2003 Jacques Vidrine <nectar@FreeBSD.org>

Update some argument-documenting comments to match reality.

Add an explicit range check to those same arguments to reduce risk of
cardiac arrest in future code readers.


# 8b149b51 07-Aug-2003 John Baldwin <jhb@FreeBSD.org>

Consistently use the BSD u_int and u_short instead of the SYSV uint and
ushort. In most of these files, there was a mixture of both styles and
this change just makes them self-consistent.

Requested

Consistently use the BSD u_int and u_short instead of the SYSV uint and
ushort. In most of these files, there was a mixture of both styles and
this change just makes them self-consistent.

Requested by: bde (kern_ktrace.c)

show more ...


# 677b542e 11-Jun-2003 David E. O'Brien <obrien@FreeBSD.org>

Use __FBSDID().


Revision tags: release/5.1.0_cvs, release/5.1.0
# f130dcf2 05-May-2003 Martin Blapp <mbr@FreeBSD.org>

Change the semantics of sysv shm emulation to take a additional
argument to the functions shm{at,ctl}1 and shm_find_segment_by_shmid{x}.
The BSD semantics didn't allow the usage of shared segment aft

Change the semantics of sysv shm emulation to take a additional
argument to the functions shm{at,ctl}1 and shm_find_segment_by_shmid{x}.
The BSD semantics didn't allow the usage of shared segment after
being marked for removal through IPC_RMID.

The patch involves the following functions:
- shmat
- shmctl
- shm_find_segment_by_shmid
- shm_find_segment_by_shmidx
- linux_shmat
- linux_shmctl

Submitted by: Orlando Bassotto <orlando.bassotto@ieo-research.it>
Reviewed by: marcel

show more ...


# b077a362 13-Apr-2003 Alan Cox <alc@FreeBSD.org>

Lock some manipulations of the vm object's flags.


Revision tags: release/4.8.0_cvs, release/4.8.0
# a163d034 19-Feb-2003 Warner Losh <imp@FreeBSD.org>

Back out M_* changes, per decision of the TRB.

Approved by: trb


# 9d4156ae 16-Feb-2003 Alfred Perlstein <alfred@FreeBSD.org>

Fix logic in loop so it actually executes.

Pointed out by: fjoe


# 5015c68a 16-Feb-2003 Alfred Perlstein <alfred@FreeBSD.org>

prevent overflow in shminfo.shmmax


# e1d7d0bb 25-Jan-2003 Alfred Perlstein <alfred@FreeBSD.org>

Bring shm functions closer the the opengroup standards.

PR: 47469
Submitted by: Craig Rodrigues <rodrigc@attbi.com>


# 44956c98 21-Jan-2003 Alfred Perlstein <alfred@FreeBSD.org>

Remove M_TRYWAIT/M_WAITOK/M_WAIT. Callers should use 0.
Merge M_NOWAIT/M_DONTWAIT into a single flag M_NOWAIT.


Revision tags: release/5.0.0_cvs, release/5.0.0
# 3db161e0 14-Jan-2003 Matthew Dillon <dillon@FreeBSD.org>

It is possible for an active aio to prevent shared memory from being
dereferenced when a process exits due to the vmspace ref-count being
bumped. Change shmexit() and shmexit_myhook() to take a vmsp

It is possible for an active aio to prevent shared memory from being
dereferenced when a process exits due to the vmspace ref-count being
bumped. Change shmexit() and shmexit_myhook() to take a vmspace instead
of a process and call it in vmspace_dofree(). This way if it is missed
in exit1()'s early-resource-free it will still be caught when the zombie is
reaped.

Also fix a potential race in shmexit_myhook() by NULLing out
vmspace->vm_shm prior to calling shm_delete_mapping() and free().

MFC after: 7 days

show more ...


# 49bf855d 02-Jan-2003 Alan Cox <alc@FreeBSD.org>

Lock the vm object when performing back-to-back vm_object_clear_flag() and
vm_object_set_flag().


Revision tags: release/4.7.0_cvs
# b618bb96 15-Aug-2002 Alfred Perlstein <alfred@FreeBSD.org>

return foo -> return (foo)


Revision tags: release/4.6.2_cvs, release/4.6.2
# 8209f090 22-Jul-2002 Alfred Perlstein <alfred@FreeBSD.org>

Change struct vmspace->vm_shm from void * to struct shmmap_state *, this
removes the need for casts in several cases.


1...<<111213141516