[PATCH] staging: greybus: control.c: fixed some coding style issues

From: Aaron Williams
Date: Thu Sep 20 2018 - 11:16:59 EST


fixed some "Alignment should match open parenthesis" checks.
Signing up for the kernel clean up crew while I learn C

Signed-off-by: Aaron Williams <zero@xxxxxxxxxxxxxxxx>
---
drivers/staging/greybus/control.c | 39 +++++++++++++++----------------
1 file changed, 19 insertions(+), 20 deletions(-)

diff --git a/drivers/staging/greybus/control.c b/drivers/staging/greybus/control.c
index 35f945a12b11..f8f0aee224c8 100644
--- a/drivers/staging/greybus/control.c
+++ b/drivers/staging/greybus/control.c
@@ -15,7 +15,6 @@
#define GB_CONTROL_VERSION_MAJOR 0
#define GB_CONTROL_VERSION_MINOR 1

-
static int gb_control_get_version(struct gb_control *control)
{
struct gb_interface *intf = control->connection->intf;
@@ -32,15 +31,15 @@ static int gb_control_get_version(struct gb_control *control)
sizeof(response));
if (ret) {
dev_err(&intf->dev,
- "failed to get control-protocol version: %d\n",
- ret);
+ "failed to get control-protocol version: %d\n",
+ ret);
return ret;
}

if (response.major > request.major) {
dev_err(&intf->dev,
- "unsupported major control-protocol version (%u > %u)\n",
- response.major, request.major);
+ "unsupported major control-protocol version (%u > %u)\n",
+ response.major, request.major);
return -ENOTSUPP;
}

@@ -48,13 +47,13 @@ static int gb_control_get_version(struct gb_control *control)
control->protocol_minor = response.minor;

dev_dbg(&intf->dev, "%s - %u.%u\n", __func__, response.major,
- response.minor);
+ response.minor);

return 0;
}

static int gb_control_get_bundle_version(struct gb_control *control,
- struct gb_bundle *bundle)
+ struct gb_bundle *bundle)
{
struct gb_interface *intf = control->connection->intf;
struct gb_control_bundle_version_request request;
@@ -69,8 +68,8 @@ static int gb_control_get_bundle_version(struct gb_control *control,
&response, sizeof(response));
if (ret) {
dev_err(&intf->dev,
- "failed to get bundle %u class version: %d\n",
- bundle->id, ret);
+ "failed to get bundle %u class version: %d\n",
+ bundle->id, ret);
return ret;
}

@@ -78,7 +77,7 @@ static int gb_control_get_bundle_version(struct gb_control *control,
bundle->class_minor = response.minor;

dev_dbg(&intf->dev, "%s - %u: %u.%u\n", __func__, bundle->id,
- response.major, response.minor);
+ response.major, response.minor);

return 0;
}
@@ -112,7 +111,7 @@ int gb_control_get_manifest_size_operation(struct gb_interface *intf)
NULL, 0, &response, sizeof(response));
if (ret) {
dev_err(&connection->intf->dev,
- "failed to get manifest size: %d\n", ret);
+ "failed to get manifest size: %d\n", ret);
return ret;
}

@@ -168,7 +167,7 @@ int gb_control_disconnecting_operation(struct gb_control *control,
ret = gb_operation_request_send_sync(operation);
if (ret) {
dev_err(&control->dev, "failed to send disconnecting: %d\n",
- ret);
+ ret);
}

gb_operation_put(operation);
@@ -400,7 +399,7 @@ int gb_control_interface_hibernate_abort(struct gb_control *control)
}

static ssize_t vendor_string_show(struct device *dev,
- struct device_attribute *attr, char *buf)
+ struct device_attribute *attr, char *buf)
{
struct gb_control *control = to_gb_control(dev);

@@ -409,7 +408,7 @@ static ssize_t vendor_string_show(struct device *dev,
static DEVICE_ATTR_RO(vendor_string);

static ssize_t product_string_show(struct device *dev,
- struct device_attribute *attr, char *buf)
+ struct device_attribute *attr, char *buf)
{
struct gb_control *control = to_gb_control(dev);

@@ -455,8 +454,8 @@ struct gb_control *gb_control_create(struct gb_interface *intf)
connection = gb_connection_create_control(intf);
if (IS_ERR(connection)) {
dev_err(&intf->dev,
- "failed to create control connection: %ld\n",
- PTR_ERR(connection));
+ "failed to create control connection: %ld\n",
+ PTR_ERR(connection));
kfree(control);
return ERR_CAST(connection);
}
@@ -485,8 +484,8 @@ int gb_control_enable(struct gb_control *control)
ret = gb_connection_enable_tx(control->connection);
if (ret) {
dev_err(&control->connection->intf->dev,
- "failed to enable control connection: %d\n",
- ret);
+ "failed to enable control connection: %d\n",
+ ret);
return ret;
}

@@ -547,8 +546,8 @@ int gb_control_add(struct gb_control *control)
ret = device_add(&control->dev);
if (ret) {
dev_err(&control->dev,
- "failed to register control device: %d\n",
- ret);
+ "failed to register control device: %d\n",
+ ret);
return ret;
}

--
2.17.1