History log of /freebsd/sys/compat/linprocfs/linprocfs.c (Results 26 – 50 of 517)
Revision (<<< Hide revision tags) (Show revision tags >>>) Date Author Comments
# ef1976cc 22-Jun-2022 Dmitry Chagin <dchagin@FreeBSD.org>

linprocfs: Skip printing of the guard page in the /proc/self/maps

To calculate the base (lowest addressable) address of the stack of the
initial thread glibc parses /proc/self/maps.
In fact, the bas

linprocfs: Skip printing of the guard page in the /proc/self/maps

To calculate the base (lowest addressable) address of the stack of the
initial thread glibc parses /proc/self/maps.
In fact, the base address is calculated as 'to' value of stack entry of the
/proc/self/maps - stack size limit (if the stack grows down).
The base address should fit in between preceding entry and stack entry of
the /proc/self/maps.
In FreeBSD, since 19bd0d9 (Implement address space guards), we actually
have two mappings for the stack region. The first one is the no-access
mapping for the region the stack can grow into (guard page), and the
second - initial stack region with size sgrowsiz.
The first mapping confuses Glibc, in the end which is improperly
calculate stack size and the base address.

PR: 253337
Reviewed by: kib
Differential revision: https://reviews.freebsd.org/D35537
MFC after: 2 week

show more ...


# 7e2a4511 31-May-2022 Dmitry Chagin <dchagin@FreeBSD.org>

linprocfs: Add /proc/vm/max_map_count

On Linux this limits the number of maps per mm struct.
We don't limit mappings, return a suitable large value.

Reviewed by: emaste
Differential revision: http

linprocfs: Add /proc/vm/max_map_count

On Linux this limits the number of maps per mm struct.
We don't limit mappings, return a suitable large value.

Reviewed by: emaste
Differential revision: https://reviews.freebsd.org/D35351
MFC after: 2 weeks

show more ...


Revision tags: release/13.1.0
# 0f2041a5 08-Mar-2022 Fernando Apesteguía <fernape@FreeBSD.org>

[linprocfs] add sys/kernel/random/boot_id

This file holds a UUID that is invariant for every boot. In our case, it is
invariant per mount.

PR: 262369
Reported by: sodynet1@gmail.com
Approved by: dc

[linprocfs] add sys/kernel/random/boot_id

This file holds a UUID that is invariant for every boot. In our case, it is
invariant per mount.

PR: 262369
Reported by: sodynet1@gmail.com
Approved by: dchagin@
Differential Revision: https://reviews.freebsd.org/D34860

show more ...


# b7df7b98 31-Mar-2022 Dmitry Chagin <dchagin@FreeBSD.org>

linprocfs: Add /proc/self/oom_score_adj.

To avoid annoyng messages from LTP test suites add the simple
implementation of /proc/self/oom_score_adj which is do nothing.

Reviewed by: emaste
Different

linprocfs: Add /proc/self/oom_score_adj.

To avoid annoyng messages from LTP test suites add the simple
implementation of /proc/self/oom_score_adj which is do nothing.

Reviewed by: emaste
Differential revision: https://reviews.freebsd.org/D34710
MFC after: 2 weeks

show more ...


# aae8ae5e 25-Mar-2022 Dmitry Chagin <dchagin@FreeBSD.org>

linprocfs: Eliminate bogus comment (KSE).

Reviewed by: trasz, emaste
Differential revision: https://reviews.freebsd.org/D31525
MFC after: 2 weeks


# 1f70a85b 08-Jan-2022 Alexander V. Chernikov <melifaro@FreeBSD.org>

linux: add sysctl to pass untranslated interface names

Reviewed by: kib
MFC after: 2 weeks
Differential Revision: https://reviews.freebsd.org/D33792


Revision tags: release/12.3.0
# 7e1d3eef 25-Nov-2021 Mateusz Guzik <mjg@FreeBSD.org>

vfs: remove the unused thread argument from NDINIT*

See b4a58fbf640409a1 ("vfs: remove cn_thread")

Bump __FreeBSD_version to 1400043.


# ae3d9554 24-Nov-2021 Mateusz Guzik <mjg@FreeBSD.org>

linprocfs: plug set-but-not-unused vars

Sponsored by: Rubicon Communications, LLC ("Netgate")


# 91be6286 03-Nov-2021 Edward Tomasz Napierala <trasz@FreeBSD.org>

linprocfs: Fix formatting of Uid and Gid lines

The separator here should be tabs, not spaces. This fixes a warning
from chromium-browser on Bionic:

[1022/162248.137612:ERROR:process_info_linux.cc(

linprocfs: Fix formatting of Uid and Gid lines

The separator here should be tabs, not spaces. This fixes a warning
from chromium-browser on Bionic:

[1022/162248.137612:ERROR:process_info_linux.cc(107)] format error: unrecognized Uid format

Sponsored By: EPSRC
Differential Revision: https://reviews.freebsd.org/D32612

show more ...


# 69ab5283 30-Sep-2021 Mateusz Guzik <mjg@FreeBSD.org>

linprocfs: find cwd and root handling

The code would incorrectly use curthread instead of the target proc to
resolve vnodes.

Fixes: 8d03b99b9dafe928 ("fd: move vnodes out of filedesc into a dedicat

linprocfs: find cwd and root handling

The code would incorrectly use curthread instead of the target proc to
resolve vnodes.

Fixes: 8d03b99b9dafe928 ("fd: move vnodes out of filedesc into a dedicated structure")
PR: 258729
Noted by: Damjan Jovanovic <damjan.jov@gmail.com>

show more ...


# fe740953 20-Jul-2021 Dmitry Chagin <dchagin@FreeBSD.org>

linprocfs: Fixup vDSO name in the procmaps after 9931033bbf.

As the sv_shared_page_base now pointed out to the native sharedpage and
the process VA layout has changed as follows:
VDSOPAGE (2 * PAGE_

linprocfs: Fixup vDSO name in the procmaps after 9931033bbf.

As the sv_shared_page_base now pointed out to the native sharedpage and
the process VA layout has changed as follows:
VDSOPAGE (2 * PAGE_SIZE)
SHAREDPAGE (PAGE_SIZE)
USRSTACK
fixup the vDSO name by calculating the start of page relative to the
native sharedpage.

Differential revision: https://reviews.freebsd.org/D30903
MFC after: 2 weeks

show more ...


Revision tags: release/13.0.0
# fa2528ac 18-Feb-2021 Alex Richardson <arichardson@FreeBSD.org>

Use atomic loads/stores when updating td->td_state

KCSAN complains about racy accesses in the locking code. Those races are
fine since they are inside a TD_SET_RUNNING() loop that expects the value

Use atomic loads/stores when updating td->td_state

KCSAN complains about racy accesses in the locking code. Those races are
fine since they are inside a TD_SET_RUNNING() loop that expects the value
to be changed by another CPU.

Use relaxed atomic stores/loads to indicate that this variable can be
written/read by multiple CPUs at the same time. This will also prevent
the compiler from doing unexpected re-ordering.

Reported by: GENERIC-KCSAN
Test Plan: KCSAN no longer complains, kernel still runs fine.
Reviewed By: markj, mjg (earlier version)
Differential Revision: https://reviews.freebsd.org/D28569

show more ...


# cd853791 28-Nov-2020 Konstantin Belousov <kib@FreeBSD.org>

Make MAXPHYS tunable. Bump MAXPHYS to 1M.

Replace MAXPHYS by runtime variable maxphys. It is initialized from
MAXPHYS by default, but can be also adjusted with the tunable kern.maxphys.

Make b_pag

Make MAXPHYS tunable. Bump MAXPHYS to 1M.

Replace MAXPHYS by runtime variable maxphys. It is initialized from
MAXPHYS by default, but can be also adjusted with the tunable kern.maxphys.

Make b_pages[] array in struct buf flexible. Size b_pages[] for buffer
cache buffers exactly to atop(maxbcachebuf) (currently it is sized to
atop(MAXPHYS)), and b_pages[] for pbufs is sized to atop(maxphys) + 1.
The +1 for pbufs allow several pbuf consumers, among them vmapbuf(),
to use unaligned buffers still sized to maxphys, esp. when such
buffers come from userspace (*). Overall, we save significant amount
of otherwise wasted memory in b_pages[] for buffer cache buffers,
while bumping MAXPHYS to desired high value.

Eliminate all direct uses of the MAXPHYS constant in kernel and driver
sources, except a place which initialize maxphys. Some random (and
arguably weird) uses of MAXPHYS, e.g. in linuxolator, are converted
straight. Some drivers, which use MAXPHYS to size embeded structures,
get private MAXPHYS-like constant; their convertion is out of scope
for this work.

Changes to cam/, dev/ahci, dev/ata, dev/mpr, dev/mpt, dev/mvs,
dev/siis, where either submitted by, or based on changes by mav.

Suggested by: mav (*)
Reviewed by: imp, mav, imp, mckusick, scottl (intermediate versions)
Tested by: pho
Sponsored by: The FreeBSD Foundation
Differential revision: https://reviews.freebsd.org/D27225

show more ...


# b1976ea1 17-Nov-2020 Conrad Meyer <cem@FreeBSD.org>

linprocfs(5): Add rudimentary /proc/<pid>/mountinfo

This is used by some Linux programs using filehandles (r367773) to locate
the mountpoint for a given fsid.

Differential Revision: https://reviews

linprocfs(5): Add rudimentary /proc/<pid>/mountinfo

This is used by some Linux programs using filehandles (r367773) to locate
the mountpoint for a given fsid.

Differential Revision: https://reviews.freebsd.org/D27136

show more ...


# 20172854 05-Nov-2020 Conrad Meyer <cem@FreeBSD.org>

Add sbuf streaming mode to pseudofs(9), use in linprocfs(5)

Add a pseudofs node flag 'PFS_AUTODRAIN', which automatically emits sbuf
contents to the caller when the sbuf buffer fills. This is only

Add sbuf streaming mode to pseudofs(9), use in linprocfs(5)

Add a pseudofs node flag 'PFS_AUTODRAIN', which automatically emits sbuf
contents to the caller when the sbuf buffer fills. This is only
permissible if the corresponding PFS node fill function can sleep
whenever it appends to the sbuf.

linprocfs' /proc/self/maps node happens to meet this requirement.
Streaming out the file as it is composed avoids truncating the output
and also avoids preallocating a very large buffer.

Reviewed by: markj; earlier version: emaste, kib, trasz
Differential Revision: https://reviews.freebsd.org/D27047

show more ...


# ad7b26ec 29-Oct-2020 Edward Tomasz Napierala <trasz@FreeBSD.org>

Make linprocfs(4) print a warning when there's not enough room to fill
/proc/self/maps.

Submitted by: dchagin (earlier version)
Reviewed by: emaste (earlier version)
MFC after: 2 weeks
Sponsored by:

Make linprocfs(4) print a warning when there's not enough room to fill
/proc/self/maps.

Submitted by: dchagin (earlier version)
Reviewed by: emaste (earlier version)
MFC after: 2 weeks
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D20576

show more ...


# 7135ca98 23-Oct-2020 Edward Tomasz Napierala <trasz@FreeBSD.org>

Add /proc/sys/kernel/ngroups_max to linprocfs(4). The id(1) command
seems to use it - it works fine without it, but still.

MFC after: 2 weeks
Sponsored by: The FreeBSD Foundation
Differential Revis

Add /proc/sys/kernel/ngroups_max to linprocfs(4). The id(1) command
seems to use it - it works fine without it, but still.

MFC after: 2 weeks
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D26898

show more ...


Revision tags: release/12.2.0
# 91bc7361 20-Oct-2020 Edward Tomasz Napierala <trasz@FreeBSD.org>

Fix linprocfs(4) /proc/self/mem semantics to more closely match Linux.
Steam's Anti-Cheat might depend on it.

PR: 248223
Analyzed by: Alex S <iwtcex@gmail.com>
Reviewed by: kib
MFC after: 2 weeks
S

Fix linprocfs(4) /proc/self/mem semantics to more closely match Linux.
Steam's Anti-Cheat might depend on it.

PR: 248223
Analyzed by: Alex S <iwtcex@gmail.com>
Reviewed by: kib
MFC after: 2 weeks
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D26816

show more ...


# 766ae4c7 15-Oct-2020 Edward Tomasz Napierala <trasz@FreeBSD.org>

With some popular multiplayer games (such as Counter-Strike: Global
Offensive) the Linux Steam client likes to occasionally scan the game
process memory, presumably as part anti-cheat measures. Turns

With some popular multiplayer games (such as Counter-Strike: Global
Offensive) the Linux Steam client likes to occasionally scan the game
process memory, presumably as part anti-cheat measures. Turns out
the client also expects each inode entry to be followed by a space
character, otherwise the parsing code crashes.

PR: 248216
Submitted by: Alex S <iwtcex@gmail.com>
MFC after: 2 weeks

show more ...


# 1a180032 01-Sep-2020 Mateusz Guzik <mjg@FreeBSD.org>

compat: clean up empty lines in .c and .h files


# e2515283 27-Aug-2020 Glen Barber <gjb@FreeBSD.org>

MFH

Sponsored by: Rubicon Communications, LLC (netgate.com)


# feabaaf9 24-Aug-2020 Mateusz Guzik <mjg@FreeBSD.org>

cache: drop the always curthread argument from reverse lookup routines

Note VOP_VPTOCNP keeps getting it as temporary compatibility for zfs.

Tested by: pho


# de6fc2e3 15-Aug-2020 Dimitry Andric <dim@FreeBSD.org>

Merge ^/head r364082 through r364250.


# 440cec3f 12-Aug-2020 Glen Barber <gjb@FreeBSD.org>

MFH

Sponsored by: Rubicon Communications, LLC (netgate.com)


# 9eb0cd08 12-Aug-2020 Mark Johnston <markj@FreeBSD.org>

linprocfs: Fix some inaccuracies in meminfo.

- Fill out MemFree correctly. Delete an ancient comment suggesting that
we don't want to advertise the true quantity of free memory.
- Populate the Bu

linprocfs: Fix some inaccuracies in meminfo.

- Fill out MemFree correctly. Delete an ancient comment suggesting that
we don't want to advertise the true quantity of free memory.
- Populate the Buffers field by reading vfs.bufspace.
- The page cache consists of all pages in page queues, not just the
inactive queue.

PR: 248463
Reported and tested by: danfe
MFC after: 1 week
Sponsored by: The FreeBSD Foundation

show more ...


12345678910>>...21