File tree Expand file tree Collapse file tree 1 file changed +9
-4
lines changed Expand file tree Collapse file tree 1 file changed +9
-4
lines changed Original file line number Diff line number Diff line change @@ -263,8 +263,10 @@ pub trait GatewayApi {
263
263
///
264
264
/// This endpoint is only valid for the `host-boot-flash` component.
265
265
///
266
- /// Computing the hash takes several seconds; callers can poll for results
267
- /// using `sp_component_hash_firmware_get()`.
266
+ /// Computing the hash takes several seconds; callers should poll for results
267
+ /// using `sp_component_hash_firmware_get()`. In general they should call
268
+ /// `sp_component_hash_firmware_get()` first anyway, as the hashes are
269
+ /// cached in the SP and may already be ready.
268
270
#[ endpoint {
269
271
method = POST ,
270
272
path = "/sp/{type}/{slot}/component/{component}/hash/{firmware_slot}" ,
@@ -278,8 +280,11 @@ pub trait GatewayApi {
278
280
///
279
281
/// This endpoint is only valid for the `host-boot-flash` component.
280
282
///
281
- /// Computing the hash takes several seconds; callers can start hashing
282
- /// using `sp_component_hash_firmware_start()`.
283
+ /// Computing the hash takes several seconds; this endpoint returns the
284
+ /// current status. If the status is `HashNotStarted`, callers should start
285
+ /// hashing using `sp_component_hash_firmware_start()`. If the status is
286
+ /// `HashInProgress`, callers should wait a bit then call this endpoint
287
+ /// again.
283
288
#[ endpoint {
284
289
method = GET ,
285
290
path = "/sp/{type}/{slot}/component/{component}/hash/{firmware_slot}" ,
You can’t perform that action at this time.
0 commit comments