#
ba5ad174 |
| 29-May-2024 |
kettenis <kettenis@openbsd.org> |
Implement the guts for "suspend-to-idle" on amd64. This enables suspend on machines that don't support S3. In its current state it doesn't save a lot of power, but this should improve over time. I
Implement the guts for "suspend-to-idle" on amd64. This enables suspend on machines that don't support S3. In its current state it doesn't save a lot of power, but this should improve over time. Implementation of wakeup methods is incomplete which means that some machine can't resume at the moment.
ok mglocker@, mlarkin@, stsp@, deraadt@
show more ...
|
#
0f9e9ec2 |
| 13-May-2024 |
jsg <jsg@openbsd.org> |
remove prototypes with no matching function ok mpi@
|
#
dcec61dc |
| 15-Aug-2023 |
miod <miod@openbsd.org> |
Replace a bunch of (1 << 31) with (1U << 31)
|
#
471aeecf |
| 06-Apr-2022 |
naddy <naddy@openbsd.org> |
constify struct cfattach
|
#
620cc1d5 |
| 04-Apr-2022 |
deraadt <deraadt@openbsd.org> |
As a hack, use CD_SKIPHIBERNATE. For 2.0, our TPM lifecycle management is improper, and some chips are more sensitive to this than others. In an unhibernate situation, /bsd.booted will 'suspend' th
As a hack, use CD_SKIPHIBERNATE. For 2.0, our TPM lifecycle management is improper, and some chips are more sensitive to this than others. In an unhibernate situation, /bsd.booted will 'suspend' the TPM, then jump directly into unhib /bsd, which 'resumes' it. This is wrong because the lifecycle is supposed to be more like suspend->BIOS->resume. This is a hack until we figure out how to fix the lifecycle. from claudio, ok dv
show more ...
|
#
57ec0946 |
| 21-Dec-2021 |
kettenis <kettenis@openbsd.org> |
Move checks on attach arguments from attach into match.
ok anton@, deraadt@
|
#
5d99c75f |
| 07-Dec-2021 |
deraadt <deraadt@openbsd.org> |
print the failed method number
|
#
306068a2 |
| 23-Oct-2021 |
dv <dv@openbsd.org> |
tpm(4): add support for tpm2 CRB interface
Some modern tpm2 devices require or prefer drivers communicate via the CRB interface and not the TIS/fifo interface. This change adds basic support for det
tpm(4): add support for tpm2 CRB interface
Some modern tpm2 devices require or prefer drivers communicate via the CRB interface and not the TIS/fifo interface. This change adds basic support for detecting CRB start mode and using CRB to issue commands required for proper S4 hibernation. As a result, this also defines a new struct definition for the TPM2 acpi table required for start mode detection.
This fixes recent S4 regressions on the Surface Go 2 caused by a change in firmware from Microsoft.
Other CRB start methods may need implementing in the future to support additional hardware.
tested by deraadt@ and many others, ok kettenis@
show more ...
|
#
01a460e6 |
| 11-Sep-2021 |
deraadt <deraadt@openbsd.org> |
Identify TPM2.0 devices and perform the 2.0-specific "suspend" command (researched by mlarkin). With this, and the latest BIOS which added S3, the lenovo x1r9 and x1nano can resume. ok kettenis mlar
Identify TPM2.0 devices and perform the 2.0-specific "suspend" command (researched by mlarkin). With this, and the latest BIOS which added S3, the lenovo x1r9 and x1nano can resume. ok kettenis mlarkin
show more ...
|
#
a9e30698 |
| 28-Jan-2021 |
cheloha <cheloha@openbsd.org> |
tpm(4): fix delay units
tpm(4) has timeout constants in milliseconds, e.g.
#define TPM_ACCESS_TMO 2000 /* 2sec */
This is fine.
The odd thing is that tpm(4) first converts these timeouts to cou
tpm(4): fix delay units
tpm(4) has timeout constants in milliseconds, e.g.
#define TPM_ACCESS_TMO 2000 /* 2sec */
This is fine.
The odd thing is that tpm(4) first converts these timeouts to counts of ticks via tpm_tmotohz() before using DELAY() to busy-wait. DELAY() takes a count of microseconds, which are not equivalent to ticks, so the units are all screwed up.
Let's correct this:
- Remove tpm_tmotohz(). We're not working with ticks so we don't it.
- Multiply the timeouts to match the delay interval. tpm_request_locality() and tpm_getburst() use intervals of 10 microseconds, so multiply the millisecond timeouts by 100. In tpm_waitfor() the delay interval is 1 microsecond, so multiply the millisecond timeout by 1000.
- Update the parameter name in tpm_waitfor() to note that we expect a count of milliseconds, not "tries".
Discussion: https://marc.info/?l=openbsd-tech&m=160995671326406&w=2
Prompted by kettenis@.
Suspend/resume tested by florian@ on an X1 Gen 2. For the record, it looks like this:
tpm0 at acpi0 TPM_ addr 0xfed40000/0x5000, device 0x0000104a rev 0x4e
Earlier versions of this patch were reviewed by kn@, but the patch became more ambitious when kettenis@ got involved so those reviews are no longer applicable.
jcs@ notes (https://marc.info/?l=openbsd-tech&m=160834427630142&w=2) in a related discussion that this driver "sucks" and should be replaced with NetBSD's rewrite. This would get us a cleaner driver with TPM 2.0 support. So there is future work to do here.
ok kettenis@
show more ...
|
#
9f1f78b7 |
| 22-May-2020 |
kettenis <kettenis@openbsd.org> |
Use the parsed address and interrupt information from struct acpi_attach_args.
tpm(4) tested by kn@ ok jmatthew@
|
#
c984dbba |
| 15-May-2019 |
tedu <tedu@openbsd.org> |
unrevert, i missed deraadt's commit with the proper fix noticed by deraadt
|
#
f5cc58e9 |
| 15-May-2019 |
tedu <tedu@openbsd.org> |
revert previous, since it makes jmc's machine print an extra newline. several printfs here seem to have mismatched newlines?
|
#
e0256b2b |
| 15-May-2019 |
deraadt <deraadt@openbsd.org> |
if \n is added in attach, then tpm_init() should skip it.
|
#
c5aeeb42 |
| 13-May-2019 |
tedu <tedu@openbsd.org> |
print a newline for attach. from f holop
|
#
07392f17 |
| 13-Apr-2019 |
deraadt <deraadt@openbsd.org> |
MSFT0101 must require some special handling, since this breaks suspend on some machines. Back out until more known.
|
#
304235fb |
| 04-Apr-2019 |
edd <edd@openbsd.org> |
Make tpm(4) attach to MSFT0101 chips.
I found this chip in my Lenovo Thinkpad X1 (5th gen): tpm0 at acpi0: TPM_ addr 0xfed40000/0x5000: device 0x001b15d1 rev 0x10
"Yes, please commit this" deraadt@
Make tpm(4) attach to MSFT0101 chips.
I found this chip in my Lenovo Thinkpad X1 (5th gen): tpm0 at acpi0: TPM_ addr 0xfed40000/0x5000: device 0x001b15d1 rev 0x10
"Yes, please commit this" deraadt@. Thanks.
show more ...
|
#
128e94b2 |
| 01-Jul-2018 |
mlarkin <mlarkin@openbsd.org> |
acpi: clean up some inconsistent style in the hid matching arrays
ok millert, kettenis, jcs, phessler, deraadt, mpi
|
#
dd9a9f1c |
| 25-Oct-2016 |
pirofti <pirofti@openbsd.org> |
Add the resource index to aml_parse_resource() callback function.
This is needed by an upcoming acpiec commit that handles machines breaking the current ACPI specifications.
Change suggested by and
Add the resource index to aml_parse_resource() callback function.
This is needed by an upcoming acpiec commit that handles machines breaking the current ACPI specifications.
Change suggested by and ok kettenis@, guenther@
show more ...
|
#
14f07311 |
| 03-Aug-2016 |
jcs <jcs@openbsd.org> |
add a minimal TPM 1.2 driver just to issue a "save state" command before suspending, in order to fix suspend/resume on some newer machines.
more cleanup and TPM 2.0 support coming later.
earlier ve
add a minimal TPM 1.2 driver just to issue a "save state" command before suspending, in order to fix suspend/resume on some newer machines.
more cleanup and TPM 2.0 support coming later.
earlier version ok pirofti ok deraadt
show more ...
|