Skip to content

Merge - #5

Merged
daglaroglou merged 13 commits into
ACKfrom
DAG
Jun 29, 2026
Merged

Merge#5
daglaroglou merged 13 commits into
ACKfrom
DAG

Conversation

@daglaroglou

Copy link
Copy Markdown
Owner

No description provided.

jimsterino98 and others added 13 commits June 22, 2026 08:06
Updated the build process to conditionally use different setup scripts based on the 'susfs' input. Removed commented-out code related to patch applications and adjusted the BBRv3 patch application method.
apply patch to fix KSUN and added Image to compile ONLY the kernel image for kernel
updated hashes and switch to official ksun rather than pershoots fork
Refactor build_kernels.yml by commenting out the cloning and patching steps for Droidspaces-OSS, and streamline kernel configuration options.
@daglaroglou
daglaroglou merged commit 5324bab into ACK Jun 29, 2026
4 checks passed

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Code Review

This pull request updates the changelog, transitions pm_get_active_wakeup_sources to use SRCU read locks with added input validation, and adjusts the wakeup event duration in alarmtimer_suspend to be dynamic. Feedback highlights two key issues: first, a potential unsigned underflow in alarmtimer.c if min is negative, which can be resolved by using max_t to guarantee a minimum duration of 1 millisecond; second, the use of the non-standard list_for_each_entry_rcu_locked macro in wakeup.c should be replaced with the standard list_for_each_entry_rcu to prevent compilation or lockdep issues.

Important

The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.

Comment thread kernel/time/alarmtimer.c

if (ktime_to_ns(min) < 2 * NSEC_PER_SEC) {
pm_wakeup_event(dev, 2 * MSEC_PER_SEC);
pm_wakeup_event(dev, ktime_to_ms(min) + 1);

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

high

If min is negative (e.g., if the alarm has already expired), ktime_to_ms(min) will return a negative value. Since pm_wakeup_event expects an unsigned int for the millisecond duration, passing a negative value will result in an extremely large wakeup duration (due to unsigned underflow), preventing the system from suspending. Use max_t to ensure the duration is at least 1 millisecond.

        pm_wakeup_event(dev, max_t(s64, 0, ktime_to_ms(min)) + 1);

pending_wakeup_source[0] = '\0';

srcuidx = srcu_read_lock(&wakeup_srcu);
list_for_each_entry_rcu_locked(ws, &wakeup_sources, entry) {

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

medium

The macro list_for_each_entry_rcu_locked is non-standard and may cause compilation failures or lockdep issues. Since we are holding the SRCU read lock (srcu_read_lock), the standard list_for_each_entry_rcu macro should be used instead.

    list_for_each_entry_rcu(ws, &wakeup_sources, entry) {

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