Skip to contentSkip to conversation

(no subject)

PATCH Thiemo Seufer 2 participants 4 messages Jan 22, 2008 – Jan 28, 2008 MIPS

lore
Share & tools
lore
#0 lore raw

Hello All,

This patch moves the micro-assembler in a separate implementation, as it is useful for further run-time optimizations. The only change in behaviour is cutting down printk noise at kernel startup time.

Checkpatch complains about macro parameters which aren't protected by parentheses. I believe this is a flaw in checkpatch, the paste operator used in those macros won't work with parenthesised parameters.

Tested on:
- Qemu 32-bit little endian
- BCM1480 64-bit big endian

Thiemo

---
Split the micro-assembler from tlbex.c.

arch/mips/mm/Makefile +2 -1
index 32fd5db..c6f832e 100644
@@ -3,7 +3,8 @@
 #
 
 obj-y				+= cache.o dma-default.o extable.o fault.o \
-				   init.o pgtable.o tlbex.o tlbex-fault.o
+				   init.o pgtable.o tlbex.o tlbex-fault.o \
+				   uasm.o
 
 obj-$(CONFIG_32BIT)		+= ioremap.o pgtable-32.o
 obj-$(CONFIG_64BIT)		+= pgtable-64.o
arch/mips/mm/tlbex.c +336 -944

1,831 lines not on this page · raw message

arch/mips/mm/uasm.c new file +566 -0

566 lines not on this page · raw message

arch/mips/mm/uasm.h new file +192 -0

192 lines not on this page · raw message

#1 lore raw

Re: your mail

Quoted 13 lines · Thiemo Seufer

This patch moves the micro-assembler in a separate implementation, as it is useful for further run-time optimizations. The only change in behaviour is cutting down printk noise at kernel startup time.

Checkpatch complains about macro parameters which aren't protected by parentheses. I believe this is a flaw in checkpatch, the paste operator used in those macros won't work with parenthesised parameters.

Tested on:
- Qemu 32-bit little endian
- BCM1480 64-bit big endian

Quoted 7 lines

Thiemo

---
Split the micro-assembler from tlbex.c.

Looks technically ok but conflicts with these 7 other patches which also touch arch/mips/mm/tlbex.c:

Please keep all the stuff the stuff that should go into the commit message - and only that - above the "---" tearline. git-am will drop anything below it and friendly greetings, signatures etc. should not go into the log message so keep that below the tearoff line.

commit 699a78e99f302003ae6d6090bf7f35eb69b772e0

Author: Manuel Lauss <[email protected]>
Date:   Thu Dec 6 09:07:55 2007 +0100

[MIPS] Alchemy: Au1210/Au1250 CPU support

This patch adds IDs for new Au1200 variants: Au1210 and Au1250. They are essentially identical to the Au1200 except for the Au1210 which has a different SoC-ID in the PRId register [bits 31:24]. The Au1250 is a "Au1200 V0.2".

commit 56bccd5921f7b1160ddab0f9c3e9cc227ecd9aef

Author: Franck Bui-Huu <[email protected]>
Date:   Thu Oct 18 09:11:17 2007 +0200

[MIPS] tlbex.c: cleanup debug code

commit 97432dc56d464006a62b1cd3ee6484828bde816c

Author: Franck Bui-Huu <[email protected]>
Date:   Thu Oct 18 09:11:16 2007 +0200

[MIPS] tlbex.c: use __cacheline_aligned instead of __tlb_handler_align

commit 82e27810cd28e4322bd400640c8627ceacfc29f5

Author: Franck Bui-Huu <[email protected]>
Date:   Thu Oct 18 09:11:15 2007 +0200

[MIPS] tlbex.c: cleanup include files

commit b849ac81b87278c9b9e17aef8f4d82a30578ec93

Author: Franck Bui-Huu <[email protected]>
Date:   Thu Oct 18 09:11:14 2007 +0200

[MIPS] tlbex.c: Cleanup __init usages.

commit bf672b2f700d031d933c7dadcd9fae5edaa019b4

Author: Maciej W. Rozycki <[email protected]>
Date:   Tue Oct 23 12:43:25 2007 +0100

[MIPS] R4000/R4400 daddiu erratum workaround

This complements the generic R4000/R4400 errata workaround code and adds
bits for the daddiu problem. In most places it just modifies handwritten assembly code so that the assembler is allowed to use a temporary register as daddiu may now be treated as a macro that expands to a sequence of li and daddu. It is the AT register or, where AT is unavailable or used explicitly for another purpose, an explicitly-named register is selected, using the .set at=<reg> feature added recently to gas. This feature is only used if CONFIG_CPU_DADDI_WORKAROUNDS has been set, so if the workaround remains disabled, the required version of binutils stays unchanged.

Similarly, daddiu instructions put in branch delay slots in noreorder
fragments are now taken out of them and the assembler is allowed to reorder them itself as possible (which it does making the whole idea of scheduling them into delay slots manually questionable).

Also in the very few places where such a simple conversion was not
possible, a handcoded longer sequence is implemented.

Other than that there are changes to code responsible for building the
TLB fault and page clear/copy handlers to avoid daddiu as appropriate. These are only effective if the erratum is verified to be present at the run time.

Finally there is a trivial update to __delay(), because it uses daddiu in
a branch delay slot.

commit 2d220349159729f143570673f8752aafd6d8da74

Author: Ralf Baechle <[email protected]>
Date:   Mon Jan 28 17:14:10 2008 +0000

[MIPS] tlbex: Cleanup handling of R2 hazards in TLB handlers.

But I'm really happing to see the generalization we've been talking about to finally proceed.

Ralf

#2 lore raw

Split the micro-assembler from tlbex.c (was: Re: your mail)

Quoted 23 lines · Ralf Baechle
Quoted 13 lines · Thiemo Seufer

This patch moves the micro-assembler in a separate implementation, as it is useful for further run-time optimizations. The only change in behaviour is cutting down printk noise at kernel startup time.

Checkpatch complains about macro parameters which aren't protected by parentheses. I believe this is a flaw in checkpatch, the paste operator used in those macros won't work with parenthesised parameters.

Tested on:
- Qemu 32-bit little endian
- BCM1480 64-bit big endian

Quoted 7 lines

Thiemo

---
Split the micro-assembler from tlbex.c.

Quoted 7 lines

Looks technically ok but conflicts with these 7 other patches which also touch arch/mips/mm/tlbex.c:

Please keep all the stuff the stuff that should go into the commit message - and only that - above the "---" tearline. git-am will drop anything below it and friendly greetings, signatures etc. should not go into the log message so keep that below the tearoff line.

Split the micro-assembler from tlbex.c.

This patch moves the micro-assembler in a separate implementation, as it is useful for further run-time optimizations. The only change in behaviour is cutting down printk noise at kernel startup time.

Checkpatch complains about macro parameters which aren't protected by parentheses. I believe this is a flaw in checkpatch, the paste operator used in those macros won't work with parenthesised parameters.

---

arch/mips/mm/Makefile +2 -1
index 32fd5db..c6f832e 100644
@@ -3,7 +3,8 @@
 #
 
 obj-y				+= cache.o dma-default.o extable.o fault.o \
-				   init.o pgtable.o tlbex.o tlbex-fault.o
+				   init.o pgtable.o tlbex.o tlbex-fault.o \
+				   uasm.o
 
 obj-$(CONFIG_32BIT)		+= ioremap.o pgtable-32.o
 obj-$(CONFIG_64BIT)		+= pgtable-64.o
arch/mips/mm/tlbex.c +341 -959

1,844 lines not on this page · raw message

arch/mips/mm/uasm.c new file +576 -0

576 lines not on this page · raw message

arch/mips/mm/uasm.h new file +192 -0

192 lines not on this page · raw message

#3 lore raw

Re: Split the micro-assembler from tlbex.c (was: Re: your mail)

Quoted 11 lines · Thiemo Seufer

Split the micro-assembler from tlbex.c.

This patch moves the micro-assembler in a separate implementation, as it is useful for further run-time optimizations. The only change in behaviour is cutting down printk noise at kernel startup time.

Checkpatch complains about macro parameters which aren't protected by parentheses. I believe this is a flaw in checkpatch, the paste operator used in those macros won't work with parenthesised parameters.

This one works, thanks.

Ralf