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

Commit 22e5f17e authored by Tomasz Wasilczyk's avatar Tomasz Wasilczyk
Browse files

Add background scan capability callback broadcast radio HAL.

Bug: b/34054813
Test: it builds.
Change-Id: Idf931f2f5fd280c0af6f0154170a79f7e57747ab
parent b01e1a8d
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -47,8 +47,8 @@ interface ITuner extends @1.0::ITuner {
     *
     * @return result OK if the scan was properly scheduled (this does not mean
     *                it successfully finished).
     *                TEMPORARILY_UNAVAILABLE if the background scan is
     *                temporarily unavailable, ie. due to ongoing foreground
     *                UNAVAILABLE if the background scan is unavailable,
     *                ie. temporarily due to ongoing foreground
     *                playback in single-tuner device.
     *                NOT_INITIALIZED other error, ie. HW failure.
     */
+9 −1
Original line number Diff line number Diff line
@@ -39,12 +39,20 @@ interface ITunerCallback extends @1.0::ITunerCallback {
     */
    oneway afSwitch_1_1(ProgramInfo info);

    /**
     * Called by the HAL when background scan feature becomes available or not.
     *
     * @param isAvailable true, if the tuner turned temporarily background-
     *                    capable, false in the other case.
     */
    oneway backgroundScanAvailable(bool isAvailable);

    /**
     * Called by the HAL when background scan initiated by startBackgroundScan
     * finishes. If the list was changed, programListChanged must be called too.
     * @param result OK if the scan succeeded, client may retrieve the actual
     *               list with ITuner::getProgramList.
     *               TEMPORARILY_UNAVAILABLE if the scan was interrupted due to
     *               UNAVAILABLE if the scan was interrupted due to
     *               hardware becoming temporarily unavailable.
     *               NOT_INITIALIZED other error, ie. HW failure.
     */
+1 −1
Original line number Diff line number Diff line
@@ -23,7 +23,7 @@ typedef @1.0::Result Result;
enum ProgramListResult : Result {
    NOT_READY,
    NOT_STARTED,
    TEMPORARILY_UNAVAILABLE,
    UNAVAILABLE,
};

/**
+4 −0
Original line number Diff line number Diff line
@@ -129,6 +129,10 @@ class BroadcastRadioHidlTest : public ::testing::VtsHalHidlTargetTestBase {
            return Void();
        }

        virtual Return<void> backgroundScanAvailable(bool isAvailable __unused) {
            return Void();
        }

        virtual Return<void> backgroundScanComplete(ProgramListResult result __unused) {
            return Void();
        }