{"id":18519300,"url":"https://github.com/linux-surface/surface-gpe","last_synced_at":"2026-05-18T03:06:15.166Z","repository":{"id":38236955,"uuid":"286816350","full_name":"linux-surface/surface-gpe","owner":"linux-surface","description":"Surface GPE/Lid driver to enable wakeup from suspend via the lid.","archived":false,"fork":false,"pushed_at":"2023-03-12T00:12:33.000Z","size":98,"stargazers_count":0,"open_issues_count":1,"forks_count":2,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-05-14T16:17:37.551Z","etag":null,"topics":["driver","linux","linux-surface"],"latest_commit_sha":null,"homepage":"","language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/linux-surface.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2020-08-11T18:14:10.000Z","updated_at":"2023-12-28T11:17:07.000Z","dependencies_parsed_at":"2025-05-14T16:17:38.946Z","dependency_job_id":null,"html_url":"https://github.com/linux-surface/surface-gpe","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/linux-surface%2Fsurface-gpe","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/linux-surface%2Fsurface-gpe/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/linux-surface%2Fsurface-gpe/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/linux-surface%2Fsurface-gpe/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/linux-surface","download_url":"https://codeload.github.com/linux-surface/surface-gpe/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254179904,"owners_count":22027884,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["driver","linux","linux-surface"],"created_at":"2024-11-06T17:16:00.690Z","updated_at":"2025-09-26T13:27:12.821Z","avatar_url":"https://github.com/linux-surface.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Linux kernel driver for GPE/Lid of Microsoft Surface Devices\n\n Surface GPE/Lid driver to enable wakeup from suspend via the lid.\n\n Conventionally, wake-up events for a specific device, e.g. the lid device, are managed via the ACPI `_PRW` field.\n While this does not seem strictly necessary based on ACPI spec, since commit [`941d3e41da7f86bdb9dcc1977c2bcc6b89bfe47 (ACPI: EC / PM: Disable non-wakeup GPEs for suspend-to-idle)`](https://lkml.org/lkml/2018/12/17/224) the kernel disables GPE wakeups to avoid non-wakeup interrupts preventing suspend by default and only enables GPEs associated via the `_PRW` field with a wake-up capable device.\n\n As there is no `_PRW` field on the lid device of MS Surface devices, we have to enable those GPEs ourselves as a workaround.\n\n## Testing and Installing\n\nNote: You normally do not need to manually install these module if you are already using a kernel from https://github.com/linux-surface/linux-surface.\n\n### Build/Test the module\n\nYou can build the module by running `make` inside the `module/` directory.\nAfter that, you can load the module by running `insmod surface_gpe.ko` and remove it by running `rmmod surface_gpe`.\n\n### Permanently install the module\n\nIf you want to permanently install the module (or ensure it is loaded during boot), you can run `make dkms-install`.\nTo uninstall it, run `make dkms-uninstall`.\nIn case you've installed a patched kernel already contiaining the in-kernel version of this module, dkms should detect this and override the in-kernel module with the externally built one.\nThis should get reverted by uninstalling the module via the command above.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flinux-surface%2Fsurface-gpe","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flinux-surface%2Fsurface-gpe","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flinux-surface%2Fsurface-gpe/lists"}