DM: refine cleanup functionality of virtual RTC

The patch includes:
1. vrtc_cleanup -> vrtc_deinit to align with other devices
2. delete timer created in vrtc_init
3. make call to vrtc_deinit in cleanup path

Signed-off-by: Yin Fengwei <fengwei.yin@intel.com>
Acked-by: Eddie Dong <Eddie.dong@intel.com>
This commit is contained in:
Yin Fengwei
2018-03-30 14:46:35 +08:00
committed by Jack Ren
parent 80a9fe5b37
commit eadc921bf0
4 changed files with 28 additions and 2 deletions

View File

@@ -37,7 +37,7 @@ struct vrtc;
struct vmctx;
struct vrtc *vrtc_init(struct vmctx *ctx, int local_time);
void vrtc_cleanup(struct vrtc *vrtc);
void vrtc_deinit(struct vmctx *ctx);
void vrtc_reset(struct vrtc *vrtc);
time_t vrtc_get_time(struct vrtc *vrtc);
int vrtc_set_time(struct vrtc *vrtc, time_t secs);