Commit 32129ec0 authored by Stefan Wahren's avatar Stefan Wahren Committed by Greg Kroah-Hartman
Browse files

staging: vchiq_core: Get the rid off curly braces around cases



Additional curly braces around cases are a bit harder to read. So
change the scope of service quota to get the rid off those braces.

Signed-off-by: default avatarStefan Wahren <stefan.wahren@i2se.com>
Link: https://lore.kernel.org/r/1618164700-21150-4-git-send-email-stefan.wahren@i2se.com


Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent e04e9008
Loading
Loading
Loading
Loading
+7 −8
Original line number Original line Diff line number Diff line
@@ -3357,6 +3357,7 @@ vchiq_set_service_option(unsigned int handle,
{
{
	struct vchiq_service *service = find_service_by_handle(handle);
	struct vchiq_service *service = find_service_by_handle(handle);
	enum vchiq_status status = VCHIQ_ERROR;
	enum vchiq_status status = VCHIQ_ERROR;
	struct vchiq_service_quota *quota;


	if (service) {
	if (service) {
		switch (option) {
		switch (option) {
@@ -3365,9 +3366,8 @@ vchiq_set_service_option(unsigned int handle,
			status = VCHIQ_SUCCESS;
			status = VCHIQ_SUCCESS;
			break;
			break;


		case VCHIQ_SERVICE_OPTION_SLOT_QUOTA: {
		case VCHIQ_SERVICE_OPTION_SLOT_QUOTA:
			struct vchiq_service_quota *quota =
			quota = &service->state->service_quotas[
				&service->state->service_quotas[
					service->localport];
					service->localport];
			if (value == 0)
			if (value == 0)
				value = service->state->default_slot_quota;
				value = service->state->default_slot_quota;
@@ -3385,11 +3385,10 @@ vchiq_set_service_option(unsigned int handle,
				}
				}
				status = VCHIQ_SUCCESS;
				status = VCHIQ_SUCCESS;
			}
			}
		} break;
			break;


		case VCHIQ_SERVICE_OPTION_MESSAGE_QUOTA: {
		case VCHIQ_SERVICE_OPTION_MESSAGE_QUOTA:
			struct vchiq_service_quota *quota =
			quota = &service->state->service_quotas[
				&service->state->service_quotas[
					service->localport];
					service->localport];
			if (value == 0)
			if (value == 0)
				value = service->state->default_message_quota;
				value = service->state->default_message_quota;
@@ -3407,7 +3406,7 @@ vchiq_set_service_option(unsigned int handle,
					complete(&quota->quota_event);
					complete(&quota->quota_event);
				status = VCHIQ_SUCCESS;
				status = VCHIQ_SUCCESS;
			}
			}
		} break;
			break;


		case VCHIQ_SERVICE_OPTION_SYNCHRONOUS:
		case VCHIQ_SERVICE_OPTION_SYNCHRONOUS:
			if ((service->srvstate == VCHIQ_SRVSTATE_HIDDEN) ||
			if ((service->srvstate == VCHIQ_SRVSTATE_HIDDEN) ||