mirror of
https://github.com/genodelabs/genode.git
synced 2025-06-16 14:18:27 +00:00
committed by
Christian Helmuth
parent
b9f0318ab8
commit
2d03e622f1
@ -17,6 +17,7 @@
|
|||||||
#include <base/component.h>
|
#include <base/component.h>
|
||||||
#include <base/log.h>
|
#include <base/log.h>
|
||||||
#include <base/heap.h>
|
#include <base/heap.h>
|
||||||
|
#include <base/sleep.h>
|
||||||
#include <block/component.h>
|
#include <block/component.h>
|
||||||
#include <block/driver.h>
|
#include <block/driver.h>
|
||||||
#include <block_session/connection.h>
|
#include <block_session/connection.h>
|
||||||
@ -86,6 +87,8 @@ struct Usb::Block_driver : Usb::Completion,
|
|||||||
Genode::log("Device plugged");
|
Genode::log("Device plugged");
|
||||||
|
|
||||||
if (!initialize()) {
|
if (!initialize()) {
|
||||||
|
env.parent().exit(-1);
|
||||||
|
Genode::sleep_forever();
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -561,11 +564,9 @@ struct Usb::Block_driver : Usb::Completion,
|
|||||||
} catch (int) {
|
} catch (int) {
|
||||||
/* handle command failures */
|
/* handle command failures */
|
||||||
Genode::error("Could not initialize storage device");
|
Genode::error("Could not initialize storage device");
|
||||||
return false;
|
|
||||||
} catch (...) {
|
} catch (...) {
|
||||||
/* handle Usb::Session failures */
|
/* handle Usb::Session failures */
|
||||||
Genode::error("Could not initialize storage device");
|
Genode::error("Could not initialize storage device");
|
||||||
throw;
|
|
||||||
}
|
}
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user