openUBMC Chip Abstract Layer V0.1
载入中...
搜索中...
未找到
wdt.h
浏览该文件的文档.
1/*
2 * Copyright (c) Huawei Technologies Co., Ltd. 2025. All rights reserved.
3 *
4 * this file licensed under the Mulan PSL v2.
5 * You can use this software according to the terms and conditions of the Mulan PSL v2.
6 * You may obtain a copy of Mulan PSL v2 at:
7 * http://license.coscl.org.cn/MulanPSL2
8 *
9 * THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND, EITHER EXPRESS OR
10 * IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT, MERCHANTABILITY OR FIT FOR A PARTICULAR
11 * PURPOSE.
12 * See the Mulan PSL v2 for more details.
13 */
14
19#ifndef DRIVER_WDT_H
20#define DRIVER_WDT_H
21
22#include "driver.h"
23
24namespace DRIVER_WDT {
25using namespace bcal;
26
31class Wdt : public IDriver {
32public:
38 virtual void clear(int32_t index) = 0;
39
46 virtual void set_feed_mode(int32_t index, const string_view_t &mode) = 0;
47
54 virtual void enable_wdt(int32_t index, int32_t enable) = 0;
55
61 virtual void abnormal_reset(int32_t index) = 0;
62
68 virtual void wait_abnormal_reset(int32_t index) = 0;
69};
70} // namespace
71#endif
看门狗接口类
Definition wdt.h:31
virtual void set_feed_mode(int32_t index, const string_view_t &mode)=0
设置看门狗喂狗模式
virtual void abnormal_reset(int32_t index)=0
停止看门狗,2s之后系统复位
virtual void wait_abnormal_reset(int32_t index)=0
看门狗超时后阻塞等待系统复位
virtual void enable_wdt(int32_t index, int32_t enable)=0
启用或禁用看门狗
virtual void clear(int32_t index)=0
喂狗
BCAL层驱动公共接口
Definition driver.h:41
BCAL 驱动公共接口定义