qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* Replacing existing kernel with new on qemuriscv64
@ 2020-07-20  7:45 Pankaj  Vinadrao Joshi
  2020-07-20 16:59 ` Alistair Francis
  0 siblings, 1 reply; 5+ messages in thread
From: Pankaj  Vinadrao Joshi @ 2020-07-20  7:45 UTC (permalink / raw)
  To: qemu-devel

[-- Attachment #1: Type: text/plain, Size: 4161 bytes --]

Hi ,
I am trying to replace my existing kernel image which is 5.5.6 to 5.5.7 on qemuriscv64 i would like to mention i have built my qemu image with openembedded-core.

i have tried to build the kernel 5.5.7 natively,i was able to build the kernel successfully and in my /boot folder i am able to see vmlinux-5.5.7  but now i want to install this image..i have tried to do it by make install i didnt got any error with it but when i rebooted my system i am getting

i have followed the following steps to build kernel
$root@qemuriscv64-exaleapsemi-r2:/usr/src/kernel#  make menuconfig arch=riscv64
$root@qemuriscv64-exaleapsemi-r2:/usr/src/kernel# make -j4
$root@qemuriscv64-exaleapsemi-r2:/usr/src/kernel# make modules_install
$root@qemuriscv64-exaleapsemi-r2:/usr/src/kernel# make install
sh ./arch/riscv/boot/install.sh 5.5.7 \
arch/riscv/boot/Image System.map "/boot"
Installing normal kernel

$reboot
13024.451157] printk: systemd-shutdow: 37 output lines suppressed due to ratelimiting
[13024.527282] systemd-shutdown[1]: Syncing filesystems and block devices.
[13024.668538] systemd-shutdown[1]: Sending SIGTERM to remaining processes...
[13024.719496] systemd-journald[87]: Received SIGTERM from PID 1 (systemd-shutdow).
[13024.769405] systemd-shutdown[1]: Sending SIGKILL to remaining processes...
[13024.834318] systemd-shutdown[1]: Unmounting file systems.
[13024.868285] [13413]: Remounting '/' read-only in with options '(null)'.
[13025.228499] EXT4-fs (vda): re-mounted. Opts: (null)
[13025.358123] systemd-shutdown[1]: All filesystems unmounted.
[13025.358576] systemd-shutdown[1]: Deactivating swaps.
[13025.361264] systemd-shutdown[1]: All swaps deactivated.
[13025.361727] systemd-shutdown[1]: Detaching loop devices.
[13025.420602] systemd-shutdown[1]: All loop devices detached.
[13025.421071] systemd-shutdown[1]: Detaching DM devices.
[13025.595237] reboot: Restarting system
[13046.599875] rcu: INFO: rcu_sched detected stalls on CPUs/tasks:
[13046.600329] (detected by 0, t=5252 jiffies, g=2837145, q=17)
[13046.600763] rcu: All QSes seen, last rcu_sched kthread activity 5252 (4298153942-4298148690), jiffies_till_next_fqs=1, root ->qsmask 0x0
[13046.601503] systemd-shutdow R  running task        0     1      0 0x00000008
[13046.602053] Call Trace:
[13046.602562] [<ffffffe00006d3fc>] walk_stackframe+0x0/0xa4
[13046.602890] [<ffffffe00006d5e2>] show_stack+0x2a/0x34
[13046.603156] [<ffffffe000091094>] sched_show_task+0x158/0x174
[13046.603442] [<ffffffe0000c4dde>] rcu_sched_clock_irq+0x6b2/0x6ec
[13046.603740] [<ffffffe0000ccadc>] update_process_times+0x1e/0x44
[13046.604009] [<ffffffe0000d79dc>] tick_sched_handle.isra.16+0x30/0x3e
[13046.604331] [<ffffffe0000d7a38>] tick_sched_timer+0x4e/0x94
[13046.604620] [<ffffffe0000cd44a>] __hrtimer_run_queues+0x10c/0x2de
[13046.604928] [<ffffffe0000cdc96>] hrtimer_interrupt+0xcc/0x1d6
[13046.605236] [<ffffffe0005d3f7c>] riscv_timer_interrupt+0x32/0x3a
[13046.605580] [<ffffffe0007889ce>] do_IRQ+0xae/0xba
[13046.605837] [<ffffffe00006bd3c>] ret_from_exception+0x0/0xc
[13046.606127] [<ffffffe00006ca58>] machine_restart+0xc/0xe
[13046.606508] rcu: rcu_sched kthread starved for 5252 jiffies! g2837145 f0x2 RCU_GP_WAIT_FQS(5) ->state=0x0 ->cpu=0
[13046.606990] rcu: RCU grace-period kthread stack dump:
[13046.607257] rcu_sched       R  running task        0    10      2 0x00000000
[13046.607610] Call Trace:
[13046.607774] [<ffffffe000784258>] __schedule+0x1a8/0x482
[13046.608044] [<ffffffe000784592>] schedule+0x60/0xda
[13046.608304] [<ffffffe000787a56>] schedule_timeout+0x15c/0x2b2
[13046.608602] [<ffffffe0000c2ec8>] rcu_gp_kthread+0x4cc/0x7ec
[13046.608889] [<ffffffe00008b0f2>] kthread+0xf0/0x102
[13046.609162] [<ffffffe00006bd3c>] ret_from_exception+0x0/0xc

..... so on getting continuously......


Can someone help me out how i can replace my kernel to 5.5.7 since i am not able to find grub or grub2 on my riscv platform?? i have googled for the solution but most of them seems to be x86 specific where they are trying to change the grub??Where i should modify for riscv to get my kernel up????


Thanks

[-- Attachment #2: Type: text/html, Size: 9569 bytes --]

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

* Re: Replacing existing kernel with new on qemuriscv64
  2020-07-20  7:45 Replacing existing kernel with new on qemuriscv64 Pankaj  Vinadrao Joshi
@ 2020-07-20 16:59 ` Alistair Francis
  2020-07-20 18:19   ` Pankaj  Vinadrao Joshi
  0 siblings, 1 reply; 5+ messages in thread
From: Alistair Francis @ 2020-07-20 16:59 UTC (permalink / raw)
  To: Pankaj Vinadrao Joshi; +Cc: qemu-devel

On Mon, Jul 20, 2020 at 2:46 AM Pankaj Vinadrao Joshi
<Pankaj.VJ@exaleapsemi.com> wrote:
>
> Hi ,
> I am trying to replace my existing kernel image which is 5.5.6 to 5.5.7 on qemuriscv64 i would like to mention i have built my qemu image with openembedded-core.
>
> i have tried to build the kernel 5.5.7 natively,i was able to build the kernel successfully and in my /boot folder i am able to see vmlinux-5.5.7  but now i want to install this image..i have tried to do it by make install i didnt got any error with it but when i rebooted my system i am getting
>
> i have followed the following steps to build kernel
> $root@qemuriscv64-exaleapsemi-r2:/usr/src/kernel#  make menuconfig arch=riscv64
> $root@qemuriscv64-exaleapsemi-r2:/usr/src/kernel# make -j4
> $root@qemuriscv64-exaleapsemi-r2:/usr/src/kernel# make modules_install
> $root@qemuriscv64-exaleapsemi-r2:/usr/src/kernel# make install
> sh ./arch/riscv/boot/install.sh 5.5.7 \
> arch/riscv/boot/Image System.map "/boot"
> Installing normal kernel
>
> $reboot
> 13024.451157] printk: systemd-shutdow: 37 output lines suppressed due to ratelimiting
> [13024.527282] systemd-shutdown[1]: Syncing filesystems and block devices.
> [13024.668538] systemd-shutdown[1]: Sending SIGTERM to remaining processes...
> [13024.719496] systemd-journald[87]: Received SIGTERM from PID 1 (systemd-shutdow).
> [13024.769405] systemd-shutdown[1]: Sending SIGKILL to remaining processes...
> [13024.834318] systemd-shutdown[1]: Unmounting file systems.
> [13024.868285] [13413]: Remounting '/' read-only in with options '(null)'.
> [13025.228499] EXT4-fs (vda): re-mounted. Opts: (null)
> [13025.358123] systemd-shutdown[1]: All filesystems unmounted.
> [13025.358576] systemd-shutdown[1]: Deactivating swaps.
> [13025.361264] systemd-shutdown[1]: All swaps deactivated.
> [13025.361727] systemd-shutdown[1]: Detaching loop devices.
> [13025.420602] systemd-shutdown[1]: All loop devices detached.
> [13025.421071] systemd-shutdown[1]: Detaching DM devices.
> [13025.595237] reboot: Restarting system
> [13046.599875] rcu: INFO: rcu_sched detected stalls on CPUs/tasks:
> [13046.600329] (detected by 0, t=5252 jiffies, g=2837145, q=17)
> [13046.600763] rcu: All QSes seen, last rcu_sched kthread activity 5252 (4298153942-4298148690), jiffies_till_next_fqs=1, root ->qsmask 0x0
> [13046.601503] systemd-shutdow R  running task        0     1      0 0x00000008
> [13046.602053] Call Trace:
> [13046.602562] [<ffffffe00006d3fc>] walk_stackframe+0x0/0xa4
> [13046.602890] [<ffffffe00006d5e2>] show_stack+0x2a/0x34
> [13046.603156] [<ffffffe000091094>] sched_show_task+0x158/0x174
> [13046.603442] [<ffffffe0000c4dde>] rcu_sched_clock_irq+0x6b2/0x6ec
> [13046.603740] [<ffffffe0000ccadc>] update_process_times+0x1e/0x44
> [13046.604009] [<ffffffe0000d79dc>] tick_sched_handle.isra.16+0x30/0x3e
> [13046.604331] [<ffffffe0000d7a38>] tick_sched_timer+0x4e/0x94
> [13046.604620] [<ffffffe0000cd44a>] __hrtimer_run_queues+0x10c/0x2de
> [13046.604928] [<ffffffe0000cdc96>] hrtimer_interrupt+0xcc/0x1d6
> [13046.605236] [<ffffffe0005d3f7c>] riscv_timer_interrupt+0x32/0x3a
> [13046.605580] [<ffffffe0007889ce>] do_IRQ+0xae/0xba
> [13046.605837] [<ffffffe00006bd3c>] ret_from_exception+0x0/0xc
> [13046.606127] [<ffffffe00006ca58>] machine_restart+0xc/0xe
> [13046.606508] rcu: rcu_sched kthread starved for 5252 jiffies! g2837145 f0x2 RCU_GP_WAIT_FQS(5) ->state=0x0 ->cpu=0
> [13046.606990] rcu: RCU grace-period kthread stack dump:
> [13046.607257] rcu_sched       R  running task        0    10      2 0x00000000
> [13046.607610] Call Trace:
> [13046.607774] [<ffffffe000784258>] __schedule+0x1a8/0x482
> [13046.608044] [<ffffffe000784592>] schedule+0x60/0xda
> [13046.608304] [<ffffffe000787a56>] schedule_timeout+0x15c/0x2b2
> [13046.608602] [<ffffffe0000c2ec8>] rcu_gp_kthread+0x4cc/0x7ec
> [13046.608889] [<ffffffe00008b0f2>] kthread+0xf0/0x102
> [13046.609162] [<ffffffe00006bd3c>] ret_from_exception+0x0/0xc
>
> ..... so on getting continuously......
>
>
> Can someone help me out how i can replace my kernel to 5.5.7 since i am not able to find grub or grub2 on my riscv platform?? i have googled for the solution but most of them seems to be x86 specific where they are trying to change the grub??Where i should modify for riscv to get my kernel up????

You won't be able to install a new kernel from the QEMU guest. You
will need to use OpenEmbedded to build a new kernel and boot that.

Alistair

>
>
> Thanks


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

* Re: Replacing existing kernel with new on qemuriscv64
  2020-07-20 16:59 ` Alistair Francis
@ 2020-07-20 18:19   ` Pankaj  Vinadrao Joshi
  2020-07-20 18:40     ` Alistair Francis
  0 siblings, 1 reply; 5+ messages in thread
From: Pankaj  Vinadrao Joshi @ 2020-07-20 18:19 UTC (permalink / raw)
  To: Alistair Francis; +Cc: qemu-devel

[-- Attachment #1: Type: text/plain, Size: 5196 bytes --]

Hi Alistair Francis,

Thanks for your response.I have same concern for other riscv hardware with custom kernel will same be applicable for it?If no from where i should change my kernel image since there also i am not able to find grub and the clarification given on web are seems to be very specific to x86 arch where i should look in case of riscv ??

Thanks

________________________________
From: Alistair Francis <alistair23@gmail.com>
Sent: Monday, July 20, 2020 10:29 PM
To: Pankaj Vinadrao Joshi <Pankaj.VJ@exaleapsemi.com>
Cc: qemu-devel@nongnu.org <qemu-devel@nongnu.org>
Subject: Re: Replacing existing kernel with new on qemuriscv64

On Mon, Jul 20, 2020 at 2:46 AM Pankaj Vinadrao Joshi
<Pankaj.VJ@exaleapsemi.com> wrote:
>
> Hi ,
> I am trying to replace my existing kernel image which is 5.5.6 to 5.5.7 on qemuriscv64 i would like to mention i have built my qemu image with openembedded-core.
>
> i have tried to build the kernel 5.5.7 natively,i was able to build the kernel successfully and in my /boot folder i am able to see vmlinux-5.5.7  but now i want to install this image..i have tried to do it by make install i didnt got any error with it but when i rebooted my system i am getting
>
> i have followed the following steps to build kernel
> $root@qemuriscv64-exaleapsemi-r2:/usr/src/kernel#  make menuconfig arch=riscv64
> $root@qemuriscv64-exaleapsemi-r2:/usr/src/kernel# make -j4
> $root@qemuriscv64-exaleapsemi-r2:/usr/src/kernel# make modules_install
> $root@qemuriscv64-exaleapsemi-r2:/usr/src/kernel# make install
> sh ./arch/riscv/boot/install.sh 5.5.7 \
> arch/riscv/boot/Image System.map "/boot"
> Installing normal kernel
>
> $reboot
> 13024.451157] printk: systemd-shutdow: 37 output lines suppressed due to ratelimiting
> [13024.527282] systemd-shutdown[1]: Syncing filesystems and block devices.
> [13024.668538] systemd-shutdown[1]: Sending SIGTERM to remaining processes...
> [13024.719496] systemd-journald[87]: Received SIGTERM from PID 1 (systemd-shutdow).
> [13024.769405] systemd-shutdown[1]: Sending SIGKILL to remaining processes...
> [13024.834318] systemd-shutdown[1]: Unmounting file systems.
> [13024.868285] [13413]: Remounting '/' read-only in with options '(null)'.
> [13025.228499] EXT4-fs (vda): re-mounted. Opts: (null)
> [13025.358123] systemd-shutdown[1]: All filesystems unmounted.
> [13025.358576] systemd-shutdown[1]: Deactivating swaps.
> [13025.361264] systemd-shutdown[1]: All swaps deactivated.
> [13025.361727] systemd-shutdown[1]: Detaching loop devices.
> [13025.420602] systemd-shutdown[1]: All loop devices detached.
> [13025.421071] systemd-shutdown[1]: Detaching DM devices.
> [13025.595237] reboot: Restarting system
> [13046.599875] rcu: INFO: rcu_sched detected stalls on CPUs/tasks:
> [13046.600329] (detected by 0, t=5252 jiffies, g=2837145, q=17)
> [13046.600763] rcu: All QSes seen, last rcu_sched kthread activity 5252 (4298153942-4298148690), jiffies_till_next_fqs=1, root ->qsmask 0x0
> [13046.601503] systemd-shutdow R  running task        0     1      0 0x00000008
> [13046.602053] Call Trace:
> [13046.602562] [<ffffffe00006d3fc>] walk_stackframe+0x0/0xa4
> [13046.602890] [<ffffffe00006d5e2>] show_stack+0x2a/0x34
> [13046.603156] [<ffffffe000091094>] sched_show_task+0x158/0x174
> [13046.603442] [<ffffffe0000c4dde>] rcu_sched_clock_irq+0x6b2/0x6ec
> [13046.603740] [<ffffffe0000ccadc>] update_process_times+0x1e/0x44
> [13046.604009] [<ffffffe0000d79dc>] tick_sched_handle.isra.16+0x30/0x3e
> [13046.604331] [<ffffffe0000d7a38>] tick_sched_timer+0x4e/0x94
> [13046.604620] [<ffffffe0000cd44a>] __hrtimer_run_queues+0x10c/0x2de
> [13046.604928] [<ffffffe0000cdc96>] hrtimer_interrupt+0xcc/0x1d6
> [13046.605236] [<ffffffe0005d3f7c>] riscv_timer_interrupt+0x32/0x3a
> [13046.605580] [<ffffffe0007889ce>] do_IRQ+0xae/0xba
> [13046.605837] [<ffffffe00006bd3c>] ret_from_exception+0x0/0xc
> [13046.606127] [<ffffffe00006ca58>] machine_restart+0xc/0xe
> [13046.606508] rcu: rcu_sched kthread starved for 5252 jiffies! g2837145 f0x2 RCU_GP_WAIT_FQS(5) ->state=0x0 ->cpu=0
> [13046.606990] rcu: RCU grace-period kthread stack dump:
> [13046.607257] rcu_sched       R  running task        0    10      2 0x00000000
> [13046.607610] Call Trace:
> [13046.607774] [<ffffffe000784258>] __schedule+0x1a8/0x482
> [13046.608044] [<ffffffe000784592>] schedule+0x60/0xda
> [13046.608304] [<ffffffe000787a56>] schedule_timeout+0x15c/0x2b2
> [13046.608602] [<ffffffe0000c2ec8>] rcu_gp_kthread+0x4cc/0x7ec
> [13046.608889] [<ffffffe00008b0f2>] kthread+0xf0/0x102
> [13046.609162] [<ffffffe00006bd3c>] ret_from_exception+0x0/0xc
>
> ..... so on getting continuously......
>
>
> Can someone help me out how i can replace my kernel to 5.5.7 since i am not able to find grub or grub2 on my riscv platform?? i have googled for the solution but most of them seems to be x86 specific where they are trying to change the grub??Where i should modify for riscv to get my kernel up????

You won't be able to install a new kernel from the QEMU guest. You
will need to use OpenEmbedded to build a new kernel and boot that.

Alistair

>
>
> Thanks
[EXT]

[-- Attachment #2: Type: text/html, Size: 18151 bytes --]

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

* Re: Replacing existing kernel with new on qemuriscv64
  2020-07-20 18:19   ` Pankaj  Vinadrao Joshi
@ 2020-07-20 18:40     ` Alistair Francis
       [not found]       ` <BMXPR01MB234400F77C27A37B859AFC50EE780@BMXPR01MB2344.INDPRD01.PROD.OUTLOOK.COM>
  0 siblings, 1 reply; 5+ messages in thread
From: Alistair Francis @ 2020-07-20 18:40 UTC (permalink / raw)
  To: Pankaj Vinadrao Joshi; +Cc: qemu-devel

On Mon, Jul 20, 2020 at 11:19 AM Pankaj Vinadrao Joshi
<Pankaj.VJ@exaleapsemi.com> wrote:
>
> Hi Alistair Francis,
>
> Thanks for your response.I have same concern for other riscv hardware with custom kernel will same be applicable for it?If no from where i should change my kernel image since there also i am not able to find grub and the clarification given on web are seems to be very specific to x86 arch where i should look in case of riscv ??

Hello,

I'm not really sure what you are asking.

The way to update the kernel will depend on how you are booting it and
where it is stored. GRUB supports RISC-V, but as there is no UEFI
support in the kernel (yet) it probably isn't the best boot method.
Most hardware will probably use u-boot instead.

Alistair

>
> Thanks
>
> ________________________________
> From: Alistair Francis <alistair23@gmail.com>
> Sent: Monday, July 20, 2020 10:29 PM
> To: Pankaj Vinadrao Joshi <Pankaj.VJ@exaleapsemi.com>
> Cc: qemu-devel@nongnu.org <qemu-devel@nongnu.org>
> Subject: Re: Replacing existing kernel with new on qemuriscv64
>
> On Mon, Jul 20, 2020 at 2:46 AM Pankaj Vinadrao Joshi
> <Pankaj.VJ@exaleapsemi.com> wrote:
> >
> > Hi ,
> > I am trying to replace my existing kernel image which is 5.5.6 to 5.5.7 on qemuriscv64 i would like to mention i have built my qemu image with openembedded-core.
> >
> > i have tried to build the kernel 5.5.7 natively,i was able to build the kernel successfully and in my /boot folder i am able to see vmlinux-5.5.7  but now i want to install this image..i have tried to do it by make install i didnt got any error with it but when i rebooted my system i am getting
> >
> > i have followed the following steps to build kernel
> > $root@qemuriscv64-exaleapsemi-r2:/usr/src/kernel#  make menuconfig arch=riscv64
> > $root@qemuriscv64-exaleapsemi-r2:/usr/src/kernel# make -j4
> > $root@qemuriscv64-exaleapsemi-r2:/usr/src/kernel# make modules_install
> > $root@qemuriscv64-exaleapsemi-r2:/usr/src/kernel# make install
> > sh ./arch/riscv/boot/install.sh 5.5.7 \
> > arch/riscv/boot/Image System.map "/boot"
> > Installing normal kernel
> >
> > $reboot
> > 13024.451157] printk: systemd-shutdow: 37 output lines suppressed due to ratelimiting
> > [13024.527282] systemd-shutdown[1]: Syncing filesystems and block devices.
> > [13024.668538] systemd-shutdown[1]: Sending SIGTERM to remaining processes...
> > [13024.719496] systemd-journald[87]: Received SIGTERM from PID 1 (systemd-shutdow).
> > [13024.769405] systemd-shutdown[1]: Sending SIGKILL to remaining processes...
> > [13024.834318] systemd-shutdown[1]: Unmounting file systems.
> > [13024.868285] [13413]: Remounting '/' read-only in with options '(null)'.
> > [13025.228499] EXT4-fs (vda): re-mounted. Opts: (null)
> > [13025.358123] systemd-shutdown[1]: All filesystems unmounted.
> > [13025.358576] systemd-shutdown[1]: Deactivating swaps.
> > [13025.361264] systemd-shutdown[1]: All swaps deactivated.
> > [13025.361727] systemd-shutdown[1]: Detaching loop devices.
> > [13025.420602] systemd-shutdown[1]: All loop devices detached.
> > [13025.421071] systemd-shutdown[1]: Detaching DM devices.
> > [13025.595237] reboot: Restarting system
> > [13046.599875] rcu: INFO: rcu_sched detected stalls on CPUs/tasks:
> > [13046.600329] (detected by 0, t=5252 jiffies, g=2837145, q=17)
> > [13046.600763] rcu: All QSes seen, last rcu_sched kthread activity 5252 (4298153942-4298148690), jiffies_till_next_fqs=1, root ->qsmask 0x0
> > [13046.601503] systemd-shutdow R  running task        0     1      0 0x00000008
> > [13046.602053] Call Trace:
> > [13046.602562] [<ffffffe00006d3fc>] walk_stackframe+0x0/0xa4
> > [13046.602890] [<ffffffe00006d5e2>] show_stack+0x2a/0x34
> > [13046.603156] [<ffffffe000091094>] sched_show_task+0x158/0x174
> > [13046.603442] [<ffffffe0000c4dde>] rcu_sched_clock_irq+0x6b2/0x6ec
> > [13046.603740] [<ffffffe0000ccadc>] update_process_times+0x1e/0x44
> > [13046.604009] [<ffffffe0000d79dc>] tick_sched_handle.isra.16+0x30/0x3e
> > [13046.604331] [<ffffffe0000d7a38>] tick_sched_timer+0x4e/0x94
> > [13046.604620] [<ffffffe0000cd44a>] __hrtimer_run_queues+0x10c/0x2de
> > [13046.604928] [<ffffffe0000cdc96>] hrtimer_interrupt+0xcc/0x1d6
> > [13046.605236] [<ffffffe0005d3f7c>] riscv_timer_interrupt+0x32/0x3a
> > [13046.605580] [<ffffffe0007889ce>] do_IRQ+0xae/0xba
> > [13046.605837] [<ffffffe00006bd3c>] ret_from_exception+0x0/0xc
> > [13046.606127] [<ffffffe00006ca58>] machine_restart+0xc/0xe
> > [13046.606508] rcu: rcu_sched kthread starved for 5252 jiffies! g2837145 f0x2 RCU_GP_WAIT_FQS(5) ->state=0x0 ->cpu=0
> > [13046.606990] rcu: RCU grace-period kthread stack dump:
> > [13046.607257] rcu_sched       R  running task        0    10      2 0x00000000
> > [13046.607610] Call Trace:
> > [13046.607774] [<ffffffe000784258>] __schedule+0x1a8/0x482
> > [13046.608044] [<ffffffe000784592>] schedule+0x60/0xda
> > [13046.608304] [<ffffffe000787a56>] schedule_timeout+0x15c/0x2b2
> > [13046.608602] [<ffffffe0000c2ec8>] rcu_gp_kthread+0x4cc/0x7ec
> > [13046.608889] [<ffffffe00008b0f2>] kthread+0xf0/0x102
> > [13046.609162] [<ffffffe00006bd3c>] ret_from_exception+0x0/0xc
> >
> > ..... so on getting continuously......
> >
> >
> > Can someone help me out how i can replace my kernel to 5.5.7 since i am not able to find grub or grub2 on my riscv platform?? i have googled for the solution but most of them seems to be x86 specific where they are trying to change the grub??Where i should modify for riscv to get my kernel up????
>
> You won't be able to install a new kernel from the QEMU guest. You
> will need to use OpenEmbedded to build a new kernel and boot that.
>
> Alistair
>
> >
> >
> > Thanks
> [EXT]


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

* Re: Replacing existing kernel with new on qemuriscv64
       [not found]         ` <CAKmqyKPq_oa6-7aVPFxDC8sdEMfR2g3WoY_Anr1TUoJsPdWG-Q@mail.gmail.com>
@ 2020-07-23  9:55           ` Pankaj  Vinadrao Joshi
  0 siblings, 0 replies; 5+ messages in thread
From: Pankaj  Vinadrao Joshi @ 2020-07-23  9:55 UTC (permalink / raw)
  To: Alistair Francis; +Cc: qemu-devel

[-- Attachment #1: Type: text/plain, Size: 8568 bytes --]

Hi,
yes am building it natively for riscv (sifive's u540 hardware ) and in /boot  i am able to find System.map-5.7.2 and vmlinux-5.7.2

root@exaleapsemi:~/linux-stable# make install
make: Warning: File '.vmlinux.cmd' has modification time 1221719 s in the future
make[1]: Warning: File 'arch/riscv/boot/.Image.cmd' has modification time 1221720 s in the future
sh ./arch/riscv/boot/install.sh 5.7.2 \
arch/riscv/boot/Image System.map "/boot"
Installing normal kernel

But now i want to boot with this kernel but i am not able to do so..its booting from the earlier kernel only..i am not able to figure out why this is happening ,while building kernel on x86 with $make install and after reboot i am able to get the new kernel but the same doesnt seems to be working on my hardware.
How i should do that??Kindly suggest.

Thanks
________________________________
From: Alistair Francis <alistair23@gmail.com>
Sent: Thursday, July 23, 2020 6:07 AM
To: Pankaj Vinadrao Joshi <Pankaj.VJ@exaleapsemi.com>
Subject: Re: Replacing existing kernel with new on qemuriscv64

On Mon, Jul 20, 2020 at 10:31 PM Pankaj Vinadrao Joshi
<Pankaj.VJ@exaleapsemi.com> wrote:
>
> Hi,
> i will explain what i mean is, i am using sifive's u540 hardware for which we have built our own custom kernel using openembedded-core lets say 5.5.6 and now i want to build the other kernel lets say 5.7, natively

Natively for which platform? You want to do build a new kernel on the
hardware and then boot into that? The kernel's are kept in a boot
partition, you should just have to copy them to that location.

> and replace the old kernel with new one,and for this i really did not understood where and what exactly i should modify to boot from the new kernel??

Yep, just replace the old one.

>
> The steps what i followed are following
>
> 1) i have cloned the kernel source
> 2)make menuconfig
> 3)make -j4
> 4)make modules_install
> 5make install

make install is probably not going to understand what to do. I think
you will need to manually do this. I can't remember where the
partition is, but it should be easy to find.

Alistair

>
> Hope now its clear what i was trying to ask for??
>
> Thanks & regards
> Pankaj
>
>
>
> ________________________________
> From: Alistair Francis <alistair23@gmail.com>
> Sent: Tuesday, July 21, 2020 12:10 AM
> To: Pankaj Vinadrao Joshi <Pankaj.VJ@exaleapsemi.com>
> Cc: qemu-devel@nongnu.org <qemu-devel@nongnu.org>
> Subject: Re: Replacing existing kernel with new on qemuriscv64
>
> On Mon, Jul 20, 2020 at 11:19 AM Pankaj Vinadrao Joshi
> <Pankaj.VJ@exaleapsemi.com> wrote:
> >
> > Hi Alistair Francis,
> >
> > Thanks for your response.I have same concern for other riscv hardware with custom kernel will same be applicable for it?If no from where i should change my kernel image since there also i am not able to find grub and the clarification given on web are seems to be very specific to x86 arch where i should look in case of riscv ??
>
> Hello,
>
> I'm not really sure what you are asking.
>
> The way to update the kernel will depend on how you are booting it and
> where it is stored. GRUB supports RISC-V, but as there is no UEFI
> support in the kernel (yet) it probably isn't the best boot method.
> Most hardware will probably use u-boot instead.
>
> Alistair
>
> >
> > Thanks
> >
> > ________________________________
> > From: Alistair Francis <alistair23@gmail.com>
> > Sent: Monday, July 20, 2020 10:29 PM
> > To: Pankaj Vinadrao Joshi <Pankaj.VJ@exaleapsemi.com>
> > Cc: qemu-devel@nongnu.org <qemu-devel@nongnu.org>
> > Subject: Re: Replacing existing kernel with new on qemuriscv64
> >
> > On Mon, Jul 20, 2020 at 2:46 AM Pankaj Vinadrao Joshi
> > <Pankaj.VJ@exaleapsemi.com> wrote:
> > >
> > > Hi ,
> > > I am trying to replace my existing kernel image which is 5.5.6 to 5.5.7 on qemuriscv64 i would like to mention i have built my qemu image with openembedded-core.
> > >
> > > i have tried to build the kernel 5.5.7 natively,i was able to build the kernel successfully and in my /boot folder i am able to see vmlinux-5.5.7  but now i want to install this image..i have tried to do it by make install i didnt got any error with it but when i rebooted my system i am getting
> > >
> > > i have followed the following steps to build kernel
> > > $root@qemuriscv64-exaleapsemi-r2:/usr/src/kernel#  make menuconfig arch=riscv64
> > > $root@qemuriscv64-exaleapsemi-r2:/usr/src/kernel# make -j4
> > > $root@qemuriscv64-exaleapsemi-r2:/usr/src/kernel# make modules_install
> > > $root@qemuriscv64-exaleapsemi-r2:/usr/src/kernel# make install
> > > sh ./arch/riscv/boot/install.sh 5.5.7 \
> > > arch/riscv/boot/Image System.map "/boot"
> > > Installing normal kernel
> > >
> > > $reboot
> > > 13024.451157] printk: systemd-shutdow: 37 output lines suppressed due to ratelimiting
> > > [13024.527282] systemd-shutdown[1]: Syncing filesystems and block devices.
> > > [13024.668538] systemd-shutdown[1]: Sending SIGTERM to remaining processes...
> > > [13024.719496] systemd-journald[87]: Received SIGTERM from PID 1 (systemd-shutdow).
> > > [13024.769405] systemd-shutdown[1]: Sending SIGKILL to remaining processes...
> > > [13024.834318] systemd-shutdown[1]: Unmounting file systems.
> > > [13024.868285] [13413]: Remounting '/' read-only in with options '(null)'.
> > > [13025.228499] EXT4-fs (vda): re-mounted. Opts: (null)
> > > [13025.358123] systemd-shutdown[1]: All filesystems unmounted.
> > > [13025.358576] systemd-shutdown[1]: Deactivating swaps.
> > > [13025.361264] systemd-shutdown[1]: All swaps deactivated.
> > > [13025.361727] systemd-shutdown[1]: Detaching loop devices.
> > > [13025.420602] systemd-shutdown[1]: All loop devices detached.
> > > [13025.421071] systemd-shutdown[1]: Detaching DM devices.
> > > [13025.595237] reboot: Restarting system
> > > [13046.599875] rcu: INFO: rcu_sched detected stalls on CPUs/tasks:
> > > [13046.600329] (detected by 0, t=5252 jiffies, g=2837145, q=17)
> > > [13046.600763] rcu: All QSes seen, last rcu_sched kthread activity 5252 (4298153942-4298148690), jiffies_till_next_fqs=1, root ->qsmask 0x0
> > > [13046.601503] systemd-shutdow R  running task        0     1      0 0x00000008
> > > [13046.602053] Call Trace:
> > > [13046.602562] [<ffffffe00006d3fc>] walk_stackframe+0x0/0xa4
> > > [13046.602890] [<ffffffe00006d5e2>] show_stack+0x2a/0x34
> > > [13046.603156] [<ffffffe000091094>] sched_show_task+0x158/0x174
> > > [13046.603442] [<ffffffe0000c4dde>] rcu_sched_clock_irq+0x6b2/0x6ec
> > > [13046.603740] [<ffffffe0000ccadc>] update_process_times+0x1e/0x44
> > > [13046.604009] [<ffffffe0000d79dc>] tick_sched_handle.isra.16+0x30/0x3e
> > > [13046.604331] [<ffffffe0000d7a38>] tick_sched_timer+0x4e/0x94
> > > [13046.604620] [<ffffffe0000cd44a>] __hrtimer_run_queues+0x10c/0x2de
> > > [13046.604928] [<ffffffe0000cdc96>] hrtimer_interrupt+0xcc/0x1d6
> > > [13046.605236] [<ffffffe0005d3f7c>] riscv_timer_interrupt+0x32/0x3a
> > > [13046.605580] [<ffffffe0007889ce>] do_IRQ+0xae/0xba
> > > [13046.605837] [<ffffffe00006bd3c>] ret_from_exception+0x0/0xc
> > > [13046.606127] [<ffffffe00006ca58>] machine_restart+0xc/0xe
> > > [13046.606508] rcu: rcu_sched kthread starved for 5252 jiffies! g2837145 f0x2 RCU_GP_WAIT_FQS(5) ->state=0x0 ->cpu=0
> > > [13046.606990] rcu: RCU grace-period kthread stack dump:
> > > [13046.607257] rcu_sched       R  running task        0    10      2 0x00000000
> > > [13046.607610] Call Trace:
> > > [13046.607774] [<ffffffe000784258>] __schedule+0x1a8/0x482
> > > [13046.608044] [<ffffffe000784592>] schedule+0x60/0xda
> > > [13046.608304] [<ffffffe000787a56>] schedule_timeout+0x15c/0x2b2
> > > [13046.608602] [<ffffffe0000c2ec8>] rcu_gp_kthread+0x4cc/0x7ec
> > > [13046.608889] [<ffffffe00008b0f2>] kthread+0xf0/0x102
> > > [13046.609162] [<ffffffe00006bd3c>] ret_from_exception+0x0/0xc
> > >
> > > ..... so on getting continuously......
> > >
> > >
> > > Can someone help me out how i can replace my kernel to 5.5.7 since i am not able to find grub or grub2 on my riscv platform?? i have googled for the solution but most of them seems to be x86 specific where they are trying to change the grub??Where i should modify for riscv to get my kernel up????
> >
> > You won't be able to install a new kernel from the QEMU guest. You
> > will need to use OpenEmbedded to build a new kernel and boot that.
> >
> > Alistair
> >
> > >
> > >
> > > Thanks
> > [EXT]
> [EXT]
[EXT]

[-- Attachment #2: Type: text/html, Size: 11719 bytes --]

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

end of thread, other threads:[~2020-07-23 10:12 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-07-20  7:45 Replacing existing kernel with new on qemuriscv64 Pankaj  Vinadrao Joshi
2020-07-20 16:59 ` Alistair Francis
2020-07-20 18:19   ` Pankaj  Vinadrao Joshi
2020-07-20 18:40     ` Alistair Francis
     [not found]       ` <BMXPR01MB234400F77C27A37B859AFC50EE780@BMXPR01MB2344.INDPRD01.PROD.OUTLOOK.COM>
     [not found]         ` <CAKmqyKPq_oa6-7aVPFxDC8sdEMfR2g3WoY_Anr1TUoJsPdWG-Q@mail.gmail.com>
2020-07-23  9:55           ` Pankaj  Vinadrao Joshi

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).