Linux MIPS Architecture development
 help / color / mirror / Atom feed
From: David Daney <ddaney@caviumnetworks.com>
To: Sergei Shtylyov <sshtylyov@ru.mvista.com>
Cc: linux-mips@linux-mips.org,
	Tomaso Paoletti <tpaoletti@caviumnetworks.com>,
	Paul Gortmaker <Paul.Gortmaker@windriver.com>
Subject: Re: [PATCH 28/37] Cavium OCTEON FPU EMU exception as TLB exception
Date: Fri, 24 Oct 2008 10:01:21 -0700	[thread overview]
Message-ID: <4901FF61.4040907@caviumnetworks.com> (raw)
In-Reply-To: <4901A5E3.3090702@ru.mvista.com>

Sergei Shtylyov wrote:
> Hello.
> 
> ddaney@caviumnetworks.com wrote:
> 
>> The FPU exceptions come in as TLB exceptions -- see if this is
>> one of them, and act accordingly.
>>
>> Signed-off-by: Tomaso Paoletti <tpaoletti@caviumnetworks.com>
>> Signed-off-by: Paul Gortmaker <Paul.Gortmaker@windriver.com>
>> Signed-off-by: David Daney <ddaney@caviumnetworks.com>
>> ---
>>  arch/mips/mm/fault.c |   15 +++++++++++++++
>>  1 files changed, 15 insertions(+), 0 deletions(-)
>>
>> diff --git a/arch/mips/mm/fault.c b/arch/mips/mm/fault.c
>> index fa636fc..9ce503a 100644
>> --- a/arch/mips/mm/fault.c
>> +++ b/arch/mips/mm/fault.c
>> @@ -47,6 +47,21 @@ asmlinkage void do_page_fault(struct pt_regs *regs, 
>> unsigned long write,
>>             field, regs->cp0_epc);
>>  #endif
>>  
>> +#ifdef CONFIG_CAVIUM_OCTEON_HW_FIX_UNALIGNED
>>   
> 
>   Why this is not in the same patch that introduces this option?

Because the option was introduced in patch 01/37 along with all the rest 
of the new files.  I decided to add the Kconfig for the entire patch set 
  in a single go.  For an incremental patch, certainly Kconfig changes 
would probably be in the patch that adds their use.  But I think 
rigorous orthodoxy on this point in the initial patch set might make 
things less clear rather than improving the situation.


> 
>> +    /*
>> +     * Normally the FPU emulator uses a load word from address one
>> +     * to retake control of the CPU after executing the
>> +     * instruction in the delay slot of an emulated branch. The
>> +     * Octeon hardware unaligned access fix changes this from an
>> +     * address exception into a TLB exception. This code checks to
>> +     * see if this page fault was caused by an FPU emulation.
>> +     *
>> +     * Terminate if exception was recognized as a delay slot return */
>>   
> 
>   I'm back to nitpicking again, see chapter 8 for the preferred 
> multiuline comment style (you almost got it right :-).
> 
>> +    extern int do_dsemulret(struct pt_regs *);
>>   
> 
>   Won't this cause a warning about the declaration amidst of code? You 
> should be able to put it in this function's declaration block painlessly...
> 

Both of these last point will be addressed.

David Daney

  parent reply	other threads:[~2008-10-24 17:01 UTC|newest]

Thread overview: 53+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-10-24  0:56 [PATCH 00/37] Add Cavium OCTEON processor support ddaney
2008-10-24  0:56 ` [PATCH 01/37] Add Cavium OCTEON processor support files to arch/mips/cavium-octeon ddaney
2008-10-24  0:56 ` [PATCH 02/37] Add Cavium OCTEON files to arch/mips/include/asm/mach-cavium-octeon ddaney
2008-10-24  0:56 ` [PATCH 03/37] Add Cavium OCTEON processor support files to arch/mips/kernel ddaney
2008-10-24  0:56 ` [PATCH 04/37] Add Cavium OCTEON processor support files to arch/mips/mm ddaney
2008-10-24  0:56 ` [PATCH 05/37] Add Cavium OCTEON processor support files to and arch/mips/cavium-octeon/executive ddaney
2008-10-24  0:56 ` [PATCH 06/37] Add Cavium OCTEON processor CSR definitions ddaney
2008-10-24  0:56 ` [PATCH 07/37] Don't assume boot CPU is CPU0 if MIPS_DISABLE_BOOT_CPU_ZERO set ddaney
2008-10-24  0:56 ` [PATCH 08/37] For Cavium OCTEON handle hazzards as per the R10000 handling ddaney
2008-10-24 10:46   ` Sergei Shtylyov
2008-10-24  0:56 ` [PATCH 09/37] Enable mips32 style bitops for Cavium OCTEON ddaney
2008-10-24  0:56 ` [PATCH 10/37] Cavium OCTEON: Set hwrena and lazily restore CP2 state ddaney
2008-10-24  0:56 ` [PATCH 11/37] Cavium OCTEON: ebase isn't just CAC_BASE ddaney
2008-10-24 19:56   ` Maciej W. Rozycki
2008-10-24 20:12     ` David Daney
2008-10-24  0:56 ` [PATCH 12/37] Add Cavium OCTEON to arch/mips/Kconfig ddaney
2008-10-24  0:56 ` [PATCH 13/37] Add Cavium OCTEON processor constants ddaney
2008-10-24  0:56 ` [PATCH 14/37] Rewrite cpu_to_name so it has one statement per line ddaney
2008-10-24  0:56 ` [PATCH 15/37] Probe for Cavium OCTEON CPUs ddaney
2008-10-24  0:56 ` [PATCH 16/37] MIPS: Hook Cavium OCTEON cache init into cache.c ddaney
2008-10-24  0:56 ` [PATCH 17/37] cavium: Hook Cavium specifics into main arch/mips dir ddaney
2008-10-24  0:56 ` [PATCH 18/37] Cavium OCTEON modify core io.h macros to account for the Octeon Errata Core-301 ddaney
2008-10-24  0:56 ` [PATCH 19/37] Cavium OCTEON: increase MAX_DMA address ddaney
2008-10-24  0:56 ` [PATCH 20/37] Cavium OCTEON: add in icache and dcache error functions ddaney
2008-10-24  0:56 ` [PATCH 21/37] Cavium OCTEON: Add cop2/cvmseg state entries to processor.h ddaney
2008-10-24  0:56 ` [PATCH 22/37] Add Cavium OCTEON specific registers to ptrace.h and asm-offsets.c ddaney
2008-10-24  0:56 ` [PATCH 23/37] Add SMP_ICACHE_FLUSH for the Cavium CPU family ddaney
2008-10-24  0:56 ` [PATCH 24/37] Cavium OCTEON: PT vs MFC0 reorder, multiplier state preservation ddaney
2008-10-24  0:56 ` [PATCH 25/37] Add Cavium OCTEON irq hazard in asmmacro.h ddaney
2008-10-24  0:56 ` [PATCH 26/37] Compute branch returns for Cavium OCTEON specific branch instructions ddaney
2008-10-24  0:56 ` [PATCH 27/37] Add Cavium OCTEON slot into proper tlb category ddaney
2008-10-24  0:56 ` [PATCH 28/37] Cavium OCTEON FPU EMU exception as TLB exception ddaney
2008-10-24 10:39   ` Sergei Shtylyov
2008-10-24 13:11     ` Paul Gortmaker
2008-10-24 17:01     ` David Daney [this message]
2008-10-24  0:56 ` [PATCH 29/37] Don't clobber spinlocks in 8250 ddaney
2008-10-24 20:12   ` Maciej W. Rozycki
2008-10-24 20:16     ` David Daney
2008-10-24  0:56 ` [PATCH 30/37] Generic 8250 serial driver changes to support future OCTEON serial patches ddaney
2008-10-24  0:56 ` [PATCH 31/37] Allow port type to be specified when calling serial8250_register_port ddaney
2008-10-24  0:56 ` [PATCH 32/37] Allow port type to specify bugs that are not probed for ddaney
2008-10-24  0:56 ` [PATCH 33/37] 8250 serial driver changes for Cavium OCTEON ddaney
2008-10-24  0:56 ` [PATCH 34/37] Adjust the dma-common.c platform hooks ddaney
2008-10-24  0:56 ` [PATCH 35/37] Set c0 status for ST0_KX on Cavium OCTEON ddaney
2008-10-26 12:48   ` Ralf Baechle
2008-10-27  1:33     ` Chad Reese
2008-10-26 18:51       ` Maciej W. Rozycki
2008-10-26 22:33       ` Ralf Baechle
2008-10-24  0:57 ` [PATCH 36/37] Cavium OCTEON: pmd_none - use pmd_val() in pmd_val() ddaney
2008-10-24 13:00   ` Paul Gortmaker
2008-10-24 15:55     ` David Daney
2008-10-24 15:12   ` Sergei Shtylyov
2008-10-24  0:57 ` [PATCH 37/37] Add defconfig for Cavium OCTEON ddaney

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4901FF61.4040907@caviumnetworks.com \
    --to=ddaney@caviumnetworks.com \
    --cc=Paul.Gortmaker@windriver.com \
    --cc=linux-mips@linux-mips.org \
    --cc=sshtylyov@ru.mvista.com \
    --cc=tpaoletti@caviumnetworks.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox