sparrow-kata-full/apps/system/components/SDKRuntime/sdk-interface/Cargo.toml
Sam Leffler f9ea7c196e SDKRuntime: overhaul rpc mechanism
Simplify the rpc mechanism and make it more robust. Instead of serializing
the request token at the front of the slice assigned to request arguments,
write the token to the label field of the MessageInfo. Likewise instead
of incorporating the status in the response data return that in the
label field.  This noticeably simplifies the code and properly handles
the case where the receiver fails to map the page frame associated with
rpc (previously it kinda punted, now the caller get a proper status
result). While here extend the request/reswponse enum's to give each
error a distinct value.

Note that requsst/response tokens are passed as raw numbers under the
assumption sender + receiver are on the same machine so are using the
same byte order.

NB: this adds the num_enum crate to handle enum<>primitive conversions.

Change-Id: I536a23c7bddc43c686cc4335f22524debeeedf4f
GitOrigin-RevId: 8a9fa009dc65605b8d160330edcde02dcfa2172b
2022-10-18 15:36:40 -07:00

25 lines
966 B
TOML

# Copyright 2022 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
[package]
name = "sdk-interface"
version = "0.1.0"
edition = "2021"
[dependencies]
num_enum = { version = "0.5", default-features = false }
postcard = { version = "0.7", features = ["alloc"], default-features = false }
sel4-sys = { path = "../../kata-os-common/src/sel4-sys", default-features = false }
serde = { version = "1.0", default-features = false, features = ["alloc", "derive"] }