Commit Graph
87188 Commits
Author SHA1 Message Date
Luca Boccassi cd1f2f2ff9 sd-dlopen: make macros to generate .notes.dlopen sections public API (#41047)
If this new scheme of adding dependencies is supposed to be used more
widely we need to start making it easy to add them. So add a new
self-contained header that projects can simply include without the need
to link against libsystemd itself. This will allow them to generate
`.notes.dlopen` sections:

```
> readelf -p .note.dlopen ./l2md

String dump of section '.note.dlopen':
  [     a]  |@FDO
  [    10]  [{"feature":"manifest-json","description":"Manifest-based change detection via gzip and JSON parsing","priority":"suggested","soname":["libz.so.1","libsystemd.so.0"]}]
  [    c2]  |@FDO
  [    c8]  [{"feature":"manifest-http","description":"HTTP transport for lore.kernel.org manifest fetch","priority":"suggested","soname":["libcurl.so.4"]}]
```
2026-03-18 12:33:58 +00:00
Daan De Meyer 2e676fd636 ci: Allow all commands in claude-review workflow
claude is asking for permissions in the logs, let's grant it access
to execute all commands to avoid the permission denials.
2026-03-18 12:44:48 +01:00
Daan De Meyer 02ab8dfc4f ci: Enable unpriv user namespaces for claude-review
Required for bubblewrap to work properly.
2026-03-18 12:44:48 +01:00
Nandakumar Raghavan a4aae32478 ansi-color: fix SYSTEMD_COLORS=true regression when output is piped
The SYSTEMD_COLORS=true/1/yes no longer forced colors
when stdout was not a TTY (e.g. piped), because the COLOR_TRUE bypass
of the terminal_is_dumb() check was accidentally dropped.

Restore the old behavior by guarding the TTY check with
`m != COLOR_TRUE`, so an explicit boolean "true" value continues to
unconditionally force color output regardless of whether stdout is a TTY
or whether $NO_COLOR is set.
2026-03-18 12:03:38 +01:00
Daan De Meyer e9396ef165 ci: Bump number of turns for claude and mention turns in prompt
claude keeps failing by its subagents completing after it has already
written the review for large prs. It seems to run out of turns, tries
to get the subagents to post partial reviews but doesn't seem to stop
them.

Let's insist that it waits for background tasks to stop but let's also
increase the max turns a bit so it doesn't run out as quickly.
2026-03-18 12:00:48 +01:00
Daan De Meyer eef8f528a3 ci: Enable network isolation for claude and allow most tools
claude wants to use python to access the JSON context so let's allow
it. Since python3 basically allows you to reimplement every other tool,
let's just enable all tools except the web related ones but enable network
isolation so it can't try to exfiltrate anything via python.
2026-03-18 12:00:48 +01:00
Nandakumar Raghavan 36d129a7ad repart: add --grain-size= option for partition alignment
Add a --grain-size= CLI option to override the default 4 KiB partition
alignment grain. Setting --grain-size=1M matches the alignment used by
fdisk/parted and fixes misaligned partitions after small fixed-size
partitions like the 16 KiB verity-sig partition.

Also fix context_place_partitions() to re-align the start offset after
each partition, not just once per free area. Without this, a small
partition would cause all subsequent partitions in the same free area
to start at an unaligned offset.
2026-03-18 10:39:39 +00:00
Luca Boccassi 3236700a67 docs: update security policy to suggest GH advisories 2026-03-18 10:36:43 +00:00
Christian Brauner 919b8c7c92 sd-dlopen: relicense header to MIT-0
Relicense sd-dlopen.h from LGPL-2.1-or-later to MIT-0 so that
downstream projects can copy/paste the macros directly without
introducing a build dependency on the systemd headers.

Acked-by: Lennart Poettering <lennart@amutable.com>
Acked-by: Luca Boccassi <luca.boccassi@gmail.com>
Signed-off-by: Christian Brauner <brauner@kernel.org>
2026-03-18 10:28:11 +00:00
Christian Brauner f90ee22bcf man: add sd-dlopen(3) and SD_ELF_NOTE_DLOPEN(3) man pages
Document the new public sd-dlopen.h header and SD_ELF_NOTE_DLOPEN()
macro with associated constants. Includes usage examples for single
and multiple soname annotations.

Signed-off-by: Christian Brauner <brauner@kernel.org>
2026-03-18 10:28:11 +00:00
Christian Brauner 8b12350b75 dlfcn-util: migrate to public SD_ELF_NOTE_DLOPEN() API
Switch all internal callers from the private ELF_NOTE_DLOPEN() macro to
the new public SD_ELF_NOTE_DLOPEN() API from sd-dlopen.h, and remove
the now-redundant macro definitions from dlfcn-util.h.

Signed-off-by: Christian Brauner <brauner@kernel.org>
2026-03-18 10:28:11 +00:00
Christian Brauner e10302b6b6 sd-dlopen: add header-only public API for FDO .note.dlopen ELF metadata
Expose ELF note dlopen annotation macros as a public header-only API in
sd-dlopen.h. This allows any project to embed .note.dlopen metadata in
their ELF binaries by simply including the header - no runtime linkage
against libsystemd is required.

The header provides SD_ELF_NOTE_DLOPEN() and associated macros/constants
implementing the ELF dlopen metadata specification for declaring optional
shared library dependencies loaded via dlopen() at runtime.

Signed-off-by: Christian Brauner <brauner@kernel.org>
2026-03-18 10:28:11 +00:00
noxiouz 4c7af7d9d1 coredump: capture crashing thread ID and name
Add %I (TID in initial PID namespace) to the core_pattern, so the
kernel passes the crashing thread's TID to systemd-coredump. Use it
to read the thread's comm name from /proc/<tid>/comm and log both as
new journal fields:

  COREDUMP_TID=       — TID of the crashing thread
  COREDUMP_THREAD_NAME= — comm name of the crashing thread

These fields are also stored as xattrs on external coredump files
(user.coredump.tid, user.coredump.thread_name) and displayed by
coredumpctl info alongside the PID line.

For single-threaded processes the TID equals the PID and thread_name
equals comm; for multi-threaded programs with named worker threads
(pthread_setname_np / PR_SET_NAME) this identifies which thread
crashed without needing to open the coredump file itself.

The new fields are optional in the socket forwarding path, so older
systemd-coredump senders are handled gracefully.

Co-developed-by: Claude <claude@anthropic.com>
2026-03-18 10:27:27 +00:00
Lennart Poettering 8a2c423870 find-esp: introduce _full() flavour of ESP/XBOOTLDR discovery functions
These functions take so many return paramaters, and in many of our cases
we don't actually needt them. Hence introduce _full() flavours of the
funcs, and hide the params by default.
2026-03-18 10:25:59 +00:00
Daan De Meyer e87303d511 ci: Reduce retention for pr-context JSON file to a week
We don't need to keep this around fpr 90 days, let's keep it around
for a week.
2026-03-18 10:53:49 +01:00
Daan De Meyer 2967e89597 ci: Enable users without write action to the repo to access claude review
The labelling approach introduced in 6089075265
means contributors can now trigger the workflow on their own when the label
is added by a maintainer and they update the PR. Hence we need to allow all
users to access the claude code action. This is safe because we already gate
the workflow ourselves to only the contributors that we want to allow.
Additionally, the claude code job has no permissions anymore except read access
to the repository and can execute very limited tools, so this should be safe.
2026-03-18 10:53:49 +01:00
Daan De Meyer 2cada660de ci: Fix artifact name in claude-review workflow
The name doesn't actually matter, it gets replaced with the name
of the file when not archiving. So stop passing a name and pass in
the filename as the name when downloading the artifact.
2026-03-18 10:53:49 +01:00
Daan De Meyer b29f3bbfa8 ci: Use artifacts to pass around pr context
The current approach runs into issues on large prs:
https://github.com/systemd/systemd/actions/runs/23220105199/job/67490722033
2026-03-18 07:27:41 +01:00
Daan De Meyer f2210fda54 ci: Add issue comments to pr context for claude-review as well
Follow up for fb513a7e1c. The issue
comments are the regular comments left on the pr.
2026-03-17 23:48:54 +01:00
Daan De Meyer fb513a7e1c ci: Fetch context for claude-review job in setup job
Rather than have claude fetch the context itself, let's fetch the
context for it in the setup job. This has the following advantages:

- We can reduce the permissions granted to the claude job
- claude has less opportunity to mess up trying to fetch the context
  itself. Specifically, it keeps spawsning a background task to fetch
  the PR branch which messes up the structured output at the end, causing
  the review job to fail. By pre-fetching the context it won't have to
  spawn the background task. Additionally, we limit the git commands it
  can execute to local ones to ensure it doesn't try to fetch the PR branch.
  Finally, we fetch the branch ourselves as pr-review so claude can look at it
  to review the PR.
2026-03-17 22:54:38 +01:00
Luca Boccassi 0c71d20265 meson: switch version to 261~devel 2026-03-17 20:02:38 +00:00
Luca Boccassi 3e52279684 Finalize meson.version for v260 2026-03-17 19:53:49 +00:00
huchangzai d97896b647 hwdb: fix ABS_PRESSURE axis range for Goodix GXTP5100 touchpad
The Goodix GXTP5100 touchpad (HID bus 0x0018, vendor 0x27C6, product
0x01E9), found in the Lenovo ThinkBook 16 G7+ IAH and ThinkPad X9 15
Gen 1, has a kernel driver bug where ABS_PRESSURE (axis 24 / 0x18) is
reported with min=0, max=0.

This invalid axis range causes libinput to reject the device with:
  "kernel bug: ABS_PRESSURE has min == max (both 0)"

The touchpad hardware itself is functional and reports valid ranges for
all other axes:
  ABS_X:  min=0, max=4149, resolution=31
  ABS_Y:  min=0, max=2147, resolution=27
  ABS_MT_POSITION_X/Y: valid ranges

Root cause: the kernel hid-multitouch driver applies a "GT7868Q report
descriptor fixup" to this device (the HID descriptor is malformed and
fails hid-generic probe with EINVAL). The fixup corrects most axes but
leaves ABS_PRESSURE with an invalid 0:0 range.

This hwdb entry overrides ABS_PRESSURE to a valid 0:255 range, allowing
libinput to accept and initialize the device.

Kernel version: 6.17.0-19-generic
Device path: /sys/bus/hid/drivers/hid-multitouch/0018:27C6:01E9.0001
2026-03-17 19:53:34 +00:00
Luca Boccassi f49576e417 Chores for v260 (#41140) 2026-03-17 19:18:49 +00:00
Daan De Meyer 74bb7fc996 Two claude-review improvements (#41142) 2026-03-17 20:09:13 +01:00
Daan De Meyer 6089075265 ci: Allow attaching claude-review label to PRs for automatic review
- If a pr is labeled with claude-review, review it immediately
- If a pr labeled with claude-review is updated, review it regardless
of the author
- If a pr is opened by a maintainer, review it and add the claude-review
label. If the claude-review label is later removed, the pr won't be
auto-reviewed anymore.
2026-03-17 20:07:23 +01:00
Daan De Meyer b54d61e00b ci: Fix allowed tools in claude-review
Bash(gh:api *) wasn't actually working. Turns out the colon syntax
is deprecated and unnecessary. Let's stop using it which also fixes
the bug so that gh api calls are allowed now.
2026-03-17 19:46:31 +01:00
Antonio Alvarez Feijoo fb292e18d8 mkosi: fix typo in UKI profile title 2026-03-17 17:50:04 +00:00
Luca Boccassi 39ba090035 NEWS: finalize for v260 2026-03-17 17:41:20 +00:00
Luca Boccassi 166d91ad91 NEWS: update contributors list 2026-03-17 17:40:54 +00:00
Luca Boccassi ce48f694a0 Update hwdb
ninja -C build update-hwdb
2026-03-17 17:40:54 +00:00
Daan De MeyerandClaude Opus 4.6 58246e6408 ci: Add automatic review thread resolution to claude-review workflow
Claude now identifies which existing review comment threads should be
resolved (because the issue was addressed or someone disagreed) and
returns their REST API IDs in a new `resolve` array in the structured
output. The post job uses GraphQL to map comment IDs to threads and
resolve them.

Also switches all GitHub data fetching from MCP tools to `gh api` calls,
since the MCP tool strips comment IDs during its GraphQL-to-minimal
conversion and cannot be used for thread resolution.

The thread resolution GraphQL pagination is wrapped in a try/catch so
that a failure to fetch threads degrades gracefully instead of aborting
the entire post job. Unmatched comment IDs are logged for debuggability.

Adds explicit instructions to complete all data fetching before starting
review and to cancel background tasks before returning structured output,
working around a claude-code-action issue where a late-completing
background task triggers a new conversation turn that overwrites the
structured JSON result.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-17 18:40:32 +01:00
David Tardon 55bf0766a1 coccinelle: fix exclusion path
This file was moved 5 years ago...

Follow-up for commits 99b9f8fddd and
6dcabd5f5e .
2026-03-17 09:26:55 +00:00
dongshengyuan cccb77304b add-ug-bo-translation 2026-03-16 20:45:41 +01:00
Luca Boccassi c751714d8c man: document that with RuntimeDirecoryPreserve= dirs are under /run/private/
This is not immediately obvious so document it explicitly.

Follow-up for 40cd2ecc26
2026-03-16 20:26:33 +01:00
Daan De Meyer 3c0c557f6c ci: Review PRs per-commit and attach comments to correct commits (#41123) 2026-03-16 17:01:36 +01:00
Daan De Meyer 94a695d89a ci: Review PRs per-commit and attach comments to correct commits
Switch claude-review from reviewing the entire PR diff at once to
reviewing each commit individually via subagents. Each commit review
subagent receives the PR context, preceding commit diffs, and its own
commit diff, then returns comments tagged with the commit SHA. This
ensures review comments are attached to the correct commit via the
GitHub API rather than all pointing at HEAD.

Also add Bash(gh:*) to allowed tools so subagents can fetch per-commit
diffs via `gh api` without needing local git objects, and remove CI
analysis (needs to be delayed until CI finishes to be useful).

Co-developed-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-16 16:12:04 +01:00
Daan De Meyer 52c4aca21e ci: Revert side/subject_type change for claude review workflow
This doesn't seem to actually work, so revert the change.
2026-03-16 16:08:26 +01:00
Daan De Meyer 3a76c0959f ci: Fix several issues in claude-review workflow
Address feedback from facebook/bpfilter#472:

- Fix setFailed error message counting file-level comments (without
  line numbers) that are intentionally skipped, use inlineComments.length
  instead of comments.length
- Fix double severity prefix in inline comments: the prompt told Claude
  to prefix body with **must-fix**/etc but the post job also prepended
  "Claude: ", producing "Claude: **must-fix**: ...". Now the prompt says
  not to prefix and the post job adds "Claude **severity**: " using the
  structured severity field
- Move error tracking instructions to a top-level section after all phases
  so they apply to all runs, not just the first run
- Clarify that line is optional: use "should be" instead of "must be"
  and document that omitting line still surfaces the comment in the
  tracking comment summary
- Distinguish cancelled vs failed in tracking comment message
- Add side: "RIGHT" and subject_type: "line" to createReviewComment
  per GitHub API recommendations
- Downgrade partial inline comment posting failures to warnings; only
  fail the job when no comments at all could be posted

Co-developed-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-16 15:30:09 +01:00
Daan De Meyer a9ac5cdf18 ci: Update github-script action version to 8.0.0 in claude-review 2026-03-16 12:23:39 +01:00
Daan De Meyer b1c446a0b0 ci: Run claude-review workflow automatically on trusted PRs 2026-03-16 12:12:46 +01:00
Daan De Meyer 9e7a2793ad ci: Insist on structured output from claude-review workflow
In some cases claude is not outputting structured JSON at the end.
Let's modify the prompt a bit to hopefully mitigate the issue.
2026-03-16 11:53:40 +01:00
davidak bbd707a882 docs: document AI use disclosure consistently
The example also adds the model version to have it for reference.
2026-03-16 10:55:02 +01:00
Zbigniew Jędrzejewski-Szmek a988b9af95 ci: Fix several robustness issues in claude-review workflow (#41115)
- Use github.paginate() for listComments to handle PRs with 100+
comments
- Make line optional in review schema to allow file-level comments
- Skip createReviewComment for comments without a line number
- Fix failed count to exclude skipped file-level comments
- Pass review result via env var instead of expression injection
- Use core.warning() instead of console.log() for JSON parse failures
- Fix MARKER insertion for single-line summaries that have no newline
- Require "@claude review" instead of just "@claude" to trigger

Co-developed-by: Claude <claude@anthropic.com>
2026-03-16 09:55:50 +01:00
Daan De Meyer 7178e3829f ci: Fix several robustness issues in claude-review workflow
- Use github.paginate() for listComments to handle PRs with 100+ comments
- Make line optional in review schema to allow file-level comments
- Skip createReviewComment for comments without a line number
- Fix failed count to exclude skipped file-level comments
- Pass review result via env var instead of expression injection
- Use core.warning() instead of console.log() for JSON parse failures
- Fix MARKER insertion for single-line summaries that have no newline
- Require "@claude review" instead of just "@claude" to trigger

Co-developed-by: Claude <claude@anthropic.com>
2026-03-16 09:16:19 +01:00
Daan De Meyer 876d36f68a ci: Add full output from claude to debug intermittent failures 2026-03-15 21:47:21 +01:00
Frantisek Sumsal 6dcabd5f5e coccinelle: simplify file exclusions
Use Coccinelle's "depends on" directive to exclude files from certain
transformations. This should make them a bit simpler and possibly
faster, since we don't have to shell out to Python.

Unfortunately, this works only for file/directory exclusions. For
function and other more complex exclusions we still need to use Python,
at least for now.

Also, completely drop the file exclusion for man/ in the xsprintf
transformation, since we filter out everything under man/ before we even
run Coccinelle (in run-coccinelle.sh).
2026-03-14 23:56:53 +00:00
Luca Boccassi 1bbf72d770 meson: bump version to v260~rc4 2026-03-13 23:03:20 +00:00
Luca Boccassi 908dfa1164 NEWS: finalize place and date 2026-03-13 23:02:53 +00:00
Zbigniew Jędrzejewski-Szmek a0adf78f4d Importd: skip fifos and sockets (#41090) 2026-03-13 23:52:44 +01:00