07 Aug, 2011

1 commit


27 Jul, 2011

1 commit

  • This allows us to move duplicated code in
    (atomic_inc_not_zero() for now) to

    Signed-off-by: Arun Sharma
    Reviewed-by: Eric Dumazet
    Cc: Ingo Molnar
    Cc: David Miller
    Cc: Eric Dumazet
    Acked-by: Mike Frysinger
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Arun Sharma
     

26 Jul, 2011

1 commit

  • * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial: (43 commits)
    fs: Merge split strings
    treewide: fix potentially dangerous trailing ';' in #defined values/expressions
    uwb: Fix misspelling of neighbourhood in comment
    net, netfilter: Remove redundant goto in ebt_ulog_packet
    trivial: don't touch files that are removed in the staging tree
    lib/vsprintf: replace link to Draft by final RFC number
    doc: Kconfig: `to be' -> `be'
    doc: Kconfig: Typo: square -> squared
    doc: Konfig: Documentation/power/{pm => apm-acpi}.txt
    drivers/net: static should be at beginning of declaration
    drivers/media: static should be at beginning of declaration
    drivers/i2c: static should be at beginning of declaration
    XTENSA: static should be at beginning of declaration
    SH: static should be at beginning of declaration
    MIPS: static should be at beginning of declaration
    ARM: static should be at beginning of declaration
    rcu: treewide: Do not use rcu_read_lock_held when calling rcu_dereference_check
    Update my e-mail address
    PCIe ASPM: forcedly -> forcibly
    gma500: push through device driver tree
    ...

    Fix up trivial conflicts:
    - arch/arm/mach-ep93xx/dma-m2p.c (deleted)
    - drivers/gpio/gpio-ep93xx.c (renamed and context nearby)
    - drivers/net/r8169.c (just context changes)

    Linus Torvalds
     

25 Jul, 2011

1 commit

  • * git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6: (34 commits)
    crypto: caam - ablkcipher support
    crypto: caam - faster aead implementation
    crypto: caam - structure renaming
    crypto: caam - shorter names
    crypto: talitos - don't bad_key in ablkcipher setkey
    crypto: talitos - remove unused giv from ablkcipher methods
    crypto: talitos - don't set done notification in hot path
    crypto: talitos - ensure request ordering within a single tfm
    crypto: gf128mul - fix call to memset()
    crypto: s390 - support hardware accelerated SHA-224
    crypto: algif_hash - Handle initial af_alg_make_sg error correctly
    crypto: sha1_generic - use SHA1_BLOCK_SIZE
    hwrng: ppc4xx - add support for ppc4xx TRNG
    crypto: crypto4xx - Perform read/modify/write on device control register
    crypto: caam - fix build warning when DEBUG_FS not configured
    crypto: arc4 - Fixed coding style issues
    crypto: crc32c - Fixed coding style issue
    crypto: omap-sham - do not schedule tasklet if there is no active requests
    crypto: omap-sham - clear device flags when finishing request
    crypto: omap-sham - irq handler must not clear error code
    ...

    Linus Torvalds
     

11 Jul, 2011

1 commit


08 Jul, 2011

1 commit

  • In gf128mul_lle() and gf128mul_bbe() r isn't completely initialized with
    zero because the size argument passed to memset() is the size of the
    pointer, not the structure it points to.

    Luckily there are no in-kernel users of those functions so the ABI
    change implied by this fix should break no existing code.

    Based on a patch by the PaX Team.

    Signed-off-by: Mathias Krause
    Cc: PaX Team
    Acked-by: David S. Miller
    Signed-off-by: Herbert Xu

    Mathias Krause
     

06 Jul, 2011

1 commit


30 Jun, 2011

6 commits


29 Jun, 2011

1 commit


22 Jun, 2011

1 commit

  • Remove linux/mm.h inclusion from netdevice.h -- it's unused (I've checked manually).

    To prevent mm.h inclusion via other channels also extract "enum dma_data_direction"
    definition into separate header. This tiny piece is what gluing netdevice.h with mm.h
    via "netdevice.h => dmaengine.h => dma-mapping.h => scatterlist.h => mm.h".
    Removal of mm.h from scatterlist.h was tried and was found not feasible
    on most archs, so the link was cutoff earlier.

    Hope people are OK with tiny include file.

    Note, that mm_types.h is still dragged in, but it is a separate story.

    Signed-off-by: Alexey Dobriyan
    Signed-off-by: David S. Miller

    Alexey Dobriyan
     

21 May, 2011

1 commit

  • * git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6: (45 commits)
    crypto: caam - add support for sha512 variants of existing AEAD algorithms
    crypto: caam - remove unused authkeylen from caam_ctx
    crypto: caam - fix decryption shared vs. non-shared key setting
    crypto: caam - platform_bus_type migration
    crypto: aesni-intel - fix aesni build on i386
    crypto: aesni-intel - Merge with fpu.ko
    crypto: mv_cesa - make count_sgs() null-pointer proof
    crypto: mv_cesa - copy remaining bytes to SRAM only when needed
    crypto: mv_cesa - move digest state initialisation to a better place
    crypto: mv_cesa - fill inner/outer IV fields only in HMAC case
    crypto: mv_cesa - refactor copy_src_to_buf()
    crypto: mv_cesa - no need to save digest state after the last chunk
    crypto: mv_cesa - print a warning when registration of AES algos fail
    crypto: mv_cesa - drop this call to mv_hash_final from mv_hash_finup
    crypto: mv_cesa - the descriptor pointer register needs to be set just once
    crypto: mv_cesa - use ablkcipher_request_cast instead of the manual container_of
    crypto: caam - fix printk recursion for long error texts
    crypto: caam - remove unused keylen from session context
    hwrng: amd - enable AMD hw rnd driver for Maple PPC boards
    hwrng: amd - manage resource allocation
    ...

    Linus Torvalds
     

16 May, 2011

1 commit

  • Loading fpu without aesni-intel does nothing. Loading aesni-intel
    without fpu causes modes like xts to fail. (Unloading
    aesni-intel will restore those modes.)

    One solution would be to make aesni-intel depend on fpu, but it
    seems cleaner to just combine the modules.

    This is probably responsible for bugs like:
    https://bugzilla.redhat.com/show_bug.cgi?id=589390

    Signed-off-by: Andy Lutomirski
    Signed-off-by: Herbert Xu

    Andy Lutomirski
     

04 May, 2011

2 commits


31 Mar, 2011

1 commit


23 Mar, 2011

1 commit

  • Instead of always creating a huge (268K) deflate_workspace with the
    maximum compression parameters (windowBits=15, memLevel=8), allow the
    caller to obtain a smaller workspace by specifying smaller parameter
    values.

    For example, when capturing oops and panic reports to a medium with
    limited capacity, such as NVRAM, compression may be the only way to
    capture the whole report. In this case, a small workspace (24K works
    fine) is a win, whether you allocate the workspace when you need it (i.e.,
    during an oops or panic) or at boot time.

    I've verified that this patch works with all accepted values of windowBits
    (positive and negative), memLevel, and compression level.

    Signed-off-by: Jim Keniston
    Cc: Herbert Xu
    Cc: David Miller
    Cc: Chris Mason
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jim Keniston
     

17 Mar, 2011

1 commit

  • * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next-2.6: (1480 commits)
    bonding: enable netpoll without checking link status
    xfrm: Refcount destination entry on xfrm_lookup
    net: introduce rx_handler results and logic around that
    bonding: get rid of IFF_SLAVE_INACTIVE netdev->priv_flag
    bonding: wrap slave state work
    net: get rid of multiple bond-related netdevice->priv_flags
    bonding: register slave pointer for rx_handler
    be2net: Bump up the version number
    be2net: Copyright notice change. Update to Emulex instead of ServerEngines
    e1000e: fix kconfig for crc32 dependency
    netfilter ebtables: fix xt_AUDIT to work with ebtables
    xen network backend driver
    bonding: Improve syslog message at device creation time
    bonding: Call netif_carrier_off after register_netdevice
    bonding: Incorrect TX queue offset
    net_sched: fix ip_tos2prio
    xfrm: fix __xfrm_route_forward()
    be2net: Fix UDP packet detected status in RX compl
    Phonet: fix aligned-mode pipe socket buffer header reserve
    netxen: support for GbE port settings
    ...

    Fix up conflicts in drivers/staging/brcm80211/brcmsmac/wl_mac80211.c
    with the staging updates.

    Linus Torvalds
     

14 Mar, 2011

1 commit


04 Mar, 2011

1 commit

  • Commit da7f033ddc9fdeb (”crypto: cryptomgr - Add test infrastructure”) added a
    const to variable which is later used as target buffer of memcpy.

    crypto/tcrypt.c:217:12: warning: passing 'const char (*)[128]' to parameter of type 'void *' discards qualifiers
    memset(&iv, 0xff, iv_len);

    crypto/tcrypt.c:test_cipher_speed()

    - unsigned char *key, iv[128];
    + const char *key, iv[128];
    ...
    memset(&iv, 0xff, iv_len);

    Signed-off-by: David Sterba
    Signed-off-by: Herbert Xu

    David Sterba
     

17 Feb, 2011

1 commit


29 Jan, 2011

3 commits

  • A self-test failure in fips mode means a panic. Well, gcm(aes)
    self-tests currently fail in fips mode, as gcm is dependent on ghash,
    which semi-recently got self-test vectors added, but wasn't marked as a
    fips_allowed algorithm. Because of gcm's dependence on what is now seen
    as a non-fips_allowed algorithm, its self-tests refuse to run.
    Previously, ghash got a pass in fips mode, due to the lack of any test
    vectors at all, and thus gcm self-tests were able to run. After this
    patch, a 'modprobe tcrypt mode=35' no longer panics in fips mode, and
    successful self-test of gcm(aes) is reported.

    Signed-off-by: Jarod Wilson
    Signed-off-by: Herbert Xu

    Jarod Wilson
     
  • We (Red Hat) are intending to include dm-crypt functionality, using
    xts(aes) for disk encryption, as part of an upcoming FIPS-140-2
    certification effort, and xts(aes) *is* on the list of possible
    mode/cipher combinations that can be certified. To make that possible, we
    need to mark xts(aes) as fips_allowed in the crypto subsystem.

    A 'modprobe tcrypt mode=10' in fips mode shows xts(aes) self-tests
    passing successfully after this change.

    Signed-off-by: Jarod Wilson
    Signed-off-by: Herbert Xu

    Jarod Wilson
     
  • Signed-off-by: Davidlohr Bueso
    Acked-by: David S. Miller
    Signed-off-by: Herbert Xu

    Davidlohr Bueso
     

14 Jan, 2011

1 commit

  • * git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6: (46 commits)
    hwrng: via_rng - Fix memory scribbling on some CPUs
    crypto: padlock - Move padlock.h into include/crypto
    hwrng: via_rng - Fix asm constraints
    crypto: n2 - use __devexit not __exit in n2_unregister_algs
    crypto: mark crypto workqueues CPU_INTENSIVE
    crypto: mv_cesa - dont return PTR_ERR() of wrong pointer
    crypto: ripemd - Set module author and update email address
    crypto: omap-sham - backlog handling fix
    crypto: gf128mul - Remove experimental tag
    crypto: af_alg - fix af_alg memory_allocated data type
    crypto: aesni-intel - Fixed build with binutils 2.16
    crypto: af_alg - Make sure sk_security is initialized on accept()ed sockets
    net: Add missing lockdep class names for af_alg
    include: Install linux/if_alg.h for user-space crypto API
    crypto: omap-aes - checkpatch --file warning fixes
    crypto: omap-aes - initialize aes module once per request
    crypto: omap-aes - unnecessary code removed
    crypto: omap-aes - error handling implementation improved
    crypto: omap-aes - redundant locking is removed
    crypto: omap-aes - DMA initialization fixes for OMAP off mode
    ...

    Linus Torvalds
     

04 Jan, 2011

2 commits


28 Dec, 2010

1 commit


21 Dec, 2010

1 commit


08 Dec, 2010

1 commit


02 Dec, 2010

1 commit


30 Nov, 2010

2 commits

  • As it is if user-space passes through a receive buffer that's not
    aligned to to the cipher block size, we'll end up encrypting or
    decrypting a partial block which causes a spurious EINVAL to be
    returned.

    This patch fixes this by moving the partial block test after the
    af_alg_make_sg call.

    Signed-off-by: Herbert Xu

    Herbert Xu
     
  • When sk_sndbuf is not a multiple of PAGE_SIZE, the limit tests
    in sendmsg fail as the limit variable becomes negative and we're
    using an unsigned comparison.

    The same thing can happen if sk_sndbuf is lowered after a sendmsg
    call.

    This patch fixes this by always taking the signed maximum of limit
    and 0 before we perform the comparison.

    It also rounds the value of sk_sndbuf down to a multiple of PAGE_SIZE
    so that we don't end up allocating a page only to use a small number
    of bytes in it because we're bound by sk_sndbuf.

    Signed-off-by: Herbert Xu

    Herbert Xu
     

29 Nov, 2010

1 commit

  • Add missing dependency on NET since we require sockets for our
    interface.

    Should really be a select but kconfig doesn't like that:

    net/Kconfig:6:error: found recursive dependency: NET -> NETWORK_FILESYSTEMS -> AFS_FS -> AF_RXRPC -> CRYPTO -> CRYPTO_USER_API_HASH -> CRYPTO_USER_API -> NET

    Reported-by: Zimny Lech
    Signed-off-by: Herbert Xu

    Herbert Xu
     

28 Nov, 2010

1 commit


27 Nov, 2010

1 commit

  • The AES-NI instructions are also available in legacy mode so the 32-bit
    architecture may profit from those, too.

    To illustrate the performance gain here's a short summary of a dm-crypt
    speed test on a Core i7 M620 running at 2.67GHz comparing both assembler
    implementations:

    x86: i568 aes-ni delta
    ECB, 256 bit: 93.8 MB/s 123.3 MB/s +31.4%
    CBC, 256 bit: 84.8 MB/s 262.3 MB/s +209.3%
    LRW, 256 bit: 108.6 MB/s 222.1 MB/s +104.5%
    XTS, 256 bit: 105.0 MB/s 205.5 MB/s +95.7%

    Additionally, due to some minor optimizations, the 64-bit version also
    got a minor performance gain as seen below:

    x86-64: old impl. new impl. delta
    ECB, 256 bit: 121.1 MB/s 123.0 MB/s +1.5%
    CBC, 256 bit: 285.3 MB/s 290.8 MB/s +1.9%
    LRW, 256 bit: 263.7 MB/s 265.3 MB/s +0.6%
    XTS, 256 bit: 251.1 MB/s 255.3 MB/s +1.7%

    Signed-off-by: Mathias Krause
    Reviewed-by: Huang Ying
    Signed-off-by: Herbert Xu

    Mathias Krause