Kernel Build Help
#11
Hi,

Could anyone who has a working kernel they built themselves share it please. just attach your .config file from the kernel build directory or your /boot/config- file related to your kernel build version.
  Reply
#12
(05-01-2018, 11:17 AM)frewind Wrote: Hi,

Could anyone who has a working kernel they built themselves share it please. just attach your .config file from the kernel build directory or your /boot/config- file related to your kernel build version.

This is a copy of /proc/config.gz when running a freshly burnt ayufan136.


Attached Files
.gz   config.gz (Size: 31.47 KB / Downloads: 161)
  Reply
#13
Ok, so I now have a working kernel build. Firstly, thanks to cooker for uploading the config. I did already try using the config from ayufan's 136 build. so I suspect my issues are down to the options I selected.

For anyone new to building kernels here's how I got this working...

I used the ayufan's 136 config.gz file (see cookers attachment), and I then refreshed the configuration with the make oldconfig command. You could just run make -j5 as this will call oldconfig anyway.

I used the lasted version of ayufan's kernel from git and then created a .config file from the config.gz file from cooker.

Code:
$ gunzip config.gz
$ cat config.gz > .config
$ make oldconfig

You will now be prompted with a series of questions, this is because the kernel source is having things added all the time so oldconfig will make sure you configure any new bit's. I read you should call make oldconfig before every compile, but you should not have to because as I pointed out above make -j5 calls oldconfig anyway.

Here is how I answered the question, I've only listed the option it requests. I cannot tell you if I've answered all of these correctly, perhaps someone can provide feedback on that?
Code:
Unmap kernel when running in userspace (aka "KAISER") (UNMAP_KERNEL_AT_EL0) [Y/n/?] (NEW) Y
Distributed Switch Architecture (NET_DSA) [N/m/y/?] (NEW) N
  Device Tree Overlay ConfigFS interface (OF_CONFIGFS) [N/y/?] (NEW) N
gpio detection driver (GPIO_DET) [N/y/?] (NEW) N
  Driver for Rockchip Ethernet PHYs (ROCKCHIP_PHY) [N/m/y/?] (NEW) m
  build wifi ko modules (WIFI_BUILD_MODULE) [N/y/?] (NEW) N
  Realtek 8192DU USB WiFi Support (RTL8192DU) [N/m/y/?] (NEW) m
  Realtek 8723AU USB WiFi Support (RTL8723AU) [N/m/y/?] (NEW) m
  Realtek 8723B USB WiFi (RTL8723BU) [N/m/y/?] (NEW) m
  Realtek 8812AU USB WiFi Support (RTL8812AU) [N/m/y/?] (NEW) m
  gslX680 d708 touchpad driver for rk3126 pad (TOUCHSCREEN_GSLX680_D708) [N/m/y/?] (NEW) N
  gslX680 touchpad driver for firefly-rk3288 (TOUCHSCREEN_GSLX680_FIREFLY) [N/m/y/?] (NEW) N
  gsl3673 touchpad driver for rk3326 board (TOUCHSCREEN_GSL3673_800X1280) [N/m/y/?] (NEW) N
  VTL touchscreens support (TOUCHSCREEN_VTL_CT36X) [N/m/y] (NEW) N
  GT1X touchscreens support (TOUCHSCREEN_GT1X) [N/m/y] (NEW) N
Pinctrl and GPIO driver for RK805 PMIC (PINCTRL_RK805) [N/m/y/?] (NEW) N
  universal Charger driver (CHARGER_UNIVERSAL) [N/m/y/?] (NEW) N
  RK816 Battery driver (BATTERY_RK816) [N/y/?] (NEW) N
  RK817 Battery driver (BATTERY_RK817) [N/y/?] (NEW) N
  RK817 Charger driver (CHARGER_RK817) [N/y/?] (NEW) N
    rk_virtual thermal driver (RK_VIRTUAL_THERMAL) [N/m/y/?] (NEW) N
Rockchip RK618 MFD Driver (MFD_RK618) [N/m/y/?] (NEW) N
  HDMI CEC support (MEDIA_CEC_SUPPORT) [N/y/?] (NEW) N
  Rockchip Image Signal Processing v1 Unit driver (VIDEO_ROCKCHIP_ISP1) [N/m/y/?] (NEW) N
  Support for Rockchip TSP (ROCKCHIP_TSP) [N/y/?] (NEW) N
  Sony imx219 sensor support (VIDEO_IMX219) [N/m/y/?] (NEW) N
  OmniVision OV2685 sensor support (VIDEO_OV2685) [N/m/y/?] (NEW) N
  OmniVision OV5695 sensor support (VIDEO_OV5695) [N/m/y/?] (NEW) N
  adv7181 driver adapt to rockchip cif isp platform (VIDEO_ADV7181) [N/m/y/?] (NEW) N
  ov7675 driver adapt to rockchip cif isp platform (VIDEO_OV7675) [N/m/y/?] (NEW) N
  nt99230 driver adapt to rockchip cif isp platform (VIDEO_NT99230) [N/m/y/?] (NEW) N
  ov13850 driver adapt to rockchip cif isp platform (VIDEO_OV13850) [N/m/y/?] (NEW) N
  Rockchip RGB support (ROCKCHIP_RGB) [N/m/y/?] (NEW) N
  Rockchip specific extensions for RK3066 HDMI (ROCKCHIP_RK3066_HDMI) [N/m/y/?] (NEW) N
Dumb VGA DAC Bridge support (DRM_DUMB_VGA_DAC) [N/m/y/?] (NEW) N
Synopsis Designware CEC interface (DRM_DW_HDMI_CEC) [N/m/y/?] (NEW) N
Mali Bifrost series support (MALI_BIFROST) [N/m/y/?] (NEW) N
    Rockchip I2S/TDM Device Driver (SND_SOC_ROCKCHIP_I2S_TDM) [N/m/y/?] (NEW) N
  ASoC support for Rockchip multicodecs (SND_SOC_ROCKCHIP_MULTICODECS) [N/m/y/?] (NEW) N
  CX20810 is a voice capture ic. (SND_SOC_CX20810) [N/m/y/?] (NEW) N
  dummy codec (SND_SOC_DUMMY_CODEC) [N/m/y] (NEW) N
  Everest Semi ES8328 CODEC I2C (SND_SOC_ES8328_I2C) [N/m/y] (NEW) N
  Everest Semi ES8396 CODEC (SND_SOC_ES8396) [N/m/y] (NEW) N
  gva codec (SND_SOC_GVA_CODEC) [N/m/y] (NEW) N
  Voice Processor support for FM1288 (SND_SOC_FM1288) [N/m/y/?] (NEW) N
  Rockchip RK312X CODEC (SND_SOC_RK312X) [N/m/y] (NEW) N
  Rockchip RK3228 CODEC (SND_SOC_RK3228) [N/m/y] (NEW) N
  Rockchip RK3308 CODEC (SND_SOC_RK3308) [N/m/y] (NEW) N
  Rockchip RK817 CODEC (SND_SOC_RK817) [N/m/y] (NEW) N
  LED support for ISSI IS31FL32XX I2C LED controller family (LEDS_IS31FL32XX) [N/m/y/?] (NEW) N
Support for ARM architected timer virtual counter access in userspace (ARM_ARCH_TIMER_VCT_ACCESS) [N/y/?] (NEW) N
PX30 (CPU_PX30) [Y/n] (NEW) N
RK3308 (CPU_RK3308) [Y/n] (NEW) N
RK3328 (CPU_RK3328) [Y/n] (NEW) Y
RK3366 (CPU_RK3366) [Y/n] (NEW) N
RK3368 (CPU_RK3368) [Y/n] (NEW) N
RK3399 (CPU_RK3399) [Y/n] (NEW) N
Android Version (ANDROID_VERSION) [0x07010000] (NEW) I just pressed enter
  ROCKCHIP NoC (Network On Chip) Probe DEVFREQ event Driver (DEVFREQ_EVENT_ROCKCHIP_NOCP) [N/m/y/?] (NEW) N
  Rockchip OTP Support (ROCKCHIP_OTP) [N/m/y/?] (NEW) N
FS Encryption (Per-file encryption) (FS_ENCRYPTION) [N/m/y/?] (NEW) N
Show process information on printks (PRINTK_PROCESS) [N/y/?] (NEW) N
  Enable trace events for preempt and irq disable/enable (PREEMPTIRQ_EVENTS) [N/y/?] (NEW) N
  Speck cipher algorithm (CRYPTO_SPECK) [N/m/y/?] (NEW) N

I then ran make -j5 as per the instructions at the start of this post.

Thanks to everyone for the help Smile
  Reply
#14
Please be sadly informed that the latest build as of today (i.e. file 0.6.44-239-arm64.img) has fixed/broke some code so that this method no longer work.

Copy of the file rk3328-rock64.dtb manually to /etc/flash-kernel still helps a bit  (i.e. error prompted if you don't).

The fatal last step is the "make install" will ignore the newly compiled labeled "dirty" version and fail back to the holy one.
  Reply
#15
I'll have a play later and see what's going on...
  Reply
#16
Hi,

I just downloaded bionic-minimal-rock64-0.6.44-239-arm64 & the latest linux-kernel-release-4.4.zip. I had to install python this time around as bionic only has python3 by default. I then followed the process outlined in this thread, this time I had to copy initrd.img-4.4.126 to initrd.img-4.4.126.old but it did then install

Before install

Linux rock64 4.4.126-rockchip-ayufan-239 #1 SMP Sun May 27 18:38:24 UTC 2018 aarch64 aarch64 aarch64 GNU/Linux

After Install

Linux rock64 4.4.126 #1 SMP Sat Jun 2 12:34:16 UTC 2018 aarch64 aarch64 aarch64 GNU/Linux

Nice thing about the latest uboot is you can pick the new or old version of the kernel to boot.

What Image are you running?
  Reply
#17
Hi,

I use stretch-minimal-rock64-0.6.44-239-arm64.img

Have you tested if the "new" kernel actually consists of those new kernel modules you added?  I saw on the last few lines after "successful" compilation that a new kernel name labeled with the word "dirty" (as before) was created but not being used. @@   so I said it fail back to the ...
  Reply
#18
In the last few lines it says
Quote:Use --force if you want version 4.4.126-g13bc656c-dirty.

command "make" does not have --force (on manpage)
so, what force is it referring to?


Code:
make[1]: 'include/generated/vdso-offsets.h' is up to date.
  CHK     include/generated/compile.h
  SKIPPED include/generated/compile.h
  CHK     kernel/config_data.h
/bin/bash ./arch/arm64/boot/install.sh 4.4.126-g13bc656c-dirty \
arch/arm64/boot/Image System.map "/boot"
run-parts: executing /etc/kernel/postinst.d/apt-auto-removal 4.4.126-g13bc656c-dirty /boot/vmlinuz-4.4.126-g13bc656c-dirty
run-parts: executing /etc/kernel/postinst.d/initramfs-tools 4.4.126-g13bc656c-dirty /boot/vmlinuz-4.4.126-g13bc656c-dirty
update-initramfs: Generating /boot/initrd.img-4.4.126-g13bc656c-dirty
Warning: root device  does not exist
Using DTB: rockchip/rk3328-rock64.dtb
Installing /etc/flash-kernel/dtbs/rk3328-rock64.dtb into /boot/dtbs/4.4.126-g13bc656c-dirty/rockchip/rk3328-rock64.dtb
Taking backup of rk3328-rock64.dtb.
Installing new rk3328-rock64.dtb.
Ignoring old or unknown version 4.4.126-g13bc656c-dirty (latest is 4.4.126-rockchip-ayufan-239.old)
Use --force if you want version 4.4.126-g13bc656c-dirty.
Installing /etc/flash-kernel/dtbs/rk3328-rock64.dtb into /boot/dtbs/4.4.126-rockchip-ayufan-239.old/rockchip/rk3328-rock64.dtb
Installing new rk3328-rock64.dtb.
flash-kernel: installing version 4.4.126-rockchip-ayufan-239.old
Taking backup of Image.
Installing new Image.
Taking backup of initrd.img.
Installing new initrd.img.
Taking backup of dtb.
Installing new dtb.
run-parts: executing /etc/kernel/postinst.d/zz-flash-kernel 4.4.126-g13bc656c-dirty /boot/vmlinuz-4.4.126-g13bc656c-dirty
Using DTB: rockchip/rk3328-rock64.dtb
Installing /etc/flash-kernel/dtbs/rk3328-rock64.dtb into /boot/dtbs/4.4.126-g13bc656c-dirty/rockchip/rk3328-rock64.dtb
Taking backup of rk3328-rock64.dtb.
Installing new rk3328-rock64.dtb.
Ignoring old or unknown version 4.4.126-g13bc656c-dirty (latest is 4.4.126-rockchip-ayufan-239.old)
  Reply
#19
(06-03-2018, 11:58 AM)cooker Wrote: In the last few lines it says
Quote:Use --force if you want version 4.4.126-g13bc656c-dirty.

command "make" does not have --force (on manpage)
so, what force is it referring to?

Since make has branched out to some sort of install script, I'd check in there for other commands.

Code:
/bin/bash ./arch/arm64/boot/install.sh 4.4.126-g13bc656c-dirty


It's probably something to do with flash-kernel, as from what I can gather so far it writes the initramfs and kernel into the right spots on the microSD... https://manpages.debian.org/testing/flas....8.en.html
  Reply
#20
(06-03-2018, 06:09 PM)pfeerick Wrote:
Code:
/bin/bash ./arch/arm64/boot/install.sh 4.4.126-g13bc656c-dirty

It's probably something to do with flash-kernel, as from what I can gather so far it writes the initramfs and kernel into the right spots on the microSD... https://manpages.debian.org/testing/flas....8.en.html

Thanks for your reply.

I tried your above command and get
Quote: *** Missing file:
 *** You need to run "make" before "make install".

then I check the script install.sh, fill in two more argument and it looks like this
Code:
rock64@rock64:~/linux-kernel$ sudo /bin/bash ./arch/arm/boot/install.sh 4.4.126-g13bc656c-dirty /boot/vmlinuz-4.4.126-g13bc656c-dirty /boot/System.map-4.4.126-g13bc656c-dirty
[sudo] password for rock64:
./arch/arm/boot/install.sh: line 39: /sbin/: Is a directory
./arch/arm/boot/install.sh: line 39: exec: /sbin/: cannot execute: Is a directory

I edited line 39 "blindly" (add ~ to get ~/sbin/...) to make it looks similar to line 38 (which is ~/bin/...)
rerun the above command and get
Quote:Installing normal kernel
You have to install it yourself

I have no intension to drill further into those scripts.  I never pass the learning curve on such activities with Rock64's ecosystem and experienced 100.0% waste of time.  Looks forward to your further assistance.  Thanks in advance for your help. Big Grin
  Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  Debian build from mrfixit2001 Luke 18 11,782 05-17-2021, 02:35 AM
Last Post: Wizzard
  Security Patches for the Kernel kwinz 8 1,694 01-16-2021, 05:34 PM
Last Post: kuleszdl
  Debian kernel stuck at 4.4.167 Enig123 5 1,417 12-29-2020, 12:57 PM
Last Post: kwinz
  Arch Linux Arm --> Kernel 5.8 breaks installation as365n4 12 5,201 08-31-2020, 01:41 AM
Last Post: as365n4
  mainline kernel sound support Openwrt lucize 2 1,499 05-01-2020, 05:09 PM
Last Post: PakoSt
  5.3 kernel support? csrf 5 2,741 04-18-2020, 11:34 PM
Last Post: CameronNemo
Question alternative browser / seamonkey armhf build? kapqa 1 1,063 03-26-2020, 03:02 AM
Last Post: kapqa
  Help troubleshooting kernel panic gabrielfin 3 1,759 03-02-2020, 04:18 PM
Last Post: gabrielfin
  csdr build issues. TravisH 0 786 02-19-2020, 04:47 AM
Last Post: TravisH
  need a dts file to set some pins as pulldown interrupts in kernel using a DTO dkebler 0 847 02-05-2020, 10:58 PM
Last Post: dkebler

Forum Jump:


Users browsing this thread: 1 Guest(s)