Processed: Re: Bug#837588: hppa: Please disable CONFIG_FTRACE for hppa architecture
Processing control commands: > reopen -1 Bug #837588 {Done: Ben Hutchings } [linux] hppa: Please disable CONFIG_FTRACE for hppa architecture 'reopen' may be inappropriate when a bug has been closed with a version; all fixed versions will be cleared, and you may need to re-add them. Bug reopened No longer marked as fixed in versions linux/4.7.4-1. > retitle -1 vmlinux in linux-image packages is unstripped Bug #837588 [linux] hppa: Please disable CONFIG_FTRACE for hppa architecture Changed Bug title to 'vmlinux in linux-image packages is unstripped' from 'hppa: Please disable CONFIG_FTRACE for hppa architecture'. -- 837588: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=837588 Debian Bug Tracking System Contact ow...@bugs.debian.org with problems
Bug#837588: hppa: Please disable CONFIG_FTRACE for hppa architecture
Control: reopen -1 Control: retitle -1 vmlinux in linux-image packages is unstripped On Thu, 2016-09-22 at 21:18 +0200, Helge Deller wrote: > Hi Ben, > > On 19.09.2016 20:56, Ben Hutchings wrote: > > > > On Mon, 2016-09-19 at 20:50 +0200, Helge Deller wrote: > > > > > > On 19.09.2016 19:41, Ben Hutchings wrote: > > > > > > > > On Mon, 2016-09-12 at 20:28 +0100, Ben Hutchings wrote: > > > > > > > > > > On Mon, 2016-09-12 at 18:17 +0200, Helge Deller wrote: > > > > > > > > > > > > > > > > > > So, can you please deactivate CONFIG_FTRACE completely for 32- and > > > > > > 64bit hppa configs? > > > > > > Is it sufficient to add "CONFIG_FTRACE=n" to > > > > > > debian/config/hppa/config ? > > > > > > > > > > Done. > > Argh - this didn't fixed the size issues on hppa. > I was under the wrong assumption, that CONFIG_FTRACE (which was implemented in > kernel 4.7 for the first time) was the culprit which increased the kernel > size. > This assumption was wrong. > > The attached patch finally fixes the issue. > It re-enables the CONFIG_FTRACE option (which is set by your upper config > files), > and disables CONFIG_DEBUG_INFO which was now suddenly enabled by the debian > kernel 4.7 (it wasn't in 4.6!). > I enabled CONFIG_DEBUG_RODATA to write-protect kernel memory as well. > > The main problem was, that the generated dwarf debug info increases the > kernel vmlinux image from 17MB to 97MB in disk size. > I've compile- and run-tested the patch and built a +b1 kernel. > > Can you apply the attached patch on top of current git? > I can commit it myself as well if you like. This is not the correct fix, nor is this an hppa-specific problem. We need to strip debug information out of the kernel image that goes into linux-image-[-unsigned], and currently we don't do that explicitly. Previously we only enabled debug information for x86 and s390, and for those the upstream build rules already strip debug information before compressing the kernel. Here's the current status, so far as I can see: alpha: vmlinux.gz, stripped(?) and compressed arm64: Image, stripped and uncompressed armel,armhf: zImage, stripped and compressed hppa: vmlinux, UNstripped and uncompressed m68k: vmlinux.gz, stripped and compressed mips*: vmlinux, UNstripped and uncompressed powerpc*: vmlinux, UNstripped and uncompressed s390x: image, stripped and uncompressed sh4: zImage, stripped(?) and compressed sparc64: zImage, stripped and compressed x86: bzImage, stripped and compressed (No binary packages of 4.7 are available on ftp.debian-ports.org for alpha or sh4 yet, so those results are based on reading the respective Makefiles.) It seems that we only need a special case in debian/rules.real for those architectures where we install vmlinux directly. Ben. -- Ben Hutchings The first rule of tautology club is the first rule of tautology club. signature.asc Description: This is a digitally signed message part
Bug#837588: hppa: Please disable CONFIG_FTRACE for hppa architecture
Hi Ben, On 19.09.2016 20:56, Ben Hutchings wrote: > On Mon, 2016-09-19 at 20:50 +0200, Helge Deller wrote: >> On 19.09.2016 19:41, Ben Hutchings wrote: >>> On Mon, 2016-09-12 at 20:28 +0100, Ben Hutchings wrote: On Mon, 2016-09-12 at 18:17 +0200, Helge Deller wrote: > > So, can you please deactivate CONFIG_FTRACE completely for 32- and > 64bit hppa configs? > Is it sufficient to add "CONFIG_FTRACE=n" to > debian/config/hppa/config ? Done. Argh - this didn't fixed the size issues on hppa. I was under the wrong assumption, that CONFIG_FTRACE (which was implemented in kernel 4.7 for the first time) was the culprit which increased the kernel size. This assumption was wrong. The attached patch finally fixes the issue. It re-enables the CONFIG_FTRACE option (which is set by your upper config files), and disables CONFIG_DEBUG_INFO which was now suddenly enabled by the debian kernel 4.7 (it wasn't in 4.6!). I enabled CONFIG_DEBUG_RODATA to write-protect kernel memory as well. The main problem was, that the generated dwarf debug info increases the kernel vmlinux image from 17MB to 97MB in disk size. I've compile- and run-tested the patch and built a +b1 kernel. Can you apply the attached patch on top of current git? I can commit it myself as well if you like. Thanks! Helge diff -up ./config/hppa/config.org ./config/hppa/config --- ./config/hppa/config.org 2016-09-21 21:34:30.894455256 +0200 +++ ./config/hppa/config 2016-09-22 20:48:48.314036351 +0200 @@ -571,15 +571,10 @@ CONFIG_SGETMASK_SYSCALL=y CONFIG_SYSFS_SYSCALL=y ## -## file: kernel/trace/Kconfig -## -#. As of 4.7 this has a huge size cost; see #837588 -# CONFIG_FTRACE is not set - -## ## file: lib/Kconfig.debug ## CONFIG_DEBUG_STACKOVERFLOW=y +CONFIG_DEBUG_RODATA=y # CONFIG_LOCKUP_DETECTOR is not set ## diff -up ./config/hppa/defines.org ./config/hppa/defines --- ./config/hppa/defines.org 2016-09-22 09:38:55.695723334 +0200 +++ ./config/hppa/defines 2016-09-22 09:38:36.771730760 +0200 @@ -6,6 +6,7 @@ kernel-arch: parisc image-file: vmlinux # linux-signed only works for architectures in the main archive signed-modules: false +debug-info: false [image] suggests: palo signature.asc Description: OpenPGP digital signature
Bug#837588: hppa: Please disable CONFIG_FTRACE for hppa architecture
On Mon, 2016-09-19 at 20:50 +0200, Helge Deller wrote: > Hi Ben, > > On 19.09.2016 19:41, Ben Hutchings wrote: > > > > On Mon, 2016-09-12 at 20:28 +0100, Ben Hutchings wrote: > > > > > > On Mon, 2016-09-12 at 18:17 +0200, Helge Deller wrote: > > > > > > > > So, can you please deactivate CONFIG_FTRACE completely for 32- and > > > > 64bit hppa configs? > > > > Is it sufficient to add "CONFIG_FTRACE=n" to > > > > debian/config/hppa/config ? > > > > > > Done. > > > > But this changes the module ABI, resulting in FTBFS. From what you've > > said on this bug, I'm not sure whether the previous version (4.7.2-1) > > was at all usable. > > I was able to boot the 4.7.2-1 kernel on one of my machines where /boot was > big enough. > The hppa buildd servers have smaller /boot partitions though nd the kernel > was not useable/installable there. > > > > > If not then I will delete the ABI reference for > > hppa so the change is ignored. > > I'd propose to delete the ABI reference. > I'm not aware of any hppa-relevant out-of-tree kernel modules either. OK. Ben. -- Ben Hutchings Klipstein's 4th Law of Prototyping and Production: A fail-safe circuit will destroy others. signature.asc Description: This is a digitally signed message part
Bug#837588: hppa: Please disable CONFIG_FTRACE for hppa architecture
Hi Ben, On 19.09.2016 19:41, Ben Hutchings wrote: > On Mon, 2016-09-12 at 20:28 +0100, Ben Hutchings wrote: >> On Mon, 2016-09-12 at 18:17 +0200, Helge Deller wrote: >>> So, can you please deactivate CONFIG_FTRACE completely for 32- and >>> 64bit hppa configs? >>> Is it sufficient to add "CONFIG_FTRACE=n" to >>> debian/config/hppa/config ? >> >> Done. > > But this changes the module ABI, resulting in FTBFS. From what you've > said on this bug, I'm not sure whether the previous version (4.7.2-1) > was at all usable. I was able to boot the 4.7.2-1 kernel on one of my machines where /boot was big enough. The hppa buildd servers have smaller /boot partitions though nd the kernel was not useable/installable there. > If not then I will delete the ABI reference for > hppa so the change is ignored. I'd propose to delete the ABI reference. I'm not aware of any hppa-relevant out-of-tree kernel modules either. Helge signature.asc Description: OpenPGP digital signature
Bug#837588: hppa: Please disable CONFIG_FTRACE for hppa architecture
On Mon, 2016-09-12 at 20:28 +0100, Ben Hutchings wrote: > Control: tag -1 pending > > On Mon, 2016-09-12 at 18:17 +0200, Helge Deller wrote: > [...] > > > > So, can you please deactivate CONFIG_FTRACE completely for 32- and > > 64bit hppa configs? > > Is it sufficient to add "CONFIG_FTRACE=n" to > > debian/config/hppa/config ? > > Done. But this changes the module ABI, resulting in FTBFS. From what you've said on this bug, I'm not sure whether the previous version (4.7.2-1) was at all usable. If not then I will delete the ABI reference for hppa so the change is ignored. Ben. -- Ben Hutchings Klipstein's 4th Law of Prototyping and Production: A fail-safe circuit will destroy others. signature.asc Description: This is a digitally signed message part
Bug#837588: hppa: Please disable CONFIG_FTRACE for hppa architecture
Control: tag -1 pending On Mon, 2016-09-12 at 18:17 +0200, Helge Deller wrote: [...] > So, can you please deactivate CONFIG_FTRACE completely for 32- and 64bit hppa > configs? > Is it sufficient to add "CONFIG_FTRACE=n" to debian/config/hppa/config ? Done. Ben. -- Ben Hutchings Klipstein's 4th Law of Prototyping and Production: A fail-safe circuit will destroy others. signature.asc Description: This is a digitally signed message part
Processed: Re: Bug#837588: hppa: Please disable CONFIG_FTRACE for hppa architecture
Processing control commands: > tag -1 pending Bug #837588 [linux] hppa: Please disable CONFIG_FTRACE for hppa architecture Added tag(s) pending. -- 837588: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=837588 Debian Bug Tracking System Contact ow...@bugs.debian.org with problems
Bug#837588: hppa: Please disable CONFIG_FTRACE for hppa architecture
Package: linux Version: 4.7.2-1 Severity: important We sadly will need to disable CONFIG_FTRACE for hppa architecture completely for now. The problem is, that gcc creates lots of overhead when adding the code for the mcount call (minimum 16 bytes per function, plus two relocation symbol entries) which leads that the 64bit vmlinux kernel file for 4.7 becomes around 99MB, while vmlinux for kernel 4.6 was just around 17MB. This size wouldn't be a real problem itself, but sadly the default /boot partition is currently maximum 128 MB in size which is not able to keep the vmlinux file plus the size for the initrd image (which is a lot bigger than 100MB then). That leads to the fact, that people who have a default hppa installation will not be able to install the new kernel (and don't have space in /boot to keep other older images either). So, can you please deactivate CONFIG_FTRACE completely for 32- and 64bit hppa configs? Is it sufficient to add "CONFIG_FTRACE=n" to debian/config/hppa/config ? Thanks! Helge PS: I'm still working on upstream ftrace support for hppa. It's not complete yet, so we don't loose to much when we disable ftrace again now. Further more I will adjust the debian installer to create bigger /boot partitions so that we can enable it later again.