DistroKit Mailinglist
 help / color / mirror / Atom feed
* [DistroKit] [PATCH 0/3] platform-rpi: various cleanups
@ 2018-10-26 12:15 Michael Olbrich
  2018-10-26 12:15 ` [DistroKit] [PATCH 1/3] platform-rpi: image-boot-vfat: add missing dependency Michael Olbrich
                   ` (3 more replies)
  0 siblings, 4 replies; 8+ messages in thread
From: Michael Olbrich @ 2018-10-26 12:15 UTC (permalink / raw)
  To: distrokit; +Cc: Michael Olbrich

Hi,

I built the rpi platform to check that my layer change works correctly and
I noticed some other issues. These are just some minor fixes and cleanups.

I also noticed that the kernel config is quite different from the v7a
config. Some of that seems to be pretty arbitrary and suboptimal. E.g. no
optimized ARM crypto implementations, no idle handler and things like that.
Is there a reason for this?

Michael

Michael Olbrich (3):
  platform-rpi: image-boot-vfat: add missing dependency
  platform-rpi: platformconfig: building the kernel requires openssl
  platform-rpi: platformconfig: some cleanup

 configs/platform-rpi/platformconfig               | 14 +++++++-------
 configs/platform-rpi/platforms/image-boot-vfat.in |  1 +
 2 files changed, 8 insertions(+), 7 deletions(-)

-- 
2.19.0


_______________________________________________
DistroKit mailing list
DistroKit@pengutronix.de

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

* [DistroKit] [PATCH 1/3] platform-rpi: image-boot-vfat: add missing dependency
  2018-10-26 12:15 [DistroKit] [PATCH 0/3] platform-rpi: various cleanups Michael Olbrich
@ 2018-10-26 12:15 ` Michael Olbrich
  2018-10-26 12:15 ` [DistroKit] [PATCH 2/3] platform-rpi: platformconfig: building the kernel requires openssl Michael Olbrich
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 8+ messages in thread
From: Michael Olbrich @ 2018-10-26 12:15 UTC (permalink / raw)
  To: distrokit; +Cc: Michael Olbrich

Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de>
---
 configs/platform-rpi/platforms/image-boot-vfat.in | 1 +
 1 file changed, 1 insertion(+)

diff --git a/configs/platform-rpi/platforms/image-boot-vfat.in b/configs/platform-rpi/platforms/image-boot-vfat.in
index 1a2d6c07c141..b99238334758 100644
--- a/configs/platform-rpi/platforms/image-boot-vfat.in
+++ b/configs/platform-rpi/platforms/image-boot-vfat.in
@@ -5,6 +5,7 @@ config IMAGE_BOOT_VFAT
 	select HOST_GENIMAGE
 	select HOST_MTOOLS
 	select HOST_DOSFSTOOLS
+	select BAREBOX
 	select KERNEL
 	prompt "Generate image/boot.vfat"
 	help
-- 
2.19.0


_______________________________________________
DistroKit mailing list
DistroKit@pengutronix.de

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

* [DistroKit] [PATCH 2/3] platform-rpi: platformconfig: building the kernel requires openssl
  2018-10-26 12:15 [DistroKit] [PATCH 0/3] platform-rpi: various cleanups Michael Olbrich
  2018-10-26 12:15 ` [DistroKit] [PATCH 1/3] platform-rpi: image-boot-vfat: add missing dependency Michael Olbrich
@ 2018-10-26 12:15 ` Michael Olbrich
  2018-10-26 12:15 ` [DistroKit] [PATCH 3/3] platform-rpi: platformconfig: some cleanup Michael Olbrich
  2018-10-26 13:29 ` [DistroKit] [PATCH 0/3] platform-rpi: various cleanups Robert Schwebel
  3 siblings, 0 replies; 8+ messages in thread
From: Michael Olbrich @ 2018-10-26 12:15 UTC (permalink / raw)
  To: distrokit; +Cc: Michael Olbrich

Needed to build scripts/extract-cert (CONFIG_SYSTEM_TRUSTED_KEYRING).

Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de>
---
 configs/platform-rpi/platformconfig | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/configs/platform-rpi/platformconfig b/configs/platform-rpi/platformconfig
index d3341bd7f21f..e7380cd02b50 100644
--- a/configs/platform-rpi/platformconfig
+++ b/configs/platform-rpi/platformconfig
@@ -124,7 +124,7 @@ PTXCONF_KERNEL_DTC=y
 # PTXCONF_KERNEL_XZ is not set
 # PTXCONF_KERNEL_LZOP is not set
 # PTXCONF_KERNEL_LZ4 is not set
-# PTXCONF_KERNEL_OPENSSL is not set
+PTXCONF_KERNEL_OPENSSL=y
 # PTXCONF_KERNEL_LIBELF is not set
 
 #
@@ -262,7 +262,7 @@ PTXCONF_HOST_LZOP=y
 # PTXCONF_HOST_MKELFIMAGE is not set
 # PTXCONF_HOST_MTD_UTILS is not set
 PTXCONF_HOST_MTOOLS=y
-# PTXCONF_HOST_OPENSSL is not set
+PTXCONF_HOST_OPENSSL=y
 # PTXCONF_HOST_PCSC_LITE is not set
 # PTXCONF_HOST_RAUC is not set
 # PTXCONF_HOST_SQUASHFS_TOOLS is not set
-- 
2.19.0


_______________________________________________
DistroKit mailing list
DistroKit@pengutronix.de

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

* [DistroKit] [PATCH 3/3] platform-rpi: platformconfig: some cleanup
  2018-10-26 12:15 [DistroKit] [PATCH 0/3] platform-rpi: various cleanups Michael Olbrich
  2018-10-26 12:15 ` [DistroKit] [PATCH 1/3] platform-rpi: image-boot-vfat: add missing dependency Michael Olbrich
  2018-10-26 12:15 ` [DistroKit] [PATCH 2/3] platform-rpi: platformconfig: building the kernel requires openssl Michael Olbrich
@ 2018-10-26 12:15 ` Michael Olbrich
  2018-10-26 13:29 ` [DistroKit] [PATCH 0/3] platform-rpi: various cleanups Robert Schwebel
  3 siblings, 0 replies; 8+ messages in thread
From: Michael Olbrich @ 2018-10-26 12:15 UTC (permalink / raw)
  To: distrokit; +Cc: Michael Olbrich

- enable stack protector
- link with --as-needed
- don't add CONFIG_DEBUG_SECTION_MISMATCH=y to makevars
- don't create the ipkg index

All suggested by reason.

Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de>
---
 configs/platform-rpi/platformconfig | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/configs/platform-rpi/platformconfig b/configs/platform-rpi/platformconfig
index e7380cd02b50..19a96ce41e91 100644
--- a/configs/platform-rpi/platformconfig
+++ b/configs/platform-rpi/platformconfig
@@ -76,9 +76,9 @@ PTXCONF_COMPILER_PREFIX_BOOTLOADER="${PTXCONF_COMPILER_PREFIX}"
 #
 # hardening options             
 #
-PTXCONF_TARGET_HARDEN_STACK_NONE=y
+# PTXCONF_TARGET_HARDEN_STACK_NONE is not set
 # PTXCONF_TARGET_HARDEN_STACK is not set
-# PTXCONF_TARGET_HARDEN_STACK_STRONG is not set
+PTXCONF_TARGET_HARDEN_STACK_STRONG=y
 # PTXCONF_TARGET_HARDEN_STACK_ALL is not set
 PTXCONF_TARGET_HARDEN_FORTIFY=y
 PTXCONF_TARGET_HARDEN_RELRO=y
@@ -92,7 +92,7 @@ PTXCONF_TARGET_HARDEN_PIE=y
 # PTXCONF_TARGET_LINKER_HASH_SYSV is not set
 PTXCONF_TARGET_LINKER_HASH_GNU=y
 # PTXCONF_TARGET_LINKER_HASH_BOTH is not set
-# PTXCONF_TARGET_LINKER_AS_NEEDED is not set
+PTXCONF_TARGET_LINKER_AS_NEEDED=y
 # PTXCONF_TARGET_DEBUG_OFF is not set
 PTXCONF_TARGET_DEBUG_KEEP=y
 # PTXCONF_TARGET_DEBUG_ENABLE is not set
@@ -136,7 +136,7 @@ PTXCONF_KERNEL_CONFIG="kernelconfig"
 #
 # Development features
 #
-PTXCONF_KERNEL_EXTRA_MAKEVARS="CONFIG_DEBUG_SECTION_MISMATCH=y"
+PTXCONF_KERNEL_EXTRA_MAKEVARS=""
 PTXCONF_DTC=y
 # PTXCONF_DTC_INSTALL_OFTREE is not set
 PTXCONF_DTC_OFTREE_DTS_PATH="${KERNEL_DIR}/arch/${PTXCONF_KERNEL_ARCH_STRING}/boot/dts"
@@ -230,7 +230,7 @@ PTXCONF_IMAGE_ROOT_TGZ_LABEL=""
 #
 # PTXCONF_IMAGE_IPKG_PUSH_TO_REPOSITORY is not set
 # PTXCONF_IMAGE_INSTALL_FROM_IPKG_REPOSITORY is not set
-PTXCONF_IMAGE_IPKG_INDEX=y
+# PTXCONF_IMAGE_IPKG_INDEX is not set
 PTXCONF_IMAGE_XPKG_EXTRA_ARGS=""
 # PTXCONF_HOST_ACL is not set
 # PTXCONF_HOST_ATTR is not set
-- 
2.19.0


_______________________________________________
DistroKit mailing list
DistroKit@pengutronix.de

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

* Re: [DistroKit] [PATCH 0/3] platform-rpi: various cleanups
  2018-10-26 12:15 [DistroKit] [PATCH 0/3] platform-rpi: various cleanups Michael Olbrich
                   ` (2 preceding siblings ...)
  2018-10-26 12:15 ` [DistroKit] [PATCH 3/3] platform-rpi: platformconfig: some cleanup Michael Olbrich
@ 2018-10-26 13:29 ` Robert Schwebel
  2018-10-31 22:37   ` Roland Hieber
  3 siblings, 1 reply; 8+ messages in thread
From: Robert Schwebel @ 2018-10-26 13:29 UTC (permalink / raw)
  To: Michael Olbrich; +Cc: distrokit

On Fri, Oct 26, 2018 at 02:15:52PM +0200, Michael Olbrich wrote:
> I built the rpi platform to check that my layer change works correctly and
> I noticed some other issues. These are just some minor fixes and cleanups.
> 
> I also noticed that the kernel config is quite different from the v7a
> config. Some of that seems to be pretty arbitrary and suboptimal. E.g. no
> optimized ARM crypto implementations, no idle handler and things like that.
> Is there a reason for this?

I don't think so, but I havn't cared much about the RPi. Roland might
have more insights, but he is currently on holiday.

rsc
-- 
Pengutronix e.K.                           | Dipl.-Ing. Robert Schwebel  |
Industrial Linux Solutions                 | https://www.pengutronix.de/ |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

_______________________________________________
DistroKit mailing list
DistroKit@pengutronix.de

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

* Re: [DistroKit] [PATCH 0/3] platform-rpi: various cleanups
  2018-10-26 13:29 ` [DistroKit] [PATCH 0/3] platform-rpi: various cleanups Robert Schwebel
@ 2018-10-31 22:37   ` Roland Hieber
  2018-11-01  9:42     ` Michael Olbrich
  0 siblings, 1 reply; 8+ messages in thread
From: Roland Hieber @ 2018-10-31 22:37 UTC (permalink / raw)
  To: Robert Schwebel; +Cc: Michael Olbrich, distrokit

On Fri, Oct 26, 2018 at 03:29:16PM +0200, Robert Schwebel wrote:
> On Fri, Oct 26, 2018 at 02:15:52PM +0200, Michael Olbrich wrote:
> > I built the rpi platform to check that my layer change works correctly and
> > I noticed some other issues. These are just some minor fixes and cleanups.
> > 
> > I also noticed that the kernel config is quite different from the v7a
> > config. Some of that seems to be pretty arbitrary and suboptimal. E.g. no
> > optimized ARM crypto implementations, no idle handler and things like that.
> > Is there a reason for this?
> 
> I don't think so, but I havn't cared much about the RPi. Roland might
> have more insights, but he is currently on holiday.

The basic state is "rpi boots a kernel", nothing more. Due to lack of
use in RPI 1 I haven't gotten around to having a better look and
cleaning up the config yet. But I wonder now that ptxdist has layer
support - could that already be used for building up a kernel config
from a platform-independent part that stays the same as a baseline for
all platforms and a platform-dependent part which only switches on the
respective platform support, drivers etc?

 - Roland

-- 
Roland Hieber                     | r.hieber@pengutronix.de     |
Pengutronix e.K.                  | https://www.pengutronix.de/ |
Peiner Str. 6-8, 31137 Hildesheim | Phone: +49-5121-206917-5086 |
Amtsgericht Hildesheim, HRA 2686  | Fax:   +49-5121-206917-5555 |

_______________________________________________
DistroKit mailing list
DistroKit@pengutronix.de

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

* Re: [DistroKit] [PATCH 0/3] platform-rpi: various cleanups
  2018-10-31 22:37   ` Roland Hieber
@ 2018-11-01  9:42     ` Michael Olbrich
  2018-11-01  9:55       ` Robert Schwebel
  0 siblings, 1 reply; 8+ messages in thread
From: Michael Olbrich @ 2018-11-01  9:42 UTC (permalink / raw)
  To: Roland Hieber; +Cc: distrokit

On Wed, Oct 31, 2018 at 11:37:38PM +0100, Roland Hieber wrote:
> On Fri, Oct 26, 2018 at 03:29:16PM +0200, Robert Schwebel wrote:
> > On Fri, Oct 26, 2018 at 02:15:52PM +0200, Michael Olbrich wrote:
> > > I built the rpi platform to check that my layer change works correctly and
> > > I noticed some other issues. These are just some minor fixes and cleanups.
> > > 
> > > I also noticed that the kernel config is quite different from the v7a
> > > config. Some of that seems to be pretty arbitrary and suboptimal. E.g. no
> > > optimized ARM crypto implementations, no idle handler and things like that.
> > > Is there a reason for this?
> > 
> > I don't think so, but I havn't cared much about the RPi. Roland might
> > have more insights, but he is currently on holiday.
> 
> The basic state is "rpi boots a kernel", nothing more. Due to lack of
> use in RPI 1 I haven't gotten around to having a better look and
> cleaning up the config yet. But I wonder now that ptxdist has layer
> support - could that already be used for building up a kernel config
> from a platform-independent part that stays the same as a baseline for
> all platforms and a platform-dependent part which only switches on the
> respective platform support, drivers etc?

Hmm, we may be able to use kernel config for v7a as a base for rpi. I don't
think using a common base is a good idea: Maintaining it would be painful.

We could add:

KERNEL_REF_CONFIG := $(call ptx/in-path,PTXDIST_PATH_LAYERS,configs/platform-v7a/kernelconfig)

I'm not sure how useful that will be.

Michael


-- 
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

_______________________________________________
DistroKit mailing list
DistroKit@pengutronix.de

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

* Re: [DistroKit] [PATCH 0/3] platform-rpi: various cleanups
  2018-11-01  9:42     ` Michael Olbrich
@ 2018-11-01  9:55       ` Robert Schwebel
  0 siblings, 0 replies; 8+ messages in thread
From: Robert Schwebel @ 2018-11-01  9:55 UTC (permalink / raw)
  To: Roland Hieber, distrokit

On Thu, Nov 01, 2018 at 10:42:38AM +0100, Michael Olbrich wrote:
> On Wed, Oct 31, 2018 at 11:37:38PM +0100, Roland Hieber wrote:
> > On Fri, Oct 26, 2018 at 03:29:16PM +0200, Robert Schwebel wrote:
> > > On Fri, Oct 26, 2018 at 02:15:52PM +0200, Michael Olbrich wrote:
> > > > I built the rpi platform to check that my layer change works correctly and
> > > > I noticed some other issues. These are just some minor fixes and cleanups.
> > > > 
> > > > I also noticed that the kernel config is quite different from the v7a
> > > > config. Some of that seems to be pretty arbitrary and suboptimal. E.g. no
> > > > optimized ARM crypto implementations, no idle handler and things like that.
> > > > Is there a reason for this?
> > > 
> > > I don't think so, but I havn't cared much about the RPi. Roland might
> > > have more insights, but he is currently on holiday.
> > 
> > The basic state is "rpi boots a kernel", nothing more. Due to lack of
> > use in RPI 1 I haven't gotten around to having a better look and
> > cleaning up the config yet. But I wonder now that ptxdist has layer
> > support - could that already be used for building up a kernel config
> > from a platform-independent part that stays the same as a baseline for
> > all platforms and a platform-dependent part which only switches on the
> > respective platform support, drivers etc?
> 
> Hmm, we may be able to use kernel config for v7a as a base for rpi. I don't
> think using a common base is a good idea: Maintaining it would be painful.
> 
> We could add:
> 
> KERNEL_REF_CONFIG := $(call ptx/in-path,PTXDIST_PATH_LAYERS,configs/platform-v7a/kernelconfig)
> 
> I'm not sure how useful that will be.

No, please don't. Maybe just diff & synchronize once, then keep an eye
on the differeces.

rsc
-- 
Pengutronix e.K.                           | Dipl.-Ing. Robert Schwebel  |
Industrial Linux Solutions                 | https://www.pengutronix.de/ |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

_______________________________________________
DistroKit mailing list
DistroKit@pengutronix.de

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

end of thread, other threads:[~2018-11-01  9:55 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-10-26 12:15 [DistroKit] [PATCH 0/3] platform-rpi: various cleanups Michael Olbrich
2018-10-26 12:15 ` [DistroKit] [PATCH 1/3] platform-rpi: image-boot-vfat: add missing dependency Michael Olbrich
2018-10-26 12:15 ` [DistroKit] [PATCH 2/3] platform-rpi: platformconfig: building the kernel requires openssl Michael Olbrich
2018-10-26 12:15 ` [DistroKit] [PATCH 3/3] platform-rpi: platformconfig: some cleanup Michael Olbrich
2018-10-26 13:29 ` [DistroKit] [PATCH 0/3] platform-rpi: various cleanups Robert Schwebel
2018-10-31 22:37   ` Roland Hieber
2018-11-01  9:42     ` Michael Olbrich
2018-11-01  9:55       ` Robert Schwebel

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox