<feed xmlns='http://www.w3.org/2005/Atom'>
<title>src/sys/dev/chromebook_platform, branch main</title>
<subtitle>FreeBSD source tree</subtitle>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/'/>
<entry>
<title>chore: replace {0, 0} with {DEV,KOBJ}METHOD_END</title>
<updated>2026-02-25T05:59:34+00:00</updated>
<author>
<name>Enji Cooper</name>
<email>ngie@FreeBSD.org</email>
</author>
<published>2026-02-21T06:14:46+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=0fc6c3f731a2cca3120798806c330a3081c9424b'/>
<id>0fc6c3f731a2cca3120798806c330a3081c9424b</id>
<content type='text'>
Both of the aforementioned macros have been present in FreeBSD
for well over a decade: 2009 for `KOBJMETHOD_END`; 2011 for
`DEVMETHOD_END`.

Adapt all hardcoded references of `{0, 0}` with `DEVMETHOD_END`
and `KOBJMETHOD_END` as appropriate. This helps ensure that
future adaptations to drivers following patterns documented
in driver(9) can be made more easily/without issue.

MFC after:	1 week
Differential Revision:	 https://reviews.freebsd.org/D55414
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Both of the aforementioned macros have been present in FreeBSD
for well over a decade: 2009 for `KOBJMETHOD_END`; 2011 for
`DEVMETHOD_END`.

Adapt all hardcoded references of `{0, 0}` with `DEVMETHOD_END`
and `KOBJMETHOD_END` as appropriate. This helps ensure that
future adaptations to drivers following patterns documented
in driver(9) can be made more easily/without issue.

MFC after:	1 week
Differential Revision:	 https://reviews.freebsd.org/D55414
</pre>
</div>
</content>
</entry>
<entry>
<title>newbus: replace leftover device unit wildcards</title>
<updated>2025-06-21T02:57:45+00:00</updated>
<author>
<name>Ahmad Khalifa</name>
<email>vexeduxr@FreeBSD.org</email>
</author>
<published>2025-06-11T00:25:08+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=b670c9bafc0e31c7609969bf374b2e80bdc00211'/>
<id>b670c9bafc0e31c7609969bf374b2e80bdc00211</id>
<content type='text'>
Reviewed by:	imp, jhb
Approved by:	imp (mentor)
Differential Revision:	https://reviews.freebsd.org/D50913
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Reviewed by:	imp, jhb
Approved by:	imp (mentor)
Differential Revision:	https://reviews.freebsd.org/D50913
</pre>
</div>
</content>
</entry>
<entry>
<title>newbus: replace -1 in BUS_ADD_CHILD(...-1) with DEVICE_UNIT_ANY</title>
<updated>2024-07-25T04:23:02+00:00</updated>
<author>
<name>Warner Losh</name>
<email>imp@FreeBSD.org</email>
</author>
<published>2024-07-25T04:23:02+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=a05a680469a7ac77b195021fed74e3aa58152dd7'/>
<id>a05a680469a7ac77b195021fed74e3aa58152dd7</id>
<content type='text'>
Sponsored by:		Netflix
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Sponsored by:		Netflix
</pre>
</div>
</content>
</entry>
<entry>
<title>sys: Automated cleanup of cdefs and other formatting</title>
<updated>2023-11-27T05:24:00+00:00</updated>
<author>
<name>Warner Losh</name>
<email>imp@FreeBSD.org</email>
</author>
<published>2023-11-24T20:12:57+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=fdafd315ad0d0f28a11b9fb4476a9ab059c62b92'/>
<id>fdafd315ad0d0f28a11b9fb4476a9ab059c62b92</id>
<content type='text'>
Apply the following automated changes to try to eliminate
no-longer-needed sys/cdefs.h includes as well as now-empty
blank lines in a row.

Remove /^#if.*\n#endif.*\n#include\s+&lt;sys/cdefs.h&gt;.*\n/
Remove /\n+#include\s+&lt;sys/cdefs.h&gt;.*\n+#if.*\n#endif.*\n+/
Remove /\n+#if.*\n#endif.*\n+/
Remove /^#if.*\n#endif.*\n/
Remove /\n+#include\s+&lt;sys/cdefs.h&gt;\n#include\s+&lt;sys/types.h&gt;/
Remove /\n+#include\s+&lt;sys/cdefs.h&gt;\n#include\s+&lt;sys/param.h&gt;/
Remove /\n+#include\s+&lt;sys/cdefs.h&gt;\n#include\s+&lt;sys/capsicum.h&gt;/

Sponsored by:		Netflix
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Apply the following automated changes to try to eliminate
no-longer-needed sys/cdefs.h includes as well as now-empty
blank lines in a row.

Remove /^#if.*\n#endif.*\n#include\s+&lt;sys/cdefs.h&gt;.*\n/
Remove /\n+#include\s+&lt;sys/cdefs.h&gt;.*\n+#if.*\n#endif.*\n+/
Remove /\n+#if.*\n#endif.*\n+/
Remove /^#if.*\n#endif.*\n/
Remove /\n+#include\s+&lt;sys/cdefs.h&gt;\n#include\s+&lt;sys/types.h&gt;/
Remove /\n+#include\s+&lt;sys/cdefs.h&gt;\n#include\s+&lt;sys/param.h&gt;/
Remove /\n+#include\s+&lt;sys/cdefs.h&gt;\n#include\s+&lt;sys/capsicum.h&gt;/

Sponsored by:		Netflix
</pre>
</div>
</content>
</entry>
<entry>
<title>sys: Remove $FreeBSD$: one-line .c pattern</title>
<updated>2023-08-16T17:54:36+00:00</updated>
<author>
<name>Warner Losh</name>
<email>imp@FreeBSD.org</email>
</author>
<published>2023-08-16T17:54:36+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=685dc743dc3b5645e34836464128e1c0558b404b'/>
<id>685dc743dc3b5645e34836464128e1c0558b404b</id>
<content type='text'>
Remove /^[\s*]*__FBSDID\("\$FreeBSD\$"\);?\s*\n/
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Remove /^[\s*]*__FBSDID\("\$FreeBSD\$"\);?\s*\n/
</pre>
</div>
</content>
</entry>
<entry>
<title>chromebook_platform: Remove unused devclass argument to DRIVER_MODULE.</title>
<updated>2022-05-09T19:22:01+00:00</updated>
<author>
<name>John Baldwin</name>
<email>jhb@FreeBSD.org</email>
</author>
<published>2022-05-09T19:22:01+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=950143eccf467f15ccea27bfaece75d7e4797d38'/>
<id>950143eccf467f15ccea27bfaece75d7e4797d38</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>[ig4] Give common name to PCI and ACPI device drivers</title>
<updated>2019-11-03T20:39:46+00:00</updated>
<author>
<name>Vladimir Kondratyev</name>
<email>wulf@FreeBSD.org</email>
</author>
<published>2019-11-03T20:39:46+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=984ed3e493adc93daf6c79800a1ae2fa53d450e9'/>
<id>984ed3e493adc93daf6c79800a1ae2fa53d450e9</id>
<content type='text'>
They share common device driver code with different bus attachments

This commit starts a bunch of changes which have following properties:

Reviewed by:		imp (previous version)
MFC after:		1 month
Differential Revision:	https://reviews.freebsd.org/D22016
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
They share common device driver code with different bus attachments

This commit starts a bunch of changes which have following properties:

Reviewed by:		imp (previous version)
MFC after:		1 month
Differential Revision:	https://reviews.freebsd.org/D22016
</pre>
</div>
</content>
</entry>
<entry>
<title>chromebook_platform: catch up with ig4iic -&gt; ig4iic_pci in r310621</title>
<updated>2017-02-25T15:55:46+00:00</updated>
<author>
<name>Andriy Gapon</name>
<email>avg@FreeBSD.org</email>
</author>
<published>2017-02-25T15:55:46+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=253495d764a74d7bda6486fb802b49ee31da3055'/>
<id>253495d764a74d7bda6486fb802b49ee31da3055</id>
<content type='text'>
Reported by:	Wolfgang Zenker &lt;wolfgang@lyxys.ka.sub.org&gt;
Tested by:	Wolfgang Zenker &lt;wolfgang@lyxys.ka.sub.org&gt;
MFC after:	5 days
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Reported by:	Wolfgang Zenker &lt;wolfgang@lyxys.ka.sub.org&gt;
Tested by:	Wolfgang Zenker &lt;wolfgang@lyxys.ka.sub.org&gt;
MFC after:	5 days
</pre>
</div>
</content>
</entry>
<entry>
<title>add iic interface to ig4 driver, move isl and cyapa to iicbus</title>
<updated>2016-10-30T12:15:33+00:00</updated>
<author>
<name>Andriy Gapon</name>
<email>avg@FreeBSD.org</email>
</author>
<published>2016-10-30T12:15:33+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=448897d366c218f9fd6208427eef1e6dd51f78d0'/>
<id>448897d366c218f9fd6208427eef1e6dd51f78d0</id>
<content type='text'>
Summary:
The hardware does not expose a classic SMBus interface.
Instead it has a lower level interface that can express a far richer
I2C protocol than what smbus offers.  However, the interface does not
provide a way to explicitly generate the I2C stop and start conditions.
It's only possible to request that the stop condition is generated
after transferring the next byte in either direction.  So, at least
one data byte must always be transferred.
Thus, some I2C sequences are impossible to generate, e.g., an equivalent
of smbus quick command (&lt;start&gt;-&lt;slave addr&gt;-&lt;r/w bit&gt;-&lt;stop&gt;).

At the same time isl(4) and cyapa(4) are moved to iicbus and now they use
iicbus_transfer for communication.  Previously they used smbus_trans()
interface that is not defined by the SMBus protocol and was implemented
only by ig4(4).  In fact, that interface was impossible to implement
for the typical SMBus controllers like intpm(4) or ichsmb(4) where
a type of the SMBus command must be programmed.

The plan is to remove smbus_trans() and all its uses.
As an aside, the smbus_trans() method deviates from the standard,
but perhaps backwards, FreeBSD convention of using 8-bit slave
addresses (shifted by 1 bit to the left).  The method expects
7-bit addresses.

There is a user facing consequence of this change.
A user must now provide device hints for isl and cyapa that specify an iicbus to use
and a slave address on it.
On Chromebook hardware where isl and cyapa devices are commonly found
it is also possible to use a new chromebook_platform(4) driver that
automatically configures isl and cyapa devices.  There is no need to
provide the device hints in that case,

Right now smbus(4) driver tries to discover all slaves on the bus.
That is very dangerous.  Fortunately, the probing code uses smbus_trans()
to do its job, so it is really enabled for ig4 only.
The plan is to remove that auto-probing code and smbus_trans().

Tested by:	grembo, Matthias Apitz &lt;guru@unixarea.de&gt; (w/o
		chromebook_platform)
Discussed with:	grembo, imp
Reviewed by:	wblock (docs)
MFC after:	1 month
Relnotes:	yes
Differential Revision: https://reviews.freebsd.org/D8172
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Summary:
The hardware does not expose a classic SMBus interface.
Instead it has a lower level interface that can express a far richer
I2C protocol than what smbus offers.  However, the interface does not
provide a way to explicitly generate the I2C stop and start conditions.
It's only possible to request that the stop condition is generated
after transferring the next byte in either direction.  So, at least
one data byte must always be transferred.
Thus, some I2C sequences are impossible to generate, e.g., an equivalent
of smbus quick command (&lt;start&gt;-&lt;slave addr&gt;-&lt;r/w bit&gt;-&lt;stop&gt;).

At the same time isl(4) and cyapa(4) are moved to iicbus and now they use
iicbus_transfer for communication.  Previously they used smbus_trans()
interface that is not defined by the SMBus protocol and was implemented
only by ig4(4).  In fact, that interface was impossible to implement
for the typical SMBus controllers like intpm(4) or ichsmb(4) where
a type of the SMBus command must be programmed.

The plan is to remove smbus_trans() and all its uses.
As an aside, the smbus_trans() method deviates from the standard,
but perhaps backwards, FreeBSD convention of using 8-bit slave
addresses (shifted by 1 bit to the left).  The method expects
7-bit addresses.

There is a user facing consequence of this change.
A user must now provide device hints for isl and cyapa that specify an iicbus to use
and a slave address on it.
On Chromebook hardware where isl and cyapa devices are commonly found
it is also possible to use a new chromebook_platform(4) driver that
automatically configures isl and cyapa devices.  There is no need to
provide the device hints in that case,

Right now smbus(4) driver tries to discover all slaves on the bus.
That is very dangerous.  Fortunately, the probing code uses smbus_trans()
to do its job, so it is really enabled for ig4 only.
The plan is to remove that auto-probing code and smbus_trans().

Tested by:	grembo, Matthias Apitz &lt;guru@unixarea.de&gt; (w/o
		chromebook_platform)
Discussed with:	grembo, imp
Reviewed by:	wblock (docs)
MFC after:	1 month
Relnotes:	yes
Differential Revision: https://reviews.freebsd.org/D8172
</pre>
</div>
</content>
</entry>
</feed>
