Skip to contentSkip to conversation

libxl: add missing action in DEFINE_DEVICE_ADD

PATCH In review Wei Liu 2 participants 3 messages Nov 11, 2014 – Nov 12, 2014

lore
Share & tools
lore

Wei Liu

author
#0 lore raw

PATCH 1/1 libxl: add missing action in DEFINE_DEVICE_ADD

Cc Ian Campbell <[email protected]>
Cc Ian Jackson <[email protected]>
Cc George Dunlap <[email protected]>
Cc Konrad Wilk <[email protected]>

---
This is a simple enough bug fix I think it should just go in.

---
 tools/libxl/libxl.c |    1 +
 1 file changed, 1 insertion(+)
tools/libxl/libxl.c +1 -0
index f7961f6..de23fec 100644
@@ -4164,6 +4164,7 @@ DEFINE_DEVICE_REMOVE(vtpm, destroy, 1)
                                                                         \
         GCNEW(aodev);                                                   \
         libxl__prepare_ao_device(ao, aodev);                            \
+        aodev->action = LIBXL__DEVICE_ACTION_ADD;                       \
         aodev->callback = device_addrm_aocomplete;                      \
         aodev->update_json = true;                                      \
         libxl__device_##type##_add(egc, domid, type, aodev);            \
Signature · 1 line
1.7.10.4
#1 lore raw
Quoted 7 lines · Wei Liu
Cc Ian Campbell <[email protected]>
Cc Ian Jackson <[email protected]>
Cc George Dunlap <[email protected]>
Cc Konrad Wilk <[email protected]>

---
This is a simple enough bug fix I think it should just go in.

Probably, but can you explain in the commit log what the symptoms of not doing it are, IOW why it is required.

Quoted 16 lines
---
 tools/libxl/libxl.c |    1 +
 1 file changed, 1 insertion(+)
tools/libxl/libxl.c +1 -0
index f7961f6..de23fec 100644
@@ -4164,6 +4164,7 @@ DEFINE_DEVICE_REMOVE(vtpm, destroy, 1)
                                                                         \
         GCNEW(aodev);                                                   \
         libxl__prepare_ao_device(ao, aodev);                            \
+        aodev->action = LIBXL__DEVICE_ACTION_ADD;                       \
         aodev->callback = device_addrm_aocomplete;                      \
         aodev->update_json = true;                                      \
         libxl__device_##type##_add(egc, domid, type, aodev);            \
author
#2 lore raw
Quoted 9 lines · Ian Campbell
Quoted 7 lines · Wei Liu
Cc Ian Campbell <[email protected]>
Cc Ian Jackson <[email protected]>
Cc George Dunlap <[email protected]>
Cc Konrad Wilk <[email protected]>

---
This is a simple enough bug fix I think it should just go in.

Quoted 3 lines

Probably, but can you explain in the commit log what the symptoms of not doing it are, IOW why it is required.

OK, I will resubmit with updated commit log.

Quoted 17 lines
Quoted 16 lines
---
 tools/libxl/libxl.c |    1 +
 1 file changed, 1 insertion(+)
tools/libxl/libxl.c +1 -0
index f7961f6..de23fec 100644
@@ -4164,6 +4164,7 @@ DEFINE_DEVICE_REMOVE(vtpm, destroy, 1)
                                                                         \
         GCNEW(aodev);                                                   \
         libxl__prepare_ao_device(ao, aodev);                            \
+        aodev->action = LIBXL__DEVICE_ACTION_ADD;                       \
         aodev->callback = device_addrm_aocomplete;                      \
         aodev->update_json = true;                                      \
         libxl__device_##type##_add(egc, domid, type, aodev);            \