1 namespace phosphor 2 { 3 namespace network 4 { 5 namespace ncsi 6 { 7 8 constexpr auto DEFAULT_VALUE = -1; 9 constexpr auto NONE = 0; 10 11 /* @brief This function will ask underlying NCSI driver 12 * to set a specific package or package/channel 13 * combination as the preferred choice. 14 * This function talks with the NCSI driver over 15 * netlink messages. 16 * @param[in] ifindex - Interface Index. 17 * @param[in] package - NCSI Package. 18 * @param[in] channel - Channel number with in the package. 19 * @returns 0 on success and negative value for failure. 20 */ 21 int setChannel(int ifindex, int package, int channel); 22 23 /* @brief This function will ask underlying NCSI driver 24 * to clear any preferred setting from the given 25 * interface. 26 * This function talks with the NCSI driver over 27 * netlink messages. 28 * @param[in] ifindex - Interface Index. 29 * @returns 0 on success and negative value for failure. 30 */ 31 int clearInterface(int ifindex); 32 33 /* @brief This function is used to dump all the info 34 * of the package and the channels underlying 35 * the package. 36 * @param[in] ifindex - Interface Index. 37 * @param[in] package - NCSI Package. 38 * @returns 0 on success and negative value for failure. 39 */ 40 int getInfo(int ifindex, int package); 41 42 } // namespace ncsi 43 } // namespace network 44 } // namespace phosphor 45