,
#define test(a) do { } while (0)
The test result is as follows.
WARNING: Argument 'a' is not used in function-like macro
#21: FILE: mm/init-mm.c:20:
+#define test(a) do { } while (0)
total: 0 errors, 1 warnings, 8 lines checked
Signed-off-by: Xining Xu
Tested-by: Barry Song
From: Barry Song
Recent commit 77292bb8ca69c80 ("crypto: scomp - remove memcpy if
sg_nents is 1 and pages are lowmem") leads to warnings on xtensa
and loongarch,
In file included from crypto/scompress.c:12:
include/crypto/scatterwalk.h: In function 'scatterwalk_pagedone'
From: Barry Song
-v7:
* collect ack of Joe for checkpatch.pl, thanks!
* fixed an indentation per Joe
-v6:
* collect ack of Joe, thanks!
* refine docs according to Jonathan, thanks!
* add checkpatch doc according to Joe, thanks!
v6 link:
https://lore.kernel.org/lkml/20240506014606.8638-1
>> From: Xining Xu
>>
>> If function-like macros do not utilize a parameter, it might result in a
>> build warning. In our coding style guidelines, we advocate for utilizing
>> static inline functions to replace such macros. This patch verifies
>> compliance with the new rule.
> []
>> diff --gi
,
#define test(a) do { } while (0)
The test result is as follows.
WARNING: Argument 'a' is not used in function-like macro
#21: FILE: mm/init-mm.c:20:
+#define test(a) do { } while (0)
total: 0 errors, 1 warnings, 8 lines checked
Signed-off-by: Xining Xu
Tested-by: Barry Song
From: Barry Song
Recent commit 77292bb8ca69c80 ("crypto: scomp - remove memcpy if
sg_nents is 1 and pages are lowmem") leads to warnings on xtensa
and loongarch,
In file included from crypto/scompress.c:12:
include/crypto/scatterwalk.h: In function 'scatterwalk_pagedone'
From: Barry Song
-v6:
* collect ack of Joe, thanks!
* refine docs according to Jonathan, thanks!
* add checkpatch doc according to Joe, thanks!
-v5:
* Simplify the code for Patch 2 according to Joe's suggestions.
* add s-o-b of Barry according to Jeff Johnson
v5 link:
Hi Joe,
any further comment for this ? May this patch get your reviewed / acked?
On Thu, Apr 4, 2024 at 6:43 AM Barry Song <21cn...@gmail.com> wrote:
>
> From: Xining Xu
>
> If function-like macros do not utilize a parameter, it might result in a
> build warning. In our co
,
#define test(a) do { } while (0)
The test result is as follows.
WARNING: Argument 'a' is not used in function-like macro
#21: FILE: mm/init-mm.c:20:
+#define test(a) do { } while (0)
total: 0 errors, 1 warnings, 8 lines checked
Signed-off-by: Xining Xu
Tested-by: Barry Song
From: Barry Song
Recent commit 77292bb8ca69c80 ("crypto: scomp - remove memcpy if
sg_nents is 1 and pages are lowmem") leads to warnings on xtensa
and loongarch,
In file included from crypto/scompress.c:12:
include/crypto/scatterwalk.h: In function 'scatterwalk_pagedone'
From: Barry Song
-v6:
* collect ack of Joe, thanks!
* refine docs according to Jonathan, thanks!
* add checkpatch doc according to Joe, thanks!
-v5:
* Simplify the code for Patch 2 according to Joe's suggestions.
* add s-o-b of Barry according to Jeff Johnson
v5 link:
efer to stick with Andrew's channel.
>
> A nit below
>
> Barry Song <21cn...@gmail.com> writes:
>
> > From: Barry Song
> >
> > Recent commit 77292bb8ca69c80 ("crypto: scomp - remove memcpy if
> > sg_nents is 1 and pages are lowmem") le
Xining Xu
Tested-by: Barry Song
Signed-off-by: Barry Song
Cc: Chris Zankel
Cc: Huacai Chen
Cc: Herbert Xu
Cc: Guenter Roeck
Cc: Stephen Rothwell
Cc: Mark Brown
Cc: Andy Whitcroft
Cc: Dwaipayan Ray
Cc: Joe Perches
Cc: Jonathan Corbet
Cc: Lukas Bulwahn
Cc: Max Filippov
Cc: Jeff J
From: Barry Song
Recent commit 77292bb8ca69c80 ("crypto: scomp - remove memcpy if
sg_nents is 1 and pages are lowmem") leads to warnings on xtensa
and loongarch,
In file included from crypto/scompress.c:12:
include/crypto/scatterwalk.h: In function 'scatterwalk_pagedone'
From: Barry Song
-v5:
* Simplify the code for Patch 2 according to Joe's suggestions.
* add s-o-b of Barry according to Jeff Johnson
-v4:
* fix Xining's email address, s/ma@outlook.com/mac@outlook.com/g
* fix some false positives of checkpatch.pl
* downgrade from ERROR
On Fri, Mar 29, 2024 at 5:01 AM Jeff Johnson wrote:
>
> On 3/27/2024 7:21 PM, Barry Song wrote:
> > From: Xining Xu
> >
> > If function-like macros do not utilize a parameter, it might result in a
> > build warning. In our coding style guidelines, we advocate f
On Thu, Mar 28, 2024 at 3:21 PM Barry Song <21cn...@gmail.com> wrote:
>
> From: Barry Song
>
> -v4:
> * fix Xining's email address, s/ma@outlook.com/mac@outlook.com/g
Hi Andrew,
Apologies for the oversight. Could you please apply these two patches to replac
Xining Xu
Tested-by: Barry Song
Cc: Chris Zankel
Cc: Huacai Chen
Cc: Herbert Xu
Cc: Guenter Roeck
Cc: Stephen Rothwell
Cc: Mark Brown
Cc: Andy Whitcroft
Cc: Dwaipayan Ray
Cc: Joe Perches
Cc: Jonathan Corbet
Cc: Lukas Bulwahn
Cc: Max Filippov
---
scripts/checkpat
From: Barry Song
Recent commit 77292bb8ca69c80 ("crypto: scomp - remove memcpy if
sg_nents is 1 and pages are lowmem") leads to warnings on xtensa
and loongarch,
In file included from crypto/scompress.c:12:
include/crypto/scatterwalk.h: In function 'scatterwalk_pagedone'
From: Barry Song
-v4:
* fix Xining's email address, s/ma@outlook.com/mac@outlook.com/g
* fix some false positives of checkpatch.pl
* downgrade from ERROR to WARN in checkpatch.pl
Thanks for Joe's comments!
-v3:
https://lore.kernel.org/all/20240322084937.66018-1-21cn...
Cc: Chris Zankel
Cc: Huacai Chen
Cc: Herbert Xu
Cc: Guenter Roeck
Cc: Stephen Rothwell
Cc: Mark Brown
Signed-off-by: Xining Xu
Tested-by: Barry Song
---
scripts/checkpatch.pl | 24
1 file changed, 24 insertions(+)
diff --git a/scripts/checkpatch.pl b/scripts/che
From: Barry Song
Recent commit 77292bb8ca69c80 ("crypto: scomp - remove memcpy if
sg_nents is 1 and pages are lowmem") leads to warnings on xtensa
and loongarch,
In file included from crypto/scompress.c:12:
include/crypto/scatterwalk.h: In function 'scatterwalk_pagedone'
From: Barry Song
A function-like macro could result in build warnings such as
"unused variable." This patchset updates the guidance to
recommend always using a static inline function instead
and also provides checkpatch support for this new rule.
Barry Song (1):
Documentation: co
On Fri, Mar 22, 2024 at 12:15 AM Mark Brown wrote:
>
> On Thu, Mar 21, 2024 at 07:48:36AM +1300, Barry Song wrote:
> > On Thu, Mar 21, 2024 at 4:49 AM Andrew Morton
> > wrote:
>
> > > Stronger than that please. Just tell people not to use macros in such
> >
On Thu, Mar 21, 2024 at 5:40 PM Meiyong Yu wrote:
>
>
> 在 2024/3/21 8:11, Barry Song 写道:
> > On Thu, Mar 21, 2024 at 12:39 PM Meiyong Yu wrote:
> >>
> >>> On Mar 20, 2024, at 08:17, Barry Song <21cn...@gmail.com> wrote:
> >>>
> >>
On Thu, Mar 21, 2024 at 12:39 PM Meiyong Yu wrote:
>
>
> > On Mar 20, 2024, at 08:17, Barry Song <21cn...@gmail.com> wrote:
> >
> > From: Barry Song
> >
> > Recent commit 77292bb8ca69c80 ("crypto: scomp - remove memcpy if
> > sg_nents is
On Thu, Mar 21, 2024 at 4:49 AM Andrew Morton wrote:
>
> On Wed, 20 Mar 2024 16:24:30 +1300 Barry Song <21cn...@gmail.com> wrote:
>
> > Hi Stephen,
> > Thanks for reviewing.
> >
> > On Wed, Mar 20, 2024 at 2:42 PM Stephen Rothwell
> > wrote:
> >
From: Barry Song
Recent commit 77292bb8ca69c80 ("crypto: scomp - remove memcpy if
sg_nents is 1 and pages are lowmem") leads to warnings on xtensa
and loongarch,
In file included from crypto/scompress.c:12:
include/crypto/scatterwalk.h: In function 'scatterwalk_pagedone'
Hi Stephen,
Thanks for reviewing.
On Wed, Mar 20, 2024 at 2:42 PM Stephen Rothwell wrote:
>
> Hi Barry,
>
> On Wed, 20 Mar 2024 13:16:56 +1300 Barry Song <21cn...@gmail.com> wrote:
> >
> > diff --git a/Documentation/process/coding-style.rst
> > b/Documentatio
From: Barry Song
Recent commit 77292bb8ca69c80 ("crypto: scomp - remove memcpy if
sg_nents is 1 and pages are lowmem") leads to warnings on xtensa
and loongarch,
In file included from crypto/scompress.c:12:
include/crypto/scatterwalk.h: In function 'scatterwalk_pagedone'
30 matches
Mail list logo