]> git.karo-electronics.de Git - karo-tx-linux.git/log
karo-tx-linux.git
12 years agoMerge remote-tracking branch 'iommu/next'
Stephen Rothwell [Fri, 21 Sep 2012 03:27:24 +0000 (13:27 +1000)]
Merge remote-tracking branch 'iommu/next'

12 years agoMerge remote-tracking branch 'watchdog/master'
Stephen Rothwell [Fri, 21 Sep 2012 03:25:47 +0000 (13:25 +1000)]
Merge remote-tracking branch 'watchdog/master'

12 years agoMerge remote-tracking branch 'selinux/master'
Stephen Rothwell [Fri, 21 Sep 2012 03:25:42 +0000 (13:25 +1000)]
Merge remote-tracking branch 'selinux/master'

12 years agoMerge remote-tracking branch 'security/next'
Stephen Rothwell [Fri, 21 Sep 2012 03:21:17 +0000 (13:21 +1000)]
Merge remote-tracking branch 'security/next'

12 years agoMerge remote-tracking branch 'regulator/for-next'
Stephen Rothwell [Fri, 21 Sep 2012 03:19:39 +0000 (13:19 +1000)]
Merge remote-tracking branch 'regulator/for-next'

Conflicts:
Documentation/devicetree/bindings/regulator/tps6586x.txt

12 years agoMerge remote-tracking branch 'omap_dss2/for-next'
Stephen Rothwell [Fri, 21 Sep 2012 03:17:59 +0000 (13:17 +1000)]
Merge remote-tracking branch 'omap_dss2/for-next'

12 years agoMerge remote-tracking branch 'fbdev/fbdev-next'
Stephen Rothwell [Fri, 21 Sep 2012 03:16:19 +0000 (13:16 +1000)]
Merge remote-tracking branch 'fbdev/fbdev-next'

12 years agoMerge remote-tracking branch 'battery/master'
Stephen Rothwell [Fri, 21 Sep 2012 03:14:46 +0000 (13:14 +1000)]
Merge remote-tracking branch 'battery/master'

Conflicts:
include/linux/mfd/88pm860x.h

12 years agoMerge remote-tracking branch 'mfd/for-next'
Stephen Rothwell [Fri, 21 Sep 2012 02:49:47 +0000 (12:49 +1000)]
Merge remote-tracking branch 'mfd/for-next'

Conflicts:
Documentation/devicetree/bindings/regulator/tps6586x.txt
drivers/mfd/88pm860x-core.c
drivers/mfd/max8925-core.c
drivers/mfd/tc3589x.c
drivers/regulator/anatop-regulator.c

12 years agoMerge remote-tracking branch 'md/for-next'
Stephen Rothwell [Fri, 21 Sep 2012 02:48:12 +0000 (12:48 +1000)]
Merge remote-tracking branch 'md/for-next'

Conflicts:
drivers/md/raid0.c
fs/bio.c

12 years agoMerge remote-tracking branch 'slab/for-next'
Stephen Rothwell [Fri, 21 Sep 2012 02:16:41 +0000 (12:16 +1000)]
Merge remote-tracking branch 'slab/for-next'

12 years agoMerge remote-tracking branch 'kgdb/kgdb-next'
Stephen Rothwell [Fri, 21 Sep 2012 02:15:03 +0000 (12:15 +1000)]
Merge remote-tracking branch 'kgdb/kgdb-next'

12 years agoMerge remote-tracking branch 'mmc/mmc-next'
Stephen Rothwell [Fri, 21 Sep 2012 02:13:27 +0000 (12:13 +1000)]
Merge remote-tracking branch 'mmc/mmc-next'

12 years agoMerge branch 'quilt/device-mapper'
Stephen Rothwell [Fri, 21 Sep 2012 02:11:43 +0000 (12:11 +1000)]
Merge branch 'quilt/device-mapper'

12 years agoMerge remote-tracking branch 'block/for-next'
Stephen Rothwell [Fri, 21 Sep 2012 02:05:14 +0000 (12:05 +1000)]
Merge remote-tracking branch 'block/for-next'

12 years agoMerge remote-tracking branch 'cgroup/for-next'
Stephen Rothwell [Fri, 21 Sep 2012 02:00:57 +0000 (12:00 +1000)]
Merge remote-tracking branch 'cgroup/for-next'

12 years agoMerge remote-tracking branch 'input/next'
Stephen Rothwell [Fri, 21 Sep 2012 01:59:18 +0000 (11:59 +1000)]
Merge remote-tracking branch 'input/next'

12 years agoMerge branch 'quilt/rr'
Stephen Rothwell [Fri, 21 Sep 2012 01:53:22 +0000 (11:53 +1000)]
Merge branch 'quilt/rr'

12 years agoMerge remote-tracking branch 'sound-asoc/for-next'
Stephen Rothwell [Fri, 21 Sep 2012 01:51:44 +0000 (11:51 +1000)]
Merge remote-tracking branch 'sound-asoc/for-next'

Conflicts:
arch/arm/mach-imx/mach-imx27_visstrim_m10.c

12 years agoMerge remote-tracking branch 'sound/for-next'
Stephen Rothwell [Fri, 21 Sep 2012 01:49:52 +0000 (11:49 +1000)]
Merge remote-tracking branch 'sound/for-next'

12 years agoMerge remote-tracking branch 'drm/drm-next'
Stephen Rothwell [Fri, 21 Sep 2012 01:48:10 +0000 (11:48 +1000)]
Merge remote-tracking branch 'drm/drm-next'

Conflicts:
drivers/gpu/drm/i915/i915_dma.c
drivers/gpu/drm/i915/intel_sdvo.c

12 years agoMerge remote-tracking branch 'crypto/master'
Stephen Rothwell [Fri, 21 Sep 2012 01:46:25 +0000 (11:46 +1000)]
Merge remote-tracking branch 'crypto/master'

Conflicts:
crypto/Kconfig

12 years agoMerge remote-tracking branch 'l2-mtd/master'
Stephen Rothwell [Fri, 21 Sep 2012 01:44:39 +0000 (11:44 +1000)]
Merge remote-tracking branch 'l2-mtd/master'

12 years agoMerge remote-tracking branch 'mtd/master'
Stephen Rothwell [Fri, 21 Sep 2012 01:43:04 +0000 (11:43 +1000)]
Merge remote-tracking branch 'mtd/master'

12 years agoMerge remote-tracking branch 'bluetooth/master'
Stephen Rothwell [Fri, 21 Sep 2012 01:41:24 +0000 (11:41 +1000)]
Merge remote-tracking branch 'bluetooth/master'

12 years agoMerge remote-tracking branch 'net-next/master'
Stephen Rothwell [Fri, 21 Sep 2012 01:30:06 +0000 (11:30 +1000)]
Merge remote-tracking branch 'net-next/master'

Conflicts:
drivers/net/usb/qmi_wwan.c
net/ipv4/fib_frontend.c
net/ipv4/route.c
net/socket.c

12 years agoMerge remote-tracking branch 'slave-dma/next'
Stephen Rothwell [Fri, 21 Sep 2012 01:18:05 +0000 (11:18 +1000)]
Merge remote-tracking branch 'slave-dma/next'

12 years agoMerge remote-tracking branch 'target-updates/for-next'
Stephen Rothwell [Fri, 21 Sep 2012 01:16:19 +0000 (11:16 +1000)]
Merge remote-tracking branch 'target-updates/for-next'

12 years agoMerge remote-tracking branch 'scsi/for-next'
Stephen Rothwell [Fri, 21 Sep 2012 01:14:19 +0000 (11:14 +1000)]
Merge remote-tracking branch 'scsi/for-next'

Conflicts:
drivers/scsi/ipr.c
drivers/scsi/qla2xxx/qla_nx.c

12 years agoMerge remote-tracking branch 'dlm/next'
Stephen Rothwell [Fri, 21 Sep 2012 01:12:43 +0000 (11:12 +1000)]
Merge remote-tracking branch 'dlm/next'

12 years agoMerge remote-tracking branch 'ubi/linux-next'
Stephen Rothwell [Fri, 21 Sep 2012 01:11:07 +0000 (11:11 +1000)]
Merge remote-tracking branch 'ubi/linux-next'

12 years agoMerge remote-tracking branch 'thermal/next'
Stephen Rothwell [Fri, 21 Sep 2012 01:09:32 +0000 (11:09 +1000)]
Merge remote-tracking branch 'thermal/next'

12 years agoMerge remote-tracking branch 'cpuidle/cpuidle-next'
Stephen Rothwell [Fri, 21 Sep 2012 01:09:25 +0000 (11:09 +1000)]
Merge remote-tracking branch 'cpuidle/cpuidle-next'

Conflicts:
drivers/cpuidle/coupled.c
include/linux/cpuidle.h

12 years agoMerge remote-tracking branch 'pstore/master'
Stephen Rothwell [Fri, 21 Sep 2012 01:07:44 +0000 (11:07 +1000)]
Merge remote-tracking branch 'pstore/master'

12 years agoMerge remote-tracking branch 'infiniband/for-next'
Stephen Rothwell [Fri, 21 Sep 2012 01:05:58 +0000 (11:05 +1000)]
Merge remote-tracking branch 'infiniband/for-next'

12 years agoMerge remote-tracking branch 'libata/NEXT'
Stephen Rothwell [Fri, 21 Sep 2012 01:04:18 +0000 (11:04 +1000)]
Merge remote-tracking branch 'libata/NEXT'

12 years agoMerge remote-tracking branch 'kconfig/for-next'
Stephen Rothwell [Fri, 21 Sep 2012 01:02:45 +0000 (11:02 +1000)]
Merge remote-tracking branch 'kconfig/for-next'

12 years agoMerge remote-tracking branch 'kbuild/for-next'
Stephen Rothwell [Fri, 21 Sep 2012 01:01:03 +0000 (11:01 +1000)]
Merge remote-tracking branch 'kbuild/for-next'

12 years agoMerge remote-tracking branch 'v4l-dvb/master'
Stephen Rothwell [Fri, 21 Sep 2012 00:59:01 +0000 (10:59 +1000)]
Merge remote-tracking branch 'v4l-dvb/master'

Conflicts:
arch/arm/mach-imx/mach-imx27_visstrim_m10.c

12 years agoMerge remote-tracking branch 'hwmon-staging/hwmon-next'
Stephen Rothwell [Fri, 21 Sep 2012 00:51:57 +0000 (10:51 +1000)]
Merge remote-tracking branch 'hwmon-staging/hwmon-next'

12 years agoMerge branch 'quilt/jdelvare-hwmon'
Stephen Rothwell [Fri, 21 Sep 2012 00:50:33 +0000 (10:50 +1000)]
Merge branch 'quilt/jdelvare-hwmon'

12 years agoMerge remote-tracking branch 'i2c-embedded/i2c-embedded/for-next'
Stephen Rothwell [Fri, 21 Sep 2012 00:49:08 +0000 (10:49 +1000)]
Merge remote-tracking branch 'i2c-embedded/i2c-embedded/for-next'

12 years agoMerge branch 'quilt/i2c'
Stephen Rothwell [Fri, 21 Sep 2012 00:47:43 +0000 (10:47 +1000)]
Merge branch 'quilt/i2c'

12 years agoMerge remote-tracking branch 'hid/for-next'
Stephen Rothwell [Fri, 21 Sep 2012 00:45:57 +0000 (10:45 +1000)]
Merge remote-tracking branch 'hid/for-next'

12 years agoMerge remote-tracking branch 'galak/next'
Stephen Rothwell [Fri, 21 Sep 2012 00:44:31 +0000 (10:44 +1000)]
Merge remote-tracking branch 'galak/next'

12 years agoMerge remote-tracking branch 'mpc5xxx/next'
Stephen Rothwell [Fri, 21 Sep 2012 00:43:07 +0000 (10:43 +1000)]
Merge remote-tracking branch 'mpc5xxx/next'

12 years agoMerge remote-tracking branch 'powerpc/next'
Stephen Rothwell [Fri, 21 Sep 2012 00:40:37 +0000 (10:40 +1000)]
Merge remote-tracking branch 'powerpc/next'

12 years agoMerge remote-tracking branch 'pci/next'
Stephen Rothwell [Fri, 21 Sep 2012 00:37:19 +0000 (10:37 +1000)]
Merge remote-tracking branch 'pci/next'

12 years agoMerge remote-tracking branch 'vfs/for-next'
Stephen Rothwell [Fri, 21 Sep 2012 00:33:07 +0000 (10:33 +1000)]
Merge remote-tracking branch 'vfs/for-next'

12 years agoMerge remote-tracking branch 'xfs/for-next'
Stephen Rothwell [Fri, 21 Sep 2012 00:31:34 +0000 (10:31 +1000)]
Merge remote-tracking branch 'xfs/for-next'

12 years agoMerge remote-tracking branch 'ubifs/linux-next'
Stephen Rothwell [Fri, 21 Sep 2012 00:30:08 +0000 (10:30 +1000)]
Merge remote-tracking branch 'ubifs/linux-next'

12 years agoMerge remote-tracking branch 'v9fs/for-next'
Stephen Rothwell [Fri, 21 Sep 2012 00:28:42 +0000 (10:28 +1000)]
Merge remote-tracking branch 'v9fs/for-next'

12 years agoMerge remote-tracking branch 'ocfs2/linux-next'
Stephen Rothwell [Fri, 21 Sep 2012 00:27:09 +0000 (10:27 +1000)]
Merge remote-tracking branch 'ocfs2/linux-next'

12 years agoMerge remote-tracking branch 'nfsd/nfsd-next'
Stephen Rothwell [Fri, 21 Sep 2012 00:25:41 +0000 (10:25 +1000)]
Merge remote-tracking branch 'nfsd/nfsd-next'

12 years agoMerge remote-tracking branch 'nfs/linux-next'
Stephen Rothwell [Fri, 21 Sep 2012 00:24:15 +0000 (10:24 +1000)]
Merge remote-tracking branch 'nfs/linux-next'

12 years agoMerge remote-tracking branch 'logfs/master'
Stephen Rothwell [Fri, 21 Sep 2012 00:22:51 +0000 (10:22 +1000)]
Merge remote-tracking branch 'logfs/master'

12 years agoMerge remote-tracking branch 'jfs/jfs-next'
Stephen Rothwell [Fri, 21 Sep 2012 00:21:22 +0000 (10:21 +1000)]
Merge remote-tracking branch 'jfs/jfs-next'

12 years agoMerge remote-tracking branch 'gfs2/master'
Stephen Rothwell [Fri, 21 Sep 2012 00:19:57 +0000 (10:19 +1000)]
Merge remote-tracking branch 'gfs2/master'

Conflicts:
fs/gfs2/rgrp.c

12 years agoMerge remote-tracking branch 'fuse/for-next'
Stephen Rothwell [Fri, 21 Sep 2012 00:18:26 +0000 (10:18 +1000)]
Merge remote-tracking branch 'fuse/for-next'

12 years agoMerge remote-tracking branch 'ext4/dev'
Stephen Rothwell [Fri, 21 Sep 2012 00:16:54 +0000 (10:16 +1000)]
Merge remote-tracking branch 'ext4/dev'

12 years agoMerge remote-tracking branch 'ext3/for_next'
Stephen Rothwell [Fri, 21 Sep 2012 00:15:25 +0000 (10:15 +1000)]
Merge remote-tracking branch 'ext3/for_next'

12 years agoMerge remote-tracking branch 'cifs/for-next'
Stephen Rothwell [Fri, 21 Sep 2012 00:13:53 +0000 (10:13 +1000)]
Merge remote-tracking branch 'cifs/for-next'

12 years agoMerge remote-tracking branch 'unicore32/unicore32'
Stephen Rothwell [Fri, 21 Sep 2012 00:12:24 +0000 (10:12 +1000)]
Merge remote-tracking branch 'unicore32/unicore32'

12 years agoMerge remote-tracking branch 'sparc-next/master'
Stephen Rothwell [Fri, 21 Sep 2012 00:10:56 +0000 (10:10 +1000)]
Merge remote-tracking branch 'sparc-next/master'

12 years agoMerge remote-tracking branch 's390/features'
Stephen Rothwell [Fri, 21 Sep 2012 00:05:50 +0000 (10:05 +1000)]
Merge remote-tracking branch 's390/features'

12 years agoMerge remote-tracking branch 'openrisc/for-upstream'
Stephen Rothwell [Fri, 21 Sep 2012 00:04:26 +0000 (10:04 +1000)]
Merge remote-tracking branch 'openrisc/for-upstream'

12 years agoMerge remote-tracking branch 'mips/mips-for-linux-next'
Stephen Rothwell [Fri, 21 Sep 2012 00:02:55 +0000 (10:02 +1000)]
Merge remote-tracking branch 'mips/mips-for-linux-next'

12 years agoMerge remote-tracking branch 'm68knommu/for-next'
Stephen Rothwell [Fri, 21 Sep 2012 00:01:30 +0000 (10:01 +1000)]
Merge remote-tracking branch 'm68knommu/for-next'

12 years agoMerge remote-tracking branch 'm68k/for-next'
Stephen Rothwell [Fri, 21 Sep 2012 00:00:07 +0000 (10:00 +1000)]
Merge remote-tracking branch 'm68k/for-next'

12 years agoMerge remote-tracking branch 'ia64/next'
Stephen Rothwell [Thu, 20 Sep 2012 23:58:43 +0000 (09:58 +1000)]
Merge remote-tracking branch 'ia64/next'

12 years agoMerge remote-tracking branch 'cris/for-next'
Stephen Rothwell [Thu, 20 Sep 2012 23:57:19 +0000 (09:57 +1000)]
Merge remote-tracking branch 'cris/for-next'

12 years agoMerge remote-tracking branch 'arm64/upstream'
Stephen Rothwell [Thu, 20 Sep 2012 23:52:15 +0000 (09:52 +1000)]
Merge remote-tracking branch 'arm64/upstream'

12 years agoMerge remote-tracking branch 'arm-perf/for-next/perf'
Stephen Rothwell [Thu, 20 Sep 2012 23:50:45 +0000 (09:50 +1000)]
Merge remote-tracking branch 'arm-perf/for-next/perf'

Conflicts:
arch/arm/kernel/hw_breakpoint.c

12 years agoMerge remote-tracking branch 'arm/for-next'
Stephen Rothwell [Thu, 20 Sep 2012 23:49:17 +0000 (09:49 +1000)]
Merge remote-tracking branch 'arm/for-next'

12 years agoMerge remote-tracking branch 'spi-current/spi/merge'
Stephen Rothwell [Thu, 20 Sep 2012 23:42:26 +0000 (09:42 +1000)]
Merge remote-tracking branch 'spi-current/spi/merge'

12 years agoMerge remote-tracking branch 'devicetree-current/devicetree/merge'
Stephen Rothwell [Thu, 20 Sep 2012 23:42:24 +0000 (09:42 +1000)]
Merge remote-tracking branch 'devicetree-current/devicetree/merge'

12 years agoMerge remote-tracking branch 'input-current/for-linus'
Stephen Rothwell [Thu, 20 Sep 2012 23:42:14 +0000 (09:42 +1000)]
Merge remote-tracking branch 'input-current/for-linus'

12 years agoMerge remote-tracking branch 'wireless/master'
Stephen Rothwell [Thu, 20 Sep 2012 23:42:13 +0000 (09:42 +1000)]
Merge remote-tracking branch 'wireless/master'

12 years agoMerge remote-tracking branch 'net/master'
Stephen Rothwell [Thu, 20 Sep 2012 23:42:11 +0000 (09:42 +1000)]
Merge remote-tracking branch 'net/master'

12 years agoMerge remote-tracking branch 'm68k-current/for-linus'
Stephen Rothwell [Thu, 20 Sep 2012 23:42:09 +0000 (09:42 +1000)]
Merge remote-tracking branch 'm68k-current/for-linus'

12 years agoMerge remote-tracking branch 'arm-current/fixes'
Stephen Rothwell [Thu, 20 Sep 2012 23:42:08 +0000 (09:42 +1000)]
Merge remote-tracking branch 'arm-current/fixes'

12 years agoUse the recently-added bio front_pad field to allocate struct dm_target_io.
Mikulas Patocka [Thu, 20 Sep 2012 23:40:13 +0000 (09:40 +1000)]
Use the recently-added bio front_pad field to allocate struct dm_target_io.

Prior to this patch, dm_target_io was allocated from a mempool. For each
dm_target_io, there is exactly one bio allocated from a bioset.

This patch merges these two allocations into one allocation: we create a
bioset with front_pad equal to the size of dm_target_io so that every
bio allocated from the bioset has sizeof(struct dm_target_io) bytes
before it. We allocate a bio and use the bytes before the bio as
dm_target_io.

This idea was introduced by Kent Overstreet.

Signed-off-by: Mikulas Patocka <mpatocka@redhat.com>
Cc: Kent Overstreet <koverstreet@google.com>
Cc: Jens Axboe <axboe@kernel.dk>
Cc: tj@kernel.org
Cc: Vivek Goyal <vgoyal@redhat.com>
Signed-off-by: Alasdair G Kergon <agk@redhat.com>
12 years agoUse the ACCESS_ONCE macro in dm-bufio and dm-verity where a variable
Mikulas Patocka [Thu, 20 Sep 2012 23:40:13 +0000 (09:40 +1000)]
Use the ACCESS_ONCE macro in dm-bufio and dm-verity where a variable
can be modified asynchronously (through sysfs) and we want to prevent
compiler optimizations that assume that the variable hasn't changed.
(See Documentation/atomic_ops.txt.)

Signed-off-by: Mikulas Patocka <mpatocka@redhat.com>
Signed-off-by: Alasdair G Kergon <agk@redhat.com>
12 years agoUse list_move() instead of list_del() + list_add().
Wei Yongjun [Thu, 20 Sep 2012 23:40:12 +0000 (09:40 +1000)]
Use list_move() instead of list_del() + list_add().

spatch with a semantic match was used to find this.
(http://coccinelle.lip6.fr/)

Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
Signed-off-by: Alasdair G Kergon <agk@redhat.com>
12 years agoThe discard limits that get established for a thin-pool or thin device
Mike Snitzer [Thu, 20 Sep 2012 23:40:12 +0000 (09:40 +1000)]
The discard limits that get established for a thin-pool or thin device
may be incompatible with the pool's data device.  Avoid this by checking
the discard limits of the pool's data device.  If an incompatibility is
found then the pool's 'discard passdown' feature is disabled.

Change thin_io_hints to ensure that a thin device always uses the same
queue limits as its pool device.

Introduce requested_pf to track whether or not the table line originally
contained the no_discard_passdown flag and use this directly for table
output.  We prepare the correct setting for discard_passdown directly in
bind_control_target (called from pool_io_hints) and store it in
adjusted_pf rather than waiting until we have access to pool->pf in
pool_preresume.

Signed-off-by: Mike Snitzer <snitzer@redhat.com>
Signed-off-by: Joe Thornber <ejt@redhat.com>
Signed-off-by: Alasdair G Kergon <agk@redhat.com>
12 years agoA little thin discard code refactoring in preparation for the next
Mike Snitzer [Thu, 20 Sep 2012 23:40:12 +0000 (09:40 +1000)]
A little thin discard code refactoring in preparation for the next
patch. Use bools instead of unsigned for features.

No functional changes.

Signed-off-by: Mike Snitzer <snitzer@redhat.com>
Signed-off-by: Joe Thornber <ejt@redhat.com>
Signed-off-by: Alasdair G Kergon <agk@redhat.com>
12 years agoThe dm thin pool target claims to support the zeroing of discarded
Mike Snitzer [Thu, 20 Sep 2012 23:40:11 +0000 (09:40 +1000)]
The dm thin pool target claims to support the zeroing of discarded
data areas.  This turns out to be incorrect when processing discards
that do not exactly cover a complete number of blocks, so the target
must always set discard_zeroes_data_unsupported.

The thin pool target will zero blocks when they are allocated if the
skip_block_zeroing feature is not specified.  The block layer
may send a discard that only partly covers a block.  If a thin pool
block is partially discarded then there is no guarantee that the
discarded data will get zeroed before it is accessed again.
Due to this, thin devices cannot claim discards will always zero data.

Signed-off-by: Mike Snitzer <snitzer@redhat.com>
Cc: stable@vger.kernel.org # 3.4+
Signed-off-by: Alasdair G Kergon <agk@redhat.com>
12 years agoAlways clear QUEUE_FLAG_ADD_RANDOM if any underlying device does not
Milan Broz [Thu, 20 Sep 2012 23:40:11 +0000 (09:40 +1000)]
Always clear QUEUE_FLAG_ADD_RANDOM if any underlying device does not
have it set.

QUEUE_FLAG_ADD_RANDOM specifies whether or not queue IO timings
contribute to the random pool.

For bio-based targets this flag is always 0 because such devices have no
real queue.

For request-based devices this flag was always set to 1 by default.

Now set it according to the flags on underlying devices. If there is at
least one device which should not contribute, set the flag to zero: If a
device, such as fast SSD storage, is not suitable for supplying entropy,
a request-based queue stacked over it will not be either.

Because the checking logic is exactly same as for the rotational flag,
share the iteration function with device_is_nonrot().

Signed-off-by: Milan Broz <mbroz@redhat.com>
Signed-off-by: Alasdair G Kergon <agk@redhat.com>
12 years agoWhen there are no paths and multipath receives an ioctl, it waits until
Mike Snitzer [Thu, 20 Sep 2012 23:40:11 +0000 (09:40 +1000)]
When there are no paths and multipath receives an ioctl, it waits until
a path becomes available.  This behaviour is incorrect if the
"queue_if_no_path" setting was not specified, as then the ioctl should
be rejected immediately, which this patch now does.

commit 35991652b ("dm mpath: allow ioctls to trigger pg init") should
have checked if queue_if_no_path was configured before queueing IO.

Checking for the queue_if_no_path feature, like is done in map_io(),
allows the following table load to work without blocking in the
multipath_ioctl retry loop:

  echo "0 1024 multipath 0 0 0 0" | dmsetup create mpath_nodevs

Without this fix the multipath_ioctl will block with the following stack
trace:

  blkid           D 0000000000000002     0 23936      1 0x00000000
   ffff8802b89e5cd8 0000000000000082 ffff8802b89e5fd8 0000000000012440
   ffff8802b89e4010 0000000000012440 0000000000012440 0000000000012440
   ffff8802b89e5fd8 0000000000012440 ffff88030c2aab30 ffff880325794040
  Call Trace:
   [<ffffffff814ce099>] schedule+0x29/0x70
   [<ffffffff814cc312>] schedule_timeout+0x182/0x2e0
   [<ffffffff8104dee0>] ? lock_timer_base+0x70/0x70
   [<ffffffff814cc48e>] schedule_timeout_uninterruptible+0x1e/0x20
   [<ffffffff8104f840>] msleep+0x20/0x30
   [<ffffffffa0000839>] multipath_ioctl+0x109/0x170 [dm_multipath]
   [<ffffffffa06bfb9c>] dm_blk_ioctl+0xbc/0xd0 [dm_mod]
   [<ffffffff8122a408>] __blkdev_driver_ioctl+0x28/0x30
   [<ffffffff8122a79e>] blkdev_ioctl+0xce/0x730
   [<ffffffff811970ac>] block_ioctl+0x3c/0x40
   [<ffffffff8117321c>] do_vfs_ioctl+0x8c/0x340
   [<ffffffff81166293>] ? sys_newfstat+0x33/0x40
   [<ffffffff81173571>] sys_ioctl+0xa1/0xb0
   [<ffffffff814d70a9>] system_call_fastpath+0x16/0x1b

Signed-off-by: Mike Snitzer <snitzer@redhat.com>
Acked-by: Mikulas Patocka <mpatocka@redhat.com>
Signed-off-by: Alasdair G Kergon <agk@redhat.com>
12 years agoThe mpio dereference should be moved below the BUG_ON NULL test
Wei Yongjun [Thu, 20 Sep 2012 23:40:10 +0000 (09:40 +1000)]
The mpio dereference should be moved below the BUG_ON NULL test
in multipath_end_io().

spatch with a semantic match is used to found this.
(http://coccinelle.lip6.fr/)

Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
Signed-off-by: Alasdair G Kergon <agk@redhat.com>
12 years agoThis patch fixes sector_t overflow checking in dm-verity.
Mikulas Patocka [Thu, 20 Sep 2012 23:40:10 +0000 (09:40 +1000)]
This patch fixes sector_t overflow checking in dm-verity.

Without this patch, the code checks for overflow only if sector_t is
smaller than long long, not if sector_t and long long have the same size.

Signed-off-by: Mikulas Patocka <mpatocka@redhat.com>
Signed-off-by: Alasdair G Kergon <agk@redhat.com>
12 years agotwl4030_charger: Use IRQF_ONESHOT
Fengguang Wu [Thu, 23 Aug 2012 11:56:43 +0000 (19:56 +0800)]
twl4030_charger: Use IRQF_ONESHOT

Generated by: scripts/coccinelle/misc/irqf_oneshot.cocci

Make sure threaded IRQs without a primary handler are always request with IRQF_ONESHOT

Signed-off-by: Fengguang Wu <fengguang.wu@intel.com>
Acked-by: Felipe Balbi <balbi@ti.com>
Signed-off-by: Anton Vorontsov <anton.vorontsov@linaro.org>
12 years agolp8727_charger: Use IRQF_ONESHOT
Fengguang Wu [Thu, 23 Aug 2012 11:42:29 +0000 (19:42 +0800)]
lp8727_charger: Use IRQF_ONESHOT

Generated by: scripts/coccinelle/misc/irqf_oneshot.cocci

ERROR: Threaded IRQ with no primary handler requested without IRQF_ONESHOT

Make sure threaded IRQs without a primary handler are always request
with IRQF_ONESHOT

Signed-off-by: Fengguang Wu <fengguang.wu@intel.com>
Acked-by: Milo(Woogyom) Kim <milo.kim@ti.com>
Signed-off-by: Anton Vorontsov <anton.vorontsov@linaro.org>
12 years ago88pm860x_battery and charger: Fix a few post-merge issues
Anton Vorontsov [Thu, 23 Aug 2012 03:31:33 +0000 (20:31 -0700)]
88pm860x_battery and charger: Fix a few post-merge issues

Sparse complains:

  CHECK   drivers/power/88pm860x_battery.c
drivers/power/88pm860x_battery.c:128:5: warning: symbol 'array_soc' was not declared. Should it be static?
  CHECK   drivers/power/88pm860x_charger.c
drivers/power/88pm860x_charger.c:640:3: warning: symbol 'pm860x_irq_descs' was not declared. Should it be static?
  CHECK   drivers/mfd/88pm860x-core.c
drivers/mfd/88pm860x-core.c:803:53: warning: incorrect type in assignment (different base types)
drivers/mfd/88pm860x-core.c:803:53:    expected struct charger_regulator *charger_regulators
drivers/mfd/88pm860x-core.c:803:53:    got struct regulator_bulk_data static [toplevel] *

The issues are minor, except for the last one. We seemed to use
'regulator_bulk_data' struct (just as charger manager documentation
wrongly tells us), but in real it should have been
'struct charger_regulator'. The only reason that it worked is
because both 'supply' and 'regulator_name' struct members are the
first in these structs. :-)

Signed-off-by: Anton Vorontsov <anton.vorontsov@linaro.org>
12 years agopower_supply: Enable battery-charger for 88pm860x
Jett.Zhou [Fri, 27 Jul 2012 08:27:16 +0000 (16:27 +0800)]
power_supply: Enable battery-charger for 88pm860x

There are charger and battery measurement feature for 88pm860x PMIC.

For charger, it can support pre-charge with small current when battery is
nearly exausted and then changed into fast-charge with CC&CV mode.

For battery monitor, it can support battery measurement such as
vbat,vsys,vchg and ibat etc,it can aslo accumulating the Coulomb value
charged or discharged from battery based on Conlomb Counter, we use it
to estimate battery capacity.

Signed-off-by: Jett.Zhou <jtzhou@marvell.com>
Signed-off-by: Anton Vorontsov <anton.vorontsov@linaro.org>
12 years agopower_supply: Add new lp8788 charger driver
Kim, Milo [Wed, 5 Sep 2012 10:43:21 +0000 (10:43 +0000)]
power_supply: Add new lp8788 charger driver

TI LP8788 PMU supports regulators, battery charger, RTC, ADC, backlight
driver and current sinks.

This patch supports the charger operations including the charger
interrupt handling.

The LP8788 charger driver provides configurable platform data.  The
charger platform data includes ADC input ID, maximum battery voltage,
charging parameters and etc.

The ADC input is used for getting the battery voltage and temperature.
Charging parameters are used for updating the charger operations such
like setting charging current and setting End-of-charge conditions.

When the charging interrupt occurs, power supply uevents are generated
in order to update the user-space information.  For platform specific
charger action, the charger_event() function can be used in the
platform side.

Signed-off-by: Milo(Woogyom) Kim <milo.kim@ti.com>
Signed-off-by: Anton Vorontsov <anton.vorontsov@linaro.org>
12 years agoxfrm_user: don't copy esn replay window twice for new states
Mathias Krause [Wed, 19 Sep 2012 11:33:43 +0000 (11:33 +0000)]
xfrm_user: don't copy esn replay window twice for new states

The ESN replay window was already fully initialized in
xfrm_alloc_replay_state_esn(). No need to copy it again.

Cc: Steffen Klassert <steffen.klassert@secunet.com>
Signed-off-by: Mathias Krause <minipli@googlemail.com>
Acked-by: Steffen Klassert <steffen.klassert@secunet.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
12 years agoxfrm_user: ensure user supplied esn replay window is valid
Mathias Krause [Thu, 20 Sep 2012 10:01:49 +0000 (10:01 +0000)]
xfrm_user: ensure user supplied esn replay window is valid

The current code fails to ensure that the netlink message actually
contains as many bytes as the header indicates. If a user creates a new
state or updates an existing one but does not supply the bytes for the
whole ESN replay window, the kernel copies random heap bytes into the
replay bitmap, the ones happen to follow the XFRMA_REPLAY_ESN_VAL
netlink attribute. This leads to following issues:

1. The replay window has random bits set confusing the replay handling
   code later on.

2. A malicious user could use this flaw to leak up to ~3.5kB of heap
   memory when she has access to the XFRM netlink interface (requires
   CAP_NET_ADMIN).

Known users of the ESN replay window are strongSwan and Steffen's
iproute2 patch (<http://patchwork.ozlabs.org/patch/85962/>). The latter
uses the interface with a bitmap supplied while the former does not.
strongSwan is therefore prone to run into issue 1.

To fix both issues without breaking existing userland allow using the
XFRMA_REPLAY_ESN_VAL netlink attribute with either an empty bitmap or a
fully specified one. For the former case we initialize the in-kernel
bitmap with zero, for the latter we copy the user supplied bitmap. For
state updates the full bitmap must be supplied.

To prevent overflows in the bitmap length calculation the maximum size
of bmp_len is limited to 128 by this patch -- resulting in a maximum
replay window of 4096 packets. This should be sufficient for all real
life scenarios (RFC 4303 recommends a default replay window size of 64).

Cc: Steffen Klassert <steffen.klassert@secunet.com>
Cc: Martin Willi <martin@revosec.ch>
Cc: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: Mathias Krause <minipli@googlemail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
12 years agoxfrm_user: fix info leak in copy_to_user_tmpl()
Mathias Krause [Wed, 19 Sep 2012 11:33:41 +0000 (11:33 +0000)]
xfrm_user: fix info leak in copy_to_user_tmpl()

The memory used for the template copy is a local stack variable. As
struct xfrm_user_tmpl contains multiple holes added by the compiler for
alignment, not initializing the memory will lead to leaking stack bytes
to userland. Add an explicit memset(0) to avoid the info leak.

Initial version of the patch by Brad Spengler.

Cc: Brad Spengler <spender@grsecurity.net>
Signed-off-by: Mathias Krause <minipli@googlemail.com>
Acked-by: Steffen Klassert <steffen.klassert@secunet.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
12 years agoxfrm_user: fix info leak in copy_to_user_policy()
Mathias Krause [Wed, 19 Sep 2012 11:33:40 +0000 (11:33 +0000)]
xfrm_user: fix info leak in copy_to_user_policy()

The memory reserved to dump the xfrm policy includes multiple padding
bytes added by the compiler for alignment (padding bytes in struct
xfrm_selector and struct xfrm_userpolicy_info). Add an explicit
memset(0) before filling the buffer to avoid the heap info leak.

Signed-off-by: Mathias Krause <minipli@googlemail.com>
Acked-by: Steffen Klassert <steffen.klassert@secunet.com>
Signed-off-by: David S. Miller <davem@davemloft.net>