From: Christoph Lameter <cl@gentwo.org> Date: 2014-06-11 15:52:46
This is under Ubuntu Utopic Unicorn on a Power 8 system while simply
trying to build with the Ubuntu standard kernel config. It could be that
these issues come about because we do not have an rc1 yet but I wanted to
give some early notice. Also this is a new arch to me so I may not be
aware of how things work.
1. Bad relocation while building:
root@rd-power8:/rdhome/clameter/linux# make
CHK include/config/kernel.release
CHK include/generated/uapi/linux/version.h
CHK include/generated/utsrelease.h
CALL scripts/checksyscalls.sh
CHK include/generated/compile.h
SKIPPED include/generated/compile.h
CALL arch/powerpc/kernel/systbl_chk.sh
CALL arch/powerpc/kernel/prom_init_check.sh
CHK kernel/config_data.h
CALL arch/powerpc/relocs_check.pl
WARNING: 1 bad relocations
c000000000cc7df0 R_PPC64_ADDR64 __crc_TOC.
2. "make install" fails
root@rd-power8:/rdhome/clameter/linux# make install
sh -x /rdhome/clameter/linux/arch/powerpc/boot/install.sh "3.15.0+"
vmlinux System.map "/boot" arch/powerpc/boot/zImage.pseries
arch/powerpc/boot/zImage.epapr
+ set -e
+ [ -x /home/clameter/bin/installkernel ]
+ [ -x /sbin/installkernel ]
+ exec /sbin/installkernel 3.15.0+ vmlinux System.map /boot
arch/powerpc/boot/zImage.pseries arch/powerpc/boot/zImage.epapr
Usage: installkernel <version> <image> <System.map> <directory>
/rdhome/clameter/linux/arch/powerpc/boot/Makefile:393: recipe for target
'install' failed
make[1]: *** [install] Error 1
/rdhome/clameter/linux/arch/powerpc/Makefile:294: recipe for target
'install' failed
make: *** [install] Error 2
3. Ubuntu "make-kpkg" fails
clameter@rd-power8:~/linux$ fakeroot make-kpkg --initrd --revision 1
kernel_image
exec make kpkg_version=13.013 -f
/usr/share/kernel-package/ruleset/minimal.mk debian DEBIAN_REVISION=1
INITRD=YES
====== making target debian/stamp/conf/minimal_debian [new prereqs:
]======
This is kernel package version 13.013.
test -d debian || mkdir debian
test ! -e stamp-building || rm -f stamp-building
install -p -m 755 /usr/share/kernel-package/rules debian/rules
for file in ChangeLog Control Control.bin86 config templates.in rules;
do \
cp -f /usr/share/kernel-package/$file ./debian/;
\
done
cp: cannot stat ‘/usr/share/kernel-package/ChangeLog’: No such file or
directory
for dir in Config docs examples ruleset scripts pkg po; do
\
cp -af /usr/share/kernel-package/$dir ./debian/;
\
done
test -f debian/control || sed -e 's/=V/../g' \
-e 's/=D/1/g' -e 's/=A/ppc64el/g' \
-e 's/=SA//g' \
-e 's/=I//g' \
-e 's/=CV/./g' \
-e 's/=M/Unknown Kernel Package Maintainer
[off-list ref]/g'
\
-e 's/=ST/linux/g' -e 's/=B/ppc64el/g' \
-e 's/=R//g' /usr/share/kernel-package/Control >
debian/control
test -f debian/changelog || sed -e 's/=V/../g' \
-e 's/=D/1/g' -e 's/=A/ppc64el/g' \
-e 's/=ST/linux/g' -e 's/=B/ppc64el/g' \
-e 's/=M/Unknown Kernel Package Maintainer
[off-list ref]/g'
\
/usr/share/kernel-package/changelog > debian/changelog
chmod 0644 debian/control debian/changelog
test -d ./debian/stamp || mkdir debian/stamp
make -f debian/rules debian/stamp/conf/kernel-conf
make[1]: Entering directory '/rdhome/clameter/linux'
debian/ruleset/misc/checks.mk:36: *** Error. I do not know where the
kernel image goes to [kimagedest undefined] The usual case for this is
that I could not determine which arch or subarch this machine belongs to.
Please specify a subarch, and try again.. Stop.
make[1]: Leaving directory '/rdhome/clameter/linux'
/usr/share/kernel-package/ruleset/minimal.mk:93: recipe for target
'debian/stamp/conf/minimal_debian' failed
make: *** [debian/stamp/conf/minimal_debian] Error 2
Failed to create a ./debian directory: at /usr/bin/make-kpkg line 966.
4. Errors during build:
Lots of integer to differnt pointer size conversions?
From: Benjamin Herrenschmidt <benh@kernel.crashing.org> Date: 2014-06-11 20:26:39
On Wed, 2014-06-11 at 10:44 -0500, Christoph Lameter wrote:
This is under Ubuntu Utopic Unicorn on a Power 8 system while simply
trying to build with the Ubuntu standard kernel config. It could be that
these issues come about because we do not have an rc1 yet but I wanted to
give some early notice. Also this is a new arch to me so I may not be
aware of how things work.
Can you try my current -next ? It has an additional fix or two by Anton
for building with ABIv2 that I'll send to Linus tomorrow.
Cheers,
Ben.
1. Bad relocation while building:
root@rd-power8:/rdhome/clameter/linux# make
CHK include/config/kernel.release
CHK include/generated/uapi/linux/version.h
CHK include/generated/utsrelease.h
CALL scripts/checksyscalls.sh
CHK include/generated/compile.h
SKIPPED include/generated/compile.h
CALL arch/powerpc/kernel/systbl_chk.sh
CALL arch/powerpc/kernel/prom_init_check.sh
CHK kernel/config_data.h
CALL arch/powerpc/relocs_check.pl
WARNING: 1 bad relocations
c000000000cc7df0 R_PPC64_ADDR64 __crc_TOC.
2. "make install" fails
root@rd-power8:/rdhome/clameter/linux# make install
sh -x /rdhome/clameter/linux/arch/powerpc/boot/install.sh "3.15.0+"
vmlinux System.map "/boot" arch/powerpc/boot/zImage.pseries
arch/powerpc/boot/zImage.epapr
+ set -e
+ [ -x /home/clameter/bin/installkernel ]
+ [ -x /sbin/installkernel ]
+ exec /sbin/installkernel 3.15.0+ vmlinux System.map /boot
arch/powerpc/boot/zImage.pseries arch/powerpc/boot/zImage.epapr
Usage: installkernel <version> <image> <System.map> <directory>
/rdhome/clameter/linux/arch/powerpc/boot/Makefile:393: recipe for target
'install' failed
make[1]: *** [install] Error 1
/rdhome/clameter/linux/arch/powerpc/Makefile:294: recipe for target
'install' failed
make: *** [install] Error 2
3. Ubuntu "make-kpkg" fails
clameter@rd-power8:~/linux$ fakeroot make-kpkg --initrd --revision 1
kernel_image
exec make kpkg_version=13.013 -f
/usr/share/kernel-package/ruleset/minimal.mk debian DEBIAN_REVISION=1
INITRD=YES
====== making target debian/stamp/conf/minimal_debian [new prereqs:
]======
This is kernel package version 13.013.
test -d debian || mkdir debian
test ! -e stamp-building || rm -f stamp-building
install -p -m 755 /usr/share/kernel-package/rules debian/rules
for file in ChangeLog Control Control.bin86 config templates.in rules;
do \
cp -f /usr/share/kernel-package/$file ./debian/;
\
done
cp: cannot stat ‘/usr/share/kernel-package/ChangeLog’: No such file or
directory
for dir in Config docs examples ruleset scripts pkg po; do
\
cp -af /usr/share/kernel-package/$dir ./debian/;
\
done
test -f debian/control || sed -e 's/=V/../g' \
-e 's/=D/1/g' -e 's/=A/ppc64el/g' \
-e 's/=SA//g' \
-e 's/=I//g' \
-e 's/=CV/./g' \
-e 's/=M/Unknown Kernel Package Maintainer
[off-list ref]/g'
\
-e 's/=ST/linux/g' -e 's/=B/ppc64el/g' \
-e 's/=R//g' /usr/share/kernel-package/Control >
debian/control
test -f debian/changelog || sed -e 's/=V/../g' \
-e 's/=D/1/g' -e 's/=A/ppc64el/g' \
-e 's/=ST/linux/g' -e 's/=B/ppc64el/g' \
-e 's/=M/Unknown Kernel Package Maintainer
[off-list ref]/g'
\
/usr/share/kernel-package/changelog > debian/changelog
chmod 0644 debian/control debian/changelog
test -d ./debian/stamp || mkdir debian/stamp
make -f debian/rules debian/stamp/conf/kernel-conf
make[1]: Entering directory '/rdhome/clameter/linux'
debian/ruleset/misc/checks.mk:36: *** Error. I do not know where the
kernel image goes to [kimagedest undefined] The usual case for this is
that I could not determine which arch or subarch this machine belongs to.
Please specify a subarch, and try again.. Stop.
make[1]: Leaving directory '/rdhome/clameter/linux'
/usr/share/kernel-package/ruleset/minimal.mk:93: recipe for target
'debian/stamp/conf/minimal_debian' failed
make: *** [debian/stamp/conf/minimal_debian] Error 2
Failed to create a ./debian directory: at /usr/bin/make-kpkg line 966.
4. Errors during build:
Lots of integer to differnt pointer size conversions?
From: Anton Blanchard <hidden> Date: 2014-06-12 12:09:15
Hi Christoph,
This is under Ubuntu Utopic Unicorn on a Power 8 system while simply
trying to build with the Ubuntu standard kernel config. It could be
that these issues come about because we do not have an rc1 yet but I
wanted to give some early notice. Also this is a new arch to me so I
may not be aware of how things work.
1. Bad relocation while building:
root@rd-power8:/rdhome/clameter/linux# make
CHK include/config/kernel.release
CHK include/generated/uapi/linux/version.h
CHK include/generated/utsrelease.h
CALL scripts/checksyscalls.sh
CHK include/generated/compile.h
SKIPPED include/generated/compile.h
CALL arch/powerpc/kernel/systbl_chk.sh
CALL arch/powerpc/kernel/prom_init_check.sh
CHK kernel/config_data.h
CALL arch/powerpc/relocs_check.pl
WARNING: 1 bad relocations
c000000000cc7df0 R_PPC64_ADDR64 __crc_TOC.
The TOC symbol export is special and I think we might need to get our
script to ignore it.
Shows how much we use make install :) Below is a quick hack to get you going
but we should look at either fixing the Ubuntu installkernel to handle
extra optional args, or stop passing them from the ppc64 kernel
install.sh script.
Anton
--
@@ -23,8 +23,8 @@ set -e# User may have a custom install script-if[-x~/bin/${INSTALLKERNEL}];thenexec~/bin/${INSTALLKERNEL}"$@";fi-if[-x/sbin/${INSTALLKERNEL}];thenexec/sbin/${INSTALLKERNEL}"$@";fi+if[-x~/bin/${INSTALLKERNEL}];thenexec~/bin/${INSTALLKERNEL}$1$2$3$4;fi+if[-x/sbin/${INSTALLKERNEL}];thenexec/sbin/${INSTALLKERNEL}$1$2$3$4;fi# Default install
@@ -45,6 +45,9 @@ while (<FD>) {/\bR_PPC_ADDR16_HA\b/or/\bR_PPC_RELATIVE\b/or/\bR_PPC_NONE\b/);+#TheTOCis"special"solet'signoreit.+nextif(/__crc_TOC\./);+#Ifweseethistypeofrelocationit'sanidicationthat#we/may/beusinganoldversionofbinutils.if(/R_PPC64_UADDR64/){
<snip>
Shows how much we use make install :) Below is a quick hack to get you going
but we should look at either fixing the Ubuntu installkernel to handle
extra optional args, or stop passing them from the ppc64 kernel
install.sh script.
It seems like passign the zImage files is probably wrong. How about:
From: Anton Blanchard <hidden> Date: 2014-07-08 01:06:43
Hi Tony,
quoted
Shows how much we use make install :) Below is a quick hack to get
you going but we should look at either fixing the Ubuntu
installkernel to handle extra optional args, or stop passing them
from the ppc64 kernel install.sh script.
It seems like passign the zImage files is probably wrong. How about:
@@ -390,7 +390,7 @@ $(obj)/zImage.initrd: $(addprefix $(obj)/, $(initrd-y))@rm-f$@;ln$<$@install:$(CONFIGURE)$(addprefix$(obj)/, $(image-y))-sh-x$(srctree)/$(src)/install.sh"$(KERNELRELEASE)"vmlinuxSystem.map"$(INSTALL_PATH)"$^+sh-x$(srctree)/$(src)/install.sh"$(KERNELRELEASE)"vmlinuxSystem.map"$(INSTALL_PATH)"# anything not in $(targets)clean-files+=$(image-)$(initrd-)cuImage.*dtbImage.*treeImage.*\
Looks reasonable to me. Grant added this back in commit 29f1aff2 (powerpc:
Copy bootable images in the default install script) but the other archs have
gone in a different direction and created make zinstall targets.
Anton