Skip to content

Install the FaceTime HD camera driver on Intel Macs that have one - #12067

Merged
omarchybot merged 9 commits into
omacom:quattrofrom
MrBazzieB:fix/facetimehd
Nov 22, 2026
Merged

omarchybot merged 9 commits into
omacom:quattrofrom
MrBazzieB:fix/facetimehd

Conversation

@MrBazzieB

Copy link
Copy Markdown
Contributor

What

Detect the Broadcom FaceTime HD PCIe webcam (14e4:1570) and install facetimehd-firmware, facetimehd-data, and facetimehd-dkms during hardware setup. A migration covers existing installs.

This is the 720p camera in 2013–2015 Intel Macs (this machine is a MacBookPro12,1). There is no in-tree driver.

Packaging

facetimehd-dkms is not in [omarchy] yet. Please add it to the ISO/repo from current patjak/facetimehd master (after 54fb8f2), not AUR 0.7.0.2.

Linux 7.2 removed strncpy from the kernel API. AUR 0.7.0.2 still calls it in fthd_v4l2.c and DKMS fails on linux-omarchy 7.2 with:

error: implicit declaration of function ‘strncpy’

Upstream already guards that call for kernels >= 4.2. I compiled c5c7fac against 7.2.5-3-omarchy on this MacBook and it built cleanly.

Also cache facetimehd-firmware and facetimehd-data (already listed in omarchy-other.packages).

Test plan

  • test/shell.d/facetimehd-test.sh
  • ./test/cli
  • ISO/package: facetimehd-dkms from current git is in [omarchy]
  • On a Mac with 14e4:1570, modinfo facetimehd and /dev/video0 after install or omarchy update

The Broadcom 1570 has no in-tree driver. Detect PCI 14e4:1570 and install
facetimehd firmware, calibration data, and the DKMS module so new and
existing Omarchy Macs get /dev/video0 after setup or omarchy update.

The packaged facetimehd-dkms must be built from patjak/facetimehd after
54fb8f2; AUR 0.7.0.2 still calls strncpy and fails to compile on Linux 7.2.
@murdawkmedia

Copy link
Copy Markdown

Confirmed working on another supported Intel Mac, with one packaging update that may simplify this PR.

Test system:

  • MacBookAir6,2
  • Broadcom FaceTime HD Camera 14e4:1570
  • Omarchy 4.0.4-1
  • linux-omarchy 7.2.5-3

Installed and tested:

  • facetimehd-dkms 0.7.2-1
  • facetimehd-firmware 1:1.43_5-2
  • facetimehd-data 5.1.5769-2

DKMS built successfully for 7.2.5-3-omarchy, modprobe facetimehd initialized the ISP and created /dev/video0, and V4L2 identified it as Apple Facetime HD. A fresh capture completed 30/30 frames at 1280x720 YUYV and 29.97 fps. Installing facetimehd-data also supplied the requested 1871_01XX.dat calibration file, removing the missing-calibration warning.

The PR body's warning about stable AUR 0.7.0.2 appears to be stale now: the current stable package is 0.7.2-1 and compiles cleanly against Omarchy's 7.2.5 kernel. That may remove the need to package a separate current-master build in [omarchy].

Strong support for the PCI-ID-gated install and migration. The exact package set proposed here works on MacBookAir6,2 and produces real 720p video, not just a loaded module.

@drbree82

drbree82 commented Oct 3, 2026

Copy link
Copy Markdown

Hi,

I was working on PR #13192 which partially fixed this, but was late.

I have an A1466 with the Broadcom 14e4:1570 camera available for testing. The camera has already been verified manually on this machine: /dev/video0 appears and mpv captures 1280×720 at 30 fps. Once the package is available in [omarchy], I can validate it through a normal omarchy update.

@calebl

calebl commented Oct 4, 2026

Copy link
Copy Markdown

Tested on a MacBookPro12,1 (Early 2015 13"), 14e4:1570, running 7.2.5-3-omarchy.

On packaging: AUR facetimehd-dkms is now at 0.7.2 (updated Sep 17), and the 0.7.2 tag is exactly 54fb8f2. It built cleanly through DKMS against linux-omarchy 7.2.5-3 here, so [omarchy] can take the stock AUR recipe instead of a git snapshot.

On facetimehd-data: with only facetimehd-firmware and facetimehd-dkms installed, the driver logs Direct firmware load for facetimehd/1871_01XX.dat failed with error -2. After installing facetimehd-data and reloading the module, that error is gone and /dev/video0 captures at 1280×720. So including it in the leaf is correct.

Small note: the migration doesn't modprobe facetimehd, so on existing installs the camera only appears after a reboot. That may be fine, but it could be worth mentioning in the post-update output.

Happy to validate through omarchy update once the packages are in [omarchy].

@murdawkmedia

Copy link
Copy Markdown

Follow-up to the recent camera reports: I ran bash test/shell.d/facetimehd-test.sh against the exact PR revision 8bb9e8e663e5decc4bae299f8ba0177adb3fe256. All 7 checks passed, including detection with a large PCI listing, skipping unrelated hardware, and requesting firmware, calibration data, and DKMS from both the install script and migration.

bash test/cli also completed successfully at that revision, with 112 checks passed.

Fresh hardware retest on MacBookAir6,2, PCI 14e4:1570, Omarchy 4.0.4-1 and 7.2.5-3-omarchy:

  • facetimehd 0.7.2 is installed through DKMS for both the running Omarchy kernel and the installed Arch kernel. All files in the three camera packages are present.
  • A 300-frame V4L2 stream completed at 1280×720 YUYV and approximately 29.97 fps. Reopening the device for another 30 frames also succeeded. Frame data was discarded.
  • I ran the exact PR migration twice on the already-provisioned machine. Both runs detected the camera and returned success without a package transaction; the package log and camera device were unchanged.

This validates current capture and the already-installed migration path. A fresh package installation through a normal omarchy update remains untested.

The reboot observation matches the code at this revision: neither the install script nor migration calls modprobe facetimehd or prints a reboot reminder. A post-install message would help existing users understand why the camera may not appear immediately after updating.

One packaging detail for the remaining validation: this revision's omarchy-pkg-add invokes pacman -S; it does not fall back to AUR. The working AUR 0.7.2 recipe therefore still needs to be published in a configured binary repository before a fresh normal-update installation can pass. I have not verified current repository availability.

@omarchybot

Copy link
Copy Markdown
Collaborator

Reviewed at 8bb9e8e against quattro. The approach is right, but it can't land until facetimehd-firmware, facetimehd-data and facetimehd-dkms are published in [omarchy]. Until then it breaks the ISO build and fresh installs on these Macs, and it stalls omarchy update on them.

What was checked. On a disposable Omarchy VM (7.2.5-3-omarchy), ./test/cli passes, and so do facetimehd-test.sh (7/7), brcmfmac-supplicant-test.sh, t2-hardware-test.sh, migrate-scope-test.sh, migrate-wrapper-test.sh and unowned-system-paths-test.sh. The VM has no 1570 camera, so I stubbed lspci to report one and ran the leaf as root and the migration as the user, with the real omarchy-pkg-add:

  • On quattro, nothing installs the driver, which is the gap this PR fills.
  • On this head, the leaf and the migration both detect the camera and both exit 1 with error: target not found for all three packages. pacman -Si does not find them in any configured repository, and omacom/omarchy-pkgs has no recipe for them yet.

What that means if it merged today:

  • install/omarchy-other.packages:75-77 adds the three packages as offline-mirror targets. builder/build-iso.sh in omarchy-iso passes every name in that list to pacman explicitly, and a missing one fails with "target not found". So every ISO build would fail, including one for a machine with no camera.
  • install/hardware/apple/fix-facetimehd.sh:9: omarchy-apply-hardware sources install/hardware/all.sh under set -euo pipefail, so on a Mac with this camera, hardware setup aborts the install.
  • migrations/1789542390.sh: the migration fails, stays pending and stops the migration queue on every existing Mac with this camera.

None of this is a defect in this branch's code. It is an ordering dependency on packaging in another repository, which is the maintainer's call. That includes redistributing Apple's camera firmware, and which facetimehd-dkms to build: as @calebl notes above, AUR is now at 0.7.2, which is 54fb8f2. omacom/omarchy-pkgs#556 and #182 both propose recipes.

Smaller points, not pushed:

  • The migration installs the module but neither loads it nor sets reboot-required, so on an existing install the camera only appears after a reboot that nothing asks for. sudo modprobe facetimehd (best effort) or omarchy-state set reboot-required would close that.
  • The comment at fix-facetimehd.sh:1-4 names AUR 0.7.0.2, which is now stale.

Competing PRs. #11381 (older) targets the same camera. It installs from the AUR with omarchy-pkg-aur-add, which can't run as root during an ISO install, so a fresh install never gets the driver. This PR's omarchy-pkg-add route is the one that works on both paths once the packages exist, so this is the one to carry forward. #11381's best-effort live modprobe is worth taking. #7732 bundles the camera with audio and SPI for MacBookPro13,1 only, so it misses the 2013-2015 models this PR detects. Both also address #11373. I have not linked it here, because the fix hasn't been seen working on hardware.

Hardware. The camera itself could not be reproduced on a VM. The reports above from @drbree82 and @calebl were made with packages they built themselves, not from this head through [omarchy]. Once the packages are published, a test of this head on a 14e4:1570 Mac through omarchy update is what would verify it.

Second opinion: Codex Medium reviewed the same head. It agreed on the package dependency and on #11381's root-install gap (independence not guaranteed). It found on its own the ISO build failure, which I then confirmed in the omarchy-iso builder, and the missing module load. It also suggested making facetimehd-data optional. I have not taken that up, because the reports above say the driver logs a firmware-load error without it.

Next: this waits on the maintainer to publish the facetimehd packages in [omarchy]. After that, it needs a hardware confirmation of this head.

@murdawkmedia

Copy link
Copy Markdown

Follow-up to the October 7 packaging review at unchanged head 8bb9e8e.

The dependency is still visible in the available metadata: pacman -Si facetimehd-dkms facetimehd-firmware facetimehd-data finds none of the three in this machine's configured sync databases, and a fresh recursive tree read of omacom/omarchy-pkgs master contains no FaceTime recipe paths. #556 and #182 remain open package proposals. The live stable mirror database request returned HTTP 403, so I cannot claim a fresh mirror-level availability check from that request.

The earlier AUR/DKMS and camera-capture reports demonstrate that the hardware can work, but do not validate this PR's fresh binary-repository installation path. I have not repeated a physical Mac capture in this follow-up or run the installer on unrelated hardware.

Which package proposal should hardware testers follow for the coordinated install/update check? Once the binary packages are available, the remaining useful test is a normal install/update on 14e4:1570, including the module-load or reboot path already noted above.

@jandrusk

Copy link
Copy Markdown

Overlaps #11381 and the consolidator #12686 (Intel Mac P08). Also blocked on getting facetimehd-dkms into [omarchy] as you noted.

Suggest closing or redirecting energy into #12686 so we don't maintain three FaceTime install paths.

@omarchybot

Copy link
Copy Markdown
Collaborator

The head is unchanged since the review above (8bb9e8e), so this only covers what is new: #12686, and whether quattro has moved under it.

#12686 is not a reason to close this one. It carries this PR's change and adds an Apple DMI vendor check before the PCI match (install/hardware/apple/fix-facetimehd.sh:6-9 on its branch). The 14e4:1570 camera only ships in Macs, and nothing shows this PR installing the driver anywhere it shouldn't, so the extra check is a narrowing rather than a fix. It also installs the same three packages the same way, so it has the same packaging blocker. The older fix wins unless the newer one fixes a real defect in it, so this stays the one to carry forward. Nothing in #11381 or #7732 changes the earlier assessment. #12686's test showing that a failed package install leaves the migration pending, and that a retry completes it (test/shell.d/camera-consolidation-test.sh:66-91), is worth having here, but it is not needed for this to land.

Still blocked on packaging. facetimehd-firmware, facetimehd-data and facetimehd-dkms are still not in [omarchy], and omacom/omarchy-pkgs#556 and #182 are still open. The new first-boot hardware queue on quattro changes how a failed leaf is retried on an image install (it exits 75 and tries again next boot). It does not change the ISO build failure or the stuck migration described above. This is a read of the code, not a new run on a worker.

Who checked it: Codex Medium compared all four PRs separately, without being told my answer. It reached the same conclusion and found the migration-retry test in #12686 without being pointed to it. Independence is not guaranteed. It also re-read this head against the current quattro and found nothing that conflicts with or replaces it.

Next: this waits on the maintainer to publish the facetimehd packages, then on a hardware test of this head through omarchy update.

Apple's license for the camera's firmware and calibration files says they may not be copied or redistributed, so [omarchy] cannot publish facetimehd-firmware or facetimehd-data and the ISO cannot cache them. The leaf now installs facetimehd-dkms, which is GPL, and facetimehd-firmware-fetcher, which downloads the files from Apple on the Mac itself and checks each against a pinned hash. Its service retries at boot, so an install with no network gets the camera on the first boot that has one.

Each part is asked for only when pacman -T says nothing installed provides it, under its current name or the older bcwc-pcie ones. omarchy-pkg-add hands every name to pacman -S once any one is missing, so a Mac running an AUR driver would otherwise be asked to install facetimehd-dkms beside it, which conflicts, and fail the migration on every update.

The migration asks for a reboot when it installed something, since the module only loads at boot, starts the fetch rather than leaving it for that boot, and takes a current timestamp. Its checks leave the test, which covers the leaf the migration sources, since a migration runs once and its test stops guarding anything.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Co-Authored-By: Opus 5.5 High <[email protected]>
@greptile-apps

greptile-apps Bot commented Nov 21, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerView in GreptileConfidence Score: 5/5

[Medium impact] The reviewed changes appear safe to merge; no new actionable issue was established.

Summary

Adds FaceTime HD camera support for Intel Macs with the Broadcom 14e4:1570 device.

  • Omarchy sets up FaceTime HD cameras on matching Intel Macs.
  • Hibernating sleep unloads the camera driver and restores it after wake.

The earlier request for migration tests was withdrawn after omarchybot explained the testing approach and manual checks.

Diagram

%%{init: {'theme': 'neutral'}}%%
flowchart TD
  A[Hibernation requested] --> B[Take camera lock]
  B --> C{Driver loaded?}
  C -- No --> F[Hibernate]
  C -- Yes --> D{Driver unloads?}
  D -- No --> E[Cancel sleep and notify user]
  D -- Yes --> F
  F --> G[Resume or sleep ends]
  G --> H[Restore driver if unloaded]
  H --> I{Camera ready?}
  I -- Yes --> J[Clear sleep markers]
  I -- No --> K[Request fetcher retry]
Loading

Reviews (3) · Last reviewed commit: "Keep the wake step within the sleep unit..." · Reviewed by Greptile

Comment thread test/shell.d/facetimehd-test.sh Outdated
Comment on lines +119 to +124
run_leaf 1
grep -Fxq $'omarchy-pkg-add\tfacetimehd-dkms\tfacetimehd-firmware-fetcher' "$calls" ||
fail "leaf installs the DKMS module and the firmware fetcher" "$(cat "$calls")"
grep -Fxq "$fetcher_enabled" "$calls" ||
fail "leaf enables the fetch for a first boot with a network" "$(cat "$calls")"
pass "leaf installs the DKMS module and the firmware fetcher, and enables the fetch"

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Upgrade steps lack tests

These tests run the install leaf but never run migrations/1795284903.sh. They miss the reboot flag and service start that existing installs depend on, so those steps can break while the tests still pass. Add migration cases for matching hardware, already-installed packages, unmatched hardware, and package-install failure. Check the reboot flag and service-start calls.

Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not changed. Omarchy's migration guide says not to add tests for a migration under test/ (agents/skills/migrations.md: "It runs once per machine and is frozen once it ships, so the test stops guarding anything. If a migration needs logic worth testing, put that logic in a bin/ command the migration calls and test the command"), and the migration's checks were removed from this test for that reason. What it does beyond the leaf is set reboot-required when the leaf selected packages and start the fetch; both were exercised on a disposable Omarchy VM against real pacman, where the migration installed both packages, set the flag and started the service, which fetched the firmware. The leaf it sources, which holds the logic, is what facetimehd-test.sh covers. Checked by Claude Opus 5.5.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Got it — that makes sense. I wasn't aware of Omarchy's migration testing policy. If the migration sources a tested leaf and the one-time orchestration (flag + service start) was verified manually on a real system, that aligns with the project's approach of not adding tests for frozen, single-run migration scripts.

Based on your explanation, shall I remember this as a rule: "Do not flag missing tests for migrations under test/; Omarchy's policy is to test reusable logic (bin/ commands, install leaves) separately and verify the migration orchestration manually on real systems, since migrations run once per machine and are frozen after shipping"?

@omarchybot

Copy link
Copy Markdown
Collaborator

Reviewed the changes at a82c4bd against quattro, including the install leaf, migration, package list and previous discussion. This was a source review by Codex (GPT-6; reasoning effort not exposed to this session); no worker tests or camera capture ran, and no second opinion on the code ran.

I classified this as a hardware compatibility fix, but the classification model, deepseek-v4p1-flash, returned no usable classification. Triage therefore stops at the classification step, without adding verification or readiness labels. This waits on the maintainer to resolve classification before verification continues.

@omarchybot omarchybot removed bug Something isn't working compatibility Make Omarchy work better on everything! labels Nov 21, 2026
omarchybot and others added 7 commits November 21, 2026 22:30
The installer works offline, so the firmware is never fetched during the install: facetimehd-firmware-fetcher.service downloads it once the Mac has a network.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
facetimehd deadlocks the kernel's hibernation freeze. Unloading it from a system-sleep hook cannot help when an app has the camera open, because the unload is refused and systemd ignores a failing sleep hook, so hibernation went ahead and hung. omarchy-system-sleep-facetimehd now runs before and after the hibernating sleep units, from drop-ins the leaf installs: it unloads the driver, or fails the unit, which cancels the sleep, and notifies the person at the seat which app to close. After the sleep it loads the driver again if it unloaded it.

The leaf installs the guard on every Mac with the camera, including one that keeps an AUR driver, and asks for the fetcher whenever nothing provides the firmware itself: calibration from the AUR facetimehd-data is left alone by the fetcher rather than standing in for firmware.bin. The manual says how hibernation behaves and how to retry the fetch.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Co-Authored-By: Codex XHigh <[email protected]>
…e's first boot

facetimehd-firmware-fetcher loads the camera driver once it has the firmware. The hibernation guard now unloads and reloads it under the same /run/lock/facetimehd.lock, and leaves its marker at the path the fetcher reads, so a fetch finishing mid-sleep cannot put the driver back before hibernating.

An image's first boot runs the leaf after boot has queued its units, so enabling the fetch left it for the next boot; there it starts now, as the Bluetooth leaf starts its service. The manual says hibernation on a critical battery and suspend-then-hibernate are refused too, and describes the fetch's retries rather than promising a time.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Co-Authored-By: Codex XHigh <[email protected]>
…the driver

The guard left no trace when the driver was not loaded, so a firmware fetch finishing between pre and the freeze could load it and hibernation went ahead with it. pre now marks the sleep in progress under the shared lock whatever it finds, and records separately whether it unloaded the driver; a fetch that finishes meanwhile asks for the load, and post makes it with the restore it owes. The manual names the driver's own refusal of ordinary suspend while the camera is open, and that a changed download stops the retries.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Co-Authored-By: Codex XHigh <[email protected]>
The guard loaded the driver on wake for a fetch that finished mid-sleep and dropped the request if that load failed, leaving nothing to retry it. The fetcher now keeps its activation pending through the sleep, and post starts its service, which loads and verifies the camera and retries until it works. A driver post fails to reload becomes that pending activation too. post waits for the shared lock rather than going on without it, since the fetcher holds it only while it loads the driver.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Co-Authored-By: Codex XHigh <[email protected]>
…loaded

A module loads even when its device fails to probe, so post took a successful modprobe for a working camera. It now waits briefly for the 1570 to be bound and to register a video device, and hands a camera that does not come back to the fetcher as pending activation, as it already did a module that would not load.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Co-Authored-By: Codex XHigh <[email protected]>
The hibernating sleep units give ExecStopPost 5 s, and post waited for the camera to come back and for the driver lock without bound, so systemd killed it mid-wait and left the sleep marked in progress with nothing restored. The drop-in raises the units' stop timeout to 30 s, post waits at most 10 s for the lock and 2 s for the camera, and anything longer is the fetcher's: a camera not back yet, or a lock it could not get, becomes pending activation and starts the fetcher, with the shared markers left untouched when post holds no lock.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Co-Authored-By: Codex XHigh <[email protected]>
@omarchybot

Copy link
Copy Markdown
Collaborator

Read the updated head aa8c505 against quattro, including the hibernation guard and drop-in, install leaf, migration, package list, manual and tests, alongside the previous discussion. This was a source review by Codex (GPT-6; reasoning effort not exposed to this session). No worker tests or camera capture ran, and no second opinion on the code ran.

I classified this as a hardware compatibility fix, but the configured classification model, deepseek-v4p1-flash, again supplied no usable classification. Classification therefore remains unresolved at this new head, and the queue workflow stops before verification. This waits on the maintainer to resolve classification; verification and readiness remain pending.

@omarchybot

Copy link
Copy Markdown
Collaborator

I pushed commits on top of yours, up to aa8c505. The packages this needed can't be published as they were, so the change now installs a driver plus a firmware fetcher, and guards hibernation.

What was wrong

  • Apple's license. It says the camera's firmware and calibration files may not be copied or redistributed, so [omarchy] cannot publish facetimehd-firmware or facetimehd-data, and the ISO cannot cache them. Add facetimehd-dkms and a fetcher for the FaceTime HD firmware omarchy-pkgs#3215 adds facetimehd-dkms and facetimehd-firmware-fetcher instead, neither containing an Apple file. The fetcher downloads firmware 5.60.0 and all eleven calibration files from Apple's own macOS 10.12.6 update, on the Mac that has the camera, checking each against patjak/facetimehd-firmware's hashes.
  • Driver 0.7.2. The tag tears the device down on suspend while an app holds the camera open, and misses calibration for some sensors. The package builds upstream's master instead, with one patch for a failed resume.
  • Hibernation. As Install the pre-T2 FaceTime HD camera driver and firmware #11381 found, the driver hangs hibernation.

What changed here

  • The leaf installs facetimehd-dkms and facetimehd-firmware-fetcher and enables the fetch. It asks for each only when nothing installed already provides it, so a Mac running an AUR driver or firmware keeps it rather than failing on a conflict. On an image's first boot it starts the fetch rather than leaving it to the next boot.
  • The ISO list carries those two packages and nothing of Apple's. The install never touches the network: the camera arrives once the Mac is online.
  • Hibernation is guarded. omarchy-system-sleep-facetimehd runs before and after every hibernating sleep, on every Mac with the camera, whichever package provides the driver.
    • It unloads the driver first.
    • While an app has the camera open, it refuses: the sleep is cancelled, with a notification naming the app.
    • After the sleep it brings the camera back, and hands anything that does not come back to the fetcher to retry.
    • It shares a lock with the fetcher, so a fetch finishing mid-sleep never loads the driver before the freeze.
  • The migration sets reboot-required when it installed something, starts the fetch, and has a current timestamp. Its checks moved to the leaf it sources, since a migration isn't tested under test/.
  • The manual says how the firmware arrives, how hibernation and suspend behave with the camera open, and how to retry the fetch.

What was checked

On disposable Omarchy VMs running linux-omarchy 7.2.15, with this branch merged onto current quattro, facetimehd-test.sh (18 checks), ./test/cli and shellcheck pass, and both packages build. DKMS builds the patched driver. Then:

  • Offline install: the leaf, with no network at all, installed both packages, built the driver and enabled the fetch in 10 seconds.
  • Fetching: the service fetched all twelve files, byte-identical to upstream's. A deferred first boot loaded the driver on that same boot.
  • Hibernation: a busy camera cancelled the sleep before it started, and the notification appeared on the desktop. An idle camera was unloaded and restored. A fetch during a hibernating sleep deferred, then completed on wake.
  • Existing AUR drivers: a Mac with an AUR -git or bcwc-pcie driver keeps it.

The VMs have no camera, so nothing has run against real hardware. Capture rests on @murdawkmedia's and @calebl's reports above, which used the same driver line.

Who checked it

Claude Opus 5.5 did the work. Opus 5.5 High reviewed the first design, and Codex XHigh reviewed the whole of it over seven rounds. Most of the changes above answer Codex's findings rather than agree with mine, and its last round found nothing left to fix. Independence between the models is not guaranteed.

Next

This waits on the maintainer: #3215 publishes first, and omacom/omarchy-iso#498 keeps the two packages off aarch64 builds. Then a test on a real 1570 Mac through omarchy update is what would confirm it: capture, suspend and resume, hibernate and resume, and the busy-camera refusal. @drbree82 and @calebl offered one.

@omarchybot
omarchybot merged commit 02bc391 into omacom:quattro Nov 22, 2026
1 check passed
cursor Bot pushed a commit to mark-groves/omarchy that referenced this pull request Nov 22, 2026
…acom#12067)

* Install the FaceTime HD camera driver on Intel Macs that have one

The Broadcom 1570 has no in-tree driver. Detect PCI 14e4:1570 and install
facetimehd firmware, calibration data, and the DKMS module so new and
existing Omarchy Macs get /dev/video0 after setup or omarchy update.

The packaged facetimehd-dkms must be built from patjak/facetimehd after
54fb8f2; AUR 0.7.0.2 still calls strncpy and fails to compile on Linux 7.2.

* Fetch the FaceTime HD firmware from Apple rather than shipping it

Apple's license for the camera's firmware and calibration files says they may not be copied or redistributed, so [omarchy] cannot publish facetimehd-firmware or facetimehd-data and the ISO cannot cache them. The leaf now installs facetimehd-dkms, which is GPL, and facetimehd-firmware-fetcher, which downloads the files from Apple on the Mac itself and checks each against a pinned hash. Its service retries at boot, so an install with no network gets the camera on the first boot that has one.

Each part is asked for only when pacman -T says nothing installed provides it, under its current name or the older bcwc-pcie ones. omarchy-pkg-add hands every name to pacman -S once any one is missing, so a Mac running an AUR driver would otherwise be asked to install facetimehd-dkms beside it, which conflicts, and fail the migration on every update.

The migration asks for a reboot when it installed something, since the module only loads at boot, starts the fetch rather than leaving it for that boot, and takes a current timestamp. Its checks leave the test, which covers the leaf the migration sources, since a migration runs once and its test stops guarding anything.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Co-Authored-By: Opus 5.5 High <[email protected]>

* Say the camera firmware arrives once the Mac is online

The installer works offline, so the firmware is never fetched during the install: facetimehd-firmware-fetcher.service downloads it once the Mac has a network.

Co-Authored-By: Claude Opus 5.5 <[email protected]>

* Refuse hibernation while the FaceTime HD camera is in use

facetimehd deadlocks the kernel's hibernation freeze. Unloading it from a system-sleep hook cannot help when an app has the camera open, because the unload is refused and systemd ignores a failing sleep hook, so hibernation went ahead and hung. omarchy-system-sleep-facetimehd now runs before and after the hibernating sleep units, from drop-ins the leaf installs: it unloads the driver, or fails the unit, which cancels the sleep, and notifies the person at the seat which app to close. After the sleep it loads the driver again if it unloaded it.

The leaf installs the guard on every Mac with the camera, including one that keeps an AUR driver, and asks for the fetcher whenever nothing provides the firmware itself: calibration from the AUR facetimehd-data is left alone by the fetcher rather than standing in for firmware.bin. The manual says how hibernation behaves and how to retry the fetch.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Co-Authored-By: Codex XHigh <[email protected]>

* Share the driver lock with the fetcher and start the fetch on an image's first boot

facetimehd-firmware-fetcher loads the camera driver once it has the firmware. The hibernation guard now unloads and reloads it under the same /run/lock/facetimehd.lock, and leaves its marker at the path the fetcher reads, so a fetch finishing mid-sleep cannot put the driver back before hibernating.

An image's first boot runs the leaf after boot has queued its units, so enabling the fetch left it for the next boot; there it starts now, as the Bluetooth leaf starts its service. The manual says hibernation on a critical battery and suspend-then-hibernate are refused too, and describes the fetch's retries rather than promising a time.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Co-Authored-By: Codex XHigh <[email protected]>

* Mark every hibernating sleep in progress, not only one that unloaded the driver

The guard left no trace when the driver was not loaded, so a firmware fetch finishing between pre and the freeze could load it and hibernation went ahead with it. pre now marks the sleep in progress under the shared lock whatever it finds, and records separately whether it unloaded the driver; a fetch that finishes meanwhile asks for the load, and post makes it with the restore it owes. The manual names the driver's own refusal of ordinary suspend while the camera is open, and that a changed download stops the retries.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Co-Authored-By: Codex XHigh <[email protected]>

* Resume the fetcher's activation on wake instead of loading for it

The guard loaded the driver on wake for a fetch that finished mid-sleep and dropped the request if that load failed, leaving nothing to retry it. The fetcher now keeps its activation pending through the sleep, and post starts its service, which loads and verifies the camera and retries until it works. A driver post fails to reload becomes that pending activation too. post waits for the shared lock rather than going on without it, since the fetcher holds it only while it loads the driver.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Co-Authored-By: Codex XHigh <[email protected]>

* Check the camera came back after the sleep, not only that the driver loaded

A module loads even when its device fails to probe, so post took a successful modprobe for a working camera. It now waits briefly for the 1570 to be bound and to register a video device, and hands a camera that does not come back to the fetcher as pending activation, as it already did a module that would not load.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Co-Authored-By: Codex XHigh <[email protected]>

* Keep the wake step within the sleep unit's stop budget

The hibernating sleep units give ExecStopPost 5 s, and post waited for the camera to come back and for the driver lock without bound, so systemd killed it mid-wait and left the sleep marked in progress with nothing restored. The drop-in raises the units' stop timeout to 30 s, post waits at most 10 s for the lock and 2 s for the camera, and anything longer is the fetcher's: a camera not back yet, or a lock it could not get, becomes pending activation and starts the fetcher, with the shared markers left untouched when post holds no lock.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Co-Authored-By: Codex XHigh <[email protected]>

---------

Co-authored-by: omarchybot <[email protected]>
Co-authored-by: Claude Opus 5.5 <[email protected]>
Co-authored-by: Codex XHigh <[email protected]>
@emirb emirb added this to the 4.6.0 milestone Dec 1, 2026
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.

7 participants