s390/zcrypt: Separate msgtype implementation from card modules.
Msgtype implementations are now separated from card specific modules and can be dynamically registered. Existing msgtype implementations are restructured in modules. Signed-off-by: Holger Dengler <hd@linux.vnet.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
This commit is contained in:

committed by
Martin Schwidefsky

parent
b26bd9413c
commit
5e55a488c8
@@ -1,7 +1,7 @@
|
||||
/*
|
||||
* zcrypt 2.1.0
|
||||
*
|
||||
* Copyright IBM Corp. 2001, 2006
|
||||
* Copyright IBM Corp. 2001, 2012
|
||||
* Author(s): Robert Burroughs
|
||||
* Eric Rossman (edrossma@us.ibm.com)
|
||||
* Cornelia Huck <cornelia.huck@de.ibm.com>
|
||||
@@ -9,6 +9,7 @@
|
||||
* Hotplug & misc device support: Jochen Roehrig (roehrig@de.ibm.com)
|
||||
* Major cleanup & driver split: Martin Schwidefsky <schwidefsky@de.ibm.com>
|
||||
* Ralph Wuerthner <rwuerthn@de.ibm.com>
|
||||
* MSGTYPE restruct: Holger Dengler <hd@linux.vnet.ibm.com>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
@@ -87,6 +88,9 @@ struct zcrypt_ops {
|
||||
struct ica_rsa_modexpo_crt *);
|
||||
long (*send_cprb)(struct zcrypt_device *, struct ica_xcRB *);
|
||||
long (*rng)(struct zcrypt_device *, char *);
|
||||
struct list_head list; /* zcrypt ops list. */
|
||||
struct module *owner;
|
||||
int variant;
|
||||
};
|
||||
|
||||
struct zcrypt_device {
|
||||
@@ -116,6 +120,10 @@ void zcrypt_device_get(struct zcrypt_device *);
|
||||
int zcrypt_device_put(struct zcrypt_device *);
|
||||
int zcrypt_device_register(struct zcrypt_device *);
|
||||
void zcrypt_device_unregister(struct zcrypt_device *);
|
||||
void zcrypt_msgtype_register(struct zcrypt_ops *);
|
||||
void zcrypt_msgtype_unregister(struct zcrypt_ops *);
|
||||
struct zcrypt_ops *zcrypt_msgtype_request(unsigned char *, int);
|
||||
void zcrypt_msgtype_release(struct zcrypt_ops *);
|
||||
int zcrypt_api_init(void);
|
||||
void zcrypt_api_exit(void);
|
||||
|
||||
|
Reference in New Issue
Block a user