This should fix the indentation issues found by checkpatch.
Signed-off-by: Stefan Wahren <stefan.wahren@i2se.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
#define BELL2 0x08
typedef struct vchiq_2835_state_struct {
- int inited;
- VCHIQ_ARM_STATE_T arm_state;
+ int inited;
+ VCHIQ_ARM_STATE_T arm_state;
} VCHIQ_2835_ARM_STATE_T;
struct vchiq_pagelist_info {
vchiq_call_connected_callbacks();
- return 0;
+ return 0;
}
VCHIQ_STATUS_T
vchiq_platform_init_state(VCHIQ_STATE_T *state)
{
- VCHIQ_STATUS_T status = VCHIQ_SUCCESS;
- state->platform_state = kzalloc(sizeof(VCHIQ_2835_ARM_STATE_T), GFP_KERNEL);
- ((VCHIQ_2835_ARM_STATE_T*)state->platform_state)->inited = 1;
- status = vchiq_arm_init_state(state, &((VCHIQ_2835_ARM_STATE_T*)state->platform_state)->arm_state);
- if(status != VCHIQ_SUCCESS)
- {
- ((VCHIQ_2835_ARM_STATE_T*)state->platform_state)->inited = 0;
- }
- return status;
+ VCHIQ_STATUS_T status = VCHIQ_SUCCESS;
+ state->platform_state = kzalloc(sizeof(VCHIQ_2835_ARM_STATE_T), GFP_KERNEL);
+ ((VCHIQ_2835_ARM_STATE_T*)state->platform_state)->inited = 1;
+ status = vchiq_arm_init_state(state, &((VCHIQ_2835_ARM_STATE_T*)state->platform_state)->arm_state);
+ if(status != VCHIQ_SUCCESS)
+ {
+ ((VCHIQ_2835_ARM_STATE_T*)state->platform_state)->inited = 0;
+ }
+ return status;
}
VCHIQ_ARM_STATE_T*
vchiq_platform_get_arm_state(VCHIQ_STATE_T *state)
{
- if(!((VCHIQ_2835_ARM_STATE_T*)state->platform_state)->inited)
- {
- BUG();
- }
- return &((VCHIQ_2835_ARM_STATE_T*)state->platform_state)->arm_state;
+ if(!((VCHIQ_2835_ARM_STATE_T*)state->platform_state)->inited)
+ {
+ BUG();
+ }
+ return &((VCHIQ_2835_ARM_STATE_T*)state->platform_state)->arm_state;
}
void
VCHIQ_STATUS_T
vchiq_platform_suspend(VCHIQ_STATE_T *state)
{
- return VCHIQ_ERROR;
+ return VCHIQ_ERROR;
}
VCHIQ_STATUS_T
vchiq_platform_resume(VCHIQ_STATE_T *state)
{
- return VCHIQ_SUCCESS;
+ return VCHIQ_SUCCESS;
}
void
int
vchiq_platform_videocore_wanted(VCHIQ_STATE_T* state)
{
- return 1; // autosuspend not supported - videocore always wanted
+ return 1; // autosuspend not supported - videocore always wanted
}
int
vchiq_platform_use_suspend_timer(void)
{
- return 0;
+ return 0;
}
void
vchiq_dump_platform_use_state(VCHIQ_STATE_T *state)
USER_SERVICE_T *user_service =
(USER_SERVICE_T *)service->base.userdata;
/* close_pending is false on first entry, and when the
- wait in vchiq_close_service has been interrupted. */
+ wait in vchiq_close_service has been interrupted. */
if (!user_service->close_pending) {
status = vchiq_close_service(service->handle);
if (status != VCHIQ_SUCCESS)
USER_SERVICE_T *user_service =
(USER_SERVICE_T *)service->base.userdata;
/* close_pending is false on first entry, and when the
- wait in vchiq_close_service has been interrupted. */
+ wait in vchiq_close_service has been interrupted. */
if (!user_service->close_pending) {
status = vchiq_remove_service(service->handle);
if (status != VCHIQ_SUCCESS)
extern void
vchiq_check_suspend(VCHIQ_STATE_T *state);
- VCHIQ_STATUS_T
+VCHIQ_STATUS_T
vchiq_use_service(VCHIQ_SERVICE_HANDLE_T handle);
extern VCHIQ_STATUS_T
VCHIQ_STATUS_T
vchiq_get_peer_version(VCHIQ_SERVICE_HANDLE_T handle, short *peer_version)
{
- VCHIQ_STATUS_T status = VCHIQ_ERROR;
- VCHIQ_SERVICE_T *service = find_service_by_handle(handle);
+ VCHIQ_STATUS_T status = VCHIQ_ERROR;
+ VCHIQ_SERVICE_T *service = find_service_by_handle(handle);
- if (!service ||
- (vchiq_check_service(service) != VCHIQ_SUCCESS) ||
- !peer_version)
- goto exit;
- *peer_version = service->peer_version;
- status = VCHIQ_SUCCESS;
+ if (!service ||
+ (vchiq_check_service(service) != VCHIQ_SUCCESS) ||
+ !peer_version)
+ goto exit;
+ *peer_version = service->peer_version;
+ status = VCHIQ_SUCCESS;
exit:
- if (service)
- unlock_service(service);
- return status;
+ if (service)
+ unlock_service(service);
+ return status;
}
VCHIQ_STATUS_T
service->stats.bulk_stalls,
service->stats.bulk_aborted_count,
service->stats.error_count);
- }
+ }
}
vchiq_dump(dump_context, buf, len + 1);
VCHIQ_STATUS_T status = VCHIQ_ERROR;
VCHIQ_STATE_T *state;
VCHIQ_INSTANCE_T instance = NULL;
- int i;
+ int i;
vchiq_log_trace(vchiq_core_log_level, "%s called", __func__);
- /* VideoCore may not be ready due to boot up timing.
- It may never be ready if kernel and firmware are mismatched, so don't block forever. */
- for (i=0; i<VCHIQ_INIT_RETRIES; i++) {
+ /* VideoCore may not be ready due to boot up timing.
+ It may never be ready if kernel and firmware are mismatched, so don't block forever. */
+ for (i=0; i<VCHIQ_INIT_RETRIES; i++) {
state = vchiq_get_state();
if (state)
break;
SHIM_SERVICE_T *service =
(SHIM_SERVICE_T *)VCHIQ_GET_SERVICE_USERDATA(handle);
- if (!service->callback)
+ if (!service->callback)
goto release;
switch (reason) {
}
release:
- vchiq_release_message(service->handle, header);
+ vchiq_release_message(service->handle, header);
done:
return VCHIQ_SUCCESS;
}
int32_t vchi_get_peer_version( const VCHI_SERVICE_HANDLE_T handle, short *peer_version )
{
- int32_t ret = -1;
- SHIM_SERVICE_T *service = (SHIM_SERVICE_T *)handle;
- if(service)
- {
- VCHIQ_STATUS_T status = vchiq_get_peer_version(service->handle, peer_version);
- ret = vchiq_status_to_vchi( status );
- }
- return ret;
+ int32_t ret = -1;
+ SHIM_SERVICE_T *service = (SHIM_SERVICE_T *)handle;
+ if(service)
+ {
+ VCHIQ_STATUS_T status;
+
+ status = vchiq_get_peer_version(service->handle, peer_version);
+ ret = vchiq_status_to_vchi( status );
+ }
+ return ret;
}
EXPORT_SYMBOL(vchi_get_peer_version);