aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--README.md3
-rw-r--r--core/lib/libtomcrypt/src/sub.mk1
-rw-r--r--lib/libmpa/sub.mk1
-rw-r--r--mk/compile.mk3
4 files changed, 4 insertions, 4 deletions
diff --git a/README.md b/README.md
index 0aa7a2fd..7a320f09 100644
--- a/README.md
+++ b/README.md
@@ -120,6 +120,9 @@ the code also follows GlobalPlatform standards. The exceptions are as follows:
deviate too much from upstream and therefore it would be hard to rebase
against those projects later on and we don't expect that it is easy to
convince other software projects to change coding style.
+ Automatic variables should always be initialized. Mixed declarations
+ and statements are allowed, and may be used to avoid assigning useless
+ values. Please leave one blank line before and after such declarations.
Regarding the checkpatch tool, it is not included directly into this project.
Please use checkpatch.pl from the Linux kernel git in combination with the
diff --git a/core/lib/libtomcrypt/src/sub.mk b/core/lib/libtomcrypt/src/sub.mk
index ca88fb1f..328cc001 100644
--- a/core/lib/libtomcrypt/src/sub.mk
+++ b/core/lib/libtomcrypt/src/sub.mk
@@ -2,7 +2,6 @@ ifdef _CFG_CRYPTO_WITH_ACIPHER
srcs-y += mpa_desc.c
# Get mpa.h which normally is an internal .h file
cppflags-mpa_desc.c-y += -Ilib/libmpa
-cflags-mpa_desc.c-y += -Wno-declaration-after-statement
cflags-mpa_desc.c-y += -Wno-unused-parameter
endif
diff --git a/lib/libmpa/sub.mk b/lib/libmpa/sub.mk
index 38c1610a..2840f847 100644
--- a/lib/libmpa/sub.mk
+++ b/lib/libmpa/sub.mk
@@ -9,7 +9,6 @@ cflags-remove-mpa_misc.c-y += -pedantic
cflags-mpa_misc.c-y += -Wno-sign-compare
srcs-y += mpa_montgomery.c
-cflags-remove-mpa_montgomery.c-y += -Wdeclaration-after-statement
srcs-y += mpa_primetest.c
cflags-remove-mpa_primetest.c-y += -pedantic
diff --git a/mk/compile.mk b/mk/compile.mk
index 7c6c890d..4f065a9c 100644
--- a/mk/compile.mk
+++ b/mk/compile.mk
@@ -40,8 +40,7 @@ comp-cflags-warns-medium = \
-Waggregate-return -Wredundant-decls
comp-cflags-warns-low = \
-Wold-style-definition -Wstrict-aliasing=2 \
- -Wundef -pedantic \
- -Wdeclaration-after-statement
+ -Wundef -pedantic
comp-cflags-warns-1:= $(comp-cflags-warns-high)
comp-cflags-warns-2:= $(comp-cflags-warns-1) $(comp-cflags-warns-medium)