mgmt: hawkbit: Conversion of k_work API
Implement new workqueue API changes. Signed-off-by: Navin Sankar Velliangiri <navin@linumiz.com>
This commit is contained in:
parent
e61b957a0f
commit
62149516c4
1 changed files with 4 additions and 4 deletions
|
@ -91,7 +91,7 @@ static union {
|
|||
struct hawkbit_cancel cancel;
|
||||
} hawkbit_results;
|
||||
|
||||
static struct k_delayed_work hawkbit_work_handle;
|
||||
static struct k_work_delayable hawkbit_work_handle;
|
||||
|
||||
static const struct json_obj_descr json_href_descr[] = {
|
||||
JSON_OBJ_DESCR_PRIM(struct hawkbit_href, href, JSON_TOK_STRING),
|
||||
|
@ -1264,11 +1264,11 @@ static void autohandler(struct k_work *work)
|
|||
break;
|
||||
}
|
||||
|
||||
k_delayed_work_submit(&hawkbit_work_handle, K_MSEC(poll_sleep));
|
||||
k_work_reschedule(&hawkbit_work_handle, K_MSEC(poll_sleep));
|
||||
}
|
||||
|
||||
void hawkbit_autohandler(void)
|
||||
{
|
||||
k_delayed_work_init(&hawkbit_work_handle, autohandler);
|
||||
k_delayed_work_submit(&hawkbit_work_handle, K_NO_WAIT);
|
||||
k_work_init_delayable(&hawkbit_work_handle, autohandler);
|
||||
k_work_reschedule(&hawkbit_work_handle, K_NO_WAIT);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue