Ratan Gupta | bbe4579 | 2018-03-23 00:22:55 +0530 | [diff] [blame] | 1 | namespace phosphor |
| 2 | { |
| 3 | namespace network |
| 4 | { |
| 5 | namespace ncsi |
| 6 | { |
| 7 | |
Ratan Gupta | ed5d7ff | 2018-03-23 00:27:52 +0530 | [diff] [blame] | 8 | constexpr auto DEFAULT_VALUE = -1; |
| 9 | constexpr auto NONE = 0; |
| 10 | |
Ratan Gupta | bbe4579 | 2018-03-23 00:22:55 +0530 | [diff] [blame] | 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 | |
Ratan Gupta | aac603e | 2018-03-23 00:25:54 +0530 | [diff] [blame] | 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 | |
Ratan Gupta | bbe4579 | 2018-03-23 00:22:55 +0530 | [diff] [blame] | 42 | }//namespace ncsi |
| 43 | }//namespace network |
| 44 | }//namespace phosphor |
| 45 | |