Permalink
Browse files

fix merge conflict

  • Loading branch information...
pfactum committed Feb 17, 2016
2 parents e1a30e4 + fdc9b76 commit cb7fa5762fdf9ce8f7cdb2be63bc3ef2c6e116bf
Showing with 1,679 additions and 567 deletions.
  1. +4 −16 arch/parisc/include/asm/hugetlb.h
  2. +4 −0 arch/parisc/include/uapi/asm/siginfo.h
  3. +48 −12 arch/parisc/mm/hugetlbpage.c
  4. +4 −2 arch/x86/crypto/chacha20-ssse3-x86_64.S
  5. +28 −3 block/blk-merge.c
  6. +49 −6 crypto/af_alg.c
  7. +4 −1 crypto/ahash.c
  8. +161 −8 crypto/algif_hash.c
  9. +198 −54 crypto/algif_skcipher.c
  10. +0 −1 crypto/crc32c_generic.c
  11. +5 −1 crypto/crypto_user.c
  12. +3 −2 crypto/shash.c
  13. +2 −0 crypto/skcipher.c
  14. +20 −0 drivers/ata/ahci.c
  15. +2 −2 drivers/ata/libahci.c
  16. +9 −4 drivers/base/platform.c
  17. +2 −2 drivers/block/zram/zcomp.c
  18. +21 −2 drivers/block/zram/zcomp_lz4.c
  19. +21 −2 drivers/block/zram/zcomp_lzo.c
  20. +4 −3 drivers/block/zram/zram_drv.c
  21. +12 −11 drivers/crypto/atmel-sha.c
  22. +2 −2 drivers/crypto/caam/ctrl.c
  23. +1 −1 drivers/crypto/marvell/cesa.c
  24. +2 −0 drivers/crypto/sunxi-ss/sun4i-ss-core.c
  25. +13 −2 drivers/hid/hid-multitouch.c
  26. +2 −2 drivers/hid/usbhid/hid-core.c
  27. +6 −5 drivers/iommu/io-pgtable-arm.c
  28. +16 −12 drivers/md/md.c
  29. +1 −1 drivers/md/md.h
  30. +3 −3 drivers/md/multipath.c
  31. +3 −3 drivers/md/raid1.c
  32. +3 −3 drivers/md/raid10.c
  33. +0 −1 drivers/media/i2c/ir-kbd-i2c.c
  34. +4 −1 drivers/media/pci/saa7134/saa7134-alsa.c
  35. +3 −0 drivers/mtd/nand/nand_base.c
  36. +1 −1 drivers/net/wireless/realtek/rtlwifi/regd.c
  37. +5 −4 drivers/net/wireless/realtek/rtlwifi/rtl8821ae/sw.c
  38. +7 −3 drivers/net/wireless/ti/wlcore/io.h
  39. +7 −3 drivers/net/wireless/ti/wlcore/spi.c
  40. +4 −2 drivers/pci/bus.c
  41. +2 −1 drivers/pci/host/pci-dra7xx.c
  42. +2 −1 drivers/pci/host/pci-exynos.c
  43. +2 −1 drivers/pci/host/pci-imx6.c
  44. +1 −1 drivers/pci/host/pci-tegra.c
  45. +4 −2 drivers/pci/host/pcie-rcar.c
  46. +2 −1 drivers/pci/host/pcie-spear13xx.c
  47. +2 −1 drivers/pci/host/pcie-xilinx.c
  48. +2 −5 drivers/tty/n_tty.c
  49. +38 −6 drivers/tty/tty_io.c
  50. +8 −0 drivers/tty/tty_mutex.c
  51. +8 −1 drivers/usb/class/cdc-acm.c
  52. +1 −0 drivers/usb/class/cdc-acm.h
  53. +5 −3 drivers/usb/core/hub.c
  54. +32 −20 drivers/usb/host/xhci-pci.c
  55. +24 −13 drivers/usb/phy/phy-msm-usb.c
  56. +1 −0 drivers/usb/serial/cp210x.c
  57. +1 −0 drivers/usb/serial/ftdi_sio.c
  58. +1 −0 drivers/usb/serial/ftdi_sio_ids.h
  59. +17 −1 drivers/usb/serial/option.c
  60. +9 −2 drivers/usb/serial/visor.c
  61. +4 −0 fs/ext4/crypto_key.c
  62. +0 −1 fs/nfs/nfs4proc.c
  63. +15 −11 fs/ocfs2/dlm/dlmmaster.c
  64. +2 −0 fs/ocfs2/dlm/dlmrecovery.c
  65. +6 −0 fs/ocfs2/dlmglue.c
  66. +6 −0 include/crypto/hash.h
  67. +6 −5 include/crypto/if_alg.h
  68. +7 −0 include/crypto/skcipher.h
  69. +1 −0 include/linux/console.h
  70. +31 −3 include/linux/hrtimer.h
  71. +1 −0 include/linux/tty.h
  72. +4 −0 include/sound/rawmidi.h
  73. +1 −2 kernel/panic.c
  74. +34 −1 kernel/printk/printk.c
  75. +1 −1 kernel/sched/core.c
  76. +37 −18 kernel/time/hrtimer.c
  77. +1 −1 kernel/time/timer_list.c
  78. +1 −1 kernel/trace/trace.c
  79. +7 −0 kernel/trace/trace_stack.c
  80. +1 −0 lib/libcrc32c.c
  81. +1 −1 mm/backing-dev.c
  82. +13 −1 mm/zsmalloc.c
  83. +2 −1 security/integrity/evm/evm_main.c
  84. +11 −0 sound/core/compress_offload.c
  85. +15 −6 sound/core/oss/pcm_oss.c
  86. +95 −39 sound/core/rawmidi.c
  87. +1 −1 sound/core/seq/oss/seq_oss_init.c
  88. +1 −1 sound/core/seq/oss/seq_oss_synth.c
  89. +3 −0 sound/core/seq/seq_clientmgr.c
  90. +130 −103 sound/core/seq/seq_ports.c
  91. +67 −20 sound/core/seq/seq_timer.c
  92. +17 −6 sound/core/seq/seq_virmidi.c
  93. +59 −39 sound/core/timer.c
  94. +18 −17 sound/drivers/dummy.c
  95. +9 −5 sound/firewire/bebob/bebob_stream.c
  96. +4 −0 sound/isa/Kconfig
  97. +3 −0 sound/pci/Kconfig
  98. +70 −21 sound/pci/hda/hda_generic.c
  99. +13 −0 sound/pci/hda/hda_intel.c
  100. +1 −1 sound/pci/hda/hda_jack.c
  101. +1 −1 sound/pci/hda/hda_jack.h
  102. +4 −1 sound/pci/hda/patch_ca0132.c
  103. +27 −0 sound/pci/hda/patch_cirrus.c
  104. +3 −2 sound/pci/hda/patch_hdmi.c
  105. +76 −9 sound/pci/hda/patch_realtek.c
  106. +3 −3 sound/pci/hda/patch_sigmatel.c
  107. +1 −1 sound/soc/codecs/rt5645.c
  108. +2 −1 sound/soc/soc-pcm.c
  109. +1 −0 sound/sparc/Kconfig
  110. +0 −1 sound/usb/midi.c
  111. +16 −2 sound/usb/quirks.c
@@ -54,24 +54,12 @@ static inline pte_t huge_pte_wrprotect(pte_t pte)
return pte_wrprotect(pte);
}
static inline void huge_ptep_set_wrprotect(struct mm_struct *mm,
unsigned long addr, pte_t *ptep)
{
pte_t old_pte = *ptep;
set_huge_pte_at(mm, addr, ptep, pte_wrprotect(old_pte));
}
void huge_ptep_set_wrprotect(struct mm_struct *mm,
unsigned long addr, pte_t *ptep);
static inline int huge_ptep_set_access_flags(struct vm_area_struct *vma,
int huge_ptep_set_access_flags(struct vm_area_struct *vma,
unsigned long addr, pte_t *ptep,
pte_t pte, int dirty)
{
int changed = !pte_same(*ptep, pte);
if (changed) {
set_huge_pte_at(vma->vm_mm, addr, ptep, pte);
flush_tlb_page(vma, addr);
}
return changed;
}
pte_t pte, int dirty);
static inline pte_t huge_ptep_get(pte_t *ptep)
{
@@ -1,6 +1,10 @@
#ifndef _PARISC_SIGINFO_H
#define _PARISC_SIGINFO_H
#if defined(__LP64__)
#define __ARCH_SI_PREAMBLE_SIZE (4 * sizeof(int))
#endif
#include <asm-generic/siginfo.h>
#undef NSIGTRAP
@@ -105,15 +105,13 @@ static inline void purge_tlb_entries_huge(struct mm_struct *mm, unsigned long ad
addr |= _HUGE_PAGE_SIZE_ENCODING_DEFAULT;
for (i = 0; i < (1 << (HPAGE_SHIFT-REAL_HPAGE_SHIFT)); i++) {
mtsp(mm->context, 1);
pdtlb(addr);
if (unlikely(split_tlb))
pitlb(addr);
purge_tlb_entries(mm, addr);
addr += (1UL << REAL_HPAGE_SHIFT);
}
}
void set_huge_pte_at(struct mm_struct *mm, unsigned long addr,
/* __set_huge_pte_at() must be called holding the pa_tlb_lock. */
static void __set_huge_pte_at(struct mm_struct *mm, unsigned long addr,
pte_t *ptep, pte_t entry)
{
unsigned long addr_start;
@@ -123,33 +121,71 @@ void set_huge_pte_at(struct mm_struct *mm, unsigned long addr,
addr_start = addr;
for (i = 0; i < (1 << HUGETLB_PAGE_ORDER); i++) {
/* Directly write pte entry. We could call set_pte_at(mm, addr, ptep, entry)
* instead, but then we get double locking on pa_tlb_lock. */
*ptep = entry;
set_pte(ptep, entry);
ptep++;
/* Drop the PAGE_SIZE/non-huge tlb entry */
purge_tlb_entries(mm, addr);
addr += PAGE_SIZE;
pte_val(entry) += PAGE_SIZE;
}
purge_tlb_entries_huge(mm, addr_start);
}
void set_huge_pte_at(struct mm_struct *mm, unsigned long addr,
pte_t *ptep, pte_t entry)
{
unsigned long flags;
purge_tlb_start(flags);
__set_huge_pte_at(mm, addr, ptep, entry);
purge_tlb_end(flags);
}
pte_t huge_ptep_get_and_clear(struct mm_struct *mm, unsigned long addr,
pte_t *ptep)
{
unsigned long flags;
pte_t entry;
purge_tlb_start(flags);
entry = *ptep;
set_huge_pte_at(mm, addr, ptep, __pte(0));
__set_huge_pte_at(mm, addr, ptep, __pte(0));
purge_tlb_end(flags);
return entry;
}
void huge_ptep_set_wrprotect(struct mm_struct *mm,
unsigned long addr, pte_t *ptep)
{
unsigned long flags;
pte_t old_pte;
purge_tlb_start(flags);
old_pte = *ptep;
__set_huge_pte_at(mm, addr, ptep, pte_wrprotect(old_pte));
purge_tlb_end(flags);
}
int huge_ptep_set_access_flags(struct vm_area_struct *vma,
unsigned long addr, pte_t *ptep,
pte_t pte, int dirty)
{
unsigned long flags;
int changed;
purge_tlb_start(flags);
changed = !pte_same(*ptep, pte);
if (changed) {
__set_huge_pte_at(vma->vm_mm, addr, ptep, pte);
}
purge_tlb_end(flags);
return changed;
}
int pmd_huge(pmd_t pmd)
{
return 0;
@@ -157,7 +157,9 @@ ENTRY(chacha20_4block_xor_ssse3)
# done with the slightly better performing SSSE3 byte shuffling,
# 7/12-bit word rotation uses traditional shift+OR.
sub $0x40,%rsp
mov %rsp,%r11
sub $0x80,%rsp
and $~63,%rsp
# x0..15[0-3] = s0..3[0..3]
movq 0x00(%rdi),%xmm1
@@ -620,6 +622,6 @@ ENTRY(chacha20_4block_xor_ssse3)
pxor %xmm1,%xmm15
movdqu %xmm15,0xf0(%rsi)
add $0x40,%rsp
mov %r11,%rsp
ret
ENDPROC(chacha20_4block_xor_ssse3)
@@ -68,6 +68,18 @@ static struct bio *blk_bio_write_same_split(struct request_queue *q,
return bio_split(bio, q->limits.max_write_same_sectors, GFP_NOIO, bs);
}
static inline unsigned get_max_io_size(struct request_queue *q,
struct bio *bio)
{
unsigned sectors = blk_max_size_offset(q, bio->bi_iter.bi_sector);
unsigned mask = queue_logical_block_size(q) - 1;
/* aligned to logical block size */
sectors &= ~(mask >> 9);
return sectors;
}
static struct bio *blk_bio_segment_split(struct request_queue *q,
struct bio *bio,
struct bio_set *bs,
@@ -79,18 +91,31 @@ static struct bio *blk_bio_segment_split(struct request_queue *q,
unsigned front_seg_size = bio->bi_seg_front_size;
bool do_split = true;
struct bio *new = NULL;
const unsigned max_sectors = get_max_io_size(q, bio);
bio_for_each_segment(bv, bio, iter) {
if (sectors + (bv.bv_len >> 9) > queue_max_sectors(q))
goto split;
/*
* If the queue doesn't support SG gaps and adding this
* offset would create a gap, disallow it.
*/
if (bvprvp && bvec_gap_to_prev(q, bvprvp, bv.bv_offset))
goto split;
if (sectors + (bv.bv_len >> 9) > max_sectors) {
/*
* Consider this a new segment if we're splitting in
* the middle of this vector.
*/
if (nsegs < queue_max_segments(q) &&
sectors < max_sectors) {
nsegs++;
sectors = max_sectors;
}
if (sectors)
goto split;
/* Make this single bvec as the 1st segment */
}
if (bvprvp && blk_queue_cluster(q)) {
if (seg_size + bv.bv_len > queue_max_segment_size(q))
goto new_segment;
@@ -76,6 +76,8 @@ int af_alg_register_type(const struct af_alg_type *type)
goto unlock;
type->ops->owner = THIS_MODULE;
if (type->ops_nokey)
type->ops_nokey->owner = THIS_MODULE;
node->type = type;
list_add(&node->list, &alg_types);
err = 0;
@@ -125,6 +127,26 @@ int af_alg_release(struct socket *sock)
}
EXPORT_SYMBOL_GPL(af_alg_release);
void af_alg_release_parent(struct sock *sk)
{
struct alg_sock *ask = alg_sk(sk);
unsigned int nokey = ask->nokey_refcnt;
bool last = nokey && !ask->refcnt;
sk = ask->parent;
ask = alg_sk(sk);
lock_sock(sk);
ask->nokey_refcnt -= nokey;
if (!last)
last = !--ask->refcnt;
release_sock(sk);
if (last)
sock_put(sk);
}
EXPORT_SYMBOL_GPL(af_alg_release_parent);
static int alg_bind(struct socket *sock, struct sockaddr *uaddr, int addr_len)
{
const u32 forbidden = CRYPTO_ALG_INTERNAL;
@@ -133,6 +155,7 @@ static int alg_bind(struct socket *sock, struct sockaddr *uaddr, int addr_len)
struct sockaddr_alg *sa = (void *)uaddr;
const struct af_alg_type *type;
void *private;
int err;
if (sock->state == SS_CONNECTED)
return -EINVAL;
@@ -160,16 +183,22 @@ static int alg_bind(struct socket *sock, struct sockaddr *uaddr, int addr_len)
return PTR_ERR(private);
}
err = -EBUSY;
lock_sock(sk);
if (ask->refcnt | ask->nokey_refcnt)
goto unlock;
swap(ask->type, type);
swap(ask->private, private);
err = 0;
unlock:
release_sock(sk);
alg_do_release(type, private);
return 0;
return err;
}
static int alg_setkey(struct sock *sk, char __user *ukey,
@@ -202,11 +231,15 @@ static int alg_setsockopt(struct socket *sock, int level, int optname,
struct sock *sk = sock->sk;
struct alg_sock *ask = alg_sk(sk);
const struct af_alg_type *type;
int err = -ENOPROTOOPT;
int err = -EBUSY;
lock_sock(sk);
if (ask->refcnt)
goto unlock;
type = ask->type;
err = -ENOPROTOOPT;
if (level != SOL_ALG || !type)
goto unlock;
@@ -238,6 +271,7 @@ int af_alg_accept(struct sock *sk, struct socket *newsock)
struct alg_sock *ask = alg_sk(sk);
const struct af_alg_type *type;
struct sock *sk2;
unsigned int nokey;
int err;
lock_sock(sk);
@@ -257,20 +291,29 @@ int af_alg_accept(struct sock *sk, struct socket *newsock)
security_sk_clone(sk, sk2);
err = type->accept(ask->private, sk2);
if (err) {
sk_free(sk2);
nokey = err == -ENOKEY;
if (nokey && type->accept_nokey)
err = type->accept_nokey(ask->private, sk2);
if (err)
goto unlock;
}
sk2->sk_family = PF_ALG;
sock_hold(sk);
if (nokey || !ask->refcnt++)
sock_hold(sk);
ask->nokey_refcnt += nokey;
alg_sk(sk2)->parent = sk;
alg_sk(sk2)->type = type;
alg_sk(sk2)->nokey_refcnt = nokey;
newsock->ops = type->ops;
newsock->state = SS_CONNECTED;
if (nokey)
newsock->ops = type->ops_nokey;
err = 0;
unlock:
@@ -451,6 +451,7 @@ static int crypto_ahash_init_tfm(struct crypto_tfm *tfm)
struct ahash_alg *alg = crypto_ahash_alg(hash);
hash->setkey = ahash_nosetkey;
hash->has_setkey = false;
hash->export = ahash_no_export;
hash->import = ahash_no_import;
@@ -463,8 +464,10 @@ static int crypto_ahash_init_tfm(struct crypto_tfm *tfm)
hash->finup = alg->finup ?: ahash_def_finup;
hash->digest = alg->digest;
if (alg->setkey)
if (alg->setkey) {
hash->setkey = alg->setkey;
hash->has_setkey = true;
}
if (alg->export)
hash->export = alg->export;
if (alg->import)
Oops, something went wrong.

0 comments on commit cb7fa57

Please sign in to comment.