> Von: David Laight [david.lai...@aculab.com]
> Gesendet: Mittwoch, 25. Februar 2015 13:01
> An: Markus Stockhausen; linux-cry...@vger.kernel.org
> Cc: linuxppc-dev@lists.ozlabs.org
> Betreff: RE: [PATCH v1 1/3] SHA1 for PPC/SPE - assembler
> 
> From: Markus Stockhausen
> > [PATCH v1 1/3] SHA1 for PPC/SPE - assembler
> >
> > This is the assembler code for SHA1 implementation with
> > the SIMD SPE instruction set. With the enhanced instruction
> > set we can operate on 2 32 bit words in parallel. That helps
> > reducing the time to calculate W16-W79. For increasing
> > performance even more the assembler function can compute
> > hashes for more than one 64 byte input block.
> >
> > The state of the used SPE registers is preserved via the
> > stack so we can run from interrupt context
> 
> Does the ppc use the same kind of delayed state save for the SPE
> resisters that x86 uses (at least on the BSDs) for its FP (etc) regs.
> 
> That would mean that the registers might contain values for
> a different process, and that the cpu could receive an IPI
> requesting they be written to the processes normal save area
> so that they can be reloaded onto a different cpu.

Indeed SPE registers are lazy switched. enable_kernel_spe()
will take care of that. Additionally I had some discussions about 
interrupt context and its limitations. So

1) I implemented register saving in all patches (see AES & SHA256). 
This is because I know which registers I will overwrite. One should 
remember that SPE registers are shared with normal registers. So 
no big impact to save 32 bit or 64 bit of the non-volatile PPC 
registers.

2) And used disabling of preemption. But in contrast to other 
crypto algorithm implementations only for reasonable time intervals 

Markus
****************************************************************************
Diese E-Mail enthält vertrauliche und/oder rechtlich geschützte
Informationen. Wenn Sie nicht der richtige Adressat sind oder diese E-Mail
irrtümlich erhalten haben, informieren Sie bitte sofort den Absender und
vernichten Sie diese Mail. Das unerlaubte Kopieren sowie die unbefugte
Weitergabe dieser Mail ist nicht gestattet.

Über das Internet versandte E-Mails können unter fremden Namen erstellt oder
manipuliert werden. Deshalb ist diese als E-Mail verschickte Nachricht keine
rechtsverbindliche Willenserklärung.

Collogia
Unternehmensberatung AG
Ubierring 11
D-50678 Köln

Vorstand:
Kadir Akin
Dr. Michael Höhnerbach

Vorsitzender des Aufsichtsrates:
Hans Kristian Langva

Registergericht: Amtsgericht Köln
Registernummer: HRB 52 497

This e-mail may contain confidential and/or privileged information. If you
are not the intended recipient (or have received this e-mail in error)
please notify the sender immediately and destroy this e-mail. Any
unauthorized copying, disclosure or distribution of the material in this
e-mail is strictly forbidden.

e-mails sent over the internet may have been written under a wrong name or
been manipulated. That is why this message sent as an e-mail is not a
legally binding declaration of intention.

Collogia
Unternehmensberatung AG
Ubierring 11
D-50678 Köln

executive board:
Kadir Akin
Dr. Michael Höhnerbach

President of the supervisory board:
Hans Kristian Langva

Registry office: district court Cologne
Register number: HRB 52 497

****************************************************************************
_______________________________________________
Linuxppc-dev mailing list
Linuxppc-dev@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/linuxppc-dev

Reply via email to