summaryrefslogtreecommitdiff
path: root/drivers/staging/vc04_services
diff options
context:
space:
mode:
authorDominic Braun <inf.braun@fau.de>2018-12-14 13:05:02 +0100
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2018-12-17 14:47:44 +0100
commitd3af2bcc6ea4e55884ee11b05a7d95002026017f (patch)
treee4f2f690e0718284dbb05de6d33b2a647768954c /drivers/staging/vc04_services
parent0b53ca3127a674f9bdc94f6a4e1e6b92eb6b17fa (diff)
staging: vc04_services: Remove VCHIQ_SERVICE_QUOTA_T typedef
Typedefing structs is not encouraged in the kernel. Signed-off-by: Dominic Braun <inf.braun@fau.de> Signed-off-by: Tobias Büttner <tobias.buettner@fau.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/vc04_services')
-rw-r--r--drivers/staging/vc04_services/interface/vchiq_arm/vchiq_core.c16
-rw-r--r--drivers/staging/vc04_services/interface/vchiq_arm/vchiq_core.h6
2 files changed, 11 insertions, 11 deletions
diff --git a/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_core.c b/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_core.c
index 7fe032abd267..5382967df3b5 100644
--- a/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_core.c
+++ b/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_core.c
@@ -357,7 +357,7 @@ static void
mark_service_closing_internal(VCHIQ_SERVICE_T *service, int sh_thread)
{
VCHIQ_STATE_T *state = service->state;
- VCHIQ_SERVICE_QUOTA_T *service_quota;
+ struct vchiq_service_quota *service_quota;
service->closing = 1;
@@ -660,7 +660,7 @@ process_free_queue(VCHIQ_STATE_T *state, BITSET_T *service_found, size_t length)
if (VCHIQ_MSG_TYPE(msgid) == VCHIQ_MSG_DATA) {
int port = VCHIQ_MSG_SRCPORT(msgid);
- VCHIQ_SERVICE_QUOTA_T *service_quota =
+ struct vchiq_service_quota *service_quota =
&state->service_quotas[port];
int count;
@@ -808,7 +808,7 @@ queue_message(VCHIQ_STATE_T *state, VCHIQ_SERVICE_T *service,
int flags)
{
VCHIQ_SHARED_STATE_T *local;
- VCHIQ_SERVICE_QUOTA_T *service_quota = NULL;
+ struct vchiq_service_quota *service_quota = NULL;
struct vchiq_header *header;
int type = VCHIQ_MSG_TYPE(msgid);
@@ -2205,7 +2205,7 @@ vchiq_init_state(VCHIQ_STATE_T *state, VCHIQ_SLOT_ZERO_T *slot_zero)
state->slot_queue_available = 0;
for (i = 0; i < VCHIQ_MAX_SERVICES; i++) {
- VCHIQ_SERVICE_QUOTA_T *service_quota =
+ struct vchiq_service_quota *service_quota =
&state->service_quotas[i];
init_completion(&service_quota->quota_event);
}
@@ -2308,7 +2308,7 @@ vchiq_add_service_internal(VCHIQ_STATE_T *state,
{
VCHIQ_SERVICE_T *service;
VCHIQ_SERVICE_T **pservice = NULL;
- VCHIQ_SERVICE_QUOTA_T *service_quota;
+ struct vchiq_service_quota *service_quota;
int i;
service = kmalloc(sizeof(VCHIQ_SERVICE_T), GFP_KERNEL);
@@ -3300,7 +3300,7 @@ vchiq_set_service_option(VCHIQ_SERVICE_HANDLE_T handle,
break;
case VCHIQ_SERVICE_OPTION_SLOT_QUOTA: {
- VCHIQ_SERVICE_QUOTA_T *service_quota =
+ struct vchiq_service_quota *service_quota =
&service->state->service_quotas[
service->localport];
if (value == 0)
@@ -3320,7 +3320,7 @@ vchiq_set_service_option(VCHIQ_SERVICE_HANDLE_T handle,
} break;
case VCHIQ_SERVICE_OPTION_MESSAGE_QUOTA: {
- VCHIQ_SERVICE_QUOTA_T *service_quota =
+ struct vchiq_service_quota *service_quota =
&service->state->service_quotas[
service->localport];
if (value == 0)
@@ -3482,7 +3482,7 @@ vchiq_dump_service_state(void *dump_context, VCHIQ_SERVICE_T *service)
if (service->srvstate != VCHIQ_SRVSTATE_FREE) {
char remoteport[30];
- VCHIQ_SERVICE_QUOTA_T *service_quota =
+ struct vchiq_service_quota *service_quota =
&service->state->service_quotas[service->localport];
int fourcc = service->base.fourcc;
int tx_pending, rx_pending;
diff --git a/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_core.h b/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_core.h
index 62d914108183..11dabe464c9b 100644
--- a/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_core.h
+++ b/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_core.h
@@ -332,14 +332,14 @@ typedef struct vchiq_service_struct {
statically allocated, since for accounting reasons a service's slot
usage is carried over between users of the same port number.
*/
-typedef struct vchiq_service_quota_struct {
+struct vchiq_service_quota {
unsigned short slot_quota;
unsigned short slot_use_count;
unsigned short message_quota;
unsigned short message_use_count;
struct completion quota_event;
int previous_tx_index;
-} VCHIQ_SERVICE_QUOTA_T;
+};
typedef struct vchiq_shared_state_struct {
@@ -497,7 +497,7 @@ struct vchiq_state_struct {
} stats;
VCHIQ_SERVICE_T * services[VCHIQ_MAX_SERVICES];
- VCHIQ_SERVICE_QUOTA_T service_quotas[VCHIQ_MAX_SERVICES];
+ struct vchiq_service_quota service_quotas[VCHIQ_MAX_SERVICES];
VCHIQ_SLOT_INFO_T slot_info[VCHIQ_MAX_SLOTS];
VCHIQ_PLATFORM_STATE_T platform_state;