cgroup: Fix 64-bit division in cgroup.stat.local
PATCH 1/1 cgroup: Fix 64-bit division in cgroup.stat.local
Fix the following build error for 32-bit systems:
arm-linux-gnueabi-ld: kernel/cgroup/cgroup.o: in function `cgroup_core_local_stat_show':
Quoted 1 line
Quoted 1 line
kernel/cgroup/cgroup.c:3781:(.text+0x28f4): undefined reference to `__aeabi_uldivmod'
arm-linux-gnueabi-ld: (__aeabi_uldivmod): Unknown destination type (ARM/Thumb) in kernel/cgroup/cgroup.o
Quoted 1 line
Quoted 1 line
kernel/cgroup/cgroup.c:3781:(.text+0x28f4): dangerous relocation: unsupported relocation
---
This patch is based on top of tj/cgroup.git:for-6.18
--- kernel/cgroup/cgroup.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
kernel/cgroup/cgroup.c +2 -2
@@ -3778,8 +3778,8 @@ static int cgroup_core_local_stat_show(struct seq_file *seq, void *v) cgrp->freezer.freeze_start_nsec); }while (read_seqcount_retry (&cgrp->freezer.freeze_seq, sequence)); -seq_printf (seq,"frozen_usec %llu\n" , - (unsigned long long ) freeze_time /NSEC_PER_USEC ); +do_div (freeze_time,NSEC_PER_USEC ); +seq_printf (seq,"frozen_usec %llu\n" , freeze_time);return 0 ; }
Signature · 1 line
2.51.0.rc2.233.g662b1ed5c5-goog
Quoted 10 lines · Tiffany Yang
Fix the following build error for 32-bit systems:
arm-linux-gnueabi-ld:kernel/cgroup/cgroup.o: in function `cgroup_core_local_stat_show':Quoted 1 line
Quoted 1 line
kernel/cgroup/cgroup.c:3781:(.text+0x28f4): undefined reference to `__aeabi_uldivmod'
arm-linux-gnueabi-ld: (
__aeabi_uldivmod): Unknown destination type (ARM/Thumb) inkernel/cgroup/cgroup.oQuoted 1 line
Quoted 1 line
kernel/cgroup/cgroup.c:3781:(.text+0x28f4): dangerous relocation: unsupported relocation
Reported-by kernel test robot <[email protected]>Signed-off-by Tiffany Yang <[email protected]>Cc Tejun Heo <[email protected]>
Applied to cgroup/for-6.18.
Thanks.
Signature · 1 line
tejun