LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > slarm64
User Name
Password
slarm64 This forum is for the discussion of slarm64.

Notices


Reply
  Search this Thread
Old 12-31-2021, 10:43 AM   #1
sndwvs
Senior Member
 
Registered: Aug 2014
Posts: 1,861

Rep: Reputation: Disabled
Odroid-C4/HC4 S905X3 (aarch64)


previous discussion Odroid-C4

The Odroid Team has provided a board for testing.
 
Old 01-02-2022, 10:23 PM   #3
sndwvs
Senior Member
 
Registered: Aug 2014
Posts: 1,861

Original Poster
Rep: Reputation: Disabled
fixed work legacy kernel 4.9.295

Code:
U-Boot 2021.10-meson-sm1 (Jan 03 2022 - 04:14:46 +0200) odroid-c4/hc4
Code:
Linux odroid-c4 4.9.295 #1 SMP PREEMPT Fri Dec 31 21:50:18 EET 2021 aarch64 GNU/Linux
slarm64-current-aarch64-server-odroid_c4-4.9.295-build-20220103.img.zst
slarm64-current-aarch64-server-odroid_c4-4.9.295-build-20220103.img.zst.sha256

Last edited by sndwvs; 01-02-2022 at 10:24 PM.
 
Old 01-18-2022, 03:26 PM   #4
ricky_cardo
Member
 
Registered: Feb 2006
Location: Syracuse, NY
Distribution: Slackware64-Current
Posts: 210

Rep: Reputation: 76
Good work on the c4/hc4. I reloaded my hc4 this week and notice I see IRQ errors (irq37). Under the new Kernel
- there is a hang/slowdown for couple minutes then recovers (from ~37sec to 214sec in this sample)

Just wanted to pass this along and I think a fix might be to add irqpoll to extraargs in uEnv.txt (I usually add the fsck options too as the power sometimes blinks.)

cat /boot/uEnv.txt
Code:
verbosity=4
console=both
extraargs=irqpoll fsck.mode=force fsck.repair=yes
ethaddr=00:50:43:84:fb:2f
fdtfile=meson-sm1-odroid-hc4.dtb

This is what I was seeing in dmesg when the odroid-hc4 was sluggish / non responsive

Code:
rcu: INFO: rcu_preempt self-detected stall on CPU
[   84.254659] rcu: 0-....: (14960 ticks this GP) idle=ba1/1/0x4000000000000002 softirq=1735/1735 fqs=6597
[   84.255291] (t=15000 jiffies g=893 q=745)
[   84.255551] Task dump for CPU 0:
[   84.255709] task:kworker/0:1H    state:R  running task     stack:    0 pid: 1180 ppid:     2 flags:0x0000000a
[   84.256381] Workqueue:  0x0 (mmc_complete)
[   84.256913] Call trace:
[   84.257048]  dump_backtrace+0x0/0x1d0
[   84.257488]  show_stack+0x18/0x70
[   84.257871]  sched_show_task+0x14c/0x170
[   84.258173]  dump_cpu_task+0x44/0x54
[   84.258509]  rcu_dump_cpu_stacks+0xe8/0x12c
[   84.258857]  rcu_sched_clock_irq+0xa24/0xd40
[   84.259220]  update_process_times+0x9c/0xec
[   84.259571]  tick_sched_handle+0x34/0x60
[   84.259969]  tick_sched_timer+0x4c/0xa4
[   84.260355]  __hrtimer_run_queues+0x138/0x1e0
[   84.260711]  hrtimer_interrupt+0xe8/0x244
[   84.261064]  arch_timer_handler_phys+0x38/0x50
[   84.261429]  handle_percpu_devid_irq+0x84/0x130
[   84.261751]  handle_domain_irq+0x60/0x90
[   84.262112]  gic_handle_irq+0x4c/0xd0
[   84.262474]  call_on_irq_stack+0x2c/0x54
[   84.262786]  do_interrupt_handler+0x54/0x60
[   84.263122]  el1_interrupt+0x30/0x80
[   84.263486]  el1h_64_irq_handler+0x18/0x24
[   84.263869]  el1h_64_irq+0x78/0x7c
[   84.264149]  finish_task_switch.isra.0+0x9c/0x270
[   84.264450]  __schedule+0x2e4/0x8a0
[   84.264731]  preempt_schedule_irq+0x44/0x130
[   84.265026]  el1_interrupt+0x60/0x80
[   84.265383]  el1h_64_irq_handler+0x18/0x24
[   84.265760]  el1h_64_irq+0x78/0x7c
[   84.266034]  schedule+0x60/0x104
[   84.266305]  worker_thread+0x1a8/0x470
[   84.266627]  kthread+0x150/0x160
[   84.266896]  ret_from_fork+0x10/0x20
[  213.542830] irq 37: nobody cared (try booting with the "irqpoll" option)
[  213.543163] CPU: 0 PID: 1781 Comm: irq/37-0.0:00 Tainted: G         C        5.15.12 #1
[  213.543572] Hardware name: Hardkernel ODROID-HC4 (DT)
[  213.543759] Call trace:
[  213.543892]  dump_backtrace+0x0/0x1d0
[  213.544362]  show_stack+0x18/0x70
[  213.544745]  dump_stack_lvl+0x68/0x84
[  213.545149]  dump_stack+0x18/0x34
[  213.545517]  __report_bad_irq+0x4c/0xdc
[  213.545857]  note_interrupt+0x32c/0x3ec
[  213.546255]  handle_irq_event+0xd0/0x140
[  213.546615]  handle_fasteoi_irq+0xa4/0x1f4
[  213.546916]  handle_domain_irq+0x60/0x90
[  213.547264]  gic_handle_irq+0x4c/0xd0
[  213.547621]  call_on_irq_stack+0x2c/0x54
[  213.547929]  do_interrupt_handler+0x54/0x60
[  213.548263]  el1_interrupt+0x30/0x80
[  213.548623]  el1h_64_irq_handler+0x18/0x24
[  213.549000]  el1h_64_irq+0x78/0x7c
[  213.549272]  _raw_spin_unlock_irq+0x14/0x50
[  213.549611]  irq_thread_fn+0x60/0x9c
[  213.549969]  irq_thread+0x158/0x290
[  213.550322]  kthread+0x150/0x160
[  213.550588]  ret_from_fork+0x10/0x20
[  213.550894] handlers:
[  213.551011] [<0000000029cf190a>] irq_default_primary_handler threaded [<0000000017490907>] phy_interrupt
[  213.551771] Disabling IRQ #37

UPDATE
irqpoll - no help

Last edited by ricky_cardo; 01-18-2022 at 05:50 PM. Reason: more complete capture
 
Old 01-18-2022, 03:35 PM   #5
sndwvs
Senior Member
 
Registered: Aug 2014
Posts: 1,861

Original Poster
Rep: Reputation: Disabled
Thanks for the info, I'll take a look at Odroid-C4.
 
1 members found this post helpful.
Old 01-18-2022, 08:50 PM   #6
ricky_cardo
Member
 
Registered: Feb 2006
Location: Syracuse, NY
Distribution: Slackware64-Current
Posts: 210

Rep: Reputation: 76
Seems a ok under 4.9.295 so it does not seem to be hardware related.
- reproducible for me under 5.15.12 (and IRQ 37 is Ethernet 10/100/1000) if that is helpful...

I'm testing on the hc4 btw
 
Old 01-19-2022, 10:20 AM   #7
sndwvs
Senior Member
 
Registered: Aug 2014
Posts: 1,861

Original Poster
Rep: Reputation: Disabled
Thanks, it's helpful.
 
Old 01-19-2022, 03:37 PM   #8
ricky_cardo
Member
 
Registered: Feb 2006
Location: Syracuse, NY
Distribution: Slackware64-Current
Posts: 210

Rep: Reputation: 76
less important but also noticeable, under the newer kernel (init 6; reboot; shutdown -r 1) all yield power down without restarting,
- I spun up (slarm64-current-aarch64-base-odroid_c4-5.10.5-build-20210107.img.zst)
-sata is recognized (hc4 model) ((seems to not see sata natively on 4.9.295))
-reboot works

Last edited by ricky_cardo; 01-19-2022 at 08:47 PM. Reason: -
 
Old 01-25-2022, 06:45 PM   #10
ricky_cardo
Member
 
Registered: Feb 2006
Location: Syracuse, NY
Distribution: Slackware64-Current
Posts: 210

Rep: Reputation: 76
Kernel slowdown / hangs seem fixed, but dmesg still complaining about IRQ#37 on the "hc4"
SATA - working well
- reboot seems to need physical unplug/replug

(which is to say:
init 6
reboot
shutdown -r 1

all leave the hc4 in a frozen (but seemly stopped) state that needs a unplug/replug.

dmesg:
Code:
[   60.425074] irq 37: nobody cared (try booting with the "irqpoll" option)
[   60.425090] CPU: 0 PID: 1786 Comm: irq/37-0.0:00 Tainted: G         C        5.16.2 #1
[   60.425096] Hardware name: Hardkernel ODROID-HC4 (DT)
[   60.425100] Call trace:
[   60.425102]  dump_backtrace+0x0/0x1d0
[   60.425115]  show_stack+0x18/0x70
[   60.425120]  dump_stack_lvl+0x68/0x84
[   60.425127]  dump_stack+0x18/0x34
[   60.425131]  __report_bad_irq+0x4c/0xdc
[   60.425139]  note_interrupt+0x32c/0x3ec
[   60.425145]  handle_irq_event+0xd0/0x140
[   60.425151]  handle_fasteoi_irq+0xa4/0x1f4
[   60.425155]  generic_handle_domain_irq+0x3c/0x60
[   60.425160]  gic_handle_irq+0x44/0xc4
[   60.425165]  call_on_irq_stack+0x2c/0x54
[   60.425169]  do_interrupt_handler+0x80/0x94
[   60.425174]  el1_interrupt+0x34/0x84
[   60.425178]  el1h_64_irq_handler+0x18/0x24
[   60.425183]  el1h_64_irq+0x78/0x7c
[   60.425186]  wake_threads_waitq+0x0/0x60
[   60.425191]  kthread+0x178/0x184
[   60.425196]  ret_from_fork+0x10/0x20
[   60.425200] handlers:
[   60.425202] [<00000000c2ce8197>] irq_default_primary_handler threaded [<00000000b8e3c45e>] phy_interrupt
[   60.425218] Disabling IRQ #37

So far this version still seems to behave the best:
Code:
slarm64-current-aarch64-base-odroid_c4-5.10.5-build-20210107.img.zst
Could not find any issue...

Last edited by ricky_cardo; 01-25-2022 at 06:46 PM.
 
Old 02-11-2022, 01:46 PM   #11
akschu
Member
 
Registered: Dec 2007
Posts: 96

Rep: Reputation: 39
I'm also using two different HC4s here is my feedback:

5.15.12 from -current seems to work fine, but you have to give it a minute for it to disable IRQ 37 as I'm also seeing the

Code:
[   60.425074] irq 37: nobody cared (try booting with the "irqpoll" option)
error. My system reports that irq 37 is:

Code:
meson-gpio-irqchip  26 Level     0.0:00
When booted with irqpoll, my system burns a bit of CPU polling the IRQ as the load average hovers around 1

Code:
# cat /proc/interrupts
           CPU0       CPU1       CPU2       CPU3
 37:   87817875          0          0          0  meson-gpio-irqchip  26 Level     0.0:00
When I go back to default then the load average drops and everything seems fine after the irq is disabled.

I went ahead and loaded up 5.16.2 and it appears to act exactly the same, it's slow until the IRQ is disabled, then seems to work okay.

schu
 
Old 02-11-2022, 07:22 PM   #12
sndwvs
Senior Member
 
Registered: Aug 2014
Posts: 1,861

Original Poster
Rep: Reputation: Disabled
here is a similar problem, but the interrupt is different.
 
Old 02-17-2022, 11:49 AM   #13
akschu
Member
 
Registered: Dec 2007
Posts: 96

Rep: Reputation: 39
Quote:
Originally Posted by sndwvs View Post
here is a similar problem, but the interrupt is different.
Thanks for that. I rebuilt 5.16.2 from your source package with that patch and I no longer see the IRQ issue and the machine runs nicely. Can you add that to your list of patches for building the next kernels?

Also, I updated the mirrors.aptalaska.net to have the slarm64-15.0 build. It's what I can do to help.
 
Old 02-17-2022, 12:33 PM   #14
akschu
Member
 
Registered: Dec 2007
Posts: 96

Rep: Reputation: 39
Quote:
Originally Posted by akschu View Post
Thanks for that. I rebuilt 5.16.2 from your source package with that patch and I no longer see the IRQ issue and the machine runs nicely. Can you add that to your list of patches for building the next kernels?
I spoke too soon. The patch causes the kernel to run well and not disable the IRQ, but it no longer allows me to reboot the machine without power cycle.

Disabling the IRQ is less of a problem for me than not being able to remotely reboot.
 
Old 02-17-2022, 12:44 PM   #15
sndwvs
Senior Member
 
Registered: Aug 2014
Posts: 1,861

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by akschu View Post
Thanks for that. I rebuilt 5.16.2 from your source package with that patch and I no longer see the IRQ issue and the machine runs nicely. Can you add that to your list of patches for building the next kernels?

Also, I updated the mirrors.aptalaska.net to have the slarm64-15.0 build. It's what I can do to help.
Hi Akschu,
thanks for testing and maintaining the repository. added patch.
 
  


Reply

Tags
amlogic, odroid, s905x3, slackware, slarm64


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Odroid-C4 S905X3 (aarch64) sndwvs Slackware - ARM 6 12-07-2021 10:26 AM
LXer: Odroid-HC4 toaster NAS runs dual PCIe-driven SATA drives LXer Syndicated Linux News 0 10-21-2020 04:12 AM
LXer: Odroid-C4 could be the Odroid you're looking for LXer Syndicated Linux News 0 04-24-2020 01:33 AM
Run Debian and Android on ODROID-C1/ODROID-C2 Vasant1234 Linux - Embedded & Single-board computer 0 05-09-2017 10:45 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > slarm64

All times are GMT -5. The time now is 01:55 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration