Skip to content

Repair T1 Mac PCIe hotplug defaults - #10886

Open
Drecullith wants to merge 1 commit into
omacom:quattrofrom
Drecullith:fix/t1-pcie-hotplug-migration
Open

Repair T1 Mac PCIe hotplug defaults#10886
Drecullith wants to merge 1 commit into
omacom:quattrofrom
Drecullith:fix/t1-pcie-hotplug-migration

Conversation

@Drecullith

Copy link
Copy Markdown

Summary

Repair existing T1 Mac installations whose Limine configuration still contains pcie_ports=compat.

The earlier T2 migration replaces this parameter with:

pm_async=off mem_sleep_default=deep

but it is gated specifically on T2 hardware and operates on t2-mac.conf. Existing T1 MacBook installations can instead retain /etc/limine-entry-tool.d/macbook-t1.conf with the obsolete pcie_ports=compat setting.

On affected machines, that setting disables native PCIe hotplug and can prevent PCIe-tunneled devices behind a Thunderbolt dock from appearing even though the dock itself is authorized and DisplayPort passthrough works.

This adds a new migration rather than modifying the previous T2 migration, since systems that already completed that migration would not rerun it.

The new migration:

  • acts only when macbook-t1.conf exists;
  • replaces only pcie_ports=compat;
  • preserves all unrelated kernel parameters;
  • rebuilds the Limine boot image after changing the configuration;
  • records successful repair with a machine-wide marker;
  • retries the rebuild if configuration repair succeeded but the previous rebuild was interrupted;
  • leaves systems without the T1 configuration untouched;
  • leaves already-current systems untouched.

Fixes #10638.

Tests

Added test/shell.d/t1-pcie-hotplug-test.sh covering:

  • stale T1 configuration is migrated;
  • unrelated kernel parameters are preserved;
  • pcie_ports=compat is removed;
  • the Limine boot image is rebuilt;
  • repeated execution before reboot is idempotent;
  • an interrupted rebuild is retried without editing the configuration again;
  • systems without macbook-t1.conf are skipped;
  • already-current/running configurations are left unchanged.

Focused regression suite: 5/5 passing.

Also verified:

  • bash -n migrations/1788906000.sh
  • bash -n test/shell.d/t1-pcie-hotplug-test.sh

No physical T1 MacBook hardware was available for live verification. The issue reporter independently reports successful recovery after applying the equivalent kernel-command-line change and rebuilding Limine.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

T1 MacBook (macbook-t1.conf) still ships pcie_ports=compat, breaking Thunderbolt dock PCIe tunneling — migration 1785944594 only covers T2

1 participant