]> rtime.felk.cvut.cz Git - linux-imx.git/log
linux-imx.git
12 years agotps65912: irq: add interrupt controller
Margarita Olaya [Thu, 9 Jun 2011 19:50:13 +0000 (14:50 -0500)]
tps65912: irq: add interrupt controller

This module controls the interrupt handling for the tps65912.
The interrupt sources can be the following:

- GPIO
- PWRON signal
- PWRHOLD signal
- Temperature detection

Signed-off-by: Margarita Olaya Cabrera <magi@slimlogic.co.uk>
Acked-by: Samuel Ortiz <sameo@linux.intel.com>
Acked-by: Liam Girdwood <lrg@ti.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
12 years agomfd: tps65912: Add new mfd device
Margarita Olaya [Thu, 9 Jun 2011 19:50:00 +0000 (14:50 -0500)]
mfd: tps65912: Add new mfd device

The tps65912 chip is a power management IC. It contains the following
components:

- Regulators
- GPIO controller

The core driver is registered as a platform driver, it provides communication
through I2C and SPI interfaces.

Signed-off-by: Margarita Olaya Cabrera <magi@slimlogic.co.uk>
Acked-by: Samuel Ortiz <sameo@linux.intel.com>
Acked-by: Liam Girdwood <lrg@ti.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
12 years agomfd: Use kstrtoul_from_user in ab8500
Peter Huewe [Mon, 6 Jun 2011 20:43:32 +0000 (22:43 +0200)]
mfd: Use kstrtoul_from_user in ab8500

This patch replaces the code for getting an unsigned long from a
userspace buffer by a simple call to kstroul_from_user.
This makes it easier to read and less error prone.

Signed-off-by: Peter Huewe <peterhuewe@gmx.de>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
12 years agomfd: Use kstrtoul_from_user in ab3550
Peter Huewe [Mon, 6 Jun 2011 20:43:31 +0000 (22:43 +0200)]
mfd: Use kstrtoul_from_user in ab3550

This patch replaces the code for getting an unsigned long from a
userspace buffer by a simple call to kstroul_from_user.
This makes it easier to read and less error prone.

Signed-off-by: Peter Huewe <peterhuewe@gmx.de>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
12 years agomfd: Use generic irq chip for jz4740-adc
Lars-Peter Clausen [Fri, 3 Jun 2011 01:14:26 +0000 (03:14 +0200)]
mfd: Use generic irq chip for jz4740-adc

Use the generic irq chip framework for implementing the irq chip for
the jz4740-adc driver.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Cc: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
12 years agomfd: Fix error handling if BUG() isn't enabled in WM8994
Mark Brown [Fri, 17 Jun 2011 11:19:41 +0000 (12:19 +0100)]
mfd: Fix error handling if BUG() isn't enabled in WM8994

Even if we would've BUG()ed we should still tidy up after ourselves if that
isn't enabled in the kernel config.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
12 years agomfd: Fix WM8994 IRQ register cache restore on resume
Mark Brown [Tue, 7 Jun 2011 10:49:42 +0000 (11:49 +0100)]
mfd: Fix WM8994 IRQ register cache restore on resume

When the byte swap was factored out into the per-register I/O functions
the register restore for the IRQ mask cache (which we use and store in
CPU native format for the interrupt handler) was not updated to do a byte
swap when it uses the bulk I/O. Fix this by writing the cache out one
register at a time.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
12 years agomfd: Support multiple active WM831x AUXADC conversions
Mark Brown [Tue, 7 Jun 2011 10:47:28 +0000 (11:47 +0100)]
mfd: Support multiple active WM831x AUXADC conversions

The WM831x AUXADC hardware can schedule multiple conversions at once,
allowing higher performance when more than one source is in use as we
can have the hardware start new conversions without having to wait for
a register write.

Take advantage of this in the interrupt driven case, maintaining a list of
callers that are waiting for AUXADC conversions and completing them all
simultaneously. The external interface of the AUXADC is not changed so
there will be limited use of the feature immediately.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
12 years agomfd: Restructure wm8994-core device revision handling
Mark Brown [Thu, 2 Jun 2011 18:18:55 +0000 (19:18 +0100)]
mfd: Restructure wm8994-core device revision handling

Switch on the device type before revision since anything we do here will
be device as well as revision specific.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
12 years agomfd: Allocate wm835x irq descs dynamically
Sascha Hauer [Thu, 2 Jun 2011 18:18:54 +0000 (19:18 +0100)]
mfd: Allocate wm835x irq descs dynamically

This allows boards to leave the irq_base field unitialized and
prevents them having to reserve irqs in the platform.
pdata can be optional for irq support now. Without pdata the
driver allocates some free irq range. With pdata and irq_base > 0
the driver allocates exactly the specified irq.
Without pdata the irq defaults to IRQF_TRIGGER_LOW.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
12 years agomfd: Refactor wm831x AUXADC handling into a separate file
Mark Brown [Thu, 2 Jun 2011 18:18:53 +0000 (19:18 +0100)]
mfd: Refactor wm831x AUXADC handling into a separate file

In preparation for some additional work on the wm831x AUXADC code move the
support into a separate file. This is a simple code motion patch, there
should be no functional changes.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
12 years agomfd: Read wm831x AUXADC conversion results before acknowledging interrupt
Mark Brown [Thu, 2 Jun 2011 18:18:52 +0000 (19:18 +0100)]
mfd: Read wm831x AUXADC conversion results before acknowledging interrupt

Ensure that there's no possibility of loosing an AUXADC interrupt by reading
the conversion result in the IRQ handler when using interrupts. Otherwise
it's possible that under very heavy load a new conversion could be initiated
before the acknowledgement for a previous interrupt has happened.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
12 years agomfd: Support dynamic allocation of IRQ range for wm831x
Mark Brown [Thu, 2 Jun 2011 18:18:51 +0000 (19:18 +0100)]
mfd: Support dynamic allocation of IRQ range for wm831x

Use irq_allocate_desc() to get the IRQ range, which turns into a noop on
non-sparse systems. Since all existing users are non-sparse there should
be no compatibility issues.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
12 years agomfd: Only register wm831x RTC device if the 32.768kHz crystal is enabled
Mark Brown [Thu, 2 Jun 2011 18:18:50 +0000 (19:18 +0100)]
mfd: Only register wm831x RTC device if the 32.768kHz crystal is enabled

The RTC uses the 32.768kHz crystal so if it's not enabled (and it can only
be enabled via OTP or InstantConfig, not runtime software) the RTC can't
function.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
12 years agomfd: Allow touchscreen to be disabled on wm831x devices
Mark Brown [Thu, 2 Jun 2011 18:18:49 +0000 (19:18 +0100)]
mfd: Allow touchscreen to be disabled on wm831x devices

Allow platform data to flag the touchscreen as disabled so that if the
touch driver is built in we don't end up causing lots of work by spuriously
detecting touchscreen activity on systems where it isn't in use.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
12 years agomfd: Implement support for multiple WM831x devices
Mark Brown [Thu, 2 Jun 2011 18:18:48 +0000 (19:18 +0100)]
mfd: Implement support for multiple WM831x devices

Systems using this functionality will be uncommon.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
12 years agomfd: Fix bus lock interaction for WM831x IRQ set_type() operation
Mark Brown [Thu, 2 Jun 2011 18:18:47 +0000 (19:18 +0100)]
mfd: Fix bus lock interaction for WM831x IRQ set_type() operation

The WM831x IRQ set_type() operation is doing a direct register write when
called but since set_type() is called with the bus lock held this isn't
legal and could cause deadlocks in the IRQ core.

Fix this by posting the updates into an array and syncing in the
bus_sync_unlock() callback.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
12 years agocifs: remove unneeded variable initialization in cifs_reconnect_tcon
Jeff Layton [Thu, 28 Jul 2011 16:40:36 +0000 (12:40 -0400)]
cifs: remove unneeded variable initialization in cifs_reconnect_tcon

Reported-and-acked-by: David Howells <dhowells@redhat.com>
Signed-off-by: Jeff Layton <jlayton@redhat.com>
Signed-off-by: Steve French <sfrench@us.ibm.com>
12 years agocifs: simplify refcounting for oplock breaks
Jeff Layton [Tue, 26 Jul 2011 16:20:17 +0000 (12:20 -0400)]
cifs: simplify refcounting for oplock breaks

Currently, we take a sb->s_active reference and a cifsFileInfo reference
when an oplock break workqueue job is queued. This is unnecessary and
more complicated than it needs to be. Also as Al points out,
deactivate_super has non-trivial locking implications so it's best to
avoid that if we can.

Instead, just cancel any pending oplock breaks for this filehandle
synchronously in cifsFileInfo_put after taking it off the lists.
That should ensure that this job doesn't outlive the structures it
depends on.

Reported-by: Al Viro <viro@ZenIV.linux.org.uk>
Signed-off-by: Jeff Layton <jlayton@redhat.com>
Signed-off-by: Steve French <sfrench@us.ibm.com>
12 years agocifs: fix compiler warning in CIFSSMBQAllEAs
Jeff Layton [Thu, 28 Jul 2011 16:48:26 +0000 (12:48 -0400)]
cifs: fix compiler warning in CIFSSMBQAllEAs

The recent fix to the above function causes this compiler warning to pop
on some gcc versions:

  CC [M]  fs/cifs/cifssmb.o
fs/cifs/cifssmb.c: In function ‘CIFSSMBQAllEAs’:
fs/cifs/cifssmb.c:5708: warning: ‘ea_name_len’ may be used uninitialized in
this function

Signed-off-by: Jeff Layton <jlayton@redhat.com>
Signed-off-by: Steve French <sfrench@us.ibm.com>
12 years agocifs: fix name parsing in CIFSSMBQAllEAs
Jeff Layton [Tue, 26 Jul 2011 22:23:47 +0000 (18:23 -0400)]
cifs: fix name parsing in CIFSSMBQAllEAs

The code that matches EA names in CIFSSMBQAllEAs is incorrect. It
uses strncmp to do the comparison with the length limited to the
name_len sent in the response.

Problem: Suppose we're looking for an attribute named "foobar" and
have an attribute before it in the EA list named "foo". The
comparison will succeed since we're only looking at the first 3
characters. Fix this by also comparing the length of the provided
ea_name with the name_len in the response. If they're not equal then
it shouldn't match.

Reported-by: Jian Li <jiali@redhat.com>
Signed-off-by: Jeff Layton <jlayton@redhat.com>
Reviewed-by: Pavel Shilovsky <piastryyy@gmail.com>
Signed-off-by: Steve French <sfrench@us.ibm.com>
12 years agocifs: don't start signing too early
Jeff Layton [Tue, 26 Jul 2011 16:21:17 +0000 (12:21 -0400)]
cifs: don't start signing too early

Sniffing traffic on the wire shows that windows clients send a zeroed
out signature field in a NEGOTIATE request, and send "BSRSPYL" in the
signature field during SESSION_SETUP. Make the cifs client behave the
same way.

It doesn't seem to make much difference in any server that I've tested
against, but it's probably best to follow windows behavior as closely as
possible here.

Signed-off-by: Jeff Layton <jlayton@redhat.com>
Reviewed-by: Shirish Pargaonkar <shirishpargaonkar@gmail.com>
Signed-off-by: Steve French <sfrench@us.ibm.com>
12 years agocifs: trivial: goto out here is unnecessary
Jeff Layton [Tue, 26 Jul 2011 16:20:18 +0000 (12:20 -0400)]
cifs: trivial: goto out here is unnecessary

...and remove some obsolete comments.

Signed-off-by: Jeff Layton <jlayton@redhat.com>
Signed-off-by: Steve French <sfrench@us.ibm.com>
12 years agocifs: advertise the right receive buffer size to the server
Jeff Layton [Tue, 26 Jul 2011 16:20:18 +0000 (12:20 -0400)]
cifs: advertise the right receive buffer size to the server

Currently, we mirror the same size back to the server that it sends us.
That makes little sense. Instead we should be sending the server the
maximum buffer size that we can handle -- CIFSMaxBufSize minus the
4 byte RFC1001 header.

Signed-off-by: Jeff Layton <jlayton@redhat.com>
Signed-off-by: Steve French <sfrench@us.ibm.com>
12 years agoMerge branch 'nfs-for-3.1' of git://git.linux-nfs.org/projects/trondmy/linux-nfs
Linus Torvalds [Sun, 31 Jul 2011 16:26:50 +0000 (06:26 -1000)]
Merge branch 'nfs-for-3.1' of git://git.linux-nfs.org/projects/trondmy/linux-nfs

* 'nfs-for-3.1' of git://git.linux-nfs.org/projects/trondmy/linux-nfs: (28 commits)
  pnfsblock: write_pagelist handle zero invalid extents
  pnfsblock: note written INVAL areas for layoutcommit
  pnfsblock: bl_write_pagelist
  pnfsblock: bl_read_pagelist
  pnfsblock: cleanup_layoutcommit
  pnfsblock: encode_layoutcommit
  pnfsblock: merge rw extents
  pnfsblock: add extent manipulation functions
  pnfsblock: bl_find_get_extent
  pnfsblock: xdr decode pnfs_block_layout4
  pnfsblock: call and parse getdevicelist
  pnfsblock: merge extents
  pnfsblock: lseg alloc and free
  pnfsblock: remove device operations
  pnfsblock: add device operations
  pnfsblock: basic extent code
  pnfsblock: use pageio_ops api
  pnfsblock: add blocklayout Kconfig option, Makefile, and stubs
  pnfs: cleanup_layoutcommit
  pnfs: ask for layout_blksize and save it in nfs_server
  ...

12 years agoMerge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/penberg...
Linus Torvalds [Sun, 31 Jul 2011 16:25:37 +0000 (06:25 -1000)]
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/penberg/slab-2.6

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/penberg/slab-2.6:
  slab: use NUMA_NO_NODE
  slab: remove one NR_CPUS dependency

12 years agoMerge branch 'urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git...
Linus Torvalds [Sun, 31 Jul 2011 16:25:09 +0000 (06:25 -1000)]
Merge branch 'urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/wfg/writeback

* 'urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/wfg/writeback:
  don't busy retry the inode on failed grab_super_passive()

12 years agoMerge git://git.infradead.org/battery-2.6
Linus Torvalds [Sun, 31 Jul 2011 16:24:50 +0000 (06:24 -1000)]
Merge git://git.infradead.org/battery-2.6

* git://git.infradead.org/battery-2.6:
  gpio-charger: Fix checking return value of request_any_context_irq
  power_supply: MAX17042: Support additional properties
  max8903_charger: Allow platform data to be __initdata
  power_supply: Add charger driver for MAX8998/LP3974
  power_supply: Add charger driver for MAX8997/8966
  max17042_battery: Remove obsolete cleanup for clientdata
  twl4030_charger: Fix warnings
  wm831x_power: Support multiple instances
  wm831x_backup: Support multiple instances
  apm_power: Fix style error in macros
  s3c_adc_battery: Fix annotation for s3c_adc_battery_probe()
  bq20z75: Enable detection after registering
  bq20z75: Add support for external notification

12 years agoMerge git://git.kernel.org/pub/scm/linux/kernel/git/brodo/cpupowerutils
Linus Torvalds [Sun, 31 Jul 2011 16:23:40 +0000 (06:23 -1000)]
Merge git://git.kernel.org/pub/scm/linux/kernel/git/brodo/cpupowerutils

* git://git.kernel.org/pub/scm/linux/kernel/git/brodo/cpupowerutils:
  cpupower: Do detect IDA (opportunistic processor performance) via cpuid
  cpupower: Show Intel turbo ratio support via ./cpupower frequency-info
  cpupowerutils: increase MAX_LINE_LEN
  cpupower: Rename package from cpupowerutils to cpupower
  cpupowerutils: Rename: libcpufreq->libcpupower
  cpupowerutils: use kernel version-derived version string
  cpupowerutils: utils - ConfigStyle bugfixes
  cpupowerutils: helpers - ConfigStyle bugfixes
  cpupowerutils: idle_monitor - ConfigStyle bugfixes
  cpupowerutils: lib - ConfigStyle bugfixes
  cpupowerutils: bench - ConfigStyle bugfixes
  cpupowerutils: do not update po files on each and every compile
  cpupowerutils: remove ccdv, use kernel quiet/verbose mechanism
  cpupowerutils: use COPYING, CREDITS from top-level directory
  cpupowerutils - cpufrequtils extended with quite some features

12 years agoMerge git://git.kernel.org/pub/scm/linux/kernel/git/brodo/pcmcia-2.6
Linus Torvalds [Sun, 31 Jul 2011 16:23:08 +0000 (06:23 -1000)]
Merge git://git.kernel.org/pub/scm/linux/kernel/git/brodo/pcmcia-2.6

* git://git.kernel.org/pub/scm/linux/kernel/git/brodo/pcmcia-2.6:
  smc91c92_cs.c: fix bogus compiler warning
  orinoco_cs: be more careful when matching cards with ID 0x0156:0x0002
  hostap_cs: support cards with "Version 01.02" as third product ID
  pcmcia: add PCMCIA_DEVICE_MANF_CARD_PROD_ID3
  pxa2xx pcmcia - stargate 2 use gpio array.
  pcmcia: pxa2xx: remove empty socket_init / socket_resume functions.
  drivers:pcmcia:soc_common: make socket_init and socket_suspend optional

12 years agopnfsblock: write_pagelist handle zero invalid extents
Peng Tao [Sun, 31 Jul 2011 00:52:56 +0000 (20:52 -0400)]
pnfsblock: write_pagelist handle zero invalid extents

For invalid extents, find other pages in the same fsblock and write them out.

[pnfsblock: write_begin]
Signed-off-by: Fred Isaman <iisaman@citi.umich.edu>
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Signed-off-by: Benny Halevy <bhalevy@tonian.com>
Signed-off-by: Peng Tao <peng_tao@emc.com>
Signed-off-by: Jim Rees <rees@umich.edu>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
12 years agopnfsblock: note written INVAL areas for layoutcommit
Fred Isaman [Sun, 31 Jul 2011 00:52:55 +0000 (20:52 -0400)]
pnfsblock: note written INVAL areas for layoutcommit

Signed-off-by: Peng Tao <peng_tao@emc.com>
Signed-off-by: Fred Isaman <iisaman@citi.umich.edu>
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Signed-off-by: Benny Halevy <bhalevy@tonian.com>
Signed-off-by: Jim Rees <rees@umich.edu>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
12 years agopnfsblock: bl_write_pagelist
Fred Isaman [Sun, 31 Jul 2011 00:52:54 +0000 (20:52 -0400)]
pnfsblock: bl_write_pagelist

Note: When upper layer's read/write request cannot be fulfilled, the block
layout driver shouldn't silently mark the page as error. It should do
what can be done and  leave the rest to the upper layer. To do so, we
should set rdata/wdata->res.count properly.

When upper layer re-send the read/write request to finish the rest
part of the request, pgbase is the position where we should start at.

[pnfsblock: bl_write_pagelist support functions]
[pnfsblock: bl_write_pagelist adjust for missing PG_USE_PNFS]
Signed-off-by: Fred Isaman <iisaman@citi.umich.edu>
[pnfsblock: handle errors when read or write pagelist.]
Signed-off-by: Zhang Jingwang <yyalone@gmail.com>
[pnfs-block: use new write_pagelist api]
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Signed-off-by: Benny Halevy <bhalevy@tonian.com>
Signed-off-by: Jim Rees <rees@umich.edu>
[SQUASHME: pnfsblock: mds_offset is set in the generic layer]
Signed-off-by: Boaz Harrosh <bharrosh@panasas.com>
Signed-off-by: Benny Halevy <bhalevy@tonian.com>
[pnfsblock: mark IO error with NFS_LAYOUT_{RW|RO}_FAILED]
Signed-off-by: Peng Tao <peng_tao@emc.com>
[pnfsblock: SQUASHME: adjust to API change]
Signed-off-by: Fred Isaman <iisaman@citi.umich.edu>
[pnfsblock: fixup blksize alignment in bl_setup_layoutcommit]
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Signed-off-by: Benny Halevy <bhalevy@tonian.com>
[pnfsblock: bl_write_pagelist adjust for missing PG_USE_PNFS]
Signed-off-by: Fred Isaman <iisaman@citi.umich.edu>
[pnfsblock: handle errors when read or write pagelist.]
Signed-off-by: Zhang Jingwang <yyalone@gmail.com>
[pnfs-block: use new write_pagelist api]
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Signed-off-by: Benny Halevy <bhalevy@tonian.com>
Signed-off-by: Jim Rees <rees@umich.edu>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
12 years agopnfsblock: bl_read_pagelist
Fred Isaman [Sun, 31 Jul 2011 00:52:53 +0000 (20:52 -0400)]
pnfsblock: bl_read_pagelist

Note: When upper layer's read/write request cannot be fulfilled, the block
layout driver shouldn't silently mark the page as error. It should do
what can be done and  leave the rest to the upper layer. To do so, we
should set rdata/wdata->res.count properly.

When upper layer re-send the read/write request to finish the rest
part of the request, pgbase is the position where we should start at.

[pnfsblock: mark IO error with NFS_LAYOUT_{RW|RO}_FAILED]
Signed-off-by: Peng Tao <peng_tao@emc.com>
[pnfsblock: read path error handling]
Signed-off-by: Fred Isaman <iisaman@citi.umich.edu>
[pnfsblock: handle errors when read or write pagelist.]
Signed-off-by: Zhang Jingwang <yyalone@gmail.com>
[pnfs-block: use new read_pagelist api]
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Signed-off-by: Benny Halevy <bhalevy@tonian.com>
Signed-off-by: Jim Rees <rees@umich.edu>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
12 years agopnfsblock: cleanup_layoutcommit
Fred Isaman [Sun, 31 Jul 2011 00:52:52 +0000 (20:52 -0400)]
pnfsblock: cleanup_layoutcommit

In blocklayout driver. There are two things happening
while layoutcommit/cleanup.
1. the modified extents are encoded.
2. On cleanup the extents are put back on the layout rw
   extents list, for reads.

In the new system where actual xdr encoding is done in
encode_layoutcommit() directly into xdr buffer, these are
the new commit stages:

1. On setup_layoutcommit, the range is adjusted as before
   and a structure is allocated for communication with
   bl_encode_layoutcommit && bl_cleanup_layoutcommit
   (Generic layer provides a void-star to hang it on)

2. bl_encode_layoutcommit is called to do the actual
   encoding directly into xdr. The commit-extent-list is not
   freed and is stored on above structure.
   FIXME: The code is not yet converted to the new XDR cleanup

3. On cleanup the commit-extent-list is put back by a call
   to set_to_rw() as before, but with no need for XDR decoding
   of the list as before. And the commit-extent-list is freed.
   Finally allocated structure is freed.

[rm inode and pnfs_layout_hdr args from cleanup_layoutcommit()]
Signed-off-by: Jim Rees <rees@umich.edu>
[pnfsblock: introduce bl_committing list]
Signed-off-by: Peng Tao <peng_tao@emc.com>
[pnfsblock: SQUASHME: adjust to API change]
Signed-off-by: Fred Isaman <iisaman@citi.umich.edu>
[blocklayout: encode_layoutcommit implementation]
Signed-off-by: Boaz Harrosh <bharrosh@panasas.com>
[pnfsblock: fix bug setting up layoutcommit.]
Signed-off-by: Tao Guo <guotao@nrchpc.ac.cn>
[pnfsblock: cleanup_layoutcommit wants a status parameter]
Signed-off-by: Boaz Harrosh <bharrosh@panasas.com>
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Signed-off-by: Benny Halevy <bhalevy@tonian.com>
Signed-off-by: Jim Rees <rees@umich.edu>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
12 years agopnfsblock: encode_layoutcommit
Fred Isaman [Sun, 31 Jul 2011 00:52:51 +0000 (20:52 -0400)]
pnfsblock: encode_layoutcommit

In blocklayout driver. There are two things happening
while layoutcommit/cleanup.
1. the modified extents are encoded.
2. On cleanup the extents are put back on the layout rw
   extents list, for reads.

In the new system where actual xdr encoding is done in
encode_layoutcommit() directly into xdr buffer, these are
the new commit stages:

1. On setup_layoutcommit, the range is adjusted as before
   and a structure is allocated for communication with
   bl_encode_layoutcommit && bl_cleanup_layoutcommit
   (Generic layer provides a void-star to hang it on)

2. bl_encode_layoutcommit is called to do the actual
   encoding directly into xdr. The commit-extent-list is not
   freed and is stored on above structure.
   FIXME: The code is not yet converted to the new XDR cleanup

3. On cleanup the commit-extent-list is put back by a call
   to set_to_rw() as before, but with no need for XDR decoding
   of the list as before. And the commit-extent-list is freed.
   Finally allocated structure is freed.

[rm inode and pnfs_layout_hdr args from cleanup_layoutcommit()]
[pnfsblock: get rid of deprecated xdr macros]
Signed-off-by: Jim Rees <rees@umich.edu>
Signed-off-by: Peng Tao <peng_tao@emc.com>
Signed-off-by: Fred Isaman <iisaman@citi.umich.edu>
[blocklayout: encode_layoutcommit implementation]
Signed-off-by: Boaz Harrosh <bharrosh@panasas.com>
[pnfsblock: fix bug setting up layoutcommit.]
Signed-off-by: Tao Guo <guotao@nrchpc.ac.cn>
[pnfsblock: prevent commit list corruption]
[pnfsblock: fix layoutcommit with an empty opaque]
Signed-off-by: Fred Isaman <iisaman@citi.umich.edu>
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Signed-off-by: Benny Halevy <bhalevy@tonian.com>
Signed-off-by: Jim Rees <rees@umich.edu>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
12 years agopnfsblock: merge rw extents
Fred Isaman [Sun, 31 Jul 2011 00:52:50 +0000 (20:52 -0400)]
pnfsblock: merge rw extents

Signed-off-by: Fred Isaman <iisaman@citi.umich.edu>
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Signed-off-by: Benny Halevy <bhalevy@tonian.com>
Signed-off-by: Jim Rees <rees@umich.edu>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
12 years agopnfsblock: add extent manipulation functions
Fred Isaman [Sun, 31 Jul 2011 00:52:49 +0000 (20:52 -0400)]
pnfsblock: add extent manipulation functions

Adds working implementations of various support functions
to handle INVAL extents, needed by writes, such as
bl_mark_sectors_init and bl_is_sector_init.

[pnfsblock: fix 64-bit compiler warnings for extent manipulation]
Signed-off-by: Fred Isaman <iisaman@citi.umich.edu>
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Signed-off-by: Benny Halevy <bhalevy@tonian.com>
[Implement release_inval_marks]
Signed-off-by: Zhang Jingwang <zhangjingwang@nrchpc.ac.cn>
Signed-off-by: Jim Rees <rees@umich.edu>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
12 years agopnfsblock: bl_find_get_extent
Fred Isaman [Sun, 31 Jul 2011 00:52:48 +0000 (20:52 -0400)]
pnfsblock: bl_find_get_extent

Implement bl_find_get_extent(), one of the core extent manipulation
routines.

[pnfsblock: Lookup list entry of layouts and tags in reverse order]
Signed-off-by: Zhang Jingwang <zhangjingwang@nrchpc.ac.cn>
Signed-off-by: Fred Isaman <iisaman@citi.umich.edu>
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Signed-off-by: Jim Rees <rees@umich.edu>
pnfsblock: fix print format warnings for sector_t and size_t

gcc spews warnings about these on x86_64, e.g.:
fs/nfs/blocklayout/blocklayout.c:74: warning: format ‘%Lu’ expects type ‘long long unsigned int’, but argument 2 has type ‘sector_t’
fs/nfs/blocklayout/blocklayout.c:388: warning: format ‘%d’ expects type ‘int’, but argument 5 has type ‘size_t’

Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Signed-off-by: Benny Halevy <bhalevy@tonian.com>
Signed-off-by: Jim Rees <rees@umich.edu>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
12 years agopnfsblock: xdr decode pnfs_block_layout4
Fred Isaman [Sun, 31 Jul 2011 00:52:47 +0000 (20:52 -0400)]
pnfsblock: xdr decode pnfs_block_layout4

XDR decodes the block layout payload sent in LAYOUTGET result, storing
the result in an extent list.

[pnfsblock: get rid of deprecated xdr macros]
Signed-off-by: Jim Rees <rees@umich.edu>
Signed-off-by: Fred Isaman <iisaman@citi.umich.edu>
[pnfsblock: fix bug getting pnfs_layout_type in translate_devid().]
Signed-off-by: Tao Guo <guotao@nrchpc.ac.cn>
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Signed-off-by: Benny Halevy <bhalevy@tonian.com>
Signed-off-by: Jim Rees <rees@umich.edu>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
12 years agopnfsblock: call and parse getdevicelist
Fred Isaman [Sun, 31 Jul 2011 00:52:46 +0000 (20:52 -0400)]
pnfsblock: call and parse getdevicelist

Call GETDEVICELIST during mount, then call and parse GETDEVICEINFO
for each device returned.

[pnfsblock: get rid of deprecated xdr macros]
Signed-off-by: Jim Rees <rees@umich.edu>
[pnfsblock: fix pnfs_deviceid references]
Signed-off-by: Fred Isaman <iisaman@citi.umich.edu>
[pnfsblock: fix print format warnings for sector_t and size_t]
[pnfs-block: #include <linux/vmalloc.h>]
[pnfsblock: no PNFS_NFS_SERVER]
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
[pnfsblock: fix bug determining size of striped volume]
[pnfsblock: fix oops when using multiple devices]
Signed-off-by: Fred Isaman <iisaman@citi.umich.edu>
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Signed-off-by: Benny Halevy <bhalevy@tonian.com>
[pnfsblock: get rid of vmap and deviceid->area structure]
Signed-off-by: Peng Tao <peng_tao@emc.com>
Signed-off-by: Jim Rees <rees@umich.edu>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
12 years agopnfsblock: merge extents
Fred Isaman [Sun, 31 Jul 2011 00:52:45 +0000 (20:52 -0400)]
pnfsblock: merge extents

Replace a stub, so that extents underlying the layouts are properly
added, merged, or ignored as necessary.

Signed-off-by: Fred Isaman <iisaman@citi.umich.edu>
[pnfsblock: delete the new node before put it]
Signed-off-by: Mingyang Guo <guomingyang@nrchpc.ac.cn>
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Signed-off-by: Peng Tao <peng_tao@emc.com>
Signed-off-by: Benny Halevy <bhalevy@tonian.com>
Signed-off-by: Jim Rees <rees@umich.edu>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
12 years agopnfsblock: lseg alloc and free
Fred Isaman [Sun, 31 Jul 2011 00:52:44 +0000 (20:52 -0400)]
pnfsblock: lseg alloc and free

Signed-off-by: Fred Isaman <iisaman@citi.umich.edu>
[pnfsblock: fix bug getting pnfs_layout_type in translate_devid().]
Signed-off-by: Tao Guo <guotao@nrchpc.ac.cn>
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Signed-off-by: Zhang Jingwang <Jingwang.Zhang@emc.com>
Signed-off-by: Benny Halevy <bhalevy@tonian.com>
Signed-off-by: Jim Rees <rees@umich.edu>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
12 years agopnfsblock: remove device operations
Jim Rees [Sun, 31 Jul 2011 00:52:43 +0000 (20:52 -0400)]
pnfsblock: remove device operations

Signed-off-by: Jim Rees <rees@umich.edu>
Signed-off-by: Fred Isaman <iisaman@citi.umich.edu>
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Signed-off-by: Benny Halevy <bhalevy@tonian.com>
[upcall bugfixes]
Signed-off-by: Peng Tao <peng_tao@emc.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
12 years agopnfsblock: add device operations
Jim Rees [Sun, 31 Jul 2011 00:52:42 +0000 (20:52 -0400)]
pnfsblock: add device operations

Signed-off-by: Jim Rees <rees@umich.edu>
Signed-off-by: Fred Isaman <iisaman@citi.umich.edu>
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Signed-off-by: Benny Halevy <bhalevy@tonian.com>
[upcall bugfixes]
Signed-off-by: Peng Tao <peng_tao@emc.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
12 years agopnfsblock: basic extent code
Fred Isaman [Sun, 31 Jul 2011 00:52:41 +0000 (20:52 -0400)]
pnfsblock: basic extent code

Adds structures and basic create/delete code for extents.

Signed-off-by: Fred Isaman <iisaman@citi.umich.edu>
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Signed-off-by: Zhang Jingwang <Jingwang.Zhang@emc.com>
Signed-off-by: Benny Halevy <bhalevy@tonian.com>
Signed-off-by: Jim Rees <rees@umich.edu>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
12 years agopnfsblock: use pageio_ops api
Benny Halevy [Sun, 31 Jul 2011 00:52:40 +0000 (20:52 -0400)]
pnfsblock: use pageio_ops api

[pnfsblock: use pnfs_generic_pg_init_read/write]
Signed-off-by: Peng Tao <peng_tao@emc.com>
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Signed-off-by: Jim Rees <rees@umich.edu>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
12 years agopnfsblock: add blocklayout Kconfig option, Makefile, and stubs
Fred Isaman [Sun, 31 Jul 2011 00:52:39 +0000 (20:52 -0400)]
pnfsblock: add blocklayout Kconfig option, Makefile, and stubs

Define a configuration variable to enable/disable compilation of the
block driver code.

Add the minimal structure for a pnfs block layout driver, and empty
list-heads that will hold the extent data

[pnfsblock: make NFS_V4_1 select PNFS_BLOCK]
Signed-off-by: Peng Tao <peng_tao@emc.com>
Signed-off-by: Fred Isaman <iisaman@citi.umich.edu>
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
[pnfs-block: fix CONFIG_PNFS_BLOCK dependencies]
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Signed-off-by: Benny Halevy <bhalevy@tonian.com>
[pnfsblock: SQUASHME: adjust to API change]
Signed-off-by: Fred Isaman <iisaman@citi.umich.edu>
[pnfs: move pnfs_layout_type inline in nfs_inode]
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
[blocklayout: encode_layoutcommit implementation]
Signed-off-by: Boaz Harrosh <bharrosh@panasas.com>
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Signed-off-by: Benny Halevy <bhalevy@tonian.com>
[pnfsblock: layout alloc and free]
Signed-off-by: Fred Isaman <iisaman@citi.umich.edu>
[pnfs: move pnfs_layout_type inline in nfs_inode]
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Signed-off-by: Benny Halevy <bhalevy@tonian.com>
[pnfsblock: define module alias]
Signed-off-by: Peng Tao <peng_tao@emc.com>
[rm inode and pnfs_layout_hdr args from cleanup_layoutcommit()]
Signed-off-by: Jim Rees <rees@umich.edu>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
12 years agopnfs: cleanup_layoutcommit
Andy Adamson [Sun, 31 Jul 2011 00:52:38 +0000 (20:52 -0400)]
pnfs: cleanup_layoutcommit

This gives layout driver a chance to cleanup structures they put in at
encode_layoutcommit.

Signed-off-by: Andy Adamson <andros@netapp.com>
[fixup layout header pointer for layoutcommit]
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Signed-off-by: Benny Halevy <bhalevy@tonian.com>
[rm inode and pnfs_layout_hdr args from cleanup_layoutcommit()]
Signed-off-by: Jim Rees <rees@umich.edu>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
12 years agopnfs: ask for layout_blksize and save it in nfs_server
Fred Isaman [Sun, 31 Jul 2011 00:52:37 +0000 (20:52 -0400)]
pnfs: ask for layout_blksize and save it in nfs_server

Block layout needs it to determine IO size.

Signed-off-by: Fred Isaman <iisaman@citi.umich.edu>
Signed-off-by: Tao Guo <glorioustao@gmail.com>
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Signed-off-by: Benny Halevy <bhalevy@tonian.com>
Signed-off-by: Jim Rees <rees@umich.edu>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
12 years agopnfs: add set-clear layoutdriver interface
Benny Halevy [Sun, 31 Jul 2011 00:52:36 +0000 (20:52 -0400)]
pnfs: add set-clear layoutdriver interface

To allow layout driver to issue getdevicelist at mount time, and clean up
at umount time.

[fixup non NFS_V4_1 set_pnfs_layoutdriver definition]
[pnfs: pass mntfh down the init_pnfs path]
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Signed-off-by: Benny Halevy <bhalevy@tonian.com>
Signed-off-by: Jim Rees <rees@umich.edu>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
12 years agopnfs: GETDEVICELIST
Andy Adamson [Sun, 31 Jul 2011 00:52:35 +0000 (20:52 -0400)]
pnfs: GETDEVICELIST

The block driver uses GETDEVICELIST

Signed-off-by: Andy Adamson <andros@netapp.com>
[pass struct nfs_server * to getdevicelist]
[get machince creds for getdevicelist]
[fix getdevicelist decode sizing]
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Signed-off-by: Benny Halevy <bhalevy@tonian.com>
Signed-off-by: Jim Rees <rees@umich.edu>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
12 years agopnfs: use lwb as layoutcommit length
Peng Tao [Sun, 31 Jul 2011 00:52:34 +0000 (20:52 -0400)]
pnfs: use lwb as layoutcommit length

Using NFS4_MAX_UINT64 will break current protocol.

[Needed in v3.0]
CC: Stable Tree <stable@kernel.org>
Signed-off-by: Peng Tao <peng_tao@emc.com>
Signed-off-by: Jim Rees <rees@umich.edu>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
12 years agopnfs: let layoutcommit handle a list of lseg
Peng Tao [Sun, 31 Jul 2011 00:52:33 +0000 (20:52 -0400)]
pnfs: let layoutcommit handle a list of lseg

There can be multiple lseg per file, so layoutcommit should be
able to handle it.

[Needed in v3.0]
CC: Stable Tree <stable@kernel.org>
Signed-off-by: Peng Tao <peng_tao@emc.com>
Signed-off-by: Boaz Harrosh <bharrosh@panasas.com>
Signed-off-by: Jim Rees <rees@umich.edu>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
12 years agopnfs: save layoutcommit cred at layout header init
Peng Tao [Sun, 31 Jul 2011 00:52:32 +0000 (20:52 -0400)]
pnfs: save layoutcommit cred at layout header init

No need to save it for every lseg.
No need to save it at every pnfs_set_layoutcommit.

[Needed in v3.0]
CC: Stable Tree <stable@kernel.org>
Signed-off-by: Peng Tao <peng_tao@emc.com>
Signed-off-by: Boaz Harrosh <bharrosh@panasas.com>
Signed-off-by: Jim Rees <rees@umich.edu>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
12 years agopnfs: save layoutcommit lwb at layout header
Peng Tao [Sun, 31 Jul 2011 00:52:31 +0000 (20:52 -0400)]
pnfs: save layoutcommit lwb at layout header

No need to save it for every lseg.

[Needed in v3.0]
CC: Stable Tree <stable@kernel.org>
Signed-off-by: Peng Tao <peng_tao@emc.com>
Signed-off-by: Jim Rees <rees@umich.edu>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
12 years agoslab: use NUMA_NO_NODE
Andrew Morton [Thu, 28 Jul 2011 20:59:49 +0000 (13:59 -0700)]
slab: use NUMA_NO_NODE

Use the nice enumerated constant.

Cc: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Pekka Enberg <penberg@kernel.org>
12 years agodon't busy retry the inode on failed grab_super_passive()
Wu Fengguang [Sat, 30 Jul 2011 04:14:35 +0000 (22:14 -0600)]
don't busy retry the inode on failed grab_super_passive()

This fixes a soft lockup on conditions

a) the flusher is working on a work by __bdi_start_writeback(), while

b) someone else calls writeback_inodes_sb*() or sync_inodes_sb(), which
   grab sb->s_umount and enqueue a new work for the flusher to execute

The s_umount grabbed by (b) will fail the grab_super_passive() in (a).
Then if the inode is requeued, wb_writeback() will busy retry on it.
As a result, wb_writeback() loops for ever without releasing
wb->list_lock, which further blocks other tasks.

Fix the busy loop by redirtying the inode. This may undesirably delay
the writeback of the inode, however most likely it will be picked up
soon by the queued work by writeback_inodes_sb*(), sync_inodes_sb() or
even writeback_inodes_wb().

bug url: http://www.spinics.net/lists/linux-fsdevel/msg47292.html

Reported-by: Christoph Hellwig <hch@infradead.org>
Tested-by: Christoph Hellwig <hch@infradead.org>
Signed-off-by: Wu Fengguang <fengguang.wu@intel.com>
12 years agoMerge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial
Linus Torvalds [Sat, 30 Jul 2011 20:51:11 +0000 (10:51 -1000)]
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial:
  sungem: fix compile failure caused by trivial #include consolidation

12 years agom68k/math-emu: Remove unnecessary code
Greg Dietsche [Thu, 16 Jun 2011 16:42:07 +0000 (11:42 -0500)]
m68k/math-emu: Remove unnecessary code

Remove unnecessary code that matches this coccinelle pattern

if (...)
return ret;
return ret;

Signed-off-by: Greg Dietsche <Gregory.Dietsche@cuw.edu>
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
12 years agom68k/math-emu: Remove commented out old code
Geert Uytterhoeven [Sun, 12 Jun 2011 09:01:21 +0000 (11:01 +0200)]
m68k/math-emu: Remove commented out old code

It's been unused for ages, and contains bugs (e.g. incorrect shifts in
lsl64()).

Reported-by: Jonathan Elchison <jelchison@gmail.com>
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
12 years agom68k: Kill warning in setup_arch() when compiling for Sun3
Geert Uytterhoeven [Wed, 8 Jun 2011 18:31:32 +0000 (20:31 +0200)]
m68k: Kill warning in setup_arch() when compiling for Sun3

arch/m68k/kernel/setup_mm.c: In function ‘setup_arch’:
arch/m68k/kernel/setup_mm.c:219: warning: unused variable ‘i’

Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
12 years agom68k/atari: Prefix GPIO_{IN,OUT} with CODEC_
Geert Uytterhoeven [Wed, 8 Jun 2011 18:20:58 +0000 (20:20 +0200)]
m68k/atari: Prefix GPIO_{IN,OUT} with CODEC_

These defines are way to generic, and cause conflicts:

drivers/net/wireless/rtlwifi/rtl8192c/../rtl8192ce/reg.h:369:1: warning: "GPIO_IN" redefined
drivers/net/wireless/rtlwifi/rtl8192c/../rtl8192ce/reg.h:370:1: warning: "GPIO_OUT" redefined
drivers/net/wireless/rtlwifi/rtl8192se/reg.h:252:1: warning: "GPIO_IN" redefined
drivers/net/wireless/rtlwifi/rtl8192se/reg.h:253:1: warning: "GPIO_OUT" redefined

Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
12 years agosparc: iounmap() and *_free_coherent() - Use lookup_resource()
Geert Uytterhoeven [Sat, 7 May 2011 18:58:02 +0000 (20:58 +0200)]
sparc: iounmap() and *_free_coherent() - Use lookup_resource()

Replace a custom implementation (which doesn't lock the resource tree) by a
call to lookup_resource()

Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Acked-by: David S. Miller <davem@davemloft.net>
12 years agom68k/atari: Reserve some ST-RAM early on for device buffer use
Michael Schmitz [Mon, 1 Nov 2010 18:54:00 +0000 (19:54 +0100)]
m68k/atari: Reserve some ST-RAM early on for device buffer use

Based on an original patch from Michael Schmitz:

Because mem_init() is now called before device init, devices that rely on
ST-RAM may find all ST-RAM already allocated to other users by the time
device init happens. In particular, a large initrd RAM disk may use up
enough of ST-RAM to cause atari_stram_alloc() to resort to
__get_dma_pages() allocation.

In the current state of Atari memory management, all of RAM is marked
DMA capable, so __get_dma_pages() may well return RAM that is not in actual
fact DMA capable. Using this for frame buffer or SCSI DMA buffer causes
subtle failure.

The ST-RAM allocator has been changed to allocate memory from a pool of
reserved ST-RAM of configurable size, set aside on ST-RAM init (i.e.
before mem_init()). As long as this pool is not exhausted, allocation of
real ST-RAM can be guaranteed.

Other changes:
  - Replace the custom allocator in the ST-RAM pool by the existing allocator
    in the resource subsystem,
  - Remove mem_init_done and its hook, as memory init is now done before
    device init,
  - Remove /proc/stram, as ST-RAM usage now shows up under /proc/iomem, e.g.

005f2000-006f1fff : ST-RAM Pool
  005f2000-0063dfff : atafb
  0063e000-00641fff : ataflop
  00642000-00642fff : SCSI

Signed-off-by: Michael Schmitz <schmitz@debian.org>
[Andreas Schwab <schwab@linux-m68k.org>: Use memparse()]
[Geert: Use the resource subsystem instead of a custom allocator]
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
12 years agom68k/amiga: Chip RAM - Use lookup_resource()
Geert Uytterhoeven [Sat, 7 May 2011 18:56:00 +0000 (20:56 +0200)]
m68k/amiga: Chip RAM - Use lookup_resource()

Replace a custom implementation (which doesn't lock the resource tree) by a
call to lookup_resource()

Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
12 years agoresources: Add lookup_resource()
Geert Uytterhoeven [Sat, 7 May 2011 18:53:16 +0000 (20:53 +0200)]
resources: Add lookup_resource()

Add a function to find an existing resource by a resource start address.
This allows to implement simple allocators (with a malloc/free-alike API)
on top of the resource system.

Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
12 years agosparc: _sparc_find_resource() should check for exact matches
Geert Uytterhoeven [Sat, 7 May 2011 13:08:36 +0000 (15:08 +0200)]
sparc: _sparc_find_resource() should check for exact matches

The address that's passed to _sparc_find_resource() should always be the
start address of a resource:
  - iounmap() passes a page-aligned virtual address, while the original
    address was created by adding the in-page offset to the resource's
    start address,
  - sbus_free_coherent() and pci32_free_coherent() should be passed an
    address obtained from sbus_alloc_coherent() resp. pci32_alloc_coherent(),
    which is always a resource's start address.

Hence replace the range check by a check for an exact match.

Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Acked-by: David S. Miller <davem@davemloft.net>
12 years agom68k/amiga: Chip RAM - Offset resource end by CHIP_PHYSADDR
Geert Uytterhoeven [Sun, 22 May 2011 09:09:02 +0000 (11:09 +0200)]
m68k/amiga: Chip RAM - Offset resource end by CHIP_PHYSADDR

Technically, the end of Chip RAM should be offset by CHIP_PHYSADDR (which is
zero).

Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
12 years agom68k/amiga: Chip RAM - Use resource_size() to fix off-by-one error
Geert Uytterhoeven [Wed, 27 Apr 2011 08:28:19 +0000 (10:28 +0200)]
m68k/amiga: Chip RAM - Use resource_size() to fix off-by-one error

Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
12 years agom68k/amiga: Chip RAM - Change chipavail to an atomic_t
Geert Uytterhoeven [Sun, 24 Apr 2011 21:40:51 +0000 (23:40 +0200)]
m68k/amiga: Chip RAM - Change chipavail to an atomic_t

While the core resource handling code is safe, our global counter must
still be protected against concurrent modifications.

Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
12 years agom68k/amiga: Chip RAM - Always allocate from the start of memory
Geert Uytterhoeven [Sun, 24 Apr 2011 21:19:05 +0000 (23:19 +0200)]
m68k/amiga: Chip RAM - Always allocate from the start of memory

As of commit 5df1abdbd37af2ae317a1c5b5944173284dc55d6 ('m68k/amiga: Fix
"debug=mem"'), "debug=mem" no longer uses amiga_chip_alloc_res(), so we
can remove the hack to prefer memory at the safe end.

This allows to simplify the code and make amiga_chip_alloc() just call
amiga_chip_alloc_res() internally.

Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
12 years agom68k/amiga: Chip RAM - Convert from printk() to pr_*()
Geert Uytterhoeven [Sun, 24 Apr 2011 20:55:20 +0000 (22:55 +0200)]
m68k/amiga: Chip RAM - Convert from printk() to pr_*()

and fix a few formattings:
  - resource sizes are now resource_size_t, use %pR to make it future proof,
  - use %lu for unsigned long.

Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
12 years agom68k/amiga: Chip RAM - Use tabs for indentation
Geert Uytterhoeven [Sat, 21 May 2011 18:46:39 +0000 (20:46 +0200)]
m68k/amiga: Chip RAM - Use tabs for indentation

Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
12 years agoMerge branch 'hwmon-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/groec...
Linus Torvalds [Sat, 30 Jul 2011 18:57:57 +0000 (08:57 -1000)]
Merge branch 'hwmon-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/groeck/staging

* 'hwmon-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/groeck/staging: (24 commits)
  hwmon: (lm90) Refactor reading of config2 register
  hwmon: (lm90) Make SA56004 detection more robust
  hwmon: (lm90) Simplify handling of extended local temp register
  hwmon: (pmbus) Add client driver for LM25066, LM5064, and LM5066
  hwmon: (max34440) Add support for peak attributes
  hwmon: (max8688) Add support for peak attributes
  hwmon: (max16064) Add support for peak attributes
  hwmon: (adm1275) Add support for peak attributes
  hwmon: (pmbus) Add support for peak attributes
  hwmon: Add new attributes to sysfs ABI
  hwmon: (pmbus) Strengthen check for status register existence
  hwmon: (pmbus) Add support for virtual pages
  hwmon: (pmbus) Support reading and writing of word registers in device specific code
  hwmon: (pmbus) Increase attribute name size
  hwmon: (pmbus) Add ADP4000, NCP4200 and NCP4208 to list of supported devices
  hwmon: (pmbus) Add support for VID output voltage mode
  hwmon: (pmbus) Move PMBus drivers to drivers/hwmon/pmbus
  hwmon: (coretemp) Add core/pkg threshold support to Coretemp
  hwmon: (lm95241) Add support for LM95231
  hwmon: LM95245 driver
  ...

12 years agoshm: optimize locking and ipc_namespace getting
Vasiliy Kulikov [Thu, 28 Jul 2011 23:56:40 +0000 (03:56 +0400)]
shm: optimize locking and ipc_namespace getting

shm_lock() does a lookup of shm segment in shm_ids(ns).ipcs_idr, which
is redundant as we already know shmid_kernel address.  An actual lock is
also not required for reads until we really want to destroy the segment.

exit_shm() and shm_destroy_orphaned() may avoid the loop by checking
whether there is at least one segment in current ipc_namespace.

The check of nsproxy and ipc_ns against NULL is redundant as exit_shm()
is called from do_exit() before the call to exit_notify(), so the
dereferencing current->nsproxy->ipc_ns is guaranteed to be safe.

Reported-by: Oleg Nesterov <oleg@redhat.com>
Signed-off-by: Vasiliy Kulikov <segoon@openwall.com>
Acked-by: Serge Hallyn <serge.hallyn@canonical.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
12 years agoshm: handle separate PID namespaces case
Vasiliy Kulikov [Thu, 28 Jul 2011 23:55:31 +0000 (03:55 +0400)]
shm: handle separate PID namespaces case

shm_try_destroy_orphaned() and shm_try_destroy_current() didn't handle
the case of separate PID namespaces, but a single IPC namespace.  If
there are tasks with the same PID values using the same shmem object,
the wrong destroy decision could be reached.

On shm segment creation store the pointer to the creator task in
shmid_kernel->shm_creator field and zero it on task exit.  Then
use the ->shm_creator insread of shm_cprid in both functions.  As
shmid_kernel object is already locked at this stage, no additional
locking is needed.

Signed-off-by: Vasiliy Kulikov <segoon@openwall.com>
Acked-by: Serge Hallyn <serge.hallyn@canonical.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
12 years agoAdditional readdir cookie loop information
Bryan Schumaker [Fri, 29 Jul 2011 15:49:06 +0000 (11:49 -0400)]
Additional readdir cookie loop information

Print out the name of the file that triggers the cookie loop  message to
make it slightly easier to track down the cause.

Signed-off-by: Bryan Schumaker <bjschuma@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
12 years agoMerge git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi-misc-2.6
Linus Torvalds [Sat, 30 Jul 2011 18:36:02 +0000 (08:36 -1000)]
Merge git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi-misc-2.6

* git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi-misc-2.6: (71 commits)
  [SCSI] fcoe: cleanup cpu selection for incoming requests
  [SCSI] fcoe: add fip retry to avoid missing critical keep alive
  [SCSI] libfc: fix warn on in lport retry
  [SCSI] libfc: Remove the reference to FCP packet from scsi_cmnd in case of error
  [SCSI] libfc: cleanup sending SRR request
  [SCSI] libfc: two minor changes in comments
  [SCSI] libfc, fcoe: ignore rx frame with wrong xid info
  [SCSI] libfc: release exchg cache
  [SCSI] libfc: use FC_MAX_ERROR_CNT
  [SCSI] fcoe: remove unused ptype field in fcoe_rcv_info
  [SCSI] bnx2fc: Update copyright and bump version to 1.0.4
  [SCSI] bnx2fc: Tx BDs cache in write tasks
  [SCSI] bnx2fc: Do not arm CQ when there are no CQEs
  [SCSI] bnx2fc: hold tgt lock when calling cmd_release
  [SCSI] bnx2fc: Enable support for sequence level error recovery
  [SCSI] bnx2fc: HSI changes for tape
  [SCSI] bnx2fc: Handle REC_TOV error code from firmware
  [SCSI] bnx2fc: REC/SRR link service request and response handling
  [SCSI] bnx2fc: Support 'sequence cleanup' task
  [SCSI] dh_rdac: Associate HBA and storage in rdac_controller to support partitions in storage
  ...

12 years agoNFS: Fix spurious readdir cookie loop messages
Trond Myklebust [Sat, 30 Jul 2011 16:45:35 +0000 (12:45 -0400)]
NFS: Fix spurious readdir cookie loop messages

If the directory contents change, then we have to accept that the
file->f_pos value may shrink if we do a 'search-by-cookie'. In that
case, we should turn off the loop detection and let the NFS client
try to recover.

The patch also fixes a second loop detection bug by ensuring
that after turning on the ctx->duped flag, we read at least one new
cookie into ctx->dir_cookie before attempting to match with
ctx->dup_cookie.

Reported-by: Petr Vandrovec <petr@vandrovec.name>
Cc: stable@kernel.org [2.6.39+]
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
12 years agoMerge branch 'slub/lockless' of git://git.kernel.org/pub/scm/linux/kernel/git/penberg...
Linus Torvalds [Sat, 30 Jul 2011 18:21:48 +0000 (08:21 -1000)]
Merge branch 'slub/lockless' of git://git.kernel.org/pub/scm/linux/kernel/git/penberg/slab-2.6

* 'slub/lockless' of git://git.kernel.org/pub/scm/linux/kernel/git/penberg/slab-2.6: (21 commits)
  slub: When allocating a new slab also prep the first object
  slub: disable interrupts in cmpxchg_double_slab when falling back to pagelock
  Avoid duplicate _count variables in page_struct
  Revert "SLUB: Fix build breakage in linux/mm_types.h"
  SLUB: Fix build breakage in linux/mm_types.h
  slub: slabinfo update for cmpxchg handling
  slub: Not necessary to check for empty slab on load_freelist
  slub: fast release on full slab
  slub: Add statistics for the case that the current slab does not match the node
  slub: Get rid of the another_slab label
  slub: Avoid disabling interrupts in free slowpath
  slub: Disable interrupts in free_debug processing
  slub: Invert locking and avoid slab lock
  slub: Rework allocator fastpaths
  slub: Pass kmem_cache struct to lock and freeze slab
  slub: explicit list_lock taking
  slub: Add cmpxchg_double_slab()
  mm: Rearrange struct page
  slub: Move page->frozen handling near where the page->freelist handling occurs
  slub: Do not use frozen page flag but a bit in the page counters
  ...

12 years agoext4: add missing kfree() on error return path in add_new_gdb()
Dan Carpenter [Sat, 30 Jul 2011 16:58:41 +0000 (12:58 -0400)]
ext4: add missing kfree() on error return path in add_new_gdb()

We added some more error handling in b40971426a "ext4: add error
checking to calls to ext4_handle_dirty_metadata()".  But we need to
call kfree() as well to avoid a memory leak.

Signed-off-by: Dan Carpenter <error27@gmail.com>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
12 years agoext4: change umode_t in tracepoint headers to be an explicit __u16
Theodore Ts'o [Sat, 30 Jul 2011 16:38:46 +0000 (12:38 -0400)]
ext4: change umode_t in tracepoint headers to be an explicit __u16

As requested by Al Viro, since umode_t may be changing to a u32 for
some architectures.

Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
Cc: Al Viro <viro@ZenIV.linux.org.uk>
12 years agoext4: fix races in ext4_sync_parent()
Theodore Ts'o [Sat, 30 Jul 2011 16:34:19 +0000 (12:34 -0400)]
ext4: fix races in ext4_sync_parent()

Fix problems if fsync() races against a rename of a parent directory
as pointed out by Al Viro in his own inimitable way:

>While we are at it, could somebody please explain what the hell is ext4
>doing in
>static int ext4_sync_parent(struct inode *inode)
>{
>        struct writeback_control wbc;
>        struct dentry *dentry = NULL;
>        int ret = 0;
>
>        while (inode && ext4_test_inode_state(inode, EXT4_STATE_NEWENTRY)) {
>                ext4_clear_inode_state(inode, EXT4_STATE_NEWENTRY);
>                dentry = list_entry(inode->i_dentry.next,
>                                    struct dentry, d_alias);
>                if (!dentry || !dentry->d_parent || !dentry->d_parent->d_inode)
>                        break;
>                inode = dentry->d_parent->d_inode;
>                ret = sync_mapping_buffers(inode->i_mapping);
>                ...
>Note that dentry obviously can't be NULL there.  dentry->d_parent is never
>NULL.  And dentry->d_parent would better not be negative, for crying out
>loud!  What's worse, there's no guarantees that dentry->d_parent will
>remain our parent over that sync_mapping_buffers() *and* that inode won't
>just be freed under us (after rename() and memory pressure leading to
>eviction of what used to be our dentry->d_parent)......

Reported-by: Al Viro <viro@ZenIV.linux.org.uk>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
12 years agoMerge branch 'kconfig' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild-2.6
Linus Torvalds [Sat, 30 Jul 2011 07:17:06 +0000 (00:17 -0700)]
Merge branch 'kconfig' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild-2.6

* 'kconfig' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild-2.6: (25 commits)
  kconfig: Introduce IS_ENABLED(), IS_BUILTIN() and IS_MODULE()
  xconfig: Abort close if configuration cannot be saved
  kconfig: fix missing "0x" prefix from S_HEX symbol in autoconf.h
  kconfig/nconf: remove useless conditionnal
  kconfig/nconf: prevent segfault on empty menu
  kconfig/nconf: use the generic menu_get_ext_help()
  nconfig: Avoid Wunused-but-set warning
  kconfig/conf: mark xfgets() private
  kconfig: remove pending prototypes for kconfig_load()
  kconfig/conf: add command line options' description
  kconfig/conf: reduce the scope of `defconfig_file'
  kconfig: use calloc() for expr allocation
  kconfig: introduce specialized printer
  kconfig: do not overwrite symbol direct dependency in assignment
  kconfig/gconf: silent missing prototype warnings
  kconfig/gconf: kill deadcode
  kconfig: nuke LKC_DIRECT_LINK cruft
  kconfig: nuke reference to SWIG
  kconfig: add missing <stdlib.h> inclusion
  kconfig: add missing <ctype.h> inclusion
  ...

Fix up conflicts in scripts/kconfig/Makefile

12 years agoMerge branch 'v4l_for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab...
Linus Torvalds [Sat, 30 Jul 2011 07:08:53 +0000 (00:08 -0700)]
Merge branch 'v4l_for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-2.6

* 'v4l_for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-2.6: (430 commits)
  [media] ir-mce_kbd-decoder: include module.h for its facilities
  [media] ov5642: include module.h for its facilities
  [media] em28xx: Fix DVB-C maxsize for em2884
  [media] tda18271c2dd: Fix saw filter configuration for DVB-C @6MHz
  [media] v4l: mt9v032: Fix Bayer pattern
  [media] V4L: mt9m111: rewrite set_pixfmt
  [media] V4L: mt9m111: fix missing return value check mt9m111_reg_clear
  [media] V4L: initial driver for ov5642 CMOS sensor
  [media] V4L: sh_mobile_ceu_camera: fix Oops when USERPTR mapping fails
  [media] V4L: soc-camera: remove soc-camera bus and devices on it
  [media] V4L: soc-camera: un-export the soc-camera bus
  [media] V4L: sh_mobile_csi2: switch away from using the soc-camera bus notifier
  [media] V4L: add media bus configuration subdev operations
  [media] V4L: soc-camera: group struct field initialisations together
  [media] V4L: soc-camera: remove now unused soc-camera specific PM hooks
  [media] V4L: pxa-camera: switch to using standard PM hooks
  [media] NetUP Dual DVB-T/C CI RF: force card hardware revision by module param
  [media] Don't OOPS if videobuf_dvb_get_frontend return NULL
  [media] NetUP Dual DVB-T/C CI RF: load firmware according card revision
  [media] omap3isp: Support configurable HS/VS polarities
  ...

Fix up conflicts:
 - arch/arm/mach-omap2/board-rx51-peripherals.c:
     cleanup regulator supply definitions in mach-omap2
   vs
     OMAP3: RX-51: define vdds_csib regulator supply
 - drivers/staging/tm6000/tm6000-alsa.c (trivial)

12 years agoMerge branch 'for-linus' of git://oss.sgi.com/xfs/xfs
Linus Torvalds [Sat, 30 Jul 2011 06:45:06 +0000 (23:45 -0700)]
Merge branch 'for-linus' of git://oss.sgi.com/xfs/xfs

* 'for-linus' of git://oss.sgi.com/xfs/xfs:
  xfs: Fix build breakage in xfs_iops.c when CONFIG_FS_POSIX_ACL is not set

12 years agoMerge branch 'next' of git://git.kernel.org/pub/scm/linux/kernel/git/ecryptfs/ecryptf...
Linus Torvalds [Sat, 30 Jul 2011 06:43:50 +0000 (23:43 -0700)]
Merge branch 'next' of git://git.kernel.org/pub/scm/linux/kernel/git/ecryptfs/ecryptfs-2.6

* 'next' of git://git.kernel.org/pub/scm/linux/kernel/git/ecryptfs/ecryptfs-2.6:
  ecryptfs: Make inode bdi consistent with superblock bdi
  eCryptfs: Unlock keys needed by ecryptfsd

12 years agoMerge branch 'stable/bug.fixes' of git://git.kernel.org/pub/scm/linux/kernel/git...
Linus Torvalds [Sat, 30 Jul 2011 06:43:32 +0000 (23:43 -0700)]
Merge branch 'stable/bug.fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/konrad/xen

* 'stable/bug.fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/konrad/xen:
  xen/balloon: Fix compile errors - missing header files.
  xen/grant: Fix compile warning.
  xen/pciback: remove duplicated #include

12 years agofrv: remove unnecessary code
Greg Dietsche [Fri, 29 Jul 2011 15:46:16 +0000 (16:46 +0100)]
frv: remove unnecessary code

remove unnecessary code that matches this coccinelle pattern

if (...)
return ret;
return ret;

Signed-off-by: Greg Dietsche <Gregory.Dietsche@cuw.edu>
Signed-off-by: David Howells <dhowells@redhat.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
12 years agoramoops: fix compile failure on parisc
James Bottomley [Fri, 29 Jul 2011 13:11:32 +0000 (17:11 +0400)]
ramoops: fix compile failure on parisc

Fixes this:

  drivers/char/ramoops.c: In function 'ramoops_init':
  drivers/char/ramoops.c:221: error: implicit declaration of function 'IS_ERR'
  drivers/char/ramoops.c:222: error: implicit declaration of function 'PTR_ERR'

If it actually builds on other platforms, it's probably getting
linux/err.h via some other #include.

Signed-off-by: James Bottomley <JBottomley@Parallels.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
12 years agoMerge branch 'linux-next' of git://git.kernel.org/pub/scm/linux/kernel/git/jbarnes...
Linus Torvalds [Sat, 30 Jul 2011 06:35:05 +0000 (23:35 -0700)]
Merge branch 'linux-next' of git://git.kernel.org/pub/scm/linux/kernel/git/jbarnes/pci-2.6

* 'linux-next' of git://git.kernel.org/pub/scm/linux/kernel/git/jbarnes/pci-2.6:
  PCI: remove printks about disabled bridge windows
  PCI: fold pci_calc_resource_flags() into decode_bar()
  PCI: treat mem BAR type "11" (reserved) as 32-bit, not 64-bit, BAR
  PCI: correct pcie_set_readrq write size
  PCI: pciehp: change wait time for valid configuration access
  x86/PCI: Preserve existing pci=bfsort whitelist for Dell systems
  PCI: ARI is a PCIe v2 feature
  x86/PCI: quirks: Use pci_dev->revision
  PCI: Make the struct pci_dev * argument of pci_fixup_irqs const.
  PCI hotplug: cpqphp: use pci_dev->vendor
  PCI hotplug: cpqphp: use pci_dev->subsystem_{vendor|device}
  x86/PCI: config space accessor functions should not ignore the segment argument
  PCI: Assign values to 'pci_obff_signal_type' enumeration constants
  x86/PCI: reduce severity of host bridge window conflict warnings
  PCI: enumerate the PCI device only removed out PCI hieratchy of OS when re-scanning PCI
  PCI: PCIe AER: add aer_recover_queue
  x86/PCI: select direct access mode for mmconfig option
  PCI hotplug: Rename is_ejectable which also exists in dock.c

12 years agoMerge branch 'upstream/xen-tracing2' of git://git.kernel.org/pub/scm/linux/kernel...
Linus Torvalds [Sat, 30 Jul 2011 06:33:40 +0000 (23:33 -0700)]
Merge branch 'upstream/xen-tracing2' of git://git.kernel.org/pub/scm/linux/kernel/git/jeremy/xen

* 'upstream/xen-tracing2' of git://git.kernel.org/pub/scm/linux/kernel/git/jeremy/xen:
  xen/tracing: fix compile errors when tracing is disabled.

12 years agoMerge branch 'at91/cleanup' of git://git.kernel.org/pub/scm/linux/kernel/git/arm...
Linus Torvalds [Sat, 30 Jul 2011 06:32:53 +0000 (23:32 -0700)]
Merge branch 'at91/cleanup' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/linux-arm-soc

* 'at91/cleanup' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/linux-arm-soc:
  at91: add arch specific ioremap support
  at91: factorize sram init
  at91: move register clocks to soc generic init
  at91: move clock subsystem init to soc generic init
  at91: use structure to store the current soc
  at91: remove AT91_DBGU offset from dbgu register macro
  at91: factorize at91 interrupts init to soc
  at91: introduce commom AT91_BASE_SYS

12 years agoMerge branch 'next/dt' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/linux...
Linus Torvalds [Sat, 30 Jul 2011 06:32:02 +0000 (23:32 -0700)]
Merge branch 'next/dt' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/linux-arm-soc

* 'next/dt' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/linux-arm-soc: (21 commits)
  arm/dt: tegra devicetree support
  arm/versatile: Add device tree support
  dt/irq: add irq_domain_generate_simple() helper
  irq: add irq_domain translation infrastructure
  dmaengine: imx-sdma: add device tree probe support
  dmaengine: imx-sdma: sdma_get_firmware does not need to copy fw_name
  dmaengine: imx-sdma: use platform_device_id to identify sdma version
  mmc: sdhci-esdhc-imx: add device tree probe support
  mmc: sdhci-pltfm: dt device does not pass parent to sdhci_alloc_host
  mmc: sdhci-esdhc-imx: get rid of the uses of cpu_is_mx()
  mmc: sdhci-esdhc-imx: do not reference platform data after probe
  mmc: sdhci-esdhc-imx: extend card_detect and write_protect support for mx5
  net/fec: add device tree probe support
  net: ibm_newemac: convert it to use of_get_phy_mode
  dt/net: add helper function of_get_phy_mode
  net/fec: gasket needs to be enabled for some i.mx
  serial/imx: add device tree probe support
  serial/imx: get rid of the uses of cpu_is_mx1()
  arm/dt: Add dtb make rule
  arm/dt: Add skeleton dtsi file
  ...

12 years agoMerge branch 'fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/linux-arm-soc
Linus Torvalds [Sat, 30 Jul 2011 06:31:22 +0000 (23:31 -0700)]
Merge branch 'fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/linux-arm-soc

* 'fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/linux-arm-soc:
  ARM: zynq: remove incorrectly deleted file
  ARM: tegra: only select MACH_HAS_SND_SOC_TEGRA_WM8903 if SND_SOC

12 years agoMerge git://git.kernel.org/pub/scm/linux/kernel/git/wim/linux-watchdog
Linus Torvalds [Sat, 30 Jul 2011 06:28:47 +0000 (23:28 -0700)]
Merge git://git.kernel.org/pub/scm/linux/kernel/git/wim/linux-watchdog

* git://git.kernel.org/pub/scm/linux/kernel/git/wim/linux-watchdog: (25 commits)
  watchdog: WatchDog Timer Driver Core - Add minimum and max timeout
  watchdog: WatchDog Timer Driver Core - Add ioctl call
  watchdog: WatchDog Timer Driver Core - Add nowayout feature
  watchdog: WatchDog Timer Driver Core - Add Magic Close feature
  watchdog: WatchDog Timer Driver Core - Add WDIOC_SETTIMEOUT and WDIOC_GETTIMEOUT ioctl
  watchdog: WatchDog Timer Driver Core - Add WDIOC_SETOPTIONS ioctl
  watchdog: WatchDog Timer Driver Core - Add WDIOC_KEEPALIVE ioctl
  watchdog: WatchDog Timer Driver Core - Add basic ioctl functionality
  watchdog: WatchDog Timer Driver Core - Add basic framework
  watchdog: hpwdt: add next gen HP servers
  watchdog: it8712f_wdt.c: improve includes
  watchdog: at91sam9/wdt: move register header to drivers
  watchdog: Add Xilinx watchdog timer driver
  watchdog: remove empty pm-functions
  watchdog: sp805: Flush posted writes in enable/disable.
  watchdog: sp805: Don't write 0 to the load value register.
  watchdog: imx2_wdt: add device tree probe support
  watchdog: s3c2410: Add support for device tree based probe
  watchdog: mpcore_wdt: Add suspend/resume support.
  watchdog: mtx1-wdt: use dev_{err,info} instead of printk()
  ...

12 years agoext2: remove duplicate 'ext2_get_acl()' define
Linus Torvalds [Sat, 30 Jul 2011 06:21:50 +0000 (23:21 -0700)]
ext2: remove duplicate 'ext2_get_acl()' define

When commit 4e34e719e457 ("fs: take the ACL checks to common code")
changed the xyz_check_acl() functions into the more natural
xyz_get_acl() interface, we grew two copies of the

  #define ext2_get_acl NULL

define for the non-acl case.

Remove the extra one.

Reported-by: Marco Stornelli <marco.stornelli@gmail.com>
Cc: Christoph Hellwig <hch@lst.de>
Cc: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
12 years agokconfig: Introduce IS_ENABLED(), IS_BUILTIN() and IS_MODULE()
Michal Marek [Wed, 20 Jul 2011 15:38:57 +0000 (17:38 +0200)]
kconfig: Introduce IS_ENABLED(), IS_BUILTIN() and IS_MODULE()

Replace the config_is_*() macros with a variant that allows for grepping
for usage of CONFIG_* options in the code. Usage:

  if (IS_ENABLED(CONFIG_NUMA))

or

  #if IS_ENABLED(CONFIG_NUMA)

The IS_ENABLED() macro evaluates to 1 if the argument is set (to either 'y'
or 'm'), IS_BUILTIN() tests if the option is 'y' and IS_MODULE() test if
the option is 'm'. Only boolean and tristate options are supported.

Reviewed-by: Arnaud Lacombe <lacombar@gmail.com>
Acked-by: Randy Dunlap <rdunlap@xenotime.net>
Signed-off-by: Michal Marek <mmarek@suse.cz>
12 years agocpupower: Do detect IDA (opportunistic processor performance) via cpuid
Thomas Renninger [Thu, 21 Jul 2011 09:54:54 +0000 (11:54 +0200)]
cpupower: Do detect IDA (opportunistic processor performance) via cpuid

IA32-Intel Devel guide Volume 3A - 14.3.2.1
-------------------------------------------
...
Opportunistic processor performance operation can be disabled by setting bit 38 of
IA32_MISC_ENABLES. This mechanism is intended for BIOS only. If
IA32_MISC_ENABLES[38] is set, CPUID.06H:EAX[1] will return 0.

Better detect things via cpuid, this cleans up the code a bit
and the MSR parts were not working correctly anyway.

Signed-off-by: Thomas Renninger <trenn@suse.de>
CC: lenb@kernel.org
CC: linux@dominikbrodowski.net
CC: cpufreq@vger.kernel.org
Signed-off-by: Dominik Brodowski <linux@dominikbrodowski.net>