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

Commit ef168ceb authored by sqian's avatar sqian Committed by android-build-merger
Browse files

Add Emergency Call Routing in HAL am: 61424080

am: e73482f8

Change-Id: Id1ac4a3ad19aa5ca2c7b8ca7fe5178a9dd6b2506
parents 3a801d42 e73482f8
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -30,6 +30,7 @@ hidl_interface {
        "DataConnActiveStatus",
        "DataProfileInfo",
        "DataRegStateResult",
        "EmergencyCallRouting",
        "EmergencyNumber",
        "EmergencyNumberSource",
        "EmergencyServiceCategory",
+20 −13
Original line number Diff line number Diff line
@@ -21,6 +21,7 @@ import @1.2::DataRequestReason;
import @1.3::IRadio;
import @1.4::AccessNetwork;
import @1.4::DataProfileInfo;
import @1.4::EmergencyCallRouting;
import @1.4::EmergencyServiceCategory;
import @1.4::RadioAccessFamily;

@@ -101,21 +102,26 @@ interface IRadio extends @1.3::IRadio {
    oneway setDataProfile_1_4(int32_t serial, vec<DataProfileInfo> profiles);

    /**
     * Initiate emergency voice call, with zero or more emergency service category(s).
     *
     * Note this API is the same as IRadio.dial except using the
     * @1.4::EmergencyServiceCategory as the input param.
     *
     * If the number in the 'dialInfo' field is identified as an emergency number in Android,
     * Android use this request for its emergency call instead of @1.0::IRadio.dial. The
     * implementation decides how to handle the call (e.g. emergency routing or normal
     * routing).
     * Initiate emergency voice call, with zero or more emergency service category(s) and routing
     * information for handling the call. Android uses this request to make its emergency call
     * instead of using @1.0::IRadio.dial if the 'address' in the 'dialInfo' field is identified
     * as an emergency number by Android.
     *
     * In multi-sim senario, this radio request is sent through the IRadio service that serves
     * the subscription the emergency number belongs to, no matter of the PUK/PIN state of the
     * subscription and the service state.
     *
     * Some countries or carriers require some emergency numbers that must be handled with normal
     * call routing or emergency routing. If the 'routing' field is specified as
     * @1.4::EmergencyNumberRouting#NORMAL, the implementation must use normal call routing to
     * handle the call; if it is specified as @1.4::EmergencyNumberRouting#EMERGENCY, the
     * implementation must use emergency routing to handle the call; if it is
     * @1.4::EmergencyNumberRouting#UNKNOWN, Android does not know how to handle the call.
     *
     * If the dialed emergency number does not have a specified emergency service category, the
     * 'categories' field is set to @1.4::EmergencyServiceCategory#UNSPECIFIED; iff either the
     * 'categories' field is set to @1.4::EmergencyServiceCategory#UNSPECIFIED or the underlying
     * 'categories' field is set to @1.4::EmergencyServiceCategory#UNSPECIFIED; if the underlying
     * technology used to request emergency services does not support the emergency service
     * category, the interpretation of the categories is defined by implementation.
     * category, the categories may be ignored.
     *
     * Reference: 3gpp TS 22.101, Section 10 - Emergency Calls
     *
@@ -123,11 +129,12 @@ interface IRadio extends @1.3::IRadio {
     * @param dialInfo the same @1.0::Dial information used by @1.0::IRadio.dial.
     * @param categories bitfield<@1.4::EmergencyServiceCategory> the Emergency Service Category(s)
     *     of the call.
     * @param routing @1.4::EmergencyCallRouting the emergency call routing information.
     *
     * Response function is IRadioResponse.emergencyDialResponse()
     */
    oneway emergencyDial(int32_t serial, Dial dialInfo,
            bitfield<EmergencyServiceCategory> categories);
            bitfield<EmergencyServiceCategory> categories, EmergencyCallRouting routing);

    /**
     * Query the preferred network type bitmap.
+10 −10
Original line number Diff line number Diff line
@@ -27,17 +27,17 @@ interface IRadioIndication extends @1.3::IRadioIndication {
     * Report the current list of emergency numbers
     *
     * Each emergency number (@1.4::EmergencyNumber) in the emergency number list contains a
     * dialing number, zero or more service category(s), mobile country code, and source(s) that
     * indicate where it comes from.
     * dialing number, zero or more service category(s), mobile country code, mobile network code,
     * and source(s) that indicate where it comes from.
     *
     * Radio must report all the valid emergency numbers with known mobile country code and
     * emergency service categories from all available sources including network signaling, sim,
     * modem/oem configuration, and default configuration (112 and 911 must be always available;
     * additionally, 000, 08, 110, 999, 118 and 119 must be available when sim is not present).
     * Radio shall not report emergency numbers that are invalid in the current locale. The
     * reported emergency number list must not have duplicate @1.4::EmergencyNumber entries. Please
     * refer the documentation of @1.4::EmergencyNumber to construct each emergency number to
     * report.
     * Radio must report all the valid emergency numbers with known mobile country code, mobile
     * network code and emergency service categories from all available sources including network
     * signaling, sim, modem/oem configuration, and default configuration (112 and 911 must be
     * always available; additionally, 000, 08, 110, 999, 118 and 119 must be available when sim
     * is not present). Radio shall not report emergency numbers that are invalid in the current
     * locale. The reported emergency number list must not have duplicate @1.4::EmergencyNumber
     * entries. Please refer the documentation of @1.4::EmergencyNumber to construct each
     * emergency number to report.
     *
     * Radio must report the complete list of emergency numbers whenever the emergency numbers in
     * the list are changed or whenever the client and the radio server are connected.
+20 −1
Original line number Diff line number Diff line
@@ -54,7 +54,7 @@ enum AccessNetwork : @1.2::AccessNetwork {

/**
 * Emergency number contains information of number, one or more service category(s), mobile country
 * code (mcc), and source(s) that indicate where it comes from.
 * code (mcc), mobile network country (mnc) and source(s) that indicate where it comes from.
 *
 * If the source of the emergency number is associated with country, field ‘mcc’ must be provided;
 * otherwise the field ‘mcc’ must be an empty string.
@@ -156,6 +156,25 @@ enum EmergencyNumberSource : int32_t {
    DEFAULT = 1 << 3,
};

/**
 * Indicates how the implementation should handle the emergency call if it is required by Android.
 */
enum EmergencyCallRouting : int32_t {
    /**
     * Indicates Android does not require how to handle the corresponding emergency call; it is
     * decided by implementation.
     */
    UNKNOWN = 0,
    /**
     * Indicates the implementation must handle the call through emergency routing.
     */
    EMERGENCY = 1,
    /**
     * Indicates the implementation must handle the call through normal call routing.
     */
    NORMAL = 2,
};

enum RadioTechnology : @1.0::RadioTechnology {
    /** 5G NR. */
    NR = 20,