Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b1cfd35b authored by Android Build Coastguard Worker's avatar Android Build Coastguard Worker
Browse files

Snap for 11124398 from 8e34a47a to 24Q1-release

Change-Id: I6edc7cf72d763aa30d3554dc92be5e5a32e0db54
parents 06b248b2 8e34a47a
Loading
Loading
Loading
Loading
+0 −18
Original line number Original line Diff line number Diff line
@@ -33157,7 +33157,6 @@ package android.os {
  public static class PerformanceHintManager.Session implements java.io.Closeable {
  public static class PerformanceHintManager.Session implements java.io.Closeable {
    method public void close();
    method public void close();
    method public void reportActualWorkDuration(long);
    method public void reportActualWorkDuration(long);
    method @FlaggedApi("android.os.adpf_gpu_report_actual_work_duration") public void reportActualWorkDuration(@NonNull android.os.WorkDuration);
    method @FlaggedApi("android.os.adpf_prefer_power_efficiency") public void setPreferPowerEfficiency(boolean);
    method @FlaggedApi("android.os.adpf_prefer_power_efficiency") public void setPreferPowerEfficiency(boolean);
    method public void setThreads(@NonNull int[]);
    method public void setThreads(@NonNull int[]);
    method public void updateTargetWorkDuration(long);
    method public void updateTargetWorkDuration(long);
@@ -33500,7 +33499,6 @@ package android.os {
    method public static boolean setCurrentTimeMillis(long);
    method public static boolean setCurrentTimeMillis(long);
    method public static void sleep(long);
    method public static void sleep(long);
    method public static long uptimeMillis();
    method public static long uptimeMillis();
    method @FlaggedApi("android.os.adpf_gpu_report_actual_work_duration") public static long uptimeNanos();
  }
  }
  public class TestLooperManager {
  public class TestLooperManager {
@@ -33766,22 +33764,6 @@ package android.os {
    method @RequiresPermission(android.Manifest.permission.VIBRATE) public final void vibrate(@NonNull android.os.CombinedVibration, @Nullable android.os.VibrationAttributes);
    method @RequiresPermission(android.Manifest.permission.VIBRATE) public final void vibrate(@NonNull android.os.CombinedVibration, @Nullable android.os.VibrationAttributes);
  }
  }
  @FlaggedApi("android.os.adpf_gpu_report_actual_work_duration") public final class WorkDuration implements android.os.Parcelable {
    ctor public WorkDuration();
    ctor public WorkDuration(long, long, long, long);
    method public int describeContents();
    method public long getActualCpuDurationNanos();
    method public long getActualGpuDurationNanos();
    method public long getActualTotalDurationNanos();
    method public long getWorkPeriodStartTimestampNanos();
    method public void setActualCpuDurationNanos(long);
    method public void setActualGpuDurationNanos(long);
    method public void setActualTotalDurationNanos(long);
    method public void setWorkPeriodStartTimestampNanos(long);
    method public void writeToParcel(@NonNull android.os.Parcel, int);
    field @NonNull public static final android.os.Parcelable.Creator<android.os.WorkDuration> CREATOR;
  }
  public class WorkSource implements android.os.Parcelable {
  public class WorkSource implements android.os.Parcelable {
    ctor public WorkSource();
    ctor public WorkSource();
    ctor public WorkSource(android.os.WorkSource);
    ctor public WorkSource(android.os.WorkSource);
+13 −2
Original line number Original line Diff line number Diff line
@@ -721,8 +721,19 @@ public abstract class DisplayManagerInternal {
    public interface DisplayOffloadSession {
    public interface DisplayOffloadSession {
        /** Provide the display state to use in place of state DOZE. */
        /** Provide the display state to use in place of state DOZE. */
        void setDozeStateOverride(int displayState);
        void setDozeStateOverride(int displayState);
        /** Returns the associated DisplayOffloader. */

        DisplayOffloader getDisplayOffloader();
        /** Whether the session is active. */
        boolean isActive();

        /**
         * Update the brightness from the offload chip.
         * @param brightness The brightness value between {@link PowerManager.BRIGHTNESS_MIN} and
         *                   {@link PowerManager.BRIGHTNESS_MAX}, or
         *                   {@link PowerManager.BRIGHTNESS_INVALID_FLOAT} which removes
         *                   the brightness from offload. Other values will be ignored.
         */
        void updateBrightness(float brightness);

        /** Returns whether displayoffload supports the given display state. */
        /** Returns whether displayoffload supports the given display state. */
        static boolean isSupportedOffloadState(int displayState) {
        static boolean isSupportedOffloadState(int displayState) {
            return Display.isSuspendedState(displayState);
            return Display.isSuspendedState(displayState);
+0 −13
Original line number Original line Diff line number Diff line
@@ -23,7 +23,6 @@ import android.content.Context;
import android.os.IBinder;
import android.os.IBinder;
import android.os.ServiceManager;
import android.os.ServiceManager;


import com.android.net.flags.Flags;
import com.android.net.module.util.PermissionUtils;
import com.android.net.module.util.PermissionUtils;
/**
/**
 * Constants and utilities for client code communicating with the network stack service.
 * Constants and utilities for client code communicating with the network stack service.
@@ -104,16 +103,4 @@ public class NetworkStack {
            final @NonNull String... otherPermissions) {
            final @NonNull String... otherPermissions) {
        PermissionUtils.enforceNetworkStackPermissionOr(context, otherPermissions);
        PermissionUtils.enforceNetworkStackPermissionOr(context, otherPermissions);
    }
    }

    /**
     * Get setting of the "set_data_saver_via_cm" flag.
     *
     * @hide
     */
    // A workaround for aconfig. Currently, aconfig value read from platform and mainline code can
    // be inconsistent. To avoid the problem, CTS for mainline code can get the flag value by this
    // method.
    public static boolean getDataSaverViaCmFlag() {
        return Flags.setDataSaverViaCm();
    }
}
}
+0 −3
Original line number Original line Diff line number Diff line
@@ -17,8 +17,6 @@


package android.os;
package android.os;


import android.os.WorkDuration;

/** {@hide} */
/** {@hide} */
oneway interface IHintSession {
oneway interface IHintSession {
    void updateTargetWorkDuration(long targetDurationNanos);
    void updateTargetWorkDuration(long targetDurationNanos);
@@ -26,5 +24,4 @@ oneway interface IHintSession {
    void close();
    void close();
    void sendHint(int hint);
    void sendHint(int hint);
    void setMode(int mode, boolean enabled);
    void setMode(int mode, boolean enabled);
    void reportActualWorkDuration2(in WorkDuration[] workDurations);
}
}
+1 −38
Original line number Original line Diff line number Diff line
@@ -103,7 +103,7 @@ public final class PerformanceHintManager {
     * Any call in this class will change its internal data, so you must do your own thread
     * Any call in this class will change its internal data, so you must do your own thread
     * safety to protect from racing.
     * safety to protect from racing.
     *
     *
     * All timings should be in {@link SystemClock#uptimeNanos()}.
     * All timings should be in {@link SystemClock#elapsedRealtimeNanos()}.
     */
     */
    public static class Session implements Closeable {
    public static class Session implements Closeable {
        private long mNativeSessionPtr;
        private long mNativeSessionPtr;
@@ -269,40 +269,6 @@ public final class PerformanceHintManager {
        public @Nullable int[] getThreadIds() {
        public @Nullable int[] getThreadIds() {
            return nativeGetThreadIds(mNativeSessionPtr);
            return nativeGetThreadIds(mNativeSessionPtr);
        }
        }

        /**
         * Reports the work duration for the last cycle of work.
         *
         * The system will attempt to adjust the core placement of the threads within the thread
         * group and/or the frequency of the core on which they are run to bring the actual duration
         * close to the target duration.
         *
         * @param workDuration the work duration of each component.
         * @throws IllegalArgumentException if work period start timestamp is not positive, or
         *         actual total duration is not positive, or actual CPU duration is not positive,
         *         or actual GPU duration is negative.
         */
        @FlaggedApi(Flags.FLAG_ADPF_GPU_REPORT_ACTUAL_WORK_DURATION)
        public void reportActualWorkDuration(@NonNull WorkDuration workDuration) {
            if (workDuration.mWorkPeriodStartTimestampNanos <= 0) {
                throw new IllegalArgumentException(
                    "the work period start timestamp should be positive.");
            }
            if (workDuration.mActualTotalDurationNanos <= 0) {
                throw new IllegalArgumentException("the actual total duration should be positive.");
            }
            if (workDuration.mActualCpuDurationNanos <= 0) {
                throw new IllegalArgumentException("the actual CPU duration should be positive.");
            }
            if (workDuration.mActualGpuDurationNanos < 0) {
                throw new IllegalArgumentException(
                    "the actual GPU duration should be non negative.");
            }
            nativeReportActualWorkDuration(mNativeSessionPtr,
                    workDuration.mWorkPeriodStartTimestampNanos,
                    workDuration.mActualTotalDurationNanos,
                    workDuration.mActualCpuDurationNanos, workDuration.mActualGpuDurationNanos);
        }
    }
    }


    private static native long nativeAcquireManager();
    private static native long nativeAcquireManager();
@@ -319,7 +285,4 @@ public final class PerformanceHintManager {
    private static native void nativeSetThreads(long nativeSessionPtr, int[] tids);
    private static native void nativeSetThreads(long nativeSessionPtr, int[] tids);
    private static native void nativeSetPreferPowerEfficiency(long nativeSessionPtr,
    private static native void nativeSetPreferPowerEfficiency(long nativeSessionPtr,
            boolean enabled);
            boolean enabled);
    private static native void nativeReportActualWorkDuration(long nativeSessionPtr,
            long workPeriodStartTimestampNanos, long actualTotalDurationNanos,
            long actualCpuDurationNanos, long actualGpuDurationNanos);
}
}
Loading