27;struct percpu_rw_semaphore'
> | 1422 | struct percpu_rw_semaphore rw_sem[SB_FREEZE_LEVELS];
>
> once rcuwait.h includes linux/sched/signal.h.
>
> Remove the linux/mm.h include.
>
> Cc: Guo Ren
> Cc: linux-c...@vger.kernel.org
> Reported-by: kbuild test robot
&g
On Sat, Mar 21, 2020 at 8:08 PM Thomas Gleixner wrote:
>
> Guo Ren writes:
>
> > Tested and Acked by me.
> >
> > Queued for next pull request, thx
>
> Can we please route that with the rcuwait changes to avoid breakage
> unless you ship it to Linus right away?
Ok, I won't queue it.
@@ -88,7 +88,7 @@ void free_initmem(void)
> ClearPageReserved(virt_to_page(addr));
> init_page_count(virt_to_page(addr));
> free_page(addr);
> - totalram_pages++;
> + atomic_long_inc(&totalram_pages);
> addr += PAGE_SIZE;
> }
For csky part, it's OK.
Guo Ren
__func__, PAGE_SIZE,
> + PAGE_SIZE);
> +
> set_pmd(pmd, __pmd(__pa(pte)));
> BUG_ON(pte != pte_offset_kernel(pmd,
> 0));
> }
Looks good for me and panic is ok.
Reviewed-by: Guo Ren
csky:
Acked-by: Guo Ren
On Mon, Feb 17, 2020 at 1:04 PM Anshuman Khandual
wrote:
>
> Lets move vma_is_accessible() helper to include/linux/mm.h which makes it
> available for general use. While here, this replaces all remaining open
> encodings for VMA access check with vma_i
_static arch_jump_label_transform_static
> +
> #endif /* __ASSEMBLY__ */
> #endif /* __ASM_CSKY_JUMP_LABEL_H */
> --
> 2.39.2
>
>
Thank you!
Reviewed-by: Guo Ren
--
Best Regards
Guo Ren
Acked-by: Guo Ren
On Wed, Sep 6, 2023 at 6:04 PM Joel Granados via B4 Relay
wrote:
>
> From: Joel Granados
>
> This commit comes at the tail end of a greater effort to remove the
> empty elements at the end of the ctl_table arrays (sentinels) which
> will reduce the overall
ock_size);
> break;
> default:
> break;
> --
> 2.39.2
>
--
Best Regards
Guo Ren
On Fri, May 5, 2023 at 9:19 PM Arnd Bergmann wrote:
>
> On Fri, May 5, 2023, at 07:47, Guo Ren wrote:
> > On Mon, Mar 27, 2023 at 8:15 PM Arnd Bergmann wrote:
>
> >>
> >> riscv also invalidates the caches before the transfer, which does
> >> not appe
k.h
> b/arch/csky/include/asm/irq_work.h
> index 33aaf39d6f94..d39fcc1f5395 100644
> --- a/arch/csky/include/asm/irq_work.h
> +++ b/arch/csky/include/asm/irq_work.h
> @@ -7,5 +7,5 @@ static inline bool arch_irq_work_has_interrupt(void)
> {
> return true;
> }
> -
Acked-by: Guo Ren
On Thu, Jun 1, 2023 at 5:34 AM Vishal Moola (Oracle)
wrote:
>
> Part of the conversions to replace pgtable constructor/destructors with
> ptdesc equivalents.
>
> Signed-off-by: Vishal Moola (Oracle)
> ---
> arch/csky/include/asm/pgalloc.h | 4 ++--
For csky part
Acked-by: Guo Ren
On Fri, Aug 19, 2022 at 9:39 AM Kefeng Wang wrote:
>
> Only x86 has own release_thread(), introduce a new weak
> release_thread() function to clean empty definitions in
> other ARCHs.
>
> Signed-off-by: Kefeng Wang
> ---
> arch/alpha
id noinstr arch_cpu_idle(void)
> * tricks
> */
> cpu_do_idle();
> - raw_local_irq_enable();
> }
> --- a/arch/csky/kernel/process.c
> +++ b/arch/csky/kernel/process.c
> @@ -100,6 +100,5 @@ void arch_cpu_idle(void)
> #ifdef CONFIG_CPU_PM_STO
Reviewed-by: Guo Ren
On Mon, Sep 19, 2022 at 6:17 PM Peter Zijlstra wrote:
>
> Doing RCU-idle outside the driver, only to then temporarily enable it
> again, at least twice, before going idle is daft.
>
> Signed-off-by: Peter Zijlstra (Intel)
> ---
> drivers/cpuidle/
sky/kernel/smp.c
> index 4b605aa2e1d6..fd7f81be16dd 100644
> --- a/arch/csky/kernel/smp.c
> +++ b/arch/csky/kernel/smp.c
> @@ -140,7 +140,7 @@ void smp_send_stop(void)
> on_each_cpu(ipi_stop, NULL, 1);
> }
>
> -void smp_send_reschedule(int cpu)
> +void arch_
_addr_valid(), which almost does what we need.
> + * not-valid. Walk the page table and check the PTE_VALID bit.
> *
> * Because this is only called on the kernel linear map, p?d_sect() implies
> * p?d_present(). When debug_pagealloc is enabled, sections mappings ar
> -#include
> -
> extern unsigned long __stack_chk_guard;
>
> /*
> @@ -15,12 +12,7 @@ extern unsigned long __stack_chk_guard;
> */
> static __always_inline void boot_init_stack_canary(void)
> {
> - unsigned long canary;
> -
> - /* Try to get a semi
RF_EVENTS
> select HAVE_PERF_REGS
> select HAVE_PERF_USER_STACK_DUMP
> diff --git a/arch/csky/include/asm/page.h b/arch/csky/include/asm/page.h
> index 4a0502e324a6..f70f37402d75 100644
> --- a/arch/csky/include/asm/page.h
> +++ b/arch/csky/include/asm/page.h
> @@
>
> #define virt_addr_valid(kaddr) ((void *)(kaddr) >= (void *)PAGE_OFFSET && \
> (void *)(kaddr) < high_memory)
> -#define pfn_valid(pfn) ((pfn) >= ARCH_PFN_OFFSET && ((pfn) -
> ARCH_PFN_OFFSET) < max_mapnr)
For csky part:
_report_idle_dead();
arch_cpu_idle_dead();
+ BUG();
}
arch_cpu_idle_enter();
> }
> #endif
> --
> 2.39.0
>
--
Best Regards
Guo Ren
On Sat, Feb 4, 2023 at 10:29 AM Josh Poimboeuf wrote:
>
> On Sat, Feb 04, 2023 at 09:12:31AM +0800, Guo Ren wrote:
> > On Sat, Feb 4, 2023 at 6:05 AM Josh Poimboeuf wrote:
> > >
> > > arch_cpu_idle_dead() doesn't return. Make that more explicit with
cache_op(paddr, size, dma_wb_range);
> - break;
> case DMA_FROM_DEVICE:
> case DMA_BIDIRECTIONAL:
> - cache_op(paddr, size, dma_wbinv_range);
> + cache_op(paddr, size, dma_wb_range);
Reviewed-by: Guo Ren
> break;
> default:
> BUG();
> --
> 2.39.2
>
--
Best Regards
Guo Ren
d kprobe_ftrace_handler(unsigned long ip, unsigned long
> parent_ip,
> struct kprobe_ctlblk *kcb;
> struct pt_regs *regs;
>
> + if (unlikely(kprobe_ftrace_disabled))
> + return;
> +
For csky part.
Acked-by: Guo Ren
> bit = ftrace_test_recu
Acked-by: Guo Ren
On Sat, Sep 19, 2020 at 5:50 PM Thomas Gleixner wrote:
>
> Signed-off-by: Thomas Gleixner
> Cc: Guo Ren
> Cc: linux-c...@vger.kernel.org
> ---
> Note: Completely untested
> ---
> arch/csky/Kconfig |1
> arch/csky/include/asm/
On Sun, Mar 28, 2021 at 7:14 PM Christophe Leroy
wrote:
>
>
>
> Le 28/03/2021 à 08:30, guo...@kernel.org a écrit :
> > From: Guo Ren
> >
> > We don't have native hw xchg16 instruction, so let qspinlock
> > generic code to deal with it.
>
> We ha
On Wed, Mar 31, 2021 at 10:32 PM wrote:
>
> From: Guo Ren
>
> This patch introduces a ticket lock implementation for riscv, along the
> same lines as the implementation for arch/arm & arch/csky.
>
> We still use qspinlock as default.
>
> Signed-off-by: Guo Ren
&
On Wed, Feb 23, 2022 at 9:42 AM Palmer Dabbelt wrote:
>
> On Tue, 01 Feb 2022 07:05:33 PST (-0800), guo...@kernel.org wrote:
> > From: Guo Ren
> >
> > Implement riscv asm/compat.h for struct compat_xxx,
> > is_compat_task, compat_user_regset, regset convert.
On Wed, Feb 23, 2022 at 9:42 AM Palmer Dabbelt wrote:
>
> On Tue, 01 Feb 2022 07:05:37 PST (-0800), guo...@kernel.org wrote:
> > From: Guo Ren
> >
> > If the current task is in COMPAT mode, set SR_UXL_32 in status for
> > returning userspace. We need CONFI
On Wed, Feb 23, 2022 at 9:42 AM Palmer Dabbelt wrote:
>
> On Tue, 01 Feb 2022 07:05:40 PST (-0800), guo...@kernel.org wrote:
> > From: Guo Ren
> >
> > There is no vgettimeofday supported in rv32 that makes simple to
> > generate rv32 vdso code which only
On Wed, Feb 23, 2022 at 9:42 AM Palmer Dabbelt wrote:
>
> On Tue, 01 Feb 2022 07:05:41 PST (-0800), guo...@kernel.org wrote:
> > From: Guo Ren
> >
> > Reconstruct __setup_additional_pages() by appending vdso info
> > pointer argument to meet compat_vds
Fon +49 551 30664-0, Fax +49 551 30664-11
> Gothaer Platz 3, 37083 Göttingen, Germany
> Sitz der Gesellschaft: Göttingen, Amtsgericht Göttingen HR B 3160
> Geschäftsführung: Heike Jordan, Dr. Uwe Kracke – Ust-IdNr.: DE 205 198 055
>
> emlix - smart embedded open source
--
Best Regards
Guo Ren
ML: https://lore.kernel.org/linux-csky/
On Wed, Feb 23, 2022 at 9:42 AM Palmer Dabbelt wrote:
>
> On Tue, 01 Feb 2022 07:05:41 PST (-0800), guo...@kernel.org wrote:
> > From: Guo Ren
> >
> > Reconstruct __setup_additional_pages() by appending vdso info
> > pointer argument to meet compat_vds
On Thu, Feb 24, 2022 at 5:38 PM Arnd Bergmann wrote:
>
> On Thu, Feb 24, 2022 at 9:54 AM wrote:
> >
> > From: Guo Ren
> >
> > Implement compat sys_call_table and some system call functions:
> > truncate64, ftruncate64, fallocate, pread64, pwrite64,
> >
On Fri, Feb 25, 2022 at 1:57 AM Palmer Dabbelt wrote:
>
> On Thu, 24 Feb 2022 00:54:07 PST (-0800), guo...@kernel.org wrote:
> > From: Guo Ren
> >
> > Reconstruct __setup_additional_pages() by appending vdso info
> > pointer argument to meet compat_vds
e/guoren/source/kernel/riscv-linux/arch/riscv/kernel/compat_vdso/gen_compat_vdso_offsets.sh
| LC_ALL=C sort > include/generated/compat_vdso-offsets.h
On Thu, Feb 24, 2022 at 6:13 PM Arnd Bergmann wrote:
>
> On Thu, Feb 24, 2022 at 9:54 AM wrote:
> >
> > From: Guo Ren
> &
On Fri, Feb 25, 2022 at 11:50 PM Arnd Bergmann wrote:
>
> On Fri, Feb 25, 2022 at 4:42 PM Guo Ren wrote:
> >
> > Hi Arnd & Palmer,
> >
> > Here is the new modified compat_vdso/Makefile, please have a look,
>
;
So how do you think compat_loff_t could be defined with __aligned__(4)?
> marking the structure packed isn't needed.
> I believe compat_u64 and compat_s64 both have aligned(4).
> It is also wrong, consider:
>
> struct foo {
> char x;
> struct compat_flock64 fl64;
> };
>
> There should be 3 bytes of padding after 'x'.
> But you've removed it.
>
> David
>
> -
> Registered Address Lakeside, Bramley Road, Mount Farm, Milton Keynes, MK1
> 1PT, UK
> Registration No: 1397386 (Wales)
>
--
Best Regards
Guo Ren
ML: https://lore.kernel.org/linux-csky/
On Mon, Feb 28, 2022 at 8:02 PM David Laight wrote:
>
> From: Guo Ren
> > Sent: 28 February 2022 11:52
> >
> > On Mon, Feb 28, 2022 at 2:40 PM David Laight
> > wrote:
> > >
> > > From: guo...@kernel.org
> > > > Sent: 27
Acked-by: Guo Ren
On Mon, Feb 28, 2022 at 7:10 PM Anshuman Khandual
wrote:
>
> This defines and exports a platform specific custom vm_get_page_prot() via
> subscribing ARCH_HAS_VM_GET_PAGE_PROT. Subsequently all __SXXX and __PXXX
> macros can be dropped which are no longer needed.
&
hine == EM_RISCV &&
+ hdr->e_ident[EI_CLASS] == ELFCLASS32;
}
static int __init compat_mode_detect(void)
On Mon, Feb 28, 2022 at 12:30 AM wrote:
>
> From: Guo Ren
>
> Implement necessary type and macro for compat elf. See the code
> comment for detail.
Hi Arnd,
On Mon, Feb 28, 2022 at 12:30 AM wrote:
>
> From: Guo Ren
>
> If the current task is in COMPAT mode, set SR_UXL_32 in status for
> returning userspace. We need CONFIG _COMPAT to prevent compiling
> errors with rv32 defconfig.
>
> Signed-off-by: Guo Ren
> S
On Fri, Mar 11, 2022 at 9:38 PM Ben Dooks wrote:
>
> On 11/03/2022 02:38, Guo Ren wrote:
> > Hi Arnd,
> >
> > On Mon, Feb 28, 2022 at 12:30 AM wrote:
> >>
> >> From: Guo Ren
> >>
> >> If the current task is in COMPAT mode, set SR_U
On Sat, Mar 12, 2022 at 4:36 PM Arnd Bergmann wrote:
>
> On Sat, Mar 12, 2022 at 3:13 AM Guo Ren wrote:
> > On Fri, Mar 11, 2022 at 9:38 PM Ben Dooks wrote:
> > > On 11/03/2022 02:38, Guo Ren wrote:
> > > >> --- a/arch/riscv/kernel/process.c
> &
16
#ifndef __ASSEMBLY__
On Wed, Mar 16, 2022 at 3:04 PM wrote:
>
> From: Guo Ren
>
> Make TASK_SIZE from const to dynamic detect TIF_32BIT flag
> function. Refer to arm64 to implement DEFAULT_MAP_WINDOW_64 for
> efi-stub.
>
> Limit 32-bit compatible process
Hi Palmer & Arnd,
Fixup fadvise64_64 arguments problem.
On Tue, Mar 22, 2022 at 10:41 PM wrote:
>
> From: Guo Ren
>
> Implement compat sys_call_table and some system call functions:
> truncate64, ftruncate64, fallocate, pread64, pwrite64,
> sync_file_range, readahead, f
On Wed, Mar 23, 2022 at 5:00 AM Palmer Dabbelt wrote:
>
> On Tue, 22 Mar 2022 07:39:43 PDT (-0700), guo...@kernel.org wrote:
> > From: Guo Ren
> >
> > Currently, most 64-bit architectures (x86, parisc, powerpc, arm64,
> > s390, mips, sparc) have supported
'/home/guoren/source/kernel/build-arm64'
On Sat, Apr 2, 2022 at 8:53 PM Guo Ren wrote:
>
> On Wed, Mar 23, 2022 at 5:00 AM Palmer Dabbelt wrote:
> >
> > On Tue, 22 Mar 2022 07:39:43 PDT (-0700), guo...@kernel.org wrote:
> > > From: Guo Ren
> > >
&
On Sat, Apr 2, 2022 at 9:39 PM Masahiro Yamada wrote:
>
> On Sat, Apr 2, 2022 at 10:36 PM wrote:
> >
> > From: Guo Ren
> >
> > The existing per-arch definitions are pretty much historic cruft.
> > Move SYSVIPC_COMPAT into init/Kconfig.
> >
> > Si
quest for COMPAT, thank you very much.
On Sat, Apr 2, 2022 at 9:53 PM wrote:
>
> From: Guo Ren
>
> Currently, most 64-bit architectures (x86, parisc, powerpc, arm64,
> s390, mips, sparc) have supported COMPAT mode. But they all have
> history issues and can't use standard
On Sat, Apr 2, 2022 at 10:04 PM Guo Ren wrote:
>
> Hi Palmer,
>
> Sorry for the late reply, I still want COMPAT to catch up at 5.18..
> I've pushed it into my next branch, and it would get in linux-next the
> next day. You could have a look at that. The repo is:
> htt
Hi Palmer,
On Tue, Apr 5, 2022 at 7:06 AM Palmer Dabbelt wrote:
>
> On Mon, 04 Apr 2022 07:28:50 PDT (-0700), guo...@kernel.org wrote:
> > On Sat, Apr 2, 2022 at 10:04 PM Guo Ren wrote:
> >>
> >> Hi Palmer,
> >>
> >> Sorry for the late reply, I s
r taking care of compat patch series.
On Tue, Apr 5, 2022 at 3:13 PM wrote:
>
> From: Guo Ren
>
> Currently, most 64-bit architectures (x86, parisc, powerpc, arm64,
> s390, mips, sparc) have supported COMPAT mode. But they all have
> history issues and can't use standard li
g clean through all the
> autobuilders before making it look good, I think it didn't fail this
> time so I'll do a bit more refactoring. Shouldn't be too much longer at
> this point.
Cool, thank you. Hope it could be in v5.19.
>
> >
> >
> > On Tue, Ap
On Fri, May 20, 2022 at 1:50 AM Palmer Dabbelt wrote:
>
> On Tue, 05 Apr 2022 00:12:54 PDT (-0700), guo...@kernel.org wrote:
> > From: Guo Ren
> >
> > Currently, most 64-bit architectures (x86, parisc, powerpc, arm64,
> > s390, mips, sparc) have supported
On Wed, Mar 31, 2021 at 10:32 PM wrote:
>
> From: Guo Ren
>
> - Using smp_cond_load_acquire in arch_spin_lock by Peter's
>advice.
> - Using __smp_acquire_fence in arch_spin_trylock
> - Using smp_store_release in arch_spin_unlock
>
> All above are just cod
On Wed, Mar 31, 2021 at 10:32 PM wrote:
>
> From: Guo Ren
>
> This patch introduces a ticket lock implementation for riscv, along the
> same lines as the implementation for arch/arm & arch/csky.
>
> We still use qspinlock as default.
>
> Signed-off-by: Guo Ren
&
On Mon, Apr 12, 2021 at 12:02 AM Guo Ren wrote:
>
> On Wed, Mar 31, 2021 at 10:32 PM wrote:
> >
> > From: Guo Ren
> >
> > This patch introduces a ticket lock implementation for riscv, along the
> > same lines as the implementation for arch/arm & arch
Only for this patch, Acked-by: Guo Ren
On Thu, Oct 28, 2021 at 5:18 AM Dmitry Osipenko wrote:
>
> Kernel now supports chained power-off handlers. Use do_kernel_power_off()
> that invokes chained power-off handlers. It also invokes legacy
> pm_power_off() for now, which will be remo
Hi Mike,
Acked-by: Guo Ren
On Thu, May 02, 2019 at 06:28:32PM +0300, Mike Rapoport wrote:
> The csky implementation pte_alloc_one(), pte_free_kernel() and pte_free()
> is identical to the generic except of lack of __GFP_ACCOUNT for the user
> PTEs allocation.
>
> Switch csky
On Sat, May 04, 2019 at 12:03:48AM +0800, Guo Ren wrote:
> Hi Mike,
>
> Acked-by: Guo Ren
>
> On Thu, May 02, 2019 at 06:28:32PM +0300, Mike Rapoport wrote:
> > The csky implementation pte_alloc_one(), pte_free_kernel() and pte_free()
> > is identical to th
On Wed, Dec 22, 2021 at 2:43 AM Christophe Leroy
wrote:
>
>
>
> Le 21/12/2021 à 18:00, guo...@kernel.org a écrit :
> > From: Guo Ren
> >
> > This macro isn't used in Linux sched, now. Delete in
> > include/linux/sched.h and arch's include/asm.
>
Got it. Thx
On Wed, Dec 22, 2021 at 3:27 PM Christophe Leroy
wrote:
>
>
>
> Le 22/12/2021 à 04:02, Guo Ren a écrit :
> > On Wed, Dec 22, 2021 at 2:43 AM Christophe Leroy
> > wrote:
> >>
> >>
> >>
> >> Le 21/12/2021 à 18:00, guo...@kern
On Sun, Dec 26, 2021 at 12:26 AM Heiko Carstens wrote:
>
> On Sat, Dec 25, 2021 at 12:54:27PM +0800, guo...@kernel.org wrote:
> > From: Guo Ren
> >
> > This macro isn't used in Linux sched, now. Delete in
> > include/linux/sched.h and arch's inc
On Mon, Jan 10, 2022 at 10:29 PM Arnd Bergmann wrote:
>
> On Tue, Dec 28, 2021 at 3:39 PM wrote:
> >
> > From: Guo Ren
> >
> > Implement necessary type and macro for compat elf. See the code
> > comment for detail.
> >
> > Signed-off-by: G
On Mon, Jan 10, 2022 at 9:35 PM Arnd Bergmann wrote:
>
> On Tue, Dec 28, 2021 at 3:39 PM wrote:
> >
> > From: Guo Ren
> >
> > Remove duplicate F_GETLK64,F_SETLK64,F_SETLKW64 definitions in
> > arch/*/include/asm/compat.h.
> >
> > Signed-off-by: G
gt;
> This is probably what we want here for compatibility reasons, but I think
> it should be explained in the changelog text, and I'd like Jeff or Bruce
> to comment on it as well: the alternative here would be to make the
> uapi definition depend on __BITS_PER_LONG==32, which is
__BITS_PER_LONG==32 || __KERNEL__ just for kernel use in compat.
> technically the right thing to do but more a of a change.
>
>Arnd
--
Best Regards
Guo Ren
ML: https://lore.kernel.org/linux-csky/
s another topic, let's give the initial compat
for 2GB support to riscv.
>
> David
>
> -
> Registered Address Lakeside, Bramley Road, Mount Farm, Milton Keynes, MK1
> 1PT, UK
> Registration No: 1397386 (Wales)
--
Best Regards
Guo Ren
ML: https://lore.kernel.org/linux-csky/
On Thu, Jan 20, 2022 at 9:33 PM Arnd Bergmann wrote:
>
> On Thu, Jan 20, 2022 at 8:39 AM wrote:
> > From: Guo Ren
> >
> > Implement necessary type and macro for compat elf. See the code
> > comment for detail.
> >
> > Signed-off-b
that #ifdef, as the is_compat_task() definition is
> meant to drop the code at compile time, unless the SR_UXL_32
> definition is not visible here.
I almost put CONFIG_COMPAT in every compat related code, because I
hope the next arch that wants to support COMPAT could easily find
where to be
t;
> The names clash with the custom versions defined for powerpc and sparc,
> but the duplicates look compatible if you can account for the padded
> argument and the lo/hi order of the pairs, so could just be removed here
> (all other architectures use custom function names instead).
I would try it later.
>
> Arnd
>
> [1] https://riscv.org/wp-content/uploads/2015/01/riscv-calling.pdf
--
Best Regards
Guo Ren
ML: https://lore.kernel.org/linux-csky/
On Thu, Jan 20, 2022 at 6:32 PM Arnd Bergmann wrote:
>
> On Thu, Jan 20, 2022 at 8:39 AM wrote:
> >
> > From: Guo Ren
> >
> > Current riscv doesn't support the 32bit KVM/arm API. Let's make it
> > clear by not selecting KVM_COMPAT.
> >
>
remove those two lines. The rest looks good to
> me.
Yes, you are right. compat_mode_t should be unsigned int.
>
>Arnd
--
Best Regards
Guo Ren
ML: https://lore.kernel.org/linux-csky/
On Thu, Jan 20, 2022 at 6:31 PM Arnd Bergmann wrote:
>
> On Thu, Jan 20, 2022 at 8:39 AM wrote:
> >
> > From: Guo Ren
> >
> > Implement compat_setup_rt_frame for sigcontext save & restore. The
> > main process is the same with signal, but the rv32 pt_reg
On Fri, Jan 21, 2022 at 4:57 PM Arnd Bergmann wrote:
>
> On Fri, Jan 21, 2022 at 7:25 AM Guo Ren wrote:
> > On Thu, Jan 20, 2022 at 10:43 PM Arnd Bergmann wrote:
> > > On Thu, Jan 20, 2022 at 8:39 AM wrote:
>
> > > Are you sure these are the right calling conve
On Thu, Jan 20, 2022 at 9:02 PM Arnd Bergmann wrote:
>
> On Thu, Jan 20, 2022 at 8:38 AM wrote:
> >
> > From: Guo Ren
> >
> > There are 7 64bit architectures that support Linux COMPAT mode to
> > run 32bit applications. A lot of definitions
tch the
> native (~0UL) definition.
Yes, native rv32 used ~0UL, although its task_size is only 2.4GB.
I would remove #define COMPAT_RLIM_INFINITY 0x7fff
>
> Arnd
--
Best Regards
Guo Ren
ML: https://lore.kernel.org/linux-csky/
On Sun, Jan 30, 2022 at 6:41 AM Arnd Bergmann wrote:
>
> > Implement compat sys_call_table and some system call functions:
> > truncate64, ftruncate64, fallocate, pread64, pwrite64,
> > sync_file_range, readahead, fadvise64_64 which need argument
> > translation.
>
On Sun, Jan 30, 2022 at 7:32 PM Arnd Bergmann wrote:
>
> On Sun, Jan 30, 2022 at 6:54 AM Guo Ren wrote:
> > On Sun, Jan 30, 2022 at 6:41 AM Arnd Bergmann wrote:
> > >
> > > I would make these endian-specific, and reverse them on big-endian
> > > arc
Reviewed-by: Guo Ren
On Mon, Jan 31, 2022 at 2:49 PM Christoph Hellwig wrote:
>
> Signed-off-by: Christoph Hellwig
> ---
> include/uapi/asm-generic/fcntl.h | 2 --
> tools/include/uapi/asm-generic/fcntl.h | 2 --
> 2 files changed, 4 deletions(-)
>
> diff
;
> struct flock64 {
> @@ -212,7 +206,9 @@ struct flock64 {
> __kernel_loff_t l_start;
> __kernel_loff_t l_len;
> __kernel_pid_t l_pid;
> +#ifdef __ARCH_FLOCK64_PAD
> __ARCH_FLOCK64_PAD
> +#endif
> };
>
> #endif /* _ASM_GENERIC_FCNTL_H */
> --
> 2.30.2
>
Reviewed-by: Guo Ren
--
Best Regards
Guo Ren
ML: https://lore.kernel.org/linux-csky/
Acked-by: Guo Ren
On Mon, Jan 31, 2022 at 2:49 PM Christoph Hellwig wrote:
>
> The F_GETLK64/F_SETLK64/F_SETLKW64 fcntl opcodes are only implemented
> for the 32-bit syscall APIs, but are also needed for compat handling
> on 64-bit kernels.
>
> Consolidate them in unistd.h ins
But most rv32 apps would meet different userspace
segment faults.
Current code would let the machine try the rv32 apps without detecting
whether hw support or not.
--
Best Regards
Guo Ren
ML: https://lore.kernel.org/linux-csky/
On Mon, Jan 31, 2022 at 8:21 PM Christoph Hellwig wrote:
>
> On Sat, Jan 29, 2022 at 08:17:14PM +0800, guo...@kernel.org wrote:
> > From: Guo Ren
> >
> > There are 7 64bit architectures that support Linux COMPAT mode to
> > run 32bit applications. A lo
ed-by: Arnd Bergmann
>
> I think it would be best to merge this through the risc-v tree along
> with the coming compat support
> that depends on it.
Okay, I would include it in my next version series.
> Alternatively, I can put it into my asm-generic
> tree for 5.18.
>
> Arnd
--
Best Regards
Guo Ren
ML: https://lore.kernel.org/linux-csky/
gt; +++ b/tools/include/uapi/asm-generic/fcntl.h
> @@ -202,7 +202,6 @@ struct flock {
> };
> #endif
>
> -#ifndef HAVE_ARCH_STRUCT_FLOCK64
> #ifndef __ARCH_FLOCK64_PAD
> #define __ARCH_FLOCK64_PAD
> #endif
> @@ -215,6 +214,5 @@ struct flock64 {
> __kernel_pid_t l_p
WN_EX15
> diff --git a/tools/include/uapi/asm-generic/fcntl.h
> b/tools/include/uapi/asm-generic/fcntl.h
> index bf961a71802e0..6e16722026f39 100644
> --- a/tools/include/uapi/asm-generic/fcntl.h
> +++ b/tools/include/uapi/asm-generic/fcntl.h
> @@ -115,13 +115,11 @@
> #define F_GETSIG 11 /* for sockets. */
> #endif
>
> -#ifndef CONFIG_64BIT
> #ifndef F_GETLK64
> #define F_GETLK64 12 /* using 'struct flock64' */
> #define F_SETLK64 13
> #define F_SETLKW64 14
> #endif
> -#endif
>
> #ifndef F_SETOWN_EX
> #define F_SETOWN_EX15
> --
> 2.30.2
>
--
Best Regards
Guo Ren
ML: https://lore.kernel.org/linux-csky/
On Tue, Feb 1, 2022 at 11:02 AM Guo Ren wrote:
>
> On Mon, Jan 31, 2022 at 2:49 PM Christoph Hellwig wrote:
> >
> > The F_GETLK64/F_SETLK64/F_SETLKW64 fcntl opcodes are only implemented
> > for the 32-bit syscall APIs, but are also needed for compat handli
On Tue, Feb 1, 2022 at 3:45 PM Christoph Hellwig wrote:
>
> On Mon, Jan 31, 2022 at 09:50:58PM +0800, Guo Ren wrote:
> > On Mon, Jan 31, 2022 at 8:26 PM Christoph Hellwig
> > wrote:
> > >
> > > Given that most rv64 implementations can't run in rv3
+#endif
+
riscv_fill_hwcap();
}
On Tue, Feb 1, 2022 at 5:36 PM Arnd Bergmann wrote:
>
> On Tue, Feb 1, 2022 at 10:13 AM Guo Ren wrote:
> > On Tue, Feb 1, 2022 at 3:45 PM Christoph Hellwig wrote:
> > > On Mon, Jan 31, 2022 at 09:50:58PM +0800, Guo Ren wrote:
>
On Tue, Feb 1, 2022 at 7:48 PM Arnd Bergmann wrote:
>
> On Tue, Feb 1, 2022 at 11:26 AM Guo Ren wrote:
> >
> > Hi Arnd & Christoph,
> >
> > The UXL field controls the value of XLEN for U-mode, termed UXLEN,
> > which may differ from the
> > value of
On Wed, Feb 2, 2022 at 12:11 AM Anup Patel wrote:
>
> On Tue, Feb 1, 2022 at 9:31 PM Paolo Bonzini wrote:
> >
> > On 2/1/22 16:44, Anup Patel wrote:
> > > +Paolo
> > >
> > > On Tue, Feb 1, 2022 at 8:38 PM wrote:
> > >>
> > >>
On Tue, Feb 1, 2022 at 11:07 PM wrote:
>
> From: Guo Ren
>
> Detect hardware COMPAT (32bit U-mode) capability in rv64. If not
> support COMPAT mode in hw, compat_elf_check_arch would return
> false by compat_binfmt_elf.c
>
> Signed-off-by: Guo Ren
> Signed-off-by: G
detected\n");
> > + }
>
> I don't think we need these printks here.
Okay
>
> Also this could be simplified to:
>
> compat_mode_supported = (csr_read(CSR_STATUS) & SR_UXL) == SR_UXL_32;
Okay
--
Best Regards
Guo Ren
ML: https://lore.kernel.org/linux-csky/
On Tue, Feb 1, 2022 at 11:06 PM wrote:
>
> From: Guo Ren
>
> Currently, most 64-bit architectures (x86, parisc, powerpc, arm64,
> s390, mips, sparc) have supported COMPAT mode. But they all have
> history issues and can't use standard linux unistd.h. RISC-V wo
/uapi/asm/unistd.h
> @@ -6,6 +6,7 @@
> #define __ARCH_WANT_SYS_CLONE3
> #define __ARCH_WANT_SET_GET_RLIMIT
> #define __ARCH_WANT_TIME32_SYSCALLS
> +#define __ARCH_WANT_SYNC_FILE_RANGE2
For csky part.
Acked-by: Guo Ren
> #include
>
> #define __NR_set_thread_area (__NR_arch_speci
The flag can be checked inside of vm_unmapped_area() so
> that this flag does not have to be handled individually by each
> architecture.
Acked-by: Guo Ren
Sv57's pain finds its cure in this antidote.
>
> Link:
> https://github.com/openjdk/jdk/blob/f080b4bb8a75284db1b6037f8c00ef3
traint in arch_get_mmap_end()
>
> For some reason, it appears that the arch_get_mmap_end()
> logic on RISC-V defaults to the maximum address
> space for the 'addr==0' case which is inconsistentn with
> the other architectures, so we should probably fix that
> part first, possibly moving more of that logic into a
> shared implementation.
>
> Arnd
>
--
Best Regards
Guo Ren
ector/Zfinx-related checks.
Signed-off-by: Tsukasa OI
Reviewed-by: Alistair Francis
Message-Id:
Signed-off-by: Alistair Francis
On Mon, May 23, 2022 at 1:45 PM Guenter Roeck wrote:
>
> On Tue, Mar 22, 2022 at 10:40:03PM +0800, guo...@kernel.org wrote:
> > From: Guo
On Mon, May 23, 2022 at 1:45 PM Guenter Roeck wrote:
>
> On Tue, Mar 22, 2022 at 10:40:03PM +0800, guo...@kernel.org wrote:
> > From: Guo Ren
> >
> > Adds initial skeletal COMPAT Kbuild (Running 32bit U-mode on
> > 64bit S-mode) support.
> > - Setup kco
On Wed, May 25, 2022 at 1:42 AM Guo Ren wrote:
>
> On Mon, May 23, 2022 at 1:45 PM Guenter Roeck wrote:
> >
> > On Tue, Mar 22, 2022 at 10:40:03PM +0800, guo...@kernel.org wrote:
> > > From: Guo Ren
> > >
> > > Adds initial skeletal COMPAT Kbuil
1 - 100 of 108 matches
Mail list logo