3.8.7-stable review
Subsystems (55)
Greg Kroah-Hartman
maintainercover 3.8.7-stable review
This is the start of the stable review cycle for the 3.8.7 release. There are 64 patches in this series, all will be posted as a response to this one. If anyone has any issues with these being applied, please let me know.
Responses should be made by Fri Apr 12 22:41:50 UTC 2013. Anything received after that time might be too late.
The whole patch series can be found in one patch at:
kernel.org/pub/linux/kernel/v3.0/stable-review/patch-3.8.7-rc1.gz
and the diffstat can be found below.
thanks,
greg k-h
-------------
Pseudo-Shortlog of commits:
Greg Kroah-Hartman <[email protected]>
Linux 3.8.7-rc1
Tim Gardner <[email protected]>
rt2x00: rt2x00pci_regbusy_read() - only print register access failure once
Bing Zhao <[email protected]>
mwifiex: complete last internal scan
Wei Yongjun <[email protected]>
can: gw: use kmem_cache_free() instead of kfree()
Trond Myklebust <[email protected]>
NFSv4: Doh! Typo in the fix to nfs41_walk_client_list
Alex Williamson <[email protected]>
vfio-pci: Fix possible integer overflow
hayeswang <[email protected]>
r8169: fix auto speed down issue
Jani Nikula <[email protected]>
drm/i915: add quirk to invert brightness on Packard Bell NCL20
Jani Nikula <[email protected]>
drm/i915: add quirk to invert brightness on eMachines e725
Jani Nikula <[email protected]>
drm/i915: add quirk to invert brightness on eMachines G725
Thomas Abraham <[email protected]>
ARM: EXYNOS: Fix crash on soft reset on EXYNOS5440
Jonghwan Choi <[email protected]>
cpufreq: exynos: Get booting freq value in exynos_cpufreq_init
Maxim Mikityanskiy <[email protected]>
msi-wmi: Fix memory leak
Richard Guy Briggs <[email protected]>
thermal: return an error on failure to register thermal class
Bjorn Helgaas <[email protected]>
Revert "PCI/ACPI: Request _OSC control before scanning PCI root bus"
Jan Beulich <[email protected]>
x86: Fix rebuild with EFI_STUB enabled
Lauri Kasanen <[email protected]>
drm/i915: Fix build failure
Trond Myklebust <[email protected]>
NFSv4/4.1: Fix bugs in nfs4[01]_walk_client_list
Trond Myklebust <[email protected]>
NFSv4: Fix a memory leak in nfs4_discover_server_trunking
Chuck Lever <[email protected]>
SUNRPC: Remove extra xprt_put()
Arnd Bergmann <[email protected]>
block: avoid using uninitialized value in from queue_var_store
Christopher Harvey <[email protected]>
drm/mgag200: Index 24 in extended CRTC registers is 24 in hex, not decimal.
Jussi Kivilinna <[email protected]>
crypto: gcm - fix assumption that assoc has one segment
Linus Walleij <[email protected]>
crypto: ux500 - add missing comma
Linus Torvalds <[email protected]>
spinlocks and preemption points need to be at least compiler barriers
Robert Tivy <[email protected]>
remoteproc: fix FW_CONFIG typo
Sjur Brændeland <[email protected]>
remoteproc: fix error path of handle_vdev
Dmitry Tarnyagin <[email protected]>
remoteproc/ste: fix memory leak on shutdown
Li Fei <[email protected]>
hwspinlock: fix __hwspin_lock_request error path
Paul Moore <[email protected]>
x86: remove the x32 syscall bitmask from syscall_get_nr()
Johannes Berg <[email protected]>
mac80211: fix remain-on-channel cancel crash
Stone Piao <[email protected]>
mwifiex: limit channel number not to overflow memory
Michael Wolf <[email protected]>
powerpc: pSeries_lpar_hpte_remove fails from Adjunct partition being performed before the ANDCOND test
Jan Kiszka <[email protected]>
ftrace: Consistently restore trace function on sysctl enabling
Youquan Song <[email protected]>
ata_piix: Fix DVD not dectected at some Haswell platforms
Rafael J. Wysocki <[email protected]>
PCI/PM: Disable runtime PM of PCIe ports
Rafael J. Wysocki <[email protected]>
PCI/ACPI: Always resume devices on ACPI wakeup notifications
Jay Estabrook <[email protected]>
alpha: Add irongate_io to PCI bus resources
David Daney <[email protected]>
MIPS: Unbreak function tracer for 64-bit kernel.
David Woodhouse <[email protected]>
libata: fix DMA to stack in reading devslp_timing parameters
Shan Hai <[email protected]>
libata: Set max sector to 65535 for Slimtype DVD A DS8A8SH drive
Shan Hai <[email protected]>
libata: Use integer return value for atapi_command_packet_set
Jakub Kicinski <[email protected]>
ixgbe: fix registration order of driver and DCA nofitication
Yinghai Lu <[email protected]>
EISA/PCI: Fix bus res reference
Yinghai Lu <[email protected]>
EISA/PCI: Init EISA early, before PNP
Jan Stancek <[email protected]>
mm: prevent mmap_cache race in find_vma()
Johan Hovold <[email protected]>
Revert "drivers/rtc/rtc-at91rm9200.c: use a variable for storing IMR"
Ilija Hadzic <[email protected]>
drm: correctly restore mappings if drm_open fails
Adam Jackson <[email protected]>
drm/i915: Be sure to turn hsync/vsync back on at crt enable (v2)
Maarten Lankhorst <[email protected]>
drm/nouveau: fix handling empty channel list in ioctl's
David Henningsson <[email protected]>
ALSA: hda - fix typo in proc output
Rainer Koenig <[email protected]>
ALSA: hda - Enabling Realtek ALC 671 codec
Mengdong Lin <[email protected]>
ALSA: hda - bug fix on return value when getting HDMI ELD info
Jan Kara <[email protected]>
reiserfs: Fix warning and inode leak when deleting inode with xattrs
Artem Bityutskiy <[email protected]>
UBIFS: make space fixup work in the remount case
Gabriel Fernandez <[email protected]>
gpio: stmpe: pass DT node to irqdomain
Anatolij Gustschin <[email protected]>
spi/mpc512x-psc: optionally keep PSC SS asserted across xfer segmensts
Girish K S <[email protected]>
spi/s3c64xx: modified error interrupt handling and init
Benjamin Tissoires <[email protected]>
HID: magicmouse: fix race between input_register() and probe()
David Daney <[email protected]>
MIPS: Fix logic errors in bitops.c
Lars-Peter Clausen <[email protected]>
regmap: cache Fix regcache-rbtree sync
Dimitris Papastamos <[email protected]>
regmap: Initialize `map->debugfs' before regcache
Lars-Peter Clausen <[email protected]>
ASoC: spear_pcm: Update to new pcm_new() API
Lars-Peter Clausen <[email protected]>
ASoC: dma-sh7760: Fix compile error
Sascha Hauer <[email protected]>
ASoC: imx-ssi: Fix occasional AC97 reset failure
-------------
Diffstat:
Makefile | 4 +- arch/alpha/kernel/sys_nautilus.c | 5 ++ arch/arm/mach-exynos/common.c | 6 +- arch/mips/kernel/mcount.S | 11 ++- arch/mips/lib/bitops.c | 16 ++-- arch/powerpc/platforms/pseries/lpar.c | 8 +- arch/x86/boot/compressed/Makefile | 5 +- arch/x86/include/asm/syscall.h | 4 +- block/blk-sysfs.c | 2 + crypto/gcm.c | 17 +++- drivers/acpi/pci_root.c | 121 +++++++++++++------------- drivers/ata/ata_piix.c | 14 ++- drivers/ata/libata-core.c | 6 +- drivers/base/regmap/regcache-rbtree.c | 2 +- drivers/base/regmap/regmap.c | 4 +- drivers/cpufreq/exynos-cpufreq.c | 4 +- drivers/crypto/ux500/cryp/cryp_core.c | 2 +- drivers/eisa/pci_eisa.c | 67 +++++++++----- drivers/gpio/gpio-stmpe.c | 15 +++- drivers/gpu/drm/drm_fops.c | 6 +- drivers/gpu/drm/i915/i915_gem_execbuffer.c | 2 +- drivers/gpu/drm/i915/intel_crt.c | 40 ++++----- drivers/gpu/drm/i915/intel_display.c | 9 ++ drivers/gpu/drm/mgag200/mgag200_mode.c | 13 +-- drivers/gpu/drm/nouveau/nouveau_abi16.c | 18 ++-- drivers/hid/hid-magicmouse.c | 29 ++++-- drivers/hwspinlock/hwspinlock_core.c | 2 + drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 11 ++- drivers/net/ethernet/realtek/r8169.c | 28 +++++- drivers/net/wireless/mwifiex/cfg80211.c | 3 +- drivers/net/wireless/mwifiex/scan.c | 11 ++- drivers/net/wireless/rt2x00/rt2x00pci.c | 4 +- drivers/pci/pci-acpi.c | 15 ++-- drivers/pci/pcie/portdrv_pci.c | 13 --- drivers/platform/x86/msi-wmi.c | 4 +- drivers/remoteproc/Kconfig | 2 +- drivers/remoteproc/remoteproc_core.c | 4 +- drivers/remoteproc/ste_modem_rproc.c | 7 +- drivers/rtc/rtc-at91rm9200.c | 50 ++++------- drivers/rtc/rtc-at91rm9200.h | 1 + drivers/spi/spi-mpc512x-psc.c | 2 +- drivers/spi/spi-s3c64xx.c | 41 +++++---- drivers/thermal/thermal_sys.c | 1 + drivers/vfio/pci/vfio_pci.c | 3 +- fs/nfs/nfs4client.c | 45 ++++++---- fs/nfs/nfs4state.c | 8 +- fs/reiserfs/xattr.c | 4 +- fs/ubifs/super.c | 12 +-- include/linux/ata.h | 2 +- include/linux/libata.h | 1 + include/linux/preempt.h | 22 +++-- include/linux/spinlock_up.h | 29 +++--- kernel/trace/ftrace.c | 8 +- mm/mmap.c | 2 +- mm/nommu.c | 2 +- net/can/gw.c | 6 +- net/mac80211/cfg.c | 6 +- net/mac80211/ieee80211_i.h | 3 +- net/mac80211/offchannel.c | 23 +++-- net/sunrpc/clnt.c | 4 +- sound/pci/hda/hda_codec.c | 2 +- sound/pci/hda/hda_eld.c | 2 +- sound/pci/hda/patch_realtek.c | 4 +- sound/soc/fsl/imx-ssi.c | 5 ++ sound/soc/sh/dma-sh7760.c | 4 +- sound/soc/spear/spear_pcm.c | 12 +-- 66 files changed, 503 insertions(+), 335 deletions(-)
Greg Kroah-Hartman
maintainerPATCH 1/64 ASoC: imx-ssi: Fix occasional AC97 reset failure
3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Sascha Hauer <[email protected]>
commit b6e51600f4e983e757b1b6942becaa1ae7d82e67 upstream.
--- sound/soc/fsl/imx-ssi.c | 5 +++++ 1 file changed, 5 insertions(+)
sound/soc/fsl/imx-ssi.c +5 -0
@@ -496,6 +496,8 @@ static void imx_ssi_ac97_reset(struct snif (imx_ssi->ac97_reset) imx_ssi->ac97_reset (ac97); +/* First read sometimes fails, do a dummy read */ +imx_ssi_ac97_read (ac97,0 ); }static void imx_ssi_ac97_warm_reset (struct snd_ac97 *ac97)
@@ -504,6 +506,9 @@ static void imx_ssi_ac97_warm_reset(struif (imx_ssi->ac97_warm_reset) imx_ssi->ac97_warm_reset (ac97); + +/* First read sometimes fails, do a dummy read */ +imx_ssi_ac97_read (ac97,0 ); }struct snd_ac97_bus_ops soc_ac97_ops = {
Greg Kroah-Hartman
maintainerPATCH 2/64 ASoC: dma-sh7760: Fix compile error
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Lars-Peter Clausen <[email protected]>
commit 417a1178f1bf3cdc606376b3ded3a22489fbb3eb upstream.
The dma-sh7760 currently fails with the following compile error:
sound/soc/sh/dma-sh7760.c:346:2: error: unknown field 'pcm_ops' specified in initializer sound/soc/sh/dma-sh7760.c:346:2: warning: initialization from incompatible pointer type sound/soc/sh/dma-sh7760.c:347:2: error: unknown field 'pcm_new' specified in initializer sound/soc/sh/dma-sh7760.c:347:2: warning: initialization makes integer from pointer without a cast sound/soc/sh/dma-sh7760.c:348:2: error: unknown field 'pcm_free' specified in initializer sound/soc/sh/dma-sh7760.c:348:2: warning: initialization from incompatible pointer type sound/soc/sh/dma-sh7760.c: In function 'sh7760_soc_platform_probe':
sound/soc/sh/dma-sh7760.c:353:2: warning: passing argument 2 of 'snd_soc_register_platform' from incompatible pointer type include/sound/soc.h:368:5: note: expected 'struct snd_soc_platform_driver *' but argument is of type 'struct snd_soc_platform *'
This is due the misnaming of the snd_soc_platform_driver type name and 'ops' field. The issue was introduced in commit f0fba2a("ASoC: multi-component - ASoC Multi-Component Support").
--- sound/soc/sh/dma-sh7760.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
sound/soc/sh/dma-sh7760.c +2 -2
@@ -342,8 +342,8 @@ static int camelot_pcm_new(struct snd_soreturn 0 ; } -static struct snd_soc_platform sh7760_soc_platform = { - .pcm_ops = &camelot_pcm_ops, +static struct snd_soc_platform_driver sh7760_soc_platform = { + .ops = &camelot_pcm_ops, .pcm_new = camelot_pcm_new, .pcm_free = camelot_pcm_free, };
Greg Kroah-Hartman
maintainerPATCH 3/64 ASoC: spear_pcm: Update to new pcm_new() API
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Lars-Peter Clausen <[email protected]>
commit 59d9cc2a5073ab4b8c8f8bdbacf230a538abc55d upstream.
Commit 552d1ef6 ("ASoC: core - Optimise and refactor pcm_new() to pass only rtd") updated the pcm_new() callback to take the rtd as the only parameter. The spear PCM driver (which was merged much later) still uses the old API. This patch updates the driver to the new API.
--- sound/soc/spear/spear_pcm.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-)
sound/soc/spear/spear_pcm.c +6 -6
@@ -149,9 +149,9 @@ static void spear_pcm_free(struct snd_pcstatic u64 spear_pcm_dmamask =DMA_BIT_MASK (32 ); -static int spear_pcm_new (struct snd_card *card, -struct snd_soc_dai *dai,struct snd_pcm *pcm) +static int spear_pcm_new (struct snd_soc_pcm_runtime *rtd) { +struct snd_card *card = rtd->card->snd_card;int ret;if (!card->dev->dma_mask)
@@ -159,16 +159,16 @@ static int spear_pcm_new(struct snd_cardif (!card->dev->coherent_dma_mask) card->dev->coherent_dma_mask =DMA_BIT_MASK (32 ); -if (dai->driver->playback.channels_min) { - ret =spear_pcm_preallocate_dma_buffer (pcm, +if (rtd->cpu_dai->driver->playback.channels_min) { + ret =spear_pcm_preallocate_dma_buffer (rtd->pcm,SNDRV_PCM_STREAM_PLAYBACK , spear_pcm_hardware.buffer_bytes_max);if (ret)return ret; } -if (dai->driver->capture.channels_min) { - ret =spear_pcm_preallocate_dma_buffer (pcm, +if (rtd->cpu_dai->driver->capture.channels_min) { + ret =spear_pcm_preallocate_dma_buffer (rtd->pcm,SNDRV_PCM_STREAM_CAPTURE , spear_pcm_hardware.buffer_bytes_max);if (ret)
Greg Kroah-Hartman
maintainerPATCH 4/64 regmap: Initialize `map->debugfs before regcache
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Dimitris Papastamos <[email protected]>
commit c6432ea9cc043994d5b7dcb3ad86a087777cb40c upstream.
In the rbtree code we are exposing statistics relating to the number of nodes/registers of the rbtree cache for each of the devices. Ensure that `map->debugfs' has been initialized before we attempt to initialize the debugfs entry for the rbtree cache.
--- drivers/base/regmap/regmap.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/base/regmap/regmap.c +2 -2
@@ -662,12 +662,12 @@ struct regmap *regmap_init(struct device } } +regmap_debugfs_init (map, config->name); + ret =regcache_init (map, config);if (ret !=0 ) goto err_range; -regmap_debugfs_init (map, config->name); -/* Add a devres resource for dev_get_regmap() */ m =devres_alloc (dev_get_regmap_release,sizeof (*m),GFP_KERNEL );if (!m) {
Greg Kroah-Hartman
maintainerPATCH 5/64 regmap: cache Fix regcache-rbtree sync
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Lars-Peter Clausen <[email protected]>
commit 8abac3ba51b5525354e9b2ec0eed1c9e95c905d9 upstream.
The last register block, which falls into the specified range, is not handled correctly. The formula which calculates the number of register which should be synced is inverse (and off by one). E.g. if all registers in that block should be synced only one is synced, and if only one should be synced all (but one) are synced. To calculate the number of registers that need to be synced we need to subtract the number of the first register in the block from the max register number and add one. This patch updates the code accordingly.
The issue was introduced in commit ac8d91c ("regmap: Supply ranges to the sync operations").
--- drivers/base/regmap/regcache-rbtree.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/base/regmap/regcache-rbtree.c +1 -1
@@ -398,7 +398,7 @@ static int regcache_rbtree_sync(struct r base =0 ;if (max < rbnode->base_reg + rbnode->blklen) - end = rbnode->base_reg + rbnode->blklen - max; + end = max - rbnode->base_reg +1 ;else end = rbnode->blklen;
Greg Kroah-Hartman
maintainerPATCH 6/64 MIPS: Fix logic errors in bitops.c
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: David Daney <[email protected]>
commit 0c81157b46c533139d6be721d41617020c59a2c3 upstream.
commit 92d11594f6 (MIPS: Remove irqflags.h dependency from bitops.h) factored some of the bitops code out into a separate file (arch/mips/lib/bitops.c). Unfortunately the logic converting a bit mask into a boolean result was lost in some of the functions. We had:
int res; unsigned long shifted_result_bit; . . . res = shifted_result_bit; return res;
Which truncates off the high 32 bits (thus yielding an incorrect value) on 64-bit systems.
The manifestation of this is that a non-SMP 64-bit kernel will not boot as the bitmap operations in bootmem.c are all screwed up.
Patchwork: https://patchwork.linux-mips.org/patch/4965/
--- arch/mips/lib/bitops.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-)
arch/mips/lib/bitops.c +8 -8
@@ -90,12 +90,12 @@ int __mips_test_and_set_bit(unsigned lonunsigned bit = nr &SZLONG_MASK ;unsigned long mask;unsigned long flags; -unsigned long res; +int res; a += nr >>SZLONG_LOG ; mask =1UL << bit;raw_local_irq_save (flags); - res = (mask & *a); + res = (mask & *a) !=0 ; *a |= mask;raw_local_irq_restore (flags);return res;
@@ -116,12 +116,12 @@ int __mips_test_and_set_bit_lock(unsigneunsigned bit = nr &SZLONG_MASK ;unsigned long mask;unsigned long flags; -unsigned long res; +int res; a += nr >>SZLONG_LOG ; mask =1UL << bit;raw_local_irq_save (flags); - res = (mask & *a); + res = (mask & *a) !=0 ; *a |= mask;raw_local_irq_restore (flags);return res;
@@ -141,12 +141,12 @@ int __mips_test_and_clear_bit(unsigned lunsigned bit = nr &SZLONG_MASK ;unsigned long mask;unsigned long flags; -unsigned long res; +int res; a += nr >>SZLONG_LOG ; mask =1UL << bit;raw_local_irq_save (flags); - res = (mask & *a); + res = (mask & *a) !=0 ; *a &= ~mask;raw_local_irq_restore (flags);return res;
@@ -166,12 +166,12 @@ int __mips_test_and_change_bit(unsignedunsigned bit = nr &SZLONG_MASK ;unsigned long mask;unsigned long flags; -unsigned long res; +int res; a += nr >>SZLONG_LOG ; mask =1UL << bit;raw_local_irq_save (flags); - res = (mask & *a); + res = (mask & *a) !=0 ; *a ^= mask;raw_local_irq_restore (flags);return res;
Greg Kroah-Hartman
maintainerPATCH 7/64 HID: magicmouse: fix race between input_register() and probe()
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Benjamin Tissoires <[email protected]>
commit f1a9a149abc86903e81dd1b2e720f3f89874384b upstream.
Since kernel 3.7, it appears that the input registration occured before the end of magicmouse_setup_input(). This is shown by receiving a lot of "EV_SYN SYN_REPORT 1" instead of normal "EV_SYN SYN_REPORT 0". This value means that the output buffer is full, and the user space is loosing events.
Using .input_configured guarantees that the race is not occuring, and that the call of "input_set_events_per_packet(input, 60)" is taken into account by input_register().
Fixes:
https://bugzilla.redhat.com/show_bug.cgi?id=908604
--- drivers/hid/hid-magicmouse.c | 29 ++++++++++++++++++++--------- 1 file changed, 20 insertions(+), 9 deletions(-)
drivers/hid/hid-magicmouse.c +20 -9
@@ -462,6 +462,21 @@ static int magicmouse_input_mapping(strureturn 0 ; } +static void magicmouse_input_configured (struct hid_device *hdev, +struct hid_input *hi) + +{ +struct magicmouse_sc *msc =hid_get_drvdata (hdev); + +int ret =magicmouse_setup_input (msc->input, hdev); +if (ret) { +hid_err (hdev,"magicmouse setup input failed (%d)\n" , ret); +/* clean msc->input to notify probe() of the failure */ + msc->input =NULL ; + } +} + +static int magicmouse_probe (struct hid_device *hdev,const struct hid_device_id *id) {
@@ -493,15 +508,10 @@ static int magicmouse_probe(struct hid_d goto err_free; } -/* We do this after hid-input is done parsing reports so that -* hid-input uses the most natural button and axis IDs. -*/ -if (msc->input) { - ret =magicmouse_setup_input (msc->input, hdev); -if (ret) { -hid_err (hdev,"magicmouse setup input failed (%d)\n" , ret); - goto err_stop_hw; - } +if (!msc->input) { +hid_err (hdev,"magicmouse input not registered\n" ); + ret = -ENOMEM ; + goto err_stop_hw; }if (id->product ==USB_DEVICE_ID_APPLE_MAGICMOUSE )
@@ -568,6 +578,7 @@ static struct hid_driver magicmouse_driv .remove = magicmouse_remove, .raw_event = magicmouse_raw_event, .input_mapping = magicmouse_input_mapping, + .input_configured = magicmouse_input_configured, };static int __init magicmouse_init (void )
Greg Kroah-Hartman
maintainerPATCH 8/64 spi/s3c64xx: modified error interrupt handling and init
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Girish K S <[email protected]>
commit 375981f2e14868be16cafbffd34a4f16a6ee01c6 upstream.
The status of the interrupt is available in the status register, so reading the clear pending register and writing back the same value will not actually clear the pending interrupts. This patch modifies the interrupt handler to read the status register and clear the corresponding pending bit in the clear pending register.
Modified the hwInit function to clear all the pending interrupts.
--- drivers/spi/spi-s3c64xx.c | 41 +++++++++++++++++++++++++---------------- 1 file changed, 25 insertions(+), 16 deletions(-)
drivers/spi/spi-s3c64xx.c +25 -16
@@ -997,25 +997,30 @@ static irqreturn_t s3c64xx_spi_irq(int i {struct s3c64xx_spi_driver_data *sdd = data;struct spi_master *spi = sdd->master; -unsigned int val; - - val =readl (sdd->regs +S3C64XX_SPI_PENDING_CLR ); - - val &=S3C64XX_SPI_PND_RX_OVERRUN_CLR | -S3C64XX_SPI_PND_RX_UNDERRUN_CLR | -S3C64XX_SPI_PND_TX_OVERRUN_CLR | -S3C64XX_SPI_PND_TX_UNDERRUN_CLR ; +unsigned int val, clr =0 ; -writel (val, sdd->regs +S3C64XX_SPI_PENDING_CLR ); + val =readl (sdd->regs +S3C64XX_SPI_STATUS ); -if (val &S3C64XX_SPI_PND_RX_OVERRUN_CLR ) +if (val &S3C64XX_SPI_ST_RX_OVERRUN_ERR ) { + clr =S3C64XX_SPI_PND_RX_OVERRUN_CLR ;dev_err (&spi->dev,"RX overrun\n" ); -if (val &S3C64XX_SPI_PND_RX_UNDERRUN_CLR ) + } +if (val &S3C64XX_SPI_ST_RX_UNDERRUN_ERR ) { + clr |=S3C64XX_SPI_PND_RX_UNDERRUN_CLR ;dev_err (&spi->dev,"RX underrun\n" ); -if (val &S3C64XX_SPI_PND_TX_OVERRUN_CLR ) + } +if (val &S3C64XX_SPI_ST_TX_OVERRUN_ERR ) { + clr |=S3C64XX_SPI_PND_TX_OVERRUN_CLR ;dev_err (&spi->dev,"TX overrun\n" ); -if (val &S3C64XX_SPI_PND_TX_UNDERRUN_CLR ) + } +if (val &S3C64XX_SPI_ST_TX_UNDERRUN_ERR ) { + clr |=S3C64XX_SPI_PND_TX_UNDERRUN_CLR ;dev_err (&spi->dev,"TX underrun\n" ); + } + +/* Clear the pending irq by setting and then clearing it */ +writel (clr, sdd->regs +S3C64XX_SPI_PENDING_CLR ); +writel (0 , sdd->regs +S3C64XX_SPI_PENDING_CLR );return IRQ_HANDLED ; }
@@ -1039,9 +1044,13 @@ static void s3c64xx_spi_hwinit(struct s3writel (0 , regs +S3C64XX_SPI_MODE_CFG );writel (0 , regs +S3C64XX_SPI_PACKET_CNT ); -/* Clear any irq pending bits */ -writel (readl (regs +S3C64XX_SPI_PENDING_CLR ), - regs +S3C64XX_SPI_PENDING_CLR ); +/* Clear any irq pending bits, should set and clear the bits */ + val =S3C64XX_SPI_PND_RX_OVERRUN_CLR | +S3C64XX_SPI_PND_RX_UNDERRUN_CLR | +S3C64XX_SPI_PND_TX_OVERRUN_CLR | +S3C64XX_SPI_PND_TX_UNDERRUN_CLR ; +writel (val, regs +S3C64XX_SPI_PENDING_CLR ); +writel (0 , regs +S3C64XX_SPI_PENDING_CLR );writel (0 , regs +S3C64XX_SPI_SWAP_CFG );
Greg Kroah-Hartman
maintainerPATCH 9/64 spi/mpc512x-psc: optionally keep PSC SS asserted across xfer segmensts
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Anatolij Gustschin <[email protected]>
commit 1ad849aee5f53353ed88d9cd3d68a51b03a7d44f upstream.
Some SPI slave devices require asserted chip select signal across multiple transfer segments of an SPI message. Currently the driver always de-asserts the internal SS signal for every single transfer segment of the message and ignores the 'cs_change' flag of the transfer description. Disable the internal chip select (SS) only if this is needed and indicated by the 'cs_change' flag.
Without this change, each partial transfer of a surrounding multi-part SPI transaction might erroneously change the SS signal, which might prevent slaves from answering the request that was sent in a previous transfer segment because the transaction could be considered aborted (SS was de-asserted before reading the response).
--- drivers/spi/spi-mpc512x-psc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/spi/spi-mpc512x-psc.c +1 -1
@@ -164,7 +164,7 @@ static int mpc512x_psc_spi_transfer_rxtxfor (i = count; i >0 ; i--) { data = tx_buf ? *tx_buf++ :0 ; -if (len ==EOFBYTE ) +if (len ==EOFBYTE && t->cs_change)setbits32 (&fifo->txcmd, MPC512x_PSC_FIFO_EOF);out_8 (&fifo->txdata_8, data); len--;
Greg Kroah-Hartman
maintainerPATCH 10/64 gpio: stmpe: pass DT node to irqdomain
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Gabriel Fernandez <[email protected]>
commit 9afd9b7090225d78ef56423a2ff65354dc38f1b1 upstream.
The irq domain was implemented but the device tree node was not transmitted to irq_domain_add_simple().
--- drivers/gpio/gpio-stmpe.c | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-)
drivers/gpio/gpio-stmpe.c +11 -4
@@ -307,11 +307,15 @@ static const struct irq_domain_ops stmpe .xlate = irq_domain_xlate_twocell, }; -static int stmpe_gpio_irq_init (struct stmpe_gpio *stmpe_gpio) +static int stmpe_gpio_irq_init (struct stmpe_gpio *stmpe_gpio, +struct device_node *np) { -int base = stmpe_gpio->irq_base; +int base =0 ; - stmpe_gpio->domain =irq_domain_add_simple (NULL , +if (!np) + base = stmpe_gpio->irq_base; + + stmpe_gpio->domain =irq_domain_add_simple (np, stmpe_gpio->chip.ngpio, base, &stmpe_gpio_irq_simple_ops, stmpe_gpio);if (!stmpe_gpio->domain) {
@@ -346,6 +350,9 @@ static int stmpe_gpio_probe(struct platf stmpe_gpio->chip = template_chip; stmpe_gpio->chip.ngpio = stmpe->num_gpios; stmpe_gpio->chip.dev = &pdev->dev; +#ifdef CONFIG_OF + stmpe_gpio->chip.of_node = np; +#endif stmpe_gpio->chip.base = pdata ? pdata->gpio_base :-1 ;if (pdata)
@@ -366,7 +373,7 @@ static int stmpe_gpio_probe(struct platf goto out_free;if (irq >=0 ) { - ret =stmpe_gpio_irq_init (stmpe_gpio); + ret =stmpe_gpio_irq_init (stmpe_gpio, np);if (ret) goto out_disable;
Greg Kroah-Hartman
maintainerPATCH 11/64 UBIFS: make space fixup work in the remount case
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Artem Bityutskiy <[email protected]>
commit 67e753ca41782913d805ff4a8a2b0f60b26b7915 upstream.
The UBIFS space fixup is a useful feature which allows to fixup the "broken" flash space at the time of the first mount. The "broken" space is usually the result of using a "dumb" industrial flasher which is not able to skip empty NAND pages and just writes all 0xFFs to the empty space, which has grave side-effects for UBIFS when UBIFS trise to write useful data to those empty pages.
The fix-up feature works roughly like this:
1. mkfs.ubifs sets the fixup flag in UBIFS superblock when creating the image (see -F option)
2. when the file-system is mounted for the first time, UBIFS notices the fixup flag and re-writes the entire media atomically, which may take really a lot of time.
3. UBIFS clears the fixup flag in the superblock.
This works fine when the file system is mounted R/W for the very first time. But it did not really work in the case when we first mount the file-system R/O, and then re-mount R/W. The reason was that we started the fixup procedure too late, which we cannot really do because we have to fixup the space before it starts being used.
--- fs/ubifs/super.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-)
fs/ubifs/super.c +6 -6
@@ -1568,6 +1568,12 @@ static int ubifs_remount_rw(struct ubifs c->remounting_rw =1 ; c->ro_mount =0 ; +if (c->space_fixup) { + err =ubifs_fixup_free_space (c); +if (err) +return err; + } + err =check_free_space (c);if (err) goto out;
@@ -1684,12 +1690,6 @@ static int ubifs_remount_rw(struct ubifs err =dbg_check_space_info (c); } -if (c->space_fixup) { - err =ubifs_fixup_free_space (c); -if (err) - goto out; - } -mutex_unlock (&c->umount_mutex);return err;
Greg Kroah-Hartman
maintainerPATCH 12/64 reiserfs: Fix warning and inode leak when deleting inode with xattrs
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Jan Kara <[email protected]>
commit 35e5cbc0af240778e61113286c019837e06aeec6 upstream.
After commit 21d8a15a (lookup_one_len: don't accept . and ..) reiserfs started failing to delete xattrs from inode. This was due to a buggy test for '.' and '..' in fill_with_dentries() which resulted in passing '.' and '..' entries to lookup_one_len() in some cases. That returned error and so we failed to iterate over all xattrs of and inode.
Fix the test in fill_with_dentries() along the lines of the one in lookup_one_len().
--- fs/reiserfs/xattr.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
fs/reiserfs/xattr.c +2 -2
@@ -187,8 +187,8 @@ fill_with_dentries(void *buf, const charif (dbuf->count ==ARRAY_SIZE (dbuf->dentries))return -ENOSPC ; -if (name[0 ] =='.' && (name[1 ] =='\0' || - (name[1 ] =='.' && name[2 ] =='\0' ))) +if (name[0 ] =='.' && (namelen <2 || + (namelen ==2 && name[1 ] =='.' )))return 0 ; dentry =lookup_one_len (name, dbuf->xadir, namelen);
Greg Kroah-Hartman
maintainerPATCH 13/64 ALSA: hda - bug fix on return value when getting HDMI ELD info
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Mengdong Lin <[email protected]>
commit 2ef5692efad330b67a234e2c49edad38538751e7 upstream.
In function snd_hdmi_get_eld(), the variable 'ret' should be initialized to 0. Otherwise it will be returned uninitialized as non-zero after ELD info is got successfully. Thus hdmi_present_sense() will always assume ELD info is invalid by mistake, and /proc file system cannot show the proper ELD info.
--- sound/pci/hda/hda_eld.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
sound/pci/hda/hda_eld.c +1 -1
@@ -322,7 +322,7 @@ int snd_hdmi_get_eld(struct hdmi_eld *el struct hda_codec *codec, hda_nid_t nid) { int i; -int ret; +int ret =0 ;int size;unsigned char *buf;
Greg Kroah-Hartman
maintainerPATCH 14/64 ALSA: hda - Enabling Realtek ALC 671 codec
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Rainer Koenig <[email protected]>
commit 1d87caa69c04008e09f5ff47b5e6acb6116febc7 upstream.
* Added the device ID to the modalias list and assinged ALC662 patches for it
* Added 4 port support for the device ID 0671 in alc662_parse_auto_config
--- sound/pci/hda/patch_realtek.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
sound/pci/hda/patch_realtek.c +3 -1
@@ -6720,7 +6720,8 @@ static int alc662_parse_auto_config(struconst hda_nid_t *ssids;if (codec->vendor_id ==0x10ec0272 || codec->vendor_id ==0x10ec0663 || - codec->vendor_id ==0x10ec0665 || codec->vendor_id ==0x10ec0670 ) + codec->vendor_id ==0x10ec0665 || codec->vendor_id ==0x10ec0670 || + codec->vendor_id ==0x10ec0671 ) ssids = alc663_ssids;else ssids = alc662_ssids;
@@ -7173,6 +7174,7 @@ static const struct hda_codec_preset snd { .id = 0x10ec0665, .name = "ALC665", .patch = patch_alc662 }, { .id = 0x10ec0668, .name = "ALC668", .patch = patch_alc662 }, { .id = 0x10ec0670, .name = "ALC670", .patch = patch_alc662 }, + { .id = 0x10ec0671, .name = "ALC671", .patch = patch_alc662 }, { .id = 0x10ec0680, .name = "ALC680", .patch = patch_alc680 }, { .id = 0x10ec0880, .name = "ALC880", .patch = patch_alc880 }, { .id = 0x10ec0882, .name = "ALC882", .patch = patch_alc882 },
Greg Kroah-Hartman
maintainerPATCH 15/64 ALSA: hda - fix typo in proc output
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: David Henningsson <[email protected]>
commit aeb3a97222832e5457c4b72d72235098ce4bfe8d upstream.
Rename "Digitial In" to "Digital In". This function is only used for proc output, so should not cause any problems to change.
--- sound/pci/hda/hda_codec.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
sound/pci/hda/hda_codec.c +1 -1
@@ -173,7 +173,7 @@ const char *snd_hda_get_jack_type(u32 cf"Line Out" ,"Speaker" ,"HP Out" ,"CD" ,"SPDIF Out" ,"Digital Out" ,"Modem Line" ,"Modem Hand" ,"Line In" ,"Aux" ,"Mic" ,"Telephony" , -"SPDIF In" ,"Digitial In" ,"Reserved" ,"Other" +"SPDIF In" ,"Digital In" ,"Reserved" ,"Other" }; return jack_types[(cfg & AC_DEFCFG_DEVICE)
Greg Kroah-Hartman
maintainerPATCH 16/64 drm/nouveau: fix handling empty channel list in ioctls
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Maarten Lankhorst <[email protected]>
commit b43decd2c513ae44a5462a1a4c2622f0fa77c9e0 upstream.
If there are no channels, chan would never end up being NULL, and so the null pointer check would fail.
Solve this by initializing chan to NULL, and iterating over temp instead.
Fixes oops when running intel-gpu-tools/tests/kms_flip, which attempts to do some intel ioctl's on a nouveau device.
--- drivers/gpu/drm/nouveau/nouveau_abi16.c | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-)
drivers/gpu/drm/nouveau/nouveau_abi16.c +10 -8
@@ -386,7 +386,7 @@ nouveau_abi16_ioctl_notifierobj_alloc(ABstruct nouveau_drm *drm =nouveau_drm (dev);struct nouveau_device *device =nv_device (drm->device);struct nouveau_abi16 *abi16 =nouveau_abi16_get (file_priv, dev); -struct nouveau_abi16_chan *chan, *temp; +struct nouveau_abi16_chan *chan =NULL , *temp;struct nouveau_abi16_ntfy *ntfy;struct nouveau_object *object;struct nv_dma_class args = {};
@@ -399,10 +399,11 @@ nouveau_abi16_ioctl_notifierobj_alloc(ABif (unlikely (nv_device (abi16->device)->card_type >=NV_C0 ))return nouveau_abi16_put (abi16, -EINVAL ); -list_for_each_entry_safe (chan, temp, &abi16->channels, head) { -if (chan->chan->handle == (NVDRM_CHAN | info->channel)) +list_for_each_entry (temp, &abi16->channels, head) { +if (temp->chan->handle == (NVDRM_CHAN | info->channel)) { + chan = temp;break ; - chan =NULL ; + } }if (!chan)
@@ -454,17 +455,18 @@ nouveau_abi16_ioctl_gpuobj_free(ABI16_IO {struct drm_nouveau_gpuobj_free *fini = data;struct nouveau_abi16 *abi16 =nouveau_abi16_get (file_priv, dev); -struct nouveau_abi16_chan *chan, *temp; +struct nouveau_abi16_chan *chan =NULL , *temp;struct nouveau_abi16_ntfy *ntfy;int ret;if (unlikely (!abi16))return -ENOMEM ; -list_for_each_entry_safe (chan, temp, &abi16->channels, head) { -if (chan->chan->handle == (NVDRM_CHAN | fini->channel)) +list_for_each_entry (temp, &abi16->channels, head) { +if (temp->chan->handle == (NVDRM_CHAN | fini->channel)) { + chan = temp;break ; - chan =NULL ; + } }if (!chan)
Greg Kroah-Hartman
maintainerPATCH 17/64 drm/i915: Be sure to turn hsync/vsync back on at crt enable (v2)
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Adam Jackson <[email protected]>
commit 637f44d24f8868ee5a597a99e7874fdd150d4cba upstream.
commit f40ebd6bcbbd0d30591f42dc16be52b5086a366b
Author: Patrik Jakobsson <[email protected]> Date: Tue Mar 5 14:24:48 2013 +0100
drm/i915: Turn off hsync and vsync on ADPA when disabling crt
properly disabled the hsync/vsync logic at disable time, but neglected to re-enable them at enable time.
v2: In the enable hook, restore the connector's expected DPMS level instead of forcing ON. Do this by stashing a back pointer to the connector in the crt (suggested by danvet) since otherwise it's awkward to look up.
[danvet: Added more verbose commit citation and cc: stable tag. Also, make it compile. Then self-lart and try to assign the right pointer.]
--- drivers/gpu/drm/i915/intel_crt.c | 40 ++++++++++++++++----------------------- 1 file changed, 17 insertions(+), 23 deletions(-)
drivers/gpu/drm/i915/intel_crt.c +17 -23
@@ -45,6 +45,9 @@struct intel_crt {struct intel_encoder base; +/* DPMS state is stored in the connector, which we need in the +* encoder's enable/disable callbacks */ +struct intel_connector *connector;bool force_hotplug_required;u32 adpa_reg; };
@@ -81,29 +84,6 @@ static bool intel_crt_get_hw_state(strucreturn true; } -static void intel_disable_crt (struct intel_encoder *encoder) -{ -struct drm_i915_private *dev_priv = encoder->base.dev->dev_private; -struct intel_crt *crt =intel_encoder_to_crt (encoder); -u32 temp; - - temp =I915_READ (crt->adpa_reg); - temp |=ADPA_HSYNC_CNTL_DISABLE |ADPA_VSYNC_CNTL_DISABLE ; - temp &= ~ADPA_DAC_ENABLE ; -I915_WRITE (crt->adpa_reg, temp); -} - -static void intel_enable_crt (struct intel_encoder *encoder) -{ -struct drm_i915_private *dev_priv = encoder->base.dev->dev_private; -struct intel_crt *crt =intel_encoder_to_crt (encoder); -u32 temp; - - temp =I915_READ (crt->adpa_reg); - temp |=ADPA_DAC_ENABLE ; -I915_WRITE (crt->adpa_reg, temp); -} -/* Note: The caller is required to filter out dpms modes not supported by the * platform. */ static void intel_crt_set_dpms (struct intel_encoder *encoder,int mode)
@@ -135,6 +115,19 @@ static void intel_crt_set_dpms(struct inI915_WRITE (crt->adpa_reg, temp); } +static void intel_disable_crt (struct intel_encoder *encoder) +{ +intel_crt_set_dpms (encoder,DRM_MODE_DPMS_OFF ); +} + +static void intel_enable_crt (struct intel_encoder *encoder) +{ +struct intel_crt *crt =intel_encoder_to_crt (encoder); + +intel_crt_set_dpms (encoder, crt->connector->base.dpms); +} + +static void intel_crt_dpms (struct drm_connector *connector,int mode) {struct drm_device *dev = connector->dev;
@@ -746,6 +739,7 @@ void intel_crt_init(struct drm_device *d } connector = &intel_connector->base; + crt->connector = intel_connector;drm_connector_init (dev, &intel_connector->base, &intel_crt_connector_funcs,DRM_MODE_CONNECTOR_VGA );
Greg Kroah-Hartman
maintainerPATCH 18/64 drm: correctly restore mappings if drm_open fails
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Ilija Hadzic <[email protected]>
commit a8ec3a662921220fc058ed6f7f3674697876d218 upstream.
If first drm_open fails, the error-handling path will incorrectly restore inode's mapping to NULL. This can cause the crash later on. Fix by separately storing away mapping pointers that drm_open can touch and restore each from its own respective variable if the call fails.
Fixes: https://bugzilla.novell.com/show_bug.cgi?id=807850
(thanks to Michal Hocko for investigating investigating and finding the root cause of the bug)
Reference:
http://lists.freedesktop.org/archives/dri-devel/2013-March/036564.html
v2: Use one variable to store file and inode mapping
since they are the same at the function entry. Fix spelling mistakes in commit message.
v3: Add reference to the original bug report.
--- drivers/gpu/drm/drm_fops.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-)
drivers/gpu/drm/drm_fops.c +4 -2
@@ -123,6 +123,7 @@ int drm_open(struct inode *inode, structint retcode =0 ;int need_setup =0 ;struct address_space *old_mapping; +struct address_space *old_imapping; minor =idr_find (&drm_minors_idr, minor_id);if (!minor)
@@ -137,6 +138,7 @@ int drm_open(struct inode *inode, structif (!dev->open_count++) need_setup =1 ;mutex_lock (&dev->struct_mutex); + old_imapping = inode->i_mapping; old_mapping = dev->dev_mapping;if (old_mapping ==NULL ) dev->dev_mapping = &inode->i_data;
@@ -159,8 +161,8 @@ int drm_open(struct inode *inode, struct err_undo:mutex_lock (&dev->struct_mutex); - filp->f_mapping = old_mapping; - inode->i_mapping = old_mapping; + filp->f_mapping = old_imapping; + inode->i_mapping = old_imapping; iput(container_of(dev->dev_mapping, struct inode, i_data)); dev->dev_mapping = old_mapping;mutex_unlock (&dev->struct_mutex);
Greg Kroah-Hartman
maintainerPATCH 19/64 Revert "drivers/rtc/rtc-at91rm9200.c: use a variable for storing IMR"
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Johan Hovold <[email protected]>
commit e24b0bfa2f0446ffaad2661040be23668133aef8 upstream.
This reverts commit 0ef1594c017521ea89278e80fe3f80dafb17abde.
This patch introduced a few races which cannot be easily fixed with a small follow-up patch. Furthermore, the SoC with the broken hardware register, which this patch intended to add support for, can only be used with device trees, which this driver currently does not support.
[ Here is the discussion that led to this "revert" patch:
https://lkml.org/lkml/2013/4/3/176 ]
--- drivers/rtc/rtc-at91rm9200.c | 50 ++++++++++++++++--------------------------- drivers/rtc/rtc-at91rm9200.h | 1 2 files changed, 20 insertions(+), 31 deletions(-)
drivers/rtc/rtc-at91rm9200.c +19 -31
@@ -44,7 +44,6 @@ static DECLARE_COMPLETION(at91_rtc_updatstatic unsigned int at91_alarm_year =AT91_RTC_EPOCH ;static void __iomem *at91_rtc_regs;static int irq; -static u32 at91_rtc_imr;/* * Decode time/date into rtc_time structure
@@ -109,11 +108,9 @@ static int at91_rtc_settime(struct devic cr =at91_rtc_read (AT91_RTC_CR );at91_rtc_write (AT91_RTC_CR , cr |AT91_RTC_UPDCAL |AT91_RTC_UPDTIM ); - at91_rtc_imr |=AT91_RTC_ACKUPD ;at91_rtc_write (AT91_RTC_IER ,AT91_RTC_ACKUPD );wait_for_completion (&at91_rtc_updated);/* wait for ACKUPD interrupt */ at91_rtc_write (AT91_RTC_IDR ,AT91_RTC_ACKUPD ); - at91_rtc_imr &= ~AT91_RTC_ACKUPD ;at91_rtc_write (AT91_RTC_TIMR , bin2bcd(tm->tm_sec) << 0
@@ -145,7 +142,7 @@ static int at91_rtc_readalarm(struct dev tm->tm_yday =rtc_year_days (tm->tm_mday, tm->tm_mon, tm->tm_year); tm->tm_year = at91_alarm_year -1900 ; - alrm->enabled = (at91_rtc_imr &AT91_RTC_ALARM ) + alrm->enabled = (at91_rtc_read (AT91_RTC_IMR ) &AT91_RTC_ALARM ) ?1 :0 ; pr_debug("%s(): %4d-%02d-%02d %02d:%02d:%02d\n", __func__,
@@ -171,7 +168,6 @@ static int at91_rtc_setalarm(struct devi tm.tm_sec = alrm->time.tm_sec;at91_rtc_write (AT91_RTC_IDR ,AT91_RTC_ALARM ); - at91_rtc_imr &= ~AT91_RTC_ALARM ;at91_rtc_write (AT91_RTC_TIMALR ,bin2bcd (tm.tm_sec) <<0 | bin2bcd(tm.tm_min) << 8
@@ -184,7 +180,6 @@ static int at91_rtc_setalarm(struct deviif (alrm->enabled) {at91_rtc_write (AT91_RTC_SCCR ,AT91_RTC_ALARM ); - at91_rtc_imr |=AT91_RTC_ALARM ;at91_rtc_write (AT91_RTC_IER ,AT91_RTC_ALARM ); }
@@ -201,12 +196,9 @@ static int at91_rtc_alarm_irq_enable(strif (enabled) {at91_rtc_write (AT91_RTC_SCCR ,AT91_RTC_ALARM ); - at91_rtc_imr |=AT91_RTC_ALARM ;at91_rtc_write (AT91_RTC_IER ,AT91_RTC_ALARM ); - }else { + }else at91_rtc_write (AT91_RTC_IDR ,AT91_RTC_ALARM ); - at91_rtc_imr &= ~AT91_RTC_ALARM ; - }return 0 ; }
@@ -215,10 +207,12 @@ static int at91_rtc_alarm_irq_enable(str*/ static int at91_rtc_proc (struct device *dev,struct seq_file *seq) { +unsigned long imr =at91_rtc_read (AT91_RTC_IMR ); +seq_printf (seq,"update_IRQ\t: %s\n" , - (at91_rtc_imr &AT91_RTC_ACKUPD ) ?"yes" :"no" ); + (imr &AT91_RTC_ACKUPD ) ?"yes" :"no" );seq_printf (seq,"periodic_IRQ\t: %s\n" , - (at91_rtc_imr &AT91_RTC_SECEV ) ?"yes" :"no" ); + (imr &AT91_RTC_SECEV ) ?"yes" :"no" );return 0 ; }
@@ -233,7 +227,7 @@ static irqreturn_t at91_rtc_interrupt(inunsigned int rtsr;unsigned long events =0 ; - rtsr =at91_rtc_read (AT91_RTC_SR ) & at91_rtc_imr; + rtsr =at91_rtc_read (AT91_RTC_SR ) &at91_rtc_read (AT91_RTC_IMR );if (rtsr) {/* this interrupt is shared! Is it ours? */ if (rtsr &AT91_RTC_ALARM ) events |= (RTC_AF |RTC_IRQF );
@@ -297,7 +291,6 @@ static int __init at91_rtc_probe(structat91_rtc_write (AT91_RTC_IDR ,AT91_RTC_ACKUPD |AT91_RTC_ALARM |AT91_RTC_SECEV |AT91_RTC_TIMEV |AT91_RTC_CALEV ); - at91_rtc_imr =0 ; ret = request_irq(irq, at91_rtc_interrupt, IRQF_SHARED,
@@ -337,7 +330,6 @@ static int __exit at91_rtc_remove(structat91_rtc_write (AT91_RTC_IDR ,AT91_RTC_ACKUPD |AT91_RTC_ALARM |AT91_RTC_SECEV |AT91_RTC_TIMEV |AT91_RTC_CALEV ); - at91_rtc_imr =0 ;free_irq (irq, pdev);rtc_device_unregister (rtc);
@@ -350,35 +342,31 @@ static int __exit at91_rtc_remove(struct/* AT91RM9200 RTC Power management control */ -static u32 at91_rtc_bkpimr; - +static u32 at91_rtc_imr;static int at91_rtc_suspend (struct device *dev) {/* this IRQ is shared with DBGU and other hardware which isn't * necessarily doing PM like we are... */ - at91_rtc_bkpimr = at91_rtc_imr & (AT91_RTC_ALARM |AT91_RTC_SECEV ); -if (at91_rtc_bkpimr) { -if (device_may_wakeup (dev)) { + at91_rtc_imr =at91_rtc_read (AT91_RTC_IMR ) + & (AT91_RTC_ALARM |AT91_RTC_SECEV ); +if (at91_rtc_imr) { +if (device_may_wakeup (dev))enable_irq_wake (irq); - }else { -at91_rtc_write (AT91_RTC_IDR , at91_rtc_bkpimr); - at91_rtc_imr &= ~at91_rtc_bkpimr; - } -} +else +at91_rtc_write (AT91_RTC_IDR , at91_rtc_imr); + }return 0 ; }static int at91_rtc_resume (struct device *dev) { -if (at91_rtc_bkpimr) { -if (device_may_wakeup (dev)) { +if (at91_rtc_imr) { +if (device_may_wakeup (dev))disable_irq_wake (irq); - }else { - at91_rtc_imr |= at91_rtc_bkpimr; -at91_rtc_write (AT91_RTC_IER , at91_rtc_bkpimr); - } +else +at91_rtc_write (AT91_RTC_IER , at91_rtc_imr); }return 0 ; }
drivers/rtc/rtc-at91rm9200.h +1 -0
@@ -64,6 +64,7 @@#define AT91_RTC_SCCR 0x1c/* Status Clear Command Register */ #define AT91_RTC_IER 0x20/* Interrupt Enable Register */ #define AT91_RTC_IDR 0x24/* Interrupt Disable Register */ +#define AT91_RTC_IMR 0x28/* Interrupt Mask Register */ #define AT91_RTC_VER 0x2c/* Valid Entry Register */ #define AT91_RTC_NVTIM (1 << 0)/* Non valid Time */
Greg Kroah-Hartman
maintainerPATCH 20/64 mm: prevent mmap_cache race in find_vma()
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Jan Stancek <[email protected]>
commit b6a9b7f6b1f21735a7456d534dc0e68e61359d2c upstream.
find_vma() can be called by multiple threads with read lock held on mm->mmap_sem and any of them can update mm->mmap_cache. Prevent compiler from re-fetching mm->mmap_cache, because other readers could update it in the meantime:
thread 1 thread 2
|
find_vma() | find_vma()
struct vm_area_struct *vma = NULL; |
vma = mm->mmap_cache; |
if (!(vma && vma->vm_end > addr |
&& vma->vm_start <= addr)) { |
| mm->mmap_cache = vma;
return vma; |
^^ compiler may optimize this |
local variable out and re-read |
mm->mmap_cache |This issue can be reproduced with gcc-4.8.0-1 on s390x by running mallocstress testcase from LTP, which triggers:
kernel BUG at mm/rmap.c:1088!
Call Trace:
([<000003d100c57000>] 0x3d100c57000)
[<000000000023a1c0>] do_wp_page+0x2fc/0xa88
[<000000000023baae>] handle_pte_fault+0x41a/0xac8
[<000000000023d832>] handle_mm_fault+0x17a/0x268
[<000000000060507a>] do_protection_exception+0x1e2/0x394
[<0000000000603a04>] pgm_check_handler+0x138/0x13c
[<000003fffcf1f07a>] 0x3fffcf1f07a
Last Breaking-Event-Address:
[<000000000024755e>] page_add_new_anon_rmap+0xc2/0x168Thanks to Jakub Jelinek for his insight on gcc and helping to track this down.
--- mm/mmap.c | 2 +- mm/nommu.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)
mm/mmap.c +1 -1
@@ -1922,7 +1922,7 @@ struct vm_area_struct *find_vma(struct m/* Check the cache first. */ /* (Cache hit rate is typically around 35%.) */ - vma = mm->mmap_cache; + vma =ACCESS_ONCE (mm->mmap_cache);if (!(vma && vma->vm_end > addr && vma->vm_start <= addr)) {struct rb_node *rb_node;
mm/nommu.c +1 -1
@@ -819,7 +819,7 @@ struct vm_area_struct *find_vma(struct mstruct vm_area_struct *vma;/* check the cache first */ - vma = mm->mmap_cache; + vma =ACCESS_ONCE (mm->mmap_cache);if (vma && vma->vm_start <= addr && vma->vm_end > addr)return vma;
Greg Kroah-Hartman
maintainerPATCH 21/64 EISA/PCI: Init EISA early, before PNP
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Yinghai Lu <[email protected]>
commit c5fb301ae83bec6892e54984e6ec765c47df8e10 upstream.
Matthew reported kernels fail the pci_eisa probe and are later successful with the virtual_eisa_root_init force probe without slot0.
The reason for that is: PNP probing is before pci_eisa_init gets called as pci_eisa_init is called via pci_driver.
pnp 00:0f has 0xc80 - 0xc84 reserved.
[ 9.700409] pnp 00:0f: [io 0x0c80-0x0c84]
so eisa_probe will fail from pci_eisa_init
==>eisa_root_register ==>eisa_probe path.
as force_probe is not set in pci_eisa_root, it will bail early when slot0 is not probed and initialized.
Try to use subsys_initcall_sync instead, and will keep following sequence:
pci_subsys_init
pci_eisa_init_early
pnpacpi_init/isapnp_init
After this patch EISA can be initialized properly, and PNP overlapping resource will not be reserved.
[ 10.104434] system 00:0f: [io 0x0c80-0x0c84] could not be reserved
--- drivers/eisa/pci_eisa.c | 41 ++++++++++++++++++++++------------------- 1 file changed, 22 insertions(+), 19 deletions(-)
drivers/eisa/pci_eisa.c +22 -19
@@ -19,8 +19,7 @@/* There is only *one* pci_eisa device per machine, right ? */ static struct eisa_root_device pci_eisa_root; -static int __init pci_eisa_init (struct pci_dev *pdev, -const struct pci_device_id *ent) +static int __init pci_eisa_init (struct pci_dev *pdev) {int rc;
@@ -45,22 +44,26 @@ static int __init pci_eisa_init(struct preturn 0 ; } -static struct pci_device_id pci_eisa_pci_tbl[] = { - {PCI_ANY_ID ,PCI_ANY_ID ,PCI_ANY_ID ,PCI_ANY_ID , -PCI_CLASS_BRIDGE_EISA <<8 ,0xffff00 ,0 }, - {0 , } -}; - -static struct pci_driver __refdata pci_eisa_driver = { - .name ="pci_eisa" , - .id_table = pci_eisa_pci_tbl, - .probe = pci_eisa_init, -}; - -static int __init pci_eisa_init_module (void ) +/* +* We have to call pci_eisa_init_early() before pnpacpi_init()/isapnp_init(). +* Otherwise pnp resource will get enabled early and could prevent eisa +* to be initialized. +* Also need to make sure pci_eisa_init_early() is called after +* x86/pci_subsys_init(). +* So need to use subsys_initcall_sync with it. +*/ +static int __init pci_eisa_init_early (void ) { -return pci_register_driver (&pci_eisa_driver); -} +struct pci_dev *dev =NULL ; +int ret; + +for_each_pci_dev (dev) +if ((dev->class >>8 ) ==PCI_CLASS_BRIDGE_EISA ) { + ret =pci_eisa_init (dev); +if (ret) +return ret; + } -device_initcall (pci_eisa_init_module); -MODULE_DEVICE_TABLE (pci, pci_eisa_pci_tbl); +return 0 ; +} +subsys_initcall_sync (pci_eisa_init_early);
Greg Kroah-Hartman
maintainerPATCH 22/64 EISA/PCI: Fix bus res reference
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Yinghai Lu <[email protected]>
commit 2cfda637e29ce9e3df31b59f64516b2e571cc985 upstream.
Matthew found that 3.8.3 is having problems with an old (ancient) PCI-to-EISA bridge, the Intel 82375. It worked with the 3.2 kernel. He identified the 82375, but doesn't assign the struct resource *res pointer inside the struct eisa_root_device, and panics.
pci_eisa_init() was using bus->resource[] directly instead of pci_bus_resource_n(). The bus->resource[] array is a PCI-internal implementation detail, and after commit 45ca9e97 (PCI: add helpers for building PCI bus resource lists) and commit 0efd5aab (PCI: add struct pci_host_bridge_window with CPU/bus address offset), bus->resource[] is not used for PCI root buses any more.
The 82375 is a subtractive-decode PCI device, so handle it the same way we handle PCI-PCI bridges in subtractive-decode mode in pci_read_bridge_bases().
--- drivers/eisa/pci_eisa.c | 28 +++++++++++++++++++++++++--- 1 file changed, 25 insertions(+), 3 deletions(-)
drivers/eisa/pci_eisa.c +25 -3
@@ -21,7 +21,8 @@ static struct eisa_root_device pci_eisa_static int __init pci_eisa_init (struct pci_dev *pdev) { -int rc; +int rc, i; +struct resource *res, *bus_res =NULL ;if ((rc =pci_enable_device (pdev))) { printk (KERN_ERR "pci_eisa : Could not enable device %s\n",
@@ -29,9 +30,30 @@ static int __init pci_eisa_init(struct preturn rc; } +/* +* The Intel 82375 PCI-EISA bridge is a subtractive-decode PCI +* device, so the resources available on EISA are the same as those +* available on the 82375 bus. This works the same as a PCI-PCI +* bridge in subtractive-decode mode (see pci_read_bridge_bases()). +* We assume other PCI-EISA bridges are similar. +* +* eisa_root_register() can only deal with a single io port resource, +* so we use the first valid io port resource. +*/ +pci_bus_for_each_resource (pdev->bus, res, i) +if (res && (res->flags &IORESOURCE_IO )) { + bus_res = res; +break ; + } + +if (!bus_res) { +dev_err (&pdev->dev,"No resources available\n" ); +return -1 ; + } + pci_eisa_root.dev = &pdev->dev; - pci_eisa_root.res = pdev->bus->resource[0 ]; - pci_eisa_root.bus_base_addr = pdev->bus->resource[0 ]->start; + pci_eisa_root.res = bus_res; + pci_eisa_root.bus_base_addr = bus_res->start; pci_eisa_root.slots =EISA_MAX_SLOTS ; pci_eisa_root.dma_mask = pdev->dma_mask;dev_set_drvdata (pci_eisa_root.dev, &pci_eisa_root);
Greg Kroah-Hartman
maintainerPATCH 23/64 ixgbe: fix registration order of driver and DCA nofitication
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Jakub Kicinski <[email protected]>
commit f01fc1a82c2ee68726b400fadb156bd623b5f2f1 upstream.
ixgbe_notify_dca cannot be called before driver registration because it expects driver's klist_devices to be allocated and initialized. While on it make sure debugfs files are removed when registration fails.
--- drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-)
drivers/net/ethernet/intel/ixgbe/ixgbe_main.c +9 -2
@@ -7858,12 +7858,19 @@ static int __init ixgbe_init_module(voidixgbe_dbg_init ();#endif /* CONFIG_DEBUG_FS */ + ret =pci_register_driver (&ixgbe_driver); +if (ret) { +#ifdef CONFIG_DEBUG_FS +ixgbe_dbg_exit (); +#endif /* CONFIG_DEBUG_FS */ +return ret; + } +#ifdef CONFIG_IXGBE_DCA dca_register_notify (&dca_notifier);#endif - ret =pci_register_driver (&ixgbe_driver); -return ret; +return 0 ; }module_init (ixgbe_init_module);
Greg Kroah-Hartman
maintainerPATCH 24/64 libata: Use integer return value for atapi_command_packet_set
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Shan Hai <[email protected]>
commit d8668fcb0b257d9fdcfbe5c172a99b8d85e1cd82 upstream.
The function returns type of ATAPI drives so it should return integer value. The commit 4dce8ba94c7 (libata: Use 'bool' return value for ata_id_XXX) since v2.6.39 changed the type of return value from int to bool, the change would cause all of the ATAPI class drives to be treated as TYPE_TAPE and the max_sectors of the drives to be set to 65535 because of the commit f8d8e5799b7(libata: increase 128 KB / cmd limit for ATAPI tape drives), for the function would return true for all ATAPI class drives and the TYPE_TAPE is defined as 0x01.
--- include/linux/ata.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
include/linux/ata.h +1 -1
@@ -954,7 +954,7 @@ static inline int atapi_cdb_len(const u1 } } -static inline bool atapi_command_packet_set (const u16 *dev_id) +static inline int atapi_command_packet_set (const u16 *dev_id) {return (dev_id[ATA_ID_CONFIG ] >>8 ) &0x1f ; }
Greg Kroah-Hartman
maintainerPATCH 25/64 libata: Set max sector to 65535 for Slimtype DVD A DS8A8SH drive
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Shan Hai <[email protected]>
commit a32450e127fc6e5ca6d958ceb3cfea4d30a00846 upstream.
The Slimtype DVD A DS8A8SH drive locks up when max sector is smaller than 65535, and the blow backtrace is observed on locking up:
INFO: task flush-8:32:1130 blocked for more than 120 seconds.
"echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
flush-8:32 D ffffffff8180cf60 0 1130 2 0x00000000
ffff880273aef618 0000000000000046 0000000000000005 ffff880273aee000 ffff880273aee000 ffff880273aeffd8 ffff880273aee010 ffff880273aee000 ffff880273aeffd8 ffff880273aee000 ffff88026e842ea0 ffff880274a10000
Call Trace: [<ffffffff8168fc2d>] schedule+0x5d/0x70 [<ffffffff8168fccc>] io_schedule+0x8c/0xd0 [<ffffffff81324461>] get_request+0x731/0x7d0 [<ffffffff8133dc60>] ? cfq_allow_merge+0x50/0x90 [<ffffffff81083aa0>] ? wake_up_bit+0x40/0x40 [<ffffffff81320443>] ? bio_attempt_back_merge+0x33/0x110 [<ffffffff813248ea>] blk_queue_bio+0x23a/0x3f0 [<ffffffff81322176>] generic_make_request+0xc6/0x120 [<ffffffff81322308>] submit_bio+0x138/0x160 [<ffffffff811d7596>] ? bio_alloc_bioset+0x96/0x120 [<ffffffff811d1f61>] submit_bh+0x1f1/0x220 [<ffffffff811d48b8>] __block_write_full_page+0x228/0x340 [<ffffffff811d3650>] ? attach_nobh_buffers+0xc0/0xc0 [<ffffffff811d8960>] ? I_BDEV+0x10/0x10 [<ffffffff811d8960>] ? I_BDEV+0x10/0x10 [<ffffffff811d4ab6>] block_write_full_page_endio+0xe6/0x100 [<ffffffff811d4ae5>] block_write_full_page+0x15/0x20 [<ffffffff811d9268>] blkdev_writepage+0x18/0x20 [<ffffffff81142527>] __writepage+0x17/0x40 [<ffffffff811438ba>] write_cache_pages+0x34a/0x4a0 [<ffffffff81142510>] ? set_page_dirty+0x70/0x70 [<ffffffff81143a61>] generic_writepages+0x51/0x80 [<ffffffff81143ab0>] do_writepages+0x20/0x50 [<ffffffff811c9ed6>] __writeback_single_inode+0xa6/0x2b0 [<ffffffff811ca861>] writeback_sb_inodes+0x311/0x4d0 [<ffffffff811caaa6>] __writeback_inodes_wb+0x86/0xd0 [<ffffffff811cad43>] wb_writeback+0x1a3/0x330 [<ffffffff816916cf>] ? _raw_spin_lock_irqsave+0x3f/0x50 [<ffffffff811b8362>] ? get_nr_inodes+0x52/0x70 [<ffffffff811cb0ac>] wb_do_writeback+0x1dc/0x260 [<ffffffff8168dd34>] ? schedule_timeout+0x204/0x240 [<ffffffff811cb232>] bdi_writeback_thread+0x102/0x2b0 [<ffffffff811cb130>] ? wb_do_writeback+0x260/0x260 [<ffffffff81083550>] kthread+0xc0/0xd0 [<ffffffff81083490>] ? kthread_worker_fn+0x1b0/0x1b0 [<ffffffff8169a3ec>] ret_from_fork+0x7c/0xb0 [<ffffffff81083490>] ? kthread_worker_fn+0x1b0/0x1b0
The above trace was triggered by
"dd if=/dev/zero of=/dev/sr0 bs=2048 count=32768"
It was previously working by accident, since another bug introduced by 4dce8ba94c7 (libata: Use 'bool' return value for ata_id_XXX) caused all drives to use maxsect=65535.
--- drivers/ata/libata-core.c | 4 ++++ include/linux/libata.h | 1 + 2 files changed, 5 insertions(+)
drivers/ata/libata-core.c +4 -0
@@ -2437,6 +2437,9 @@ int ata_dev_configure(struct ata_device dev->max_sectors = min_t(unsigned int, ATA_MAX_SECTORS_128, dev->max_sectors); +if (dev->horkage &ATA_HORKAGE_MAX_SEC_LBA48 ) + dev->max_sectors =ATA_MAX_SECTORS_LBA48 ; +if (ap->ops->dev_config) ap->ops->dev_config (dev);
@@ -4098,6 +4101,7 @@ static const struct ata_blacklist_entry/* Weird ATAPI devices */ { "TORiSAN DVD-ROM DRD-N216", NULL, ATA_HORKAGE_MAX_SEC_128 }, { "QUANTUM DAT DAT72-000", NULL, ATA_HORKAGE_ATAPI_MOD16_DMA }, + { "Slimtype DVD A DS8A8SH", NULL, ATA_HORKAGE_MAX_SEC_LBA48 }, /* Devices we expect to fail diagnostics */
include/linux/libata.h +1 -0
@@ -398,6 +398,7 @@ enum {ATA_HORKAGE_NOSETXFER = (1 <<14 ),/* skip SETXFER, SATA only */ ATA_HORKAGE_BROKEN_FPDMA_AA = (1 <<15 ),/* skip AA */ ATA_HORKAGE_DUMP_ID = (1 <<16 ),/* dump IDENTIFY data */ + ATA_HORKAGE_MAX_SEC_LBA48 = (1 << 17), /* Set max sects to 65535 *//* DMA mask for user DMA control: User visible values; DO NOT renumber */
Greg Kroah-Hartman
maintainerPATCH 26/64 libata: fix DMA to stack in reading devslp_timing parameters
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: David Woodhouse <[email protected]>
commit 8e725c7f8a60feaa88edacd4dee2c754d5ae7706 upstream.
Commit 803739d25c2343da6d2f95eebdcbc08bf67097d4 ("[libata] replace sata_settings with devslp_timing"), which was also Cc: stable, used a stack buffer to receive data from ata_read_log_page(), which triggers
the following warning:
ahci 0000:00:1f.2: DMA-API: device driver maps memory fromstack [addr=ffff880140469948]
Fix this by using ap->sector_buf instead of a stack buffer.
--- drivers/ata/libata-core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/ata/libata-core.c +1 -1
@@ -2329,7 +2329,7 @@ int ata_dev_configure(struct ata_device* from SATA Settings page of Identify Device Data Log. */ if (ata_id_has_devslp (dev->id)) { -u8 sata_setting[ATA_SECT_SIZE ]; +u8 *sata_setting = ap->sector_buf;int i, j; dev->flags |=ATA_DFLAG_DEVSLP ;
Greg Kroah-Hartman
maintainerPATCH 27/64 MIPS: Unbreak function tracer for 64-bit kernel.
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: David Daney <[email protected]>
commit ad8c396936e328f5344e1881afde9e28d5f2045f upstream.
Commit 58b69401c797 [MIPS: Function tracer: Fix broken function tracing] completely broke the function tracer for 64-bit kernels. The symptom is a system hang very early in the boot process.
The fix: Remove/fix $sp adjustments for 64-bit case.
--- arch/mips/kernel/mcount.S | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-)
arch/mips/kernel/mcount.S +7 -4
@@ -46,10 +46,9 @@ PTR_L a5, PT_R9(sp) PTR_L a6, PT_R10(sp) PTR_L a7, PT_R11(sp) -#else - PTR_ADDIU sp, PT_SIZE #endif -.endm + PTR_ADDIU sp, PT_SIZE + .endm .macro RETURN_BACK jr ra
@@ -68,7 +67,11 @@ NESTED(ftrace_caller, PT_SIZE, ra) .globl _mcount _mcount: b ftrace_stub - addiu sp,sp,8 +#ifdef CONFIG_32BIT + addiu sp,sp,8 +#else + nop +#endif /* When tracing is activated, it calls ftrace_caller+8 (aka here) */ lw t1, function_trace_stop
Greg Kroah-Hartman
maintainerPATCH 28/64 alpha: Add irongate_io to PCI bus resources
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Jay Estabrook <[email protected]>
commit aa8b4be3ac049c8b1df2a87e4d1d902ccfc1f7a9 upstream.
Fixes a NULL pointer dereference at boot on UP1500.
--- arch/alpha/kernel/sys_nautilus.c | 5 +++++ 1 file changed, 5 insertions(+)
arch/alpha/kernel/sys_nautilus.c +5 -0
@@ -188,6 +188,10 @@ nautilus_machine_check(unsigned long vecextern void free_reserved_mem (void *,void *);extern void pcibios_claim_one_bus (struct pci_bus *); +static struct resource irongate_io = { + .name ="Irongate PCI IO" , + .flags =IORESOURCE_IO , +};static struct resource irongate_mem = { .name ="Irongate PCI MEM" , .flags =IORESOURCE_MEM ,
@@ -209,6 +213,7 @@ nautilus_init_pci(void) irongate =pci_get_bus_and_slot (0 ,0 ); bus->self = irongate; + bus->resource[0 ] = &irongate_io; bus->resource[1 ] = &irongate_mem;pci_bus_size_bridges (bus);
Greg Kroah-Hartman
maintainerPATCH 29/64 PCI/ACPI: Always resume devices on ACPI wakeup notifications
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: "Rafael J. Wysocki" <[email protected]>
commit 24ad0ef9c8b946ed2abe681e4e44f4a1e643d882 upstream.
It turns out that the _Lxx control methods provided by some BIOSes clear the PME Status bit of PCI devices they handle, which means that pci_acpi_wake_dev() cannot really use that bit to check whether or not the device has signalled wakeup.
One symptom of the problem is, for example, that when an affected PCI USB controller is runtime-suspended, then plugging in a new USB device into one of the controller's ports will not wake up the controller, which should happen.
For this reason, make pci_acpi_wake_dev() always attempt to resume the device it is called for regardless of the device's PME Status bit value (that bit still has to be cleared if set at this point, though).
--- drivers/pci/pci-acpi.c | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-)
drivers/pci/pci-acpi.c +8 -7
@@ -53,14 +53,15 @@ static void pci_acpi_wake_dev(acpi_handlreturn ; } -if (!pci_dev->pm_cap || !pci_dev->pme_support - ||pci_check_pme_status (pci_dev)) { -if (pci_dev->pme_poll) - pci_dev->pme_poll = false; +/* Clear PME Status if set. */ +if (pci_dev->pme_support) +pci_check_pme_status (pci_dev); -pci_wakeup_event (pci_dev); -pm_runtime_resume (&pci_dev->dev); - } +if (pci_dev->pme_poll) + pci_dev->pme_poll = false; + +pci_wakeup_event (pci_dev); +pm_runtime_resume (&pci_dev->dev);if (pci_dev->subordinate)pci_pme_wakeup_bus (pci_dev->subordinate);
Greg Kroah-Hartman
maintainerPATCH 30/64 PCI/PM: Disable runtime PM of PCIe ports
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: "Rafael J. Wysocki" <[email protected]>
commit de7d5f729c72638f41d7c17487bccb1c570ff144 upstream.
The runtime PM of PCIe ports turns out to be quite fragile, as in some cases things work while in some other cases they don't and we don't seem to have a good way to determine whether or not they are going to work in advance.
For this reason, avoid enabling runtime PM for PCIe ports by keeping their runtime PM reference counters always above 0 for the time being.
When a PCIe port is suspended, it can no longer report events like hotplug, so hotplug below the port may not work, as in the bug report below.
[bhelgaas: changelog, stable]
Reference: https://bugzilla.kernel.org/show_bug.cgi?id=53811
--- drivers/pci/pcie/portdrv_pci.c | 13 ------------- 1 file changed, 13 deletions(-)
drivers/pci/pcie/portdrv_pci.c +0 -13
@@ -185,14 +185,6 @@ static const struct dev_pm_ops pcie_port#endif /* !PM */ /* -* PCIe port runtime suspend is broken for some chipsets, so use a -* black list to disable runtime PM for these chipsets. -*/ -static const struct pci_device_id port_runtime_pm_black_list[] = { - {/* end: all zeroes */ } -}; - -/* * pcie_portdrv_probe - Probe PCI-Express port devices * @dev: PCI-Express port device being probed *
@@ -225,16 +217,11 @@ static int pcie_portdrv_probe(struct pci* it by default. */ dev->d3cold_allowed = false; -if (!pci_match_id (port_runtime_pm_black_list, dev)) -pm_runtime_put_noidle (&dev->dev); -return 0 ; }static void pcie_portdrv_remove (struct pci_dev *dev) { -if (!pci_match_id (port_runtime_pm_black_list, dev)) -pm_runtime_get_noresume (&dev->dev);pcie_port_device_remove (dev);pci_disable_device (dev); }
Greg Kroah-Hartman
maintainerPATCH 31/64 ata_piix: Fix DVD not dectected at some Haswell platforms
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Youquan Song <[email protected]>
commit b55f84e2d527182e7c611d466cd0bb6ddce201de upstream.
There is a quirk patch 5e5a4f5d5a08c9c504fe956391ac3dae2c66556d "ata_piix: make DVD Drive recognisable on systems with Intel Sandybridge
chipsets(v2)" fixing the 4 ports IDE controller 32bit PIO mode.
We've hit a problem with DVD not recognized on Haswell Desktop platform which includes Lynx Point 2-port SATA controller.
This quirk patch disables 32bit PIO on this controller in IDE mode.
v2: Change spelling error in statememnt pointed by Sergei Shtylyov.
v3: Change comment statememnt and spliting line over 80 characters pointed by
Libor Pechacek and also rebase the patch against 3.8-rc7 kernel.
--- drivers/ata/ata_piix.c | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-)
drivers/ata/ata_piix.c +13 -1
@@ -150,6 +150,7 @@ enum piix_controller_ids { tolapai_sata, piix_pata_vmw,/* PIIX4 for VMware, spurious DMA_ERR */ ich8_sata_snb, + ich8_2port_sata_snb, }; struct piix_map_db {
@@ -304,7 +305,7 @@ static const struct pci_device_id piix_p/* SATA Controller IDE (Lynx Point) */ { 0x8086, 0x8c01, PCI_ANY_ID, PCI_ANY_ID, 0, 0, ich8_sata_snb },/* SATA Controller IDE (Lynx Point) */ - { 0x8086, 0x8c08, PCI_ANY_ID, PCI_ANY_ID, 0, 0, ich8_2port_sata }, + { 0x8086, 0x8c08, PCI_ANY_ID, PCI_ANY_ID, 0, 0, ich8_2port_sata_snb },/* SATA Controller IDE (Lynx Point) */ { 0x8086, 0x8c09, PCI_ANY_ID, PCI_ANY_ID, 0, 0, ich8_2port_sata }, /* SATA Controller IDE (Lynx Point-LP) */
@@ -439,6 +440,7 @@ static const struct piix_map_db *piix_ma [ich8m_apple_sata] = &ich8m_apple_map_db, [tolapai_sata] = &tolapai_map_db, [ich8_sata_snb] = &ich8_map_db, + [ich8_2port_sata_snb] = &ich8_2port_map_db, };static struct pci_bits piix_enable_bits[] = {
@@ -1240,6 +1242,16 @@ static struct ata_port_info piix_port_in .pio_mask = ATA_PIO4, .mwdma_mask = ATA_MWDMA2, .udma_mask = ATA_UDMA6, + .port_ops = &piix_sata_ops, + }, + + [ich8_2port_sata_snb] = + { + .flags =PIIX_SATA_FLAGS |PIIX_FLAG_SIDPR + | PIIX_FLAG_PIO16, + .pio_mask = ATA_PIO4, + .mwdma_mask = ATA_MWDMA2, + .udma_mask = ATA_UDMA6, .port_ops = &piix_sata_ops, }, };
Greg Kroah-Hartman
maintainerPATCH 32/64 ftrace: Consistently restore trace function on sysctl enabling
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Jan Kiszka <[email protected]>
commit 5000c418840b309251c5887f0b56503aae30f84c upstream.
If we reenable ftrace via syctl, we currently set ftrace_trace_function based on the previous simplistic algorithm. This is inconsistent with what update_ftrace_function does. So better call that helper instead.
--- kernel/trace/ftrace.c | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-)
kernel/trace/ftrace.c +2 -6
@@ -4537,12 +4537,8 @@ ftrace_enable_sysctl(struct ctl_table *tftrace_startup_sysctl ();/* we are starting ftrace again */ -if (ftrace_ops_list != &ftrace_list_end) { -if (ftrace_ops_list->next == &ftrace_list_end) - ftrace_trace_function = ftrace_ops_list->func; -else - ftrace_trace_function = ftrace_ops_list_func; - } +if (ftrace_ops_list != &ftrace_list_end) +update_ftrace_function (); }else {/* stopping ftrace calls (just send to ftrace_stub) */
Greg Kroah-Hartman
maintainerPATCH 33/64 powerpc: pSeries_lpar_hpte_remove fails from Adjunct partition being performed before the ANDCOND test
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Michael Wolf <[email protected]>
commit 9fb2640159f9d4f5a2a9d60e490482d4cbecafdb upstream.
Some versions of pHyp will perform the adjunct partition test before the ANDCOND test. The result of this is that H_RESOURCE can be returned and cause the BUG_ON condition to occur. The HPTE is not removed. So add a check for H_RESOURCE, it is ok if this HPTE is not removed as pSeries_lpar_hpte_remove is looking for an HPTE to remove and not a specific HPTE to remove. So it is ok to just move on to the next slot and try again.
--- arch/powerpc/platforms/pseries/lpar.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-)
arch/powerpc/platforms/pseries/lpar.c +7 -1
@@ -186,7 +186,13 @@ static long pSeries_lpar_hpte_remove(uns (0x1UL << 4), &dummy1, &dummy2);if (lpar_rc ==H_SUCCESS )return i; -BUG_ON (lpar_rc !=H_NOT_FOUND ); + +/* +* The test for adjunct partition is performed before the +* ANDCOND test. H_RESOURCE may be returned, so we need to +* check for that as well. +*/ +BUG_ON (lpar_rc !=H_NOT_FOUND && lpar_rc !=H_RESOURCE ); slot_offset++; slot_offset &=0x7 ;
Greg Kroah-Hartman
maintainerPATCH 34/64 mwifiex: limit channel number not to overflow memory
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Stone Piao <[email protected]>
commit 901ceba4e81e9dd6b4a3c4c37ee22000a6c5c65f upstream.
Limit the channel number in scan request, or the driver scan config structure memory will be overflowed.
--- drivers/net/wireless/mwifiex/cfg80211.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
drivers/net/wireless/mwifiex/cfg80211.c +2 -1
@@ -1846,7 +1846,8 @@ mwifiex_cfg80211_scan(struct wiphy *wiph } } -for (i =0 ; i < request->n_channels; i++) { +for (i =0 ; i <min_t (u32, request->n_channels, +MWIFIEX_USER_SCAN_CHAN_MAX ); i++) { chan = request->channels[i]; priv->user_scan_cfg->chan_list[i].chan_number = chan->hw_value; priv->user_scan_cfg->chan_list[i].radio_type = chan->band;
Greg Kroah-Hartman
maintainerPATCH 35/64 mac80211: fix remain-on-channel cancel crash
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Johannes Berg <[email protected]>
commit 3fbd45ca8d1c98f3c2582ef8bc70ade42f70947b upstream.
If a ROC item is canceled just as it expires, the work struct may be scheduled while it is running (and waiting for the mutex). This results in it being run after being freed, which obviously crashes.
To fix this don't free it when aborting is requested but instead mark it as "to be freed", which makes the work a no-op and allows freeing it outside.
--- net/mac80211/cfg.c | 6 ++++-- net/mac80211/ieee80211_i.h | 3 ++- net/mac80211/offchannel.c | 23 +++++++++++++++++------ 3 files changed, 23 insertions(+), 9 deletions(-)
net/mac80211/cfg.c +4 -2
@@ -2499,7 +2499,7 @@ static int ieee80211_cancel_roc(struct ilist_del (&dep->list);mutex_unlock (&local->mtx); -ieee80211_roc_notify_destroy (dep); +ieee80211_roc_notify_destroy (dep, true);return 0 ; }
@@ -2539,7 +2539,7 @@ static int ieee80211_cancel_roc(struct iieee80211_start_next_roc (local);mutex_unlock (&local->mtx); -ieee80211_roc_notify_destroy (found); +ieee80211_roc_notify_destroy (found, true); }else {/* work may be pending so use it all the time */ found->abort = true;
@@ -2549,6 +2549,8 @@ static int ieee80211_cancel_roc(struct i/* work will clean up etc */ flush_delayed_work (&found->work); +WARN_ON (!found->to_be_freed); +kfree (found); }return 0 ;
net/mac80211/ieee80211_i.h +2 -1
@@ -346,6 +346,7 @@ struct ieee80211_roc_work {struct ieee80211_channel *chan;bool started, abort, hw_begun, notified; +bool to_be_freed;unsigned long hw_start_time;
@@ -1363,7 +1364,7 @@ void ieee80211_offchannel_return(structvoid ieee80211_roc_setup (struct ieee80211_local *local);void ieee80211_start_next_roc (struct ieee80211_local *local);void ieee80211_roc_purge (struct ieee80211_sub_if_data *sdata); -void ieee80211_roc_notify_destroy (struct ieee80211_roc_work *roc); +void ieee80211_roc_notify_destroy (struct ieee80211_roc_work *roc,bool free);void ieee80211_sw_roc_work (struct work_struct *work);void ieee80211_handle_roc_started (struct ieee80211_roc_work *roc);
net/mac80211/offchannel.c +17 -6
@@ -299,10 +299,13 @@ void ieee80211_start_next_roc(struct iee } } -void ieee80211_roc_notify_destroy (struct ieee80211_roc_work *roc) +void ieee80211_roc_notify_destroy (struct ieee80211_roc_work *roc,bool free) {struct ieee80211_roc_work *dep, *tmp; +if (WARN_ON (roc->to_be_freed)) +return ; +/* was never transmitted */ if (roc->frame) { cfg80211_mgmt_tx_status(&roc->sdata->wdev,
@@ -318,9 +321,12 @@ void ieee80211_roc_notify_destroy(struct GFP_KERNEL);list_for_each_entry_safe (dep, tmp, &roc->dependents, list) -ieee80211_roc_notify_destroy (dep); +ieee80211_roc_notify_destroy (dep, true); -kfree (roc); +if (free) +kfree (roc); +else + roc->to_be_freed = true; }void ieee80211_sw_roc_work (struct work_struct *work)
@@ -333,6 +339,9 @@ void ieee80211_sw_roc_work(struct work_smutex_lock (&local->mtx); +if (roc->to_be_freed) + goto out_unlock; +if (roc->abort) goto finish;
@@ -372,7 +381,7 @@ void ieee80211_sw_roc_work(struct work_s finish:list_del (&roc->list); started = roc->started; -ieee80211_roc_notify_destroy (roc); +ieee80211_roc_notify_destroy (roc, !roc->abort);if (started) {drv_flush (local, false);
@@ -412,7 +421,7 @@ static void ieee80211_hw_roc_done(structlist_del (&roc->list); -ieee80211_roc_notify_destroy (roc); +ieee80211_roc_notify_destroy (roc, true);/* if there's another roc, start it now */ ieee80211_start_next_roc (local);
@@ -462,12 +471,14 @@ void ieee80211_roc_purge(struct ieee8021list_for_each_entry_safe (roc, tmp, &tmp_list, list) {if (local->ops->remain_on_channel) {list_del (&roc->list); -ieee80211_roc_notify_destroy (roc); +ieee80211_roc_notify_destroy (roc, true); }else {ieee80211_queue_delayed_work (&local->hw, &roc->work,0 );/* work will clean up etc */ flush_delayed_work (&roc->work); +WARN_ON (!roc->to_be_freed); +kfree (roc); } }
Greg Kroah-Hartman
maintainerPATCH 36/64 x86: remove the x32 syscall bitmask from syscall_get_nr()
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Paul Moore <[email protected]>
commit 8b4b9f27e57584f3d90e0bb84cf800ad81cfe3a1 upstream.
Commit fca460f95e928bae373daa8295877b6905bc62b8 simplified the x32 implementation by creating a syscall bitmask, equal to 0x40000000, that could be applied to x32 syscalls such that the masked syscall number would be the same as a x86_64 syscall. While that patch was a nice way to simplify the code, it went a bit too far by adding the mask to syscall_get_nr(); returning the masked syscall numbers can cause confusion with callers that expect syscall numbers matching the x32 ABI, e.g. unmasked syscall numbers.
This patch fixes this by simply removing the mask from syscall_get_nr() while preserving the other changes from the original commit. While there are several syscall_get_nr() callers in the kernel, most simply check that the syscall number is greater than zero, in this case this patch will have no effect. Of those remaining callers, they appear to be few, seccomp and ftrace, and from my testing of seccomp without this patch the original commit definitely breaks things; the seccomp filter does not correctly filter the syscalls due to the difference in syscall numbers in the BPF filter and the value from syscall_get_nr(). Applying this patch restores the seccomp BPF filter functionality on x32.
I've tested this patch with the seccomp BPF filters as well as ftrace and everything looks reasonable to me; needless to say general usage seemed fine as well.
--- arch/x86/include/asm/syscall.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
arch/x86/include/asm/syscall.h +2 -2
@@ -29,13 +29,13 @@ extern const unsigned long sys_call_tabl*/ static inline int syscall_get_nr (struct task_struct *task,struct pt_regs *regs) { -return regs->orig_ax & __SYSCALL_MASK; +return regs->orig_ax; }static inline void syscall_rollback (struct task_struct *task,struct pt_regs *regs) { - regs->ax = regs->orig_ax & __SYSCALL_MASK; + regs->ax = regs->orig_ax; } static inline long syscall_get_error(struct task_struct *task,
Greg Kroah-Hartman
maintainerPATCH 37/64 hwspinlock: fix __hwspin_lock_request error path
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Li Fei <[email protected]>
commit c10b90d85a5126d25c89cbaa50dc9fdd1c4d001a upstream.
Even in failed case of pm_runtime_get_sync, the usage_count is incremented. In order to keep the usage_count with correct value and runtime power management to behave correctly, call pm_runtime_put_noidle in such case.
In __hwspin_lock_request, module_put is also called before return in pm_runtime_get_sync failed case.
Signed-off-by Liu Chuansheng <[email protected]>
--- drivers/hwspinlock/hwspinlock_core.c | 2 ++ 1 file changed, 2 insertions(+)
drivers/hwspinlock/hwspinlock_core.c +2 -0
@@ -416,6 +416,8 @@ static int __hwspin_lock_request(struct ret =pm_runtime_get_sync (dev);if (ret <0 ) {dev_err (dev,"%s: can't power on device\n" , __func__); +pm_runtime_put_noidle (dev); +module_put (dev->driver->owner);return ret; }
Greg Kroah-Hartman
maintainerPATCH 38/64 remoteproc/ste: fix memory leak on shutdown
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Dmitry Tarnyagin <[email protected]>
commit 1cd425b660bd5b4f41b9175b0b7bf3828ce88144 upstream.
Fixes coherent memory leakage, caused by non-deallocated firmware image chunk.
--- drivers/remoteproc/ste_modem_rproc.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-)
drivers/remoteproc/ste_modem_rproc.c +6 -1
@@ -240,6 +240,8 @@ static int sproc_drv_remove(struct platf/* Unregister as remoteproc device */ rproc_del (sproc->rproc); +dma_free_coherent (sproc->rproc->dev.parent,SPROC_FW_SIZE , + sproc->fw_addr, sproc->fw_dma_addr);rproc_put (sproc->rproc); mdev->drv_data =NULL ;
@@ -297,10 +299,13 @@ static int sproc_probe(struct platform_d/* Register as a remoteproc device */ err =rproc_add (rproc);if (err) - goto free_rproc; + goto free_mem;return 0 ; +free_mem: +dma_free_coherent (rproc->dev.parent,SPROC_FW_SIZE , + sproc->fw_addr, sproc->fw_dma_addr); free_rproc:/* Reset device data upon error */ mdev->drv_data =NULL ;
Greg Kroah-Hartman
maintainerPATCH 39/64 remoteproc: fix error path of handle_vdev
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Sjur Brændeland <[email protected]>
commit cde42e076c1cdd69a1f955d66ff6596bad3d2105 upstream.
Remove the vdev entry from the list before freeing it, otherwise rproc->vdevs will explode.
--- drivers/remoteproc/remoteproc_core.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
drivers/remoteproc/remoteproc_core.c +3 -1
@@ -370,10 +370,12 @@ static int rproc_handle_vdev(struct rpro/* it is now safe to add the virtio device */ ret =rproc_add_virtio_dev (rvdev, rsc->id);if (ret) - goto free_rvdev; + goto remove_rvdev;return 0 ; +remove_rvdev: +list_del (&rvdev->node); free_rvdev:kfree (rvdev);return ret;
Greg Kroah-Hartman
maintainerPATCH 40/64 remoteproc: fix FW_CONFIG typo
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Robert Tivy <[email protected]>
commit c7426bce5933d16b492a34e42ae77e26fceddff6 upstream.
Fix obvious typo introduced in commit e121aefa7d9f10eee5cf26ed47129237a05d940b ("remoteproc: fix missing CONFIG_FW_LOADER configurations").
--- drivers/remoteproc/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/remoteproc/Kconfig +1 -1
@@ -5,7 +5,7 @@ config REMOTEPROC tristate depends on EXPERIMENTAL depends on HAS_DMA - select FW_CONFIG + select FW_LOADER select VIRTIO config OMAP_REMOTEPROC
Greg Kroah-Hartman
maintainerPATCH 41/64 spinlocks and preemption points need to be at least compiler barriers
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Linus Torvalds <[email protected]>
commit 386afc91144b36b42117b0092893f15bc8798a80 upstream.
In UP and non-preempt respectively, the spinlocks and preemption disable/enable points are stubbed out entirely, because there is no regular code that can ever hit the kind of concurrency they are meant to protect against.
However, while there is no regular code that can cause scheduling, we _do_ end up having some exceptional (literally!) code that can do so, and that we need to make sure does not ever get moved into the critical region by the compiler.
In particular, get_user() and put_user() is generally implemented as inline asm statements (even if the inline asm may then make a call instruction to call out-of-line), and can obviously cause a page fault and IO as a result. If that inline asm has been scheduled into the middle of a preemption-safe (or spinlock-protected) code region, we obviously lose.
Now, admittedly this is *very* unlikely to actually ever happen, and we've not seen examples of actual bugs related to this. But partly exactly because it's so hard to trigger and the resulting bug is so subtle, we should be extra careful to get this right.
So make sure that even when preemption is disabled, and we don't have to generate any actual *code* to explicitly tell the system that we are in a preemption-disabled region, we need to at least tell the compiler not to move things around the critical region.
This patch grew out of the same discussion that caused commits 79e5f05edcbf ("ARC: Add implicit compiler barrier to raw_local_irq* functions") and 3e2e0d2c222b ("tile: comment assumption about __insn_mtspr for <asm/irqflags.h>") to come about.
Note for stable: use discretion when/if applying this. As mentioned, this bug may never have actually bitten anybody, and gcc may never have done the required code motion for it to possibly ever trigger in practice.
--- include/linux/preempt.h | 20 +++++++++++++------- include/linux/spinlock_up.h | 29 ++++++++++++++++++----------- 2 files changed, 31 insertions(+), 18 deletions(-)
include/linux/preempt.h +13 -7
@@ -93,14 +93,20 @@ do { \#else /* !CONFIG_PREEMPT_COUNT */ -#define preempt_disable () do { } while (0) -#define sched_preempt_enable_no_resched () do { } while (0) -#define preempt_enable_no_resched () do { } while (0) -#define preempt_enable () do { } while (0) +/* +* Even if we don't have any preemption, we need preempt disable/enable +* to be barriers, so that we don't have things like get_user/put_user +* that can cause faults and scheduling migrate into our preempt-protected +* region. +*/ +#define preempt_disable () barrier() +#define sched_preempt_enable_no_resched () barrier() +#define preempt_enable_no_resched () barrier() +#define preempt_enable () barrier() -#define preempt_disable_notrace () do { } while (0) -#define preempt_enable_no_resched_notrace () do { } while (0) -#define preempt_enable_notrace () do { } while (0) +#define preempt_disable_notrace () barrier() +#define preempt_enable_no_resched_notrace () barrier() +#define preempt_enable_notrace () barrier()#endif /* CONFIG_PREEMPT_COUNT */
include/linux/spinlock_up.h +18 -11
@@ -16,7 +16,10 @@* In the debug case, 1 means unlocked, 0 means locked. (the values * are inverted, to catch initialization bugs) * -* No atomicity anywhere, we are on UP. +* No atomicity anywhere, we are on UP. However, we still need +* the compiler barriers, because we do not want the compiler to +* move potentially faulting instructions (notably user accesses) +* into the locked sequence, resulting in non-atomic execution. */ #ifdef CONFIG_DEBUG_SPINLOCK
@@ -25,6 +28,7 @@static inline void arch_spin_lock (arch_spinlock_t *lock) { lock->slock =0 ; +barrier (); } static inline void
@@ -32,6 +36,7 @@ arch_spin_lock_flags(arch_spinlock_t *lo {local_irq_save (flags); lock->slock =0 ; +barrier (); }static inline int arch_spin_trylock (arch_spinlock_t *lock)
@@ -39,32 +44,34 @@ static inline int arch_spin_trylock(archchar oldval = lock->slock; lock->slock =0 ; +barrier (); return oldval > 0; }static inline void arch_spin_unlock (arch_spinlock_t *lock) { +barrier (); lock->slock =1 ; }/* * Read-write spinlocks. No debug version. */ -#define arch_read_lock (lock) do { (void)(lock); } while (0) -#define arch_write_lock (lock) do { (void)(lock); } while (0) -#define arch_read_trylock (lock) ({ (void)(lock); 1; }) -#define arch_write_trylock (lock) ({ (void)(lock); 1; }) -#define arch_read_unlock (lock) do { (void)(lock); } while (0) -#define arch_write_unlock (lock) do { (void)(lock); } while (0) +#define arch_read_lock (lock) do { barrier(); (void)(lock); } while (0) +#define arch_write_lock (lock) do { barrier(); (void)(lock); } while (0) +#define arch_read_trylock (lock) ({ barrier(); (void)(lock); 1; }) +#define arch_write_trylock (lock) ({ barrier(); (void)(lock); 1; }) +#define arch_read_unlock (lock) do { barrier(); (void)(lock); } while (0) +#define arch_write_unlock (lock) do { barrier(); (void)(lock); } while (0)#else /* DEBUG_SPINLOCK */ #define arch_spin_is_locked (lock) ((void)(lock), 0)/* for sched.c and kernel_lock.c: */ -# define arch_spin_lock (lock) do { (void)(lock); } while (0) -# define arch_spin_lock_flags (lock, flags) do { (void)(lock); } while (0) -# define arch_spin_unlock (lock) do { (void)(lock); } while (0) -# define arch_spin_trylock (lock) ({ (void)(lock); 1; }) +# define arch_spin_lock (lock) do { barrier(); (void)(lock); } while (0) +# define arch_spin_lock_flags (lock, flags) do { barrier(); (void)(lock); } while (0) +# define arch_spin_unlock (lock) do { barrier(); (void)(lock); } while (0) +# define arch_spin_trylock (lock) ({ barrier(); (void)(lock); 1; })#endif /* DEBUG_SPINLOCK */ #define arch_spin_is_contended (lock) (((void)(lock), 0))
Re: [ 41/64] spinlocks and preemption points need to be at least compiler barriers
Quoted 5 lines · Greg Kroah-Hartman
Note for stable: use discretion when/if applying this. As mentioned, this bug may never have actually bitten anybody, and gcc may never have done the required code motion for it to possibly ever trigger in practice.
No objections, I just wanted to make sure the stable people had noticed this message to them...
Linus
Greg Kroah-Hartman
maintainerRe: [ 41/64] spinlocks and preemption points need to be at least compiler barriers
Quoted 10 lines · Linus Torvalds
Quoted 5 lines · Greg Kroah-Hartman
Note for stable: use discretion when/if applying this. As mentioned, this bug may never have actually bitten anybody, and gcc may never have done the required code motion for it to possibly ever trigger in practice.
No objections, I just wanted to make sure the stable people had noticed this message to them...
Yeah, I saw it, and it looks like a valid thing to apply.
thanks,
greg k-h
Greg Kroah-Hartman
maintainerPATCH 42/64 crypto: ux500 - add missing comma
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Linus Walleij <[email protected]>
commit d47cbd5bcee7c7a08fc0283dda465375fa1b1fda upstream.
Commit 4f31f5b19eb0418a847b989abc9ac22af1991fe2
"PM / crypto / ux500: Use struct dev_pm_ops for power management" add a new line to the driver struct but missed to add a trailing comma, causing build errors when crypto is selected. This adds the missing comma.
This was not noticed until now because the crypto block is not in the ux500 defconfig. A separate patch will be submitted to fix this.
--- drivers/crypto/ux500/cryp/cryp_core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/crypto/ux500/cryp/cryp_core.c +1 -1
@@ -1750,7 +1750,7 @@ static struct platform_driver cryp_drive .shutdown = ux500_cryp_shutdown, .driver = { .owner = THIS_MODULE, - .name = "cryp1" + .name = "cryp1", .pm = &ux500_cryp_pm, } };
Greg Kroah-Hartman
maintainerPATCH 43/64 crypto: gcm - fix assumption that assoc has one segment
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Jussi Kivilinna <[email protected]>
commit d3dde52209ab571e4e2ec26c66f85ad1355f7475 upstream.
rfc4543(gcm(*)) code for GMAC assumes that assoc scatterlist always contains only one segment and only makes use of this first segment. However ipsec passes assoc with three segments when using 'extended sequence number' thus in this case rfc4543(gcm(*)) fails to function correctly. Patch fixes this issue.
--- crypto/gcm.c | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-)
crypto/gcm.c +14 -3
@@ -44,6 +44,7 @@ struct crypto_rfc4543_ctx {struct crypto_rfc4543_req_ctx {u8 auth_tag[16 ]; +u8 assocbuf[32 ];struct scatterlist cipher[1 ];struct scatterlist payload[2 ];struct scatterlist assoc[2 ];
@@ -1142,9 +1143,19 @@ static struct aead_request *crypto_rfc45scatterwalk_crypto_chain (payload, dst, vdst == req->iv +8 ,2 ); assoclen +=8 + req->cryptlen - (enc ?0 : authsize); -sg_init_table (assoc,2 ); -sg_set_page (assoc,sg_page (req->assoc), req->assoc->length, - req->assoc->offset); +if (req->assoc->length == req->assoclen) { +sg_init_table (assoc,2 ); +sg_set_page (assoc,sg_page (req->assoc), req->assoc->length, + req->assoc->offset); + }else { +BUG_ON (req->assoclen >sizeof (rctx->assocbuf)); + +scatterwalk_map_and_copy (rctx->assocbuf, req->assoc,0 , + req->assoclen,0 ); + +sg_init_table (assoc,2 ); +sg_set_buf (assoc, rctx->assocbuf, req->assoclen); + }scatterwalk_crypto_chain (assoc, payload,0 ,2 );aead_request_set_tfm (subreq, ctx->child);
Greg Kroah-Hartman
maintainerPATCH 44/64 drm/mgag200: Index 24 in extended CRTC registers is 24 in hex, not decimal.
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Christopher Harvey <[email protected]>
commit 1812a3db0874be1d1524086da9e84397b800f546 upstream.
This change properly enables the "requester" in G200ER cards that is responsible for getting pixels out of memory and clocking them out to the screen.
--- drivers/gpu/drm/mgag200/mgag200_mode.c | 13 +++---------- 1 file changed, 3 insertions(+), 10 deletions(-)
drivers/gpu/drm/mgag200/mgag200_mode.c +3 -10
@@ -751,8 +751,6 @@ static int mga_crtc_mode_set(struct drm_int i;unsigned char misc =0 ;unsigned char ext_vga[6 ]; -unsigned char ext_vga_index24; -unsigned char dac_index90 =0 ;u8 bppshift;static unsigned char dacvalue[] = {
@@ -803,7 +801,6 @@ static int mga_crtc_mode_set(struct drm_ option2 =0x0000b000 ;break ;case G200_ER : - dac_index90 =0 ;break ; }
@@ -852,10 +849,8 @@ static int mga_crtc_mode_set(struct drm_WREG_DAC (i, dacvalue[i]); } -if (mdev->type ==G200_ER ) { -WREG_DAC (0x90 , dac_index90); - } - +if (mdev->type ==G200_ER ) +WREG_DAC (0x90 ,0 );if (option)pci_write_config_dword (dev->pdev,PCI_MGA_OPTION , option);
@@ -952,8 +947,6 @@ static int mga_crtc_mode_set(struct drm_if (mdev->type ==G200_WB ) ext_vga[1 ] |=0x88 ; - ext_vga_index24 =0x05 ; -/* Set pixel clocks */ misc =0x2d ;WREG8 (MGA_MISC_OUT , misc);
@@ -965,7 +958,7 @@ static int mga_crtc_mode_set(struct drm_ }if (mdev->type ==G200_ER ) -WREG_ECRT (24 , ext_vga_index24); +WREG_ECRT (0x24 ,0x5 );if (mdev->type ==G200_EV ) {WREG_ECRT (6 ,0 );
Greg Kroah-Hartman
maintainerPATCH 45/64 block: avoid using uninitialized value in from queue_var_store
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Arnd Bergmann <[email protected]>
commit c678ef5286ddb5cf70384ad5af286b0afc9b73e1 upstream.
As found by gcc-4.8, the QUEUE_SYSFS_BIT_FNS macro creates functions that use a value generated by queue_var_store independent of whether that value was set or not.
block/blk-sysfs.c: In function 'queue_store_nonrot':block/blk-sysfs.c:244:385: warning: 'val' may be used uninitialized in this function [-Wmaybe-uninitialized]
Unlike most other such warnings, this one is not a false positive, writing any non-number string into the sysfs files indeed has an undefined result, rather than returning an error.
--- block/blk-sysfs.c | 2 ++ 1 file changed, 2 insertions(+)
block/blk-sysfs.c +2 -0
@@ -229,6 +229,8 @@ queue_store_##name(struct request_queueunsigned long val; \ssize_t ret; \ ret =queue_var_store (&val, page, count); \ +if (ret <0 ) \ +return ret; \if (neg) \ val = !val; \ \
Greg Kroah-Hartman
maintainerPATCH 46/64 SUNRPC: Remove extra xprt_put()
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Chuck Lever <[email protected]>
commit a58e0be6f6b3eb2079b0b8fedc9df6fa86869f1e upstream.
While testing error cases where rpc_new_client() fails, I saw some oopses.
If rpc_new_client() fails, it already invokes xprt_put(). Thus __rpc_clone_client() does not need to invoke it again.
Introduced by commit 1b63a751 "SUNRPC: Refactor rpc_clone_client()" Fri Sep 14, 2012.
--- net/sunrpc/clnt.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-)
net/sunrpc/clnt.c +1 -3
@@ -511,7 +511,7 @@ static struct rpc_clnt *__rpc_clone_clie new =rpc_new_client (args, xprt);if (IS_ERR (new)) { err =PTR_ERR (new); - goto out_put; + goto out_err; }atomic_inc (&clnt->cl_count);
@@ -524,8 +524,6 @@ static struct rpc_clnt *__rpc_clone_clie new->cl_chatty = clnt->cl_chatty;return new; -out_put: -xprt_put (xprt); out_err:dprintk ("RPC: %s: returned error %d\n" , __func__, err);return ERR_PTR (err);
Greg Kroah-Hartman
maintainerPATCH 47/64 NFSv4: Fix a memory leak in nfs4_discover_server_trunking
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Trond Myklebust <[email protected]>
commit b193d59a4863ea670872d76dc99231ddeb598625 upstream.
When we assign a new rpc_client to clp->cl_rpcclient, we need to destroy the old one.
--- fs/nfs/nfs4state.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-)
fs/nfs/nfs4state.c +7 -1
@@ -1877,7 +1877,13 @@ again: status =PTR_ERR (clnt);break ; } - clp->cl_rpcclient = clnt; +/* Note: this is safe because we haven't yet marked the +* client as ready, so we are the only user of +* clp->cl_rpcclient +*/ + clnt =xchg (&clp->cl_rpcclient, clnt); +rpc_shutdown_client (clnt); + clnt = clp->cl_rpcclient; goto again;case -NFS4ERR_MINOR_VERS_MISMATCH :
Greg Kroah-Hartman
maintainerPATCH 48/64 NFSv4/4.1: Fix bugs in nfs4[01]_walk_client_list
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Trond Myklebust <[email protected]>
commit 7b1f1fd1842e6ede25183c267ae733a7f67f00bc upstream.
It is unsafe to use list_for_each_entry_safe() here, because when we drop the nn->nfs_client_lock, we pin the _current_ list entry and ensure that it stays in the list, but we don't do the same for the _next_ list entry. Use of list_for_each_entry() is therefore the correct thing to do.
Also fix the refcounting in nfs41_walk_client_list().
Finally, ensure that the nfs_client has finished being initialised and, in the case of NFSv4.1, that the session is set up.
--- fs/nfs/nfs4client.c | 44 ++++++++++++++++++++++++++++---------------- 1 file changed, 28 insertions(+), 16 deletions(-)
fs/nfs/nfs4client.c +28 -16
@@ -300,7 +300,7 @@ int nfs40_walk_client_list(struct nfs_cl struct rpc_cred *cred) {struct nfs_net *nn =net_generic (new->cl_net, nfs_net_id); -struct nfs_client *pos, *n, *prev =NULL ; +struct nfs_client *pos, *prev =NULL ;struct nfs4_setclientid_res clid = { .clientid = new->cl_clientid, .confirm = new->cl_confirm,
@@ -308,10 +308,23 @@ int nfs40_walk_client_list(struct nfs_clint status = -NFS4ERR_STALE_CLIENTID ;spin_lock (&nn->nfs_client_lock); -list_for_each_entry_safe (pos, n, &nn->nfs_client_list, cl_share_link) { +list_for_each_entry (pos, &nn->nfs_client_list, cl_share_link) {/* If "pos" isn't marked ready, we can't trust the * remaining fields in "pos" */ -if (pos->cl_cons_state <NFS_CS_READY ) +if (pos->cl_cons_state >NFS_CS_READY ) { +atomic_inc (&pos->cl_count); +spin_unlock (&nn->nfs_client_lock); + +if (prev) +nfs_put_client (prev); + prev = pos; + + status =nfs_wait_client_init_complete (pos); +spin_lock (&nn->nfs_client_lock); +if (status <0 ) +continue ; + } +if (pos->cl_cons_state !=NFS_CS_READY )continue ;if (pos->rpc_ops != new->rpc_ops)
@@ -423,16 +436,16 @@ int nfs41_walk_client_list(struct nfs_cl struct rpc_cred *cred) {struct nfs_net *nn =net_generic (new->cl_net, nfs_net_id); -struct nfs_client *pos, *n, *prev =NULL ; +struct nfs_client *pos, *prev =NULL ;int status = -NFS4ERR_STALE_CLIENTID ;spin_lock (&nn->nfs_client_lock); -list_for_each_entry_safe (pos, n, &nn->nfs_client_list, cl_share_link) { +list_for_each_entry (pos, &nn->nfs_client_list, cl_share_link) {/* If "pos" isn't marked ready, we can't trust the * remaining fields in "pos", especially the client * ID and serverowner fields. Wait for CREATE_SESSION * to finish. */ -if (pos->cl_cons_state <NFS_CS_READY ) { +if (pos->cl_cons_state >NFS_CS_READY ) {atomic_inc (&pos->cl_count);spin_unlock (&nn->nfs_client_lock);
@@ -440,18 +453,17 @@ int nfs41_walk_client_list(struct nfs_clnfs_put_client (prev); prev = pos; -nfs4_schedule_lease_recovery (pos); status =nfs_wait_client_init_complete (pos); -if (status <0 ) { -nfs_put_client (pos); -spin_lock (&nn->nfs_client_lock); -continue ; +if (status ==0 ) { +nfs4_schedule_lease_recovery (pos); + status =nfs4_wait_clnt_recover (pos); } - status = pos->cl_cons_state;spin_lock (&nn->nfs_client_lock);if (status <0 )continue ; } +if (pos->cl_cons_state !=NFS_CS_READY ) +continue ;if (pos->rpc_ops != new->rpc_ops)continue ;
@@ -469,17 +481,17 @@ int nfs41_walk_client_list(struct nfs_clcontinue ;atomic_inc (&pos->cl_count); -spin_unlock (&nn->nfs_client_lock); + *result = pos;dprintk ("NFS: <-- %s using nfs_client = %p ({%d})\n" , __func__, pos,atomic_read (&pos->cl_count)); - - *result = pos; - return 0; + break; }/* No matching nfs_client found. */ spin_unlock (&nn->nfs_client_lock);dprintk ("NFS: <-- %s status = %d\n" , __func__, status); +if (prev) +nfs_put_client (prev);return status; }#endif /* CONFIG_NFS_V4_1 */
Greg Kroah-Hartman
maintainerPATCH 49/64 drm/i915: Fix build failure
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Lauri Kasanen <[email protected]>
commit 27b7c63a7c509d797c151e95a641e1d94d94bbd9 upstream.
ERROR: "__build_bug_on_failed" [drivers/gpu/drm/i915/i915.ko] undefined!
Originally reported at http://www.gossamer-threads.com/lists/linux/kernel/1631803
FDO bug #62775
This needs to be backported to both 3.7 and 3.8 stable trees. Doesn't apply straight, but it's a quick change.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=62775
--- drivers/gpu/drm/i915/i915_gem_execbuffer.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpu/drm/i915/i915_gem_execbuffer.c +1 -1
@@ -43,7 +43,7 @@ eb_create(int size) {struct eb_objects *eb;int count =PAGE_SIZE /sizeof (struct hlist_head ) /2 ; -BUILD_BUG_ON (!is_power_of_2 (PAGE_SIZE /sizeof (struct hlist_head ))); +BUILD_BUG_ON_NOT_POWER_OF_2 (PAGE_SIZE /sizeof (struct hlist_head ));while (count > size) count >>=1 ; eb = kzalloc(count*sizeof(struct hlist_head) +
Greg Kroah-Hartman
maintainerPATCH 50/64 x86: Fix rebuild with EFI_STUB enabled
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Jan Beulich <[email protected]>
commit 918708245e92941df16a634dc201b407d12bcd91 upstream.
eboot.o and efi_stub_$(BITS).o didn't get added to "targets", and hence their .cmd files don't get included by the build machinery, leading to the files always getting rebuilt.
Rather than adding the two files individually, take the opportunity and add $(VMLINUX_OBJS) to "targets" instead, thus allowing the assignment at the top of the file to be shrunk quite a bit.
At the same time, remove a pointless flags override line - the variable assigned to was misspelled anyway, and the options added are meaningless for assembly sources.
[ hpa: the patch is not minimal, but I am taking it for -urgent anyway
since the excess impact of the patch seems to be small enough. ]
--- arch/x86/boot/compressed/Makefile | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-)
arch/x86/boot/compressed/Makefile +2 -3
@@ -4,7 +4,7 @@ # create a compressed vmlinux image from the original vmlinux # -targets := vmlinux.lds vmlinux vmlinux.bin vmlinux.bin.gz vmlinux.bin.bz2 vmlinux.bin.lzma vmlinux.bin.xz vmlinux.bin.lzo head_$(BITS).o misc.o string.o cmdline.o early_serial_console.o piggy.o +targets := vmlinux vmlinux.bin vmlinux.bin.gz vmlinux.bin.bz2 vmlinux.bin.lzma vmlinux.bin.xz vmlinux.bin.lzo KBUILD_CFLAGS := -m$(BITS) -D__KERNEL__ $(LINUX_INCLUDE) -O2 KBUILD_CFLAGS += -fno-strict-aliasing -fPIC
@@ -29,7 +29,6 @@ VMLINUX_OBJS = $(obj)/vmlinux.lds $(obj) $(obj)/piggy.o $(obj)/eboot.o: KBUILD_CFLAGS += -fshort-wchar -mno-red-zone -$(obj)/efi_stub_$(BITS).o: KBUILD_CLFAGS += -fshort-wchar -mno-red-zone ifeq ($(CONFIG_EFI_STUB), y) VMLINUX_OBJS += $(obj)/eboot.o $(obj)/efi_stub_$(BITS).o
@@ -43,7 +42,7 @@ OBJCOPYFLAGS_vmlinux.bin := -R .comment $(obj)/vmlinux.bin: vmlinux FORCE $(call if_changed,objcopy) -targets += vmlinux.bin.all vmlinux.relocs +targets += $(patsubst $(obj)/%,%,$(VMLINUX_OBJS)) vmlinux.bin.all vmlinux.relocs CMD_RELOCS = arch/x86/tools/relocs quiet_cmd_relocs = RELOCS $@
Greg Kroah-Hartman
maintainerPATCH 51/64 Revert "PCI/ACPI: Request _OSC control before scanning PCI root bus"
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Bjorn Helgaas <[email protected]>
commit b8178f130e25c1bdac1c33e0996f1ff6e20ec08e upstream.
This reverts commit 8c33f51df406e1a1f7fa4e9b244845b7ebd61fa6.
Conflicts:
drivers/acpi/pci_root.c
This commit broke some pre-1.1 PCIe devices by leaving them with ASPM enabled. Previously, we had disabled ASPM on these devices because many of them don't implement it correctly (per 149e1637).
Requesting _OSC control early means that aspm_disabled may be set before we scan the PCI bus and configure link ASPM state. But the ASPM configuration currently skips the check for pre-PCIe 1.1 devices when aspm_disabled is set, like this:
acpi_pci_root_add
acpi_pci_osc_support
if (flags != base_flags)
pcie_no_aspm
aspm_disabled = 1
pci_acpi_scan_root
...
pcie_aspm_init_link_state
pcie_aspm_sanity_check
if (!aspm_disabled)
/* check for pre-PCIe 1.1 device */Therefore, setting aspm_disabled early means that we leave ASPM enabled on these pre-PCIe 1.1 devices, which is a regression for some devices.
The best fix would be to clean up the ASPM init so we can evaluate _OSC before scanning the bug (that way boot-time and hot-add discovery will work the same), but that requires significant rework.
For now, we'll just revert the _OSC change as the lowest-risk fix.
Reference: https://bugzilla.kernel.org/show_bug.cgi?id=55211
--- drivers/acpi/pci_root.c | 121 +++++++++++++++++++++++------------------------- 1 file changed, 59 insertions(+), 62 deletions(-)
drivers/acpi/pci_root.c +59 -62
@@ -454,7 +454,6 @@ static int acpi_pci_root_add(struct acpiacpi_handle handle;struct acpi_device *child;u32 flags, base_flags; -bool is_osc_granted = false; root =kzalloc (sizeof (struct acpi_pci_root ),GFP_KERNEL );if (!root)
@@ -525,60 +524,6 @@ static int acpi_pci_root_add(struct acpi flags = base_flags =OSC_PCI_SEGMENT_GROUPS_SUPPORT ;acpi_pci_osc_support (root, flags); -/* Indicate support for various _OSC capabilities. */ -if (pci_ext_cfg_avail ()) - flags |=OSC_EXT_PCI_CONFIG_SUPPORT ; -if (pcie_aspm_support_enabled ()) { - flags |=OSC_ACTIVE_STATE_PWR_SUPPORT | -OSC_CLOCK_PWR_CAPABILITY_SUPPORT ; - } -if (pci_msi_enabled ()) - flags |=OSC_MSI_SUPPORT ; -if (flags != base_flags) { - status =acpi_pci_osc_support (root, flags); -if (ACPI_FAILURE (status)) { -dev_info (&device->dev,"ACPI _OSC support " -"notification failed, disabling PCIe ASPM\n" ); -pcie_no_aspm (); - flags = base_flags; - } - } -if (!pcie_ports_disabled - && (flags &ACPI_PCIE_REQ_SUPPORT ) ==ACPI_PCIE_REQ_SUPPORT ) { - flags =OSC_PCI_EXPRESS_CAP_STRUCTURE_CONTROL - |OSC_PCI_EXPRESS_NATIVE_HP_CONTROL - |OSC_PCI_EXPRESS_PME_CONTROL ; - -if (pci_aer_available ()) { -if (aer_acpi_firmware_first ()) -dev_dbg (&device->dev, -"PCIe errors handled by BIOS.\n" ); -else - flags |=OSC_PCI_EXPRESS_AER_CONTROL ; - } - -dev_info (&device->dev, -"Requesting ACPI _OSC control (0x%02x)\n" , flags); - - status =acpi_pci_osc_control_set (device->handle, &flags, -OSC_PCI_EXPRESS_CAP_STRUCTURE_CONTROL ); -if (ACPI_SUCCESS (status)) { - is_osc_granted = true; -dev_info (&device->dev, -"ACPI _OSC control (0x%02x) granted\n" , flags); - }else { - is_osc_granted = false; -dev_info (&device->dev, -"ACPI _OSC request failed (%s), " -"returned control mask: 0x%02x\n" , -acpi_format_exception (status), flags); - } - }else { -dev_info (&device->dev, -"Unable to request _OSC control " -"(_OSC support mask: 0x%02x)\n" , flags); - } -/* * TBD: Need PCI interface for enumeration/configuration of roots. */
@@ -618,14 +563,66 @@ static int acpi_pci_root_add(struct acpilist_for_each_entry (child, &device->children, node)acpi_pci_bridge_scan (child); -/* ASPM setting */ -if (is_osc_granted) { -if (acpi_gbl_FADT.boot_flags &ACPI_FADT_NO_ASPM ) -pcie_clear_aspm (root->bus); +/* Indicate support for various _OSC capabilities. */ +if (pci_ext_cfg_avail ()) + flags |=OSC_EXT_PCI_CONFIG_SUPPORT ; +if (pcie_aspm_support_enabled ()) + flags |=OSC_ACTIVE_STATE_PWR_SUPPORT | +OSC_CLOCK_PWR_CAPABILITY_SUPPORT ; +if (pci_msi_enabled ()) + flags |=OSC_MSI_SUPPORT ; +if (flags != base_flags) { + status =acpi_pci_osc_support (root, flags); +if (ACPI_FAILURE (status)) { +dev_info (root->bus->bridge,"ACPI _OSC support " +"notification failed, disabling PCIe ASPM\n" ); +pcie_no_aspm (); + flags = base_flags; + } + } + +if (!pcie_ports_disabled + && (flags &ACPI_PCIE_REQ_SUPPORT ) ==ACPI_PCIE_REQ_SUPPORT ) { + flags =OSC_PCI_EXPRESS_CAP_STRUCTURE_CONTROL + |OSC_PCI_EXPRESS_NATIVE_HP_CONTROL + |OSC_PCI_EXPRESS_PME_CONTROL ; + +if (pci_aer_available ()) { +if (aer_acpi_firmware_first ()) +dev_dbg (root->bus->bridge, +"PCIe errors handled by BIOS.\n" ); +else + flags |=OSC_PCI_EXPRESS_AER_CONTROL ; + } + +dev_info (root->bus->bridge, +"Requesting ACPI _OSC control (0x%02x)\n" , flags); + + status =acpi_pci_osc_control_set (device->handle, &flags, +OSC_PCI_EXPRESS_CAP_STRUCTURE_CONTROL ); +if (ACPI_SUCCESS (status)) { +dev_info (root->bus->bridge, +"ACPI _OSC control (0x%02x) granted\n" , flags); +if (acpi_gbl_FADT.boot_flags &ACPI_FADT_NO_ASPM ) { +/* +* We have ASPM control, but the FADT indicates +* that it's unsupported. Clear it. +*/ +pcie_clear_aspm (root->bus); + } + }else { +dev_info (root->bus->bridge, +"ACPI _OSC request failed (%s), " +"returned control mask: 0x%02x\n" , +acpi_format_exception (status), flags); +pr_info ("ACPI _OSC control for PCIe not granted, " +"disabling ASPM\n" ); +pcie_no_aspm (); + } }else { -pr_info ("ACPI _OSC control for PCIe not granted, " -"disabling ASPM\n" ); -pcie_no_aspm (); +dev_info (root->bus->bridge, +"Unable to request _OSC control " +"(_OSC support mask: 0x%02x)\n" , flags); }pci_acpi_add_bus_pm_notifier (device, root->bus);
Greg Kroah-Hartman
maintainerPATCH 52/64 thermal: return an error on failure to register thermal class
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Richard Guy Briggs <[email protected]>
commit da28d966f6aa942ae836d09729f76a1647932309 upstream.
The return code from the registration of the thermal class is used to unallocate resources, but this failure isn't passed back to the caller of thermal_init. Return this failure back to the caller.
This bug was introduced in changeset 4cb18728 which overwrote the return code when the variable was re-used to catch the return code of the registration of the genetlink thermal socket family.
--- drivers/thermal/thermal_sys.c | 1 + 1 file changed, 1 insertion(+)
drivers/thermal/thermal_sys.c +1 -0
@@ -1807,6 +1807,7 @@ static int __init thermal_init(void)idr_destroy (&thermal_cdev_idr);mutex_destroy (&thermal_idr_lock);mutex_destroy (&thermal_list_lock); +return result; } result =genetlink_init ();return result;
Greg Kroah-Hartman
maintainerPATCH 53/64 msi-wmi: Fix memory leak
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Maxim Mikityanskiy <[email protected]>
commit 51c94491c82c3d9029f6e87a1a153db321d88e35 upstream.
Fix memory leak - don't forget to kfree ACPI object when returning from msi_wmi_notify() after suppressing key event.
--- drivers/platform/x86/msi-wmi.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
drivers/platform/x86/msi-wmi.c +3 -1
@@ -176,7 +176,7 @@ static void msi_wmi_notify(u32 value, vopr_debug ("Suppressed key event 0x%X - " "Last press was %lld us ago\n" , key->code,ktime_to_us (diff)); -return ; + goto msi_wmi_notify_exit; } last_pressed[key->code -SCANCODE_BASE ] = cur;
@@ -195,6 +195,8 @@ static void msi_wmi_notify(u32 value, vopr_info ("Unknown key pressed - %x\n" , eventcode); }else pr_info ("Unknown event received\n" ); + +msi_wmi_notify_exit:kfree (response.pointer); }
Greg Kroah-Hartman
maintainerPATCH 54/64 cpufreq: exynos: Get booting freq value in exynos_cpufreq_init
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Jonghwan Choi <[email protected]>
commit 6e45eb12fd1c741d556bf264ee98853b5f3104e5 upstream.
Boot_freq is for saving booting freq. But exynos_cpufreq_cpu_init is called in hotplug. If boot_freq is existed in exynos_cpufreq_cpu_init, boot_freq could be changed.
--- drivers/cpufreq/exynos-cpufreq.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/cpufreq/exynos-cpufreq.c +2 -2
@@ -222,8 +222,6 @@ static int exynos_cpufreq_cpu_init(struccpufreq_frequency_table_get_attr (exynos_info->freq_table, policy->cpu); - locking_frequency =exynos_getspeed (0 ); -/* set the transition latency value */ policy->cpuinfo.transition_latency =100000 ;
@@ -288,6 +286,8 @@ static int __init exynos_cpufreq_init(vo goto err_vdd_arm; } + locking_frequency =exynos_getspeed (0 ); +register_pm_notifier (&exynos_cpufreq_nb);if (cpufreq_register_driver (&exynos_driver)) {
Greg Kroah-Hartman
maintainerPATCH 55/64 ARM: EXYNOS: Fix crash on soft reset on EXYNOS5440
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Thomas Abraham <[email protected]>
commit 60db7e5f9c9a25a7a9b01007e6e3f5a93bc16a3a upstream.
The soft-reset control register is located in the XMU controller space. Map this controller space before writing to the soft-reset controller register.
--- arch/arm/mach-exynos/common.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-)
arch/arm/mach-exynos/common.c +4 -2
@@ -299,6 +299,7 @@ void exynos4_restart(char mode, const chvoid exynos5_restart (char mode,const char *cmd) { +struct device_node *np;u32 val;void __iomem *addr;
@@ -306,8 +307,9 @@ void exynos5_restart(char mode, const ch val =0x1 ; addr =EXYNOS_SWRESET ; }else if (of_machine_is_compatible ("samsung,exynos5440" )) { - val = (0x10 <<20 ) | (0x1 <<16 ); - addr =EXYNOS5440_SWRESET ; + np =of_find_compatible_node (NULL ,NULL ,"samsung,exynos5440-clock" ); + addr =of_iomap (np,0 ) +0xcc ; + val = (0xfff <<20 ) | (0x1 <<16 ); }else {pr_err ("%s: cannot support non-DT\n" , __func__);return ;
Greg Kroah-Hartman
maintainerPATCH 56/64 drm/i915: add quirk to invert brightness on eMachines G725
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Jani Nikula <[email protected]>
commit 1ffff60320879830e469e26062c18f75236822ba upstream.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=59628
--- drivers/gpu/drm/i915/intel_display.c | 3 +++ 1 file changed, 3 insertions(+)
drivers/gpu/drm/i915/intel_display.c +3 -0
@@ -8901,6 +8901,9 @@ static struct intel_quirk intel_quirks[]/* Acer Aspire 4736Z */ { 0x2a42, 0x1025, 0x0260, quirk_invert_brightness }, + +/* Acer/eMachines G725 */ + { 0x2a42, 0x1025, 0x0210, quirk_invert_brightness }, };static void intel_init_quirks (struct drm_device *dev)
Greg Kroah-Hartman
maintainerPATCH 57/64 drm/i915: add quirk to invert brightness on eMachines e725
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Jani Nikula <[email protected]>
commit 01e3a8feb40e54b962a20fa7eb595c5efef5e109 upstream.
Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=31522#c35
--- drivers/gpu/drm/i915/intel_display.c | 3 +++ 1 file changed, 3 insertions(+)
drivers/gpu/drm/i915/intel_display.c +3 -0
@@ -8904,6 +8904,9 @@ static struct intel_quirk intel_quirks[]/* Acer/eMachines G725 */ { 0x2a42, 0x1025, 0x0210, quirk_invert_brightness }, + +/* Acer/eMachines e725 */ + { 0x2a42, 0x1025, 0x0212, quirk_invert_brightness }, };static void intel_init_quirks (struct drm_device *dev)
Greg Kroah-Hartman
maintainerPATCH 58/64 drm/i915: add quirk to invert brightness on Packard Bell NCL20
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Jani Nikula <[email protected]>
commit 5559ecadad5a73b27f863e92f4b4f369501dce6f upstream.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=44156
--- drivers/gpu/drm/i915/intel_display.c | 3 +++ 1 file changed, 3 insertions(+)
drivers/gpu/drm/i915/intel_display.c +3 -0
@@ -8907,6 +8907,9 @@ static struct intel_quirk intel_quirks[]/* Acer/eMachines e725 */ { 0x2a42, 0x1025, 0x0212, quirk_invert_brightness }, + +/* Acer/Packard Bell NCL20 */ + { 0x2a42, 0x1025, 0x034b, quirk_invert_brightness }, };static void intel_init_quirks (struct drm_device *dev)
Greg Kroah-Hartman
maintainerPATCH 59/64 r8169: fix auto speed down issue
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: hayeswang <[email protected]>
commit e2409d83434d77874b461b78af6a19cd6e6a1280 upstream.
It would cause no link after suspending or shutdowning when the nic changes the speed to 10M and connects to a link partner which forces the speed to 100M.
Check the link partner ability to determine which speed to set.
--- drivers/net/ethernet/realtek/r8169.c | 28 +++++++++++++++++++++++++--- 1 file changed, 25 insertions(+), 3 deletions(-)
drivers/net/ethernet/realtek/r8169.c +25 -3
@@ -3819,6 +3819,30 @@ static void rtl_init_mdio_ops(struct rtl } } +static void rtl_speed_down (struct rtl8169_private *tp) +{ +u32 adv; +int lpa; + +rtl_writephy (tp,0x1f ,0x0000 ); + lpa =rtl_readphy (tp,MII_LPA ); + +if (lpa & (LPA_10HALF |LPA_10FULL )) + adv = ADVERTISED_10baseT_Half | ADVERTISED_10baseT_Full; +else if (lpa & (LPA_100HALF |LPA_100FULL )) + adv = ADVERTISED_10baseT_Half | ADVERTISED_10baseT_Full | + ADVERTISED_100baseT_Half | ADVERTISED_100baseT_Full; +else + adv = ADVERTISED_10baseT_Half | ADVERTISED_10baseT_Full | + ADVERTISED_100baseT_Half | ADVERTISED_100baseT_Full | + (tp->mii.supports_gmii ? + ADVERTISED_1000baseT_Half | + ADVERTISED_1000baseT_Full :0 ); + +rtl8169_set_speed (tp->dev,AUTONEG_ENABLE ,SPEED_1000 ,DUPLEX_FULL , + adv); +} +static void rtl_wol_suspend_quirk (struct rtl8169_private *tp) {void __iomem *ioaddr = tp->mmio_addr;
@@ -3849,9 +3873,7 @@ static bool rtl_wol_pll_power_down(strucif (!(__rtl8169_get_wol (tp) &WAKE_ANY ))return false; -rtl_writephy (tp,0x1f ,0x0000 ); -rtl_writephy (tp,MII_BMCR ,0x0000 ); - +rtl_speed_down (tp);rtl_wol_suspend_quirk (tp);return true;
Greg Kroah-Hartman
maintainerPATCH 60/64 vfio-pci: Fix possible integer overflow
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Alex Williamson <[email protected]>
commit 904c680c7bf016a8619a045850937427f8d7368c upstream.
The VFIO_DEVICE_SET_IRQS ioctl takes a start and count parameter, both of which are unsigned. We attempt to bounds check these, but fail to account for the case where start is a very large number, allowing start + count to wrap back into the valid range. Bounds check both start and start + count.
--- drivers/vfio/pci/vfio_pci.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
drivers/vfio/pci/vfio_pci.c +2 -1
@@ -331,6 +331,7 @@ static long vfio_pci_ioctl(void *device_if (!(hdr.flags &VFIO_IRQ_SET_DATA_NONE )) {size_t size; +int max =vfio_pci_get_irq_count (vdev, hdr.index);if (hdr.flags &VFIO_IRQ_SET_DATA_BOOL ) size =sizeof (uint8_t );
@@ -340,7 +341,7 @@ static long vfio_pci_ioctl(void *device_return -EINVAL ;if (hdr.argsz - minsz < hdr.count * size || - hdr.count >vfio_pci_get_irq_count (vdev, hdr.index)) + hdr.start >= max || hdr.start + hdr.count > max)return -EINVAL ; data = memdup_user((void __user *)(arg + minsz),
Greg Kroah-Hartman
maintainerPATCH 61/64 NFSv4: Doh! Typo in the fix to nfs41_walk_client_list
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Trond Myklebust <[email protected]>
commit eb04e0ac198cec3bab407ad220438dfa65c19c67 upstream.
Make sure that we set the status to 0 on success. Missed in testing because it never appears when doing multiple mounts to _different_ servers.
--- fs/nfs/nfs4client.c | 1 + 1 file changed, 1 insertion(+)
fs/nfs/nfs4client.c +1 -0
@@ -482,6 +482,7 @@ int nfs41_walk_client_list(struct nfs_clatomic_inc (&pos->cl_count); *result = pos; + status =0 ;dprintk ("NFS: <-- %s using nfs_client = %p ({%d})\n" , __func__, pos,atomic_read (&pos->cl_count));break ;
Greg Kroah-Hartman
maintainerPATCH 62/64 can: gw: use kmem_cache_free() instead of kfree()
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Wei Yongjun <[email protected]>
commit 3480a2125923e4b7a56d79efc76743089bf273fc upstream.
Memory allocated by kmem_cache_alloc() should be freed using kmem_cache_free(), not kfree().
--- net/can/gw.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
net/can/gw.c +3 -3
@@ -436,7 +436,7 @@ static int cgw_notifier(struct notifier_if (gwj->src.dev == dev || gwj->dst.dev == dev) {hlist_del (&gwj->list);cgw_unregister_filter (gwj); -kfree (gwj); +kmem_cache_free (cgw_cache, gwj); } } }
@@ -829,7 +829,7 @@ static void cgw_remove_all_jobs(void)hlist_for_each_entry_safe (gwj, n, nx, &cgw_list, list) {hlist_del (&gwj->list);cgw_unregister_filter (gwj); -kfree (gwj); +kmem_cache_free (cgw_cache, gwj); } }
@@ -885,7 +885,7 @@ static int cgw_remove_job(struct sk_buffhlist_del (&gwj->list);cgw_unregister_filter (gwj); -kfree (gwj); +kmem_cache_free (cgw_cache, gwj); err =0 ;break ; }
Greg Kroah-Hartman
maintainerPATCH 63/64 mwifiex: complete last internal scan
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Bing Zhao <[email protected]>
commit 21de979ecfc7b7f9442f8aea9a54b3ab670d0151 upstream.
We are waiting on first scan command of internal scan request before association, so we should complete on last internal scan command response.
--- drivers/net/wireless/mwifiex/scan.c | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-)
drivers/net/wireless/mwifiex/scan.c +9 -2
@@ -1371,8 +1371,10 @@ int mwifiex_scan_networks(struct mwifiexqueue_work (adapter->workqueue, &adapter->main_work);/* Perform internal scan synchronously */ -if (!priv->scan_request) +if (!priv->scan_request) { +dev_dbg (adapter->dev,"wait internal scan\n" );mwifiex_wait_queue_complete (adapter, cmd_node); + } }else {spin_unlock_irqrestore (&adapter->scan_pending_q_lock, flags);
@@ -1768,7 +1770,12 @@ check_next_scan:/* Need to indicate IOCTL complete */ if (adapter->curr_cmd->wait_q_enabled) { adapter->cmd_wait_q.status =0 ; -mwifiex_complete_cmd (adapter, adapter->curr_cmd); +if (!priv->scan_request) { +dev_dbg (adapter->dev, +"complete internal scan\n" ); +mwifiex_complete_cmd (adapter, + adapter->curr_cmd); + } }if (priv->report_scan_result) priv->report_scan_result = false;
Greg Kroah-Hartman
maintainerPATCH 64/64 rt2x00: rt2x00pci_regbusy_read() - only print register access failure once
In reply to Greg Kroah-Hartman3.8-stable review patch. If anyone has any objections, please let me know.
------------------
From: Tim Gardner <[email protected]>
commit 83589b30f1e1dc9898986293c9336b8ce1705dec upstream.
It appears that when this register read fails it never recovers, so I think there is no need to repeat the same error message ad infinitum.
--- drivers/net/wireless/rt2x00/rt2x00pci.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/net/wireless/rt2x00/rt2x00pci.c +2 -2
@@ -52,8 +52,8 @@ int rt2x00pci_regbusy_read(struct rt2x00udelay (REGISTER_BUSY_DELAY ); } -ERROR (rt2x00dev,"Indirect register access failed: " -"offset=0x%.08x, value=0x%.08x\n" , offset, *reg); +printk_once (KERN_ERR "%s() Indirect register access failed: " +"offset=0x%.08x, value=0x%.08x\n" , __func__, offset, *reg); *reg = ~0 ;return 0 ;
Quoted 8 lines · Greg Kroah-Hartman
This is the start of the stable review cycle for the 3.8.7 release. There are 64 patches in this series, all will be posted as a response to this one. If anyone has any issues with these being applied, please let me know.
Responses should be made by Fri Apr 12 22:41:50 UTC 2013. Anything received after that time might be too late.
Quoted 8 lines
The whole patch series can be found in one patch at:
kernel.org/pub/linux/kernel/v3.0/stable-review/patch-3.8.7-rc1.gzand the diffstat can be found below.
thanks,
greg k-h
Patches applied cleanly to 3.0.72, 3.4.39, and 3.8.6
Reviewing patches - will let you know anything odd.
Compiled and booted on the following systems:
HP ProBook 6475b AMD A10-4600M APU with Radeon(tm) HD Graphics Hewlett-Packard HP Compaq dc7700
dmesgs for all releases look good. No regressions compared to the previous dmesgs for each of these releases.
Cross-compile tests results:
alpha: defconfig passed on all
arm: defconfig passed on all
arm64: not applicable to 3.0.y, 3.4.y. defconfig passed on 3.8.y
c6x: not applicable to 3.0.y, defconfig passed on 3.4.y, and 3.8.y.
mips: defconfig passed on all
mipsel: defconfig passed on all
powerpc: wii_defconfig passed on all
sh: defconfig passed on all
sparc: defconfig passed on all
tile: tilegx_defconfig passed on all
-- Shuah
Greg Kroah-Hartman
maintainerQuoted 14 lines · Shuah Khan
Quoted 12 lines · Greg Kroah-Hartman
This is the start of the stable review cycle for the 3.8.7 release. There are 64 patches in this series, all will be posted as a response to this one. If anyone has any issues with these being applied, please let me know.
Responses should be made by Fri Apr 12 22:41:50 UTC 2013. Anything received after that time might be too late.
The whole patch series can be found in one patch at:
kernel.org/pub/linux/kernel/v3.0/stable-review/patch-3.8.7-rc1.gzand the diffstat can be found below.
Quoted 7 lines
Quoted 4 lines
thanks,
greg k-h
Patches applied cleanly to 3.0.72, 3.4.39, and 3.8.6
Reviewing patches - will let you know anything odd.
Thanks for testing and letting us know.
greg k-h