diff options
| author | Mateusz Guzik <mjg@FreeBSD.org> | 2020-09-01 21:45:08 +0000 |
|---|---|---|
| committer | Mateusz Guzik <mjg@FreeBSD.org> | 2020-09-01 21:45:08 +0000 |
| commit | 6c7cae4a73b883ec0410e882bb56622c3090592c (patch) | |
| tree | fcbe350f4b410e8a551e330576053454e79c4ddf /sys/dev/xen/control | |
| parent | 6831ac28dcecc6015d61098c8173261bfbdba280 (diff) | |
Notes
Diffstat (limited to 'sys/dev/xen/control')
| -rw-r--r-- | sys/dev/xen/control/control.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/sys/dev/xen/control/control.c b/sys/dev/xen/control/control.c index 6c71e67eda05..8ad398bf986b 100644 --- a/sys/dev/xen/control/control.c +++ b/sys/dev/xen/control/control.c @@ -356,7 +356,7 @@ xctrl_on_watch_event(struct xs_watch *watch, const char **vec, unsigned int len) char *result; int error; int result_len; - + error = xs_read(XST_NIL, "control", "shutdown", &result_len, (void **)&result); if (error != 0 || result_len == 0) @@ -370,7 +370,6 @@ xctrl_on_watch_event(struct xs_watch *watch, const char **vec, unsigned int len) reason = xctrl_shutdown_reasons; last_reason = reason + nitems(xctrl_shutdown_reasons); while (reason < last_reason) { - if (!strcmp(result, reason->name)) { reason->handler(); break; @@ -469,11 +468,11 @@ static device_method_t xctrl_methods[] = { DEVMETHOD(device_probe, xctrl_probe), DEVMETHOD(device_attach, xctrl_attach), DEVMETHOD(device_detach, xctrl_detach), - + DEVMETHOD_END }; DEFINE_CLASS_0(xctrl, xctrl_driver, xctrl_methods, sizeof(struct xctrl_softc)); devclass_t xctrl_devclass; - + DRIVER_MODULE(xctrl, xenstore, xctrl_driver, xctrl_devclass, NULL, NULL); |
