aboutsummaryrefslogtreecommitdiffstats
path: root/arch/s390/include/uapi/asm
diff options
context:
space:
mode:
authorHarald Freudenberger <freude@linux.ibm.com>2019-08-30 15:57:17 +0200
committerVasily Gorbik <gor@linux.ibm.com>2020-01-30 13:07:55 +0100
commita7367997abb64b5e5a4f6fe6091629440b10da40 (patch)
treeb16ba69ac2eadeead1b86535b623655c55f310b5 /arch/s390/include/uapi/asm
parents390/zcrypt: enable card/domain autoselect on ep11 cprbs (diff)
downloadlinux-dev-a7367997abb64b5e5a4f6fe6091629440b10da40.tar.xz
linux-dev-a7367997abb64b5e5a4f6fe6091629440b10da40.zip
s390/zcrypt: ep11 structs rework, export zcrypt_send_ep11_cprb
Minor rework for struct ep11_cprb and struct ep11_urb. Use of u8, u16, u32 instead of unsigned char. Declare pointers to mem from userspace with __user to give sparse a chance to check. Export zcrypt_send_ep11_cprb() function as this function will be called by code in progress which will build ep11 cprbs within the zcrypt device driver zoo and send them to EP11 crypto cards. Signed-off-by: Harald Freudenberger <freude@linux.ibm.com> Signed-off-by: Vasily Gorbik <gor@linux.ibm.com>
Diffstat (limited to 'arch/s390/include/uapi/asm')
-rw-r--r--arch/s390/include/uapi/asm/zcrypt.h28
1 files changed, 14 insertions, 14 deletions
diff --git a/arch/s390/include/uapi/asm/zcrypt.h b/arch/s390/include/uapi/asm/zcrypt.h
index 7f179a30beb1..5a2177e96e88 100644
--- a/arch/s390/include/uapi/asm/zcrypt.h
+++ b/arch/s390/include/uapi/asm/zcrypt.h
@@ -161,17 +161,17 @@ struct ica_xcRB {
* @payload_len: Payload length
*/
struct ep11_cprb {
- __u16 cprb_len;
- unsigned char cprb_ver_id;
- unsigned char pad_000[2];
- unsigned char flags;
- unsigned char func_id[2];
- __u32 source_id;
- __u32 target_id;
- __u32 ret_code;
- __u32 reserved1;
- __u32 reserved2;
- __u32 payload_len;
+ __u16 cprb_len;
+ __u8 cprb_ver_id;
+ __u8 pad_000[2];
+ __u8 flags;
+ __u8 func_id[2];
+ __u32 source_id;
+ __u32 target_id;
+ __u32 ret_code;
+ __u32 reserved1;
+ __u32 reserved2;
+ __u32 payload_len;
} __attribute__((packed));
/**
@@ -197,13 +197,13 @@ struct ep11_target_dev {
*/
struct ep11_urb {
__u16 targets_num;
- __u64 targets;
+ __u8 __user *targets;
__u64 weight;
__u64 req_no;
__u64 req_len;
- __u64 req;
+ __u8 __user *req;
__u64 resp_len;
- __u64 resp;
+ __u8 __user *resp;
} __attribute__((packed));
/**