Re: [PATCH] staging: gdm724x: gdm_tty: replaced macro with a function

2020-09-01 Thread Greg KH
On Tue, Sep 01, 2020 at 10:16:26PM +0200, Antoni Przybylik wrote: > This approach is more elegant and prevents some problems related to > macros such as operator precedence in expanded expression. > > Signed-off-by: Antoni Przybylik > --- > drivers/staging/gdm724x/gdm_tty.c | 15 +--

[staging:staging-testing] BUILD SUCCESS WITH WARNING 4c6491a343e91a5a2a699b0b545f8ba1ec1e8c65

2020-09-01 Thread kernel test robot
' is reassigned a value before the old one has been used. [redundantAssignment] drivers/staging/emxx_udc/emxx_udc.c:839:9: warning: Variable 'result' is reassigned a value before the old one has been used. [redundantAssignment] Warning ids grouped by kconfigs: gcc_recent_errors `

[staging:staging-testing 62/88] drivers/staging/emxx_udc/emxx_udc.c:839:9: warning: Variable 'result' is reassigned a value before the old one has been used.

2020-09-01 Thread kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging.git staging-testing head: 4c6491a343e91a5a2a699b0b545f8ba1ec1e8c65 commit: fbcfdfab4a2c4ec5e2195929528506fec39388f3 [62/88] staging: emxx_udc: Allow for building on !ARM compiler: riscv32-linux-gcc (GCC) 9.3.0 If you fix th

[staging:staging-linus] BUILD SUCCESS a139ffa40f0c24b753838b8ef3dcf6ad10eb7854

2020-09-01 Thread kernel test robot
allmodconfig x86_64 randconfig-a004-20200901 x86_64 randconfig-a006-20200901 x86_64 randconfig-a003-20200901 x86_64 randconfig-a005-20200901 x86_64 randconfig-a001-20200901 x86_64 randconfig-a002-20200901 i386

Re: [PATCH] staging: gdm724x: gdm_tty: replaced macro with a function

2020-09-01 Thread antoni.przyby...@wp.pl
On 01.09.2020 19:50, Greg KH wrote: On Tue, Sep 01, 2020 at 06:18:46PM +0200, Antoni Przybylik wrote: This approach is more elegant and prevents some problems related to macros such as operator precedence in expanded expression. Signed-off-by: Antoni Przybylik --- drivers/staging/gdm724x/gd

[PATCH] staging: gdm724x: gdm_tty: replaced macro with a function

2020-09-01 Thread Antoni Przybylik
This approach is more elegant and prevents some problems related to macros such as operator precedence in expanded expression. Signed-off-by: Antoni Przybylik --- drivers/staging/gdm724x/gdm_tty.c | 15 +-- 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/drivers/staging

Re: [PATCH] staging: gdm724x: gdm_tty: replaced macro with an inline function

2020-09-01 Thread kernel test robot
Hi Antoni, Thank you for the patch! Yet something to improve: [auto build test ERROR on staging/staging-testing] url: https://github.com/0day-ci/linux/commits/Antoni-Przybylik/staging-gdm724x-gdm_tty-replaced-macro-with-an-inline-function/20200901-234632 base: https://git.kernel.org/pub

Re: [PATCH] staging: gdm724x: gdm_tty: replaced macro with a function

2020-09-01 Thread Greg KH
On Tue, Sep 01, 2020 at 06:18:46PM +0200, Antoni Przybylik wrote: > This approach is more elegant and prevents some problems related to > macros such as operator precedence in expanded expression. > > Signed-off-by: Antoni Przybylik > --- > drivers/staging/gdm724x/gdm_tty.c | 15 +--

[PATCH] staging: gdm724x: gdm_tty: replaced macro with a function

2020-09-01 Thread Antoni Przybylik
This approach is more elegant and prevents some problems related to macros such as operator precedence in expanded expression. Signed-off-by: Antoni Przybylik --- drivers/staging/gdm724x/gdm_tty.c | 15 +-- 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/drivers/staging

Re: [PATCH] staging: gdm724x: gdm_tty: replaced macro with an inline function

2020-09-01 Thread Greg KH
On Tue, Sep 01, 2020 at 05:44:37PM +0200, Antoni Przybylik wrote: > This approach is more elegant and prevents some problems related to > macros such as operator precedence in expanded expression. > > Signed-off-by: Antoni Przybylik > --- > drivers/staging/gdm724x/gdm_tty.c | 15 +--

[PATCH] staging: gdm724x: gdm_tty: replaced macro with an inline function

2020-09-01 Thread Antoni Przybylik
This approach is more elegant and prevents some problems related to macros such as operator precedence in expanded expression. Signed-off-by: Antoni Przybylik --- drivers/staging/gdm724x/gdm_tty.c | 15 +-- 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/drivers/stagin

Re: [PATCH] staging: gdm724x: gdm_tty: corrected macro by adding brackets

2020-09-01 Thread Dan Carpenter
On Tue, Sep 01, 2020 at 12:43:11PM +0200, antoniprzybylik wrote: ^^^ Please, fix your From: header so that it says "Antoni Przybylik". > Such macros are dangerous. Consider following example: > #define GDM_TTY_READY(gdm) (gdm && gdm->tty_

Re: Fwd: Re: [PATCH] staging: gdm724x: gdm_tty: corrected macro by adding brackets

2020-09-01 Thread Greg KH
On Tue, Sep 01, 2020 at 02:06:23PM +0200, antoni.przyby...@wp.pl wrote: > On 01.09.2020 13:08, Greg KH wrote: > > On Tue, Sep 01, 2020 at 12:43:11PM +0200, antoniprzybylik wrote: > > > Such macros are dangerous. Consider following example: > > > #define GDM_TTY_READY(gdm) (gdm && gdm->tty_dev &&

Re: Fwd: Re: [PATCH] staging: gdm724x: gdm_tty: corrected macro by adding brackets

2020-09-01 Thread Dan Carpenter
On Tue, Sep 01, 2020 at 02:06:23PM +0200, antoni.przyby...@wp.pl wrote: > On 01.09.2020 13:08, Greg KH wrote: > > On Tue, Sep 01, 2020 at 12:43:11PM +0200, antoniprzybylik wrote: > > > Such macros are dangerous. Consider following example: > > > #define GDM_TTY_READY(gdm) (gdm && gdm->tty_dev &&

Fwd: Re: [PATCH] staging: gdm724x: gdm_tty: corrected macro by adding brackets

2020-09-01 Thread antoni.przyby...@wp.pl
On 01.09.2020 13:08, Greg KH wrote: On Tue, Sep 01, 2020 at 12:43:11PM +0200, antoniprzybylik wrote: Such macros are dangerous. Consider following example: #define GDM_TTY_READY(gdm) (gdm && gdm->tty_dev && gdm->port.count) GDM_TTY_READY(a + b) This macro will be expanded in such

Re: [PATCH] staging: gdm724x: gdm_tty: corrected macro by adding brackets

2020-09-01 Thread Greg KH
On Tue, Sep 01, 2020 at 12:43:11PM +0200, antoniprzybylik wrote: > Such macros are dangerous. Consider following example: > #define GDM_TTY_READY(gdm) (gdm && gdm->tty_dev && gdm->port.count) > GDM_TTY_READY(a + b) > This macro will be expanded in such a way: > (a + b && a + b->tt

[PATCH] staging: gdm724x: gdm_tty: corrected macro by adding brackets

2020-09-01 Thread antoniprzybylik
Such macros are dangerous. Consider following example: #define GDM_TTY_READY(gdm) (gdm && gdm->tty_dev && gdm->port.count) GDM_TTY_READY(a + b) This macro will be expanded in such a way: (a + b && a + b->tty_dev && a + b->port.count) And it will lead to errors. Signed-off-b

Re: [PATCH v11 07/11] device-mapping: Introduce DMA range map, supplanting dma_pfn_offset

2020-09-01 Thread Christoph Hellwig
I've applied this to the dma-mapping tree. I had to resolve a conflict in drivers/of/address.c with a recent mainline commit. I also applied the minor tweaks Andy pointed out plus a few more style changes. A real change is that I changed the prototype for dma_copy_dma_range_map to require less b