2023-10-22 10:38:42

by Nandha Kumar Singaram

[permalink] [raw]
Subject: [PATCH 0/3] staging: greybus: Coding style cleanup patches

This patchset performs code cleanup in greybus driver as per
linux coding style and may be applied in any sequence.

Nandha Kumar Singaram (3):
staging: greybus: Modify lines end with a '('
staging: greybus: Alignment should match open parenthesis
staging: greybus: fixed prefer using ftrace warning

drivers/staging/greybus/bootrom.c | 2 --
drivers/staging/greybus/camera.c | 13 ++++++-------
2 files changed, 6 insertions(+), 9 deletions(-)

--
2.25.1


2023-10-22 10:39:47

by Nandha Kumar Singaram

[permalink] [raw]
Subject: [PATCH 1/3] staging: greybus: Modify lines end with a '('

Adhere to linux coding style. Reported by checkpatch.pl:
CHECK: Lines should not end with a '('

Signed-off-by: Nandha Kumar Singaram <[email protected]>
---
drivers/staging/greybus/camera.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/staging/greybus/camera.c b/drivers/staging/greybus/camera.c
index ae49e37a87e9..feddceddffbb 100644
--- a/drivers/staging/greybus/camera.c
+++ b/drivers/staging/greybus/camera.c
@@ -267,8 +267,7 @@ static int gb_camera_get_max_pkt_size(struct gb_camera *gcam,
* Validate the stream configuration response verifying padding is correctly
* set and the returned number of streams is supported
*/
-static const int gb_camera_configure_streams_validate_response(
- struct gb_camera *gcam,
+static const int gb_camera_configure_streams_validate_response(struct gb_camera *gcam,
struct gb_camera_configure_streams_response *resp,
unsigned int nstreams)
{
--
2.25.1

2023-10-22 10:41:20

by Nandha Kumar Singaram

[permalink] [raw]
Subject: [PATCH 2/3] staging: greybus: Alignment should match open parenthesis

Adhere to linux coding style. Reported by checkpatch.pl:
CHECK: Alignment should match open parenthesis

Signed-off-by: Nandha Kumar Singaram <[email protected]>
---
drivers/staging/greybus/camera.c | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/drivers/staging/greybus/camera.c b/drivers/staging/greybus/camera.c
index feddceddffbb..40d3b8aca8f0 100644
--- a/drivers/staging/greybus/camera.c
+++ b/drivers/staging/greybus/camera.c
@@ -220,7 +220,7 @@ static int gb_camera_operation_sync_flags(struct gb_connection *connection,
}

static int gb_camera_get_max_pkt_size(struct gb_camera *gcam,
- struct gb_camera_configure_streams_response *resp)
+ struct gb_camera_configure_streams_response *resp)
{
unsigned int max_pkt_size = 0;
unsigned int i;
@@ -377,8 +377,8 @@ struct ap_csi_config_request {
#define GB_CAMERA_CSI_CLK_FREQ_MARGIN 150000000U

static int gb_camera_setup_data_connection(struct gb_camera *gcam,
- struct gb_camera_configure_streams_response *resp,
- struct gb_camera_csi_params *csi_params)
+ struct gb_camera_configure_streams_response *resp,
+ struct gb_camera_csi_params *csi_params)
{
struct ap_csi_config_request csi_cfg;
struct gb_connection *conn;
@@ -782,8 +782,8 @@ static ssize_t gb_camera_op_capabilities(void *priv, char *data, size_t len)
}

static int gb_camera_op_configure_streams(void *priv, unsigned int *nstreams,
- unsigned int *flags, struct gb_camera_stream *streams,
- struct gb_camera_csi_params *csi_params)
+ unsigned int *flags, struct gb_camera_stream *streams,
+ struct gb_camera_csi_params *csi_params)
{
struct gb_camera *gcam = priv;
struct gb_camera_stream_config *gb_streams;
--
2.25.1

2023-10-22 10:42:37

by Nandha Kumar Singaram

[permalink] [raw]
Subject: [PATCH 3/3] staging: greybus: fixed prefer using ftrace warning

Adhere to linux coding style. Reported by checkpatch.pl:
WARNING: Unnecessary ftrace-like logging - prefer using ftrace

Signed-off-by: Nandha Kumar Singaram <[email protected]>
---
drivers/staging/greybus/bootrom.c | 2 --
1 file changed, 2 deletions(-)

diff --git a/drivers/staging/greybus/bootrom.c b/drivers/staging/greybus/bootrom.c
index a8efb86de140..79581457c4af 100644
--- a/drivers/staging/greybus/bootrom.c
+++ b/drivers/staging/greybus/bootrom.c
@@ -491,8 +491,6 @@ static void gb_bootrom_disconnect(struct gb_bundle *bundle)
{
struct gb_bootrom *bootrom = greybus_get_drvdata(bundle);

- dev_dbg(&bundle->dev, "%s\n", __func__);
-
gb_connection_disable(bootrom->connection);

/* Disable timeouts */
--
2.25.1

2023-10-22 11:19:00

by Greg Kroah-Hartman

[permalink] [raw]
Subject: Re: [PATCH 1/3] staging: greybus: Modify lines end with a '('

On Sun, Oct 22, 2023 at 03:39:28AM -0700, Nandha Kumar Singaram wrote:
> Adhere to linux coding style. Reported by checkpatch.pl:
> CHECK: Lines should not end with a '('
>
> Signed-off-by: Nandha Kumar Singaram <[email protected]>
> ---
> drivers/staging/greybus/camera.c | 3 +--
> 1 file changed, 1 insertion(+), 2 deletions(-)

Subject line should be:
"staging: greybus: camera: Modify..."
right?

thanks,

greg k-h

2023-10-22 11:19:21

by Greg Kroah-Hartman

[permalink] [raw]
Subject: Re: [PATCH 2/3] staging: greybus: Alignment should match open parenthesis

On Sun, Oct 22, 2023 at 03:40:57AM -0700, Nandha Kumar Singaram wrote:
> Adhere to linux coding style. Reported by checkpatch.pl:
> CHECK: Alignment should match open parenthesis
>
> Signed-off-by: Nandha Kumar Singaram <[email protected]>
> ---
> drivers/staging/greybus/camera.c | 10 +++++-----
> 1 file changed, 5 insertions(+), 5 deletions(-)

Same subject line problem :(

2023-10-22 11:19:42

by Greg Kroah-Hartman

[permalink] [raw]
Subject: Re: [PATCH 3/3] staging: greybus: fixed prefer using ftrace warning

On Sun, Oct 22, 2023 at 03:42:26AM -0700, Nandha Kumar Singaram wrote:
> Adhere to linux coding style. Reported by checkpatch.pl:
> WARNING: Unnecessary ftrace-like logging - prefer using ftrace
>
> Signed-off-by: Nandha Kumar Singaram <[email protected]>
> ---
> drivers/staging/greybus/bootrom.c | 2 --
> 1 file changed, 2 deletions(-)

Again, subject line should have "bootrom" in there somewhere, right?

thanks,

greg k-h

2023-10-22 12:04:19

by Nandha Kumar Singaram

[permalink] [raw]
Subject: Re: [PATCH 3/3] staging: greybus: fixed prefer using ftrace warning

On Sun, Oct 22, 2023 at 01:19:33PM +0200, Greg Kroah-Hartman wrote:
> On Sun, Oct 22, 2023 at 03:42:26AM -0700, Nandha Kumar Singaram wrote:
> > Adhere to linux coding style. Reported by checkpatch.pl:
> > WARNING: Unnecessary ftrace-like logging - prefer using ftrace
> >
> > Signed-off-by: Nandha Kumar Singaram <[email protected]>
> > ---
> > drivers/staging/greybus/bootrom.c | 2 --
> > 1 file changed, 2 deletions(-)
>
> Again, subject line should have "bootrom" in there somewhere, right?
>
> thanks,
>
> greg k-h

Will update and share the patchset again.

Thanks,
Nandha Kumar