* [PATCH 0/4] staging: vme_user: fix checks reported in vme_fake.c
@ 2023-08-26 21:05 Alexon Oliveira
2023-08-26 21:05 ` [PATCH 1/4] staging: vme_user: fix check alignment of open parenthesis " Alexon Oliveira
` (4 more replies)
0 siblings, 5 replies; 6+ messages in thread
From: Alexon Oliveira @ 2023-08-26 21:05 UTC (permalink / raw)
To: gregkh; +Cc: martyn, manohar.vanga, linux-kernel, linux-staging,
Alexon Oliveira
The goal of this series is to fix all warnings related to
aligment of open parenthesis, lines not ending with '(',
unnecessary blank lines and unnecessary space after a cast
in the vme_fake.c file, as reported by checkpatch to adhere
to the Linux kernel coding-style guidelines.
Alexon Oliveira (4):
staging: vme_user: fix check alignment of open parenthesis in
vme_fake.c
staging: vme_user: fix check lines not ending with '(' in vme_fake.c
staging: vme_user: fix check unnecessary blank lines in vme_fake.c
staging: vme_user: fix check unnecessary space after a cast in
vme_fake.c
drivers/staging/vme_user/vme_fake.c | 72 ++++++++++++++---------------
1 file changed, 35 insertions(+), 37 deletions(-)
--
2.41.0
^ permalink raw reply [flat|nested] 6+ messages in thread* [PATCH 1/4] staging: vme_user: fix check alignment of open parenthesis in vme_fake.c 2023-08-26 21:05 [PATCH 0/4] staging: vme_user: fix checks reported in vme_fake.c Alexon Oliveira @ 2023-08-26 21:05 ` Alexon Oliveira 2023-08-26 21:05 ` [PATCH 2/4] staging: vme_user: fix check lines not ending with '(' " Alexon Oliveira ` (3 subsequent siblings) 4 siblings, 0 replies; 6+ messages in thread From: Alexon Oliveira @ 2023-08-26 21:05 UTC (permalink / raw) To: gregkh; +Cc: martyn, manohar.vanga, linux-kernel, linux-staging, Alexon Oliveira Fixed all CHECK: Alignment should match open parenthesis as reported by checkpatch to adhere to the Linux kernel coding-style guidelines. Signed-off-by: Alexon Oliveira <alexondunkan@gmail.com> --- drivers/staging/vme_user/vme_fake.c | 65 +++++++++++++++-------------- 1 file changed, 33 insertions(+), 32 deletions(-) diff --git a/drivers/staging/vme_user/vme_fake.c b/drivers/staging/vme_user/vme_fake.c index 7c53a8a7b79b..a88d2c8a785b 100644 --- a/drivers/staging/vme_user/vme_fake.c +++ b/drivers/staging/vme_user/vme_fake.c @@ -105,7 +105,7 @@ static void fake_VIRQ_tasklet(unsigned long data) * Configure VME interrupt */ static void fake_irq_set(struct vme_bridge *fake_bridge, int level, - int state, int sync) + int state, int sync) { /* Nothing to do */ } @@ -125,7 +125,7 @@ static dma_addr_t fake_ptr_to_pci(void *addr) * interrupt to be acked. */ static int fake_irq_generate(struct vme_bridge *fake_bridge, int level, - int statid) + int statid) { struct fake_driver *bridge; @@ -152,8 +152,8 @@ static int fake_irq_generate(struct vme_bridge *fake_bridge, int level, * Initialize a slave window with the requested attributes. */ static int fake_slave_set(struct vme_slave_resource *image, int enabled, - unsigned long long vme_base, unsigned long long size, - dma_addr_t buf_base, u32 aspace, u32 cycle) + unsigned long long vme_base, unsigned long long size, + dma_addr_t buf_base, u32 aspace, u32 cycle) { unsigned int i, granularity = 0; unsigned long long vme_bound; @@ -221,8 +221,8 @@ static int fake_slave_set(struct vme_slave_resource *image, int enabled, * Get slave window configuration. */ static int fake_slave_get(struct vme_slave_resource *image, int *enabled, - unsigned long long *vme_base, unsigned long long *size, - dma_addr_t *buf_base, u32 *aspace, u32 *cycle) + unsigned long long *vme_base, unsigned long long *size, + dma_addr_t *buf_base, u32 *aspace, u32 *cycle) { unsigned int i; struct fake_driver *bridge; @@ -249,8 +249,8 @@ static int fake_slave_get(struct vme_slave_resource *image, int *enabled, * Set the attributes of an outbound window. */ static int fake_master_set(struct vme_master_resource *image, int enabled, - unsigned long long vme_base, unsigned long long size, - u32 aspace, u32 cycle, u32 dwidth) + unsigned long long vme_base, unsigned long long size, + u32 aspace, u32 cycle, u32 dwidth) { int retval = 0; unsigned int i; @@ -335,8 +335,8 @@ static int fake_master_set(struct vme_master_resource *image, int enabled, * Set the attributes of an outbound window. */ static int __fake_master_get(struct vme_master_resource *image, int *enabled, - unsigned long long *vme_base, unsigned long long *size, - u32 *aspace, u32 *cycle, u32 *dwidth) + unsigned long long *vme_base, unsigned long long *size, + u32 *aspace, u32 *cycle, u32 *dwidth) { unsigned int i; struct fake_driver *bridge; @@ -356,15 +356,15 @@ static int __fake_master_get(struct vme_master_resource *image, int *enabled, } static int fake_master_get(struct vme_master_resource *image, int *enabled, - unsigned long long *vme_base, unsigned long long *size, - u32 *aspace, u32 *cycle, u32 *dwidth) + unsigned long long *vme_base, unsigned long long *size, + u32 *aspace, u32 *cycle, u32 *dwidth) { int retval; spin_lock(&image->lock); retval = __fake_master_get(image, enabled, vme_base, size, aspace, - cycle, dwidth); + cycle, dwidth); spin_unlock(&image->lock); @@ -511,7 +511,7 @@ static noinline_for_stack u32 fake_vmeread32(struct fake_driver *bridge, } static ssize_t fake_master_read(struct vme_master_resource *image, void *buf, - size_t count, loff_t offset) + size_t count, loff_t offset) { int retval; u32 aspace, cycle, dwidth; @@ -700,7 +700,7 @@ static noinline_for_stack void fake_vmewrite32(struct fake_driver *bridge, } static ssize_t fake_master_write(struct vme_master_resource *image, void *buf, - size_t count, loff_t offset) + size_t count, loff_t offset) { int retval = 0; u32 aspace, cycle, dwidth; @@ -739,7 +739,7 @@ static ssize_t fake_master_write(struct vme_master_resource *image, void *buf, if ((addr + done) & 0x2) { if ((count - done) < 2) { fake_vmewrite8(bridge, (u8 *)(buf + done), - addr + done, aspace, cycle); + addr + done, aspace, cycle); done += 1; goto out; } else { @@ -768,7 +768,7 @@ static ssize_t fake_master_write(struct vme_master_resource *image, void *buf, count32 = (count - done); while (done < count32) { fake_vmewrite8(bridge, (u8 *)(buf + done), addr + done, - aspace, cycle); + aspace, cycle); done += 1; } @@ -784,7 +784,7 @@ static ssize_t fake_master_write(struct vme_master_resource *image, void *buf, if ((count - done) & 0x1) { fake_vmewrite8(bridge, (u8 *)(buf + done), addr + done, aspace, - cycle); + cycle); done += 1; } @@ -802,8 +802,8 @@ static ssize_t fake_master_write(struct vme_master_resource *image, void *buf, * Requires a previously configured master window, returns final value. */ static unsigned int fake_master_rmw(struct vme_master_resource *image, - unsigned int mask, unsigned int compare, unsigned int swap, - loff_t offset) + unsigned int mask, unsigned int compare, + unsigned int swap, loff_t offset) { u32 tmp, base; u32 aspace, cycle; @@ -848,7 +848,7 @@ static unsigned int fake_master_rmw(struct vme_master_resource *image, * callback is attached and disabled when the last callback is removed. */ static int fake_lm_set(struct vme_lm_resource *lm, unsigned long long lm_base, - u32 aspace, u32 cycle) + u32 aspace, u32 cycle) { int i; struct vme_bridge *fake_bridge; @@ -894,7 +894,8 @@ static int fake_lm_set(struct vme_lm_resource *lm, unsigned long long lm_base, * or disabled. */ static int fake_lm_get(struct vme_lm_resource *lm, - unsigned long long *lm_base, u32 *aspace, u32 *cycle) + unsigned long long *lm_base, + u32 *aspace, u32 *cycle) { struct fake_driver *bridge; @@ -917,7 +918,7 @@ static int fake_lm_get(struct vme_lm_resource *lm, * Callback will be passed the monitor triggered. */ static int fake_lm_attach(struct vme_lm_resource *lm, int monitor, - void (*callback)(void *), void *data) + void (*callback)(void *), void *data) { struct vme_bridge *fake_bridge; struct fake_driver *bridge; @@ -995,7 +996,7 @@ static int fake_slot_get(struct vme_bridge *fake_bridge) } static void *fake_alloc_consistent(struct device *parent, size_t size, - dma_addr_t *dma) + dma_addr_t *dma) { void *alloc = kmalloc(size, GFP_KERNEL); @@ -1006,7 +1007,7 @@ static void *fake_alloc_consistent(struct device *parent, size_t size, } static void fake_free_consistent(struct device *parent, size_t size, - void *vaddr, dma_addr_t dma) + void *vaddr, dma_addr_t dma) { kfree(vaddr); /* @@ -1094,7 +1095,7 @@ static int __init fake_init(void) mutex_init(&fake_device->vme_int); mutex_init(&fake_bridge->irq_mtx); tasklet_init(&fake_device->int_tasklet, fake_VIRQ_tasklet, - (unsigned long) fake_bridge); + (unsigned long) fake_bridge); strcpy(fake_bridge->name, driver_name); @@ -1118,10 +1119,10 @@ static int __init fake_init(void) VME_PROG | VME_DATA; master_image->width_attr = VME_D16 | VME_D32; memset(&master_image->bus_resource, 0, - sizeof(struct resource)); + sizeof(struct resource)); master_image->kern_base = NULL; list_add_tail(&master_image->list, - &fake_bridge->master_resources); + &fake_bridge->master_resources); } /* Add slave windows to list */ @@ -1144,7 +1145,7 @@ static int __init fake_init(void) VME_2eSST267 | VME_2eSST320 | VME_SUPER | VME_USER | VME_PROG | VME_DATA; list_add_tail(&slave_image->list, - &fake_bridge->slave_resources); + &fake_bridge->slave_resources); } /* Add location monitor to list */ @@ -1179,7 +1180,7 @@ static int __init fake_init(void) fake_bridge->free_consistent = fake_free_consistent; pr_info("Board is%s the VME system controller\n", - (geoid == 1) ? "" : " not"); + (geoid == 1) ? "" : " not"); pr_info("VME geographical address is set to %d\n", geoid); @@ -1220,7 +1221,7 @@ static int __init fake_init(void) /* resources are stored in link list */ list_for_each_safe(pos, n, &fake_bridge->master_resources) { master_image = list_entry(pos, struct vme_master_resource, - list); + list); list_del(pos); kfree(master_image); } @@ -1275,7 +1276,7 @@ static void __exit fake_exit(void) /* resources are stored in link list */ list_for_each_safe(pos, tmplist, &fake_bridge->master_resources) { master_image = list_entry(pos, struct vme_master_resource, - list); + list); list_del(pos); kfree(master_image); } -- 2.41.0 ^ permalink raw reply related [flat|nested] 6+ messages in thread
* [PATCH 2/4] staging: vme_user: fix check lines not ending with '(' in vme_fake.c 2023-08-26 21:05 [PATCH 0/4] staging: vme_user: fix checks reported in vme_fake.c Alexon Oliveira 2023-08-26 21:05 ` [PATCH 1/4] staging: vme_user: fix check alignment of open parenthesis " Alexon Oliveira @ 2023-08-26 21:05 ` Alexon Oliveira 2023-08-26 21:05 ` [PATCH 3/4] staging: vme_user: fix check unnecessary blank lines " Alexon Oliveira ` (2 subsequent siblings) 4 siblings, 0 replies; 6+ messages in thread From: Alexon Oliveira @ 2023-08-26 21:05 UTC (permalink / raw) To: gregkh; +Cc: martyn, manohar.vanga, linux-kernel, linux-staging, Alexon Oliveira Fixed all CHECK: Lines should not end with a '(' as reported by checkpatch to adhere to the Linux kernel coding-style guidelines. Signed-off-by: Alexon Oliveira <alexondunkan@gmail.com> --- drivers/staging/vme_user/vme_fake.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/staging/vme_user/vme_fake.c b/drivers/staging/vme_user/vme_fake.c index a88d2c8a785b..dbaf050f88e5 100644 --- a/drivers/staging/vme_user/vme_fake.c +++ b/drivers/staging/vme_user/vme_fake.c @@ -403,8 +403,7 @@ static void fake_lm_check(struct fake_driver *bridge, unsigned long long addr, if (((lm_base + (8 * i)) <= addr) && ((lm_base + (8 * i) + 8) > addr)) { if (bridge->lm_callback[i]) - bridge->lm_callback[i]( - bridge->lm_data[i]); + bridge->lm_callback[i](bridge->lm_data[i]); } } } -- 2.41.0 ^ permalink raw reply related [flat|nested] 6+ messages in thread
* [PATCH 3/4] staging: vme_user: fix check unnecessary blank lines in vme_fake.c 2023-08-26 21:05 [PATCH 0/4] staging: vme_user: fix checks reported in vme_fake.c Alexon Oliveira 2023-08-26 21:05 ` [PATCH 1/4] staging: vme_user: fix check alignment of open parenthesis " Alexon Oliveira 2023-08-26 21:05 ` [PATCH 2/4] staging: vme_user: fix check lines not ending with '(' " Alexon Oliveira @ 2023-08-26 21:05 ` Alexon Oliveira 2023-08-26 21:05 ` [PATCH 4/4] staging: vme_user: fix check unnecessary space after a cast " Alexon Oliveira 2023-08-27 18:59 ` [PATCH 0/4] staging: vme_user: fix checks reported " Greg KH 4 siblings, 0 replies; 6+ messages in thread From: Alexon Oliveira @ 2023-08-26 21:05 UTC (permalink / raw) To: gregkh; +Cc: martyn, manohar.vanga, linux-kernel, linux-staging, Alexon Oliveira Fixed all CHECK: Blank lines aren't necessary before a close brace '}' as reported by checkpatch to adhere to the Linux kernel coding-style guidelines. Signed-off-by: Alexon Oliveira <alexondunkan@gmail.com> --- drivers/staging/vme_user/vme_fake.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/drivers/staging/vme_user/vme_fake.c b/drivers/staging/vme_user/vme_fake.c index dbaf050f88e5..4258ed6033e7 100644 --- a/drivers/staging/vme_user/vme_fake.c +++ b/drivers/staging/vme_user/vme_fake.c @@ -584,7 +584,6 @@ static ssize_t fake_master_read(struct vme_master_resource *image, void *buf, aspace, cycle); done += 1; } - } if ((dwidth == VME_D16) || (dwidth == VME_D32)) { @@ -770,7 +769,6 @@ static ssize_t fake_master_write(struct vme_master_resource *image, void *buf, aspace, cycle); done += 1; } - } if ((dwidth == VME_D16) || (dwidth == VME_D32)) { -- 2.41.0 ^ permalink raw reply related [flat|nested] 6+ messages in thread
* [PATCH 4/4] staging: vme_user: fix check unnecessary space after a cast in vme_fake.c 2023-08-26 21:05 [PATCH 0/4] staging: vme_user: fix checks reported in vme_fake.c Alexon Oliveira ` (2 preceding siblings ...) 2023-08-26 21:05 ` [PATCH 3/4] staging: vme_user: fix check unnecessary blank lines " Alexon Oliveira @ 2023-08-26 21:05 ` Alexon Oliveira 2023-08-27 18:59 ` [PATCH 0/4] staging: vme_user: fix checks reported " Greg KH 4 siblings, 0 replies; 6+ messages in thread From: Alexon Oliveira @ 2023-08-26 21:05 UTC (permalink / raw) To: gregkh; +Cc: martyn, manohar.vanga, linux-kernel, linux-staging, Alexon Oliveira Fixed all CHECK: No space is necessary after a cast as reported by checkpatch to adhere to the Linux kernel coding-style guidelines. Signed-off-by: Alexon Oliveira <alexondunkan@gmail.com> --- drivers/staging/vme_user/vme_fake.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/staging/vme_user/vme_fake.c b/drivers/staging/vme_user/vme_fake.c index 4258ed6033e7..4ccb16dd0d0b 100644 --- a/drivers/staging/vme_user/vme_fake.c +++ b/drivers/staging/vme_user/vme_fake.c @@ -95,7 +95,7 @@ static void fake_VIRQ_tasklet(unsigned long data) struct vme_bridge *fake_bridge; struct fake_driver *bridge; - fake_bridge = (struct vme_bridge *) data; + fake_bridge = (struct vme_bridge *)data; bridge = fake_bridge->driver_priv; vme_irq_handler(fake_bridge, bridge->int_level, bridge->int_statid); @@ -1092,7 +1092,7 @@ static int __init fake_init(void) mutex_init(&fake_device->vme_int); mutex_init(&fake_bridge->irq_mtx); tasklet_init(&fake_device->int_tasklet, fake_VIRQ_tasklet, - (unsigned long) fake_bridge); + (unsigned long)fake_bridge); strcpy(fake_bridge->name, driver_name); -- 2.41.0 ^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH 0/4] staging: vme_user: fix checks reported in vme_fake.c 2023-08-26 21:05 [PATCH 0/4] staging: vme_user: fix checks reported in vme_fake.c Alexon Oliveira ` (3 preceding siblings ...) 2023-08-26 21:05 ` [PATCH 4/4] staging: vme_user: fix check unnecessary space after a cast " Alexon Oliveira @ 2023-08-27 18:59 ` Greg KH 4 siblings, 0 replies; 6+ messages in thread From: Greg KH @ 2023-08-27 18:59 UTC (permalink / raw) To: Alexon Oliveira; +Cc: martyn, manohar.vanga, linux-kernel, linux-staging On Sat, Aug 26, 2023 at 06:05:14PM -0300, Alexon Oliveira wrote: > The goal of this series is to fix all warnings related to > aligment of open parenthesis, lines not ending with '(', > unnecessary blank lines and unnecessary space after a cast > in the vme_fake.c file, as reported by checkpatch to adhere > to the Linux kernel coding-style guidelines. > > Alexon Oliveira (4): > staging: vme_user: fix check alignment of open parenthesis in > vme_fake.c > staging: vme_user: fix check lines not ending with '(' in vme_fake.c > staging: vme_user: fix check unnecessary blank lines in vme_fake.c > staging: vme_user: fix check unnecessary space after a cast in > vme_fake.c > > drivers/staging/vme_user/vme_fake.c | 72 ++++++++++++++--------------- > 1 file changed, 35 insertions(+), 37 deletions(-) > > -- > 2.41.0 > > 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 ^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2023-08-27 18:59 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-08-26 21:05 [PATCH 0/4] staging: vme_user: fix checks reported in vme_fake.c Alexon Oliveira
2023-08-26 21:05 ` [PATCH 1/4] staging: vme_user: fix check alignment of open parenthesis " Alexon Oliveira
2023-08-26 21:05 ` [PATCH 2/4] staging: vme_user: fix check lines not ending with '(' " Alexon Oliveira
2023-08-26 21:05 ` [PATCH 3/4] staging: vme_user: fix check unnecessary blank lines " Alexon Oliveira
2023-08-26 21:05 ` [PATCH 4/4] staging: vme_user: fix check unnecessary space after a cast " Alexon Oliveira
2023-08-27 18:59 ` [PATCH 0/4] staging: vme_user: fix checks reported " Greg KH
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox