09 Aug, 2016

1 commit

  • Since 6de62f15b581 ("crypto: algif_hash - Require setkey before
    accept(2)"), the AF_ALG interface requires userspace to provide a key
    to any algorithm that has a setkey method. However, the non-HMAC
    algorithms are not keyed, so setting a key is unnecessary.

    Fix this by removing the setkey method from the non-keyed hash
    algorithms.

    Fixes: 6de62f15b581 ("crypto: algif_hash - Require setkey before accept(2)")
    Cc:
    Signed-off-by: Russell King
    Signed-off-by: Herbert Xu

    Russell King
     

08 Aug, 2016

2 commits

  • To be able to generate shared descriptors for AEAD, the authentication size
    needs to be known. However, there is no imposed order of calling .setkey,
    .setauthsize callbacks.

    Thus, in case authentication size is not known at .setkey time, defer it
    until .setauthsize is called.

    The authsize != 0 check was incorrectly removed when converting the driver
    to the new AEAD interface.

    Cc: # 4.3+
    Fixes: 479bcc7c5b9e ("crypto: caam - Convert authenc to new AEAD interface")
    Signed-off-by: Horia Geantă
    Signed-off-by: Herbert Xu

    Horia Geantă
     
  • There are a few things missed by the conversion to the
    new AEAD interface:

    1 - echainiv(authenc) encrypt shared descriptor

    The shared descriptor is incorrect: due to the order of operations,
    at some point in time MATH3 register is being overwritten.

    2 - buffer used for echainiv(authenc) encrypt shared descriptor

    Encrypt and givencrypt shared descriptors (for AEAD ops) are mutually
    exclusive and thus use the same buffer in context state: sh_desc_enc.

    However, there's one place missed by s/sh_desc_givenc/sh_desc_enc,
    leading to errors when echainiv(authenc(...)) algorithms are used:
    DECO: desc idx 14: Header Error. Invalid length or parity, or
    certain other problems.

    While here, also fix a typo: dma_mapping_error() is checking
    for validity of sh_desc_givenc_dma instead of sh_desc_enc_dma.

    Cc: # 4.3+
    Fixes: 479bcc7c5b9e ("crypto: caam - Convert authenc to new AEAD interface")
    Signed-off-by: Horia Geantă
    Signed-off-by: Herbert Xu

    Horia Geantă
     

02 Aug, 2016

1 commit

  • Pull crypto fixes from Herbert Xu:
    "This fixes a number of regressions in the marvell cesa driver caused
    by the chaining work, and a regression in lib/mpi that leads to a
    GFP_KERNEL allocation with preemption disabled"

    * 'linus' of git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6:
    crypto: marvell - Don't copy IV vectors from the _process op for ciphers
    lib/mpi: Fix SG miter leak
    crypto: marvell - Update cache with input sg only when it is unmapped
    crypto: marvell - Don't chain at DMA level when backlog is disabled
    crypto: marvell - Fix memory leaks in TDMA chain for cipher requests

    Linus Torvalds
     

31 Jul, 2016

1 commit

  • Pull powerpc updates from Michael Ellerman:
    "Highlights:
    - PowerNV PCI hotplug support.
    - Lots more Power9 support.
    - eBPF JIT support on ppc64le.
    - Lots of cxl updates.
    - Boot code consolidation.

    Bug fixes:
    - Fix spin_unlock_wait() from Boqun Feng
    - Fix stack pointer corruption in __tm_recheckpoint() from Michael
    Neuling
    - Fix multiple bugs in memory_hotplug_max() from Bharata B Rao
    - mm: Ensure "special" zones are empty from Oliver O'Halloran
    - ftrace: Separate the heuristics for checking call sites from
    Michael Ellerman
    - modules: Never restore r2 for a mprofile-kernel style mcount() call
    from Michael Ellerman
    - Fix endianness when reading TCEs from Alexey Kardashevskiy
    - start rtasd before PCI probing from Greg Kurz
    - PCI: rpaphp: Fix slot registration for multiple slots under a PHB
    from Tyrel Datwyler
    - powerpc/mm: Add memory barrier in __hugepte_alloc() from Sukadev
    Bhattiprolu

    Cleanups & fixes:
    - Drop support for MPIC in pseries from Rashmica Gupta
    - Define and use PPC64_ELF_ABI_v2/v1 from Michael Ellerman
    - Remove unused symbols in asm-offsets.c from Rashmica Gupta
    - Fix SRIOV not building without EEH enabled from Russell Currey
    - Remove kretprobe_trampoline_holder from Thiago Jung Bauermann
    - Reduce log level of PCI I/O space warning from Benjamin
    Herrenschmidt
    - Add array bounds checking to crash_shutdown_handlers from Suraj
    Jitindar Singh
    - Avoid -maltivec when using clang integrated assembler from Anton
    Blanchard
    - Fix array overrun in ppc_rtas() syscall from Andrew Donnellan
    - Fix error return value in cmm_mem_going_offline() from Rasmus
    Villemoes
    - export cpu_to_core_id() from Mauricio Faria de Oliveira
    - Remove old symbols from defconfigs from Andrew Donnellan
    - Update obsolete comments in setup_32.c about entry conditions from
    Benjamin Herrenschmidt
    - Add comment explaining the purpose of setup_kdump_trampoline() from
    Benjamin Herrenschmidt
    - Merge the RELOCATABLE config entries for ppc32 and ppc64 from Kevin
    Hao
    - Remove RELOCATABLE_PPC32 from Kevin Hao
    - Fix .long's in tlb-radix.c to more meaningful from Balbir Singh

    Minor cleanups & fixes:
    - Andrew Donnellan, Anna-Maria Gleixner, Anton Blanchard, Benjamin
    Herrenschmidt, Bharata B Rao, Christophe Leroy, Colin Ian King,
    Geliang Tang, Greg Kurz, Madhavan Srinivasan, Michael Ellerman,
    Michael Ellerman, Stephen Rothwell, Stewart Smith.

    Freescale updates from Scott:
    - "Highlights include more 8xx optimizations, device tree updates,
    and MVME7100 support."

    PowerNV PCI hotplug from Gavin Shan:
    - PCI: Add pcibios_setup_bridge()
    - Override pcibios_setup_bridge()
    - Remove PCI_RESET_DELAY_US
    - Move pnv_pci_ioda_setup_opal_tce_kill() around
    - Increase PE# capacity
    - Allocate PE# in reverse order
    - Create PEs in pcibios_setup_bridge()
    - Setup PE for root bus
    - Extend PCI bridge resources
    - Make pnv_ioda_deconfigure_pe() visible
    - Dynamically release PE
    - Update bridge windows on PCI plug
    - Delay populating pdn
    - Support PCI slot ID
    - Use PCI slot reset infrastructure
    - Introduce pnv_pci_get_slot_id()
    - Functions to get/set PCI slot state
    - PCI/hotplug: PowerPC PowerNV PCI hotplug driver
    - Print correct PHB type names

    Power9 idle support from Shreyas B. Prabhu:
    - set power_save func after the idle states are initialized
    - Use PNV_THREAD_WINKLE macro while requesting for winkle
    - make hypervisor state restore a function
    - Rename idle_power7.S to idle_book3s.S
    - Rename reusable idle functions to hardware agnostic names
    - Make pnv_powersave_common more generic
    - abstraction for saving SPRs before entering deep idle states
    - Add platform support for stop instruction
    - cpuidle/powernv: Use CPUIDLE_STATE_MAX instead of MAX_POWERNV_IDLE_STATES
    - cpuidle/powernv: cleanup cpuidle-powernv.c
    - cpuidle/powernv: Add support for POWER ISA v3 idle states
    - Use deepest stop state when cpu is offlined

    Power9 PMU from Madhavan Srinivasan:
    - factor out power8 pmu macros and defines
    - factor out power8 pmu functions
    - factor out power8 __init_pmu code
    - Add power9 event list macros for generic and cache events
    - Power9 PMU support
    - Export Power9 generic and cache events to sysfs

    Power9 preliminary interrupt & PCI support from Benjamin Herrenschmidt:
    - Add XICS emulation APIs
    - Move a few exception common handlers to make room
    - Add support for HV virtualization interrupts
    - Add mechanism to force a replay of interrupts
    - Add ICP OPAL backend
    - Discover IODA3 PHBs
    - pci: Remove obsolete SW invalidate
    - opal: Add real mode call wrappers
    - Rename TCE invalidation calls
    - Remove SWINV constants and obsolete TCE code
    - Rework accessing the TCE invalidate register
    - Fallback to OPAL for TCE invalidations
    - Use the device-tree to get available range of M64's
    - Check status of a PHB before using it
    - pci: Don't try to allocate resources that will be reassigned

    Other Power9:
    - Send SIGBUS on unaligned copy and paste from Chris Smart
    - Large Decrementer support from Oliver O'Halloran
    - Load Monitor Register Support from Jack Miller

    Performance improvements from Anton Blanchard:
    - Avoid load hit store in __giveup_fpu() and __giveup_altivec()
    - Avoid load hit store in setup_sigcontext()
    - Remove assembly versions of strcpy, strcat, strlen and strcmp
    - Align hot loops of some string functions

    eBPF JIT from Naveen N. Rao:
    - Fix/enhance 32-bit Load Immediate implementation
    - Optimize 64-bit Immediate loads
    - Introduce rotate immediate instructions
    - A few cleanups
    - Isolate classic BPF JIT specifics into a separate header
    - Implement JIT compiler for extended BPF

    Operator Panel driver from Suraj Jitindar Singh:
    - devicetree/bindings: Add binding for operator panel on FSP machines
    - Add inline function to get rc from an ASYNC_COMP opal_msg
    - Add driver for operator panel on FSP machines

    Sparse fixes from Daniel Axtens:
    - make some things static
    - Introduce asm-prototypes.h
    - Include headers containing prototypes
    - Use #ifdef __BIG_ENDIAN__ #else for REG_BYTE
    - kvm: Clarify __user annotations
    - Pass endianness to sparse
    - Make ppc_md.{halt, restart} __noreturn

    MM fixes & cleanups from Aneesh Kumar K.V:
    - radix: Update LPCR HR bit as per ISA
    - use _raw variant of page table accessors
    - Compile out radix related functions if RADIX_MMU is disabled
    - Clear top 16 bits of va only on older cpus
    - Print formation regarding the the MMU mode
    - hash: Update SDR1 size encoding as documented in ISA 3.0
    - radix: Update PID switch sequence
    - radix: Update machine call back to support new HCALL.
    - radix: Add LPID based tlb flush helpers
    - radix: Add a kernel command line to disable radix
    - Cleanup LPCR defines

    Boot code consolidation from Benjamin Herrenschmidt:
    - Move epapr_paravirt_early_init() to early_init_devtree()
    - cell: Don't use flat device-tree after boot
    - ge_imp3a: Don't use the flat device-tree after boot
    - mpc85xx_ds: Don't use the flat device-tree after boot
    - mpc85xx_rdb: Don't use the flat device-tree after boot
    - Don't test for machine type in rtas_initialize()
    - Don't test for machine type in smp_setup_cpu_maps()
    - dt: Add of_device_compatible_match()
    - Factor do_feature_fixup calls
    - Move 64-bit feature fixup earlier
    - Move 64-bit memory reserves to setup_arch()
    - Use a cachable DART
    - Move FW feature probing out of pseries probe()
    - Put exception configuration in a common place
    - Remove early allocation of the SMU command buffer
    - Move MMU backend selection out of platform code
    - pasemi: Remove IOBMAP allocation from platform probe()
    - mm/hash: Don't use machine_is() early during boot
    - Don't test for machine type to detect HEA special case
    - pmac: Remove spurrious machine type test
    - Move hash table ops to a separate structure
    - Ensure that ppc_md is empty before probing for machine type
    - Move 64-bit probe_machine() to later in the boot process
    - Move 32-bit probe() machine to later in the boot process
    - Get rid of ppc_md.init_early()
    - Move the boot time info banner to a separate function
    - Move setting of {i,d}cache_bsize to initialize_cache_info()
    - Move the content of setup_system() to setup_arch()
    - Move cache info inits to a separate function
    - Re-order the call to smp_setup_cpu_maps()
    - Re-order setup_panic()
    - Make a few boot functions __init
    - Merge 32-bit and 64-bit setup_arch()

    Other new features:
    - tty/hvc: Use IRQF_SHARED for OPAL hvc consoles from Sam Mendoza-Jonas
    - tty/hvc: Use opal irqchip interface if available from Sam Mendoza-Jonas
    - powerpc: Add module autoloading based on CPU features from Alastair D'Silva
    - crypto: vmx - Convert to CPU feature based module autoloading from Alastair D'Silva
    - Wake up kopald polling thread before waiting for events from Benjamin Herrenschmidt
    - xmon: Dump ISA 2.06 SPRs from Michael Ellerman
    - xmon: Dump ISA 2.07 SPRs from Michael Ellerman
    - Add a parameter to disable 1TB segs from Oliver O'Halloran
    - powerpc/boot: Add OPAL console to epapr wrappers from Oliver O'Halloran
    - Assign fixed PHB number based on device-tree properties from Guilherme G. Piccoli
    - pseries: Add pseries hotplug workqueue from John Allen
    - pseries: Add support for hotplug interrupt source from John Allen
    - pseries: Use kernel hotplug queue for PowerVM hotplug events from John Allen
    - pseries: Move property cloning into its own routine from Nathan Fontenot
    - pseries: Dynamic add entires to associativity lookup array from Nathan Fontenot
    - pseries: Auto-online hotplugged memory from Nathan Fontenot
    - pseries: Remove call to memblock_add() from Nathan Fontenot

    cxl:
    - Add set and get private data to context struct from Michael Neuling
    - make base more explicitly non-modular from Paul Gortmaker
    - Use for_each_compatible_node() macro from Wei Yongjun
    - Frederic Barrat
    - Abstract the differences between the PSL and XSL
    - Make vPHB device node match adapter's
    - Philippe Bergheaud
    - Add mechanism for delivering AFU driver specific events
    - Ignore CAPI adapters misplaced in switched slots
    - Refine slice error debug messages
    - Andrew Donnellan
    - static-ify variables to fix sparse warnings
    - PCI/hotplug: pnv_php: export symbols and move struct types needed by cxl
    - PCI/hotplug: pnv_php: handle OPAL_PCI_SLOT_OFFLINE power state
    - Add cxl_check_and_switch_mode() API to switch bi-modal cards
    - remove dead Kconfig options
    - fix potential NULL dereference in free_adapter()
    - Ian Munsie
    - Update process element after allocating interrupts
    - Add support for CAPP DMA mode
    - Fix allowing bogus AFU descriptors with 0 maximum processes
    - Fix allocating a minimum of 2 pages for the SPA
    - Fix bug where AFU disable operation had no effect
    - Workaround XSL bug that does not clear the RA bit after a reset
    - Fix NULL pointer dereference on kernel contexts with no AFU interrupts
    - powerpc/powernv: Split cxl code out into a separate file
    - Add cxl_slot_is_supported API
    - Enable bus mastering for devices using CAPP DMA mode
    - Move cxl_afu_get / cxl_afu_put to base
    - Allow a default context to be associated with an external pci_dev
    - Do not create vPHB if there are no AFU configuration records
    - powerpc/powernv: Add support for the cxl kernel api on the real phb
    - Add support for using the kernel API with a real PHB
    - Add kernel APIs to get & set the max irqs per context
    - Add preliminary workaround for CX4 interrupt limitation
    - Add support for interrupts on the Mellanox CX4
    - Workaround PE=0 hardware limitation in Mellanox CX4
    - powerpc/powernv: Fix pci-cxl.c build when CONFIG_MODULES=n

    selftests:
    - Test unaligned copy and paste from Chris Smart
    - Load Monitor Register Tests from Jack Miller
    - Cyril Bur
    - exec() with suspended transaction
    - Use signed long to read perf_event_paranoid
    - Fix usage message in context_switch
    - Fix generation of vector instructions/types in context_switch
    - Michael Ellerman
    - Use "Delta" rather than "Error" in normal output
    - Import Anton's mmap & futex micro benchmarks
    - Add a test for PROT_SAO"

    * tag 'powerpc-4.8-1' of git://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux: (263 commits)
    powerpc/mm: Parenthesise IS_ENABLED() in if condition
    tty/hvc: Use opal irqchip interface if available
    tty/hvc: Use IRQF_SHARED for OPAL hvc consoles
    selftests/powerpc: exec() with suspended transaction
    powerpc: Improve comment explaining why we modify VRSAVE
    powerpc/mm: Drop unused externs for hpte_init_beat[_v3]()
    powerpc/mm: Rename hpte_init_lpar() and move the fallback to a header
    powerpc/mm: Fix build break when PPC_NATIVE=n
    crypto: vmx - Convert to CPU feature based module autoloading
    powerpc: Add module autoloading based on CPU features
    powerpc/powernv/ioda: Fix endianness when reading TCEs
    powerpc/mm: Add memory barrier in __hugepte_alloc()
    powerpc/modules: Never restore r2 for a mprofile-kernel style mcount() call
    powerpc/ftrace: Separate the heuristics for checking call sites
    powerpc: Merge 32-bit and 64-bit setup_arch()
    powerpc/64: Make a few boot functions __init
    powerpc: Re-order setup_panic()
    powerpc: Re-order the call to smp_setup_cpu_maps()
    powerpc/32: Move cache info inits to a separate function
    powerpc/64: Move the content of setup_system() to setup_arch()
    ...

    Linus Torvalds
     

29 Jul, 2016

1 commit

  • The IV output vectors should only be copied from the _complete operation
    and not from the _process operation, i.e only from the operation that is
    designed to copy the result of the request to the right location. This
    copy is already done in the _complete operation, so this commit removes
    the duplicated code in the _process op.

    Fixes: 3610d6cd5231 ("crypto: marvell - Add a complete...")
    Signed-off-by: Romain Perier
    Acked-by: Boris Brezillon
    Signed-off-by: Herbert Xu

    Romain Perier
     

28 Jul, 2016

3 commits

  • So far, the cache of the ahash requests was updated from the 'complete'
    operation. This complete operation is called from mv_cesa_tdma_process
    before the cleanup operation, which means that the content of req->src
    can be read and copied when it is still mapped. This commit fixes the
    issue by moving this cache update from mv_cesa_ahash_complete to
    mv_cesa_ahash_req_cleanup, so the copy is done once the sglist is
    unmapped.

    Fixes: 1bf6682cb31d ("crypto: marvell - Add a complete operation for..")
    Signed-off-by: Romain Perier
    Acked-by: Boris Brezillon
    Signed-off-by: Herbert Xu

    Romain Perier
     
  • The flag CRYPTO_TFM_REQ_MAY_BACKLOG is optional and can be set from the
    user to put requests into the backlog queue when the main cryptographic
    queue is full. Before calling mv_cesa_tdma_chain we must check the value
    of the return status to be sure that the current request has been
    correctly queued or added to the backlog.

    Fixes: 85030c5168f1 ("crypto: marvell - Add support for chaining...")
    Signed-off-by: Romain Perier
    Acked-by: Boris Brezillon
    Signed-off-by: Herbert Xu

    Romain Perier
     
  • So far in mv_cesa_ablkcipher_dma_req_init, if an error is thrown while
    the tdma chain is built there is a memory leak. This issue exists
    because the chain is assigned later at the end of the function, so the
    cleanup function is called with the wrong version of the chain.

    Fixes: db509a45339f ("crypto: marvell/cesa - add TDMA support")
    Signed-off-by: Romain Perier
    Acked-by: Boris Brezillon
    Signed-off-by: Herbert Xu

    Romain Perier
     

27 Jul, 2016

2 commits

  • Pull crypto updates from Herbert Xu:
    "Here is the crypto update for 4.8:

    API:
    - first part of skcipher low-level conversions
    - add KPP (Key-agreement Protocol Primitives) interface.

    Algorithms:
    - fix IPsec/cryptd reordering issues that affects aesni
    - RSA no longer does explicit leading zero removal
    - add SHA3
    - add DH
    - add ECDH
    - improve DRBG performance by not doing CTR by hand

    Drivers:
    - add x86 AVX2 multibuffer SHA256/512
    - add POWER8 optimised crc32c
    - add xts support to vmx
    - add DH support to qat
    - add RSA support to caam
    - add Layerscape support to caam
    - add SEC1 AEAD support to talitos
    - improve performance by chaining requests in marvell/cesa
    - add support for Araneus Alea I USB RNG
    - add support for Broadcom BCM5301 RNG
    - add support for Amlogic Meson RNG
    - add support Broadcom NSP SoC RNG"

    * 'linus' of git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6: (180 commits)
    crypto: vmx - Fix aes_p8_xts_decrypt build failure
    crypto: vmx - Ignore generated files
    crypto: vmx - Adding support for XTS
    crypto: vmx - Adding asm subroutines for XTS
    crypto: skcipher - add comment for skcipher_alg->base
    crypto: testmgr - Print akcipher algorithm name
    crypto: marvell - Fix wrong flag used for GFP in mv_cesa_dma_add_iv_op
    crypto: nx - off by one bug in nx_of_update_msc()
    crypto: rsa-pkcs1pad - fix rsa-pkcs1pad request struct
    crypto: scatterwalk - Inline start/map/done
    crypto: scatterwalk - Remove unnecessary BUG in scatterwalk_start
    crypto: scatterwalk - Remove unnecessary advance in scatterwalk_pagedone
    crypto: scatterwalk - Fix test in scatterwalk_done
    crypto: api - Optimise away crypto_yield when hard preemption is on
    crypto: scatterwalk - add no-copy support to copychunks
    crypto: scatterwalk - Remove scatterwalk_bytes_sglen
    crypto: omap - Stop using crypto scatterwalk_bytes_sglen
    crypto: skcipher - Remove top-level givcipher interface
    crypto: user - Remove crypto_lookup_skcipher call
    crypto: cts - Convert to skcipher
    ...

    Linus Torvalds
     
  • Pull s390 updates from Martin Schwidefsky:
    "There are a couple of new things for s390 with this merge request:

    - a new scheduling domain "drawer" is added to reflect the unusual
    topology found on z13 machines. Performance tests showed up to 8
    percent gain with the additional domain.

    - the new crc-32 checksum crypto module uses the vector-galois-field
    multiply and sum SIMD instruction to speed up crc-32 and crc-32c.

    - proper __ro_after_init support, this requires RO_AFTER_INIT_DATA in
    the generic vmlinux.lds linker script definitions.

    - kcov instrumentation support. A prerequisite for that is the
    inline assembly basic block cleanup, which is the reason for the
    net/iucv/iucv.c change.

    - support for 2GB pages is added to the hugetlbfs backend.

    Then there are two removals:

    - the oprofile hardware sampling support is dead code and is removed.
    The oprofile user space uses the perf interface nowadays.

    - the ETR clock synchronization is removed, this has been superseeded
    be the STP clock synchronization. And it always has been
    "interesting" code..

    And the usual bug fixes and cleanups"

    * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/s390/linux: (82 commits)
    s390/pci: Delete an unnecessary check before the function call "pci_dev_put"
    s390/smp: clean up a condition
    s390/cio/chp : Remove deprecated create_singlethread_workqueue
    s390/chsc: improve channel path descriptor determination
    s390/chsc: sanitize fmt check for chp_desc determination
    s390/cio: make fmt1 channel path descriptor optional
    s390/chsc: fix ioctl CHSC_INFO_CU command
    s390/cio/device_ops: fix kernel doc
    s390/cio: allow to reset channel measurement block
    s390/console: Make preferred console handling more consistent
    s390/mm: fix gmap tlb flush issues
    s390/mm: add support for 2GB hugepages
    s390: have unique symbol for __switch_to address
    s390/cpuinfo: show maximum thread id
    s390/ptrace: clarify bits in the per_struct
    s390: stack address vs thread_info
    s390: remove pointless load within __switch_to
    s390: enable kcov support
    s390/cpumf: use basic block for ecctr inline assembly
    s390/hypfs: use basic block for diag inline assembly
    ...

    Linus Torvalds
     

21 Jul, 2016

3 commits


20 Jul, 2016

2 commits


19 Jul, 2016

4 commits


18 Jul, 2016

1 commit


11 Jul, 2016

2 commits


05 Jul, 2016

5 commits


01 Jul, 2016

6 commits


28 Jun, 2016

1 commit

  • The ARM allmodconfig build currently warngs because of the
    ux500 crypto driver not working well with the jump label
    implementation that we started using for dynamic debug, which
    breaks building with 'gcc -O0':

    In file included from /git/arm-soc/include/linux/jump_label.h:105:0,
    from /git/arm-soc/include/linux/dynamic_debug.h:5,
    from /git/arm-soc/include/linux/printk.h:289,
    from /git/arm-soc/include/linux/kernel.h:13,
    from /git/arm-soc/include/linux/clk.h:16,
    from /git/arm-soc/drivers/crypto/ux500/hash/hash_core.c:16:
    /git/arm-soc/arch/arm/include/asm/jump_label.h: In function 'hash_set_dma_transfer':
    /git/arm-soc/arch/arm/include/asm/jump_label.h:13:7: error: asm operand 0 probably doesn't match constraints [-Werror]
    asm_volatile_goto("1:\n\t"

    Turning off compiler optimizations has never really been supported
    here, and it's only used when debugging the driver. I have not found
    a good reason for doing this here, other than a misguided attempt
    to produce more readable assembly output. Also, the driver is only
    used in obsolete hardware that almost certainly nobody will spend
    time debugging any more.

    This just removes the -O0 flag from the compiler options.

    Signed-off-by: Arnd Bergmann
    Signed-off-by: Herbert Xu

    Arnd Bergmann
     

24 Jun, 2016

4 commits

  • Adds software fallback support for small crypto requests. In these cases,
    it is undesirable to use DMA, as setting it up itself is rather heavy
    operation. Gives about 40% extra performance in ipsec usecase.

    Signed-off-by: Bin Liu
    [t-kristo@ti.com: dropped the extra traces, updated some comments
    on the code]
    Signed-off-by: Tero Kristo
    Signed-off-by: Herbert Xu

    Bin Liu
     
  • The extra call to dmaengine_terminate_all is not needed, as the DMA
    is not running at this point. This improves performance slightly.

    Signed-off-by: Lokesh Vutla
    Signed-off-by: Tero Kristo
    Signed-off-by: Herbert Xu

    Lokesh Vutla
     
  • Change crypto queue size from 1 to 10 for omap SHA driver. This should
    allow clients to enqueue requests more effectively to avoid serializing
    whole crypto sequences, giving extra performance.

    Signed-off-by: Tero Kristo
    Signed-off-by: Herbert Xu

    Tero Kristo
     
  • Calling runtime PM API for every block causes serious performance hit to
    crypto operations that are done on a long buffer. As crypto is performed
    on a page boundary, encrypting large buffers can cause a series of crypto
    operations divided by page. The runtime PM API is also called those many
    times.

    Convert the driver to use runtime_pm autosuspend instead, with a default
    timeout value of 1 second. This results in upto ~50% speedup.

    Signed-off-by: Tero Kristo
    Signed-off-by: Herbert Xu

    Tero Kristo
     

23 Jun, 2016

1 commit

  • Now that crypto requests are chained together at the DMA level, we
    increase the size of the crypto queue for each engine. The result is
    that as the backlog list is reached later, it does not stop the crypto
    stack from sending asychronous requests, so more cryptographic tasks
    are processed by the engines.

    Signed-off-by: Romain Perier
    Acked-by: Boris Brezillon
    Signed-off-by: Herbert Xu

    Romain Perier