Skip to content

Conversation

@likewhatevs
Copy link
Contributor

Add a matcher to layered to match cgroups which contain a specified substring.

seems to work w/ test json:
image

Add a matcher to layered to match cgroups which
contain a specified substring.
@likewhatevs
Copy link
Contributor Author

Copy pasta of match_prefix_suffix is because I don't think there's a way to pack more into that fn w/o making the verifier sad.

#define trace(fmt, args...) do { if (debug > 1) bpf_printk(fmt, ##args); } while (0)

bool match_prefix_suffix(const char *prefix, const char *str, bool match_suffix);
enum MatchType {
Copy link
Contributor

Choose a reason for hiding this comment

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

nice!

Copy link
Contributor

@hodgesds hodgesds left a comment

Choose a reason for hiding this comment

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

LGTM

@likewhatevs likewhatevs added this pull request to the merge queue May 28, 2025
Merged via the queue into sched-ext:main with commit cad4610 May 28, 2025
16 checks passed
@likewhatevs likewhatevs deleted the layered-cgrp-contains branch May 28, 2025 15:45
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.

2 participants