Linux-Next discussions
 help / color / mirror / Atom feed
* linux-next: manual merge of the akpm-current tree with the dax-misc tree
From: Stephen Rothwell @ 2016-05-18  3:57 UTC (permalink / raw)
  To: Andrew Morton, Verma, Vishal L
  Cc: linux-next, linux-kernel, Christoph Hellwig, Toshi Kani

Hi Andrew,

Today's linux-next merge of the akpm-current tree got a conflict in:

  include/linux/dax.h

between commit:

  ecdb4bf9e327 ("dax: export a low-level __dax_zero_page_range helper")

from the dax-misc tree and commit:

  29d44f6759f6 ("dax: add dax_get_unmapped_area for pmd mappings")

from the akpm-current tree.

I fixed it up (see below) and can carry the fix as necessary. This
is now fixed as far as linux-next is concerned, but any non trivial
conflicts should be mentioned to your upstream maintainer when your tree
is submitted for merging.  You may also want to consider cooperating
with the maintainer of the conflicting tree to minimise any particularly
complex conflicts.

-- 
Cheers,
Stephen Rothwell

diff --cc include/linux/dax.h
index 7743e51f826c,184b1714900c..000000000000
--- a/include/linux/dax.h
+++ b/include/linux/dax.h
@@@ -14,19 -17,15 +14,22 @@@ int __dax_fault(struct vm_area_struct *
  
  #ifdef CONFIG_FS_DAX
  struct page *read_dax_sector(struct block_device *bdev, sector_t n);
 +int __dax_zero_page_range(struct block_device *bdev, sector_t sector,
 +		unsigned int offset, unsigned int length);
+ unsigned long dax_get_unmapped_area(struct file *filp, unsigned long addr,
+ 		unsigned long len, unsigned long pgoff, unsigned long flags);
  #else
  static inline struct page *read_dax_sector(struct block_device *bdev,
  		sector_t n)
  {
  	return ERR_PTR(-ENXIO);
  }
 +static inline int __dax_zero_page_range(struct block_device *bdev,
 +		sector_t sector, unsigned int offset, unsigned int length)
 +{
 +	return -ENXIO;
 +}
+ #define dax_get_unmapped_area	NULL
  #endif
  
  #ifdef CONFIG_TRANSPARENT_HUGEPAGE

^ permalink raw reply

* linux-next: manual merge of the dax-misc tree with the nvdimm tree
From: Stephen Rothwell @ 2016-05-18  3:34 UTC (permalink / raw)
  To: Verma, Vishal L; +Cc: linux-next, linux-kernel, Dan Williams, Jan Kara

Hi all,

Today's linux-next merge of the dax-misc tree got a conflict in:

  fs/block_dev.c

between commit:

  8044aae6f374 ("Revert "block: enable dax for raw block devices"")

from the nvdimm tree and commit:

  02fbd139759f ("dax: Remove complete_unwritten argument")

from the dax-misc tree.

I fixed it up (the former removed the code modified by the latter) and
can carry the fix as necessary. This is now fixed as far as linux-next
is concerned, but any non trivial conflicts should be mentioned to your
upstream maintainer when your tree is submitted for merging.  You may
also want to consider cooperating with the maintainer of the conflicting
tree to minimise any particularly complex conflicts.

-- 
Cheers,
Stephen Rothwell

^ permalink raw reply

* Re: Linux-next parallel cp workload hang
From: Al Viro @ 2016-05-18  2:06 UTC (permalink / raw)
  To: Xiong Zhou; +Cc: linux-next, inux-kernel, linux-fsdevel, Dave Chinner
In-Reply-To: <20160518013802.GA4679@ZX.nay.redhat.com>

[dchinner Cc'd]

On Wed, May 18, 2016 at 09:38:02AM +0800, Xiong Zhou wrote:
> Hi,
> 
> Parallel cp workload (xfstests generic/273) hangs like blow.
> It's reproducible with a small chance, less the 1/100 i think.
> 
> Have hit this in linux-next 20160504 0506 0510 trees, testing on
> xfs with loop or block device. Ext4 survived several rounds
> of testing.
> 
> Linux next 20160510 tree hangs within 500 rounds testing several
> times. The same tree with vfs parallel lookup patchset reverted
> survived 900 rounds testing. Reverted commits are attached.
> 
> Bisecting in this patchset ided this commit:
> 
> 3b0a3c1ac1598722fc289da19219d14f2a37b31f is the first bad commit
> commit 3b0a3c1ac1598722fc289da19219d14f2a37b31f
> Author: Al Viro <viro@zeniv.linux.org.uk>
> Date:   Wed Apr 20 23:42:46 2016 -0400
> 
>     simple local filesystems: switch to ->iterate_shared()
>     
>     no changes needed (XFS isn't simple, but it has the same parallelism
>     in the interesting parts exercised from CXFS).
>     
> With this commit reverted on top of Linux next 0510 tree, 5000+ rounds
> of testing passed.

Joy...  So much for CXFS testing, probably...  All that commit changes for
XFS is allowing xfs_readdir() to be called in parallel for different struct
file.  We can always revert the XFS part, of course, but it would be
interesting to find out what happens to be dependent on external exclusion
there.

^ permalink raw reply

* Linux-next parallel cp workload hang
From: Xiong Zhou @ 2016-05-18  1:46 UTC (permalink / raw)
  To: linux-next, viro; +Cc: linux-kernel, linux-fsdevel

[-- Attachment #1: Type: text/plain, Size: 5438 bytes --]

Hi,

Parallel cp workload (xfstests generic/273) hangs like blow.
It's reproducible with a small chance, less the 1/100 i think.

Have hit this in linux-next 20160504 0506 0510 trees, testing on
xfs with loop or block device. Ext4 survived several rounds
of testing.

Linux next 20160510 tree hangs within 500 rounds testing several
times. The same tree with vfs parallel lookup patchset reverted
survived 900 rounds testing. Reverted commits are attached.

Bisecting in this patchset ided this commit:

3b0a3c1ac1598722fc289da19219d14f2a37b31f is the first bad commit
commit 3b0a3c1ac1598722fc289da19219d14f2a37b31f
Author: Al Viro <viro@zeniv.linux.org.uk>
Date:   Wed Apr 20 23:42:46 2016 -0400

    simple local filesystems: switch to ->iterate_shared()
    
    no changes needed (XFS isn't simple, but it has the same parallelism
    in the interesting parts exercised from CXFS).
    
With this commit reverted on top of Linux next 0510 tree, 5000+ rounds
of testing passed.

Although 2000 rounds testing had been conducted before good/bad
verdict, i'm not 100 percent sure about all this, since it's
so hard to hit, and i am not that lucky..

Bisect log and full blocked state process dump log are also attached.

Furthermore, this was first hit when testing fs dax on nvdimm,
however it's reproducible without dax mount option, and also
reproducible on loop device, just seems harder to hit.

Thanks,
Xiong

[0.771475] INFO: task cp:49033 blocked for more than 120 seconds.
[0.794263]       Not tainted 4.6.0-rc6-next-20160504 #5
[0.812515] "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables
this message.
[0.841801] cp              D ffff880b4e977928     0 49033  49014
0x00000080
[0.868923]  ffff880b4e977928 ffff880ba275d380 ffff880b8d712b80
ffff880b4e978000
[0.897504]  7fffffffffffffff 0000000000000002 0000000000000000
ffff880b8d712b80
[0.925234]  ffff880b4e977940 ffffffff816cbc25 ffff88035a1dabb0
ffff880b4e9779e8
[0.953237] Call Trace:
[0.958314]  [<ffffffff816cbc25>] schedule+0x35/0x80
[0.974854]  [<ffffffff816ceb71>] schedule_timeout+0x231/0x2d0
[0.995728]  [<ffffffff810d2e2d>] ? down_trylock+0x2d/0x40
[1.015351]  [<ffffffffa03fa6c2>] ? xfs_iext_bno_to_ext+0xa2/0x190 [xfs]
[1.040182]  [<ffffffff816cdb89>] __down_common+0xaa/0x104
[1.059021]  [<ffffffffa04076d2>] ? _xfs_buf_find+0x162/0x340 [xfs]
[1.081357]  [<ffffffff816cdc00>] __down+0x1d/0x1f
[1.097166]  [<ffffffff810d2e81>] down+0x41/0x50
[1.112869]  [<ffffffffa04074bc>] xfs_buf_lock+0x3c/0xf0 [xfs]
[1.134504]  [<ffffffffa04076d2>] _xfs_buf_find+0x162/0x340 [xfs]
[1.156871]  [<ffffffffa04078da>] xfs_buf_get_map+0x2a/0x270 [xfs]
[1.180010]  [<ffffffffa04084ed>] xfs_buf_read_map+0x2d/0x180 [xfs]
[1.203538]  [<ffffffffa0435f21>] xfs_trans_read_buf_map+0xf1/0x300 [xfs]
[1.229194]  [<ffffffffa03e75b1>] xfs_da_read_buf+0xd1/0x100 [xfs]
[1.251948]  [<ffffffffa03ed5e6>] xfs_dir3_data_read+0x26/0x60 [xfs]
[1.275736]  [<ffffffffa040923e>]
xfs_dir2_leaf_readbuf.isra.12+0x1be/0x4a0 [xfs]
[1.305094]  [<ffffffff816cdc92>] ? down_read+0x12/0x30
[1.323787]  [<ffffffffa04187a4>] ? xfs_ilock+0xe4/0x110 [xfs]
[1.345114]  [<ffffffffa040965b>] xfs_dir2_leaf_getdents+0x13b/0x3d0
[xfs]
[1.371818]  [<ffffffffa0409f26>] xfs_readdir+0x1a6/0x1c0 [xfs]
[1.393471]  [<ffffffffa040bcbb>] xfs_file_readdir+0x2b/0x30 [xfs]
[1.416874]  [<ffffffff8122cec3>] iterate_dir+0x173/0x190
[1.436709]  [<ffffffff81003276>] ? do_audit_syscall_entry+0x66/0x70
[1.460951]  [<ffffffff8122d338>] SyS_getdents+0x98/0x120
[1.480566]  [<ffffffff8122cee0>] ? iterate_dir+0x190/0x190
[1.500909]  [<ffffffff81003b12>] do_syscall_64+0x62/0x110
[1.520847]  [<ffffffff816cf9a1>] entry_SYSCALL64_slow_path+0x25/0x25
[1.545372] INFO: task cp:49040 blocked for more than 120 seconds.
[1.568933]       Not tainted 4.6.0-rc6-next-20160504 #5
[1.587943] "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables
this message.
[1.618544] cp              D ffff880b91463b00     0 49040  49016
0x00000080
[1.645502]  ffff880b91463b00 ffff880464d5c140 ffff88029b475700
ffff880b91464000
[1.674145]  ffff880411c42610 ffffffffffffffff ffff880411c42628
ffff8802c10bc610
[1.702834]  ffff880b91463b18 ffffffff816cbc25 ffff88029b475700
ffff880b91463b88
[1.731501] Call Trace:
[1.736866]  [<ffffffff816cbc25>] schedule+0x35/0x80
[1.754119]  [<ffffffff816ce3c2>] rwsem_down_read_failed+0xf2/0x140
[1.777411]  [<ffffffffa0418800>] ? xfs_ilock_data_map_shared+0x30/0x40
[xfs]
[1.805090]  [<ffffffff81355e08>] call_rwsem_down_read_failed+0x18/0x30
[1.830482]  [<ffffffff816cdca0>] down_read+0x20/0x30
[1.848505]  [<ffffffffa04187a4>] xfs_ilock+0xe4/0x110 [xfs]
[1.869293]  [<ffffffffa0418800>] xfs_ilock_data_map_shared+0x30/0x40
[xfs]
[1.896775]  [<ffffffffa040bc60>] xfs_dir_open+0x30/0x60 [xfs]
[1.917882]  [<ffffffff8121603f>] do_dentry_open+0x20f/0x320
[1.938919]  [<ffffffffa040bc30>] ? xfs_file_mmap+0x50/0x50 [xfs]
[1.961532]  [<ffffffff81217487>] vfs_open+0x57/0x60
[1.978945]  [<ffffffff81226f65>] path_openat+0x325/0x14e0
[1.999273]  [<ffffffff81228533>] ? putname+0x53/0x60
[2.017695]  [<ffffffff81229581>] do_filp_open+0x91/0x100
[2.036893]  [<ffffffff81237866>] ? __alloc_fd+0x46/0x180
[2.055479]  [<ffffffff812177e4>] do_sys_open+0x124/0x210
[2.073783]  [<ffffffff8113110b>] ? __audit_syscall_exit+0x1db/0x260
[2.096426]  [<ffffffff81217904>] SyS_openat+0x14/0x20
[2.113690]  [<ffffffff81003b12>] do_syscall_64+0x62/0x110
[2.132417]  [<ffffffff816cf9a1>] entry_SYSCALL64_slow_path+0x25/0x25


[-- Attachment #2: g273-block-dumps.tar.gz --]
[-- Type: application/gzip, Size: 102883 bytes --]

^ permalink raw reply

* Re: QRTR merge conflict resolution
From: Stephen Rothwell @ 2016-05-18  0:43 UTC (permalink / raw)
  To: David Miller
  Cc: bjorn.andersson, arnd, linux-arm-kernel, andy.gross, netdev,
	linux-kernel, linux-next, olof
In-Reply-To: <20160517.141154.1511755950068252376.davem@davemloft.net>

Hi David,

On Tue, 17 May 2016 14:11:54 -0400 (EDT) David Miller <davem@davemloft.net> wrote:
>
> From: Bjorn Andersson <bjorn.andersson@linaro.org>
> Date: Fri, 13 May 2016 15:19:09 -0700
> 
> > I have prepared the merge of net-next and the conflicting tag from the
> > Qualcomm SOC, please include this in your pull towards Linus to avoid
> > the merge conflict.  
> 
> Pulled, thanks.

Except in the merge resolution, the 2 new functions added to
include/linux/soc/qcom/smd.h (qcom_smd_get_drvdata and
qcom_smd_set_drvdata) were not marked "static inline" :-(

-- 
Cheers,
Stephen Rothwell

^ permalink raw reply

* Re: QRTR merge conflict resolution
From: David Miller @ 2016-05-17 18:11 UTC (permalink / raw)
  To: bjorn.andersson
  Cc: arnd, linux-arm-kernel, sfr, andy.gross, netdev, linux-kernel,
	linux-next, olof
In-Reply-To: <20160513221909.GC1256@tuxbot>

From: Bjorn Andersson <bjorn.andersson@linaro.org>
Date: Fri, 13 May 2016 15:19:09 -0700

> I have prepared the merge of net-next and the conflicting tag from the
> Qualcomm SOC, please include this in your pull towards Linus to avoid
> the merge conflict.

Pulled, thanks.

^ permalink raw reply

* Re: linux-next: manual merge of the net-next tree with the arm64 tree
From: Daniel Borkmann @ 2016-05-17 13:49 UTC (permalink / raw)
  To: Catalin Marinas
  Cc: Geert Uytterhoeven, Stephen Rothwell, David Miller,
	netdev@vger.kernel.org, Linux-Next, linux-kernel@vger.kernel.org,
	Yang Shi, Will Deacon
In-Reply-To: <20160517133834.GF23555@e104818-lin.cambridge.arm.com>

On 05/17/2016 03:38 PM, Catalin Marinas wrote:
> On Tue, May 17, 2016 at 09:12:34AM +0200, Daniel Borkmann wrote:
>> On 05/17/2016 09:03 AM, Geert Uytterhoeven wrote:
>> [...]
>>> Someone's not gonna be happy with commit 6077776b5908 ("bpf: split
>>> HAVE_BPF_JIT into cBPF and eBPF variant") breaking the sort order again...
>>
>> Wasn't aware of that. Maybe I'm missing something, but there appears
>> to be no throughout consistent ordering ...
>>
>> [...]
>>          select HAVE_PERF_REGS
>>          select HAVE_PERF_USER_STACK_DUMP
>>          select HAVE_RCU_TABLE_FREE
>>          select HAVE_SYSCALL_TRACEPOINTS
>>          select IOMMU_DMA if IOMMU_SUPPORT
>>          select IRQ_DOMAIN
>>          select IRQ_FORCED_THREADING
>> [...]
>>          select RTC_LIB
>>          select SPARSE_IRQ
>>          select SYSCTL_EXCEPTION_TRACE
>>          select HAVE_CONTEXT_TRACKING
>>          select HAVE_ARM_SMCCC
>> [...]
>
> We keep fixing them as we merge other stuff. For example, latest
> mainline has commit 8ee708792e1c ("arm64: Kconfig: remove redundant
> HAVE_ARCH_TRANSPARENT_HUGEPAGE definition") which also fixes up the
> Kconfig order.

Understood, thanks for the clarification (and sorry for the sort order
issue).

^ permalink raw reply

* Re: linux-next: manual merge of the net-next tree with the arm64 tree
From: Catalin Marinas @ 2016-05-17 13:38 UTC (permalink / raw)
  To: Daniel Borkmann
  Cc: Geert Uytterhoeven, Stephen Rothwell, David Miller,
	netdev@vger.kernel.org, Linux-Next, linux-kernel@vger.kernel.org,
	Yang Shi, Will Deacon
In-Reply-To: <573AC462.7070809@iogearbox.net>

On Tue, May 17, 2016 at 09:12:34AM +0200, Daniel Borkmann wrote:
> On 05/17/2016 09:03 AM, Geert Uytterhoeven wrote:
> [...]
> >Someone's not gonna be happy with commit 6077776b5908 ("bpf: split
> >HAVE_BPF_JIT into cBPF and eBPF variant") breaking the sort order again...
> 
> Wasn't aware of that. Maybe I'm missing something, but there appears
> to be no throughout consistent ordering ...
> 
> [...]
>         select HAVE_PERF_REGS
>         select HAVE_PERF_USER_STACK_DUMP
>         select HAVE_RCU_TABLE_FREE
>         select HAVE_SYSCALL_TRACEPOINTS
>         select IOMMU_DMA if IOMMU_SUPPORT
>         select IRQ_DOMAIN
>         select IRQ_FORCED_THREADING
> [...]
>         select RTC_LIB
>         select SPARSE_IRQ
>         select SYSCTL_EXCEPTION_TRACE
>         select HAVE_CONTEXT_TRACKING
>         select HAVE_ARM_SMCCC
> [...]

We keep fixing them as we merge other stuff. For example, latest
mainline has commit 8ee708792e1c ("arm64: Kconfig: remove redundant
HAVE_ARCH_TRANSPARENT_HUGEPAGE definition") which also fixes up the
Kconfig order.

-- 
Catalin

^ permalink raw reply

* next-20160517 build: 0 failures 19 warnings (next-20160517)
From: Build bot for Mark Brown @ 2016-05-17 10:04 UTC (permalink / raw)
  To: kernel-build-reports, linaro-kernel, linux-next

Tree/Branch: next-20160517
Git describe: next-20160517
Commit: 16c704a374 Add linux-next specific files for 20160517

Build Time: 152 min 58 sec

Passed:    9 / 9   (100.00 %)
Failed:    0 / 9   (  0.00 %)

Errors: 0
Warnings: 19
Section Mismatches: 0

-------------------------------------------------------------------------------
defconfigs with issues (other than build errors):
      1 warnings    0 mismatches  : arm64-allnoconfig
     15 warnings    0 mismatches  : arm64-allmodconfig
      3 warnings    0 mismatches  : arm-multi_v5_defconfig
      3 warnings    0 mismatches  : arm-multi_v7_defconfig
      1 warnings    0 mismatches  : x86_64-defconfig
      8 warnings    0 mismatches  : arm-allmodconfig
      1 warnings    0 mismatches  : arm-allnoconfig
      1 warnings    0 mismatches  : x86_64-allnoconfig
      4 warnings    0 mismatches  : arm64-defconfig

-------------------------------------------------------------------------------

Warnings Summary: 19
	  6 ../fs/ext4/inode.c:3502:9: warning: unused variable 'offset' [-Wunused-variable]
	  5 ../include/linux/export.h:63:25: warning: 'regulator_can_change_voltage' is deprecated [-Wdeprecated-declarations]
	  5 ../drivers/regulator/core.c:2536:1: warning: 'regulator_can_change_voltage' is deprecated [-Wdeprecated-declarations]
	  3 ../mm/page_alloc.c:3658:5: warning: 'compact_result' may be used uninitialized in this function [-Wmaybe-uninitialized]
	  2 ../sound/soc/codecs/hdac_hdmi.c:1721:16: warning: unused variable 'timeout' [-Wunused-variable]
	  2 ../drivers/xen/balloon.c:154:13: warning: 'release_memory_resource' declared 'static' but never defined [-Wunused-function]
	  2 ../drivers/pinctrl/stm32/pinctrl-stm32.c:797:17: warning: too many arguments for format [-Wformat-extra-args]
	  1 ../include/soc/nps/common.h:162:9: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast]
	  1 ../include/soc/nps/common.h:148:9: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast]
	  1 ../fs/reiserfs/ibalance.c:1156:2: warning: 'new_insert_key' may be used uninitialized in this function [-Wmaybe-uninitialized]
	  1 ../fs/gfs2/dir.c:802:9: warning: 'leaf_no' may be used uninitialized in this function [-Wmaybe-uninitialized]
	  1 ../fs/gfs2/dir.c:1021:8: warning: 'leaf_no' may be used uninitialized in this function [-Wmaybe-uninitialized]
	  1 ../drivers/staging/iio/adc/ad7606_spi.c:24:18: warning: 'data' may be used uninitialized in this function [-Wmaybe-uninitialized]
	  1 ../drivers/soc/mediatek/mtk-pmic-wrap.c:1086:16: warning: large integer implicitly truncated to unsigned type [-Woverflow]
	  1 ../drivers/soc/mediatek/mtk-pmic-wrap.c:1074:16: warning: large integer implicitly truncated to unsigned type [-Woverflow]
	  1 ../drivers/soc/mediatek/mtk-pmic-wrap.c:1062:16: warning: large integer implicitly truncated to unsigned type [-Woverflow]
	  1 ../drivers/gpu/drm/omapdrm/dss/hdmi5.c:134:2: warning: 'regulator_can_change_voltage' is deprecated [-Wdeprecated-declarations]
	  1 ../drivers/gpu/drm/omapdrm/dss/hdmi4.c:117:2: warning: 'regulator_can_change_voltage' is deprecated [-Wdeprecated-declarations]
	  1 ../drivers/gpu/drm/omapdrm/dss/dsi.c:1183:2: warning: 'regulator_can_change_voltage' is deprecated [-Wdeprecated-declarations]



===============================================================================
Detailed per-defconfig build reports below:


-------------------------------------------------------------------------------
arm64-allnoconfig : PASS, 0 errors, 1 warnings, 0 section mismatches

Warnings:
	../mm/page_alloc.c:3658:5: warning: 'compact_result' may be used uninitialized in this function [-Wmaybe-uninitialized]

-------------------------------------------------------------------------------
arm64-allmodconfig : PASS, 0 errors, 15 warnings, 0 section mismatches

Warnings:
	../fs/ext4/inode.c:3502:9: warning: unused variable 'offset' [-Wunused-variable]
	../sound/soc/codecs/hdac_hdmi.c:1721:16: warning: unused variable 'timeout' [-Wunused-variable]
	../fs/gfs2/dir.c:802:9: warning: 'leaf_no' may be used uninitialized in this function [-Wmaybe-uninitialized]
	../fs/gfs2/dir.c:1021:8: warning: 'leaf_no' may be used uninitialized in this function [-Wmaybe-uninitialized]
	../fs/reiserfs/ibalance.c:1156:2: warning: 'new_insert_key' may be used uninitialized in this function [-Wmaybe-uninitialized]
	../include/soc/nps/common.h:148:9: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast]
	../include/soc/nps/common.h:162:9: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast]
	../drivers/pinctrl/stm32/pinctrl-stm32.c:797:17: warning: too many arguments for format [-Wformat-extra-args]
	../drivers/regulator/core.c:2536:1: warning: 'regulator_can_change_voltage' is deprecated [-Wdeprecated-declarations]
	../include/linux/export.h:63:25: warning: 'regulator_can_change_voltage' is deprecated [-Wdeprecated-declarations]
	../drivers/soc/mediatek/mtk-pmic-wrap.c:1062:16: warning: large integer implicitly truncated to unsigned type [-Woverflow]
	../drivers/soc/mediatek/mtk-pmic-wrap.c:1074:16: warning: large integer implicitly truncated to unsigned type [-Woverflow]
	../drivers/soc/mediatek/mtk-pmic-wrap.c:1086:16: warning: large integer implicitly truncated to unsigned type [-Woverflow]
	../drivers/staging/iio/adc/ad7606_spi.c:24:18: warning: 'data' may be used uninitialized in this function [-Wmaybe-uninitialized]
	../drivers/xen/balloon.c:154:13: warning: 'release_memory_resource' declared 'static' but never defined [-Wunused-function]

-------------------------------------------------------------------------------
arm-multi_v5_defconfig : PASS, 0 errors, 3 warnings, 0 section mismatches

Warnings:
	../fs/ext4/inode.c:3502:9: warning: unused variable 'offset' [-Wunused-variable]
	../drivers/regulator/core.c:2536:1: warning: 'regulator_can_change_voltage' is deprecated [-Wdeprecated-declarations]
	../include/linux/export.h:63:25: warning: 'regulator_can_change_voltage' is deprecated [-Wdeprecated-declarations]

-------------------------------------------------------------------------------
arm-multi_v7_defconfig : PASS, 0 errors, 3 warnings, 0 section mismatches

Warnings:
	../fs/ext4/inode.c:3502:9: warning: unused variable 'offset' [-Wunused-variable]
	../drivers/regulator/core.c:2536:1: warning: 'regulator_can_change_voltage' is deprecated [-Wdeprecated-declarations]
	../include/linux/export.h:63:25: warning: 'regulator_can_change_voltage' is deprecated [-Wdeprecated-declarations]

-------------------------------------------------------------------------------
x86_64-defconfig : PASS, 0 errors, 1 warnings, 0 section mismatches

Warnings:
	../fs/ext4/inode.c:3502:9: warning: unused variable 'offset' [-Wunused-variable]

-------------------------------------------------------------------------------
arm-allmodconfig : PASS, 0 errors, 8 warnings, 0 section mismatches

Warnings:
	../fs/ext4/inode.c:3502:9: warning: unused variable 'offset' [-Wunused-variable]
	../sound/soc/codecs/hdac_hdmi.c:1721:16: warning: unused variable 'timeout' [-Wunused-variable]
	../drivers/gpu/drm/omapdrm/dss/dsi.c:1183:2: warning: 'regulator_can_change_voltage' is deprecated [-Wdeprecated-declarations]
	../drivers/gpu/drm/omapdrm/dss/hdmi4.c:117:2: warning: 'regulator_can_change_voltage' is deprecated [-Wdeprecated-declarations]
	../drivers/gpu/drm/omapdrm/dss/hdmi5.c:134:2: warning: 'regulator_can_change_voltage' is deprecated [-Wdeprecated-declarations]
	../drivers/pinctrl/stm32/pinctrl-stm32.c:797:17: warning: too many arguments for format [-Wformat-extra-args]
	../drivers/regulator/core.c:2536:1: warning: 'regulator_can_change_voltage' is deprecated [-Wdeprecated-declarations]
	../include/linux/export.h:63:25: warning: 'regulator_can_change_voltage' is deprecated [-Wdeprecated-declarations]

-------------------------------------------------------------------------------
arm-allnoconfig : PASS, 0 errors, 1 warnings, 0 section mismatches

Warnings:
	../mm/page_alloc.c:3658:5: warning: 'compact_result' may be used uninitialized in this function [-Wmaybe-uninitialized]

-------------------------------------------------------------------------------
x86_64-allnoconfig : PASS, 0 errors, 1 warnings, 0 section mismatches

Warnings:
	../mm/page_alloc.c:3658:5: warning: 'compact_result' may be used uninitialized in this function [-Wmaybe-uninitialized]

-------------------------------------------------------------------------------
arm64-defconfig : PASS, 0 errors, 4 warnings, 0 section mismatches

Warnings:
	../fs/ext4/inode.c:3502:9: warning: unused variable 'offset' [-Wunused-variable]
	../drivers/regulator/core.c:2536:1: warning: 'regulator_can_change_voltage' is deprecated [-Wdeprecated-declarations]
	../include/linux/export.h:63:25: warning: 'regulator_can_change_voltage' is deprecated [-Wdeprecated-declarations]
	../drivers/xen/balloon.c:154:13: warning: 'release_memory_resource' declared 'static' but never defined [-Wunused-function]
-------------------------------------------------------------------------------

Passed with no errors, warnings or mismatches:

close failed in file object destructor:
sys.excepthook is missing
lost sys.stderr

^ permalink raw reply

* Re: linux-next: manual merge of the net-next tree with the arm64 tree
From: Daniel Borkmann @ 2016-05-17  7:12 UTC (permalink / raw)
  To: Geert Uytterhoeven, Stephen Rothwell
  Cc: David Miller, netdev@vger.kernel.org, Catalin Marinas, Linux-Next,
	linux-kernel@vger.kernel.org, Yang Shi, Will Deacon
In-Reply-To: <CAMuHMdX8oW2M8Rr_LUHNSi9PMyEoNOdsp4MrN5z3SySjfahFmw@mail.gmail.com>

On 05/17/2016 09:03 AM, Geert Uytterhoeven wrote:
[...]
> Someone's not gonna be happy with commit 6077776b5908 ("bpf: split
> HAVE_BPF_JIT into cBPF and eBPF variant") breaking the sort order again...

Wasn't aware of that. Maybe I'm missing something, but there appears
to be no throughout consistent ordering ...

[...]
         select HAVE_PERF_REGS
         select HAVE_PERF_USER_STACK_DUMP
         select HAVE_RCU_TABLE_FREE
         select HAVE_SYSCALL_TRACEPOINTS
         select IOMMU_DMA if IOMMU_SUPPORT
         select IRQ_DOMAIN
         select IRQ_FORCED_THREADING
[...]
         select RTC_LIB
         select SPARSE_IRQ
         select SYSCTL_EXCEPTION_TRACE
         select HAVE_CONTEXT_TRACKING
         select HAVE_ARM_SMCCC
[...]

^ permalink raw reply

* Re: linux-next: manual merge of the net-next tree with the arm64 tree
From: Geert Uytterhoeven @ 2016-05-17  7:03 UTC (permalink / raw)
  To: Stephen Rothwell
  Cc: David Miller, netdev@vger.kernel.org, Catalin Marinas, Linux-Next,
	linux-kernel@vger.kernel.org, Daniel Borkmann, Yang Shi,
	Will Deacon
In-Reply-To: <20160517102441.0cfbc192@canb.auug.org.au>

On Tue, May 17, 2016 at 2:24 AM, Stephen Rothwell <sfr@canb.auug.org.au> wrote:
>
> Today's linux-next merge of the net-next tree got a conflict in:
>
>   arch/arm64/Kconfig
>
> between commit:
>
>   8ee708792e1c ("arm64: Kconfig: remove redundant HAVE_ARCH_TRANSPARENT_HUGEPAGE definition")
>
> from the arm64 tree and commit:
>
>   6077776b5908 ("bpf: split HAVE_BPF_JIT into cBPF and eBPF variant")
>
> from the net-next tree.
>
> I fixed it up (see below) and can carry the fix as necessary. This
> is now fixed as far as linux-next is concerned, but any non trivial
> conflicts should be mentioned to your upstream maintainer when your tree
> is submitted for merging.  You may also want to consider cooperating
> with the maintainer of the conflicting tree to minimise any particularly
> complex conflicts.
>
> --
> Cheers,
> Stephen Rothwell
>
> diff --cc arch/arm64/Kconfig
> index 8845c0d100d7,e6761ea2feec..000000000000
> --- a/arch/arm64/Kconfig
> +++ b/arch/arm64/Kconfig
> @@@ -59,9 -58,7 +59,9 @@@ config ARM6
>         select HAVE_ARCH_MMAP_RND_COMPAT_BITS if COMPAT
>         select HAVE_ARCH_SECCOMP_FILTER
>         select HAVE_ARCH_TRACEHOOK
>  +      select HAVE_ARCH_TRANSPARENT_HUGEPAGE
>  +      select HAVE_ARM_SMCCC
> -       select HAVE_BPF_JIT
> +       select HAVE_EBPF_JIT
>         select HAVE_C_RECORDMCOUNT
>         select HAVE_CC_STACKPROTECTOR
>         select HAVE_CMPXCHG_DOUBLE

Someone's not gonna be happy with commit 6077776b5908 ("bpf: split
HAVE_BPF_JIT into cBPF and eBPF variant") breaking the sort order again...

Gr{oetje,eeting}s,

                        Geert

^ permalink raw reply

* Re: linux-next: manual merge of the net-next tree with the arm64 tree
From: Daniel Borkmann @ 2016-05-17  6:05 UTC (permalink / raw)
  To: Stephen Rothwell, David Miller, netdev, Catalin Marinas
  Cc: linux-next, linux-kernel, Yang Shi, Will Deacon
In-Reply-To: <20160517102441.0cfbc192@canb.auug.org.au>

On 05/17/2016 02:24 AM, Stephen Rothwell wrote:
> Hi all,
>
> Today's linux-next merge of the net-next tree got a conflict in:
>
>    arch/arm64/Kconfig
>
> between commit:
>
>    8ee708792e1c ("arm64: Kconfig: remove redundant HAVE_ARCH_TRANSPARENT_HUGEPAGE definition")
>
> from the arm64 tree and commit:
>
>    6077776b5908 ("bpf: split HAVE_BPF_JIT into cBPF and eBPF variant")
>
> from the net-next tree.
>
> I fixed it up (see below) and can carry the fix as necessary. This
> is now fixed as far as linux-next is concerned, but any non trivial
> conflicts should be mentioned to your upstream maintainer when your tree
> is submitted for merging.  You may also want to consider cooperating
> with the maintainer of the conflicting tree to minimise any particularly
> complex conflicts.

Diff looks good, thanks!

^ permalink raw reply

* linux-next: Tree for May 17
From: Stephen Rothwell @ 2016-05-17  5:04 UTC (permalink / raw)
  To: linux-next; +Cc: linux-kernel

Hi all,

Please do not add any v4.8 destined material to your linux-next included
branches until after v4.7-rc1 has been released.

Changes since 20160516:

The vfs tree gained a conflict against the ext4 tree.

The net-next tree gained a conflict against the arm64 tree.

The spi tree lost its build failure.

Non-merge commits (relative to Linus' tree): 9737
 8314 files changed, 424907 insertions(+), 177068 deletions(-)

----------------------------------------------------------------------------

I have created today's linux-next tree at
git://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git
(patches at http://www.kernel.org/pub/linux/kernel/next/ ).  If you
are tracking the linux-next tree using git, you should not use "git pull"
to do so as that will try to merge the new linux-next release with the
old one.  You should use "git fetch" and checkout or reset to the new
master.

You can see which trees have been included by looking in the Next/Trees
file in the source.  There are also quilt-import.log and merge.log
files in the Next directory.  Between each merge, the tree was built
with a ppc64_defconfig for powerpc and an allmodconfig (with
CONFIG_BUILD_DOCSRC=n) for x86_64, a multi_v7_defconfig for arm and a
native build of tools/perf. After the final fixups (if any), I do an
x86_64 modules_install followed by builds for x86_64 allnoconfig,
powerpc allnoconfig (32 and 64 bit), ppc44x_defconfig, allyesconfig
(this fails its final link) and pseries_le_defconfig and i386, sparc
and sparc64 defconfig.

Below is a summary of the state of the merge.

I am currently merging 235 trees (counting Linus' and 35 trees of patches
pending for Linus' tree).

Stats about the size of the tree over time can be seen at
http://neuling.org/linux-next-size.html .

Status of my local build tests will be at
http://kisskb.ellerman.id.au/linux-next .  If maintainers want to give
advice about cross compilers/configs that work, we are always open to add
more builds.

Thanks to Randy Dunlap for doing many randconfig builds.  And to Paul
Gortmaker for triage and bug fixes.

-- 
Cheers,
Stephen Rothwell

$ git checkout master
$ git reset --hard stable
Merging origin/master (cf6ed9a6682d Merge branch 'ras-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip)
Merging fixes/master (b507146bb6b9 Merge branch 'linus' of git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6)
Merging kbuild-current/rc-fixes (3d1450d54a4f Makefile: Force gzip and xz on module install)
Merging arc-current/for-curr (44549e8f5eea Linux 4.6-rc7)
Merging arm-current/fixes (ec953b70f368 ARM: 8573/1: domain: move {set,get}_domain under config guard)
Merging m68k-current/for-linus (9a6462763b17 m68k/mvme16x: Include generic <linux/rtc.h>)
Merging metag-fixes/fixes (0164a711c97b metag: Fix ioremap_wc/ioremap_cached build errors)
Merging powerpc-fixes/fixes (b4c112114aab powerpc: Fix bad inline asm constraint in create_zero_mask())
Merging powerpc-merge-mpe/fixes (bc0195aad0da Linux 4.2-rc2)
Merging sparc/master (33656a1f2ee5 Merge branch 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jack/linux-fs)
Merging net/master (2dcd0af568b0 Linux 4.6)
Merging ipsec/master (d6af1a31cc72 vti: Add pmtu handling to vti_xmit.)
Merging ipvs/master (f28f20da704d Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net)
Merging wireless-drivers/master (cbbba30f1ac9 Merge tag 'iwlwifi-for-kalle-2016-05-04' of https://git.kernel.org/pub/scm/linux/kernel/git/iwlwifi/iwlwifi-fixes)
Merging mac80211/master (e6436be21e77 mac80211: fix statistics leak if dev_alloc_name() fails)
Merging sound-current/for-linus (a158f2b79ff1 Merge tag 'asoc-v4.7' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-linus)
Merging pci-current/for-linus (9a2a5a638f8e PCI: Do not treat EPROBE_DEFER as device attach failure)
Merging driver-core.current/driver-core-linus (c3b46c73264b Linux 4.6-rc4)
Merging tty.current/tty-linus (44549e8f5eea Linux 4.6-rc7)
Merging usb.current/usb-linus (44549e8f5eea Linux 4.6-rc7)
Merging usb-gadget-fixes/fixes (38740a5b87d5 usb: gadget: f_fs: Fix use-after-free)
Merging usb-serial-fixes/usb-linus (74d2a91aec97 USB: serial: option: add even more ZTE device ids)
Merging usb-chipidea-fixes/ci-for-usb-stable (d144dfea8af7 usb: chipidea: otg: change workqueue ci_otg as freezable)
Merging staging.current/staging-linus (44549e8f5eea Linux 4.6-rc7)
Merging char-misc.current/char-misc-linus (44549e8f5eea Linux 4.6-rc7)
Merging input-current/for-linus (c52c545ead97 Input: twl6040-vibra - fix DT node memory management)
Merging crypto-current/master (256b1cfb9a34 crypto: qat - change the adf_ctl_stop_devices to void)
Merging ide/master (1993b176a822 Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/ide)
Merging devicetree-current/devicetree/merge (f76502aa9140 of/dynamic: Fix test for PPC_PSERIES)
Merging rr-fixes/fixes (8244062ef1e5 modules: fix longstanding /proc/kallsyms vs module insertion race.)
Merging vfio-fixes/for-linus (8160c4e45582 vfio: fix ioctl error handling)
Merging kselftest-fixes/fixes (505ce68c6da3 selftest/seccomp: Fix the seccomp(2) signature)
Merging backlight-fixes/for-backlight-fixes (68feaca0b13e backlight: pwm: Handle EPROBE_DEFER while requesting the PWM)
Merging ftrace-fixes/for-next-urgent (6224beb12e19 tracing: Have branch tracer use recursive field of task struct)
Merging mfd-fixes/for-mfd-fixes (1b52e50f2a40 mfd: max77843: Fix max77843_chg_init() return on error)
Merging drm-intel-fixes/for-linux-next-fixes (2dcd0af568b0 Linux 4.6)
Merging asm-generic/master (b0da6d44157a asm-generic: Drop renameat syscall from default list)
Merging arc/for-next (445a64214285 arc: axs10x: Add DT bindings for I2S PLL Clock)
Merging arm/for-next (b6810489fa29 Merge branch 'devel-stable' into for-next)
Merging arm-perf/for-next/perf (4ba2578fa7b5 arm64: perf: don't expose CHAIN event in sysfs)
Merging arm-soc/for-next (83e0a1672eb5 Merge branch 'next/defconfig' into for-next)
Merging at91/at91-next (5a0d7c6a48ae Merge branch 'at91-4.7-defconfig' into at91-next)
Merging bcm2835-dt/bcm2835-dt-next (896ad420db8d dt/bindings: bcm2835: correct description for DMA-int)
Merging bcm2835-soc/bcm2835-soc-next (92e963f50fc7 Linux 4.5-rc1)
Merging bcm2835-drivers/bcm2835-drivers-next (92e963f50fc7 Linux 4.5-rc1)
Merging bcm2835-defconfig/bcm2835-defconfig-next (3652bb35abf6 ARM: bcm2835: Enable NFS root support.)
Merging berlin/berlin/for-next (9a7e06833249 Merge branch 'berlin/fixes' into berlin/for-next)
Merging cortex-m/for-next (f719a0d6a854 ARM: efm32: switch to vendor,device compatible strings)
Merging imx-mxs/for-next (63b44471754b Merge branch 'imx/defconfig64' into for-next)
Merging keystone/next (02e15d234006 Merge branch 'for_4.7/kesytone' into next)
Merging mvebu/for-next (01316cded75b Merge branch 'mvebu/defconfig' into mvebu/for-next)
Merging omap/for-next (5c66191b5c76 Merge branch 'omap-for-v4.7/dt' into for-next)
Merging omap-pending/for-next (c20c8f750d9f ARM: OMAP2+: hwmod: fix _idle() hwmod state sanity check sequence)
Merging qcom/for-next (100b83d52f51 ARM: dts: msm8974: Add SCM firmware node)
Merging renesas/next (e5c640c6f9cc Merge branches 'heads/arm64-defconfig-for-v4.7', 'heads/arm64-dt-pm-domain-for-v4.7', 'heads/dt-for-v4.7' and 'heads/pci-defconfig-for-v4.7' into next)
Merging rockchip/for-next (f6ec4147adc3 Merge branch 'v4.7-clk/next' into for-next)
Merging rpi/for-rpi-next (bc0195aad0da Linux 4.2-rc2)
Merging samsung/for-next (92e963f50fc7 Linux 4.5-rc1)
Merging samsung-krzk/for-next (05e8e9a8696c Merge branch 'fixes' into for-next)
Merging tegra/for-next (5c282bc9d0a3 Merge branch for-4.7/defconfig into for-next)
Merging arm64/for-next/core (e6d9a5254333 arm64: do not enforce strict 16 byte alignment to stack pointer)
CONFLICT (content): Merge conflict in drivers/firmware/efi/arm-init.c
CONFLICT (content): Merge conflict in arch/arm/kvm/arm.c
Merging blackfin/for-linus (391e74a51ea2 eth: bf609 eth clock: add pclk clock for stmmac driver probe)
CONFLICT (content): Merge conflict in arch/blackfin/mach-common/pm.c
Merging c6x/for-linux-next (ca3060d39ae7 c6x: Use generic clkdev.h header)
Merging cris/for-next (f9f3f864b5e8 cris: Fix section mismatches in architecture startup code)
Merging h8300/h8300-next (8cad489261c5 h8300: switch EARLYCON)
Merging hexagon/linux-next (02cc2ccfe771 Revert "Hexagon: fix signal.c compile error")
Merging ia64/next (787ca32dc704 ia64/unaligned: Silence another GCC warning about an uninitialised variable)
Merging m68k/for-next (9a6462763b17 m68k/mvme16x: Include generic <linux/rtc.h>)
Merging m68knommu/for-next (44156affd184 m68k: change m68knommu maintainer email address)
Merging metag/for-next (096a8b6d5e7a metag: Fix atomic_*_return inline asm constraints)
Merging microblaze/next (52e9e6e05617 microblaze: pci: export isa_io_base to fix link errors)
Merging mips/mips-for-linux-next (b071c5d7998a USB: ohci-jz4740: Remove obsolete driver)
Merging nios2/for-next (a8950e49bd24 nios2: memset: use the right constraint modifier for the %4 output operand)
Merging parisc-hd/for-next (695499920489 parisc: Add native high-resolution sched_clock() implementation)
Merging powerpc/next (1d4e89cf0a4e powerpc/powernv/npu: Add PE to PHB's list)
CONFLICT (content): Merge conflict in arch/powerpc/kernel/prom.c
Merging powerpc-mpe/next (bc0195aad0da Linux 4.2-rc2)
Merging fsl/next (fba4e9f9898a powerpc/fsl/dts: Add "jedec,spi-nor" flash compatible)
Merging mpc5xxx/next (39e69f55f857 powerpc: Introduce the use of the managed version of kzalloc)
Merging s390/features (c53db5222b92 s390/vmem: remove unused function parameter)
Merging sparc-next/master (9f935675d41a Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input)
Merging tile/master (4ef00aa30a3f tile: sort the "select" lines in the TILE/TILEGX configs)
Merging uml/linux-next (ad32a1f3c36b um: use %lx format specifiers for unsigned longs)
Merging unicore32/unicore32 (c83d8b2fc986 unicore32: mm: Add missing parameter to arch_vma_access_permitted)
Merging xtensa/for_next (9da8320bb977 xtensa: add test_kc705_hifi variant)
Merging btrfs/next (bb7ab3b92e46 btrfs: Fix misspellings in comments.)
Merging btrfs-kdave/for-next (a3a7fdf24a89 Merge branch 'for-next-next-4.7-20160512' into for-next-20160512)
Merging ceph/master (d3767f0faeda rbd: report unsupported features to syslog)
Merging cifs/for-next (2e66cc8422f6 [SMB3] remove directory incorrectly tries to set delete on close on non-empty directories)
Merging configfs/for-next (96c22a329351 configfs: fix CONFIGFS_BIN_ATTR_[RW]O definitions)
Merging ecryptfs/next (933c32fe0e42 ecryptfs: drop null test before destroy functions)
Merging ext3/for_next (2a28900be206 udf: Export superblock magic to userspace)
Merging ext4/dev (12735f881952 ext4: pre-zero allocated blocks for DAX IO)
Merging f2fs/dev (ab47036d8f72 f2fs: fix deadlock when flush inline data)
Merging fscache/fscache (b00c2ae2ed3c FS-Cache: Don't override netfs's primary_index if registering failed)
Merging fuse/for-next (4441f63ab7e5 fuse: update mailing list in MAINTAINERS)
Merging gfs2/for-next (68cd4ce2caf2 GFS2: Refactor gfs2_remove_from_journal)
Merging jfs/jfs-next (6ed71e9819ac jfs: Coalesce some formats)
Merging nfs/linux-next (44549e8f5eea Linux 4.6-rc7)
Merging nfsd/nfsd-next (d9e4084f6c97 svcrdma: Generalize svc_rdma_xdr_decode_req())
Merging orangefs/for-next (e56f49814250 orangefs: remove unused variable)
Merging overlayfs/overlayfs-next (41523ff335f4 ovl: override creds with the ones from the superblock mounter)
Merging v9fs/for-next (a333e4bf2556 fs/9p: use fscache mutex rather than spinlock)
Merging ubifs/linux-next (c27cb97218b3 ubifs: Remove unused header)
Merging xfs/for-next (d8bdd04e309b Merge branch 'xfs-4.7-misc-fixes' into for-next)
Merging file-locks/linux-next (5af9c2e19da6 Merge branch 'akpm' (patches from Andrew))
Merging vfs/for-next (16a9fad4ef80 Merge branch 'sendmsg.cifs' into for-next)
CONFLICT (content): Merge conflict in fs/f2fs/data.c
CONFLICT (content): Merge conflict in fs/ext4/inode.c
CONFLICT (content): Merge conflict in fs/ext4/indirect.c
CONFLICT (content): Merge conflict in fs/ext4/ext4.h
Merging pci/next (c21cdb3a2e9e Merge branches 'pci/arm64' and 'pci/host-hv' into next)
Applying: iommu/amd: fix up for aliases API change
Merging hid/for-next (185a9cac5b1e Merge branch 'for-4.6/upstream-fixes' into for-next)
Merging i2c/i2c/for-next (d3e47ff44331 Merge branch 'i2c/for-4.7' into i2c/for-next)
Merging jdelvare-hwmon/master (f02de116250d Documentation/hwmon: Update links in max34440)
Merging dmi/master (c3db05ecf8ac firmware: dmi_scan: Save SMBIOS Type 9 System Slots)
Merging hwmon-staging/hwmon-next (d6a442df63b2 hwmon: (sch5636) trivial fix of spelling mistake on revision)
Merging v4l-dvb/master (73dfb701d254 Merge branch 'v4l_for_linus' into to_next)
Merging pm/linux-next (7e84c1f8ca55 Merge branch 'acpi-video' into linux-next)
CONFLICT (content): Merge conflict in arch/arm/mach-shmobile/Makefile
CONFLICT (content): Merge conflict in MAINTAINERS
Merging idle/next (f55532a0c0b8 Linux 4.6-rc1)
Merging thermal/next (f1ba9eb85b5e thermal: int340x: processor_thermal: support acpi notification)
Merging thermal-soc/next (ddc8fdc6e2f0 Merge branch 'work-fixes' into work-next)
Merging ieee1394/for-next (384fbb96f926 firewire: nosy: Replace timeval with timespec64)
Merging dlm/next (82c7d823cc31 dlm: config: Fix ENOMEM failures in make_cluster())
Merging swiotlb/linux-next (386744425e35 swiotlb: Make linux/swiotlb.h standalone includible)
Merging slave-dma/next (0c1a8ad32520 Merge branch 'topic/core' into next)
Merging net-next/master (7e2c3aea4398 net: also make sch_handle_egress() drop monitor ready)
CONFLICT (content): Merge conflict in include/linux/soc/qcom/smd.h
CONFLICT (content): Merge conflict in arch/arm64/Kconfig
Applying: soc: qcom: smd: fix for Qualcomm IPC router and callback API change
Merging ipsec-next/master (cb866e3298cd xfrm: Increment statistic counter on inner mode error)
Merging ipvs-next/master (698e2a8dca98 ipvs: make drop_entry protection effective for SIP-pe)
Merging wireless-drivers-next/master (52776a700b53 Merge ath-next from ath.git)
CONFLICT (content): Merge conflict in drivers/net/wireless/intel/iwlwifi/mvm/tx.c
Merging bluetooth/master (7e2c3aea4398 net: also make sch_handle_egress() drop monitor ready)
Merging mac80211-next/master (4f45bb3e8a8f mac80211_hwsim: Allow managing radios from non-initial namespaces)
Merging rdma/for-next (94d7f1a255db Merge branches 'hfi1' and 'iw_cxgb4' into k.o/for-4.7)
Merging rdma-leon/rdma-next (44549e8f5eea Linux 4.6-rc7)
Merging rdma-leon-test/testing/rdma-next (d9233ad6ef2f Merge branch 'topic/srp' into testing/rdma-next)
CONFLICT (content): Merge conflict in drivers/infiniband/hw/i40iw/i40iw_verbs.c
CONFLICT (content): Merge conflict in drivers/infiniband/hw/cxgb4/cm.c
Merging mtd/master (20c07a5bf094 mtd: nand: Drop mtd.owner requirement in nand_scan)
Merging l2-mtd/master (e5366a266a8c mtd: spi-nor: support GigaDevice gd25lq64c)
Merging nand/nand/next (666b65683dad mtd: brcmnand: respect ECC algorithm set by NAND subsystem)
Merging crypto/master (256b1cfb9a34 crypto: qat - change the adf_ctl_stop_devices to void)
Merging drm/drm-next (95306975e9dd Merge tag 'drm/tegra/for-4.7-rc1' of git://anongit.freedesktop.org/tegra/linux into drm-next)
Merging drm-panel/drm/panel/for-next (227e4f4079e1 drm/panel: simple: Add support for TPK U.S.A. LLC Fusion 7" and 10.1" panels)
Merging drm-intel/for-linux-next (5b4fd5b1111b drm/i915: Update DRIVER_DATE to 20160425)
Merging drm-tegra/drm/tegra/for-next (057eab2013ec MAINTAINERS: Remove Terje Bergström as Tegra DRM maintainer)
Merging drm-misc/topic/drm-misc (9ecb549867d7 drm/atomic: Add drm_atomic_helper_best_encoder())
Merging drm-exynos/exynos-drm/for-next (25364a9e54fb Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/hid)
Merging drm-msm/msm-next (2b669875332f drm/msm: Drop load/unload drm_driver ops)
Merging hdlcd/for-upstream/hdlcd (69c2565a3cca drm: ARM HDLCD - fix an error code)
Merging drm-vc4/drm-vc4-next (efea172891fc drm/vc4: Return -EBUSY if there's already a pending flip event.)
Merging sunxi/sunxi/for-next (ed490b3ebfa4 Merge branches 'sunxi/drm-fixes-for-4.7' and 'sunxi/dt-for-4.7' into sunxi/for-next)
Merging kbuild/for-next (d99c8a9355cf Merge branch 'kbuild/kbuild' into kbuild/for-next)
Merging kconfig/for-next (5bcba792bb30 localmodconfig: Fix whitespace repeat count after "tristate")
Merging regmap/for-next (d4ab78d7076d Merge remote-tracking branches 'regmap/topic/doc' and 'regmap/topic/flat' into regmap-next)
Merging sound/for-next (581abbaa0336 Merge branch 'for-next' into for-linus)
Merging sound-asoc/for-next (102283e44630 Merge remote-tracking branches 'asoc/topic/topology', 'asoc/topic/twl6040', 'asoc/topic/wm8960' and 'asoc/topic/wm8962' into asoc-next)
Merging modules/modules-next (e2d1248432c4 module: Disable MODULE_FORCE_LOAD when MODULE_SIG_FORCE is enabled)
Merging input/next (d96caf8c33ca Input: rotary-encoder - fix bare use of 'unsigned')
Merging block/for-next (661806a31989 Merge branch 'for-4.7/core' into for-next)
CONFLICT (content): Merge conflict in drivers/nvme/host/pci.c
Merging lightnvm/for-next (2a65aee4011b lightnvm: reserved space calculation incorrect)
Merging device-mapper/for-next (202bae52934d dm thin: unroll issue_discard() to create longer discard bio chains)
Merging pcmcia/master (e8e68fd86d22 pcmcia: do not break rsrc_nonstatic when handling anonymous cards)
Merging mmc-uh/next (1c447116d017 mmc: mmc: Fix partition switch timeout for some eMMCs)
Merging md/for-next (1fa9a1ad0a9d md-cluster: check the return value of process_recvd_msg)
Merging mfd/for-mfd-next (68b21094ef9b mfd: ab8500-debugfs: Trivial fix of spelling mistake on "between")
Merging backlight/for-backlight-next (60d613d6aef4 backlight: pwm_bl: Free PWM requested by legacy API on error path)
Merging battery/master (4a99fa06a8ca sbs-battery: fix power status when battery charging near dry)
Merging omap_dss2/for-next (ffe1b6c453ef video: AMBA CLCD: Remove unncessary include in amba-clcd.c)
Merging regulator/for-next (180aaa7717a8 Merge remote-tracking branches 'regulator/topic/tps6524x' and 'regulator/topic/twl' into regulator-next)
Merging security/next (a6926cc989eb Merge branch 'stable-4.7' of git://git.infradead.org/users/pcmoore/selinux into next)
CONFLICT (content): Merge conflict in crypto/asymmetric_keys/pkcs7_parser.c
Merging integrity/next (05d1a717ec04 ima: add support for creating files using the mknodat syscall)
Merging keys/keys-next (75aeddd12f20 MAINTAINERS: Update keyrings record and add asymmetric keys record)
Merging selinux/next (c2316dbf1242 selinux: apply execstack check on thread stacks)
Merging tpmdd/next (e8f2f45a4402 tpm: Fix suspend regression)
Merging watchdog/master (ae67643edc6e Documentation: Add ebc-c384_wdt watchdog-parameters.txt entry)
Merging iommu/next (6c0b43df74f9 Merge branches 'arm/io-pgtable', 'arm/rockchip', 'arm/omap', 'x86/vt-d', 'ppc/pamu', 'core' and 'x86/amd' into next)
Merging dwmw2-iommu/master (22e2f9fa63b0 iommu/vt-d: Use per-cpu IOVA caching)
Merging vfio/next (5ed4aba1265f vfio_iommu_spapr_tce: Remove unneeded iommu_group_get_iommudata)
Merging jc_docs/docs-next (022eedeebfdd Merge branch 'jani-rest' into docs-next)
CONFLICT (content): Merge conflict in samples/Makefile
Merging trivial/for-next (52bbe141f37f gitignore: fix wording)
Merging audit/next (188e3c5cd2b6 tty: provide tty_name() even without CONFIG_TTY)
Merging devicetree/devicetree/next (48a9b733e644 of/irq: Rename "intc_desc" to "of_intc_desc" to fix OF on sh)
Merging dt-rh/for-next (b6010770f332 drivers/of: Export of_detach_node())
CONFLICT (content): Merge conflict in drivers/iommu/arm-smmu.c
CONFLICT (content): Merge conflict in Documentation/devicetree/bindings/gpu/nvidia,gk20a.txt
Merging mailbox/mailbox-for-next (c430cf376fee mailbox: Fix devm_ioremap_resource error detection code)
Merging spi/for-next (80862e3d2e65 Merge remote-tracking branch 'spi/topic/zynqmp' into spi-next)
Merging tip/auto-latest (73764b364e86 Merge branch 'x86/asm')
CONFLICT (content): Merge conflict in drivers/irqchip/irq-gic.c
CONFLICT (content): Merge conflict in drivers/irqchip/Makefile
CONFLICT (content): Merge conflict in drivers/irqchip/Kconfig
CONFLICT (content): Merge conflict in drivers/cpufreq/longhaul.c
Merging clockevents/clockevents/next (cee77c2c5b57 clocksource/drivers/tango-xtal: Fix incorrect test)
Merging edac/linux_next (12f0721c5a70 sb_edac: correctly fetch DIMM width on Ivy Bridge and Haswell)
Merging edac-amd/for-next (3f37a36b6282 EDAC, amd64_edac: Drop pci_register_driver() use)
Merging irqchip/irqchip/for-next (a66ce4b7d9d2 Merge branch 'irqchip/mvebu' into irqchip/for-next)
Merging ftrace/for-next (0fc1b09ff1ff tracing: Use temp buffer when filtering events)
Merging rcu/rcu/next (2ba259ab67a8 fixup! rcu: Make call_rcu_tasks() tolerate first call with irqs disabled)
Merging kvm/linux-next (c4a8de357ef1 KVM: s390: set halt polling to 80 microseconds)
CONFLICT (content): Merge conflict in drivers/irqchip/irq-gic.c
CONFLICT (content): Merge conflict in drivers/irqchip/irq-gic-v3.c
Merging kvm-arm/next (064850532444 kvm: arm64: Enable hardware updates of the Access Flag for Stage 2 page tables)
Merging kvm-ppc/kvm-ppc-next (c63517c2e381 KVM: PPC: Book3S: correct width in XER handling)
Merging kvm-ppc-paulus/kvm-ppc-next (b1a4286b8f33 KVM: PPC: Book3S HV: Re-enable XICS fast path for irqfd-generated interrupts)
Merging kvms390/next (60a37709ce60 KVM: s390: Populate mask of non-hypervisor managed facility bits)
Merging xen-tip/linux-next (51c2a7526e54 xen/gntdev: reduce copy batch size to 16)
CONFLICT (content): Merge conflict in drivers/xen/efi.c
CONFLICT (content): Merge conflict in arch/arm64/kernel/setup.c
Applying: xen: efi: merge fix patch
Merging percpu/for-next (18fc93fd6412 percpu: remove PERCPU_ENOUGH_ROOM which is stale definition)
Merging workqueues/for-next (f1e89a8f3358 Merge branch 'for-4.6-fixes' into for-next)
Merging drivers-x86/for-next (9a73a6895fc5 surfacepro3_button: Add a warning when switching to tablet mode)
Merging chrome-platform/for-next (9e96aa70e9ac platform/chrome: chromeos_laptop - Add Elan touchpad for Wolf)
Merging hsi/for-next (c2f90a465df7 HSI: omap-ssi: move omap_ssi_port_update_fclk)
Merging leds/for-next (80d6737b27bb leds: gpio: Support the "panic-indicator" firmware property)
Merging ipmi/for-next (a1b4e31bfabb IPMI: reserve memio regions separately)
Merging driver-core/driver-core-next (c6e360a0d9d2 Revert "base: dd: don't remove driver_data in -EPROBE_DEFER case")
Merging tty/tty-next (d20bb59af646 MAINTAINERS: 8250: remove website reference)
CONFLICT (content): Merge conflict in include/uapi/linux/serial_core.h
CONFLICT (content): Merge conflict in drivers/tty/serial/Makefile
Merging usb/usb-next (60d5794fe5a5 Merge tag 'usb-serial-4.7-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/johan/usb-serial into usb-next)
Merging usb-gadget/next (2a58f9c12bb3 usb: dwc3: gadget: disable automatic calculation of ACK TP NUMP)
Merging usb-serial/usb-next (b923c6c62981 USB: serial: ti_usb_3410_5052: add MOXA UPORT 11x0 support)
Merging usb-chipidea-next/ci-for-usb-next (764763f0a0c8 doc: usb: chipidea: update the doc for OTG FSM)
Merging staging/staging-next (ffc83a79b44e Staging: emxx_udc: emxx_udc: fixed coding style issue)
CONFLICT (content): Merge conflict in drivers/staging/lustre/lustre/llite/rw26.c
Applying: staging: lustre: o2iblnd: fix for ib_map_mr_sg() API changes
Merging char-misc/char-misc-next (725d0123dfff Merge 4.6-rc7 into char-misc-testing)
Merging extcon/extcon-next (453fc627c7b5 extcon: usb-gpio: add support for ACPI gpio interface)
Merging cgroup/for-next (a6b18f07bc86 Merge branch 'for-4.6-fixes' into for-next)
Merging scsi/for-next (02714f2c73a6 Merge branch 'misc' into for-next)
Merging target-updates/for-next (54a5e73f4d6e tcm_qla2xxx Add SCSI command jammer/discard capability)
Merging target-merge/for-next-merge (2994a7518317 cxgb4: update Kconfig and Makefile)
Merging libata/for-next (a85742332511 Merge branch 'for-4.7' into for-next)
Merging pinctrl/for-next (58d73d264a02 Merge branch 'devel' into for-next)
Merging vhost/linux-next (e00f7bd22129 virtio: Silence uninitialized variable warning)
Merging remoteproc/for-next (7a6271a80cae remoteproc/wkup_m3: Use MODULE_DEVICE_TABLE to export alias)
Merging rpmsg/for-next (0259cd1b6496 Merge remote-tracking branches 'remoteproc/rpmsg-next' and 'remoteproc/rproc-next' into for-next)
Merging gpio/for-next (d30a2b47d4c2 MIPS: do away with ARCH_[WANT_OPTIONAL|REQUIRE]_GPIOLIB)
CONFLICT (content): Merge conflict in arch/mips/Kconfig
Merging dma-mapping/dma-mapping-next (d770e558e219 Linux 4.2-rc1)
Merging pwm/for-next (4295ada2fe87 Merge branch 'for-4.7/pwm-atomic' into for-next)
Merging dma-buf/for-next (12566cc35d0e Merge tag 'pci-v4.6-fixes-2' of git://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci)
Merging userns/for-next (f2ca379642d7 namei: permit linking with CAP_FOWNER in userns)
Merging ktest/for-next (f55532a0c0b8 Linux 4.6-rc1)
Merging clk/clk-next (9ffee1c4be7c clk: qcom: mmcc-8996: Remove clocks that should be controlled by RPM)
CONFLICT (content): Merge conflict in drivers/clk/Kconfig
Merging aio/master (b562e44f507e Linux 4.5)
Merging kselftest/next (6eab37daf0ec tools: testing: define the _GNU_SOURCE macro)
Merging y2038/y2038 (4b277763c5b3 vfs: Add support to document max and min inode times)
Merging luto-misc/next (afd2ff9b7e1b Linux 4.4)
Merging borntraeger/linux-next (b562e44f507e Linux 4.5)
Merging livepatching/for-next (6d9122078097 Merge branch 'for-4.7/core' into for-next)
Merging coresight/next (545a6c33f4a8 coresight: Handle build path error)
Merging rtc/rtc-next (854ec813cc23 rtc: rename so the tps6586x-rtc module can be autoloaded at boot)
Merging hwspinlock/for-next (bd5717a4632c hwspinlock: qcom: Correct msb in regmap_field)
Merging nvdimm/libnvdimm-for-next (e897b3cc7a5a Merge branch 'for-4.7/acpi6.1' into libnvdimm-for-next)
Merging akpm-current/current (a758ba862244 ipc/msg.c: use freezable blocking call)
CONFLICT (content): Merge conflict in include/linux/efi.h
CONFLICT (content): Merge conflict in arch/tile/Kconfig
CONFLICT (content): Merge conflict in arch/powerpc/include/asm/book3s/64/pgtable.h
CONFLICT (content): Merge conflict in arch/mips/kernel/process.c
CONFLICT (content): Merge conflict in arch/mips/Kconfig
CONFLICT (content): Merge conflict in arch/cris/Kconfig
Applying: mm-rename-_count-field-of-the-struct-page-to-_refcount-fix6
$ git checkout -b akpm remotes/origin/akpm/master
Applying: mm: make optimistic check for swapin readahead fix
Applying: drivers/net/wireless/intel/iwlwifi/dvm/calib.c: simplfy min() expression
Applying: mm: make mmap_sem for write waits killable for mm syscalls
Applying: mm: make vm_mmap killable
Applying: mm: make vm_munmap killable
Applying: mm, aout: handle vm_brk failures
Applying: mm, elf: handle vm_brk error
Applying: mm: make vm_brk killable
Applying: mm, proc: make clear_refs killable
Applying: mm, fork: make dup_mmap wait for mmap_sem for write killable
Applying: ipc, shm: make shmem attach/detach wait for mmap_sem killable
Applying: vdso: make arch_setup_additional_pages wait for mmap_sem for write killable
Applying: coredump: make coredump_wait wait for mmap_sem for write killable
Applying: aio: make aio_setup_ring killable
Applying: exec: make exec path waiting for mmap_sem killable
Applying: prctl: make PR_SET_THP_DISABLE wait for mmap_sem killable
Applying: uprobes: wait for mmap_sem for write killable
Applying: drm/i915: make i915_gem_mmap_ioctl wait for mmap_sem killable
Applying: drm/radeon: make radeon_mn_get wait for mmap_sem killable
Applying: drm/amdgpu: make amdgpu_mn_get wait for mmap_sem killable
Applying: drm/amdgpu: use ERR_PTR() to return from amdgpu_mn_get
Applying: kgdb: depends on VT
Merging akpm/master (240210845e20 kgdb: depends on VT)

^ permalink raw reply

* Re: linux-next: manual merge of the vfs tree with the ext4 tree
From: Theodore Ts'o @ 2016-05-17  3:16 UTC (permalink / raw)
  To: Stephen Rothwell
  Cc: Al Viro, linux-next, linux-kernel, Christoph Hellwig, Jan Kara
In-Reply-To: <20160517102355.4be4af45@canb.auug.org.au>

On Tue, May 17, 2016 at 10:23:55AM +1000, Stephen Rothwell wrote:
> Hi all,
> 
> Today's linux-next merge of the vfs tree got conflicts in:
> 
>   fs/ext4/ext4.h
>   fs/ext4/indirect.c
>   fs/ext4/inode.c
> 
> between commit:
> 
>   914f82a32d02 ("ext4: refactor direct IO code")
> 
> from the ext4 tree and commit:
> 
>   c8b8e32d700f ("direct-io: eliminate the offset argument to ->direct_IO")
> 
> from the vfs tree.
> 
> I fixed it up (hopefully - see below) and can carry the fix as
> necessary. This is now fixed as far as linux-next is concerned, but any
> non trivial conflicts should be mentioned to your upstream maintainer
> when your tree is submitted for merging.

Thanks for the heads up.  My merge resolution was backwards from yours
(because I merged the ext4 tree into vfs tree while you apparently did
the reverse), and this resolution was complex enough that I'm waiting
for you to publish next-20160517 to make sure you came up with the
same final result of fs/ext4/inode.c (minus the f2fs's ext4 crypto
merge, which I think Jaeguk is going to be dropping from his tree, but
I don't know if that will have happened by next-20160517).

I'm kicking off a set of tests to make sure there aren't problems with
the resulting merge going beyond the purely syntactic merge
resolution.

Cheers,

							- Ted

^ permalink raw reply

* linux-next: manual merge of the net-next tree with the arm64 tree
From: Stephen Rothwell @ 2016-05-17  0:24 UTC (permalink / raw)
  To: David Miller, netdev, Catalin Marinas
  Cc: linux-next, linux-kernel, Daniel Borkmann, Yang Shi, Will Deacon

Hi all,

Today's linux-next merge of the net-next tree got a conflict in:

  arch/arm64/Kconfig

between commit:

  8ee708792e1c ("arm64: Kconfig: remove redundant HAVE_ARCH_TRANSPARENT_HUGEPAGE definition")

from the arm64 tree and commit:

  6077776b5908 ("bpf: split HAVE_BPF_JIT into cBPF and eBPF variant")

from the net-next tree.

I fixed it up (see below) and can carry the fix as necessary. This
is now fixed as far as linux-next is concerned, but any non trivial
conflicts should be mentioned to your upstream maintainer when your tree
is submitted for merging.  You may also want to consider cooperating
with the maintainer of the conflicting tree to minimise any particularly
complex conflicts.

-- 
Cheers,
Stephen Rothwell

diff --cc arch/arm64/Kconfig
index 8845c0d100d7,e6761ea2feec..000000000000
--- a/arch/arm64/Kconfig
+++ b/arch/arm64/Kconfig
@@@ -59,9 -58,7 +59,9 @@@ config ARM6
  	select HAVE_ARCH_MMAP_RND_COMPAT_BITS if COMPAT
  	select HAVE_ARCH_SECCOMP_FILTER
  	select HAVE_ARCH_TRACEHOOK
 +	select HAVE_ARCH_TRANSPARENT_HUGEPAGE
 +	select HAVE_ARM_SMCCC
- 	select HAVE_BPF_JIT
+ 	select HAVE_EBPF_JIT
  	select HAVE_C_RECORDMCOUNT
  	select HAVE_CC_STACKPROTECTOR
  	select HAVE_CMPXCHG_DOUBLE

^ permalink raw reply

* linux-next: manual merge of the vfs tree with the ext4 tree
From: Stephen Rothwell @ 2016-05-17  0:23 UTC (permalink / raw)
  To: Al Viro, Theodore Ts'o
  Cc: linux-next, linux-kernel, Christoph Hellwig, Jan Kara

Hi all,

Today's linux-next merge of the vfs tree got conflicts in:

  fs/ext4/ext4.h
  fs/ext4/indirect.c
  fs/ext4/inode.c

between commit:

  914f82a32d02 ("ext4: refactor direct IO code")

from the ext4 tree and commit:

  c8b8e32d700f ("direct-io: eliminate the offset argument to ->direct_IO")

from the vfs tree.

I fixed it up (hopefully - see below) and can carry the fix as
necessary. This is now fixed as far as linux-next is concerned, but any
non trivial conflicts should be mentioned to your upstream maintainer
when your tree is submitted for merging.  You may also want to consider
cooperating with the maintainer of the conflicting tree to minimise any
particularly complex conflicts.

-- 
Cheers,
Stephen Rothwell

diff --cc fs/ext4/ext4.h
index b84aa1ca480a,72f4c9e00e97..000000000000
--- a/fs/ext4/ext4.h
+++ b/fs/ext4/ext4.h
diff --cc fs/ext4/indirect.c
index bc15c2c17633,627b7e8f9ef3..000000000000
--- a/fs/ext4/indirect.c
+++ b/fs/ext4/indirect.c
diff --cc fs/ext4/inode.c
index f9ab1e8cc416,79b298d397b4..000000000000
--- a/fs/ext4/inode.c
+++ b/fs/ext4/inode.c
@@@ -3327,13 -3334,12 +3327,13 @@@ static int ext4_end_io_dio(struct kioc
   * if the machine crashes during the write.
   *
   */
- static ssize_t ext4_direct_IO_write(struct kiocb *iocb, struct iov_iter *iter,
- 				    loff_t offset)
 -static ssize_t ext4_ext_direct_IO(struct kiocb *iocb, struct iov_iter *iter)
++static ssize_t ext4_direct_IO_write(struct kiocb *iocb, struct iov_iter *iter)
  {
  	struct file *file = iocb->ki_filp;
  	struct inode *inode = file->f_mapping->host;
 +	struct ext4_inode_info *ei = EXT4_I(inode);
  	ssize_t ret;
+ 	loff_t offset = iocb->ki_pos;
  	size_t count = iov_iter_count(iter);
  	int overwrite = 0;
  	get_block_t *get_block_func = NULL;
@@@ -3423,12 -3399,12 +3423,12 @@@
  #ifdef CONFIG_EXT4_FS_ENCRYPTION
  	BUG_ON(ext4_encrypted_inode(inode) && S_ISREG(inode->i_mode));
  #endif
 -	if (IS_DAX(inode))
 +	if (IS_DAX(inode)) {
- 		ret = dax_do_io(iocb, inode, iter, offset, get_block_func,
+ 		ret = dax_do_io(iocb, inode, iter, get_block_func,
  				ext4_end_io_dio, dio_flags);
 -	else
 +	} else
  		ret = __blockdev_direct_IO(iocb, inode,
- 					   inode->i_sb->s_bdev, iter, offset,
+ 					   inode->i_sb->s_bdev, iter,
  					   get_block_func,
  					   ext4_end_io_dio, NULL, dio_flags);
  
@@@ -3451,82 -3428,6 +3451,82 @@@
  	if (overwrite)
  		inode_lock(inode);
  
 +	if (ret < 0 && final_size > inode->i_size)
 +		ext4_truncate_failed_write(inode);
 +
 +	/* Handle extending of i_size after direct IO write */
 +	if (orphan) {
 +		int err;
 +
 +		/* Credits for sb + inode write */
 +		handle = ext4_journal_start(inode, EXT4_HT_INODE, 2);
 +		if (IS_ERR(handle)) {
 +			/* This is really bad luck. We've written the data
 +			 * but cannot extend i_size. Bail out and pretend
 +			 * the write failed... */
 +			ret = PTR_ERR(handle);
 +			if (inode->i_nlink)
 +				ext4_orphan_del(NULL, inode);
 +
 +			goto out;
 +		}
 +		if (inode->i_nlink)
 +			ext4_orphan_del(handle, inode);
 +		if (ret > 0) {
 +			loff_t end = offset + ret;
 +			if (end > inode->i_size) {
 +				ei->i_disksize = end;
 +				i_size_write(inode, end);
 +				/*
 +				 * We're going to return a positive `ret'
 +				 * here due to non-zero-length I/O, so there's
 +				 * no way of reporting error returns from
 +				 * ext4_mark_inode_dirty() to userspace.  So
 +				 * ignore it.
 +				 */
 +				ext4_mark_inode_dirty(handle, inode);
 +			}
 +		}
 +		err = ext4_journal_stop(handle);
 +		if (ret == 0)
 +			ret = err;
 +	}
 +out:
 +	return ret;
 +}
 +
- static ssize_t ext4_direct_IO_read(struct kiocb *iocb, struct iov_iter *iter,
- 				   loff_t offset)
++static ssize_t ext4_direct_IO_read(struct kiocb *iocb, struct iov_iter *iter)
 +{
 +	int unlocked = 0;
 +	struct inode *inode = iocb->ki_filp->f_mapping->host;
++	loff_t offset = iocb->ki_pos;
 +	ssize_t ret;
 +
 +	if (ext4_should_dioread_nolock(inode)) {
 +		/*
 +		 * Nolock dioread optimization may be dynamically disabled
 +		 * via ext4_inode_block_unlocked_dio(). Check inode's state
 +		 * while holding extra i_dio_count ref.
 +		 */
 +		inode_dio_begin(inode);
 +		smp_mb();
 +		if (unlikely(ext4_test_inode_state(inode,
 +						    EXT4_STATE_DIOREAD_LOCK)))
 +			inode_dio_end(inode);
 +		else
 +			unlocked = 1;
 +	}
 +	if (IS_DAX(inode)) {
- 		ret = dax_do_io(iocb, inode, iter, offset, ext4_dio_get_block,
++		ret = dax_do_io(iocb, inode, iter, ext4_dio_get_block,
 +				NULL, unlocked ? 0 : DIO_LOCKING);
 +	} else {
 +		ret = __blockdev_direct_IO(iocb, inode, inode->i_sb->s_bdev,
- 					   iter, offset, ext4_dio_get_block,
++					   iter, ext4_dio_get_block,
 +					   NULL, NULL,
 +					   unlocked ? 0 : DIO_LOCKING);
 +	}
 +	if (unlocked)
 +		inode_dio_end(inode);
  	return ret;
  }
  
@@@ -3554,10 -3455,10 +3554,10 @@@ static ssize_t ext4_direct_IO(struct ki
  		return 0;
  
  	trace_ext4_direct_IO_enter(inode, offset, count, iov_iter_rw(iter));
 -	if (ext4_test_inode_flag(inode, EXT4_INODE_EXTENTS))
 -		ret = ext4_ext_direct_IO(iocb, iter);
 +	if (iov_iter_rw(iter) == READ)
- 		ret = ext4_direct_IO_read(iocb, iter, offset);
++		ret = ext4_direct_IO_read(iocb, iter);
  	else
- 		ret = ext4_direct_IO_write(iocb, iter, offset);
 -		ret = ext4_ind_direct_IO(iocb, iter);
++		ret = ext4_direct_IO_write(iocb, iter);
  	trace_ext4_direct_IO_exit(inode, offset, count, iov_iter_rw(iter), ret);
  	return ret;
  }

^ permalink raw reply

* Re: linux-next: manual merge of the f2fs tree with the ext4 tree
From: Theodore Ts'o @ 2016-05-16 23:55 UTC (permalink / raw)
  To: Jaegeuk Kim; +Cc: Stephen Rothwell, linux-next, linux-kernel, Daeho Jeong
In-Reply-To: <20160516222241.GA40269@jaegeuk.gateway>

On Mon, May 16, 2016 at 03:22:41PM -0700, Jaegeuk Kim wrote:
> > Sorry, I just ran out of time to try to verify that the patch wouldn't
> > break anything, and given that we're going to need to wait for
> > "fscrypto/f2fs: allow fs-specific key prefix for fs encryption" to go
> > upstream.
> 
> Agreed. IIUC, let me push the fscrypto/f2fs patch to v4.7 first?

Right --- that's in linux-next already, right?  And currently it's a
combined fscrypto/f2fs patch, which is why I suspect letting it go
into v4.7 first makes sense.  I'll make sure the ext4 move to
fs/crypto will be one of the first development patches for 4.8 (modulo
any urgent bug fixes that need to go into 4.7 final first).

> I have no planned patch right now, and of course, it must have no problem for
> you to treat with further patches.
> Also, let me take a look at any missing part again, regarding to your concerns.

I'm sure there may be some missing pieces around using file system
level crypto for the desktop / server use case.  Some of them are in
how we handle removable thumb drives, for example.

There are definitely some missing pieces about how to handle removable
SD cards for Android, as well, including some kernel-side patches that
are currently living in the unstable portion of the ext4 patch queue.
We never got the design, implementation and kernel<->userspace API's
fully baked, so that's not going upstream any time soon, but all of
this means that we will need to figure out what's the best way to
develop, test, and push fs/crypto changes in the long term.  This may
mean a new git tree with shared maintenance, as one way that we could
do things.

       		       	       	       	     - Ted

^ permalink raw reply

* Re: linux-next: manual merge of the f2fs tree with the ext4 tree
From: Jaegeuk Kim @ 2016-05-16 22:22 UTC (permalink / raw)
  To: Theodore Ts'o, Stephen Rothwell, linux-next, linux-kernel,
	Daeho Jeong
In-Reply-To: <20160516213028.GO7799@thunk.org>

On Mon, May 16, 2016 at 05:30:28PM -0400, Theodore Ts'o wrote:
> On Mon, May 09, 2016 at 10:15:03AM -0700, Jaegeuk Kim wrote:
> > Hi Stephen,
> > 
> > Thank you for the notice.
> > I've been waiting for a comment about the below patch targeted to v4.7 from Ted.
> > Meanwhile, I intended to prepare -next for that patch in advance.
> > Surely, once I get a sense that I need to consider v4.8, I'll drop this patch
> > for -next right away.
> 
> Yeah, I think it would be better for me to take the ext4 "migrate into
> vfs's crypto engine" patch, and at this point, for 4.8.

Fair enough.

> Sorry, I just ran out of time to try to verify that the patch wouldn't
> break anything, and given that we're going to need to wait for
> "fscrypto/f2fs: allow fs-specific key prefix for fs encryption" to go
> upstream.

Agreed. IIUC, let me push the fscrypto/f2fs patch to v4.7 first?

> Do you have any other planned changes for the fscrypto tree planned
> for 4.8.  If not, then perhaps it will be easier if I take the pen for
> any changes needed for fs/crypto, and moving forward, we probably need
> to find ways to make changes where commits specific for fs/crypto
> should be isolated from ext4 or f2fs changes, and as much as possible
> to be backwards compatible so that as we add new features to
> fs/crypto, we don't need to synchronize changes across multiple file
> systems.

I have no planned patch right now, and of course, it must have no problem for
you to treat with further patches.
Also, let me take a look at any missing part again, regarding to your concerns.

Thanks,

^ permalink raw reply

* Re: linux-next: manual merge of the f2fs tree with the ext4 tree
From: Theodore Ts'o @ 2016-05-16 21:30 UTC (permalink / raw)
  To: Jaegeuk Kim; +Cc: Stephen Rothwell, linux-next, linux-kernel, Daeho Jeong
In-Reply-To: <20160509171503.GA810@jaegeuk.gateway>

On Mon, May 09, 2016 at 10:15:03AM -0700, Jaegeuk Kim wrote:
> Hi Stephen,
> 
> Thank you for the notice.
> I've been waiting for a comment about the below patch targeted to v4.7 from Ted.
> Meanwhile, I intended to prepare -next for that patch in advance.
> Surely, once I get a sense that I need to consider v4.8, I'll drop this patch
> for -next right away.

Yeah, I think it would be better for me to take the ext4 "migrate into
vfs's crypto engine" patch, and at this point, for 4.8.

Sorry, I just ran out of time to try to verify that the patch wouldn't
break anything, and given that we're going to need to wait for
"fscrypto/f2fs: allow fs-specific key prefix for fs encryption" to go
upstream.

Do you have any other planned changes for the fscrypto tree planned
for 4.8.  If not, then perhaps it will be easier if I take the pen for
any changes needed for fs/crypto, and moving forward, we probably need
to find ways to make changes where commits specific for fs/crypto
should be isolated from ext4 or f2fs changes, and as much as possible
to be backwards compatible so that as we add new features to
fs/crypto, we don't need to synchronize changes across multiple file
systems.

Cheers,

						- Ted

^ permalink raw reply

* Re: linux-next: manual merge of the wireless-drivers-next tree with the net-next tree
From: David Miller @ 2016-05-16 15:09 UTC (permalink / raw)
  To: kvalo; +Cc: sfr, netdev, linux-next, linux-kernel, linux-wireless,
	luciano.coelho
In-Reply-To: <871t529mik.fsf@kamboji.qca.qualcomm.com>

From: Kalle Valo <kvalo@codeaurora.org>
Date: Mon, 16 May 2016 16:10:27 +0300

> I wasn't expecting that skb_info variable is removed. Do we now have
> merge damage somewhere? Luca, what do you think?

It's possible I got the net --> net-next merge wrong the other day, feel
free to send me an appropriate fixup.

Thanks.

^ permalink raw reply

* Re: linux-next: manual merge of the wireless-drivers-next tree with the net-next tree
From: Kalle Valo @ 2016-05-16 13:58 UTC (permalink / raw)
  To: Coelho, Luciano
  Cc: sfr@canb.auug.org.au, linux-wireless@vger.kernel.org,
	davem@davemloft.net, netdev@vger.kernel.org,
	linux-next@vger.kernel.org, linux-kernel@vger.kernel.org,
	emmanuel.grumbach
In-Reply-To: <1463405875.25219.98.camel@intel.com>

"Coelho, Luciano" <luciano.coelho@intel.com> writes:

(dropping damaged diffs etc, adding Emmanuel as the author of
5c08b0f5026f ("iwlwifi: mvm: don't override the rate with the AMSDU
len"))

>> I wasn't expecting that skb_info variable is removed. Do we now have
>> merge damage somewhere? Luca, what do you think?
>
> As we discussed on IRC, it seems to me that there was a merge damage
> when Dave merged net.git into net-next.git (as you mostly found out ;).
>
> I'm not sure how to solve that, but I'm sure you and Dave can figure
> something out. :) Please let me know if you need any help with it.

Yeah, I guess in net-next.git Dave assumed that 'info == skb_info' is
always valid in iwl_mvm_set_tx_cmd(), but I don't that's the case. So I
think the end case, after a merge, should look like this:

void iwl_mvm_set_tx_cmd(struct iwl_mvm *mvm, struct sk_buff *skb,
			struct iwl_tx_cmd *tx_cmd,
			struct ieee80211_tx_info *info, u8 sta_id)
{
	struct ieee80211_tx_info *skb_info = IEEE80211_SKB_CB(skb);
	struct ieee80211_hdr *hdr = (void *)skb->data;
	__le16 fc = hdr->frame_control;
	u32 tx_flags = le32_to_cpu(tx_cmd->tx_flags);
	u32 len = skb->len + FCS_LEN;
	u8 ac;

[...]

	tx_cmd->tx_flags = cpu_to_le32(tx_flags);
	/* Total # bytes to be transmitted */
	tx_cmd->len = cpu_to_le16((u16)skb->len +
		(uintptr_t)skb_info->driver_data[0]);
	tx_cmd->life_time = cpu_to_le32(TX_CMD_LIFE_TIME_INFINITE);
	tx_cmd->sta_id = sta_id;

I'm going to propose this to Dave in my pending pull request[1]. But I
would appreciate if someone else would double check this.

[1] https://patchwork.ozlabs.org/patch/621953/

-- 
Kalle Valo

^ permalink raw reply

* Re: linux-next: manual merge of the wireless-drivers-next tree with the net-next tree
From: Coelho, Luciano @ 2016-05-16 13:37 UTC (permalink / raw)
  To: sfr@canb.auug.org.au, kvalo@codeaurora.org
  Cc: linux-wireless@vger.kernel.org, davem@davemloft.net,
	netdev@vger.kernel.org, linux-next@vger.kernel.org,
	linux-kernel@vger.kernel.org
In-Reply-To: <871t529mik.fsf@kamboji.qca.qualcomm.com>

Hi Kalle,

On Mon, 2016-05-16 at 16:10 +0300, Kalle Valo wrote:
> (Adding Luca and linux-wireless)
> 
> Stephen Rothwell <sfr@canb.auug.org.au> writes:
> 
> > 
> > Today's linux-next merge of the wireless-drivers-next tree got a
> > conflict in:
> > 
> >   drivers/net/wireless/intel/iwlwifi/mvm/tx.c
> > 
> > between commit:
> > 
> >   909b27f70643 ("Merge
> > git://git.kernel.org/pub/scm/linux/kernel/git/davem/net")
> > 
> > from the net-next tree and commit:
> > 
> >   a525d0eab17d ("Merge tag 'iwlwifi-for-kalle-2016-05-04' of
> > git://git.kernel.org/pub/scm/linux/kernel/git/iwlwifi/iwlwifi-
> > fixes")
> > 
> > from the wireless-drivers-next tree.
> > 
> > I fixed it up (I think that the net-next tree merge lost the
> > changes
> > to iwl_mvm_set_tx_cmd() associated with commit 5c08b0f5026f
> > ("iwlwifi:
> > mvm: don't override the rate with the AMSDU len")) and can carry
> > the
> > fix as necessary.
> Hmm, I'm starting to suspect something is wrong. I did a test merge
> of
> net-next and wireless-drivers-next and got this as a diff after the
> merge:
> 
> --- a/drivers/net/wireless/intel/iwlwifi/mvm/tx.c
> +++ b/drivers/net/wireless/intel/iwlwifi/mvm/tx.c
> @@ -211,7 +211,6 @@ void iwl_mvm_set_tx_cmd(struct iwl_mvm *mvm,
> struct sk_buff *skb,
>                         struct iwl_tx_cmd *tx_cmd,
>                         struct ieee80211_tx_info *info, u8 sta_id)
>  {
> -       struct ieee80211_tx_info *skb_info = IEEE80211_SKB_CB(skb);
>         struct ieee80211_hdr *hdr = (void *)skb->data;
>         __le16 fc = hdr->frame_control;
>         u32 tx_flags = le32_to_cpu(tx_cmd->tx_flags);
> @@ -295,7 +294,7 @@ void iwl_mvm_set_tx_cmd(struct iwl_mvm *mvm,
> struct sk_buff *skb,
>         tx_cmd->tx_flags = cpu_to_le32(tx_flags);
>         /* Total # bytes to be transmitted */
>         tx_cmd->len = cpu_to_le16((u16)skb->len +
> -               (uintptr_t)skb_info->driver_data[0]);
> +               (uintptr_t)info->driver_data[0]);
>         tx_cmd->life_time = cpu_to_le32(TX_CMD_LIFE_TIME_INFINITE);
>         tx_cmd->sta_id = sta_id;
> 
> But commit 5c08b0f5026f ("iwlwifi: mvm: don't override the rate with
> the
> AMSDU len") specifically added skb_info variable to that function:
> 
> @@ -105,6 +105,7 @@ void iwl_mvm_set_tx_cmd(struct iwl_mvm *mvm,
> struct sk_buff *skb,
>                         struct iwl_tx_cmd *tx_cmd,
>                         struct ieee80211_tx_info *info, u8 sta_id)
>  {
> +       struct ieee80211_tx_info *skb_info = IEEE80211_SKB_CB(skb);
>         struct ieee80211_hdr *hdr = (void *)skb->data;
>         __le16 fc = hdr->frame_control;
>         u32 tx_flags = le32_to_cpu(tx_cmd->tx_flags);
> @@ -185,7 +186,7 @@ void iwl_mvm_set_tx_cmd(struct iwl_mvm *mvm,
> struct sk_buff *skb,
>         tx_cmd->tx_flags = cpu_to_le32(tx_flags);
>         /* Total # bytes to be transmitted */
>         tx_cmd->len = cpu_to_le16((u16)skb->len +
> -               (uintptr_t)info->driver_data[0]);
> +               (uintptr_t)skb_info->driver_data[0]);
>         tx_cmd->next_frame_len = 0;
>         tx_cmd->life_time = cpu_to_le32(TX_CMD_LIFE_TIME_INFINITE);
>         tx_cmd->sta_id = sta_id;
> 
> I wasn't expecting that skb_info variable is removed. Do we now have
> merge damage somewhere? Luca, what do you think?

As we discussed on IRC, it seems to me that there was a merge damage
when Dave merged net.git into net-next.git (as you mostly found out ;).

I'm not sure how to solve that, but I'm sure you and Dave can figure
something out. :) Please let me know if you need any help with it.

--
Cheers,
Luca.

^ permalink raw reply

* Re: linux-next: manual merge of the wireless-drivers-next tree with the net-next tree
From: Kalle Valo @ 2016-05-16 13:10 UTC (permalink / raw)
  To: Stephen Rothwell
  Cc: David Miller, netdev, linux-next, linux-kernel, linux-wireless,
	luciano.coelho
In-Reply-To: <20160516101606.751f9613@canb.auug.org.au>

(Adding Luca and linux-wireless)

Stephen Rothwell <sfr@canb.auug.org.au> writes:

> Today's linux-next merge of the wireless-drivers-next tree got a
> conflict in:
>
>   drivers/net/wireless/intel/iwlwifi/mvm/tx.c
>
> between commit:
>
>   909b27f70643 ("Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net")
>
> from the net-next tree and commit:
>
>   a525d0eab17d ("Merge tag 'iwlwifi-for-kalle-2016-05-04' of git://git.kernel.org/pub/scm/linux/kernel/git/iwlwifi/iwlwifi-fixes")
>
> from the wireless-drivers-next tree.
>
> I fixed it up (I think that the net-next tree merge lost the changes
> to iwl_mvm_set_tx_cmd() associated with commit 5c08b0f5026f ("iwlwifi:
> mvm: don't override the rate with the AMSDU len")) and can carry the
> fix as necessary.

Hmm, I'm starting to suspect something is wrong. I did a test merge of
net-next and wireless-drivers-next and got this as a diff after the
merge:

--- a/drivers/net/wireless/intel/iwlwifi/mvm/tx.c
+++ b/drivers/net/wireless/intel/iwlwifi/mvm/tx.c
@@ -211,7 +211,6 @@ void iwl_mvm_set_tx_cmd(struct iwl_mvm *mvm, struct sk_buff *skb,
                        struct iwl_tx_cmd *tx_cmd,
                        struct ieee80211_tx_info *info, u8 sta_id)
 {
-       struct ieee80211_tx_info *skb_info = IEEE80211_SKB_CB(skb);
        struct ieee80211_hdr *hdr = (void *)skb->data;
        __le16 fc = hdr->frame_control;
        u32 tx_flags = le32_to_cpu(tx_cmd->tx_flags);
@@ -295,7 +294,7 @@ void iwl_mvm_set_tx_cmd(struct iwl_mvm *mvm, struct sk_buff *skb,
        tx_cmd->tx_flags = cpu_to_le32(tx_flags);
        /* Total # bytes to be transmitted */
        tx_cmd->len = cpu_to_le16((u16)skb->len +
-               (uintptr_t)skb_info->driver_data[0]);
+               (uintptr_t)info->driver_data[0]);
        tx_cmd->life_time = cpu_to_le32(TX_CMD_LIFE_TIME_INFINITE);
        tx_cmd->sta_id = sta_id;

But commit 5c08b0f5026f ("iwlwifi: mvm: don't override the rate with the
AMSDU len") specifically added skb_info variable to that function:

@@ -105,6 +105,7 @@ void iwl_mvm_set_tx_cmd(struct iwl_mvm *mvm, struct sk_buff *skb,
                        struct iwl_tx_cmd *tx_cmd,
                        struct ieee80211_tx_info *info, u8 sta_id)
 {
+       struct ieee80211_tx_info *skb_info = IEEE80211_SKB_CB(skb);
        struct ieee80211_hdr *hdr = (void *)skb->data;
        __le16 fc = hdr->frame_control;
        u32 tx_flags = le32_to_cpu(tx_cmd->tx_flags);
@@ -185,7 +186,7 @@ void iwl_mvm_set_tx_cmd(struct iwl_mvm *mvm, struct sk_buff *skb,
        tx_cmd->tx_flags = cpu_to_le32(tx_flags);
        /* Total # bytes to be transmitted */
        tx_cmd->len = cpu_to_le16((u16)skb->len +
-               (uintptr_t)info->driver_data[0]);
+               (uintptr_t)skb_info->driver_data[0]);
        tx_cmd->next_frame_len = 0;
        tx_cmd->life_time = cpu_to_le32(TX_CMD_LIFE_TIME_INFINITE);
        tx_cmd->sta_id = sta_id;

I wasn't expecting that skb_info variable is removed. Do we now have
merge damage somewhere? Luca, what do you think?

-- 
Kalle Valo

^ permalink raw reply

* [PATCH] MIPS: Fix VZ probe gas errors with binutils <2.24
From: James Hogan @ 2016-05-16 11:50 UTC (permalink / raw)
  To: Ralf Baechle
  Cc: Guenter Roeck, linux-kernel, linux-next, James Hogan, linux-mips
In-Reply-To: <57374216.10307@roeck-us.net>

The VZ guest register & TLB access macros introduced in commit "MIPS:
Add guest CP0 accessors" use VZ ASE specific instructions that aren't
understood by versions of binutils prior to 2.24.

Add a check for whether the toolchain supports the -mvirt option,
similar to the MSA toolchain check, and implement the accessors using
.word if not.

Due to difficulty in converting compiler specified registers (e.g. "$3")
to usable numbers (e.g. "3") in inline asm, we need to copy to/from a
temporary register, namely the assembler temporary (at/$1), and specify
guest CP0 registers numerically in the gc0 macros.

Fixes: 7eb91118227d ("MIPS: Add guest CP0 accessors")
Signed-off-by: James Hogan <james.hogan@imgtec.com>
Reported-by: Guenter Roeck <linux@roeck-us.net>
Cc: Ralf Baechle <ralf@linux-mips.org>
Cc: linux-mips@linux-mips.org
---
Ralf: If it isn't too late, can this to be squashed into the "MIPS: Add
guest CP0 accessors" commit?
---
 arch/mips/Makefile               |   2 +
 arch/mips/include/asm/mipsregs.h | 475 ++++++++++++++++++++++++---------------
 2 files changed, 296 insertions(+), 181 deletions(-)

diff --git a/arch/mips/Makefile b/arch/mips/Makefile
index c0b002a09bef..efd7a9dc93c4 100644
--- a/arch/mips/Makefile
+++ b/arch/mips/Makefile
@@ -200,6 +200,8 @@ ifeq ($(CONFIG_CPU_HAS_MSA),y)
 toolchain-msa				:= $(call cc-option-yn,$(mips-cflags) -mhard-float -mfp64 -Wa$(comma)-mmsa)
 cflags-$(toolchain-msa)			+= -DTOOLCHAIN_SUPPORTS_MSA
 endif
+toolchain-virt				:= $(call cc-option-yn,$(mips-cflags) -mvirt)
+cflags-$(toolchain-virt)		+= -DTOOLCHAIN_SUPPORTS_VIRT
 
 cflags-$(CONFIG_MIPS_COMPACT_BRANCHES_NEVER)	+= -mcompact-branches=never
 cflags-$(CONFIG_MIPS_COMPACT_BRANCHES_OPTIMAL)	+= -mcompact-branches=optimal
diff --git a/arch/mips/include/asm/mipsregs.h b/arch/mips/include/asm/mipsregs.h
index 1019de6bb2a8..25d01577d0b5 100644
--- a/arch/mips/include/asm/mipsregs.h
+++ b/arch/mips/include/asm/mipsregs.h
@@ -1683,15 +1683,18 @@ do {									\
  * Macros to access the guest system control coprocessor
  */
 
+#ifdef TOOLCHAIN_SUPPORTS_VIRT
+
 #define __read_32bit_gc0_register(source, sel)				\
 ({ int __res;								\
 	__asm__ __volatile__(						\
 		".set\tpush\n\t"					\
 		".set\tmips32r2\n\t"					\
 		".set\tvirt\n\t"					\
-		"mfgc0\t%0, " #source ", " #sel "\n\t"			\
+		"mfgc0\t%0, $%1, %2\n\t"				\
 		".set\tpop"						\
-		: "=r" (__res));					\
+		: "=r" (__res)						\
+		: "i" (source), "i" (sel));				\
 	__res;								\
 })
 
@@ -1701,9 +1704,10 @@ do {									\
 		".set\tpush\n\t"					\
 		".set\tmips64r2\n\t"					\
 		".set\tvirt\n\t"					\
-		"dmfgc0\t%0, " #source ", " #sel "\n\t"			\
+		"dmfgc0\t%0, $%1, %2\n\t"			\
 		".set\tpop"						\
-		: "=r" (__res));					\
+		: "=r" (__res)						\
+		: "i" (source), "i" (sel));				\
 	__res;								\
 })
 
@@ -1713,9 +1717,10 @@ do {									\
 		".set\tpush\n\t"					\
 		".set\tmips32r2\n\t"					\
 		".set\tvirt\n\t"					\
-		"mtgc0\t%z0, " #register ", " #sel "\n\t"		\
+		"mtgc0\t%z0, $%1, %2\n\t"				\
 		".set\tpop"						\
-		: : "Jr" ((unsigned int)(value)));			\
+		: : "Jr" ((unsigned int)(value)),			\
+		    "i" (register), "i" (sel));				\
 } while (0)
 
 #define __write_64bit_gc0_register(register, sel, value)		\
@@ -1724,11 +1729,70 @@ do {									\
 		".set\tpush\n\t"					\
 		".set\tmips64r2\n\t"					\
 		".set\tvirt\n\t"					\
-		"dmtgc0\t%z0, " #register ", " #sel "\n\t"		\
+		"dmtgc0\t%z0, $%1, %2\n\t"				\
 		".set\tpop"						\
-		: : "Jr" (value));					\
+		: : "Jr" (value),					\
+		    "i" (register), "i" (sel));				\
 } while (0)
 
+#else	/* TOOLCHAIN_SUPPORTS_VIRT */
+
+#define __read_32bit_gc0_register(source, sel)				\
+({ int __res;								\
+	__asm__ __volatile__(						\
+		".set\tpush\n\t"					\
+		".set\tnoat\n\t"					\
+		"# mfgc0\t$1, $%1, %2\n\t"				\
+		".word\t(0x40610000 | %1 << 11 | %2)\n\t"		\
+		"move\t%0, $1\n\t"					\
+		".set\tpop"						\
+		: "=r" (__res)						\
+		: "i" (source), "i" (sel));				\
+	__res;								\
+})
+
+#define __read_64bit_gc0_register(source, sel)				\
+({ unsigned long long __res;						\
+	__asm__ __volatile__(						\
+		".set\tpush\n\t"					\
+		".set\tnoat\n\t"					\
+		"# dmfgc0\t$1, $%1, %2\n\t"				\
+		".word\t(0x40610100 | %1 << 11 | %2)\n\t"		\
+		"move\t%0, $1\n\t"					\
+		".set\tpop"						\
+		: "=r" (__res)						\
+		: "i" (source), "i" (sel));				\
+	__res;								\
+})
+
+#define __write_32bit_gc0_register(register, sel, value)		\
+do {									\
+	__asm__ __volatile__(						\
+		".set\tpush\n\t"					\
+		".set\tnoat\n\t"					\
+		"move\t$1, %0\n\t"					\
+		"# mtgc0\t$1, $%1, %2\n\t"				\
+		".word\t(0x40610200 | %1 << 11 | %2)\n\t"		\
+		".set\tpop"						\
+		: : "Jr" ((unsigned int)(value)),			\
+		    "i" (register), "i" (sel));				\
+} while (0)
+
+#define __write_64bit_gc0_register(register, sel, value)		\
+do {									\
+	__asm__ __volatile__(						\
+		".set\tpush\n\t"					\
+		".set\tnoat\n\t"					\
+		"move\t$1, %0\n\t"					\
+		"# dmtgc0\t$1, $%1, %2\n\t"				\
+		".word\t(0x40610300 | %1 << 11 | %2)\n\t"		\
+		".set\tpop"						\
+		: : "Jr" (value),					\
+		    "i" (register), "i" (sel));				\
+} while (0)
+
+#endif	/* !TOOLCHAIN_SUPPORTS_VIRT */
+
 #define __read_ulong_gc0_register(reg, sel)				\
 	((sizeof(unsigned long) == 4) ?					\
 	(unsigned long) __read_32bit_gc0_register(reg, sel) :		\
@@ -1742,189 +1806,189 @@ do {									\
 		__write_64bit_gc0_register(reg, sel, val);		\
 } while (0)
 
-#define read_gc0_index()		__read_32bit_gc0_register($0, 0)
-#define write_gc0_index(val)		__write_32bit_gc0_register($0, 0, val)
+#define read_gc0_index()		__read_32bit_gc0_register(0, 0)
+#define write_gc0_index(val)		__write_32bit_gc0_register(0, 0, val)
 
-#define read_gc0_entrylo0()		__read_ulong_gc0_register($2, 0)
-#define write_gc0_entrylo0(val)		__write_ulong_gc0_register($2, 0, val)
+#define read_gc0_entrylo0()		__read_ulong_gc0_register(2, 0)
+#define write_gc0_entrylo0(val)		__write_ulong_gc0_register(2, 0, val)
 
-#define read_gc0_entrylo1()		__read_ulong_gc0_register($3, 0)
-#define write_gc0_entrylo1(val)		__write_ulong_gc0_register($3, 0, val)
+#define read_gc0_entrylo1()		__read_ulong_gc0_register(3, 0)
+#define write_gc0_entrylo1(val)		__write_ulong_gc0_register(3, 0, val)
 
-#define read_gc0_context()		__read_ulong_gc0_register($4, 0)
-#define write_gc0_context(val)		__write_ulong_gc0_register($4, 0, val)
+#define read_gc0_context()		__read_ulong_gc0_register(4, 0)
+#define write_gc0_context(val)		__write_ulong_gc0_register(4, 0, val)
 
-#define read_gc0_contextconfig()	__read_32bit_gc0_register($4, 1)
-#define write_gc0_contextconfig(val)	__write_32bit_gc0_register($4, 1, val)
+#define read_gc0_contextconfig()	__read_32bit_gc0_register(4, 1)
+#define write_gc0_contextconfig(val)	__write_32bit_gc0_register(4, 1, val)
 
-#define read_gc0_userlocal()		__read_ulong_gc0_register($4, 2)
-#define write_gc0_userlocal(val)	__write_ulong_gc0_register($4, 2, val)
+#define read_gc0_userlocal()		__read_ulong_gc0_register(4, 2)
+#define write_gc0_userlocal(val)	__write_ulong_gc0_register(4, 2, val)
 
-#define read_gc0_xcontextconfig()	__read_ulong_gc0_register($4, 3)
-#define write_gc0_xcontextconfig(val)	__write_ulong_gc0_register($4, 3, val)
+#define read_gc0_xcontextconfig()	__read_ulong_gc0_register(4, 3)
+#define write_gc0_xcontextconfig(val)	__write_ulong_gc0_register(4, 3, val)
 
-#define read_gc0_pagemask()		__read_32bit_gc0_register($5, 0)
-#define write_gc0_pagemask(val)		__write_32bit_gc0_register($5, 0, val)
+#define read_gc0_pagemask()		__read_32bit_gc0_register(5, 0)
+#define write_gc0_pagemask(val)		__write_32bit_gc0_register(5, 0, val)
 
-#define read_gc0_pagegrain()		__read_32bit_gc0_register($5, 1)
-#define write_gc0_pagegrain(val)	__write_32bit_gc0_register($5, 1, val)
+#define read_gc0_pagegrain()		__read_32bit_gc0_register(5, 1)
+#define write_gc0_pagegrain(val)	__write_32bit_gc0_register(5, 1, val)
 
-#define read_gc0_segctl0()		__read_ulong_gc0_register($5, 2)
-#define write_gc0_segctl0(val)		__write_ulong_gc0_register($5, 2, val)
+#define read_gc0_segctl0()		__read_ulong_gc0_register(5, 2)
+#define write_gc0_segctl0(val)		__write_ulong_gc0_register(5, 2, val)
 
-#define read_gc0_segctl1()		__read_ulong_gc0_register($5, 3)
-#define write_gc0_segctl1(val)		__write_ulong_gc0_register($5, 3, val)
-
-#define read_gc0_segctl2()		__read_ulong_gc0_register($5, 4)
-#define write_gc0_segctl2(val)		__write_ulong_gc0_register($5, 4, val)
-
-#define read_gc0_pwbase()		__read_ulong_gc0_register($5, 5)
-#define write_gc0_pwbase(val)		__write_ulong_gc0_register($5, 5, val)
-
-#define read_gc0_pwfield()		__read_ulong_gc0_register($5, 6)
-#define write_gc0_pwfield(val)		__write_ulong_gc0_register($5, 6, val)
-
-#define read_gc0_pwsize()		__read_ulong_gc0_register($5, 7)
-#define write_gc0_pwsize(val)		__write_ulong_gc0_register($5, 7, val)
-
-#define read_gc0_wired()		__read_32bit_gc0_register($6, 0)
-#define write_gc0_wired(val)		__write_32bit_gc0_register($6, 0, val)
-
-#define read_gc0_pwctl()		__read_32bit_gc0_register($6, 6)
-#define write_gc0_pwctl(val)		__write_32bit_gc0_register($6, 6, val)
-
-#define read_gc0_hwrena()		__read_32bit_gc0_register($7, 0)
-#define write_gc0_hwrena(val)		__write_32bit_gc0_register($7, 0, val)
-
-#define read_gc0_badvaddr()		__read_ulong_gc0_register($8, 0)
-#define write_gc0_badvaddr(val)		__write_ulong_gc0_register($8, 0, val)
-
-#define read_gc0_badinstr()		__read_32bit_gc0_register($8, 1)
-#define write_gc0_badinstr(val)		__write_32bit_gc0_register($8, 1, val)
-
-#define read_gc0_badinstrp()		__read_32bit_gc0_register($8, 2)
-#define write_gc0_badinstrp(val)	__write_32bit_gc0_register($8, 2, val)
-
-#define read_gc0_count()		__read_32bit_gc0_register($9, 0)
-
-#define read_gc0_entryhi()		__read_ulong_gc0_register($10, 0)
-#define write_gc0_entryhi(val)		__write_ulong_gc0_register($10, 0, val)
-
-#define read_gc0_compare()		__read_32bit_gc0_register($11, 0)
-#define write_gc0_compare(val)		__write_32bit_gc0_register($11, 0, val)
-
-#define read_gc0_status()		__read_32bit_gc0_register($12, 0)
-#define write_gc0_status(val)		__write_32bit_gc0_register($12, 0, val)
-
-#define read_gc0_intctl()		__read_32bit_gc0_register($12, 1)
-#define write_gc0_intctl(val)		__write_32bit_gc0_register($12, 1, val)
-
-#define read_gc0_cause()		__read_32bit_gc0_register($13, 0)
-#define write_gc0_cause(val)		__write_32bit_gc0_register($13, 0, val)
-
-#define read_gc0_epc()			__read_ulong_gc0_register($14, 0)
-#define write_gc0_epc(val)		__write_ulong_gc0_register($14, 0, val)
-
-#define read_gc0_ebase()		__read_32bit_gc0_register($15, 1)
-#define write_gc0_ebase(val)		__write_32bit_gc0_register($15, 1, val)
-
-#define read_gc0_ebase_64()		__read_64bit_gc0_register($15, 1)
-#define write_gc0_ebase_64(val)		__write_64bit_gc0_register($15, 1, val)
-
-#define read_gc0_config()		__read_32bit_gc0_register($16, 0)
-#define read_gc0_config1()		__read_32bit_gc0_register($16, 1)
-#define read_gc0_config2()		__read_32bit_gc0_register($16, 2)
-#define read_gc0_config3()		__read_32bit_gc0_register($16, 3)
-#define read_gc0_config4()		__read_32bit_gc0_register($16, 4)
-#define read_gc0_config5()		__read_32bit_gc0_register($16, 5)
-#define read_gc0_config6()		__read_32bit_gc0_register($16, 6)
-#define read_gc0_config7()		__read_32bit_gc0_register($16, 7)
-#define write_gc0_config(val)		__write_32bit_gc0_register($16, 0, val)
-#define write_gc0_config1(val)		__write_32bit_gc0_register($16, 1, val)
-#define write_gc0_config2(val)		__write_32bit_gc0_register($16, 2, val)
-#define write_gc0_config3(val)		__write_32bit_gc0_register($16, 3, val)
-#define write_gc0_config4(val)		__write_32bit_gc0_register($16, 4, val)
-#define write_gc0_config5(val)		__write_32bit_gc0_register($16, 5, val)
-#define write_gc0_config6(val)		__write_32bit_gc0_register($16, 6, val)
-#define write_gc0_config7(val)		__write_32bit_gc0_register($16, 7, val)
-
-#define read_gc0_watchlo0()		__read_ulong_gc0_register($18, 0)
-#define read_gc0_watchlo1()		__read_ulong_gc0_register($18, 1)
-#define read_gc0_watchlo2()		__read_ulong_gc0_register($18, 2)
-#define read_gc0_watchlo3()		__read_ulong_gc0_register($18, 3)
-#define read_gc0_watchlo4()		__read_ulong_gc0_register($18, 4)
-#define read_gc0_watchlo5()		__read_ulong_gc0_register($18, 5)
-#define read_gc0_watchlo6()		__read_ulong_gc0_register($18, 6)
-#define read_gc0_watchlo7()		__read_ulong_gc0_register($18, 7)
-#define write_gc0_watchlo0(val)		__write_ulong_gc0_register($18, 0, val)
-#define write_gc0_watchlo1(val)		__write_ulong_gc0_register($18, 1, val)
-#define write_gc0_watchlo2(val)		__write_ulong_gc0_register($18, 2, val)
-#define write_gc0_watchlo3(val)		__write_ulong_gc0_register($18, 3, val)
-#define write_gc0_watchlo4(val)		__write_ulong_gc0_register($18, 4, val)
-#define write_gc0_watchlo5(val)		__write_ulong_gc0_register($18, 5, val)
-#define write_gc0_watchlo6(val)		__write_ulong_gc0_register($18, 6, val)
-#define write_gc0_watchlo7(val)		__write_ulong_gc0_register($18, 7, val)
-
-#define read_gc0_watchhi0()		__read_32bit_gc0_register($19, 0)
-#define read_gc0_watchhi1()		__read_32bit_gc0_register($19, 1)
-#define read_gc0_watchhi2()		__read_32bit_gc0_register($19, 2)
-#define read_gc0_watchhi3()		__read_32bit_gc0_register($19, 3)
-#define read_gc0_watchhi4()		__read_32bit_gc0_register($19, 4)
-#define read_gc0_watchhi5()		__read_32bit_gc0_register($19, 5)
-#define read_gc0_watchhi6()		__read_32bit_gc0_register($19, 6)
-#define read_gc0_watchhi7()		__read_32bit_gc0_register($19, 7)
-#define write_gc0_watchhi0(val)		__write_32bit_gc0_register($19, 0, val)
-#define write_gc0_watchhi1(val)		__write_32bit_gc0_register($19, 1, val)
-#define write_gc0_watchhi2(val)		__write_32bit_gc0_register($19, 2, val)
-#define write_gc0_watchhi3(val)		__write_32bit_gc0_register($19, 3, val)
-#define write_gc0_watchhi4(val)		__write_32bit_gc0_register($19, 4, val)
-#define write_gc0_watchhi5(val)		__write_32bit_gc0_register($19, 5, val)
-#define write_gc0_watchhi6(val)		__write_32bit_gc0_register($19, 6, val)
-#define write_gc0_watchhi7(val)		__write_32bit_gc0_register($19, 7, val)
-
-#define read_gc0_xcontext()		__read_ulong_gc0_register($20, 0)
-#define write_gc0_xcontext(val)		__write_ulong_gc0_register($20, 0, val)
-
-#define read_gc0_perfctrl0()		__read_32bit_gc0_register($25, 0)
-#define write_gc0_perfctrl0(val)	__write_32bit_gc0_register($25, 0, val)
-#define read_gc0_perfcntr0()		__read_32bit_gc0_register($25, 1)
-#define write_gc0_perfcntr0(val)	__write_32bit_gc0_register($25, 1, val)
-#define read_gc0_perfcntr0_64()		__read_64bit_gc0_register($25, 1)
-#define write_gc0_perfcntr0_64(val)	__write_64bit_gc0_register($25, 1, val)
-#define read_gc0_perfctrl1()		__read_32bit_gc0_register($25, 2)
-#define write_gc0_perfctrl1(val)	__write_32bit_gc0_register($25, 2, val)
-#define read_gc0_perfcntr1()		__read_32bit_gc0_register($25, 3)
-#define write_gc0_perfcntr1(val)	__write_32bit_gc0_register($25, 3, val)
-#define read_gc0_perfcntr1_64()		__read_64bit_gc0_register($25, 3)
-#define write_gc0_perfcntr1_64(val)	__write_64bit_gc0_register($25, 3, val)
-#define read_gc0_perfctrl2()		__read_32bit_gc0_register($25, 4)
-#define write_gc0_perfctrl2(val)	__write_32bit_gc0_register($25, 4, val)
-#define read_gc0_perfcntr2()		__read_32bit_gc0_register($25, 5)
-#define write_gc0_perfcntr2(val)	__write_32bit_gc0_register($25, 5, val)
-#define read_gc0_perfcntr2_64()		__read_64bit_gc0_register($25, 5)
-#define write_gc0_perfcntr2_64(val)	__write_64bit_gc0_register($25, 5, val)
-#define read_gc0_perfctrl3()		__read_32bit_gc0_register($25, 6)
-#define write_gc0_perfctrl3(val)	__write_32bit_gc0_register($25, 6, val)
-#define read_gc0_perfcntr3()		__read_32bit_gc0_register($25, 7)
-#define write_gc0_perfcntr3(val)	__write_32bit_gc0_register($25, 7, val)
-#define read_gc0_perfcntr3_64()		__read_64bit_gc0_register($25, 7)
-#define write_gc0_perfcntr3_64(val)	__write_64bit_gc0_register($25, 7, val)
-
-#define read_gc0_errorepc()		__read_ulong_gc0_register($30, 0)
-#define write_gc0_errorepc(val)		__write_ulong_gc0_register($30, 0, val)
-
-#define read_gc0_kscratch1()		__read_ulong_gc0_register($31, 2)
-#define read_gc0_kscratch2()		__read_ulong_gc0_register($31, 3)
-#define read_gc0_kscratch3()		__read_ulong_gc0_register($31, 4)
-#define read_gc0_kscratch4()		__read_ulong_gc0_register($31, 5)
-#define read_gc0_kscratch5()		__read_ulong_gc0_register($31, 6)
-#define read_gc0_kscratch6()		__read_ulong_gc0_register($31, 7)
-#define write_gc0_kscratch1(val)	__write_ulong_gc0_register($31, 2, val)
-#define write_gc0_kscratch2(val)	__write_ulong_gc0_register($31, 3, val)
-#define write_gc0_kscratch3(val)	__write_ulong_gc0_register($31, 4, val)
-#define write_gc0_kscratch4(val)	__write_ulong_gc0_register($31, 5, val)
-#define write_gc0_kscratch5(val)	__write_ulong_gc0_register($31, 6, val)
-#define write_gc0_kscratch6(val)	__write_ulong_gc0_register($31, 7, val)
+#define read_gc0_segctl1()		__read_ulong_gc0_register(5, 3)
+#define write_gc0_segctl1(val)		__write_ulong_gc0_register(5, 3, val)
+
+#define read_gc0_segctl2()		__read_ulong_gc0_register(5, 4)
+#define write_gc0_segctl2(val)		__write_ulong_gc0_register(5, 4, val)
+
+#define read_gc0_pwbase()		__read_ulong_gc0_register(5, 5)
+#define write_gc0_pwbase(val)		__write_ulong_gc0_register(5, 5, val)
+
+#define read_gc0_pwfield()		__read_ulong_gc0_register(5, 6)
+#define write_gc0_pwfield(val)		__write_ulong_gc0_register(5, 6, val)
+
+#define read_gc0_pwsize()		__read_ulong_gc0_register(5, 7)
+#define write_gc0_pwsize(val)		__write_ulong_gc0_register(5, 7, val)
+
+#define read_gc0_wired()		__read_32bit_gc0_register(6, 0)
+#define write_gc0_wired(val)		__write_32bit_gc0_register(6, 0, val)
+
+#define read_gc0_pwctl()		__read_32bit_gc0_register(6, 6)
+#define write_gc0_pwctl(val)		__write_32bit_gc0_register(6, 6, val)
+
+#define read_gc0_hwrena()		__read_32bit_gc0_register(7, 0)
+#define write_gc0_hwrena(val)		__write_32bit_gc0_register(7, 0, val)
+
+#define read_gc0_badvaddr()		__read_ulong_gc0_register(8, 0)
+#define write_gc0_badvaddr(val)		__write_ulong_gc0_register(8, 0, val)
+
+#define read_gc0_badinstr()		__read_32bit_gc0_register(8, 1)
+#define write_gc0_badinstr(val)		__write_32bit_gc0_register(8, 1, val)
+
+#define read_gc0_badinstrp()		__read_32bit_gc0_register(8, 2)
+#define write_gc0_badinstrp(val)	__write_32bit_gc0_register(8, 2, val)
+
+#define read_gc0_count()		__read_32bit_gc0_register(9, 0)
+
+#define read_gc0_entryhi()		__read_ulong_gc0_register(10, 0)
+#define write_gc0_entryhi(val)		__write_ulong_gc0_register(10, 0, val)
+
+#define read_gc0_compare()		__read_32bit_gc0_register(11, 0)
+#define write_gc0_compare(val)		__write_32bit_gc0_register(11, 0, val)
+
+#define read_gc0_status()		__read_32bit_gc0_register(12, 0)
+#define write_gc0_status(val)		__write_32bit_gc0_register(12, 0, val)
+
+#define read_gc0_intctl()		__read_32bit_gc0_register(12, 1)
+#define write_gc0_intctl(val)		__write_32bit_gc0_register(12, 1, val)
+
+#define read_gc0_cause()		__read_32bit_gc0_register(13, 0)
+#define write_gc0_cause(val)		__write_32bit_gc0_register(13, 0, val)
+
+#define read_gc0_epc()			__read_ulong_gc0_register(14, 0)
+#define write_gc0_epc(val)		__write_ulong_gc0_register(14, 0, val)
+
+#define read_gc0_ebase()		__read_32bit_gc0_register(15, 1)
+#define write_gc0_ebase(val)		__write_32bit_gc0_register(15, 1, val)
+
+#define read_gc0_ebase_64()		__read_64bit_gc0_register(15, 1)
+#define write_gc0_ebase_64(val)		__write_64bit_gc0_register(15, 1, val)
+
+#define read_gc0_config()		__read_32bit_gc0_register(16, 0)
+#define read_gc0_config1()		__read_32bit_gc0_register(16, 1)
+#define read_gc0_config2()		__read_32bit_gc0_register(16, 2)
+#define read_gc0_config3()		__read_32bit_gc0_register(16, 3)
+#define read_gc0_config4()		__read_32bit_gc0_register(16, 4)
+#define read_gc0_config5()		__read_32bit_gc0_register(16, 5)
+#define read_gc0_config6()		__read_32bit_gc0_register(16, 6)
+#define read_gc0_config7()		__read_32bit_gc0_register(16, 7)
+#define write_gc0_config(val)		__write_32bit_gc0_register(16, 0, val)
+#define write_gc0_config1(val)		__write_32bit_gc0_register(16, 1, val)
+#define write_gc0_config2(val)		__write_32bit_gc0_register(16, 2, val)
+#define write_gc0_config3(val)		__write_32bit_gc0_register(16, 3, val)
+#define write_gc0_config4(val)		__write_32bit_gc0_register(16, 4, val)
+#define write_gc0_config5(val)		__write_32bit_gc0_register(16, 5, val)
+#define write_gc0_config6(val)		__write_32bit_gc0_register(16, 6, val)
+#define write_gc0_config7(val)		__write_32bit_gc0_register(16, 7, val)
+
+#define read_gc0_watchlo0()		__read_ulong_gc0_register(18, 0)
+#define read_gc0_watchlo1()		__read_ulong_gc0_register(18, 1)
+#define read_gc0_watchlo2()		__read_ulong_gc0_register(18, 2)
+#define read_gc0_watchlo3()		__read_ulong_gc0_register(18, 3)
+#define read_gc0_watchlo4()		__read_ulong_gc0_register(18, 4)
+#define read_gc0_watchlo5()		__read_ulong_gc0_register(18, 5)
+#define read_gc0_watchlo6()		__read_ulong_gc0_register(18, 6)
+#define read_gc0_watchlo7()		__read_ulong_gc0_register(18, 7)
+#define write_gc0_watchlo0(val)		__write_ulong_gc0_register(18, 0, val)
+#define write_gc0_watchlo1(val)		__write_ulong_gc0_register(18, 1, val)
+#define write_gc0_watchlo2(val)		__write_ulong_gc0_register(18, 2, val)
+#define write_gc0_watchlo3(val)		__write_ulong_gc0_register(18, 3, val)
+#define write_gc0_watchlo4(val)		__write_ulong_gc0_register(18, 4, val)
+#define write_gc0_watchlo5(val)		__write_ulong_gc0_register(18, 5, val)
+#define write_gc0_watchlo6(val)		__write_ulong_gc0_register(18, 6, val)
+#define write_gc0_watchlo7(val)		__write_ulong_gc0_register(18, 7, val)
+
+#define read_gc0_watchhi0()		__read_32bit_gc0_register(19, 0)
+#define read_gc0_watchhi1()		__read_32bit_gc0_register(19, 1)
+#define read_gc0_watchhi2()		__read_32bit_gc0_register(19, 2)
+#define read_gc0_watchhi3()		__read_32bit_gc0_register(19, 3)
+#define read_gc0_watchhi4()		__read_32bit_gc0_register(19, 4)
+#define read_gc0_watchhi5()		__read_32bit_gc0_register(19, 5)
+#define read_gc0_watchhi6()		__read_32bit_gc0_register(19, 6)
+#define read_gc0_watchhi7()		__read_32bit_gc0_register(19, 7)
+#define write_gc0_watchhi0(val)		__write_32bit_gc0_register(19, 0, val)
+#define write_gc0_watchhi1(val)		__write_32bit_gc0_register(19, 1, val)
+#define write_gc0_watchhi2(val)		__write_32bit_gc0_register(19, 2, val)
+#define write_gc0_watchhi3(val)		__write_32bit_gc0_register(19, 3, val)
+#define write_gc0_watchhi4(val)		__write_32bit_gc0_register(19, 4, val)
+#define write_gc0_watchhi5(val)		__write_32bit_gc0_register(19, 5, val)
+#define write_gc0_watchhi6(val)		__write_32bit_gc0_register(19, 6, val)
+#define write_gc0_watchhi7(val)		__write_32bit_gc0_register(19, 7, val)
+
+#define read_gc0_xcontext()		__read_ulong_gc0_register(20, 0)
+#define write_gc0_xcontext(val)		__write_ulong_gc0_register(20, 0, val)
+
+#define read_gc0_perfctrl0()		__read_32bit_gc0_register(25, 0)
+#define write_gc0_perfctrl0(val)	__write_32bit_gc0_register(25, 0, val)
+#define read_gc0_perfcntr0()		__read_32bit_gc0_register(25, 1)
+#define write_gc0_perfcntr0(val)	__write_32bit_gc0_register(25, 1, val)
+#define read_gc0_perfcntr0_64()		__read_64bit_gc0_register(25, 1)
+#define write_gc0_perfcntr0_64(val)	__write_64bit_gc0_register(25, 1, val)
+#define read_gc0_perfctrl1()		__read_32bit_gc0_register(25, 2)
+#define write_gc0_perfctrl1(val)	__write_32bit_gc0_register(25, 2, val)
+#define read_gc0_perfcntr1()		__read_32bit_gc0_register(25, 3)
+#define write_gc0_perfcntr1(val)	__write_32bit_gc0_register(25, 3, val)
+#define read_gc0_perfcntr1_64()		__read_64bit_gc0_register(25, 3)
+#define write_gc0_perfcntr1_64(val)	__write_64bit_gc0_register(25, 3, val)
+#define read_gc0_perfctrl2()		__read_32bit_gc0_register(25, 4)
+#define write_gc0_perfctrl2(val)	__write_32bit_gc0_register(25, 4, val)
+#define read_gc0_perfcntr2()		__read_32bit_gc0_register(25, 5)
+#define write_gc0_perfcntr2(val)	__write_32bit_gc0_register(25, 5, val)
+#define read_gc0_perfcntr2_64()		__read_64bit_gc0_register(25, 5)
+#define write_gc0_perfcntr2_64(val)	__write_64bit_gc0_register(25, 5, val)
+#define read_gc0_perfctrl3()		__read_32bit_gc0_register(25, 6)
+#define write_gc0_perfctrl3(val)	__write_32bit_gc0_register(25, 6, val)
+#define read_gc0_perfcntr3()		__read_32bit_gc0_register(25, 7)
+#define write_gc0_perfcntr3(val)	__write_32bit_gc0_register(25, 7, val)
+#define read_gc0_perfcntr3_64()		__read_64bit_gc0_register(25, 7)
+#define write_gc0_perfcntr3_64(val)	__write_64bit_gc0_register(25, 7, val)
+
+#define read_gc0_errorepc()		__read_ulong_gc0_register(30, 0)
+#define write_gc0_errorepc(val)		__write_ulong_gc0_register(30, 0, val)
+
+#define read_gc0_kscratch1()		__read_ulong_gc0_register(31, 2)
+#define read_gc0_kscratch2()		__read_ulong_gc0_register(31, 3)
+#define read_gc0_kscratch3()		__read_ulong_gc0_register(31, 4)
+#define read_gc0_kscratch4()		__read_ulong_gc0_register(31, 5)
+#define read_gc0_kscratch5()		__read_ulong_gc0_register(31, 6)
+#define read_gc0_kscratch6()		__read_ulong_gc0_register(31, 7)
+#define write_gc0_kscratch1(val)	__write_ulong_gc0_register(31, 2, val)
+#define write_gc0_kscratch2(val)	__write_ulong_gc0_register(31, 3, val)
+#define write_gc0_kscratch3(val)	__write_ulong_gc0_register(31, 4, val)
+#define write_gc0_kscratch4(val)	__write_ulong_gc0_register(31, 5, val)
+#define write_gc0_kscratch5(val)	__write_ulong_gc0_register(31, 6, val)
+#define write_gc0_kscratch6(val)	__write_ulong_gc0_register(31, 7, val)
 
 /*
  * Macros to access the floating point coprocessor control registers
@@ -2421,6 +2485,8 @@ static inline void tlb_write_random(void)
 		".set reorder");
 }
 
+#ifdef TOOLCHAIN_SUPPORTS_VIRT
+
 /*
  * Guest TLB operations.
  *
@@ -2479,6 +2545,53 @@ static inline void guest_tlbinvf(void)
 		".set pop");
 }
 
+#else	/* TOOLCHAIN_SUPPORTS_VIRT */
+
+/*
+ * Guest TLB operations.
+ *
+ * It is responsibility of the caller to take care of any TLB hazards.
+ */
+static inline void guest_tlb_probe(void)
+{
+	__asm__ __volatile__(
+		"# tlbgp\n\t"
+		".word 0x42000010");
+}
+
+static inline void guest_tlb_read(void)
+{
+	__asm__ __volatile__(
+		"# tlbgr\n\t"
+		".word 0x42000009");
+}
+
+static inline void guest_tlb_write_indexed(void)
+{
+	__asm__ __volatile__(
+		"# tlbgwi\n\t"
+		".word 0x4200000a");
+}
+
+static inline void guest_tlb_write_random(void)
+{
+	__asm__ __volatile__(
+		"# tlbgwr\n\t"
+		".word 0x4200000e");
+}
+
+/*
+ * Guest TLB Invalidate Flush
+ */
+static inline void guest_tlbinvf(void)
+{
+	__asm__ __volatile__(
+		"# tlbginvf\n\t"
+		".word 0x4200000c");
+}
+
+#endif	/* !TOOLCHAIN_SUPPORTS_VIRT */
+
 /*
  * Manipulate bits in a register.
  */
-- 
2.4.10

^ permalink raw reply related

* Re: linux-next: build failure after merge of the spi tree
From: Mark Brown @ 2016-05-16 10:23 UTC (permalink / raw)
  To: Stephen Rothwell; +Cc: linux-next, linux-kernel, Stefan Roese, Arnd Bergmann
In-Reply-To: <20160516120831.375203a1@canb.auug.org.au>

[-- Attachment #1: Type: text/plain, Size: 212 bytes --]

On Mon, May 16, 2016 at 12:08:31PM +1000, Stephen Rothwell wrote:
> Hi Mark,
> 
> After merging the spi tree, today's linux-next build (x86_64 allmodconfig)
> failed like this:

Sorry, dropped this patch.

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 473 bytes --]

^ permalink raw reply


This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox