On Thu, Sep 27, 2018 at 08:49:18AM -0700, Christoph Hellwig wrote:
> > --- /dev/null
> > +++ b/arch/csky/include/asm/irq.h
> > @@ -0,0 +1,9 @@
> > +// SPDX-License-Identifier: GPL-2.0
> > +// Copyright (C) 2018 Hangzhou C-SKY Microsystems co.,ltd.
> > +
> > +#ifndef __ASM_CSKY_IRQ_H
> > +#define
___constant_swab64(u);
>
> > +unsigned int notrace __bswapsi2(unsigned int u)
> > +{
> > + return (((u) & 0xff00) >> 24) |
> > + (((u) & 0x00ff) >> 8) |
> > + (((u) & 0xff00) << 8) |
> > + (((u) & 0x00ff) << 24);
> > +}
>
> Same here.
OK.
#include
unsigned int notrace __bswapsi2(unsigned int u)
{
return ___constant_swab32(u);
}
Thx
Guo Ren
___constant_swab64(u);
>
> > +unsigned int notrace __bswapsi2(unsigned int u)
> > +{
> > + return (((u) & 0xff00) >> 24) |
> > + (((u) & 0x00ff) >> 8) |
> > + (((u) & 0xff00) << 8) |
> > + (((u) & 0x00ff) << 24);
> > +}
>
> Same here.
OK.
#include
unsigned int notrace __bswapsi2(unsigned int u)
{
return ___constant_swab32(u);
}
Thx
Guo Ren
On Fri, Sep 28, 2018 at 09:21:16AM -0700, Christoph Hellwig wrote:
> On Fri, Sep 28, 2018 at 08:51:17AM +0800, Guo Ren wrote:
> > The arch_sync_dma_for_cpu()/arch_sync_dma_for_device() implementation is
> > broken for some combinations that end up in a BUG() instead of performing
&g
On Fri, Sep 28, 2018 at 09:21:16AM -0700, Christoph Hellwig wrote:
> On Fri, Sep 28, 2018 at 08:51:17AM +0800, Guo Ren wrote:
> > The arch_sync_dma_for_cpu()/arch_sync_dma_for_device() implementation is
> > broken for some combinations that end up in a BUG() instead of performing
&g
On Thu, Sep 27, 2018 at 09:50:43PM +0200, Eric W. Biederman wrote:
> Guo Ren writes:
>
> > --- /dev/null
> > +++ b/arch/csky/abiv2/fpu.c
> > +void fpu_fpe(struct pt_regs * regs)
> > +{
> > + int sig;
> > + unsigned int fesr;
> > + si
On Thu, Sep 27, 2018 at 09:50:43PM +0200, Eric W. Biederman wrote:
> Guo Ren writes:
>
> > --- /dev/null
> > +++ b/arch/csky/abiv2/fpu.c
> > +void fpu_fpe(struct pt_regs * regs)
> > +{
> > + int sig;
> > + unsigned int fesr;
> > + si
On Thu, Sep 27, 2018 at 08:49:18AM -0700, Christoph Hellwig wrote:
> > --- /dev/null
> > +++ b/arch/csky/include/asm/irq.h
> > @@ -0,0 +1,9 @@
> > +// SPDX-License-Identifier: GPL-2.0
> > +// Copyright (C) 2018 Hangzhou C-SKY Microsystems co.,ltd.
> > +
> > +#ifndef __ASM_CSKY_IRQ_H
> > +#define
On Thu, Sep 27, 2018 at 08:49:18AM -0700, Christoph Hellwig wrote:
> > --- /dev/null
> > +++ b/arch/csky/include/asm/irq.h
> > @@ -0,0 +1,9 @@
> > +// SPDX-License-Identifier: GPL-2.0
> > +// Copyright (C) 2018 Hangzhou C-SKY Microsystems co.,ltd.
> > +
> > +#ifndef __ASM_CSKY_IRQ_H
> > +#define
ed long vaddr;
> > +
> > + if (PageHighMem(page))
> > + vaddr = (unsigned long) kmap_atomic(page);
>
> This isn't going to work as the size might be larger than PAGE_SIZE.
Yes, you are right. I must fix it up. Thank you
Best Regards
Guo Ren
ed long vaddr;
> > +
> > + if (PageHighMem(page))
> > + vaddr = (unsigned long) kmap_atomic(page);
>
> This isn't going to work as the size might be larger than PAGE_SIZE.
Yes, you are right. I must fix it up. Thank you
Best Regards
Guo Ren
On Fri, Sep 28, 2018 at 06:32:34AM -0500, Rob Herring wrote:
> On Thu, Sep 27, 2018 at 8:03 PM Guo Ren wrote:
> >
> > On Thu, Sep 27, 2018 at 11:43:17AM -0500, Rob Herring wrote:
> > > On Tue, Sep 25, 2018 at 07:39:21AM +0800, Guo Ren wrote:
> > > > This patc
On Fri, Sep 28, 2018 at 06:32:34AM -0500, Rob Herring wrote:
> On Thu, Sep 27, 2018 at 8:03 PM Guo Ren wrote:
> >
> > On Thu, Sep 27, 2018 at 11:43:17AM -0500, Rob Herring wrote:
> > > On Tue, Sep 25, 2018 at 07:39:21AM +0800, Guo Ren wrote:
> > > > This patc
On Thu, Sep 27, 2018 at 11:50:44AM -0500, Rob Herring wrote:
> On Tue, Sep 25, 2018 at 07:39:26AM +0800, Guo Ren wrote:
> > - Dt-bindings doc about C-SKY Multi-processors interrupt controller.
> >
> > Signed-off-by: Guo Ren
> > ---
> > .../bindings/interrupt
On Thu, Sep 27, 2018 at 11:50:44AM -0500, Rob Herring wrote:
> On Tue, Sep 25, 2018 at 07:39:26AM +0800, Guo Ren wrote:
> > - Dt-bindings doc about C-SKY Multi-processors interrupt controller.
> >
> > Signed-off-by: Guo Ren
> > ---
> > .../bindings/interrupt
On Thu, Sep 27, 2018 at 11:43:17AM -0500, Rob Herring wrote:
> On Tue, Sep 25, 2018 at 07:39:21AM +0800, Guo Ren wrote:
> > This patch adds the documentation to describe that how to add cpu nodes in
> > dts for SMP.
> >
> > Signed-off-by: Guo Ren
> > ---
>
On Thu, Sep 27, 2018 at 11:43:17AM -0500, Rob Herring wrote:
> On Tue, Sep 25, 2018 at 07:39:21AM +0800, Guo Ren wrote:
> > This patch adds the documentation to describe that how to add cpu nodes in
> > dts for SMP.
> >
> > Signed-off-by: Guo Ren
> > ---
>
In flush_cache_range(vma, ...) cache_wbinv_range() couldn't deal with
vma->mm's asid for cache_flush_line. So we use cache_wbinv_all() first
and we'll improve with cache_flush(vma, start, end) in future.
For tlb_start_vma, we make it the same as other arch.
Signed-off-by: Guo Ren
---
arch/c
In flush_cache_range(vma, ...) cache_wbinv_range() couldn't deal with
vma->mm's asid for cache_flush_line. So we use cache_wbinv_all() first
and we'll improve with cache_flush(vma, start, end) in future.
For tlb_start_vma, we make it the same as other arch.
Signed-off-by: Guo Ren
---
arch/c
- Dt-bindings doc for gx6605s SOC's system timer.
Signed-off-by: Guo Ren
Reviewed-by: Rob Herring
---
.../bindings/timer/csky,gx6605s-timer.txt | 42 ++
1 file changed, 42 insertions(+)
create mode 100644
Documentation/devicetree/bindings/timer/csky,gx6605s
- Dt-bindings doc for gx6605s SOC's system timer.
Signed-off-by: Guo Ren
Reviewed-by: Rob Herring
---
.../bindings/timer/csky,gx6605s-timer.txt | 42 ++
1 file changed, 42 insertions(+)
create mode 100644
Documentation/devicetree/bindings/timer/csky,gx6605s
,
from ./include/linux/rcupdate.h:38,
from ./include/linux/init_task.h:5,
from init/init_task.c:2:
The asm/bitops.h will lose asm/atomic.h for cycle include.
Signed-off-by: Guo Ren
---
arch/csky/include/asm/cmpxchg.h | 7 ---
1 file changed
Changelog:
- Add License and Copyright
- Use timer-of framework
- Change name with upstream feedback
- Use clksource_mmio framework
Signed-off-by: Guo Ren
---
drivers/clocksource/Kconfig | 8 ++
drivers/clocksource/Makefile| 1 +
drivers/clocksource/timer-gx6605s.c | 150
,
from ./include/linux/rcupdate.h:38,
from ./include/linux/init_task.h:5,
from init/init_task.c:2:
The asm/bitops.h will lose asm/atomic.h for cycle include.
Signed-off-by: Guo Ren
---
arch/csky/include/asm/cmpxchg.h | 7 ---
1 file changed
Changelog:
- Add License and Copyright
- Use timer-of framework
- Change name with upstream feedback
- Use clksource_mmio framework
Signed-off-by: Guo Ren
---
drivers/clocksource/Kconfig | 8 ++
drivers/clocksource/Makefile| 1 +
drivers/clocksource/timer-gx6605s.c | 150
Add csky vendor definition.
Signed-off-by: Guo Ren
---
Documentation/devicetree/bindings/vendor-prefixes.txt | 1 +
1 file changed, 1 insertion(+)
diff --git a/Documentation/devicetree/bindings/vendor-prefixes.txt
b/Documentation/devicetree/bindings/vendor-prefixes.txt
index 2c3fc51..a728ee3
- Dt-bingdings doc for C-SKY SMP system setting.
Signed-off-by: Guo Ren
---
.../devicetree/bindings/timer/csky,mptimer.txt | 46 ++
1 file changed, 46 insertions(+)
create mode 100644 Documentation/devicetree/bindings/timer/csky,mptimer.txt
diff --git a/Documentation
Add csky vendor definition.
Signed-off-by: Guo Ren
---
Documentation/devicetree/bindings/vendor-prefixes.txt | 1 +
1 file changed, 1 insertion(+)
diff --git a/Documentation/devicetree/bindings/vendor-prefixes.txt
b/Documentation/devicetree/bindings/vendor-prefixes.txt
index 2c3fc51..a728ee3
- Dt-bingdings doc for C-SKY SMP system setting.
Signed-off-by: Guo Ren
---
.../devicetree/bindings/timer/csky,mptimer.txt | 46 ++
1 file changed, 46 insertions(+)
create mode 100644 Documentation/devicetree/bindings/timer/csky,mptimer.txt
diff --git a/Documentation
Specific implementation do not improve the performance, fall
back to asm-generic/bitops/atomic.h.
Signed-off-by: Guo Ren
---
arch/csky/include/asm/bitops.h | 201 -
1 file changed, 201 deletions(-)
diff --git a/arch/csky/include/asm/bitops.h b/arch/csky
.
- Coding convention with upstream feed-back.
Signed-off-by: Guo Ren
---
drivers/clocksource/Kconfig| 8 ++
drivers/clocksource/Makefile | 1 +
drivers/clocksource/csky_mptimer.c | 176 +
include/linux/cpuhotplug.h | 1 +
4 files changed
- Dt-bindings doc about C-SKY Multi-processors interrupt controller.
Signed-off-by: Guo Ren
---
.../bindings/interrupt-controller/csky,mpintc.txt | 40 ++
1 file changed, 40 insertions(+)
create mode 100644
Documentation/devicetree/bindings/interrupt-controller/csky
g return value not
directly use IPI_IRQ. The modification also involves csky_mpintc.
Signed-off-by: Guo Ren
---
arch/csky/include/asm/smp.h | 4 +++-
arch/csky/kernel/smp.c | 27 +++
2 files changed, 22 insertions(+), 9 deletions(-)
diff --git a/arch/csky/inclu
- Dt-bindings doc about C-SKY apb bus interrupt controller.
Signed-off-by: Guo Ren
---
.../interrupt-controller/csky,apb-intc.txt | 62 ++
1 file changed, 62 insertions(+)
create mode 100644
Documentation/devicetree/bindings/interrupt-controller/csky,apb-intc.txt
Specific implementation do not improve the performance, fall
back to asm-generic/bitops/atomic.h.
Signed-off-by: Guo Ren
---
arch/csky/include/asm/bitops.h | 201 -
1 file changed, 201 deletions(-)
diff --git a/arch/csky/include/asm/bitops.h b/arch/csky
.
- Coding convention with upstream feed-back.
Signed-off-by: Guo Ren
---
drivers/clocksource/Kconfig| 8 ++
drivers/clocksource/Makefile | 1 +
drivers/clocksource/csky_mptimer.c | 176 +
include/linux/cpuhotplug.h | 1 +
4 files changed
- Dt-bindings doc about C-SKY Multi-processors interrupt controller.
Signed-off-by: Guo Ren
---
.../bindings/interrupt-controller/csky,mpintc.txt | 40 ++
1 file changed, 40 insertions(+)
create mode 100644
Documentation/devicetree/bindings/interrupt-controller/csky
g return value not
directly use IPI_IRQ. The modification also involves csky_mpintc.
Signed-off-by: Guo Ren
---
arch/csky/include/asm/smp.h | 4 +++-
arch/csky/kernel/smp.c | 27 +++
2 files changed, 22 insertions(+), 9 deletions(-)
diff --git a/arch/csky/inclu
- Dt-bindings doc about C-SKY apb bus interrupt controller.
Signed-off-by: Guo Ren
---
.../interrupt-controller/csky,apb-intc.txt | 62 ++
1 file changed, 62 insertions(+)
create mode 100644
Documentation/devicetree/bindings/interrupt-controller/csky,apb-intc.txt
Add a maintainer information for the csky(C-SKY) architecture.
Signed-off-by: Guo Ren
---
MAINTAINERS | 16
1 file changed, 16 insertions(+)
diff --git a/MAINTAINERS b/MAINTAINERS
index d870cb5..6b7c1be 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -3211,6 +3211,22 @@ T
This patch adds the documentation to describe that how to add cpu nodes in
dts for SMP.
Signed-off-by: Guo Ren
---
Documentation/devicetree/bindings/csky/cpus.txt | 70 +
1 file changed, 70 insertions(+)
create mode 100644 Documentation/devicetree/bindings/csky/cpus.txt
TO_DEV writeback nonewriteback none
TO_CPU invalidate invalidate* invalidate invalidate*
BIDIR writeback invalidate writeback invalidate
Link: https://lore.kernel.org/lkml/20180518215548.gh17...@n2100.armlinux.org.uk/
Signed-off-by: Guo
irq map, reserve soft_irq & private_irq space
- Add License and Copyright
- Support set_affinity for irq balance in SMP
Signed-off-by: Guo Ren
---
drivers/irqchip/Kconfig | 8 ++
drivers/irqchip/Makefile | 1 +
drivers/irqchip/irq-csky-mpintc.c |
rq-pending
- remove CSKY_VECIRQ_LEGENCY
- change to generic irq chip framework
- add License and Copyright
- use irq_domain_add_linear instead of leagcy
Signed-off-by: Guo Ren
---
drivers/irqchip/Kconfig | 8 ++
drivers/irqchip/Makefile| 1 +
drivers/irqchip/irq-c
Add a maintainer information for the csky(C-SKY) architecture.
Signed-off-by: Guo Ren
---
MAINTAINERS | 16
1 file changed, 16 insertions(+)
diff --git a/MAINTAINERS b/MAINTAINERS
index d870cb5..6b7c1be 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -3211,6 +3211,22 @@ T
This patch adds the documentation to describe that how to add cpu nodes in
dts for SMP.
Signed-off-by: Guo Ren
---
Documentation/devicetree/bindings/csky/cpus.txt | 70 +
1 file changed, 70 insertions(+)
create mode 100644 Documentation/devicetree/bindings/csky/cpus.txt
TO_DEV writeback nonewriteback none
TO_CPU invalidate invalidate* invalidate invalidate*
BIDIR writeback invalidate writeback invalidate
Link: https://lore.kernel.org/lkml/20180518215548.gh17...@n2100.armlinux.org.uk/
Signed-off-by: Guo
irq map, reserve soft_irq & private_irq space
- Add License and Copyright
- Support set_affinity for irq balance in SMP
Signed-off-by: Guo Ren
---
drivers/irqchip/Kconfig | 8 ++
drivers/irqchip/Makefile | 1 +
drivers/irqchip/irq-csky-mpintc.c |
rq-pending
- remove CSKY_VECIRQ_LEGENCY
- change to generic irq chip framework
- add License and Copyright
- use irq_domain_add_linear instead of leagcy
Signed-off-by: Guo Ren
---
drivers/irqchip/Kconfig | 8 ++
drivers/irqchip/Makefile| 1 +
drivers/irqchip/irq-c
This patch adds boot, ipi, hotplug code for SMP.
Signed-off-by: Guo Ren
---
arch/csky/include/asm/smp.h | 26 +
arch/csky/kernel/smp.c | 234
2 files changed, 260 insertions(+)
create mode 100644 arch/csky/include/asm/smp.h
create mode
This patch adds csky register definition, byteorder, asm-offsets codes.
Signed-off-by: Guo Ren
---
arch/csky/abiv1/inc/abi/reg_ops.h | 27
arch/csky/abiv1/inc/abi/regdef.h | 26 +++
arch/csky/abiv2/inc/abi/reg_ops.h | 17 ++
arch/csky/abiv2/inc/abi/regdef.h | 26
This patch adds boot, ipi, hotplug code for SMP.
Signed-off-by: Guo Ren
---
arch/csky/include/asm/smp.h | 26 +
arch/csky/kernel/smp.c | 234
2 files changed, 260 insertions(+)
create mode 100644 arch/csky/include/asm/smp.h
create mode
This patch adds csky register definition, byteorder, asm-offsets codes.
Signed-off-by: Guo Ren
---
arch/csky/abiv1/inc/abi/reg_ops.h | 27
arch/csky/abiv1/inc/abi/regdef.h | 26 +++
arch/csky/abiv2/inc/abi/reg_ops.h | 17 ++
arch/csky/abiv2/inc/abi/regdef.h | 26
This patch adds "user access from kernel" codes.
Signed-off-by: Guo Ren
---
arch/csky/include/asm/uaccess.h | 399
arch/csky/lib/usercopy.c| 271 +++
2 files changed, 670 insertions(+)
create mode 100644 arch/cs
This patch adds IRQ handling files.
Signed-off-by: Guo Ren
---
arch/csky/include/asm/irq.h | 9
arch/csky/include/asm/irqflags.h | 50
arch/csky/kernel/irq.c | 22 ++
3 files changed, 81 insertions(+)
create mode
This patch adds "user access from kernel" codes.
Signed-off-by: Guo Ren
---
arch/csky/include/asm/uaccess.h | 399
arch/csky/lib/usercopy.c| 271 +++
2 files changed, 670 insertions(+)
create mode 100644 arch/cs
This patch adds IRQ handling files.
Signed-off-by: Guo Ren
---
arch/csky/include/asm/irq.h | 9
arch/csky/include/asm/irqflags.h | 50
arch/csky/kernel/irq.c | 22 ++
3 files changed, 81 insertions(+)
create mode
This patch adds string optimize codes and some auxiliary code.
Signed-off-by: Chen Linfei
Signed-off-by: Mao Han
Signed-off-by: Guo Ren
---
arch/csky/abiv1/bswapdi.c| 19 +++
arch/csky/abiv1/bswapsi.c| 15 ++
arch/csky/abiv1/inc/abi/string.h | 13 ++
arch/csky/abiv1
This patch adds string optimize codes and some auxiliary code.
Signed-off-by: Chen Linfei
Signed-off-by: Mao Han
Signed-off-by: Guo Ren
---
arch/csky/abiv1/bswapdi.c| 19 +++
arch/csky/abiv1/bswapsi.c| 15 ++
arch/csky/abiv1/inc/abi/string.h | 13 ++
arch/csky/abiv1
This patch adds atomic, cmpxchg, spinlock files.
- SMP supported
- ticklock supported
- queue-rwlock supported
Signed-off-by: Guo Ren
---
arch/csky/include/asm/atomic.h | 213 ++
arch/csky/include/asm/cmpxchg.h| 70 +
arch/csky/include/asm
This patch adds ELF definition and module relocate codes.
Signed-off-by: Guo Ren
---
arch/csky/include/asm/elf.h | 150
arch/csky/kernel/module.c | 83
2 files changed, 233 insertions(+)
create mode 100644 arch/csky
This patch adds arch ptrace implementation, stack dump and bug.h.
Signed-off-by: Guo Ren
---
arch/csky/include/asm/bug.h | 26 +++
arch/csky/include/uapi/asm/ptrace.h | 104
arch/csky/kernel/dumpstack.c| 65
arch/csky/kernel/ptrace.c | 318
This patch adds atomic, cmpxchg, spinlock files.
- SMP supported
- ticklock supported
- queue-rwlock supported
Signed-off-by: Guo Ren
---
arch/csky/include/asm/atomic.h | 213 ++
arch/csky/include/asm/cmpxchg.h| 70 +
arch/csky/include/asm
This patch adds ELF definition and module relocate codes.
Signed-off-by: Guo Ren
---
arch/csky/include/asm/elf.h | 150
arch/csky/kernel/module.c | 83
2 files changed, 233 insertions(+)
create mode 100644 arch/csky
This patch adds arch ptrace implementation, stack dump and bug.h.
Signed-off-by: Guo Ren
---
arch/csky/include/asm/bug.h | 26 +++
arch/csky/include/uapi/asm/ptrace.h | 104
arch/csky/kernel/dumpstack.c| 65
arch/csky/kernel/ptrace.c | 318
This patch adds exception handling code, cpuinfo and mm-fault code.
Signed-off-by: Guo Ren
---
arch/csky/abiv1/alignment.c | 332 +
arch/csky/abiv1/inc/abi/entry.h | 160
arch/csky/abiv2/inc/abi/entry.h | 157
arch/csky
This patch adds exception handling code, cpuinfo and mm-fault code.
Signed-off-by: Guo Ren
---
arch/csky/abiv1/alignment.c | 332 +
arch/csky/abiv1/inc/abi/entry.h | 160
arch/csky/abiv2/inc/abi/entry.h | 157
arch/csky
(1GB)
- abiv1 CPU (CK610) is VIPT cache and it doesn't support highmem.
- abiv2 CPUs are all PIPT cache and they could support highmem.
Lowmem is directly mapped by msa0 & msa1 reg, and we needn't setup
memory page table for it.
Signed-off-by: Guo Ren
---
arch/csky/abiv1/inc
This patch adds files related to VDSO and our VDSO only support
rt_sigreturn.
Signed-off-by: Guo Ren
---
arch/csky/abiv1/inc/abi/vdso.h | 18 +
arch/csky/abiv2/inc/abi/vdso.h | 24
arch/csky/include/asm/vdso.h | 13 +++
arch/csky/kernel/vdso.c| 85
(1GB)
- abiv1 CPU (CK610) is VIPT cache and it doesn't support highmem.
- abiv2 CPUs are all PIPT cache and they could support highmem.
Lowmem is directly mapped by msa0 & msa1 reg, and we needn't setup
memory page table for it.
Signed-off-by: Guo Ren
---
arch/csky/abiv1/inc
This patch adds files related to VDSO and our VDSO only support
rt_sigreturn.
Signed-off-by: Guo Ren
---
arch/csky/abiv1/inc/abi/vdso.h | 18 +
arch/csky/abiv2/inc/abi/vdso.h | 24
arch/csky/include/asm/vdso.h | 13 +++
arch/csky/kernel/vdso.c| 85
This patch adds files related to syscall.
Signed-off-by: Guo Ren
---
arch/csky/include/asm/syscall.h | 69 +
arch/csky/include/asm/syscalls.h| 15
arch/csky/include/uapi/asm/unistd.h | 10 ++
arch/csky/kernel/syscall.c | 42
This patch adds files related to syscall.
Signed-off-by: Guo Ren
---
arch/csky/include/asm/syscall.h | 69 +
arch/csky/include/asm/syscalls.h| 15
arch/csky/include/uapi/asm/unistd.h | 10 ++
arch/csky/kernel/syscall.c | 42
This patch adds files related to task_switch, sigcontext, signal.
Signed-off-by: Guo Ren
---
arch/csky/abiv2/fpu.c | 281 +
arch/csky/abiv2/inc/abi/fpu.h | 66 ++
arch/csky/include/asm/mmu_context.h | 149 ++
arch/csky
This patch adds files related to task_switch, sigcontext, signal.
Signed-off-by: Guo Ren
---
arch/csky/abiv2/fpu.c | 281 +
arch/csky/abiv2/inc/abi/fpu.h | 66 ++
arch/csky/include/asm/mmu_context.h | 149 ++
arch/csky
This patch add boot code. Thx boot params is all in dtb and it's
the only way to let kernel get bootloader param information.
Signed-off-by: Guo Ren
---
arch/csky/kernel/head.S| 78 +
arch/csky/kernel/setup.c | 151
This patch adds cache and tlb sync codes for abiv1 & abiv2.
Signed-off-by: Guo Ren
---
arch/csky/abiv1/cacheflush.c | 51
arch/csky/abiv1/inc/abi/cacheflush.h | 43 +++
arch/csky/abiv1/inc/abi/tlb.h | 12 ++
arch/csky/abiv2/cacheflush.c |
This patch add boot code. Thx boot params is all in dtb and it's
the only way to let kernel get bootloader param information.
Signed-off-by: Guo Ren
---
arch/csky/kernel/head.S| 78 +
arch/csky/kernel/setup.c | 151
This patch adds cache and tlb sync codes for abiv1 & abiv2.
Signed-off-by: Guo Ren
---
arch/csky/abiv1/cacheflush.c | 51
arch/csky/abiv1/inc/abi/cacheflush.h | 43 +++
arch/csky/abiv1/inc/abi/tlb.h | 12 ++
arch/csky/abiv2/cacheflush.c |
g select.
590c7e6 csky: bugfix compile error with CONFIG_AUDIT
1989292 csky: revert some back with cleanup unistd.h
f1454fe csky: cleanup unistd.h
5d2985f csky: cleanup Kconfig and Makefile.
423d97e csky: cancel subdirectories
cae2af4 csky: use asm-generic/fcntl.h
Guo Ren (33):
csky: Build i
g select.
590c7e6 csky: bugfix compile error with CONFIG_AUDIT
1989292 csky: revert some back with cleanup unistd.h
f1454fe csky: cleanup unistd.h
5d2985f csky: cleanup Kconfig and Makefile.
423d97e csky: cancel subdirectories
cae2af4 csky: use asm-generic/fcntl.h
Guo Ren (33):
csky: Build i
This patch adds Makefile, Kconfig for build infrastructure.
Signed-off-by: Guo Ren
---
arch/csky/Kconfig | 204 +
arch/csky/Kconfig.debug| 8 ++
arch/csky/Makefile | 92 +++
arch/csky/abiv1
This patch adds Makefile, Kconfig for build infrastructure.
Signed-off-by: Guo Ren
---
arch/csky/Kconfig | 204 +
arch/csky/Kconfig.debug| 8 ++
arch/csky/Makefile | 92 +++
arch/csky/abiv1
This patch adds csky defconfig.
Signed-off-by: Guo Ren
---
arch/csky/configs/defconfig | 61 +
1 file changed, 61 insertions(+)
create mode 100644 arch/csky/configs/defconfig
diff --git a/arch/csky/configs/defconfig b/arch/csky/configs/defconfig
new
This patch adds csky defconfig.
Signed-off-by: Guo Ren
---
arch/csky/configs/defconfig | 61 +
1 file changed, 61 insertions(+)
create mode 100644 arch/csky/configs/defconfig
diff --git a/arch/csky/configs/defconfig b/arch/csky/configs/defconfig
new
=bc3ec75de5452db59b683487867ba562b950708a
Thx!
Guo Ren
On Wed, Sep 26, 2018 at 02:27:45PM +0300, Mike Rapoport wrote:
> Hi,
>
> The below patch fixes the bootmem leftovers in csky. It is based on the
> current mmots and csky build there fails because of undefined reference to
> dma_direct_ops:
>
> MODPO
=bc3ec75de5452db59b683487867ba562b950708a
Thx!
Guo Ren
On Wed, Sep 26, 2018 at 02:27:45PM +0300, Mike Rapoport wrote:
> Hi,
>
> The below patch fixes the bootmem leftovers in csky. It is based on the
> current mmots and csky build there fails because of undefined reference to
> dma_direct_ops:
>
> MODPO
On Thu, Sep 27, 2018 at 11:01:34AM +0200, Peter Zijlstra wrote:
> On Thu, Sep 27, 2018 at 04:11:42PM +0800, Guo Ren wrote:
> > On Thu, Sep 27, 2018 at 09:08:59AM +0200, Peter Zijlstra wrote:
>
> > > That's not what I meant; I meant you need something like:
> > >
&
On Thu, Sep 27, 2018 at 11:01:34AM +0200, Peter Zijlstra wrote:
> On Thu, Sep 27, 2018 at 04:11:42PM +0800, Guo Ren wrote:
> > On Thu, Sep 27, 2018 at 09:08:59AM +0200, Peter Zijlstra wrote:
>
> > > That's not what I meant; I meant you need something like:
> > >
&
On Thu, Sep 27, 2018 at 09:08:59AM +0200, Peter Zijlstra wrote:
> On Thu, Sep 27, 2018 at 01:27:38PM +0800, Guo Ren wrote:
> > On Tue, Sep 25, 2018 at 09:24:07AM +0200, Peter Zijlstra wrote:
> > > On Mon, Sep 24, 2018 at 10:36:22PM +0800, Guo Ren wrote:
> > > > diff -
On Thu, Sep 27, 2018 at 09:08:59AM +0200, Peter Zijlstra wrote:
> On Thu, Sep 27, 2018 at 01:27:38PM +0800, Guo Ren wrote:
> > On Tue, Sep 25, 2018 at 09:24:07AM +0200, Peter Zijlstra wrote:
> > > On Mon, Sep 24, 2018 at 10:36:22PM +0800, Guo Ren wrote:
> > > > diff -
On Tue, Sep 25, 2018 at 09:24:07AM +0200, Peter Zijlstra wrote:
> On Mon, Sep 24, 2018 at 10:36:22PM +0800, Guo Ren wrote:
> > diff --git a/arch/csky/abiv1/inc/abi/cacheflush.h
> > b/arch/csky/abiv1/inc/abi/cacheflush.h
> > new file mode 100644
> > index 000
On Tue, Sep 25, 2018 at 09:24:07AM +0200, Peter Zijlstra wrote:
> On Mon, Sep 24, 2018 at 10:36:22PM +0800, Guo Ren wrote:
> > diff --git a/arch/csky/abiv1/inc/abi/cacheflush.h
> > b/arch/csky/abiv1/inc/abi/cacheflush.h
> > new file mode 100644
> > index 000
inline void change_bit(int nr, volatile unsigned long *addr)
> > > +{
> > > + unsigned long mask = BIT_MASK(nr);
> > > + unsigned long *p = ((unsigned long *)addr) + BIT_WORD(nr);
> > > + unsigned long tmp;
> > > +
> > > + /* *p ^= mask; */
> > > + smp_mb();
> > > + asm volatile (
> > > + "1: ldex.w %0, (%2)\n"
> > > + " xor32 %0, %0, %1 \n"
> > > + " stex.w %0, (%2)\n"
> > > + " bez %0, 1b \n"
> > > + : "="(tmp)
> > > + : "r"(mask), "r"(p)
> > > + : "memory");
> > > + smp_mb();
> > > +}
> >
> > The {set,clear,change}_bit() operations don't have to be ordered: you
> > might want to remove the above smp_mb()s (and adjust the comments).
I confused it with cmpxchg, seems cmpxchg need smp_mb() before
See: https://lkml.org/lkml/2018/7/6/383
> Better yet, you can entirely delete all that and use
> asm-generic/bitops/atomic.h instead.
Yes, approve. Seems I only need care about asm/atomic.h, it's good for
me.
Best Regards
Guo Ren
inline void change_bit(int nr, volatile unsigned long *addr)
> > > +{
> > > + unsigned long mask = BIT_MASK(nr);
> > > + unsigned long *p = ((unsigned long *)addr) + BIT_WORD(nr);
> > > + unsigned long tmp;
> > > +
> > > + /* *p ^= mask; */
> > > + smp_mb();
> > > + asm volatile (
> > > + "1: ldex.w %0, (%2)\n"
> > > + " xor32 %0, %0, %1 \n"
> > > + " stex.w %0, (%2)\n"
> > > + " bez %0, 1b \n"
> > > + : "="(tmp)
> > > + : "r"(mask), "r"(p)
> > > + : "memory");
> > > + smp_mb();
> > > +}
> >
> > The {set,clear,change}_bit() operations don't have to be ordered: you
> > might want to remove the above smp_mb()s (and adjust the comments).
I confused it with cmpxchg, seems cmpxchg need smp_mb() before
See: https://lkml.org/lkml/2018/7/6/383
> Better yet, you can entirely delete all that and use
> asm-generic/bitops/atomic.h instead.
Yes, approve. Seems I only need care about asm/atomic.h, it's good for
me.
Best Regards
Guo Ren
fd2791b..46c5aaa 100644
> --- a/arch/csky/mm/init.c
> +++ b/arch/csky/mm/init.c
> @@ -14,7 +14,6 @@
> #include
> #include
> #include
> -#include
> #include
> #include
> #include
> @@ -44,7 +43,7 @@ void __init mem_init(void)
> #endif
> high_memory = (void *) __va(max_low_pfn << PAGE_SHIFT);
>
> - free_all_bootmem();
> + memblock_free_all();
>
> #ifdef CONFIG_HIGHMEM
> for (tmp = highstart_pfn; tmp < highend_pfn; tmp++) {
The patch looks good for me.
Thx
Guo Ren
fd2791b..46c5aaa 100644
> --- a/arch/csky/mm/init.c
> +++ b/arch/csky/mm/init.c
> @@ -14,7 +14,6 @@
> #include
> #include
> #include
> -#include
> #include
> #include
> #include
> @@ -44,7 +43,7 @@ void __init mem_init(void)
> #endif
> high_memory = (void *) __va(max_low_pfn << PAGE_SHIFT);
>
> - free_all_bootmem();
> + memblock_free_all();
>
> #ifdef CONFIG_HIGHMEM
> for (tmp = highstart_pfn; tmp < highend_pfn; tmp++) {
The patch looks good for me.
Thx
Guo Ren
On Tue, Sep 25, 2018 at 11:59:48AM +0200, Arnd Bergmann wrote:
> On Tue, Sep 25, 2018 at 11:46 AM Guo Ren wrote:
> >
> > On Mon, Sep 24, 2018 at 10:38:04PM +0200, Arnd Bergmann wrote:
> > > On Tue, Sep 18, 2018 at 3:48 PM Guo Ren wrote:
> > > >
> > >
On Tue, Sep 25, 2018 at 11:59:48AM +0200, Arnd Bergmann wrote:
> On Tue, Sep 25, 2018 at 11:46 AM Guo Ren wrote:
> >
> > On Mon, Sep 24, 2018 at 10:38:04PM +0200, Arnd Bergmann wrote:
> > > On Tue, Sep 18, 2018 at 3:48 PM Guo Ren wrote:
> > > >
> > >
On Mon, Sep 24, 2018 at 10:38:04PM +0200, Arnd Bergmann wrote:
> On Tue, Sep 18, 2018 at 3:48 PM Guo Ren wrote:
> >
> > ref: https://lkml.org/lkml/2018/5/18/1068
> >
> > map for_cpu for_device unmap
> > TO_DEV writeback non
601 - 700 of 1253 matches
Mail list logo