<feed xmlns='http://www.w3.org/2005/Atom'>
<title>src/sys/compat/linuxkpi/common/include, branch main</title>
<subtitle>FreeBSD source tree</subtitle>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/'/>
<entry>
<title>linuxkpi: Fix an off-by-one error in the kfifo implementation</title>
<updated>2026-04-15T13:33:04+00:00</updated>
<author>
<name>Mark Johnston</name>
<email>markj@FreeBSD.org</email>
</author>
<published>2026-04-15T13:33:04+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=52d2fc702b85d56b35f8828fe7efca3cde0d25b7'/>
<id>52d2fc702b85d56b35f8828fe7efca3cde0d25b7</id>
<content type='text'>
"total" is the number of slots in the array, so wraparound needs to be
done when "first" or "last" is greater than or equal to the number of
slots.

Note that no consumers of the code are currently connected to the kernel
build.

Reported by:	Stanislav Fort &lt;stanislav.fort@aisle.com&gt;
Reviewed by:	bz, emaste
MFC after:	1 week
Differential Revision:	https://reviews.freebsd.org/D56371
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
"total" is the number of slots in the array, so wraparound needs to be
done when "first" or "last" is greater than or equal to the number of
slots.

Note that no consumers of the code are currently connected to the kernel
build.

Reported by:	Stanislav Fort &lt;stanislav.fort@aisle.com&gt;
Reviewed by:	bz, emaste
MFC after:	1 week
Differential Revision:	https://reviews.freebsd.org/D56371
</pre>
</div>
</content>
</entry>
<entry>
<title>linuxkpi: Add &lt;linux/ascii85.h&gt;</title>
<updated>2026-04-06T19:28:11+00:00</updated>
<author>
<name>Jean-Sébastien Pédron</name>
<email>dumbbell@FreeBSD.org</email>
</author>
<published>2026-03-09T19:04:12+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=0eaa57625d0fbe9960eabbaaedd522acdf673648'/>
<id>0eaa57625d0fbe9960eabbaaedd522acdf673648</id>
<content type='text'>
This is used by the i915 DRM driver for some time to log more details
about a GPU error, but the code was commented out.

Reviewed by:	emaste
Sponsored by:	The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D56282
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This is used by the i915 DRM driver for some time to log more details
about a GPU error, but the code was commented out.

Reviewed by:	emaste
Sponsored by:	The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D56282
</pre>
</div>
</content>
</entry>
<entry>
<title>linuxkpi: Define missing `SZ_*` below 1 kib</title>
<updated>2026-04-06T19:28:10+00:00</updated>
<author>
<name>Jean-Sébastien Pédron</name>
<email>dumbbell@FreeBSD.org</email>
</author>
<published>2026-03-08T11:23:54+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=5ee604b2446fa0f3fb949b21a587884ad65b5737'/>
<id>5ee604b2446fa0f3fb949b21a587884ad65b5737</id>
<content type='text'>
The amdgpu DRM driver started to use it in Linux 6.11.

Reviewed by:	bz, emaste
Sponsored by:	The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D55740
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The amdgpu DRM driver started to use it in Linux 6.11.

Reviewed by:	bz, emaste
Sponsored by:	The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D55740
</pre>
</div>
</content>
</entry>
<entry>
<title>linuxkpi: Define `MIN_T()` and `MAX_T()`</title>
<updated>2026-04-06T19:28:10+00:00</updated>
<author>
<name>Jean-Sébastien Pédron</name>
<email>dumbbell@FreeBSD.org</email>
</author>
<published>2026-03-08T11:18:22+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=ece26db020db3a21b1a4c6b608f77a9ed5be5924'/>
<id>ece26db020db3a21b1a4c6b608f77a9ed5be5924</id>
<content type='text'>
There are the same as `MIN()` and `MAX()` except that they take a type
to cast both arguments to compare.

The DRM generic code started to use it in Linux 6.11.

Reviewed by:	bz, emaste
Sponsored by:	The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D55739
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
There are the same as `MIN()` and `MAX()` except that they take a type
to cast both arguments to compare.

The DRM generic code started to use it in Linux 6.11.

Reviewed by:	bz, emaste
Sponsored by:	The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D55739
</pre>
</div>
</content>
</entry>
<entry>
<title>linuxkpi: Document why &lt;linux/pci.h&gt; can't include &lt;linux/ioport.h&gt;</title>
<updated>2026-04-06T19:28:10+00:00</updated>
<author>
<name>Jean-Sébastien Pédron</name>
<email>dumbbell@FreeBSD.org</email>
</author>
<published>2026-03-08T09:45:48+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=91e54839545f6cb91bb1a5f768ddd6c1e2420b48'/>
<id>91e54839545f6cb91bb1a5f768ddd6c1e2420b48</id>
<content type='text'>
Reviewed by:	bz, emaste
Sponsored by:	The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D55738
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Reviewed by:	bz, emaste
Sponsored by:	The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D55738
</pre>
</div>
</content>
</entry>
<entry>
<title>linuxkpi: Add field `flags` to `struct resource`</title>
<updated>2026-04-06T19:28:10+00:00</updated>
<author>
<name>Jean-Sébastien Pédron</name>
<email>dumbbell@FreeBSD.org</email>
</author>
<published>2026-03-08T09:44:12+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=ddf89d899b8d2d0e26c1a22c92f3ac1eddeac9f6'/>
<id>ddf89d899b8d2d0e26c1a22c92f3ac1eddeac9f6</id>
<content type='text'>
This in the Linux version of `struct resource`, not the FreeBSD native
structure.

The amdgpu DRM driver started to use it in Linux 6.11.

Reviewed by:	bz
Sponsored by:	The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D55737
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This in the Linux version of `struct resource`, not the FreeBSD native
structure.

The amdgpu DRM driver started to use it in Linux 6.11.

Reviewed by:	bz
Sponsored by:	The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D55737
</pre>
</div>
</content>
</entry>
<entry>
<title>linuxkpi: Add &lt;linux/mfd/core.h&gt;</title>
<updated>2026-04-06T19:28:09+00:00</updated>
<author>
<name>Jean-Sébastien Pédron</name>
<email>dumbbell@FreeBSD.org</email>
</author>
<published>2026-03-08T09:40:38+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=356d6f47d3b54b34aaba9e60aa551f3d615d0e2f'/>
<id>356d6f47d3b54b34aaba9e60aa551f3d615d0e2f</id>
<content type='text'>
To be exact, there was a dummy file with no content before. This commit
defines `struct mfd_cell` and adds two function stubs.

The function stubs are not implemented but still return success. They
log a message to indicate they need to be implemented.

Also, unlike Linux, &lt;linux/mfd/core.h&gt; includes &lt;linux/ioport.h&gt;. This
works around the fact that we can't include &lt;linux/ioport.h&gt; from
&lt;linux/pci.h&gt;, due to a conflict with the FreeBSD-native `struct
resource`.

The amdgpu DRM driver started to use it in Linux 6.11.

Reviewed by:	bz, emaste
Sponsored by:	The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D55736
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
To be exact, there was a dummy file with no content before. This commit
defines `struct mfd_cell` and adds two function stubs.

The function stubs are not implemented but still return success. They
log a message to indicate they need to be implemented.

Also, unlike Linux, &lt;linux/mfd/core.h&gt; includes &lt;linux/ioport.h&gt;. This
works around the fact that we can't include &lt;linux/ioport.h&gt; from
&lt;linux/pci.h&gt;, due to a conflict with the FreeBSD-native `struct
resource`.

The amdgpu DRM driver started to use it in Linux 6.11.

Reviewed by:	bz, emaste
Sponsored by:	The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D55736
</pre>
</div>
</content>
</entry>
<entry>
<title>linuxkpi: Add &lt;linux/linux_logo.h&gt;</title>
<updated>2026-04-06T19:28:09+00:00</updated>
<author>
<name>Jean-Sébastien Pédron</name>
<email>dumbbell@FreeBSD.org</email>
</author>
<published>2026-03-04T20:49:50+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=ca6ea6df1f9241346d043a2091484ac9ced6580e'/>
<id>ca6ea6df1f9241346d043a2091484ac9ced6580e</id>
<content type='text'>
It only defines the `struct linux_logo` structure for now. It does not
define any actual logo.

Reviewed by:	bz, emaste
Sponsored by:	The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D55735
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
It only defines the `struct linux_logo` structure for now. It does not
define any actual logo.

Reviewed by:	bz, emaste
Sponsored by:	The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D55735
</pre>
</div>
</content>
</entry>
<entry>
<title>linuxkpi: Define `PMD_SHIFT`</title>
<updated>2026-04-06T19:28:09+00:00</updated>
<author>
<name>Jean-Sébastien Pédron</name>
<email>dumbbell@FreeBSD.org</email>
</author>
<published>2026-03-04T20:36:20+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=be92ad6b12a5046cecf25477e7a3e88f70e5daee'/>
<id>be92ad6b12a5046cecf25477e7a3e88f70e5daee</id>
<content type='text'>
For now, only define it for x86 architectures.

The DRM generic code started to use it in Linux 6.11.

Reviewed by:	bz, emaste
Sponsored by:	The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D55734
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
For now, only define it for x86 architectures.

The DRM generic code started to use it in Linux 6.11.

Reviewed by:	bz, emaste
Sponsored by:	The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D55734
</pre>
</div>
</content>
</entry>
<entry>
<title>linuxkpi: Define `CONFIG_PGTABLE_LEVELS`</title>
<updated>2026-04-06T19:28:09+00:00</updated>
<author>
<name>Jean-Sébastien Pédron</name>
<email>dumbbell@FreeBSD.org</email>
</author>
<published>2026-03-04T20:34:37+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=7bf93680807e518853262f3f961f88eb8ec03c83'/>
<id>7bf93680807e518853262f3f961f88eb8ec03c83</id>
<content type='text'>
This is a kernel configuration constant that is expected to be defined.

The DRM generic code started to use it in Linux 6.11.

Reviewed by:	bz
Sponsored by:	The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D55733
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This is a kernel configuration constant that is expected to be defined.

The DRM generic code started to use it in Linux 6.11.

Reviewed by:	bz
Sponsored by:	The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D55733
</pre>
</div>
</content>
</entry>
</feed>
