staging:gpib:agilent_82350b: Code cleanup, spelling fixes
v3 cover staging:gpib:agilent_82350b: Code cleanup, spelling fixes
From: Ravi Kumar Kairi <[email protected]>
This patch series addresses the following changes:
1. Fixing spelling mistakes such as "havn't" → "haven't"
2. Removing unnecessary commented-out code
3. Cleaning up whitespace and formatting inconsistencies
4. Removing an empty line in if{} which was causing it to be read as a single line
These are minor changes aimed at improving code readability and maintainability.
I appreciate your time in reviewing this series. and I'm deeply sorry for the spam beacuse I messed up last time I sumbiited Thanks,
Ravi Kumar Kairi (4):
staging:gpib:agilent_82350b: Fixed spelling error staging:gpib:agilent_82350b: Removed commented out code staging:gpib:agilent_82350b:Removed blank line staging:gpib:agilent_82350b: Fix Indent issue with block
.../staging/gpib/agilent_82350b/agilent_82350b.c | 16 +--------------- 1 file changed, 1 insertion(+), 15 deletions(-)
Signature · 1 line
2.48.1
PATCH v2 1/4 staging:gpib:agilent_82350b: Fixed spelling error
From: Ravi Kumar Kairi <[email protected]>
fixed havn't -> haven't
--- drivers/staging/gpib/agilent_82350b/agilent_82350b.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/staging/gpib/agilent_82350b/agilent_82350b.c +1 -1
@@ -121,7 +121,7 @@ static int agilent_82350b_accel_read(gpib_board_t *board, uint8_t *buffer, size_writeb (DIRECTION_GPIB_TO_HOST , a_priv->gpib_base +SRAM_ACCESS_CONTROL_REG );if (retval <0 )return retval; -// read last bytes if we havn't received an END yet +// read last bytes if we haven't received an END yet if (*end ==0 ) {size_t num_bytes;// try to make sure we holdoff after last byte read
Signature · 1 line
2.48.1
PATCH v2 2/4 staging:gpib:agilent_82350b: Removed commented out code
In reply to Ravi Kumar kairiFrom: Ravi Kumar Kairi <[email protected]>
Removed commented out debugging code to make code look cleaner as spcified by TODO
--- drivers/staging/gpib/agilent_82350b/agilent_82350b.c | 9 --------- 1 file changed, 9 deletions(-)
drivers/staging/gpib/agilent_82350b/agilent_82350b.c +0 -9
@@ -176,7 +176,6 @@ static int agilent_82350b_accel_write(gpib_board_t *board, uint8_t *buffer, size event_status =read_and_clear_event_status (board); -//pr_info("ag_ac_wr: event status 0x%x tms state 0x%lx\n", event_status, tms_priv->state); #ifdef EXPERIMENTAL pr_info ("ag_ac_wr: wait for previous BO to complete if any\n" );
@@ -190,13 +189,11 @@ static int agilent_82350b_accel_write(gpib_board_t *board, uint8_t *buffer, sizereturn retval;#endif -//pr_info("ag_ac_wr: sending first byte\n"); retval =agilent_82350b_write (board, buffer,1 ,0 , &num_bytes); *bytes_written += num_bytes;if (retval <0 )return retval; -//pr_info("ag_ac_wr: %ld bytes eoi %d tms state 0x%lx\n",length, send_eoi, tms_priv->state); write_byte (tms_priv, tms_priv->imr0_bits & ~HR_BOIE ,IMR0 );for (i =1 ; i < fifotransferlength;) {
@@ -210,8 +207,6 @@ static int agilent_82350b_accel_write(gpib_board_t *board, uint8_t *buffer, size }writeb (ENABLE_TI_TO_SRAM , a_priv->gpib_base +SRAM_ACCESS_CONTROL_REG ); -//pr_info("ag_ac_wr: send block: %d bytes tms 0x%lx\n", block_size, -// tms_priv->state); if (agilent_82350b_fifo_is_halted (a_priv)) {writeb (RESTART_STREAM_BIT , a_priv->gpib_base +STREAM_STATUS_REG );
@@ -226,7 +221,6 @@ static int agilent_82350b_accel_write(gpib_board_t *board, uint8_t *buffer, size test_bit(TIMO_NUM, &board->status));writeb (0 , a_priv->gpib_base +SRAM_ACCESS_CONTROL_REG ); num_bytes = block_size -read_transfer_counter (a_priv); -//pr_info("ag_ac_wr: sent %ld bytes tms 0x%lx\n", num_bytes, tms_priv->state); *bytes_written += num_bytes; retval =translate_wait_return_value (board, retval);
@@ -238,8 +232,6 @@ static int agilent_82350b_accel_write(gpib_board_t *board, uint8_t *buffer, sizereturn retval;if (send_eoi) { -//pr_info("ag_ac_wr: sending last byte with eoi byte no: %d\n", -// fifotransferlength+1); retval =agilent_82350b_write (board, buffer + fifotransferlength,1 , send_eoi, &num_bytes);
@@ -284,7 +276,6 @@ static irqreturn_t agilent_82350b_interrupt(int irq, void *arg)tms9914_interrupt_have_status (board, &a_priv->tms9914_priv, tms9914_status1, tms9914_status2); } -//pr_info("event_status=0x%x s1 %x s2 %x\n", event_status,tms9914_status1,tms9914_status2); //write-clear status bits if (event_status & (BUFFER_END_STATUS_BIT |TERM_COUNT_STATUS_BIT )) { writeb(event_status & (BUFFER_END_STATUS_BIT | TERM_COUNT_STATUS_BIT),
Signature · 1 line
2.48.1
Re: [PATCH v3 2/4] [PATCH V2 2/4] staging:gpib:agilent_82350b: Removed commented out code
Quoted 15 lines · Ravi Kumar kairi
From: Ravi Kumar Kairi <[email protected]>
Removed commented out debugging code to make code look cleaner as spcified by TODO
Signed-off-by Ravi Kumar Kairi <[email protected]>--- drivers/staging/gpib/agilent_82350b/agilent_82350b.c | 9 --------- 1 file changed, 9 deletions(-)drivers/staging/gpib/agilent_82350b/agilent_82350b.c +0
-0
drivers/staging/gpib/agilent_82350b/agilent_82350b.c static int agilent_82350b_accel_write(gpib_board_t *board, uint8_t *buffer, size · line 179
Quoted 5 lines
drivers/staging/gpib/agilent_82350b/agilent_82350b.c +0
-1@@ -176,7 +176,6 @@ static int agilent_82350b_accel_write(gpib_board_t *board, uint8_t *buffer, size event_status =read_and_clear_event_status (board); -//pr_info("ag_ac_wr: event status 0x%x tms state 0x%lx\n", event_status, tms_priv->state);
Same comments as for v2.
You're not supposed to mix delete comments with delete duplicate blank lines but at the same time, you can't introduce NEW double blank line warnings.
regards,
dan carpenter
A message that is not in the archive (sent off-list or not yet received): CAEEw=4mN+Y8G6a92baCH6kANcpmTFDzn_LSS3XRfXAFdPZxo8A@mail.gmail.com
Re: [PATCH v3 2/4] [PATCH V2 2/4] staging:gpib:agilent_82350b: Removed commented out code
Quoted 2 lines · Ravi Kumar Kairi
So should I just do the whole deleting comment thing in one go? Instead of first deleted comment and then deleted blank space?
Hm... I had to check. All the issues addressed in patch 3 were introduced by patch 2. So, yes, combine patch 2 and 3.
regards,
dan carpenter
PATCH v2 3/4 staging:gpib:agilent_82350b:Removed blank line
In reply to Ravi Kumar kairiFrom: Ravi Kumar Kairi <[email protected]>
removed few empty lines that were causing checkpatch script warnings
--- drivers/staging/gpib/agilent_82350b/agilent_82350b.c | 4 ---- 1 file changed, 4 deletions(-)
drivers/staging/gpib/agilent_82350b/agilent_82350b.c +0 -4
@@ -176,7 +176,6 @@ static int agilent_82350b_accel_write(gpib_board_t *board, uint8_t *buffer, size event_status =read_and_clear_event_status (board); -#ifdef EXPERIMENTAL pr_info ("ag_ac_wr: wait for previous BO to complete if any\n" ); retval = wait_event_interruptible(board->wait,
@@ -193,8 +192,6 @@ static int agilent_82350b_accel_write(gpib_board_t *board, uint8_t *buffer, size *bytes_written += num_bytes;if (retval <0 )return retval; - -write_byte (tms_priv, tms_priv->imr0_bits & ~HR_BOIE ,IMR0 );for (i =1 ; i < fifotransferlength;) {clear_bit (WRITE_READY_BN , &tms_priv->state);
@@ -207,7 +204,6 @@ static int agilent_82350b_accel_write(gpib_board_t *board, uint8_t *buffer, size }writeb (ENABLE_TI_TO_SRAM , a_priv->gpib_base +SRAM_ACCESS_CONTROL_REG ); -if (agilent_82350b_fifo_is_halted (a_priv)) {writeb (RESTART_STREAM_BIT , a_priv->gpib_base +STREAM_STATUS_REG );// pr_info("ag_ac_wr: needed restart\n");
Signature · 1 line
2.48.1
Greg KH
maintainerRe: [PATCH v3 3/4] [PATCH V2 3/4] staging:gpib:agilent_82350b:Removed blank line
Quoted 22 lines · Ravi Kumar kairi
From: Ravi Kumar Kairi <[email protected]>
removed few empty lines that were causing checkpatch script warnings
Signed-off-by Ravi Kumar Kairi <[email protected]>--- drivers/staging/gpib/agilent_82350b/agilent_82350b.c | 4 ---- 1 file changed, 4 deletions(-)drivers/staging/gpib/agilent_82350b/agilent_82350b.c +0
-1@@ -176,7 +176,6 @@ static int agilent_82350b_accel_write(gpib_board_t *board, uint8_t *buffer, size event_status =read_and_clear_event_status (board); -#ifdef EXPERIMENTAL pr_info ("ag_ac_wr: wait for previous BO to complete if any\n" ); retval = wait_event_interruptible(board->wait,
drivers/staging/gpib/agilent_82350b/agilent_82350b.c static int agilent_82350b_accel_write(gpib_board_t *board, uint8_t *buffer, size · line 197
Quoted 5 lines
drivers/staging/gpib/agilent_82350b/agilent_82350b.c +0
-2@@ -193,8 +192,6 @@ static int agilent_82350b_accel_write(gpib_board_t *board, uint8_t *buffer, size *bytes_written += num_bytes;if (retval <0 )return retval; - -
Why did you remove both lines here? One is fine.
And your subject line needs an extra ' ' in it, right?
thanks,
greg k-h
PATCH v2 4/4 staging:gpib:agilent_82350b: Fix Indent issue with block
In reply to Ravi Kumar kairiFrom: Ravi Kumar Kairi <[email protected]>
There was a empty line, which was causing the checkpatch script to think it's a single line statment, after removing the empty line it's no longer asking to check that line.
--- drivers/staging/gpib/agilent_82350b/agilent_82350b.c | 1 - 1 file changed, 1 deletion(-)
drivers/staging/gpib/agilent_82350b/agilent_82350b.c +0 -1
@@ -228,7 +228,6 @@ static int agilent_82350b_accel_write(gpib_board_t *board, uint8_t *buffer, sizereturn retval;if (send_eoi) { - retval =agilent_82350b_write (board, buffer + fifotransferlength,1 , send_eoi, &num_bytes); *bytes_written += num_bytes;
Signature · 1 line
2.48.1
Greg KH
maintainerRe: [PATCH v3 4/4] [PATCH V2 4/4] staging:gpib:agilent_82350b: Fix Indent issue with block
Quoted 16 lines · Ravi Kumar kairi
From: Ravi Kumar Kairi <[email protected]>
There was a empty line, which was causing the checkpatch script to think it's a single line statment, after removing the empty line it's no longer asking to check that line.
Signed-off-by Ravi Kumar Kairi <[email protected]>--- drivers/staging/gpib/agilent_82350b/agilent_82350b.c | 1 - 1 file changed, 1 deletion(-)drivers/staging/gpib/agilent_82350b/agilent_82350b.c +0
-0
drivers/staging/gpib/agilent_82350b/agilent_82350b.c static int agilent_82350b_accel_write(gpib_board_t *board, uint8_t *buffer, size · line 233
Quoted 7 lines
drivers/staging/gpib/agilent_82350b/agilent_82350b.c +0
-1@@ -228,7 +228,6 @@ static int agilent_82350b_accel_write(gpib_board_t *board, uint8_t *buffer, sizereturn retval;if (send_eoi) { - retval =agilent_82350b_write (board, buffer + fifotransferlength,1 , send_eoi, &num_bytes); *bytes_written += num_bytes;
The subject line is really odd as this change has nothing to do with indentation :(
thanks,
greg k-h
Re: [PATCH v3 4/4] [PATCH V2 4/4] staging:gpib:agilent_82350b: Fix Indent issue with block
Quoted 27 lines · Greg KH
Quoted 16 lines · Ravi Kumar kairi
From: Ravi Kumar Kairi <[email protected]>
There was a empty line, which was causing the checkpatch script to think it's a single line statment, after removing the empty line it's no longer asking to check that line.
Signed-off-by Ravi Kumar Kairi <[email protected]>--- drivers/staging/gpib/agilent_82350b/agilent_82350b.c | 1 - 1 file changed, 1 deletion(-)drivers/staging/gpib/agilent_82350b/agilent_82350b.c +0
-0drivers/staging/gpib/agilent_82350b/agilent_82350b.c static int agilent_82350b_accel_write(gpib_board_t *board, uint8_t *buffer, size · line 233
Quoted 7 lines
drivers/staging/gpib/agilent_82350b/agilent_82350b.c +0
-1@@ -228,7 +228,6 @@ static int agilent_82350b_accel_write(gpib_board_t *board, uint8_t *buffer, sizereturn retval;if (send_eoi) { - retval =agilent_82350b_write (board, buffer + fifotransferlength,1 , send_eoi, &num_bytes); *bytes_written += num_bytes;The subject line is really odd as this change has nothing to do with indentation :(
Quoted 3 lines
thanks,
greg k-h
Yes, I now realize it ;-; and will do better next time, btw I came here from your foss conf video on YouTube
Greg KH
maintainerQuoted 19 lines · Ravi Kumar kairi
From: Ravi Kumar Kairi <[email protected]>
This patch series addresses the following changes:
1. Fixing spelling mistakes such as "havn't" → "haven't"
2. Removing unnecessary commented-out code
3. Cleaning up whitespace and formatting inconsistencies
4. Removing an empty line in if{} which was causing it to be read as a single lineThese are minor changes aimed at improving code readability and maintainability.
I appreciate your time in reviewing this series. and I'm deeply sorry for the spam beacuse I messed up last time I sumbiited Thanks,
Ravi Kumar Kairi (4):
staging:gpib:agilent_82350b: Fixed spelling error staging:gpib:agilent_82350b: Removed commented out code staging:gpib:agilent_82350b:Removed blank line staging:gpib:agilent_82350b: Fix Indent issue with block
Quoted 7 lines
.../staging/gpib/agilent_82350b/agilent_82350b.c | 16 +--------------- 1 file changed, 1 insertion(+), 15 deletions(-)Signature · 1 line
2.48.1
Hi,
This is the friendly patch-bot of Greg Kroah-Hartman. You have sent him a patch that has triggered this response. He used to manually respond to these common problems, but in order to save his sanity (he kept writing the same thing over and over, yet to different people), I was created. Hopefully you will not take offence and will fix the problem in your patch and resubmit it so that it can be accepted into the Linux kernel tree.
You are receiving this message because of the following common error(s) as indicated below:
- This looks like a new version of a previously submitted patch, but you did not list below the --- line any changes from the previous version. Please read the section entitled "The canonical patch format" in the kernel file, Documentation/process/submitting-patches.rst for what needs to be done here to properly describe this.
If you wish to discuss this problem further, or you have questions about how to resolve this issue, please feel free to respond to this email and Greg will reply once he has dug out from the pending patches received from other developers.
thanks,
greg k-h's patch email bot