All of lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH 1/2] polarssl: security bump to version 1.2.12
@ 2014-10-27 14:07 Gustavo Zacarias
  2014-10-27 14:07 ` [Buildroot] [PATCH 2/2] polarssl: disable assembly for more scenarios Gustavo Zacarias
  2014-10-27 16:47 ` [Buildroot] [PATCH 1/2] polarssl: security bump to version 1.2.12 Thomas Petazzoni
  0 siblings, 2 replies; 6+ messages in thread
From: Gustavo Zacarias @ 2014-10-27 14:07 UTC (permalink / raw)
  To: buildroot

Fixes several memory leaks.
No assigned CVE or Polar-SA yet.

Signed-off-by: Gustavo Zacarias <gustavo@zacarias.com.ar>
---
 package/polarssl/polarssl.hash | 5 ++---
 package/polarssl/polarssl.mk   | 2 +-
 2 files changed, 3 insertions(+), 4 deletions(-)

diff --git a/package/polarssl/polarssl.hash b/package/polarssl/polarssl.hash
index ca437ac..9769788 100644
--- a/package/polarssl/polarssl.hash
+++ b/package/polarssl/polarssl.hash
@@ -1,3 +1,2 @@
-# From https://polarssl.org/tech-updates/releases/polarssl-1.2.11-released
-sha1	40cb3a833245273946c2075e6c948bbcda8a1be9	polarssl-1.2.11-gpl.tgz
-sha256	b3e9d059c687980976b468d8260f658e9003aede1dbc4a918526e90abdaa7d75	polarssl-1.2.11-gpl.tgz
+# From https://polarssl.org/tech-updates/releases/polarssl-1.2.12-released
+sha256	63dd60e78d25c438648607bb177b063dcf5fbf3ced9ee794fcb165d101940131	polarssl-1.2.12-gpl.tgz
diff --git a/package/polarssl/polarssl.mk b/package/polarssl/polarssl.mk
index 21bf160..7c27505 100644
--- a/package/polarssl/polarssl.mk
+++ b/package/polarssl/polarssl.mk
@@ -5,7 +5,7 @@
 ################################################################################
 
 POLARSSL_SITE = https://polarssl.org/code/releases
-POLARSSL_VERSION = 1.2.11
+POLARSSL_VERSION = 1.2.12
 POLARSSL_SOURCE = polarssl-$(POLARSSL_VERSION)-gpl.tgz
 POLARSSL_CONF_OPTS = \
 	-DENABLE_PROGRAMS=$(if $(BR2_PACKAGE_POLARSSL_PROGRAMS),ON,OFF)
-- 
2.0.4

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

* [Buildroot] [PATCH 2/2] polarssl: disable assembly for more scenarios
  2014-10-27 14:07 [Buildroot] [PATCH 1/2] polarssl: security bump to version 1.2.12 Gustavo Zacarias
@ 2014-10-27 14:07 ` Gustavo Zacarias
  2014-10-27 16:48   ` Thomas Petazzoni
  2014-10-27 16:47 ` [Buildroot] [PATCH 1/2] polarssl: security bump to version 1.2.12 Thomas Petazzoni
  1 sibling, 1 reply; 6+ messages in thread
From: Gustavo Zacarias @ 2014-10-27 14:07 UTC (permalink / raw)
  To: buildroot

Disable assembly optimizations for:
Microblaze in general (previously a patch).
ARM with debugging in Thumb1/2 mode. This one fixes:
http://autobuild.buildroot.net/results/31e/31e8c4e29d51039cd5d213c2fe176a9cc39879da/

Do so in a nicer way with a one-liner sed and drop the patch.

And rename patches around, numbering was off.

Signed-off-by: Gustavo Zacarias <gustavo@zacarias.com.ar>
---
 ...t-suite.patch => polarssl-0001-no-test-suite.patch} |  0
 ...e-the-standard-CMake-flag-to-drive-the-share.patch} |  0
 .../polarssl/polarssl-02-disable-microblaze-asm.patch  | 18 ------------------
 package/polarssl/polarssl.mk                           | 12 ++++++++++++
 4 files changed, 12 insertions(+), 18 deletions(-)
 rename package/polarssl/{polarssl-01-no-test-suite.patch => polarssl-0001-no-test-suite.patch} (100%)
 rename package/polarssl/{polarssl-0003-cmake-use-the-standard-CMake-flag-to-drive-the-share.patch => polarssl-0002-cmake-use-the-standard-CMake-flag-to-drive-the-share.patch} (100%)
 delete mode 100644 package/polarssl/polarssl-02-disable-microblaze-asm.patch

diff --git a/package/polarssl/polarssl-01-no-test-suite.patch b/package/polarssl/polarssl-0001-no-test-suite.patch
similarity index 100%
rename from package/polarssl/polarssl-01-no-test-suite.patch
rename to package/polarssl/polarssl-0001-no-test-suite.patch
diff --git a/package/polarssl/polarssl-0003-cmake-use-the-standard-CMake-flag-to-drive-the-share.patch b/package/polarssl/polarssl-0002-cmake-use-the-standard-CMake-flag-to-drive-the-share.patch
similarity index 100%
rename from package/polarssl/polarssl-0003-cmake-use-the-standard-CMake-flag-to-drive-the-share.patch
rename to package/polarssl/polarssl-0002-cmake-use-the-standard-CMake-flag-to-drive-the-share.patch
diff --git a/package/polarssl/polarssl-02-disable-microblaze-asm.patch b/package/polarssl/polarssl-02-disable-microblaze-asm.patch
deleted file mode 100644
index e90e12d..0000000
--- a/package/polarssl/polarssl-02-disable-microblaze-asm.patch
+++ /dev/null
@@ -1,18 +0,0 @@
-Microblaze assembly seems to be broken, fixes:
-
-http://autobuild.buildroot.net/results/4d5/4d54958ded61a0d929d992e4ca0bb31c996953cb/
-
-Signed-off-by: Gustavo Zacarias <gustavo@zacarias.com.ar>
-
-diff -Nura polarssl-1.2.11.orig/include/polarssl/bn_mul.h polarssl-1.2.11/include/polarssl/bn_mul.h
---- polarssl-1.2.11.orig/include/polarssl/bn_mul.h	2014-07-30 15:47:27.381658434 -0300
-+++ polarssl-1.2.11/include/polarssl/bn_mul.h	2014-07-30 15:48:52.616543074 -0300
-@@ -480,7 +480,7 @@
- 
- #endif /* SPARCv8 */
- 
--#if defined(__microblaze__) || defined(microblaze)
-+#if 0 && defined(__microblaze__) || defined(microblaze)
- 
- #define MULADDC_INIT                    \
-     asm(                                \
diff --git a/package/polarssl/polarssl.mk b/package/polarssl/polarssl.mk
index 7c27505..046c6bf 100644
--- a/package/polarssl/polarssl.mk
+++ b/package/polarssl/polarssl.mk
@@ -14,4 +14,16 @@ POLARSSL_INSTALL_STAGING = YES
 POLARSSL_LICENSE = GPLv2
 POLARSSL_LICENSE_FILES = LICENSE
 
+define POLARSSL_DISABLE_ASM
+	$(SED) '/^#define POLARSSL_HAVE_ASM/d' $(@D)/include/polarssl/config.h
+endef
+
+# ARM in thumb mode breaks debugging with asm optimizations
+# Microblaze asm optimizations are broken in general
+ifeq ($(BR2_ENABLE_DEBUG)$(BR2_ARM_INSTRUCTIONS_THUMB)$(BR2_ARM_INSTRUCTIONS_THUMB2),yy)
+POLARSSL_POST_CONFIGURE_HOOKS += POLARSSL_DISABLE_ASM
+else ifeq ($(BR2_microblaze),y)
+POLARSSL_POST_CONFIGURE_HOOKS += POLARSSL_DISABLE_ASM
+endif
+
 $(eval $(cmake-package))
-- 
2.0.4

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

* [Buildroot] [PATCH 1/2] polarssl: security bump to version 1.2.12
  2014-10-27 14:07 [Buildroot] [PATCH 1/2] polarssl: security bump to version 1.2.12 Gustavo Zacarias
  2014-10-27 14:07 ` [Buildroot] [PATCH 2/2] polarssl: disable assembly for more scenarios Gustavo Zacarias
@ 2014-10-27 16:47 ` Thomas Petazzoni
  1 sibling, 0 replies; 6+ messages in thread
From: Thomas Petazzoni @ 2014-10-27 16:47 UTC (permalink / raw)
  To: buildroot

Dear Gustavo Zacarias,

On Mon, 27 Oct 2014 11:07:17 -0300, Gustavo Zacarias wrote:
> Fixes several memory leaks.
> No assigned CVE or Polar-SA yet.
> 
> Signed-off-by: Gustavo Zacarias <gustavo@zacarias.com.ar>
> ---
>  package/polarssl/polarssl.hash | 5 ++---
>  package/polarssl/polarssl.mk   | 2 +-
>  2 files changed, 3 insertions(+), 4 deletions(-)

Applied, thanks!

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

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

* [Buildroot] [PATCH 2/2] polarssl: disable assembly for more scenarios
  2014-10-27 14:07 ` [Buildroot] [PATCH 2/2] polarssl: disable assembly for more scenarios Gustavo Zacarias
@ 2014-10-27 16:48   ` Thomas Petazzoni
  2014-10-27 16:53     ` Gustavo Zacarias
  0 siblings, 1 reply; 6+ messages in thread
From: Thomas Petazzoni @ 2014-10-27 16:48 UTC (permalink / raw)
  To: buildroot

Dear Gustavo Zacarias,

On Mon, 27 Oct 2014 11:07:18 -0300, Gustavo Zacarias wrote:

> +# ARM in thumb mode breaks debugging with asm optimizations
> +# Microblaze asm optimizations are broken in general
> +ifeq ($(BR2_ENABLE_DEBUG)$(BR2_ARM_INSTRUCTIONS_THUMB)$(BR2_ARM_INSTRUCTIONS_THUMB2),yy)
> +POLARSSL_POST_CONFIGURE_HOOKS += POLARSSL_DISABLE_ASM

It's not really great to have to build things differently debugging on
BR2_ENABLE_DEBUG, because the prompt of BR2_ENABLE_DEBUG is "build
packages with debugging symbols". So the user may expect that we build
the same set of features, just with debugging symbols.

Though I agree that with BR2_ENABLE_DEBUG also activating
--enable-debug, a lot more than just debugging symbols actually happens.

Therefore, committed, thanks!

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

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

* [Buildroot] [PATCH 2/2] polarssl: disable assembly for more scenarios
  2014-10-27 16:48   ` Thomas Petazzoni
@ 2014-10-27 16:53     ` Gustavo Zacarias
  2014-10-27 16:59       ` Thomas Petazzoni
  0 siblings, 1 reply; 6+ messages in thread
From: Gustavo Zacarias @ 2014-10-27 16:53 UTC (permalink / raw)
  To: buildroot

On 10/27/2014 01:48 PM, Thomas Petazzoni wrote:

> It's not really great to have to build things differently debugging on
> BR2_ENABLE_DEBUG, because the prompt of BR2_ENABLE_DEBUG is "build
> packages with debugging symbols". So the user may expect that we build
> the same set of features, just with debugging symbols.
> 
> Though I agree that with BR2_ENABLE_DEBUG also activating
> --enable-debug, a lot more than just debugging symbols actually happens.
> 
> Therefore, committed, thanks!

Well i'm not very happy to build things differently (asm vs no asm) if
debugging is on since it can change the result and make it pointless,
but it wouldn't be too good to disable asm in general for thumb either
so i threw the dice on the lesser evil.
Regards.

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

* [Buildroot] [PATCH 2/2] polarssl: disable assembly for more scenarios
  2014-10-27 16:53     ` Gustavo Zacarias
@ 2014-10-27 16:59       ` Thomas Petazzoni
  0 siblings, 0 replies; 6+ messages in thread
From: Thomas Petazzoni @ 2014-10-27 16:59 UTC (permalink / raw)
  To: buildroot

Dear Gustavo Zacarias,

On Mon, 27 Oct 2014 13:53:48 -0300, Gustavo Zacarias wrote:

> > It's not really great to have to build things differently debugging on
> > BR2_ENABLE_DEBUG, because the prompt of BR2_ENABLE_DEBUG is "build
> > packages with debugging symbols". So the user may expect that we build
> > the same set of features, just with debugging symbols.
> > 
> > Though I agree that with BR2_ENABLE_DEBUG also activating
> > --enable-debug, a lot more than just debugging symbols actually happens.
> > 
> > Therefore, committed, thanks!
> 
> Well i'm not very happy to build things differently (asm vs no asm) if
> debugging is on since it can change the result and make it pointless,
> but it wouldn't be too good to disable asm in general for thumb either
> so i threw the dice on the lesser evil.

Yeah, I'm fine with the trade-off as well.

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

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

end of thread, other threads:[~2014-10-27 16:59 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-10-27 14:07 [Buildroot] [PATCH 1/2] polarssl: security bump to version 1.2.12 Gustavo Zacarias
2014-10-27 14:07 ` [Buildroot] [PATCH 2/2] polarssl: disable assembly for more scenarios Gustavo Zacarias
2014-10-27 16:48   ` Thomas Petazzoni
2014-10-27 16:53     ` Gustavo Zacarias
2014-10-27 16:59       ` Thomas Petazzoni
2014-10-27 16:47 ` [Buildroot] [PATCH 1/2] polarssl: security bump to version 1.2.12 Thomas Petazzoni

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.