01 Jul, 2011
1 commit
-
The perf_event overflow handler does not receive any caller-derived
argument, so many callers need to resort to looking up the perf_event
in their local data structure. This is ugly and doesn't scale if a
single callback services many perf_events.Fix by adding a context parameter to perf_event_create_kernel_counter()
(and derived hardware breakpoints APIs) and storing it in the perf_event.
The field can be accessed from the callback as event->overflow_handler_context.
All callers are updated.Signed-off-by: Avi Kivity
Signed-off-by: Peter Zijlstra
Link: http://lkml.kernel.org/r/1309362157-6596-2-git-send-email-avi@redhat.com
Signed-off-by: Ingo Molnar
28 Jun, 2011
12 commits
-
When auditing the locking in i915_gem.c (for a prospective change which
I then abandoned), I noticed two places where struct_mutex is not held
across GEM object manipulations that would usually require it.Since one is in initial setup and the other in driver unload, I'm
guessing the mutex is not required for either; but post a patch in case
it is.Signed-off-by: Hugh Dickins
Cc: Chris Wilson
Cc: Keith Packard
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
The interface to ->truncate_range is changing very slightly: once "tmpfs:
take control of its truncate_range" has been applied, this can be applied.
For now there is only a slight inefficiency while this remains unapplied,
but it will soon become essential for managing shmem's use of swap.Change i915_gem_object_truncate() to use shmem_truncate_range() directly:
which should also spare i915 later change if we switch from
inode_operations->truncate_range to file_operations->fallocate.Signed-off-by: Hugh Dickins
Cc: Christoph Hellwig
Cc: Chris Wilson
Cc: Keith Packard
Cc: Dave Airlie
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Soon tmpfs will stop supporting ->readpage and read_cache_page_gfp(): once
"tmpfs: add shmem_read_mapping_page_gfp" has been applied, this patch can
be applied to ease the transition.Make i915_gem_object_get_pages_gtt() use shmem_read_mapping_page_gfp() in
the one place it's needed; elsewhere use shmem_read_mapping_page(), with
the mapping's gfp_mask properly initialized.Forget about __GFP_COLD: since tmpfs initializes its pages with memset,
asking for a cold page is counter-productive.Include linux/shmem_fs.h also in drm_gem.c: with shmem_file_setup() now
declared there too, we shall remove the prototype from linux/mm.h later.Signed-off-by: Hugh Dickins
Cc: Christoph Hellwig
Cc: Chris Wilson
Cc: Keith Packard
Cc: Dave Airlie
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Soon tmpfs will stop supporting ->readpage and read_mapping_page(): once
"tmpfs: add shmem_read_mapping_page_gfp" has been applied, this patch can
be applied to ease the transition.ttm_tt_swapin() and ttm_tt_swapout() use shmem_read_mapping_page() in
place of read_mapping_page(), since their swap_space has been created with
shmem_file_setup().Signed-off-by: Hugh Dickins
Cc: Christoph Hellwig
Cc: Thomas Hellstrom
Cc: Dave Airlie
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Fis the warning
drivers/tty/serial/8250_pci.c:1457: warning: initialization from incompatible pointer type
Cc: Greg KH
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Fix this section mismatch:
WARNING: drivers/misc/ioc4.o(.data+0x144): Section mismatch in reference from the variable ioc4_load_modules_work to the function .devinit.text:ioc4_load_modules()
The variable ioc4_load_modules_work references
the function __devinit ioc4_load_modules()
If the reference is valid then annotate the
variable with __init* or __refdata (see linux/init.h) or name the variable:
*driver, *_template, *_timer, *_sht, *_ops, *_probe, *_probe_one, *_consoleThis one is potentially fatal; by the time ioc4_load_modules is invoked
it may already have been freed. For that reason ioc4_load_modules_work
can't be turned to __devinitdata but also because it's referenced in
ioc4_exit.Signed-off-by: Ralf Baechle
Acked-by: Brent Casavant
Cc: Tejun Heo
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Fix this section mismatch:
WARNING: drivers/leds/leds-lp5523.o(.text+0x12f4): Section mismatch in reference from the function lp5523_probe() to the function .init.text:lp5523_init_led()
The function lp5523_probe() references
the function __init lp5523_init_led().
This is often because lp5523_probe lacks a __init
annotation or the annotation of lp5523_init_led is wrong.Fixing this one triggers one more mismatch, fix that one as well.
Signed-off-by: Ralf Baechle
Cc: Richard Purdie
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Fix this section mismatch:
WARNING: drivers/leds/leds-lp5521.o(.text+0xf2c): Section mismatch in reference from the function lp5521_probe() to the function .init.text:lp5521_init_led()
The function lp5521_probe() references
the function __init lp5521_init_led().
This is often because lp5521_probe lacks a __init
annotation or the annotation of lp5521_init_led is wrong.Fixing this mismatch triggers one more mismatch, fix that one as well.
Signed-off-by: Ralf Baechle
Cc: Richard Purdie
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
We observed the crash point count going negative in cases where the
crash point is hit multiple times before the check of "count == 0" is
done. Because of this we never call lkdtm_do_action(). This patch just
adds a spinlock to protect count.Reported-by: Tapan Dhimant
Signed-off-by: Josh Hunt
Acked-by: Ankita Garg
Cc:
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
PT7C4338 chip is being manufactured by Pericom Technology Inc. It is a
serial real-time clock which provides:1) Low-power clock/calendar.
2) Programmable square-wave output.It has 56 bytes of nonvolatile RAM. Its register set is same as that of
rtc device: DS1307.Signed-off-by: Priyanka Jain
Acked-by: Timur Tabi
Reviewed-by: Wolfram Sang
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/cjb/mmc:
mmc: queue: bring discard_granularity/alignment into line with SCSI
mmc: queue: append partition subname to queue thread name
mmc: core: make erase timeout calculation allow for gated clock
mmc: block: switch card to User Data Area when removing the block driver
mmc: sdio: reset card during power_restore
mmc: cb710: fix #ifdef HAVE_EFFICIENT_UNALIGNED_ACCESS
mmc: sdhi: DMA slave ID 0 is invalid
mmc: tmio: fix regression in TMIO_MMC_WRPROTECT_DISABLE handling
mmc: omap_hsmmc: use original sg_len for dma_unmap_sg
mmc: omap_hsmmc: fix ocr mask usage
mmc: sdio: fix runtime PM path during driver removal
mmc: Add PCI fixup quirks for Ricoh 1180:e823 reader
mmc: sdhi: fix module unloading
mmc: of_mmc_spi: add NO_IRQ define to of_mmc_spi.c
mmc: vub300: fix null dereferences in error handling -
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/hid:
HID: hid-multitouch: add support for a new Lumio dual-touch panel
HID: hid-multitouch: correct VID for Stantum panels
HID: hid-multitouch: ensure slots are initialized
26 Jun, 2011
11 commits
-
SCSI defines discard alignment as the offset to the first
optimal discard. In the case of SD/MMC, that is always zero
which is the default.SCSI defines discard granularity as a hint of a optimal
discard size. That is much better expressed by the MMC
"preferred erase size" (pref_erase) field.Signed-off-by: Adrian Hunter
Signed-off-by: Chris Ball -
For example, an eMMC with 2 boot partitions will have 3 threads.
The names change from:40 ? 00:00:00 mmcqd/0
41 ? 00:00:00 mmcqd/0
42 ? 00:00:00 mmcqd/0to:
40 ? 00:00:00 mmcqd/0
41 ? 00:00:00 mmcqd/0boot0
42 ? 00:00:00 mmcqd/0boot1Signed-off-by: Adrian Hunter
Cc: Andrei Warkentin
Signed-off-by: Chris Ball -
The erase timeout calculation may depend on clock rate
which is zero if the clock is gated, so use
mmc_host_clk_rate() which allows for that case.Signed-off-by: Adrian Hunter
Signed-off-by: Chris Ball -
The MMC block driver and other drivers (e.g. mmc-test) will expect
the card to be switched to the User Data Area eMMC partition when
they start. Hence the MMC block driver should ensure it is that
way when it is removed.Signed-off-by: Adrian Hunter
Cc: Andrei Warkentin
Signed-off-by: Chris Ball -
mmc_sdio_power_restore() skips some steps that are performed in other
power-related codepaths which are necessary to fully reset the card.
Without this, runtime PM fails for SD8686 SDIO wifi on OLPC XO-1.5.Signed-off-by: Daniel Drake
Signed-off-by: Chris Ball -
HAVE_EFFICIENT_UNALIGNED_ACCESS is a config option, therefore it needs
the CONFIG_ before it when used by the preprocessor.Signed-off-by: James Hogan
Acked-by: Michał Mirosław
Signed-off-by: Chris Ball -
Don't try to allocate DMA resources if the platform didn't specify
positive DMA slave IDs.Signed-off-by: Guennadi Liakhovetski
Signed-off-by: Chris Ball -
Commit b6147490e6aac82 ("mmc: tmio: split core functionality, DMA and
MFD glue") broke handling of the TMIO_MMC_WRPROTECT_DISABLE flag by
the tmio-mmc driver. This patch restores the original behaviour.Signed-off-by: Guennadi Liakhovetski
Cc:
Signed-off-by: Chris Ball -
Don't use the returned sg_len from dma_map_sg() as inparameter
to dma_unmap_sg(). Use the original sg_len for both dma_map_sg
and dma_unmap_sg according to the documentation in DMA-API.txt.Signed-off-by: Per Forlin
Reviewed-by: Venkatraman S
Signed-off-by: Chris Ball -
The OMAP HSMMC driver uses an ocr_mask to determine the list of voltages
supported by the card. It populates this mask based on the list of
voltages supported by the regulator that supplies the voltage.Commit 64be97822b (omap4 hsmmc: Update ocr mask for MMC2 for regulator
to use) passed a fixed ocr_mask from the OMAP4 SDP board file to limit
the voltage to 2.9-3.0 Volts, and updated the driver to use this mask
if provided, instead of using the regulator's supported voltages.However the commit is buggy - the ocr_mask is overridden by the
regulator's capabilities anyway. Fix this.(The bug shows up when a system-wide suspend is attempted on the OMAP4
SDP/Blaze platforms. The eMMC card comes up at 3V, but drops to 1.65V
after the system resumes).Signed-off-by: Anand Gadiyar
Acked-by: Balaji T K
Acked-by: Venkatraman S
Tested-by: Kishore Kadiyala
Signed-off-by: Sourav Poddar
Signed-off-by: Chris Ball -
After commit e1866b3 "PM / Runtime: Rework runtime PM handling
during driver removal" was introduced, the driver core stopped
incrementing the runtime PM usage counter of the device during
the invocation of the ->remove() callback.This indirectly broke SDIO's runtime PM path during driver removal,
because no one calls _put_sync() anymore after ->remove() completes.This means that the power of runtime-PM-managed SDIO cards is kept
high after their driver is removed (even if it was powered down
beforehand).Fix that by directly calling _put_sync() when the last usage
counter is downref'ed by the SDIO bus.Reported-and-tested-by: Daniel Drake
Signed-off-by: Ohad Ben-Cohen
Signed-off-by: Chris Ball
25 Jun, 2011
2 commits
-
…l/git/tip/linux-2.6-tip
* 'timer-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
rtc: vt8500: Fix build error & cleanup rtc_class_ops->update_irq_enable()
alarmtimers: Return -ENOTSUPP if no RTC device is present
alarmtimers: Handle late rtc module loading -
* 'drm-intel-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/keithp/linux-2.6:
drm/i915: save/resume forcewake lock fixes
Revert "drm/i915: Kill GTT mappings when moving from GTT domain"
drm/i915: Apply HWSTAM workaround for BSD ring on SandyBridge
drm/i915: Call intel_enable_plane from i9xx_crtc_mode_set (again)
24 Jun, 2011
14 commits
-
* 'upstream-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jgarzik/libata-dev:
pata_marvell: Add support for 88SE91A0, 88SE91A4
libata/sas: only set FROZEN flag if new EH is supported
libata: apply NOSETXFER horkage to the affected Pioneer drives regardless of firmware revision
drivers/ata/sata_dwc_460ex: Fix typo 'corrresponding' -
* 'drm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6:
drm/radeon/kms: handle special cases for vddc
drm/radeon/kms: fix num_banks tiling config for fusion -
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/nab/scsi-post-merge-2.6:
tcm_fc: Fix conversion spec warning
tcm_fc: Fix possible lock to unlock type deadlock
tcm_fc: Fix ft_send_tm LUN lookup OOPs
target: Fix incorrect strlen() NULL terminator checks
target: Drop bogus ERR_PTR usage in target_fabric_configfs_init
target: Fix ERR_PTR dereferencing bugs
target: Convert transport_deregister_session_configfs nacl_sess_lock to save irq state
target: Fix transport_get_lun_for_tmr failure cases
[SCSI] target: Convert TASK_ATTR to scsi_tcq.h definitions
[SCSI] target: Convert REPORT_LUNs to use int_to_scsilun
[SCSI] target: Fix task->task_execute_queue=1 clear bug + LUN_RESET OOPs
[SCSI] target: Fix bug with task_sg chained transport_free_dev_tasks release
[SCSI] target: Fix interrupt context bug with stats_lock and core_tmr_alloc_req
[SCSI] target: Fix multi task->task_sg[] chaining logic bug -
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jbarnes/pci-2.6:
x86/PCI/ACPI: fix type mismatch
PCI: fix new kernel-doc warning
PCI: Fix warning in drivers/pci/probe.c on sparc64 -
Signed-off-by: Benjamin Tissoires
Signed-off-by: Jiri Kosina -
while merging hid-stantum into hid-multitouch, I did not correctly copy/paste
the VIDs for those devices. This patch fixes it.Signed-off-by: Benjamin Tissoires
Signed-off-by: Jiri Kosina -
In case a device does not provide the feature "Maximum Contact Count",
or set it at 0, the maxcontacts field may be at 0 while calling
input_mt_init_slots.This patch ensures that hid-multitouch will allways report
ABS_MT_SLOT and ABS_MT_TRACKING_ID to the user space.This corrects a bug found with some Ilitek devices that has been
integrated in 3.0-rc0.Signed-off-by: Benjamin Tissoires
Signed-off-by: Jiri Kosina -
This patch enables support for Marvell IDE PATA controllers found on
Asus P8P67LE motherboard.The formatting has been corrected and I also received a report from two
users of this motherboard that the patch works.Signed-off-by: Paweł Drewniak
Signed-off-by: Jeff Garzik -
A voltage value of 0xff01 requires that the driver
look up the max voltage for the board based using the
atom SetVoltage command table.Setting the proper voltage should fix stability on
some newer asics.Signed-off-by: Alex Deucher
Signed-off-by: Dave Airlie -
The field is encoded:
0 = 4 banks
1 = 8 banks
2 = 16 banksSigned-off-by: Alex Deucher
Signed-off-by: Dave Airlie -
This patch fixes the following conversion specification warning for size_t
drivers/target/tcm_fc/tfc_io.c: In function ‘ft_queue_data_in’:
drivers/target/tcm_fc/tfc_io.c:209: warning: format ‘%x’ expects type ‘unsigned int’, but argument 5 has type ‘size_t’Reported-by: Randy Dunlap
Reported-by: Stephen Rothwell
Signed-off-by: Nicholas Bellinger -
There is a typo here, it should be an unlock instead of a lock. The
original code will deadlock.Signed-off-by: Dan Carpenter
Signed-off-by: Nicholas Bellinger -
This patch fixes a bug in ft_send_tm() that was incorrectly calling
ft_get_lun_for_cmd() -> transport_get_lun_for_cmd(), instead of using
transport_get_lun_for_tmr() for the proper struct se_lun lookup
that was triggering an OOPs in the se_cmd->tmr_req failure path.This patch fixes the issue by re-arranging the codepath where
transport_get_lun_for_tmr() is called after tmr request is allocated and
made it available as part of se_cmd.It also drops the now unnecessary ft_get_lun_for_cmd() unpacking code, and
uses scsilun_to_int() directly ahead of transport_get_lun_for_cmd() and
transport_get_lun_for_tmr() usage.Signed-off-by: Patil, Kiran
Signed-off-by: Robert Love
Signed-off-by: Nicholas A. Bellinger -
This patch fixes a number of cases in target core using an incorrectly
if (strlen(foo) > SOME_MAX_SIZE)
As strlen() returns the number of characters in the string not counting
the NULL character at the end. So if you do something like:char buf[10];
if (strlen("0123456789") > 10)
return -ETOOLONG;
snprintf(buf, 10, "0123456789");
printf("%s\n", buf);then the last "9" gets chopped off and only "012345678" is printed.
Plus I threw in one small related cleanup.
Signed-off-by: Dan Carpenter
Signed-off-by: Nicholas Bellinger