summaryrefslogtreecommitdiff
path: root/drivers
AgeCommit message (Collapse)Author
2011-01-12alarm: disable rtc alarm suspend/resume handlersDeepesh Gujarathi
This is a temporary WAR to avoid the undesired "RTC wakeup" issue. The original source of the problem seems to be in userspace. But use this WAR till we find a proper fix. Bug 773133 Change-Id: I20930056f9a33f539699e777ec9ae45bb4bac34f Reviewed-on: http://git-master/r/15487 Reviewed-by: Deepesh Subhash Gujarathi (Engrg-Mobile) <dgujarathi@nvidia.com> Tested-by: Deepesh Subhash Gujarathi (Engrg-Mobile) <dgujarathi@nvidia.com> Reviewed-by: Bharat Nihalani <bnihalani@nvidia.com>
2011-01-11hwmon: nct1008: delete driver codeVarun Wadekar
nct1008 driver will now reside in drivers/misc Bug 742230 Change-Id: I774c920cf96ded96ae440a99935f6cb9f1f63323 Signed-off-by: Varun Wadekar <vwadekar@nvidia.com> Reviewed-on: http://git-master/r/15496 Reviewed-by: Bharat Nihalani <bnihalani@nvidia.com>
2011-01-10[ARM] tegra: hdmi repeater, renegotiate, fixesJon Mayo
check for repeaters and store repeater info. userspace application queries this status to authenticate the connection. when authentication fails, auto-renegotiate every 1.75 seconds. fixes: * i2c infrastructure reimplemented in a clean way. removed hooks from hdmi.c and edid.c * added a few msleeps to conform to specifications. * removed read file operation, nobody was using it. * ioctl() bails out if hardware is disabled Bug 727054 Change-Id: I5e738323dd85911259bb4695659ffea19a5c1e49 Reviewed-on: http://git-master/r/15195 Reviewed-by: Jonathan Mayo <jmayo@nvidia.com> Tested-by: Jonathan Mayo <jmayo@nvidia.com> Reviewed-by: Peter Zu <pzu@nvidia.com> Reviewed-by: Yu-Huan Hsu <yhsu@nvidia.com>
2011-01-10[ARM] tegra: hdmi hotplug fixedJon Mayo
modified tegra_dc_enable and tegra_dc_detect sequence for working hotplug detection. HDMI enable pin needs to be enabled before EDID detect function is used. The enable bails out early if pclk(pixel clock) is 0, but pclk cannot be configured until modes are loaded by EDID detect function. Bug 727054 Change-Id: I2d02b82374c131ccbdb8e4e8f43e46840fbae06b Reviewed-on: http://git-master/r/15197 Reviewed-by: Jonathan Mayo <jmayo@nvidia.com> Tested-by: Jonathan Mayo <jmayo@nvidia.com> Reviewed-by: Peter Zu <pzu@nvidia.com> Reviewed-by: Yu-Huan Hsu <yhsu@nvidia.com>
2011-01-10[ARM] tegra: edid uses garbage on i2c failureJon Mayo
garbage timings and partial mode lists were being reported because i2c errors were being ignored in tegra_edid_get_monspecs(). Bug 727054 Change-Id: Iec7878f2a3071c5297d0569d4f1cce1c9ed48979 Reviewed-on: http://git-master/r/15196 Reviewed-by: Jonathan Mayo <jmayo@nvidia.com> Tested-by: Jonathan Mayo <jmayo@nvidia.com> Reviewed-by: Peter Zu <pzu@nvidia.com> Reviewed-by: Yu-Huan Hsu <yhsu@nvidia.com>
2011-01-10merging android-tegra-2.6.36 into git-master/linux-2.6/android-tegra-2.6.36Nitin Kumbhar
Conflicts: arch/arm/mach-tegra/fuse.c drivers/misc/Makefile Change-Id: I300b925d78b31efe00c342190d8dbd50e2e81230
2011-01-09Merge branch 'linux-tegra-2.6.36' into android-tegra-2.6.36Colin Cross
2011-01-09rtc: tps6586x: Fix error in RTC tick calculationsLowell Dennis
In the TPS6586x PMU/PMIC RTC support code, when converting from seconds to ticks using a shift operator, the most significant bits were being lost due to seconds being a 32-bit value and ticks being a 64-bit value. A hard cast was added to avoid this loss. Reviewed-by: Lowell Dennis <ldennis@nvidia.com> Tested-by: Lowell Dennis <ldennis@nvidia.com> Reviewed-by: Jonathan Mayo <jmayo@nvidia.com> Reviewed-by: Peter Zu <pzu@nvidia.com> Reviewed-by: Bharat Nihalani <bnihalani@nvidia.com> Signed-off-by: Robert Morell <rmorell@nvidia.com> Signed-off-by: Colin Cross <ccross@android.com>
2011-01-09usb: ehci: tegra: continues driving FS-J during resumeJay Cheng
To prevent USB glitch. Also only program PTC bits when resume from LP0 Change-Id: Iced668e33f986828d3a483b411055948b5b257e1 Signed-off-by: Jay Cheng <jacheng@nvidia.com>
2011-01-09usb: ehci: tegra: remove reschedule rh_timerJay Cheng
Reschedule rh_timer may cause usb device resume fail, as rh_timer may be timeout and send USB_REQ_GET_STATUS SETUP control transfer by the time when the device is handling clear suspend feature, which in turn the device may drop clear suspend feature request. Actually on port resume case, the host driver don't need to reschedule rh_timer to check port status. The host driver will check port status right after suspend feature is cleared. Change-Id: I6205e97af49ed4349b6215b851f6b5f1394258d8 Signed-off-by: Jay Cheng <jacheng@nvidia.com>
2011-01-08Merge branch 'linux-tegra-2.6.36' into android-tegra-2.6.36Colin Cross
Conflicts: drivers/misc/Kconfig drivers/misc/Makefile Change-Id: I826244513f799fdd2fb0269abad3271c96661293
2011-01-07NCT1008 temperature sensor driverTodd Poynor
Replace the PM-only driver for NCT1008 with a new version written by Varun Wadekar and Dmitriy Gruzman. Add a callback to an alarm function specified in the board platform data. Change-Id: Ib429533930ee75af3402d24b0bc286da9f6ee67b Signed-off-by: Todd Poynor <toddpoynor@google.com>
2011-01-07misc: Initial NCT1008 driverGreg Meiste
Initial version of the NCT1008 driver to turn off the sensor when the device is suspended. This improves standby current drain. Change-Id: Ia64613c33c0052434d5e304c434605611e5ef789 Signed-off-by: Greg Meiste <w30289@motorola.com>
2011-01-07video: tegra: fix debug regs file hangErik Gilling
Change-Id: I2bdfe5ec9f69b7b7960e59bec76fb9b02b61f3fb Signed-off-by: Erik Gilling <konkers@android.com>
2011-01-07Merge branch 'linux-tegra-2.6.36' into android-tegra-2.6.36Colin Cross
Conflicts: arch/arm/mm/cache-v6.S Change-Id: I1a2063218dd705a762a40f4a9dfe504ce1a1d491
2011-01-07Merge branch 'android-2.6.36' into android-tegra-2.6.36Colin Cross
2011-01-07Merge commit 'v2.6.36.3' into linux-tegra-2.6.36Colin Cross
2011-01-07crytpo: tegra-aes: make aes_handle_req aynschronousVarun Wadekar
the encrypt/decrypt callbacks have to return with -EINPROGRESS error code and the request complete callback needs to be called from handle_req for aynchronous block ciphers. use work queue to make the driver asynchronous. Change-Id: I0dec1185c31e5de7ba039c39d6bd87c8b3487b2a Signed-off-by: Varun Wadekar <vwadekar@nvidia.com>
2011-01-07input: keyreset: Allow reset function to be overridenColin Cross
Change-Id: Ibb3dda05772b2e89d7b2646689944d309cb1f74e Signed-off-by: Colin Cross <ccross@android.com>
2011-01-07gspca - sonixj: Add a flag in the driver_info tableJean-Francois Moine
commit c6c14330717f9850b4b4c054b81424b9979cd07d upstream. Signed-off-by: Jean-François Moine <moinejf@free.fr> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-01-07gspca - sonixj: Set the flag for some devicesJean-Francois Moine
commit b2272a49e7df37732d73988f00468ce31e1ebc92 upstream. The flag PDN_INV indicates that the sensor pin S_PWR_DN has not the same value as other webcams with the same sensor. For now, only two webcams have been so detected: the Microsoft's VX1000 and VX3000. Signed-off-by: Jean-François Moine <moinejf@free.fr> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-01-07orinoco: initialise priv->hw before assigning the interruptDavid Kilroy
commit 229bd792be0bad245b78ed8f119952733a4752e5 upstream. The interrupt handler takes a lock - but since commit bcad6e80f3f this lock goes through an indirection specified in the hermes_t structure. We must therefore initialise the structure before setting up the interrupt handler. Fix orinoco_cs and spectrum_cs <https://bugzilla.kernel.org/show_bug.cgi?id=23932> Bisected by: Matt Domsch <Matt_Domsch@dell.com> Signed-off by: David Kilroy <kilroyd@googlemail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-01-07Don't export format_by_forcc on two different driversMauro Carvalho Chehab
commit a757ee2216211278680dd8ac869aabe7b4a9970d upstream. Drivers should append their name on exported symbols, to avoid conflicts with allyesconfig: drivers/staging/built-in.o: In function `format_by_fourcc': /home/v4l/work_trees/linus/drivers/staging/cx25821/cx25821-video.c:96: multiple definition of `format_by_fourcc' drivers/media/built-in.o:/home/v4l/work_trees/linus/drivers/media/common/saa7146_video.c:88: first defined here Let's rename both occurences with a small shellscript: for i in drivers/staging/cx25821/*.[ch]; do sed s,format_by_fourcc,cx25821_format_by_fourcc,g <$i >a && mv a $i; done for i in drivers/media/common/saa7146*.[ch]; do sed s,format_by_fourcc,saa7146_format_by_fourcc,g <$i >a && mv a $i; done for i in include/media/saa7146*.[ch]; do sed s,format_by_fourcc,saa7146_format_by_fourcc,g <$i >a && mv a $i; done Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-01-07mx2_camera: fix pixel clock polarity configurationBaruch Siach
commit 42cc37fe20cc680fb58fe12ae5ba718d683b8ca2 upstream. When SOCAM_PCLK_SAMPLE_FALLING, just leave CSICR1_REDGE unset, otherwise we get the inverted behaviour. Signed-off-by: Baruch Siach <baruch@tkos.co.il> Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-01-07block: Deprecate QUEUE_FLAG_CLUSTER and use queue_limits insteadMartin K. Petersen
commit e692cb668fdd5a712c6ed2a2d6f2a36ee83997b4 upstream. When stacking devices, a request_queue is not always available. This forced us to have a no_cluster flag in the queue_limits that could be used as a carrier until the request_queue had been set up for a metadevice. There were several problems with that approach. First of all it was up to the stacking device to remember to set queue flag after stacking had completed. Also, the queue flag and the queue limits had to be kept in sync at all times. We got that wrong, which could lead to us issuing commands that went beyond the max scatterlist limit set by the driver. The proper fix is to avoid having two flags for tracking the same thing. We deprecate QUEUE_FLAG_CLUSTER and use the queue limit directly in the block layer merging functions. The queue_limit 'no_cluster' is turned into 'cluster' to avoid double negatives and to ease stacking. Clustering defaults to being enabled as before. The queue flag logic is removed from the stacking function, and explicitly setting the cluster flag is no longer necessary in DM and MD. Reported-by: Ed Lin <ed.lin@promise.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> Acked-by: Mike Snitzer <snitzer@redhat.com> Signed-off-by: Jens Axboe <jaxboe@fusionio.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-01-07libata-sff: fix HSM_ST_ERR handling in __ata_sff_port_intr()Tejun Heo
commit 687a993339c4f3a63654746230da3aab8bbdbffd upstream. While separating out BMDMA irq handler from SFF, commit c3b28894 (libata-sff: separate out BMDMA irq handler) incorrectly made __ata_sff_port_intr() consider an IRQ to be an idle one if the host state was transitioned to HSM_ST_ERR by ata_bmdma_port_intr(). This makes BMDMA drivers ignore IRQs reporting host bus error which leads to timeouts instead of triggering EH immediately. Fix it by making __ata_sff_port_intr() consider the IRQ to be an idle one iff the state is HSM_ST_IDLE. This is equivalent to adding HSM_ST_ERR to the "break"ing case but less error-prone. Signed-off-by: Tejun Heo <tj@kernel.org> Reported-by: Antonio Toma <antonio.toma@gmail.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-01-07mv_xor: fix race in tasklet functionSaeed Bishara
commit 8333f65ef094e47020cd01452b4637e7daf5a77f upstream. use mv_xor_slot_cleanup() instead of __mv_xor_slot_cleanup() as the former function aquires the spin lock that needed to protect the drivers data. Signed-off-by: Saeed Bishara <saeed@marvell.com> Signed-off-by: Dan Williams <dan.j.williams@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-01-07drm/i915, intel_ips: When i915 loads after IPS, make IPS relink to i915.Eric Anholt
commit 63ee41d794d9c555f84205517a68509848988760 upstream. The IPS driver is designed to be able to run detached from i915 and just not enable GPU turbo in that case, in order to avoid module dependencies between the two drivers. This means that we don't know what the load order between the two is going to be, and we had previously only supported IPS after (optionally) i915, but not i915 after IPS. If the wrong order was chosen, you'd get no GPU turbo, and something like half the possible graphics performance. Signed-off-by: Eric Anholt <eric@anholt.net> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-01-07drm/i915/dp: Fix I2C/EDID handling with active DisplayPort to DVI converterDavid Flynn
commit 8316f33766a82907c694267ff911e45e256f09f9 upstream. The DisplayPort standard (1.1a) states that: The I2C-over-AUX Reply field is valid only when Native AUX CH Reply field is AUX_ACK (00). When Native AUX CH Reply field is not 00, then, I2C-over-AUX Reply field must be 00 and be ignored. This fixes broken EDID reading when using an active DisplayPort to duallink DVI converter. If the AUX CH replier chooses to defer the transaction, a short read occurs and erroneous data is returned as the i2c reply due to a lack of length checking and failure to check for AUX ACK. As a result, broken EDIDs can look like: 0 1 2 3 4 5 6 7 8 9 a b c d e f 0123456789abcdef 00: bc bc bc ff bc bc bc ff bc bc bc ac bc bc bc 45 ???.???.???????E 10: bc bc bc 10 bc bc bc 34 bc bc bc ee bc bc bc 4c ???????4???????L 20: bc bc bc 50 bc bc bc 00 bc bc bc 40 bc bc bc 00 ???P???.???@???. 30: bc bc bc 01 bc bc bc 01 bc bc bc a0 bc bc bc 40 ???????????????@ 40: bc bc bc 00 bc bc bc 00 bc bc bc 00 bc bc bc 55 ???.???.???.???U 50: bc bc bc 35 bc bc bc 31 bc bc bc 20 bc bc bc fc ???5???1??? ???? 60: bc bc bc 4c bc bc bc 34 bc bc bc 46 bc bc bc 00 ???L???4???F???. 70: bc bc bc 38 bc bc bc 11 bc bc bc 20 bc bc bc 20 ???8??????? ??? 80: bc bc bc ff bc bc bc ff bc bc bc ff bc bc bc ff ???.???.???.???. ... which can lead to: [drm:drm_edid_block_valid] *ERROR* EDID checksum is invalid, remainder [drm:drm_edid_block_valid] *ERROR* Raw EDID: <3>30 30 30 30 30 30 30 32 38 32 30 32 63 63 31 61 000000028202cc1a <3>28 00 02 8c 00 00 00 00 18 00 00 00 00 00 00 00 (............... <3>20 4c 61 73 74 20 62 65 61 63 6f 6e 3a 20 33 32 Last beacon: 32 <3>32 30 6d 73 20 61 67 6f 46 00 05 8c 00 00 00 00 20ms agoF....... <3>36 00 00 00 00 00 00 00 00 0c 57 69 2d 46 69 20 6.........Wi-Fi <3>52 6f 75 74 65 72 01 08 82 84 8b 96 24 30 48 6c Router......$0Hl <3>03 01 01 06 02 00 00 2a 01 00 2f 01 00 32 04 0c .......*../..2.. <3>12 18 60 dd 09 00 10 18 02 00 00 01 00 00 18 00 ..`............. Signed-off-by: David Flynn <davidf@rd.bbc.co.uk> [ickle: fix up some surrounding checkpatch warnings] Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-01-07drm/radeon/kms: reorder display resume to avoid problemsAlex Deucher
commit a93f344d3c04e4b84490c65f2a574387c593be40 upstream. On resume, we were attemping to unblank the displays before the timing and plls had be reprogrammed which led to atom timeouts waiting for things that are not yet programmed. Re-program the mode first, then reset the dpms state. This fixes the infamous atombios timeouts on resume. Signed-off-by: Alex Deucher <alexdeucher@gmail.com> Signed-off-by: Dave Airlie <airlied@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-01-07drm/radeon/kms: fix evergreen asic resetAlex Deucher
commit 9f0c4f9c2f835eee1bbb93f96bf9483d56f1892b upstream. Only reset the grbm blocks, srbm tends to lock the GPU if not done properly and in most cases is not necessary. Also, no need to call asic init after reset the grbm blocks. Signed-off-by: Alex Deucher <alexdeucher@gmail.com> Reviewed-by: Jerome Glisse <jglisse@redhat.com> Signed-off-by: Dave Airlie <airlied@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-01-07drm/radeon/kms/evergreen: reset the grbm blocks at resume and initAlex Deucher
commit 86f5c9edbb3bac37cc8cee6528a929005ba72aad upstream. This fixes module reloading and resume as the gfx block seems to be left in a bad state in some cases. Signed-off-by: Alex Deucher <alexdeucher@gmail.com> Signed-off-by: Dave Airlie <airlied@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-01-07mfd: Supply IRQ base for WM832x devicesMark Brown
commit bd7c72ed18d719c1fb0fdf6ff9042d8ab78fdf71 upstream. Without this the IRQ base will not be correctly configured for the subdevices. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-01-07mfd: Support additional parent IDs for wm831xMark Brown
commit b93cef556162b0f33399bfe5f307c54f51554e09 upstream. Some newer device revisions add a second parent ID. Support this in the device validity checks done at startup. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-01-07watchdog: Fix null pointer dereference while accessing rdc321x platform_dataFlorian Fainelli
commit 3b3c1f24e96c411a95daabb6af9e09c5381f713b upstream. rdc321x-wdt currently fetches its driver specific data by using the platform_device->platform_data pointer, this is wrong because the mfd device which registers our platform_device has been added using mfd_add_device() which sets the platform_device->driver_data pointer instead. Signed-off-by: Florian Fainelli <florian@openwrt.org> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-01-07RAMOOPS: Don't overflow over non-allocated regionsAhmed S. Darwish
commit 1873bb8115e678ad9fd0aac9dbbc68383bc36e06 upstream. The current code mis-calculates the ramoops header size, leading to an overflow over the next record at best, or over a non-allocated region at worst. Fix that calculation. Signed-off-by: Ahmed S. Darwish <darwish.07@gmail.com> Acked-by: Marco Stornelli <marco.stornelli@gmail.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-01-07rtc: rs5c372: fix buffer sizeWolfram Sang
commit 118364948fad7b6c0469ef2d3ddaee447d7a0b5f upstream. Match the buffer size to the amount of initialized values. Before, it was one too big and thus destroyed the neighbouring register causing the clock to run at false speeds. Reported-by: Andre van Rooyen <a.v.rooyen@sercom.nl> Signed-off-by: Wolfram Sang <w.sang@pengutronix.de> Cc: Alessandro Zummo <a.zummo@towertech.it> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-01-07mmc: Fix re-probing with PM_POST_RESTORE notificationTakashi Iwai
commit 274476f8fe0b6ac9bac542cc39de12c3dd0f43f6 upstream. In the error-path where PM notifies PM_POST_RESTORE, the rescan-blockage should be cleared as well. Otherwise it'll be never re-probed. Also, as a bonus, this fixes a bug in S4 with user-mode suspend in the current code, as it sends PM_POST_RESTORE instead of PM_POST_HIBERNATION wrongly. Signed-off-by: Takashi Iwai <tiwai@suse.de> Signed-off-by: Chris Ball <cjb@laptop.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-01-07mmc: atmel-mci: fix multiblock SDIO transfersNicolas Ferre
commit 2f1d791882d21a4002a719fb016a1ac21c8bd6b7 upstream. Based on report made by Yauhen in: "MMC: Fix multiblock SDIO transfers in AT91 MCI" patch, I report those changes to the brother driver: atmel-mci. So, this patch sets SDIO transfer types: SDIO block and SDIO byte transfers instead of using ordinary MMC block transfers. It is checking opcode for SDIO CMD53 and setting transfer type in MCI_CMDR register properly. Reported-by: Yauhen Kharuzhy <yauhen.kharuzhy@promwad.com> Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com> Acked-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com> Signed-off-by: Chris Ball <cjb@laptop.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-01-07mmc: at91_mci: fix multiblock SDIO transfersYauhen Kharuzhy
commit a2255ff45143001fecbc5e5a4b58fcb999d393ae upstream. The AT91 MCI has special SDIO transfer types: SDIO block and SDIO byte transfers, but at91_mci driver doesn't use them and handles all SDIO transfers as ordinary MMC block transfers. This causes problems for multiple-block SDIO transfers (in particular for 256-bytes blocks). Fix this situation by checking the opcode for SDIO CMD53 and setting the transfer type in the AT91_MCI_CMDR register properly. This patch was tested with libertas SDIO driver: problem with TX timeouts on big packets was eliminated. Signed-off-by: Yauhen Kharuzhy <yauhen.kharuzhy@promwad.com> Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com> Acked-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com> Signed-off-by: Chris Ball <cjb@laptop.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-01-07cs5535-gpio: handle GPIO regs where higher (clear) bits are setAndres Salomon
commit 44658a11f312fb9217674cb90b1a11cbe17fd18d upstream. The default for non-READ_BACK GPIO regs is to have the clear bits set; this means that our original errata fix was too simplistic. This changes it to the following behavior: - when setting GPIOs, ignore the higher order bits (they're for clearing, we don't need to care about them). - when clearing GPIOs, keep all the bits, but unset (via XOR) the lower order bit that negates the clear bit that we care about. That is, if we're clearing GPIO 26 (val = 0x04000000), we first XOR what's currently in the register with 0x0400 (GPIO 26's SET bit), and then OR that with the GPIO 26's CLEAR bit. Tested-by: Daniel Drake <dsd@laptop.org> Signed-off-by: Andres Salomon <dilinger@queued.net> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-01-07cs5535-gpio: don't apply errata #36 to edge detect GPIOsAndres Salomon
commit 001851659354cce436b749a793f3512a53394d80 upstream. The edge detect status GPIOs function differently from the other atomic model CS5536 GPIO registers; writing 1 to the high bits clears the GPIO, but writing 1 to the lower bits also clears the bit. This means that read-modify-write doesn't actually work for it, so don't apply the errata here. If a negative edge status gets lost after resume.. well, we tried our best! Tested-by: Daniel Drake <dsd@laptop.org> Signed-off-by: Andres Salomon <dilinger@queued.net> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-01-07gpio: Fix null pointer dereference while accessing rdc321x platform_dataFlorian Fainelli
commit fa6469cb5b2d16703464c344b943e2c025cb7858 upstream. rdc321x-gpio currently fetches its driver specific data by using the platform_device->platform_data pointer, this is wrong because the mfd device which registers our platform_device has been added using mfd_add_device() which sets the platform_device->driver_data pointer instead. Signed-off-by: Florian Fainelli <florian@openwrt.org> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-01-07xhci: Fix issue with port array setup and buggy hosts.Sarah Sharp
commit f8bbeabc34aa945ab4275abc9a4dfde0aea798ca upstream. Fix two bugs with the port array setup. The first bug will only show up with broken xHCI hosts with Extended Capabilities registers that have duplicate port speed entries for the same port. The idea with the original code was to set the port_array entry to -1 if the duplicate port speed entry said the port was a different speed than the original port speed entry. That would mean that later, the port would not be exposed to the USB core. Unfortunately, I forgot a continue statement, and the port_array entry would just be overwritten in the next line. The second bug would happen if there are conflicting port speed registers (so that some entry in port_array is -1), or one of the hardware port registers was not described in the port speed registers (so that some entry in port_array is 0). The code that sets up the usb2_ports array would accidentally claim those ports. That wouldn't really cause any user-visible issues, but it is a bug. This patch should go into the stable trees that have the port array and USB 3.0 port disabling prevention patches. Signed-off-by: Sarah Sharp <sarah.a.sharp@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-01-07n_gsm: gsm_data_alloc buffer allocation could fail and it is not being checkedKen Mills
commit 093d804611b9a38fe59753b37c29f840518406a9 upstream. gsm_data_alloc buffer allocation could fail and it is not being checked. Add check for allocated buffer and return if the buffer allocation fails. Signed-off-by: Ken Mills <ken.k.mills@intel.com> Signed-off-by: Alan Cox <alan@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-01-07n_gsm: Fix message length handling when building headerKen Mills
commit be7a7411d63ccad165d66fe8e0b11b2ee336159b upstream. Fix message length handling when building header When the message length is greater than 127, the length field in the header is built incorrectly. According to the spec, when the length is less than 128 the length field is a single byte formatted as: bbbbbbb1. When it is greater than 127 then the field is two bytes of the format: bbbbbbb0 bbbbbbbb. Signed-off-by: Ken Mills <ken.k.mills@intel.com> Signed-off-by: Alan Cox <alan@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-01-07p54usb: New USB ID for Gemtek WUBI-100GWEduardo Costa
commit 56e6417b49132d4f56e9f2241d31942b90b46315 upstream. This USB ID is for the WUBI-100GW 802.11g Wireless LAN USB Device that uses p54usb. Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: Eduardo Costa <ecosta.tmp@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-01-07p54usb: add 5 more USBIDsChristian Lamparter
commit 16cad7fba037b34ca32cc0adac65bc089d969fb8 upstream. This patch adds five more USBIDs to the table. Source: http://www.linuxant.com/pipermail/driverloader/2005q3/002307.html http://wireless.kernel.org/en/users/Drivers/p54/devices (by M. Davis) Signed-off-by: Christian Lamparter <chunkeey@googlemail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-01-07Revert "USB: gadget: Allow function access to device ID data during bind()"Greg Kroah-Hartman
commit dbb442b85a1d82f91cfe0524c4f9b3a5196a10ca upstream. This reverts commit 1ab83238740ff1e1773d5c13ecac43c60cf4aec4. Turns out this doesn't allow for the device ids to be overridden properly, so we need to revert the thing. Reported-by: Jef Driesen <jefdriesen@telenet.be> Cc: Robert Lukassen <Robert.Lukassen@tomtom.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-01-07USB: usb-storage: unusual_devs entry for the Samsung YP-CP3Vitaly Kuznetsov
commit d73a9b3001f29271c2e9f2a806b05a431c5d9591 upstream. Add an unusual_devs entry for the Samsung YP-CP3 MP4 player. User was getting the following errors in dmesg: usb 2-6: reset high speed USB device using ehci_hcd and address 2 usb 2-6: reset high speed USB device using ehci_hcd and address 2 usb 2-6: reset high speed USB device using ehci_hcd and address 2 usb 2-6: USB disconnect, address 2 sd 3:0:0:0: [sdb] Assuming drive cache: write through sdb:<2>ldm_validate_partition_table(): Disk read failed. Dev sdb: unable to read RDB block 0 unable to read partition table Signed-off-by: Vitaly Kuznetsov <vitty@altlinux.ru> Acked-by: Alan Stern <stern@rowland.harvard.edu> CC: Matthew Dharm <mdharm-usb@one-eyed-alien.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>