public inbox for linux-staging@lists.linux.dev
 help / color / mirror / Atom feed
* [PATCH v7] staging: vt6655: Match open parentheses in card.c
@ 2024-03-05 21:04 Dorine Tipo
  2024-03-07 17:14 ` Philipp Hortmann
  0 siblings, 1 reply; 2+ messages in thread
From: Dorine Tipo @ 2024-03-05 21:04 UTC (permalink / raw)
  To: gregkh, linux-staging, outreachy; +Cc: Dorine Tipo

Align the function parameters to silence a checkpatch warning.

This patch aligns parameters in functions calculate_ofdmr_parameter(),
card_set_phy_parameter(), card_update_tsf() and card_get_tsf_offset(),
for better readability.

Signed-off-by: Dorine Tipo <dorine.a.tipo@gmail.com>
---
Changelog:
V2: Modified subjects to be unique for each patch, as requested by
<gregkh@linuxfoundation.org>
    Fixed the warnings in the patches as suggested by
<philipp.g.hortmann@gmail.com>

V3: Combined the vt6655 patches into one patch as suggested by
<dan.carpenter@linaro.org>

V4: Removed the multiple signed-off-by as suggested by
    <philipp.g.hortmann@gmail.com>
    Omitted the cover letter as the changes have been combined into one
    patch
    Reworked the patch subject to be concise

V5: Fixed the commit message to "Align
    the function parameters to silence a checkpatch warning." as
    suggested by <dan.carpenter@linaro.org>

V6: Fix trailing white spaces in the patch to silence checkpatch warning

V7: Edited the subject line to include file name as suggested by
    <philipp.g.hortmann@gmail.com>

 drivers/staging/vt6655/card.c | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/drivers/staging/vt6655/card.c b/drivers/staging/vt6655/card.c
index 36183f2a64c1..3f807d898607 100644
--- a/drivers/staging/vt6655/card.c
+++ b/drivers/staging/vt6655/card.c
@@ -81,9 +81,9 @@ static void vt6655_mac_set_bb_type(void __iomem *iobase, u32 mask)
  * Return Value: none
  */
 static void calculate_ofdmr_parameter(unsigned char rate,
-				       u8 bb_type,
-				       unsigned char *tx_rate,
-				       unsigned char *rsv_time)
+				      u8 bb_type,
+				      unsigned char *tx_rate,
+				      unsigned char *rsv_time)
 {
 	switch (rate) {
 	case RATE_6M:
@@ -288,7 +288,7 @@ bool card_set_phy_parameter(struct vnt_private *priv, u8 bb_type)
  * Return Value: none
  */
 bool card_update_tsf(struct vnt_private *priv, unsigned char rx_rate,
-		    u64 bss_timestamp)
+		     u64 bss_timestamp)
 {
 	u64 local_tsf;
 	u64 tsf_offset = 0;
@@ -297,7 +297,7 @@ bool card_update_tsf(struct vnt_private *priv, unsigned char rx_rate,

 	if (bss_timestamp != local_tsf) {
 		tsf_offset = card_get_tsf_offset(rx_rate, bss_timestamp,
-						local_tsf);
+						 local_tsf);
 		/* adjust TSF, HW's TSF add TSF Offset reg */
 		tsf_offset =  le64_to_cpu(tsf_offset);
 		iowrite32((u32)tsf_offset, priv->port_offset + MAC_REG_TSFOFST);
@@ -321,7 +321,7 @@ bool card_update_tsf(struct vnt_private *priv, unsigned char rx_rate,
  * Return Value: true if succeed; otherwise false
  */
 bool card_set_beacon_period(struct vnt_private *priv,
-			  unsigned short beacon_interval)
+			    unsigned short beacon_interval)
 {
 	u64 next_tbtt;

--
2.25.1


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH v7] staging: vt6655: Match open parentheses in card.c
  2024-03-05 21:04 [PATCH v7] staging: vt6655: Match open parentheses in card.c Dorine Tipo
@ 2024-03-07 17:14 ` Philipp Hortmann
  0 siblings, 0 replies; 2+ messages in thread
From: Philipp Hortmann @ 2024-03-07 17:14 UTC (permalink / raw)
  To: Dorine Tipo, gregkh, linux-staging, outreachy

On 3/5/24 22:04, Dorine Tipo wrote:
> Align the function parameters to silence a checkpatch warning.
> 
> This patch aligns parameters in functions calculate_ofdmr_parameter(),
> card_set_phy_parameter(), card_update_tsf() and card_get_tsf_offset(),
> for better readability.
> 
> Signed-off-by: Dorine Tipo <dorine.a.tipo@gmail.com>
> ---
> Changelog:
> V2: Modified subjects to be unique for each patch, as requested by
> <gregkh@linuxfoundation.org>
>      Fixed the warnings in the patches as suggested by
> <philipp.g.hortmann@gmail.com>
> 
> V3: Combined the vt6655 patches into one patch as suggested by
> <dan.carpenter@linaro.org>
> 
> V4: Removed the multiple signed-off-by as suggested by
>      <philipp.g.hortmann@gmail.com>
>      Omitted the cover letter as the changes have been combined into one
>      patch
>      Reworked the patch subject to be concise
> 
> V5: Fixed the commit message to "Align
>      the function parameters to silence a checkpatch warning." as
>      suggested by <dan.carpenter@linaro.org>
> 
> V6: Fix trailing white spaces in the patch to silence checkpatch warning
> 
> V7: Edited the subject line to include file name as suggested by
>      <philipp.g.hortmann@gmail.com>
> 

Hi Dorine,

what is the git repo you are using and which branch?
I cannot apply your patch. See below.

Check the git repo as shown below:

I hope we can find the reason... do you modify the patch with an other 
editor?

Bye Philipp



kernel@matrix-ESPRIMO-P710:~/Documents/git/kernels/staging$ git remote 
show origin
* remote origin
   Fetch URL: 
git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging.git
   Push  URL: 
git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging.git
   HEAD branch: master
   Remote branches:
     bus_cleanup     tracked
     greybus         tracked
     main            tracked
     master          tracked
     staging-linus   tracked
     staging-next    tracked
     staging-octeon  tracked
     staging-testing tracked
   Local branches configured for 'git pull':
     master          merges with remote master
     staging-next    merges with remote staging-next
     staging-testing merges with remote staging-testing
   Local refs configured for 'git push':
     master          pushes to master          (up to date)
     staging-next    pushes to staging-next    (local out of date)
     staging-testing pushes to staging-testing (up to date)

kernel@matrix-ESPRIMO-P710:~/Documents/git/kernels/staging$ git branch -a
   arnd_berg
   ath10k_shorted
   checkout
   master
   rtl8192_next
   staging-next
* staging-testing
   remotes/origin/HEAD -> origin/master
   remotes/origin/bus_cleanup
   remotes/origin/greybus
   remotes/origin/main
   remotes/origin/master
   remotes/origin/staging-linus
   remotes/origin/staging-next
   remotes/origin/staging-octeon
   remotes/origin/staging-testing



kernel@matrix-ESPRIMO-P710:~/Documents/git/kernels/staging$ git status
On branch staging-testing
Your branch is up to date with 'origin/staging-testing'.

nothing to commit, working tree clean
kernel@matrix-ESPRIMO-P710:~/Documents/git/kernels/staging$ git pull
Already up to date.
kernel@matrix-ESPRIMO-P710:~/Documents/git/kernels/staging$ git apply 
--reject --whitespace=fix ~/Downloads/20240305-\[PATCH\ v7\]\ staging_\ 
vt6655_\ Match\ open\ parentheses\ in\ card.c-14951.txt
Checking patch drivers/staging/vt6655/card.c...
error: while searching for:
  * Return Value: none
  */
static void calculate_ofdmr_parameter(unsigned char rate,
				       u8 bb_type,
				       unsigned char *tx_rate,
				       unsigned char *rsv_time)
{
	switch (rate) {
	case RATE_6M:

error: patch failed: drivers/staging/vt6655/card.c:81
error: while searching for:
  * Return Value: none
  */
bool card_update_tsf(struct vnt_private *priv, unsigned char rx_rate,
		    u64 bss_timestamp)
{
	u64 local_tsf;
	u64 tsf_offset = 0;

error: patch failed: drivers/staging/vt6655/card.c:288
error: while searching for:

	if (bss_timestamp != local_tsf) {
		tsf_offset = card_get_tsf_offset(rx_rate, bss_timestamp,
						local_tsf);
		/* adjust TSF, HW's TSF add TSF Offset reg */
		tsf_offset =  le64_to_cpu(tsf_offset);
		iowrite32((u32)tsf_offset, priv->port_offset + MAC_REG_TSFOFST);

error: patch failed: drivers/staging/vt6655/card.c:297
error: while searching for:
  * Return Value: true if succeed; otherwise false
  */
bool card_set_beacon_period(struct vnt_private *priv,
			  unsigned short beacon_interval)
{
	u64 next_tbtt;


error: patch failed: drivers/staging/vt6655/card.c:321
Applying patch drivers/staging/vt6655/card.c with 4 rejects...
Rejected hunk #1.
Rejected hunk #2.
Rejected hunk #3.
Rejected hunk #4.
kernel@matrix-ESPRIMO-P710:~/Documents/git/kernels/staging$


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2024-03-07 17:15 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-03-05 21:04 [PATCH v7] staging: vt6655: Match open parentheses in card.c Dorine Tipo
2024-03-07 17:14 ` Philipp Hortmann

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox