<feed xmlns='http://www.w3.org/2005/Atom'>
<title>src/sys/mips/include, branch release/13.2.0</title>
<subtitle>FreeBSD source tree</subtitle>
<id>https://cgit-dev.freebsd.org/src/atom?h=release%2F13.2.0</id>
<link rel='self' href='https://cgit-dev.freebsd.org/src/atom?h=release%2F13.2.0'/>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/'/>
<updated>2022-05-12T22:12:59Z</updated>
<entry>
<title>Create sys/reg.h for the common code previously in machine/reg.h</title>
<updated>2022-05-12T22:12:59Z</updated>
<author>
<name>Andrew Turner</name>
<email>andrew@FreeBSD.org</email>
</author>
<published>2021-08-27T09:38:40Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=e5e2c7ffa0f7d9ba0874b95924f4d977b116f45b'/>
<id>urn:sha1:e5e2c7ffa0f7d9ba0874b95924f4d977b116f45b</id>
<content type='text'>
Move the common kernel function signatures from machine/reg.h to a new
sys/reg.h. This is in preperation for adding PT_GETREGSET to ptrace(2).

Reviewed by:	imp, markj
Sponsored by:	DARPA, AFRL (original work)
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D19830

(cherry picked from commit b792434150d66b9b2356fb9a7548f4c7f0a0f16c)
</content>
</entry>
<entry>
<title>Simplify swi for bus_dma.</title>
<updated>2022-04-29T21:27:47Z</updated>
<author>
<name>John Baldwin</name>
<email>jhb@FreeBSD.org</email>
</author>
<published>2021-12-28T21:51:25Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=5159d50a1e0690d2bf46c49f83112a756bd6fb47'/>
<id>urn:sha1:5159d50a1e0690d2bf46c49f83112a756bd6fb47</id>
<content type='text'>
When a DMA request using bounce pages completes, a swi is triggered to
schedule pending DMA requests using the just-freed bounce pages.  For
a long time this bus_dma swi has been tied to a "virtual memory" swi
(swi_vm).  However, all of the swi_vm implementations are the same and
consist of checking a flag (busdma_swi_pending) which is always true
and if set calling busdma_swi.  I suspect this dates back to the
pre-SMPng days and that the intention was for swi_vm to serve as a
mux.  However, in the current scheme there's no need for the mux.

Instead, remove swi_vm and vm_ih.  Each bus_dma implementation that
uses bounce pages is responsible for creating its own swi (busdma_ih)
which it now schedules directly.  This swi invokes busdma_swi directly
removing the need for busdma_swi_pending.

One consequence is that the swi now works on RISC-V which had previously
failed to invoke busdma_swi from swi_vm.

Reviewed by:	imp, kib
Sponsored by:	Netflix
Differential Revision:	https://reviews.freebsd.org/D33447

(cherry picked from commit 254e4e5b77d7788c46333ae35d5e9f347e22c746)
</content>
</entry>
<entry>
<title>Add &lt;machine/tls.h&gt; header to hold MD constants and helpers for TLS.</title>
<updated>2022-04-29T20:50:05Z</updated>
<author>
<name>John Baldwin</name>
<email>jhb@FreeBSD.org</email>
</author>
<published>2021-12-09T21:17:13Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=25f14b19c6ec7a1a0c1f7a6d9080152eb0e71a16'/>
<id>urn:sha1:25f14b19c6ec7a1a0c1f7a6d9080152eb0e71a16</id>
<content type='text'>
The header exports the following:

- Definition of struct tcb.
- Helpers to get/set the tcb for the current thread.
- TLS_TCB_SIZE (size of TCB)
- TLS_TCB_ALIGN (alignment of TCB)
- TLS_VARIANT_I or TLS_VARIANT_II
- TLS_DTV_OFFSET (bias of pointers in dtv[])
- TLS_TP_OFFSET (bias of "thread pointer" relative to TCB)

Note that TLS_TP_OFFSET does not account for if the unbiased thread
pointer points to the start of the TCB (arm and x86) or the end of the
TCB (MIPS, PowerPC, and RISC-V).

Note also that for amd64, the struct tcb does not include the unused
tcb_spare field included in the current structure in libthr.  libthr
does not use this field, and the existing calls in libc and rtld that
allocate a TCB for amd64 assume it is the size of 3 Elf_Addr's (and
thus do not allocate room for tcb_spare).

A &lt;sys/_tls_variant_i.h&gt; header is used by architectures using
Variant I TLS which uses a common struct tcb.

Reviewed by:	kib (older version of x86/tls.h), jrtc27
Sponsored by:	The University of Cambridge, Google Inc.
Differential Revision:	https://reviews.freebsd.org/D33351

For stable/13 only, sys/arm/include/tls.h includes support for
ARM_TP_ADDRESS which is not present in main.

(cherry picked from commit 1a62e9bc0046bfe20f4dd785561e469ff73fd508)
</content>
</entry>
<entry>
<title>mips: Rename TLS_DTP_OFFSET to TLS_DTV_OFFSET.</title>
<updated>2022-04-29T20:50:04Z</updated>
<author>
<name>John Baldwin</name>
<email>jhb@FreeBSD.org</email>
</author>
<published>2021-12-09T21:16:00Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=bd3afd52745a373560203d7baf694f0de38b1ea2'/>
<id>urn:sha1:bd3afd52745a373560203d7baf694f0de38b1ea2</id>
<content type='text'>
This is the more standard name for the bias of dtv pointers used on
other platforms.  This also fixes a few other places that were using
the wrong bias previously on MIPS such as dlpi_tls_data in struct
dl_phdr_info and the recently added __libc_tls_get_addr().

Reviewed by:	kib, jrtc27
Sponsored by:	The University of Cambridge, Google Inc.
Differential Revision:	https://reviews.freebsd.org/D33346

(cherry picked from commit 03f6b141068ee7f1004ebfc76242cf951494b7d2)
</content>
</entry>
<entry>
<title>Remove "All Rights Reserved" from FreeBSD Foundation sys/ copyrights</title>
<updated>2022-02-08T20:00:55Z</updated>
<author>
<name>Ed Maste</name>
<email>emaste@FreeBSD.org</email>
</author>
<published>2021-08-08T14:38:01Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=94e6d1448863a8ccccec3c7e4e501761803cce0e'/>
<id>urn:sha1:94e6d1448863a8ccccec3c7e4e501761803cce0e</id>
<content type='text'>
These ones were unambiguous cases where the Foundation was the only
listed copyright holder (in the associated license block).

Sponsored by:	The FreeBSD Foundation

(cherry picked from commit 9feff969a01044c3083b552f06f7eb6416bc0524)
</content>
</entry>
<entry>
<title>Clean up a couple of MD warts in vm_fault_populate():</title>
<updated>2021-12-28T00:35:55Z</updated>
<author>
<name>Jason A. Harmening</name>
<email>jah@FreeBSD.org</email>
</author>
<published>2021-03-27T03:10:46Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=fa4e4d55b3c8d427298744a13e53d6592b56c270'/>
<id>urn:sha1:fa4e4d55b3c8d427298744a13e53d6592b56c270</id>
<content type='text'>
--Eliminate a big ifdef that encompassed all currently-supported
architectures except mips and powerpc32.  This applied to the case
in which we've allocated a superpage but the pager-populated range
is insufficient for a superpage mapping.  For platforms that don't
support superpages the check should be inexpensive as we shouldn't
get a superpage in the first place.  Make the normal-page fallback
logic identical for all platforms and provide a simple implementation
of pmap_ps_enabled() for MIPS and Book-E/AIM32 powerpc.

--Apply the logic for handling pmap_enter() failure if a superpage
mapping can't be supported due to additional protection policy.
Use KERN_PROTECTION_FAILURE instead of KERN_FAILURE for this case,
and note Intel PKU on amd64 as the first example of such protection
policy.

Reviewed by:	kib, markj, bdragon

(cherry picked from commit 8dc8feb53da0c1a2301cb21c87b17a09d12e8fa7)
</content>
</entry>
<entry>
<title>Implement GET_STACK_USAGE on remaining archs</title>
<updated>2021-12-07T18:13:47Z</updated>
<author>
<name>Mitchell Horne</name>
<email>mhorne@FreeBSD.org</email>
</author>
<published>2021-11-25T16:01:11Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=1d640e61358469c17fb0ce340f78104a50b26959'/>
<id>urn:sha1:1d640e61358469c17fb0ce340f78104a50b26959</id>
<content type='text'>
This definition enables callers to estimate remaining space on the
kstack, and take action on it. Notably, it enables optimizations in the
GEOM and netgraph subsystems to directly dispatch work items when there
is sufficient stack space, rather than queuing them for a worker thread.

Implement it for riscv, arm, and mips. Remove the #ifdefs, so it will
not go unimplemented elsewhere.

PR:		259157
Reviewed by:	mav, kib, markj (previous version)
MFC after:	1 week
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D32580

(cherry picked from commit 0d2224733e970aaa67a4e1af7b340044adda92f6)
</content>
</entry>
<entry>
<title>minidump: Parameterize minidumpsys()</title>
<updated>2021-12-03T14:02:03Z</updated>
<author>
<name>Mitchell Horne</name>
<email>mhorne@FreeBSD.org</email>
</author>
<published>2021-11-17T15:26:59Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=eb2ea57ef1f2f1a36953aa0aaa7c7522311a81f8'/>
<id>urn:sha1:eb2ea57ef1f2f1a36953aa0aaa7c7522311a81f8</id>
<content type='text'>
The minidump code is written assuming that certain global state will not
change, and rightly so, since it executes from a kernel debugger
context. In order to support taking minidumps of a live system, we
should allow copies of relevant global state that is likely to change to
be passed as parameters to the minidumpsys() function.

This patch does the work of parameterizing this function, by adding a
struct minidumpstate argument. For now, this struct allows for copies of
the kernel message buffer, and the bitset that tracks which pages should
be dumped (vm_page_dump). Follow-up changes will actually make use of
these arguments.

Notably, dump_avail[] does not need a snapshot, since it is not expected
to change after system initialization.

The existing minidumpsys() definitions are renamed, and a thin MI
wrapper is added to kern_dump.c, which handles the construction of
the state struct. Thus, calling minidumpsys() remains as simple as
before.

Reviewed by:	kib, markj, jhb
Sponsored by:	Juniper Networks, Inc.
Sponsored by:	Klara, Inc.
MFC after:	2 weeks
Differential Revision:	https://reviews.freebsd.org/D31989

(cherry picked from commit 1adebe3cd6b1eb0973969e2c4c5d41f174caa304)
</content>
</entry>
<entry>
<title>netinet: Remove in_cksum_update()</title>
<updated>2021-12-01T12:41:55Z</updated>
<author>
<name>Mark Johnston</name>
<email>markj@FreeBSD.org</email>
</author>
<published>2021-11-24T18:15:40Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=bc7bc3bdf95f29d72479cf8c3c858d257f12e327'/>
<id>urn:sha1:bc7bc3bdf95f29d72479cf8c3c858d257f12e327</id>
<content type='text'>
It was never implemented on powerpc or riscv and appears to have been
unused since it was added in 1998.  No functional change intended.

Reviewed by:	kp, glebius, cy
Sponsored by:	The FreeBSD Foundation

(cherry picked from commit 09100f936be0684aa8caef441b96345960fd9c72)
</content>
</entry>
<entry>
<title>minidump: De-duplicate the progress bar</title>
<updated>2021-10-15T15:20:48Z</updated>
<author>
<name>Mitchell Horne</name>
<email>mhorne@FreeBSD.org</email>
</author>
<published>2021-09-29T17:44:27Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=fc7febf483a4910b024b34ab8620e6ac14590c08'/>
<id>urn:sha1:fc7febf483a4910b024b34ab8620e6ac14590c08</id>
<content type='text'>
The implementation of the progress bar is simple, but duplicated for
most minidump implementations. Extract the common bits to kern_dump.c.
Ensure that the bar is reset with each subsequent dump; this was only
done on some platforms previously.

Reviewed by:	markj
MFC after:	2 weeks
Sponsored by:	Juniper Networks, Inc.
Sponsored by:	Klara, Inc.
Differential Revision:	https://reviews.freebsd.org/D31885

(cherry picked from commit ab4ed843a303ea3e585f8ed3f79873e46d3b3ae3)
</content>
</entry>
</feed>
