Takashi Iwai [Fri, 1 Jun 2012 08:06:23 +0000 (10:06 +0200)]
UPSTREAM: xhci: Fix invalid loop check in xhci_free_tt_info()
commit
46ed8f00d8982e49f8fe2c1a9cea192f640cb3ba upstream.
xhci_free_tt_info() may access the invalid memory when it removes the
last entry but the list is not empty. Then tt_next reaches to the
list head but it still tries to check the tt_info of that entry.
This patch fixes the bug and cleans up the messy code by rewriting
with a simple list_for_each_entry_safe().
This patch should be backported to kernels as old as 3.2, that contain
the commit
839c817ce67178ca3c7c7ad534c571bba1e69ebe "xhci: Store
information about roothubs and TTs."
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Sarah Sharp <sarah.a.sharp@linux.intel.com>
Reviewed-by: Oliver Neukum <oneukum@suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
(cherry picked from commit
b063a624f08cfa64c2d9162d1525da95519e6156)
BUG=None
TEST=Together with other cherry-picks: run BVT trybots on all platforms,
manually confirm that USB network/storage/input devices still work
(including across suspend/resume)
Change-Id: I6b86ca835e1a915cbbbbf47356d696efe86a96d8
Signed-off-by: Julius Werner <jwerner@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/46056
Reviewed-by: Vincent Palatin <vpalatin@chromium.org>
Andiry Xu [Fri, 4 May 2012 16:50:10 +0000 (00:50 +0800)]
UPSTREAM: usbcore: enable USB2 LPM if port suspend fails
commit
c3e751e4f4754793bb52bd5ae30e9cc027edbb12 upstream.
USB2 LPM is disabled when device begin to suspend and enabled after device
is resumed. That's because USB spec does not define the transition from
U1/U2 state to U3 state.
If usb_port_suspend() fails, usb_port_resume() is never called, and USB2 LPM
is disabled in this situation. Enable USB2 LPM if port suspend fails.
This patch should be backported to kernels as old as 3.2, that contain
the commit
65580b4321eb36f16ae8b5987bfa1bb948fc5112 "xHCI: set USB2
hardware LPM".
Signed-off-by: Andiry Xu <andiry.xu@gmail.com>
Signed-off-by: Sarah Sharp <sarah.a.sharp@linux.intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
(cherry picked from commit
edad2199132a88f160c4939d1ad3eecc4c33b211)
BUG=None
TEST=Together with other cherry-picks: run BVT trybots on all platforms,
manually confirm that USB network/storage/input devices still work
(including across suspend/resume)
Change-Id: I3762df7d8d42c3d8228b1f19ce5f1439e19457e1
Signed-off-by: Julius Werner <jwerner@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/46055
Reviewed-by: Vincent Palatin <vpalatin@chromium.org>
Grant Grundler [Thu, 21 Mar 2013 16:13:41 +0000 (09:13 -0700)]
Revert "Revert "UPSTREAM: mmc: dw_mmc: correct the calculation for CLKDIV""
This reverts commit
f786fcc8d52e5a7d15a90cf266f2ac1d40f54a5e
Cannot reproduce "won't boot" with "normal" FW versions. See bug for details.
Change-Id: Ibb2730ecef525831883ff26bc04c72a55f47f06d
Reviewed-on: https://gerrit.chromium.org/gerrit/46128
Reviewed-by: Grant Grundler <grundler@chromium.org>
Tested-by: Grant Grundler <grundler@chromium.org>
Reviewed-by: Daniel Kurtz <djkurtz@chromium.org>
Commit-Queue: Paul Stewart <pstew@chromium.org>
Doug Anderson [Tue, 11 Sep 2012 16:10:08 +0000 (09:10 -0700)]
CHROMIUM: CONFIG: Add debug info
This was default on all builds but got lost in a kernel rebase. It
adds no-overhead to release builds since they are stripped but means
the vmlinux we get from the bots has symbols.
BUG=chromium:222294
TEST=Build the kernel and run with it. Use kgdb with this kernel.
Change-Id: Ief705b2a1a09917b6885ed84c7a405cb12e105f2
Signed-off-by: Doug Anderson <dianders@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/33566
Reviewed-by: Mike Frysinger <vapier@chromium.org>
Reviewed-by: Sonny Rao <sonnyrao@chromium.org>
Reviewed-by: Sameer Nanda <snanda@chromium.org>
Reviewed-by: Olof Johansson <olofj@chromium.org>
Doug Anderson [Mon, 18 Mar 2013 23:12:42 +0000 (16:12 -0700)]
samsung: snow: bitfix: Don't bail if we can't recover unused memory
The bitfix code has the requirement that you can only recover an
entire 8K chunk of memory at a time, even though memory can be
"skipped" (not processed by bitfix) in 4K chunks. If we ever detect
corruption in a 8K chunk that contained skipped pages then we'd bail
and reboot.
The original concept of "skipping" pages was there for sacred areas of
memory: the stack, console buffer, MMU structures, etc. For these
areas of memory the above logic makes a lot of sense. Dealing with a
page at a time meant that we could still _detect_ corruption on that
page. ...and we could even fix it! ...but since evidence suggested
that if one half of a chunk was corrupted that there's a good chance
of corruption in the other half, we chose to bail and reboot.
The above logic didn't take into account that we added another reason
for skipping a page: if it was unused. For part of a chunk is unused
then we should just recover the half of the chunk that we care about
and not worry about corruption in the other half.
BUG=chromium-os:39522
TEST=suspend_stress_test
Change-Id: I57ad2fe24755e8867fdd4a5b729521b0ddb1d5fc
Signed-off-by: Doug Anderson <dianders@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/45807
Reviewed-by: Olof Johansson <olofj@chromium.org>
Yuvaraj CD [Mon, 8 Oct 2012 08:59:51 +0000 (14:29 +0530)]
UPSTREAM: mmc: dw_mmc: enable controller interrupt before calling mmc_start_host
As mmc_start_host is getting called before enabling the dw_mmc controller
interrupt, there is a problem of missing the SDMMC_INT_CMD_DONE for the
very first command sent by the sdio_reset.
This problem occurs only when we disable MMC debugging i.e, MMC_DEBUG=n.
This patch enables the dw_mmc controller interrupt before mmc_start_host.
BUG=chrome-os-partner:17015
TEST=Stress test on flaky device that generates CRC errors.
Signed-off-by: Yuvaraj CD <yuvaraj.cd@samsung.com>
Reviewed-by: Girish K S <girish.shivananjappa@linaro.org>
Acked-by: Will Newton <will.newton@imgtec.com>
Signed-off-by: Chris Ball <cjb@laptop.org>
Signed-off-by: Doug Anderson <dianders@chromium.org>
Change-Id: I02ffde04115a707d03d694d3539b3111007cd58c
(cherry picked from commit
2da1d7f2948900cd50d38643db39f790edb3cc96)
Reviewed-on: https://gerrit.chromium.org/gerrit/45581
Reviewed-by: Bing Zhao <bzhao@marvell.com>
Reviewed-by: Paul Stewart <pstew@chromium.org>
Seungwon Jeon [Wed, 1 Aug 2012 00:30:40 +0000 (09:30 +0900)]
UPSTREAM: mmc: dw_mmc: correct mishandling error interrupt
Datasheet of SYNOPSYS mentions that DTO(Data Transfer Over) interrupt
will be raised even if some error interrupts, however it is actually
found that DTO does not occur. SYNOPSYS has confirmed this issue.
Current implementation defers the call of tasklet_schedule until DTO
when the error interrupts is happened. This patch fixes error handling.
BUG=chrome-os-partner:17015
TEST=Stress test on flaky device that generates CRC errors.
Signed-off-by: Seungwon Jeon <tgih.jun@samsung.com>
Acked-by: Jaehoon Chung <jh80.chung@samsung.com>
Acked-by: Will Newton <will.newton@imgtec.com>
Signed-off-by: Chris Ball <cjb@laptop.org>
Signed-off-by: Doug Anderson <dianders@chromium.org>
Change-Id: I6c9d0ccff6f23d41f9f9eb15de99fffdb3422dff
(cherry picked from commit
9b2026a12511439d906a5d8d302ae285ebe7378a)
Reviewed-on: https://gerrit.chromium.org/gerrit/45580
Reviewed-by: Bing Zhao <bzhao@marvell.com>
Reviewed-by: Paul Stewart <pstew@chromium.org>
Seungwon Jeon [Wed, 1 Aug 2012 00:30:30 +0000 (09:30 +0900)]
UPSTREAM: mmc: dw_mmc: amend using error interrupt status
RINTSTS status includes masked interrupts as well as unmasked.
data_status and cmd_status are set by value of RINTSTS in interrupt handler
and tasklet finally uses it to decide whether error is happened or not.
In addition, MINTSTS status is used for setting data_status in PIO.
Masked error interrupt will not be handled and that status can be considered
non-error case.
BUG=chrome-os-partner:17015
TEST=Stress test on flaky device that generates CRC errors.
Signed-off-by: Seungwon Jeon <tgih.jun@samsung.com>
Reviewed By: Girish K S <girish.shivananjappa@linaro.org>
Acked-by: Jaehoon Chung <jh80.chung@samsung.com>
Acked-by: Will Newton <will.newton@imgtec.com>
Signed-off-by: Chris Ball <cjb@laptop.org>
Signed-off-by: Doug Anderson <dianders@chromium.org>
Change-Id: Ibf3eb215ad9b03593cf486fe483428510eb5c175
(cherry picked from commit
182c90815993452f1902837cc342ac2c05ef13f5)
Reviewed-on: https://gerrit.chromium.org/gerrit/45579
Reviewed-by: Bing Zhao <bzhao@marvell.com>
Reviewed-by: Paul Stewart <pstew@chromium.org>
Seungwon Jeon [Wed, 1 Aug 2012 00:30:46 +0000 (09:30 +0900)]
UPSTREAM: mmc: dw_mmc: fix error handling in PIO mode
Data transfer will be continued until all the bytes are transmitted,
even if data crc error occurs during a multiple-block data transfer.
This means RXDR/TXDR interrupts will occurs until data transfer is
terminated. Early setting of host->sg to NULL prevents going into
xxx_data_pio functions, hence permanent unhandled RXDR/TXDR interrupts
occurs. And checking error interrupt status in the xxx_data_pio functions
is no need because dw_mci_interrupt does do the same. This patch also
removes it.
BUG=chrome-os-partner:17015
TEST=Stress test on flaky device that generates CRC errors.
Signed-off-by: Seungwon Jeon <tgih.jun@samsung.com>
Acked-by: Jaehoon Chung <jh80.chung@samsung.com>
Acked-by: Will Newton <will.newton@imgtec.com>
Signed-off-by: Chris Ball <cjb@laptop.org>
Signed-off-by: Doug Anderson <dianders@chromium.org>
Change-Id: I8f33ed81c9034c1127a363aef303f82a02acc44c
(cherry picked from commit
e74f3a9c993a088f0a067e13941075e4acb7300a)
Reviewed-on: https://gerrit.chromium.org/gerrit/45578
Reviewed-by: Bing Zhao <bzhao@marvell.com>
Reviewed-by: Paul Stewart <pstew@chromium.org>
John Sheu [Tue, 19 Mar 2013 22:20:45 +0000 (15:20 -0700)]
CHROMIUM: arm: exynos: s5p-mfc: Disable PMU configuration for MFC
For s5p-mfc, initializing the PMU configuration for the MFC block
appears to occasionally cause the MFC block to run in a
lower-performance state during video decoding, resulting in sub-realtime
performance for 1080p video decoding. Revert the PMU configuration,
just for the MFC block, while further debugging occurs.
BUG=chromium:220275
TEST=local build, run on snow
Change-Id: I70b04de1cd872a9b87b6e8cf8e7e85e48c87ad87
Reviewed-on: https://gerrit.chromium.org/gerrit/45928
Tested-by: John Sheu <sheu@chromium.org>
Reviewed-by: Doug Anderson <dianders@chromium.org>
Commit-Queue: John Sheu <sheu@chromium.org>
Kamil Debski [Fri, 11 Jan 2013 14:29:34 +0000 (11:29 -0300)]
s5p-mfc: end-of-stream handling in encoder bug fix
<UPSTREAM MERGE NOT REQUIRED>
linux-media commit
eb36209297b7aadbd3144c74cb79d35704c3086e
Original commit message as follows:
In some circumstances after issuing the V4L2_ENC_CMD_STOP the application
could freeze. This patch prevents this behavior.
Signed-off-by: Kamil Debski <k.debski@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Change-Id: I4c2befaedf39882c86b694ce30d25367449b1260
Signed-off-by: John Sheu <sheu@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/45101
John Sheu [Fri, 8 Mar 2013 02:37:13 +0000 (18:37 -0800)]
s5p-mfc: Fix kernel warning on memory init
<UPSTREAM MERGE NOT REQUIRED>
linux-media commit
6e83e6e25eb49dc57a69b3f8ecc1e764c9775101
Original commit message as follows:
Cleaned up the memory devices allocation code and added
missing device_initialize() call to remove the kernel warning
during memory allocations.
Signed-off-by: Arun Kumar K <arun.kk@samsung.com>
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Change-Id: Ie9cf1d8fcdc3e70acf23329449c8985eab5cd68e
Signed-off-by: John Sheu <sheu@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/45100
Sachin Kamat [Tue, 22 Jan 2013 04:00:06 +0000 (01:00 -0300)]
s5p-mfc: Use WARN_ON(condition) directly
<UPSTREAM MERGE NOT REQUIRED>
linux-media commit
e82564475eab196b2e8a11572fff8e268329530e
Original commit message as follows:
Use WARN_ON(condition) directly instead of wrapping around an if
condition.
Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Change-Id: Iea1296a0452dd1b948bd1e6ba41b3e8149f579a3
Signed-off-by: John Sheu <sheu@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/45099
Sachin Kamat [Mon, 14 Jan 2013 09:09:41 +0000 (06:09 -0300)]
s5p-mfc: Use NULL instead of 0 for pointer
<UPSTREAM MERGE NOT REQUIRED>
linux-media commit
0e5d61d87b3a1ad5591e0dfbe4c548f862e9f5a6
Original commit message as follows:
Fixes the following warning:
drivers/media/video/s5p-mfc/s5p_mfc_opr.c:56:27: warning:
Using plain integer as NULL pointer
Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Acked-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Change-Id: I94dadee385729b0bd35639d6a1f3b3f937370499
Signed-off-by: John Sheu <sheu@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/45098
Kamil Debski [Fri, 11 Jan 2013 14:29:32 +0000 (11:29 -0300)]
s5p-mfc: Fix a watchdog bug
<UPSTREAM MERGE NOT REQUIRED>
linux-media commit
33133ea7aca7eedf8b1b4cee514c76dce7654a8c
Original commit message as follows:
Fixed wrong condition in firmware reload function used by the watchdog.
Signed-off-by: Kamil Debski <k.debski@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Change-Id: I484659ec7100051b83df128a6aef28f02df91a3e
Signed-off-by: John Sheu <sheu@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/45097
John Sheu [Wed, 13 Feb 2013 22:03:59 +0000 (14:03 -0800)]
CHROMIUM: s5p-mfc: fix DISPLAY_DELAY
V4L2_CID_MPEG_MFC51_VIDEO_DECODER_H264_DISPLAY_DELAY_ENABLE is being
ignored, and the display delay is always being applied. Fix this.
Signed-off-by: John Sheu <sheu@google.com>
BUG=chromium:175638
BUG=chromium-os:38121
BUG=chromium-os:38376
BUG=chromium-os:38693
TEST=local build, run on snow
Change-Id: I0b098d021d656197d058e573cf66a3b1f624a275
Reviewed-on: https://gerrit.chromium.org/gerrit/43677
Reviewed-by: Pawel Osciak <posciak@chromium.org>
Commit-Queue: John Sheu <sheu@chromium.org>
Tested-by: John Sheu <sheu@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/45655
Reviewed-by: John Sheu <sheu@chromium.org>
John Sheu [Wed, 13 Feb 2013 21:53:56 +0000 (13:53 -0800)]
CHROMIUM: s5p-mfc: Fix input/output format reporting
The video encode/decode paths have duplicated logic between
VIDIOC_TRY_FMT and VIDIOC_S_FMT that should be de-duped. Also, video
decode reports V4L2_PIX_FMT_NV12MT_16X16 output format, regardless of
what the actual output has been set at. Fix this.
Signed-off-by: John Sheu <sheu@google.com>
BUG=chromium-os:38376
TEST=local build, run on snow
Change-Id: I3c4c5258733421f54340ca8237d2c5200cb76fc4
Reviewed-on: https://gerrit.chromium.org/gerrit/43676
Reviewed-by: Pawel Osciak <posciak@chromium.org>
Commit-Queue: John Sheu <sheu@chromium.org>
Tested-by: John Sheu <sheu@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/45654
Reviewed-by: John Sheu <sheu@chromium.org>
Naveen krishna Chatradhi [Tue, 31 Jul 2012 06:30:19 +0000 (12:00 +0530)]
exynos/mfc: add mfc device to power domain
This patch adds the mfc device to the genpd by calling the
function 'pm_genpd_of_add_device_by_name'. The power domain
is found by searching for a of property 'samsung,pd' in the of node.
BUG=chrome-os-partner:11793
Test=MFC/GSC/Sysmmu get suspended after probe and resume upon
video playback. Tested on Daisy.
Change-Id: I171fab67eb63a2e779dd2405befb080b35fa018e
Signed-off-by: Naveen krishna Chatradhi <ch.naveen@samsung.com>
Signed-off-by: Prathyush K <prathyush.k@samsung.com>
Reviewed-on: https://gerrit.chromium.org/gerrit/29164
Tested-by: Prathyush Kalashwaram <prathyush@chromium.org>
Commit-Ready: Olof Johansson <olofj@chromium.org>
Reviewed-by: Olof Johansson <olofj@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/45653
Reviewed-by: John Sheu <sheu@chromium.org>
Tested-by: John Sheu <sheu@chromium.org>
Commit-Queue: John Sheu <sheu@chromium.org>
Prathyush K [Tue, 31 Jul 2012 07:50:52 +0000 (13:20 +0530)]
exynos/mfc: add sysmmu power on/off calls
This patch calls the sysmmu driver helper functions for resuming
and suspending its two sysmmus during mfc power on/off. This is required
for the sysmmus to resume/suspend along with the parent mfc device.
BUG=chrome-os-partner:11793
TEST=MFC/GSC/Sysmmu get suspended after probe and resume upon
video playback. Tested on Daisy.
Change-Id: I3faacf3dfc397c72402e9c981ff314007c94887d
Signed-off-by: Prathyush K <prathyush.k@samsung.com>
Reviewed-on: https://gerrit.chromium.org/gerrit/29165
Tested-by: Prathyush Kalashwaram <prathyush@chromium.org>
Reviewed-by: Olof Johansson <olofj@chromium.org>
Commit-Ready: Olof Johansson <olofj@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/42960
Commit-Queue: John Sheu <sheu@chromium.org>
Reviewed-by: John Sheu <sheu@chromium.org>
Tested-by: John Sheu <sheu@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/44767
Subash Patel [Fri, 20 Jul 2012 10:16:20 +0000 (15:46 +0530)]
arm: exynos: sysmmu: release iommu mapping during module exit
This change will add support for detaching iommu mapping, domain
and switchoff the hardware for an attached device.
This commit adds the following changes:
a) support in dma-mapping framework to call iommu_detach_device()
b) support in the exynos to call arm_iommu_detach_device() and
arm_iommu_release_mapping()
c) changes to the module exit of drm_drv, drm_fimd, gsc, tv and mfc
BUG=chrome-os-partner:11310
TEST=none
Change-Id: I35afd8c96ea3ad8427d9b8a7c0cf449aa4121f4e
Signed-off-by: Subash Patel <subash.ramaswamy@linaro.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/27362
Tested-by: Jon Kliegman <kliegs@chromium.org>
Reviewed-by: Sonny Rao <sonnyrao@chromium.org>
Commit-Ready: Anush Elangovan <anush@google.com>
Reviewed-by: Anush Elangovan <anush@google.com>
Reviewed-by: Pawel Osciak <posciak@google.com>
Reviewed-on: https://gerrit.chromium.org/gerrit/45652
Reviewed-by: John Sheu <sheu@chromium.org>
Tested-by: John Sheu <sheu@chromium.org>
Commit-Queue: John Sheu <sheu@chromium.org>
John Sheu [Thu, 7 Feb 2013 01:13:54 +0000 (17:13 -0800)]
ARM: EXYNOS: MFC: Add IOMMU mapping to MFC probe
IOMMU mapping is created for mfc device during probe. This
requires the sysmmu_l and sysmmu_r property be set in the DTS
file. First, the sysmmu device nodes are found and then the
sysmmu platform devices are retrieved. A IOMMU mapping is then created
for mfc_l and mfc_r devices.
Change-Id: Ic7e6669911d2629c8872e78e5e187950484a8c35
Signed-off-by: Prathyush K <prathyush.k@samsung.com>
Reviewed-on: https://gerrit.chromium.org/gerrit/42958
Reviewed-by: Pawel Osciak <posciak@chromium.org>
Commit-Queue: John Sheu <sheu@chromium.org>
Tested-by: John Sheu <sheu@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/45096
Reviewed-by: John Sheu <sheu@chromium.org>
John Sheu [Fri, 8 Mar 2013 04:32:08 +0000 (20:32 -0800)]
s5p-mfc: remove V4L2_FL_LOCK_ALL_FOPS from s5p-mfc
<UPSTREAM MERGE NOT REQUIRED>
The upstream (3.9+) s5p-mfc driver handles its own locking.
BUG=chromium-os:38376
TEST=local build, run on snow
Change-Id: I0aaff284a6b0a156f10d5dca39b5ee37f3287e9c
Signed-off-by: John Sheu <sheu@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/45095
Derek Basehore [Tue, 19 Mar 2013 00:36:25 +0000 (17:36 -0700)]
CHROMIUM: rtc: fix bug with setting control register
A bit in the RTC_CONTROL register was accidentally lost in cmos_caused_wake.
It seems that this effectively moved us from 24 hour format to 12 hour format in
practice. This can cause the time from the RTC to be misinterpreted, so the
system will read the wrong time from the RTC. It might then go back to an
old value for the system time (and also store that in the RTC).
BUG=chromium:216936
TEST=suspend resume system (with dark resume happening)
Change-Id: I1425b857caf49ce3e538dfc05b981153729565f9
Signed-off-by: Derek Basehore <dbasehore@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/45823
Reviewed-by: Luigi Semenzato <semenzato@chromium.org>
Mauro Carvalho Chehab [Thu, 24 Jan 2013 20:49:18 +0000 (18:49 -0200)]
s5p-mfc: merge upstream merge
<UPSTREAM MERGE NOT REQUIRED>
linux-media commit
a32f7d1ad3744914273c6907204c2ab3b5d496a0
Only changes to drivers/media/video/s5p-mfc are merged here.
Original commit message follows:
Merge branch 'v4l_for_linus' into staging/for_v3.9
* v4l_for_linus: (464 commits)
[media] uvcvideo: Set error_idx properly for S_EXT_CTRLS failures
[media] uvcvideo: Cleanup leftovers of partial revert
[media] uvcvideo: Return -EACCES when trying to set a read-only control
Linux 3.8-rc3
mm: reinstante dropped pmd_trans_splitting() check
cred: Remove tgcred pointer from struct cred
drm/ttm: fix fence locking in ttm_buffer_object_transfer
ARM: clps711x: Fix bad merge of clockevents setup
ARM: highbank: save and restore L2 cache and GIC on suspend
ARM: highbank: add a power request clear
ARM: highbank: fix secondary boot and hotplug
ARM: highbank: fix typos with hignbank in power request functions
ARM: dts: fix highbank cpu mpidr values
ARM: dts: add device_type prop to cpu nodes on Calxeda platforms
drm/prime: drop reference on imported dma-buf come from gem
xen/netfront: improve truesize tracking
ARM: mx5: Fix MX53 flexcan2 clock
ARM: OMAP2+: am33xx-hwmod: Fix wrongly terminated am33xx_usbss_mpu_irqs array
sctp: fix Kconfig bug in default cookie hmac selection
EDAC: Cleanup device deregistering path
...
Conflicts:
drivers/media/pci/dm1105/dm1105.c
drivers/media/video/soc_camera/mx2_camera.c
Change-Id: I80ec2451fff2a9ff43927f31dcd8cacd1dd44a6c
Signed-off-by: John Sheu <sheu@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/44766
Reviewed-by: Pawel Osciak <posciak@chromium.org>
Julius Werner [Wed, 13 Mar 2013 18:39:27 +0000 (11:39 -0700)]
CHROMIUM: Disable USB persist system-wide by default.
This patch effectively reverts upstream commit
9214d1d8, which enabled
USB persist by default. We have long had disabled persist on ChromeOS
through an explicit sysfs write from powerd_suspend to save kernel
resume time. This change will make that solution obsolete by disabling
persist by default from the kernel, resulting in a much cleaner system
state that does not flip-flop between persist/non-persist during
suspend/resume. This will also solve issues with autosuspend on drivers
that do not provide a reset_resume method.
BUG=chrome-os-partner:17609
TEST=Boot kernel, make sure that /sys/bus/usb/devices/*/power/persist
are all zeroes (and stay that way over suspend and when plugging in more
devices).
Change-Id: If3ef6423a82aa9af0cb1b10c49da0ffa8201224a
Signed-off-by: Julius Werner <jwerner@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/45326
Reviewed-by: Vincent Palatin <vpalatin@chromium.org>
Reviewed-by: Sameer Nanda <snanda@chromium.org>
Pawel Osciak [Tue, 19 Mar 2013 17:22:40 +0000 (10:22 -0700)]
CHROMIUM: MFC video nodes should start from video10
This restores a patch that was overwritten by MFC driver backport.
This workaround is required for factory camera tests that don't understand
mem2mem devices and fail on trying to interrogate MFC.
Signed-off-by: Pawel Osciak <posciak@chromium.org>
BUG=chromium:222071
TEST=manual
Change-Id: Ie7a2b4e52c45ff254535c783725f6a572a16cf02
Reviewed-on: https://gerrit.chromium.org/gerrit/45864
Reviewed-by: John Sheu <sheu@chromium.org>
Commit-Queue: Pawel Osciak <posciak@chromium.org>
Tested-by: Pawel Osciak <posciak@chromium.org>
Stuart Abercrombie [Tue, 19 Mar 2013 01:00:57 +0000 (18:00 -0700)]
Restrict DP sink wake up to non-EDP.
Doing it on EDP was producing a kernel warning with screen power down.
BUG=chrome-os-partner:17893
TEST=No warning with screen power down. Apple mini DP->VGA adapter still works.
Change-Id: I769c31b43753c7ced7cb0b2f0d50fc96c2486779
Reviewed-on: https://gerrit.chromium.org/gerrit/45814
Reviewed-by: Stéphane Marchesin <marcheu@chromium.org>
Commit-Queue: Stuart Abercrombie <sabercrombie@chromium.org>
Tested-by: Stuart Abercrombie <sabercrombie@chromium.org>
Hans Verkuil [Thu, 10 May 2012 07:57:22 +0000 (04:57 -0300)]
v4l2-dev: add flag to have the core lock all file operations
This used to be the default if the lock pointer was set, but now that lock is by
default only used for ioctl serialization. Those drivers that already used
core locking have this flag set explicitly, except for some drivers where
it was obvious that there was no need to serialize any file operations other
than ioctl.
The drivers that didn't need this flag were:
drivers/media/radio/dsbr100.c
drivers/media/radio/radio-isa.c
drivers/media/radio/radio-keene.c
drivers/media/radio/radio-miropcm20.c
drivers/media/radio/radio-mr800.c
drivers/media/radio/radio-tea5764.c
drivers/media/radio/radio-timb.c
drivers/media/video/vivi.c
sound/i2c/other/tea575x-tuner.c
The other drivers that use core locking and where it was not immediately
obvious that this flag wasn't needed were changed so that the flag is set
together with a comment that that driver needs work to avoid having to
set that flag. This will often involve taking the core lock in the fops
themselves.
Eventually this flag should go and it should not be used in new drivers.
There are a few reasons why we want to avoid core locking of non-ioctl
fops: in the case of mmap this can lead to a deadlock in rare situations
since when mmap is called the mmap_sem is held and it is possible for
other parts of the code to take that lock as well (copy_from_user()/copy_to_user()
perform a down_read(&mm->mmap_sem) when a page fault occurs).
It is very unlikely that that happens since the core lock serializes all
fops, but the kernel warns about it if lock validation is turned on.
For poll it is also undesirable to take the core lock as that can introduce
increased latency. The same is true for read/write.
While it was possible to make flags or something to turn on/off taking the
core lock for each file operation, in practice it is much simpler to just
not take it at all except for ioctl and leave it to the driver to take the
lock. There are only a handful fops compared to the zillion ioctls we have.
I also wanted to make it obvious which drivers still take the lock for all
fops, so that's why I chose to have drivers set it explicitly.
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Acked-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Change-Id: I0dc54aee9b2797dd1e799254a928af06524f45b0
Reviewed-on: https://gerrit.chromium.org/gerrit/45651
Reviewed-by: Pawel Osciak <posciak@chromium.org>
Commit-Queue: John Sheu <sheu@chromium.org>
Tested-by: John Sheu <sheu@chromium.org>
Andrei Emeltchenko [Thu, 24 May 2012 12:42:51 +0000 (15:42 +0300)]
Bluetooth: update stack to 3.8
AceLan Kao (3):
Bluetooth: Add support for IMC Networks [13d3:3393]
Bluetooth: Add support for Foxconn / Hon Hai [0489:e04e]
Bluetooth: Add support for Foxconn / Hon Hai [0489:e056]
Anderson Lizardo (1):
Bluetooth: Fix incorrect strncpy() in hidp_setup_hid()
Andre Guedes (48):
Bluetooth: Check FINDING state in interleaved discovery
Bluetooth: Add hci_cancel_le_scan() to hci_core
Bluetooth: LE support for MGMT stop discovery
Bluetooth: Replace EPERM by EALREADY in hci_cancel_inquiry
Bluetooth: Refactor stop_discovery
Bluetooth: Add Periodic Inquiry command complete handler
Bluetooth: Add HCI_PERIODIC_INQ to dev_flags
Bluetooth: Check HCI_PERIODIC_INQ in start_discovery
Bluetooth: Ignore inquiry results from periodic inquiry
Bluetooth: Add Periodic Inquiry command complete handler
Bluetooth: Add HCI_PERIODIC_INQ to dev_flags
Bluetooth: Remove MGMT_ADDR_INVALID macro
Bluetooth: Remove useless code in hci_connect
Bluetooth: Move address type macros to bluetooth.h
Bluetooth: Rename link_to_mgmt to link_to_bdaddr
Bluetooth: Add address type to struct sockaddr_l2
Bluetooth: Rename mgmt_to_le to bdaddr_to_le
Bluetooth: Move bdaddr_to_le to hci_core
Bluetooth: Add dst_type parameter to hci_connect
Bluetooth: Use address type info from user-space
Bluetooth: Remove advertising cache
Bluetooth: Change default MTU for L2CAP ATT channel
Bluetooth: Check MTU value in l2cap_sock_setsockopt_old
Bluetooth: Rename L2CAP_LE_DEFAULT_MTU
Bluetooth: Filter duplicated reports in LE scan
Bluetooth: Remove magic value in disconnect mgmt handler
Bluetooth: Use GFP_KERNEL in mgmt_handlers
Bluetooth: Use GFP_KERNEL in mgmt_pending_add
Bluetooth: Use GFP_KERNEL in mgmt events functions
Bluetooth: Remove missing code
Bluetooth: Use lmp_bredr_capable where applicable
Bluetooth: Use lmp_le_capable where applicable
Bluetooth: Use lmp_ssp_capable where applicable
Bluetooth: Use lmp_esco_capable where applicable
Bluetooth: Use lmp_rswitch_capable where applicable
Bluetooth: Use lmp_sniff_capable where applicable
Bluetooth: Use lmp_sniffsubr_capable where applicable
Bluetooth: Use lmp_no_flush_capable where applicable
Bluetooth: Remove locking in hci_user_passkey_request_evt
Bluetooth: Trivial refactoring
Bluetooth: Fix hci_le_conn_complete_evt
Bluetooth: Remove unneeded code
Bluetooth: Refactor hci_cs_le_create_conn
Bluetooth: Find hci_conn by BT_CONNECT state
Bluetooth: Lookup hci_conn in hci_le_conn_complete_evt
Bluetooth: Refactor in hci_le_conn_complete_evt
Bluetooth: Fix use-after-free bug in SMP
Bluetooth: Fix hci_conn timeout routine
Andrei Emeltchenko (181):
Revert "CHROMIUM: bluetooth: initialize rfc struct in l2cap_core.c"
Bluetooth: trivial: Correct endian conversion
Bluetooth: Correct type for hdev lmp_subver
Bluetooth: Correct type for ediv to __le16
Bluetooth: Fix extra conversion to __le32
Bluetooth: Correct chan->psm endian conversions
Bluetooth: Correct ediv in SMP
Bluetooth: Correct length calc in L2CAP conf rsp
Bluetooth: Correct CID endian notation
Bluetooth: Convert error codes to le16
Bluetooth: trivial: Fix endian conversion mode
Bluetooth: trivial: Correct types
Bluetooth: Fix type in cpu_to_le conversion
Bluetooth: Fix opcode access in hci_complete
Bluetooth: trivial: Remove sparse warnings
Bluetooth: Silence sparse warning
Bluetooth: Comments and style fixes
Bluetooth: Remove unneeded timer clear
Bluetooth: Make L2CAP chan_add functions static
Bluetooth: Remove unneeded zero initialization
Bluetooth: Add Read Local AMP Info to init
Bluetooth: Adds set_default function in L2CAP setup
Bluetooth: Fix debug printing unallocated name
Bluetooth: trivial: Remove empty line
Bluetooth: Remove unneeded calculation and magic number
Bluetooth: Silent sparse warnings
Bluetooth: Use defined link key size
Bluetooth: Preserve L2CAP flags values
Bluetooth: trivial: Remove empty line
Bluetooth: Define L2CAP conf continuation flag
Bluetooth: Define and use PSM identifiers
Bluetooth: Use __constant when dealing with constants
Bluetooth: Use __constant modifier in HCI code
Bluetooth: Define HCI AMP cmd struct
Bluetooth: Move clean up code and set of SOCK_ZAPPED to l2cap_sock.c
Bluetooth: Add l2cap_chan->ops->ready()
Bluetooth: trivial: Use defined PSMLEN instead of magic
Bluetooth: A2MP: Create A2MP channel
Bluetooth: A2MP: AMP Manager basic functions
Bluetooth: A2MP: Build and Send msg helpers
Bluetooth: A2MP: Add chan callbacks
Bluetooth: A2MP: Definitions for A2MP commands
Bluetooth: A2MP: Define A2MP status codes
Bluetooth: A2MP: Process A2MP messages
Bluetooth: A2MP: Process A2MP Command Reject
Bluetooth: A2MP: Process A2MP Discover Request
Bluetooth: A2MP: Process A2MP Change Notify
Bluetooth: A2MP: Process A2MP Get Info Request
Bluetooth: A2MP: Process A2MP Get AMP Assoc Request
Bluetooth: A2MP: Process A2MP Create Physlink Request
Bluetooth: A2MP: Process A2MP Disc Physlink Request
Bluetooth: A2MP: Process A2MP Command Responses
Bluetooth: A2MP: Handling fixed channels
Bluetooth: A2MP: Manage incoming connections
Bluetooth: Do not check func ready existence
Bluetooth: A2MP: Do not reference hci_conn
Bluetooth: Make l2cap_data_channel return void
Bluetooth: Make l2cap_conless_channel return void
Bluetooth: Make l2cap_att_channel return void
Bluetooth: Remove magic disconnect reason
Bluetooth: Use standard HCI cmd timeout for RESET
Bluetooth: Update HCI timeouts constants to use msecs_to_jiffies
Bluetooth: Add opcode to error message
Bluetooth: Correct debug print specifier for u16 objects
Bluetooth: Fix not setting HCI_RESET flag for AMP
Bluetooth: Fix compile warnings in mgmt
Bluetooth: Use AUTO_OFF constant in jiffies
Bluetooth: btmrvl: Do not send vendor events to bluetooth stack
Bluetooth: Improve debugging messages for hci_conn
Bluetooth: Fix warning: using int as NULL pointer
Bluetooth: Route traffic only through BR/EDR controller
Bluetooth: bluecard_cs: Shorten scope for iobase
Bluetooth: Do not auto off AMP controller
Bluetooth: btmrvl: trivial style fixes
Bluetooth: debug: Add printing num of cmds queued
Bluetooth: debug: Correct types specifiers for L2CAP
Bluetooth: debug: Print CID and PSM in hex format
Bluetooth: debug: Add debug to l2cap_security_cfm
Bluetooth: debug: Use standard hex object specifiers in hci_event
Bluetooth: debug: Print l2cap_chan refcount
Bluetooth: debug: Print amp_mgr refcnt
Bluetooth: mgmt: Managing only BR/EDR HCI controllers
Bluetooth: debug: Fix printing A2MP cmd code format
Bluetooth: debug: Fix printing refcnt for hci_conn
Bluetooth: trivial: Fix mixing spaces and tabs in smp
Bluetooth: Define AMP controller statuses
Bluetooth: Do not shadow hdr variable
Bluetooth: Fix processing A2MP chan in security_cfm
Bluetooth: Make connect / disconnect cfm functions return void
Bluetooth: smp: Fix possible NULL dereference
Bluetooth: trivial: Shorten variable scope
Bluetooth: trivial: Use preferred method for NULL check
Bluetooth: Remove unneeded zero init
Bluetooth: trivial: Make hci_chan_del return void
Bluetooth: trivial: Remove empty line
Bluetooth: debug: Print refcnt for hci_dev
Bluetooth: AMP: Add Read Data Block Size to amp_init
Bluetooth: Fix freeing uninitialized delayed works
Bluetooth: Add HCI logical link cmds definitions
Bluetooth: A2MP: Create amp_mgr global list
Bluetooth: AMP: Use HCI cmd to Read AMP Info
Bluetooth: AMP: Use HCI cmd to Read Loc AMP Assoc
Bluetooth: A2MP: Process Discover Response
Bluetooth: AMP: Physical link struct and helpers
Bluetooth: AMP: Remote AMP ctrl definitions
Bluetooth: AMP: Handle create / disc phylink req
Bluetooth: A2MP: Process A2MP Getinfo Rsp
Bluetooth: A2MP: Process A2MP Get AMP Assoc Rsp
Bluetooth: Choose connection based on capabilities
Bluetooth: AMP: Add AMP key calculation
Bluetooth: AMP: Create Physical Link
Bluetooth: AMP: Write remote AMP Assoc
Bluetooth: A2MP: Add fallback to normal l2cap init sequence
Bluetooth: AMP: Process Chan Selected event
Bluetooth: AMP: Accept Physical Link
Bluetooth: AMP: Handle Accept phylink command status evt
Bluetooth: Use %pMR in debug instead of batostr
Bluetooth: Use %pMR in sprintf/seq_printf instead of batostr
Bluetooth: Use %pMR instead of baswap in seq_show
bluetooth: Remove unneeded batostr function
Bluetooth: Factor out hci_queue_acl
Bluetooth: Factor out Create Configuration Response
Bluetooth: Use %zu print specifier for size_t type
Bluetooth: A2MP: Correct assoc_len size
Bluetooth: btmrvl: Correct num_block name
Bluetooth: btmrvl: Use DIV_ROUND_UP macro
Bluetooth: btmrvl: Fix skb buffer overflow
Bluetooth: A2MP: Fix potential NULL dereference
Bluetooth: AMP: Fix possible NULL dereference
Bluetooth: Fix dereference after NULL check
Bluetooth: AMP: Factor out amp_ctrl_add
Bluetooth: AMP: Factor out phylink_add
Bluetooth: AMP: Use block_mtu for AMP controller
Bluetooth: Adjust L2CAP Max PDU size for AMP packets
Bluetooth: L2CAP: Fix using default Flush Timeout for EFS
Bluetooth: btmrv: Use %*ph specifier instead of print_hex_dump_bytes
Bluetooth: Allow to set flush timeout
Bluetooth: AMP: Handle AMP_LINK timeout
Bluetooth: AMP: Add handle to hci_chan structure
Bluetooth: AMP: Handle number of compl blocks for AMP_LINK
Bluetooth: AMP: Handle AMP_LINK connection
Bluetooth: AMP: Hanlde AMP_LINK case in conn_put
Bluetooth: AMP: Use Loglink handle in ACL Handle field
Bluetooth: AMP: Handle complete frames in l2cap
Bluetooth: AMP: Drop packets when no l2cap conn exist
Bluetooth: Send EFS Conf Rsp only for BR/EDR chan
Bluetooth: Zero bredr pointer when chan is deleted
Bluetooth: AMP: Get amp_mgr reference in HS hci_conn
Bluetooth: trivial: Remove unneeded assignment
Bluetooth: Use helper function sending EFS conf rsp
Bluetooth: AMP: Process Physical Link Complete evt
Bluetooth: AMP: Process Logical Link complete evt
Bluetooth: Add put(hcon) when deleting hchan
Bluetooth: trivial: Fix braces style and remove empty line
Bluetooth: Save hs_hchan instead of hs_hcon in loglink complete
Bluetooth: Return correct L2CAP response type
Bluetooth: Derive remote and local amp id from chan struct
Bluetooth: AMP: Add Logical Link Create function
Bluetooth: AMP: Process Disc Logical Link
Bluetooth: AMP: Process Disc Physical Link Complete evt
Bluetooth: AMP: Remove hci_conn receiving error command status
Bluetooth: Disconnect logical link when deleting chan
Bluetooth: AMP: Check for hs_hcon instead of ctrl_id
Bluetooth: AMP: Use l2cap_physical_cfm in phylink complete evt
Bluetooth: Process Create Chan Request
Bluetooth: Rename ctrl_id to remote_amp_id
Bluetooth: Use __l2cap_no_conn_pending helper
Bluetooth: Remove unneeded local_amp_id initialization
Bluetooth: Refactor locking in amp_physical_cfm
Bluetooth: Disable FCS only for new HS channels
Bluetooth: trivial: Use __constant for constants
Bluetooth: Fix sending L2CAP Create Chan Req
Bluetooth: Set local_amp_id after getting Phylink Completed evt
Bluetooth: Improve error message printing
Bluetooth: AMP: Set no FCS for incoming L2CAP chan
Bluetooth: Refactor l2cap_send_disconn_req
Bluetooth: AMP: Mark controller radio powered down after HCIDEVDOWN
Bluetooth: AMP: Check that AMP is present and active
Bluetooth: Fix missing L2CAP EWS Conf parameter
Bluetooth: Process receiving FCS_NONE in L2CAP Conf Rsp
Bluetooth: trivial: Change NO_FCS_RECV to RECV_NO_FCS
Andrzej Kaczmarek (5):
Bluetooth: Allow only one LE connection attempt
Bluetooth: Return proper mgmt state when LE pairing connection failed
Bluetooth: Fix not removing hci_conn for failed LE connection
Bluetooth: mgmt: Fix enabling SSP while powered off
Bluetooth: mgmt: Fix enabling LE while powered off
Bing Zhao (1):
Bluetooth: btmrvl: add SD8787 Bluetooth AMP device ID
Cristian Chilipirea (1):
Bluetooth: Fixed checkpatch warnings
David Herrmann (5):
Bluetooth: Remove redundant hdev->parent field
Bluetooth: vhci: Ignore return code of nonseekable_open()
Bluetooth: Move hci_alloc/free_dev close to hci_register/unregister_dev
Bluetooth: Move device initialization to hci_alloc_dev()
Bluetooth: Remove unneeded initialization in hci_alloc_dev()
Denis Kirjanov (1):
Bluetooth:Replace list_for_each with list_for_each_entry() helper
Devendra Naga (1):
Bluetooth: cleanup dtl1_config
Dmitry Kasatkin (1):
Bluetooth: Add function to derive AMP key using hmac
Eldad Zack (1):
Bluetooth: bnep: use constant for ethertype
Frédéric Dalleau (2):
Bluetooth: Add BT_DEFER_SETUP option to sco socket
Bluetooth: Implement deferred sco socket setup
Giancarlo Formicuccia (1):
Bluetooth: add support for atheros 0930:0219
Gustavo Padovan (59):
Bluetooth: Remove sk parameter from l2cap_chan_create()
Bluetooth: Remove err parameter from alloc_skb()
Bluetooth: remove unneeded declaration of sco_conn_del()
Bluetooth: Remove unneeded elements from size calculation
Bluetooth: Remove hlen variable
Bluetooth: Fix wrong set of skb fragments
Bluetooth: Fix packet size provided to the controller
Bluetooth: Fix skb length calculation
Bluetooth: improve readability of l2cap_seq_list code
Bluetooth: report the right security level in getsockopt
Bluetooth: Create flags for bt_sk()
Bluetooth: Report proper error number in disconnection
Bluetooth: Fix coding style in mgmt.c
Bluetooth: Fix coding style in sco.c
Bluetooth: Fix coding style in hci_sock.c
Bluetooth: Fix coding style in hci_sysfs.c
Bluetooth: Fix coding style in hci_event.c
Bluetooth: Fix coding style in hci_conn.c
Bluetooth: Fix coding style in hci_core.c
Bluetooth: Do not purge queue in Basic Mode
Bluetooth: Remove double check for BT_CONNECTED
Bluetooth: Remove dead int returns
Bluetooth: Fix trailing whitespaces in license text
Bluetooth: Remove most of the inline usage
Bluetooth: Remove 'register' usage from the subsystem
Bluetooth: Fix coding style in include/net/bluetooth
Bluetooth: Fix coding style in the subsystem
Bluetooth: Remove unnecessary headers include
Bluetooth: Remove unneeded EXPORT_SYMBOL
Bluetooth: Use lmp_ssp_capable() macro
Bluetooth: Get a more accurate L2CAP PDU len
Bluetooth: Remove extra l2cap_state_change(BT_CONNECTED)
Bluetooth: Use l2cap_chan_ready() in LE path
Bluetooth: Use chan as parameters for l2cap chan ops
Bluetooth: Use chan->state instead of sk->sk_state
Bluetooth: Move check for backlog size to l2cap_sock.c
Bluetooth: check for already existent channel before create new one
Bluetooth: Create function to return the ERTM header size
Bluetooth: Remove unused err var from l2cap_segment_sdu()
Bluetooth: Create empty l2cap ops function
Bluetooth: Fix style in hidp code
Bluetooth: Fix possible deadlock in SCO code
Bluetooth: Use USB_VENDOR_AND_INTERFACE() for Broadcom devices
Bluetooth: Add USB_VENDOR_AND_INTERFACE_INFO() for Broadcom/Foxconn
Bluetooth: Fix two warnings in BT_DBG
Bluetooth: Fix L2CAP coding style
Bluetooth: Remove GFP_ATOMIC usage from l2cap_core.c
Bluetooth: use l2cap_chan_set_err()
Bluetooth: Use locked l2cap_state_change()
Bluetooth: Call ops->teardown() without checking for NULL
Bluetooth: Move bt_accept_enqueue() to l2cap_sock.c
Bluetooth: Add chan->ops->defer()
Bluetooth: Rename __l2cap_connect() to l2cap_connect()
Bluetooth: Replace *_init() for *_setup()
Bluetooth: Add missing lock nesting notation
Bluetooth: cancel power_on work when unregistering the device
Bluetooth: Move double negation to macros
Revert "Bluetooth: Fix possible deadlock in SCO code"
Bluetooth: Check if the hci connection exists in SCO shutdown
Hemant Gupta (5):
Bluetooth: Send correct address type for LTK
Bluetooth: Fix clearing discovery type when stopping discovery
Bluetooth: mgmt: Fix missing connect failed event for LE
Bluetooth: mgmt: Fix address type while loading Long Term Key
Bluetooth: Don't distribute keys in case of Encryption Failure
Henrik Rydberg (1):
Bluetooth: Add support for Apple vendor-specific devices
Ido Yariv (1):
Bluetooth: Search global l2cap channels by src/dst addresses
Jaganath Kanakkassery (5):
Bluetooth: Refactor PIN code rejection to use user_pairing_resp()
Bluetooth: Move l2cap_chan_hold/put to l2cap_core.c
Bluetooth: Free the l2cap channel list only when refcount is zero
Bluetooth: Fix socket not getting freed if l2cap channel create fails
Bluetooth: Fix authentication if acl data comes before remote feature evt
Jaroslav Resler (1):
Bluetooth: Add support for BCM20702A0 [04ca, 2003]
Jeff Cook (1):
Bluetooth: Add support for BCM20702A0 [0b05, 17b5]
Jefferson Delfes (2):
Bluetooth: Fix flags of mgmt_device_found event
Bluetooth: Force the process of unpair command if disconnect failed
Jesper Juhl (1):
Bluetooth: btmrvl_sdio: remove pointless conditional before release_firmware()
Joe Perches (1):
bluetooth: Convert compare_ether_addr to ether_addr_equal
Johan Hedberg (49):
Bluetooth: Fix Inquiry with RSSI event mask
Bluetooth: Fix SMP pairing method selection
Bluetooth: Fix deadlock and crash when SMP pairing times out
Bluetooth: Fix SMP security elevation from medium to high
Bluetooth: Add support for encryption key refresh
Bluetooth: Change page scan interval in fast connectable mode
Bluetooth: Initial skeleton for Three-wire UART (H5) support
Bluetooth: Add basic state tracking to Three-wire UART driver
Bluetooth: Add initial reliable packet support for Three-wire UART
Bluetooth: Add basic packet parsing to Three-wire UART driver
Bluetooth: Add initial packet sending support to Three-wire UART
Bluetooth: Add Three-wire header value convenience macros
Bluetooth: Fix/implement Three-wire reliable packet sending
Bluetooth: Add support for Three-wire Link Control packets
Bluetooth: Simplify hci_uart_tty_close logic
Bluetooth: Add delayed init sequence support for UART controllers
Bluetooth: Use delayed init for Three-wire UART
Bluetooth: Improve rx debug logs for Three-wire UART
Bluetooth: Add initial sleep support to Three-wire UART
Bluetooth: Add initialization tracking to HCI Three-wire driver
Bluetooth: Implement proper low-power support for Three-wire UART
Bluetooth: Remove unnecessary h5_build_pkt function
Bluetooth: Improve Three-wire UART configuration handling
Bluetooth: Introduce a flags variable to Three-wire UART state
Bluetooth: mgmt: Implement support for passkey notification
Bluetooth: Update management interface revision
Bluetooth: SMP: Fix setting unknown auth_req bits
Bluetooth: Add initial support for LE-only controllers
Bluetooth: Fix LE MTU reporting for HCIGETDEVINFO
Bluetooth: Add setting of the LE event mask
Bluetooth: Read adversiting channel TX power during init sequence
Bluetooth: Fix HCI command sending when powering on LE-only adapters
Bluetooth: mgmt: Restrict BR/EDR settings to BR/EDR-only adapters
Bluetooth: Fix updating host feature bits for LE
Bluetooth: Add missing feature test macros
Bluetooth: Make use feature test macros
Bluetooth: Add flag for LE GAP Peripheral role
Bluetooth: Disallow LE scanning and connecting in peripheral role
Bluetooth: Fix setting host feature bits for SSP
Bluetooth: Fix sending unnecessary HCI_Write_SSP_Mode command
Bluetooth: Fix unnecessary EIR update during powering on
Bluetooth: Fix sending unnecessary HCI_LE_Host_Enable
Bluetooth: Fix parameter order of hci_get_route
Bluetooth: Fix having bogus entries in mgmt_read_index_list reply
Bluetooth: Fix memory leak when removing a UUID
Bluetooth: Use proper invalid value for tx_power
Bluetooth: Add support for setting LE advertising data
Bluetooth: Fix updating advertising state flags and data
Bluetooth: Fix handling of unexpected SMP PDUs
Lamarque V. Souza (1):
HID: hidp: fallback to input session properly if hid is blacklisted
Lukasz Rymanowski (1):
Bluetooth: Remove not needed status parameter
Manoj Iyer (1):
Bluetooth: btusb: Add vendor specific ID (0a5c:21f4) BCM20702A0
Marcel Holtmann (12):
Bluetooth: Add TX power tag to EIR data
Bluetooth: Handle EIR tags for Device ID
Bluetooth: Add management command for setting Device ID
Bluetooth: Fix broken usage of put_unaligned_le16
Bluetooth: Fix broken usage of get_unaligned_le16
Bluetooth: Update management interface revision
Bluetooth: Split error handling for L2CAP listen sockets
Bluetooth: Split error handling for SCO listen sockets
Bluetooth: Don't check source address in SCO bind function
Bluetooth: Restrict to one SCO listening socket
Bluetooth: Enable Low Energy support by default
Bluetooth: Notify about device registration before power on
Marcos Chaparro (1):
Bluetooth: ath3k: Add support for VAIO VPCEH [0489:e027]
Marek Vasut (1):
Bluetooth: Support AR3011 in Acer Iconia Tab W500
Masatake YAMATO (8):
Bluetooth: /proc/net/ entries for bluetooth protocols
Bluetooth: Added /proc/net/bnep via bt_procfs_init()
Bluetooth: Added /proc/net/cmtp via bt_procfs_init()
Bluetooth: Added /proc/net/hci via bt_procfs_init()
Bluetooth: Added /proc/net/hidp via bt_procfs_init()
Bluetooth: Added /proc/net/l2cap via bt_procfs_init()
Bluetooth: Added /proc/net/rfcomm via bt_procfs_init()
Bluetooth: Added /proc/net/sco via bt_procfs_init()
Mat Martineau (66):
Bluetooth: Add definitions and struct members for new ERTM state machine
Bluetooth: Add a structure to carry ERTM data in skb control blocks
Bluetooth: Add the l2cap_seq_list structure for tracking frames
Bluetooth: Functions for handling ERTM control fields
Bluetooth: Improve ERTM sequence number offset calculation
Bluetooth: Remove duplicate structure members from bt_skb_cb
Bluetooth: Move recently-added ERTM header packing functions
Bluetooth: Initialize new l2cap_chan structure members
Bluetooth: Remove unused function
Bluetooth: Make better use of l2cap_chan reference counting
Bluetooth: Add Code Aurora Forum copyright
Bluetooth: Refactor L2CAP ERTM and streaming transmit segmentation
Bluetooth: Update tx_send_head when sending ERTM data
Bluetooth: Initialize the transmit queue for L2CAP streaming mode
Bluetooth: Fix a redundant and problematic incoming MTU check
Bluetooth: Restore locking semantics when looking up L2CAP channels
Bluetooth: Lock the L2CAP channel when sending
Bluetooth: Free allocated ERTM SREJ list if init fails
Bluetooth: Fix early return from l2cap_chan_del
Bluetooth: Change default state of ERTM disable flag
Bluetooth: Add a new L2CAP ERTM transmit state machine.
Bluetooth: Refactor l2cap_streaming_send
Bluetooth: Refactor l2cap_ertm_send
Bluetooth: Refactor l2cap_send_sframe
Bluetooth: Consolidate common receive code for ERTM and streaming mode
Bluetooth: Add streaming mode receive and incoming packet classifier
Bluetooth: Remove receive code that has been superceded
Bluetooth: Refactor l2cap_send_ack
Bluetooth: Use the transmit state machine for busy state changes
Bluetooth: Update l2cap_send_i_or_rr_or_rnr to fit the spec better
Bluetooth: Add the ERTM receive state machine
Bluetooth: Add implementation for retransmitting all unacked frames
Bluetooth: Send SREJ frames when packets go missing
Bluetooth: Reassemble all available data when retransmissions succeed.
Bluetooth: Handle SREJ requests to resend unacked frames
Bluetooth: Handle incoming REJ frames
Bluetooth: Use new header structures in l2cap_send_rr_or_rnr
Bluetooth: Check rules when setting retransmit or monitor timers
Bluetooth: Use the ERTM transmit state machine from timeout handlers
Bluetooth: Simplify the ERTM ack timeout
Bluetooth: Remove unneccesary inline
Bluetooth: Set txwin values for streaming mode
Bluetooth: Remove unused ERTM control field macros
Bluetooth: Enable ERTM by default
Bluetooth: Send a configuration request after security confirmation
Bluetooth: Use tx window from config response for ack timing
Bluetooth: Process create response and connect response identically
Bluetooth: Factor out common L2CAP connection code
Bluetooth: Add new l2cap_chan struct members for high speed channels
Bluetooth: Add L2CAP create channel request handling
Bluetooth: Remove unnecessary intermediate function
Bluetooth: Lookup channel structure based on DCID
Bluetooth: Channel move request handling
Bluetooth: Add new ERTM receive states for channel move
Bluetooth: Add move channel confirm handling
Bluetooth: Add state to hci_chan
Bluetooth: Move channel response
Bluetooth: Add logical link confirm
Bluetooth: Add move confirm response handling
Bluetooth: Handle physical link completion
Bluetooth: Flag ACL frames as complete for AMP controllers
Bluetooth: Do not send data during channel move
Bluetooth: Configure appropriate timeouts for AMP controllers
Bluetooth: Ignore BR/EDR packet size constraints when fragmenting for AMP
Bluetooth: Do not retransmit data during a channel move
Bluetooth: Start channel move when socket option is changed
Mathias Krause (6):
Bluetooth: HCI - Fix info leak in getsockopt(HCI_FILTER)
Bluetooth: HCI - Fix info leak via getsockname()
Bluetooth: RFCOMM - Fix info leak in getsockopt(BT_SECURITY)
Bluetooth: RFCOMM - Fix info leak in ioctl(RFCOMMGETDEVLIST)
Bluetooth: RFCOMM - Fix info leak via getsockname()
Bluetooth: L2CAP - Fix info leak via getsockname()
Michael Gruetzner (1):
Bluetooth: Add support for Foxconn/Hon Hai AR5BBU22 0489:E03C
Mikel Astiz (6):
Bluetooth: Use unsigned int instead of signed int
Bluetooth: Remove unnecessary check
Bluetooth: btusb: Dynamic alternate setting
Bluetooth: Add more HCI error codes
Bluetooth: Fix minor coding style in hci_event.c
Bluetooth: mgmt: Add device disconnect reason
Paulo Sérgio (1):
Bluetooth: Fix error status when pairing fails
Peng Chen (1):
Bluetooth: add support for atheros 0489:e057
Peter Senna Tschudin (5):
Bluetooth: bluecard_cs.c: removes unnecessary semicolon
Bluetooth: hci_ldisc.c: removes unnecessary semicolon
Bluetooth: hci_ll.c: removes unnecessary semicolon
Bluetooth: hci_vhci.c: removes unnecessary semicolon
Bluetooth: btuart_cs.c: removes unnecessary semicolon
Ram Malovany (3):
Bluetooth: Fix using NULL inquiry entry
Bluetooth: Fix using a NULL inquiry cache entry
Bluetooth: Set name_state to unknown when entry name is empty
Rami Rosen (1):
Bluetooth: remove unused member of hci_dev.
Sachin Kamat (12):
Bluetooth: Use devm_kzalloc in bcm203x.c file.
Bluetooth: Use devm_kzalloc in bfusb.c file
Bluetooth: Use devm_kzalloc in bluecard_cs.c file
Bluetooth: Use devm_kzalloc in bpa10x.c file
Bluetooth: Use devm_kzalloc in bt3c_cs.c file
Bluetooth: Use devm_kzalloc in btmrvl_sdio.c file
Bluetooth: Use devm_kzalloc in btsdio.c file
Bluetooth: Use devm_kzalloc in btuart_cs.c file
Bluetooth: Use devm_kzalloc in btusb.c file
Bluetooth: Use devm_kzalloc in btwilink.c file
Bluetooth: Use devm_kzalloc in dtl1_cs.c file
Bluetooth: Use module_platform_driver() in btwilink.c file
Sasha Levin (2):
Bluetooth: Really fix registering hci with duplicate name
Bluetooth: don't attempt to free a channel that wasn't created
Syam Sidhardhan (13):
Bluetooth: mgmt: Remove unwanted goto statements
Bluetooth: remove header declared but not defined
Bluetooth: Remove strtoba header declared but not defined
Bluetooth: Remove unused hci_le_ltk_reply()
Bluetooth: Remove unused hci_le_ltk_neg_reply()
Bluetooth: debug: Correct the PSM printing
Bluetooth: Use kref for l2cap channel reference counting
Bluetooth: Use __constant modifier for L2CAP SMP CID
Bluetooth: Use __constant modifier for RFCOMM PSM
Bluetooth: trivial: Remove newline before EOF
Bluetooth: Replace include linux/module.h with linux/export.h
Bluetooth: Remove unnecessary include export.h
Bluetooth: mgmt: Use __constant when dealing with constants
Szymon Janc (8):
Bluetooth: mgmt: Fix some code style and indentation issues
Bluetooth: mgmt: Don't allow to set invalid value to DeviceID source
Bluetooth: Remove unused HCI timeouts definitions
Bluetooth: Fix using uninitialized option in RFCMode
Bluetooth: Fix legacy pairing with some devices
Bluetooth: Increase HCI command tx timeout
Bluetooth: Remove OOB data if device was discovered in band
Bluetooth: Fix sending HCI commands after reset
Ulisses Furquim (1):
Bluetooth: Fix registering hci with duplicate name
Vinicius Costa Gomes (13):
Bluetooth: Add support for reusing the same hci_conn for LE links
Bluetooth: Fix checking the wrong flag when accepting a socket
Bluetooth: Remove some functions from being exported
Bluetooth: Rename LE and ACL connection functions
Bluetooth: Refactor LE connection into its own function
Bluetooth: Refactor ACL connection into its own function
Bluetooth: Refactor SCO connection into its own function
Bluetooth: Simplify a the connection type handling
Bluetooth: Add type information to the hci_connect() debug statement
Bluetooth: Fix establishing ESCO links
Bluetooth: Change signature of smp_conn_security()
Bluetooth: Fix sending a HCI Authorization Request over LE links
Bluetooth: Fix not removing power_off delayed work
Vishal Agarwal (3):
Bluetooth: Fix EIR data generation for mgmt_device_found
Bluetooth: Fix LE pairing completion on connection failure
Bluetooth: Fix sending HCI_Disconnect only when connected
Wei Yongjun (1):
Bluetooth: btmrvl: remove pointless conditional before kfree_skb()
Yevgeniy Melnichuk (1):
Bluetooth: Add support for Sony Vaio T-Series
Zhao Hongjiang (1):
net: change return values from -EACCES to -EPERM
BUG=chromium-os:38832
TEST=emerge-${BOARD} chromeos-kernel
Change-Id: I8e22c32da0c9b07a9dcc27ef91dcafd1f5a221da
Signed-off-by: Scott James Remnant <keybuk@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/44888
Todd Poynor [Wed, 3 Oct 2012 07:39:56 +0000 (00:39 -0700)]
CHROMIUM: cpufreq: interactive: run at fraction of hispeed_freq when load is low
When load is below go_hispeed_load, apply the percentage of CPU load to
a max frequency of hispeed_freq instead of the max speed. This avoids
jumping too quickly to hispeed_freq when it is a relatively low
percentage of max speed. This also allows go_hispeed_load to be set to
a high percentage relative to hispeed_freq (as a percentage of max speed,
again useful when hispeed_freq is a low fraction of max speed), to cap
larger loads at hispeed_freq. For example, a load of 60% will typically
move to 60% of hispeed_freq, not 60% of max speed. This causes the
governor to apply two different speed caps, depending on whether load is
below or above go_hispeed_load.
Also fix the type of hispeed_freq, which was u64, to match other
speed data types (and avoid overhead and allow division).
Signed-off-by: Todd Poynor <toddpoynor@google.com>
BUG=chrome-os-partner:11515
TEST=boot snow and sanity check governor stats (should be noop w/ current settings)
Change-Id: Ie2d0668be161c074aaad77db2037505431457b3a
Reviewed-on: https://gerrit.chromium.org/gerrit/38230
Reviewed-by: Sameer Nanda <snanda@chromium.org>
Reviewed-by: Todd Broch <tbroch@chromium.org>
Commit-Queue: Andrew Bresticker <abrestic@chromium.org>
Tested-by: Andrew Bresticker <abrestic@chromium.org>
Dylan Reid [Fri, 15 Feb 2013 00:05:03 +0000 (16:05 -0800)]
CHROMIUM: spring: dts: Use MAX98089 codec for audio.
Switch from 98095 for EVT build.
BUG=chrome-os-partner:17794
TEST=Play audio on Spring from speakers and headphones.
Change-Id: I1da995e905956c56a1c86f27eb71b735fc847a44
Signed-off-by: Dylan Reid <dgreid@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/43359
Reviewed-by: Vincent Palatin <vpalatin@chromium.org>
Reviewed-by: Olof Johansson <olofj@chromium.org>
Dylan Reid [Sat, 2 Mar 2013 01:22:07 +0000 (17:22 -0800)]
CHROMIUM: ASoC: samsung: Daisy - be specific about MAX98088/9
Spring uses the MAX98089 codec, which is supported by max98088.c. For
device tree indicate 98089 in case there is a need to differentiate in
the future.
BUG=chrome-os-partner:17794
TEST=play audio on snow and spring.
Change-Id: I9930363408e499c59ae66dd9719005eb769eb46e
Signed-off-by: Dylan Reid <dgreid@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/44446
Reviewed-by: Vincent Palatin <vpalatin@chromium.org>
Reviewed-by: Olof Johansson <olofj@chromium.org>
Chung-yih Wang [Thu, 14 Mar 2013 06:25:38 +0000 (14:25 +0800)]
CHROMIUM: Input: synaptics - report ABS_X, ABS_Y positions on Cr48
Signed-off-by: Chung-yih Wang <cywang@chromium.org>
BUG=chromium:191329
TEST=on device, type 'evtest' and enter the ID for touchpad device
Press a finger on the pad and see if there is ABS_X, ABS_Y
printed from evtest.
Change-Id: If2ff89aabbcee348f401c3c3f16543fac93d5d2e
Reviewed-on: https://gerrit.chromium.org/gerrit/45392
Commit-Queue: Chung-yih Wang <cywang@chromium.org>
Tested-by: Chung-yih Wang <cywang@chromium.org>
Reviewed-by: Chung-yih Wang <cywang@chromium.org>
Paul Taysom [Thu, 31 Jan 2013 21:44:23 +0000 (13:44 -0800)]
CHROMIUM: md: dm-verity: Fix to avoid a deadlock in dm-bufio
Changed the dm-verity prefetching to use a worker thread to avoid
a deadlock in dm-bufio.
If generic_make_request is called recursively, it queues the I/O
request on the current->bio_list without making the I/O request
and returns. The routine making the recursive call cannot wait
for the I/O to complete.
The deadlock occurred when one thread grabbed the bufio_client
mutex and waited for an I/O to complete but the I/O was queued
on another thread's current->bio_list and it was waiting to get
the mutex held by the first thread.
The fix allows only one I/O request from dm-verity to dm-bufio
per thread. To do this, the prefetch requests were queued on worker
threads.
In addition to avoiding the deadlock, this fix made a slight
improvement in performance.
seconds_kernel_to_login:
with prefetch: 8.43s
without prefetch: 9.2s
worker prefetch: 8.28s
BUG=chromium-os:39148
TEST=./run_remote_tests.sh --board=$B --remote=$IP suite:smoke
Signed-off-by: Paul Taysom <taysom@chromium.org>
Signed-off-by: Mikulas Patocka <mpatocka@redhat.com>
Cc: stable@kernel.org
Change-Id: I5f3cddfed507abfb8198fee71e713495f076b772
Reviewed-on: https://gerrit.chromium.org/gerrit/42422
Tested-by: Paul Taysom <taysom@chromium.org>
Reviewed-by: Mandeep Singh Baines <msb@chromium.org>
Reviewed-by: Olof Johansson <olofj@chromium.org>
Commit-Queue: Paul Taysom <taysom@chromium.org>
Paul Taysom [Wed, 16 Jan 2013 22:55:05 +0000 (14:55 -0800)]
CHROMIUM: md: dm-verity fixes chromeos needs
This CL has all the changes that needed to be made to
the upstream version of dm-verity.
1. Notify
2. Same paramaters as the old version of dm-verity
3. Opening device by uuid
See CL 41206
At Mandeep's suggestion, I've modified the upstream version of
verity to accept the legacy parameters. This means we can move
to the upstream version of verity without making changes to
out build, install and signing scripts.
Results from platform_BootPerfServer/control.perfalerts
on a Lucas
baseline CL
reboot_in_syslog 23 111
seconds_firmware_boot 30.86 30.75
seconds_kernel_to_chrome_exec 4.64 4.82
seconds_kernel_to_chrome_main 5.55 6.11
seconds_kernel_to_login 8.32 8.14
seconds_kernel_to_network 8.73 8.17
seconds_kernel_to_startup 1.63 1.72
seconds_kernel_to_startup_done 2.4 2.37
seconds_kernel_to_x_started 4.55 4.73
seconds_power_on_to_kernel 30.86 30.75
seconds_power_on_to_login 39.18 38.89 (30 sec wait for dev)
BUG=chromium-os:31803
TEST=platform_DMVerityCorruption, platform_DMVerityBitCorruption
Change-Id: Iaedc50bc679c931d77044589de1a305fcb5b0180
Signed-off-by: Paul Taysom <taysom@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/41468
Paul Taysom [Mon, 14 Jan 2013 16:36:18 +0000 (08:36 -0800)]
CHROMIUM: md: dm-verity convert to upstream version
This CL only has the upstream version of dm-verity.c.
It was take from the 3.4.22 version of linux.
I've also removed dm-verity.h and dm-bht.c which are not
part of the upstream version of verity.
Removed the old documenation and added the new documents.
The next CL will have have the changes to make it work.
BUG=chromium-os:31803
TEST=platform_DMVerityCorruption, platform_DMVerityBitCorruption
Change-Id: Ic7050bc2609ef322080f76286a1f41417dc7def8
Signed-off-by: Paul Taysom <taysom@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/41206
Tai-Hsu Lin [Tue, 12 Mar 2013 07:03:31 +0000 (15:03 +0800)]
CHROMIUM: input: cyapa - handling rt_suspend for fw_update
This patch handle the case where fw update may fail if the
device is currently runtime suspended. It forces the device
to resume before issuing soft reset. The patch also increases
waiting time/retry counts for a few commands.
Signed-off-by: Tai-Hsu Lin <sheckylin@chromium.org>
CQ-DEPEND=If3bd68194309bbe225c2357609ede1a7595b5eba
BUG=chromium-os:39500
TEST=echo 1000 > ${DEVICE_PATH}/power/runtime_suspend_scanrate/ms
echo -n 1 > ${DEVICE_PATH}/update_fw
Before the fix, fw update would fail. After the fix, it should
succeed.
Change-Id: I2cb891e28c7564a5bb47924a231d25e57e70373c
Reviewed-on: https://gerrit.chromium.org/gerrit/45307
Reviewed-by: Benson Leung <bleung@chromium.org>
Commit-Queue: Tai-Hsu Lin <sheckylin@chromium.org>
Tested-by: Tai-Hsu Lin <sheckylin@chromium.org>
Tai-Hsu Lin [Mon, 11 Mar 2013 10:08:15 +0000 (18:08 +0800)]
CHROMIUM: input: cyapa - adding more debug message
The patch adds debug messages when entering most functions
so that the call stack is more visible for the developer. It
also adds messages for some cases where the errors were silently
handled before.
Signed-off-by: Tai-Hsu Lin <sheckylin@chromium.org>
BUG=chromium-os:39606
TEST=boot a machine with Cypress trackpad and check the dmesg.
Change-Id: If3bd68194309bbe225c2357609ede1a7595b5eba
Reviewed-on: https://gerrit.chromium.org/gerrit/45063
Reviewed-by: Benson Leung <bleung@chromium.org>
Tested-by: Tai-Hsu Lin <sheckylin@chromium.org>
Commit-Queue: Tai-Hsu Lin <sheckylin@chromium.org>
Simon Glass [Sun, 10 Feb 2013 04:32:57 +0000 (20:32 -0800)]
CHROMIUM: charger-manager: Rewrite probe function
Split the probe function into separate functions in preparation for device
tree enablement.
Drop the extra rtc warning in the setup function and just do it once in
the probe function.
BUG=chrome-os-partner:10617
TEST=build and boot to kernel prompt on snow
See that the charger-manager still probes and appears to run correctly.
Change-Id: Ied0ddbc57c83869eb75a5b769ed2233b7742af15
Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/43025
Reviewed-by: Benson Leung <bleung@chromium.org>
Kees Cook [Fri, 8 Mar 2013 02:09:58 +0000 (18:09 -0800)]
CHROMIUM: drm/i915: bounds check execbuffer relocations
It is possible to wrap the counter used to allocate the buffer for
relocation copies. This could lead to heap writing overflows.
BUG=chromium-os:39733
TEST=link build, PoC fails
[sending upstream]
Change-Id: Ifdd4ae846042852a4462d70cfa3c3b84d5a9d133
Signed-off-by: Kees Cook <keescook@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/45118
Reviewed-by: Jorge Lucangeli Obes <jorgelo@chromium.org>
Reviewed-by: Stéphane Marchesin <marcheu@chromium.org>
Kees Cook [Mon, 11 Mar 2013 20:33:13 +0000 (13:33 -0700)]
CHROMIUM: signal: always clear sa_restorer on execve
When the new signal handlers are set up, the location of sa_restorer is
not cleared, leaking a parent process's address space location to
children. This allows for a potential bypass of the parent's ASLR by
examining the sa_restorer value returned when calling sigaction().
Based on what should be considered "secret" about addresses, it only
matters across the exec not the fork (since the VMAs haven't changed until
the exec). But since exec sets SIG_DFL and keeps sa_restorer, this is
where it should be fixed.
Given the few uses of sa_restorer, a "set" function was not written since
this would be the only use. Instead, we use __ARCH_HAS_SA_RESTORER, as
already done in other places.
Example of the leak before applying this patch:
$ cat /proc/$$/maps
...
7fb9f3083000-
7fb9f3238000 r-xp
00000000 fd:01 404469 .../libc-2.15.so
...
$ ./leak
...
7f278bc74000-
7f278be29000 r-xp
00000000 fd:01 404469 .../libc-2.15.so
...
1 0 (nil) 0x7fb9f30b94a0
2
4000000 (nil) 0x7f278bcaa4a0
3
4000000 (nil) 0x7f278bcaa4a0
4 0 (nil) 0x7fb9f30b94a0
...
BUG=chromium:177956
TEST=link build, PoC fails to show leaks
[sent upstream https://lkml.org/lkml/2013/3/11/498]
[changed #ifdef for pre-3.9 defines]
Change-Id: Icb92cc8a616f326f8df783b749ba1ffad24d98ce
Signed-off-by: Kees Cook <keescook@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/45130
Reviewed-by: Julien Tinnes <jln@chromium.org>
Todd Broch [Wed, 6 Mar 2013 17:11:37 +0000 (09:11 -0800)]
CHROMIUM: power,mkbp: Update PSU status via EC's MKBP.
EC has only one interrupt to the AP which is used to
signal keyboard input has arrived.
In order to signal change in power supply unit status (PSU) without
complicating and slowing keyboard response, we've added a virtual
keystroke, KEY_BATTERY, to signal change in PSU state.
Signed-off-by: Todd Broch <tbroch@chromium.org>
BUG=chrome-os-partner:17927
TEST=manual,
1. Plug-in AC supply, boot and login as root
2. Examine current PSU type
cat /sys/class/power_supply/cros_ec-charger/type
Mains
3. Unplug PSU, repeat 2. see same result
4. From EC console press 'BATTERY_KEY'
kpbress 0 7 1
5. Re-examine PSU type
cat /sys/class/power_supply/cros_ec-charger/type
UNKNOWN
Repeat steps 1-5 for various PSUs
Change-Id: Ie80f7ae45f8bb47dbad893eb87e5fb6df7a3e3cd
Reviewed-on: https://gerrit.chromium.org/gerrit/45074
Reviewed-by: Vincent Palatin <vpalatin@chromium.org>
Commit-Queue: Todd Broch <tbroch@chromium.org>
Tested-by: Todd Broch <tbroch@chromium.org>
Chih-Chung Chang [Sat, 9 Mar 2013 13:05:33 +0000 (21:05 +0800)]
CHROMIUM: ALSA: hda/ca0132 - Fix division by zero in ca0132_update_latency()
The original code avoids the division if the runtime parameters have
not been set by checking if it is still in the SNDRV_PCM_STATE_OPEN
state. However if the system is suspended between snd_pcm_open() and
snd_pcm_hw_params(), the state is changed from SNDRV_PCM_STATE_OPEN to
SNDRV_PCM_STATE_SUSPENDED, and the check misses the case.
The new check just looks at the runtime parameters directly to see if
it is already set.
BUG=chromium-os:39661
TEST=compile kernel
Change-Id: I2ba983e00e61c330fe04a5a93f34101f01893ac3
Signed-off-by: Chih-Chung Chang <chihchung@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/45022
Chung-yih Wang [Mon, 4 Mar 2013 11:10:07 +0000 (19:10 +0800)]
CHROMIUM: Input: atkbd - skip re-probing on non-KBD i8042 ports
The serio0 or "i8042 KBD port" (defined in i8042.c) is used for a system to
connect AT keyboard device in general. When a system resumes from suspend,
kernel rescans all serio ports again for matching devices with serio
driver one by one. Currently, the retry mechanism in atkbd_probe() may take
few milliseconds for each serial port. There will be four auxiliary ports if
multiplexing is enabled on the second serial port, and this will add the
latency of system resume or boot significantly. The patch tries to skip
reprobe mechanism for non-KBD ports in order to reduce the unresponsiveness
for a system with ps/2-type of touchpad resuming from suspend. By skipping
reprobes on non-KBD i8042 ports it could save 1+ seconds of latency.
BUG=chrome-os-partner:15015
TEST=on device; use powerd_suspend and then hit a key to wake it up
see if the trackpoint/trackpoint could be active in 2+ seconds
after resume instead of 3~4 seconds long
Change-Id: I0e62c351225b06af44b55e8600f6e37b05ae5a06
Signed-off-by: Chung-yih Wang <cywang@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/44518
Reviewed-by: Benson Leung <bleung@chromium.org>
Reviewed-by: Luigi Semenzato <semenzato@chromium.org>
Simon Glass [Sun, 17 Jun 2012 17:26:42 +0000 (10:26 -0700)]
CHROMIUM: power: charger-manager: Use device tree node
We should use the device tree for charger manager. As a first step, check
the node and enable the driver only if present.
BUG=chrome-os-partner:10617
TEST=build and boot to kernel prompt on snow
Change-Id: Ic57d927a8dc2a15c250fe280a8c330e3b8e896f1
Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/40168
Simon Glass [Sun, 17 Jun 2012 17:28:19 +0000 (10:28 -0700)]
CHROMIUM: power: dts: Add device tree binding for battery-system
This node brings together the various chargers and batteries into a single
unit called the battery system. It provides a unified view of the charge
state to user space.
This initial binding provides for the existing parameters in the driver.
BUG=chrome-os-partner:10617
TEST=build and boot to kernel prompt on snow
Change-Id: Ib5714d10dc2849779abb3f413deb5446fdfbdf81
Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/40167
Reviewed-by: Benson Leung <bleung@chromium.org>
Amitkumar Karwar [Tue, 3 Jul 2012 02:32:33 +0000 (19:32 -0700)]
UPSTREAM: mwifiex: add set_antenna handler support
This enables user to set mode of Tx/Rx path using "iw set antenna"
command. For non MIMO chips, the command will be used for selecting
specific antenna or configuring antenna diversity mode.
Signed-off-by: Amitkumar Karwar <akarwar@marvell.com>
Signed-off-by: Bing Zhao <bzhao@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Signed-off-by: Paul Stewart <pstew@chromium.org>
BUG=chrome-os-partner:17995
TEST=Used "iw phy phy0 set antenna 3 3" and "iw phy phy0 set antenna 1 1"
("iw phy phy0 set antenna 2 2" does not work).
Change-Id: I34a16db8c9d14eb4f8123fbb8005a56f28f3c429
Reviewed-on: https://gerrit.chromium.org/gerrit/44729
Reviewed-by: Ajay Gummalla <agummalla@chromium.org>
Reviewed-by: Bing Zhao <bzhao@marvell.com>
Reviewed-by: Christopher Wiley <wiley@chromium.org>
Commit-Queue: Paul Stewart <pstew@chromium.org>
Tested-by: Paul Stewart <pstew@chromium.org>
Xi Wang [Thu, 7 Mar 2013 05:13:51 +0000 (00:13 -0500)]
UPSTREAM: ALSA: hda/ca0132 - Avoid division by zero in dspxfr_one_seg()
Move the zero check `hda_frame_size_words == 0' before the modulus
`buffer_size_words % hda_frame_size_words'.
Also remove the redundant null check `buffer_addx == NULL'.
Signed-off-by: Xi Wang <xi.wang@gmail.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Dylan Reid <dgreid@chromium.org>
Conflicts:
sound/pci/hda/patch_ca0132.c
BUG=chromium-os:39661
TEST=play audio on link.
Change-Id: I926b440ba3a5d2a7ccbba63b60a7d5f116b93766
Reviewed-on: https://gerrit.chromium.org/gerrit/44902
Reviewed-by: Chih-Chung Chang <chihchung@chromium.org>
Commit-Queue: Dylan Reid <dgreid@chromium.org>
Tested-by: Dylan Reid <dgreid@chromium.org>
Daniel Kurtz [Wed, 6 Mar 2013 04:29:09 +0000 (12:29 +0800)]
CHROMIUM: drm/exynos: Clean up DRM_DEBUG messages
The DRM_DEBUG messages in this driver do a pretty good job of generating
a function trace in dmesg when enabled.
This patch attempts to make this trace more useful in a few ways:
(1) Instead of dumping file names (which can be trivially deduced from
function names using grep), prefer dumping function parameters, especially
when they are drm object handles.
(2) Since DRM_DEBUG_* already dump function name; no need to explicitly
print it.
(3) Use the same style for naming CRTC, CONNECTOR and ENCODER in debug
messages as is used in the drm common code.
(4) Log when drm objects are created, add include the new objects handle.
(5) Add debug messages to a few more non-critical path functions.
Signed-off-by: Daniel Kurtz <djkurtz@chromium.org>
BUG=chromium-os:36608
TEST=Enable DRM_DEBUG_KMS, reboot, and inspect drm messages in dmesg
Change-Id: I6dc2e86be6ef64ca0384c407c9e90ad3c8b0f9e1
Reviewed-on: https://gerrit.chromium.org/gerrit/38890
Reviewed-by: Stéphane Marchesin <marcheu@chromium.org>
Reviewed-by: Daniel Kurtz <djkurtz@chromium.org>
Tested-by: Daniel Kurtz <djkurtz@chromium.org>
Commit-Queue: Daniel Kurtz <djkurtz@chromium.org>
Daniel Kurtz [Fri, 8 Mar 2013 03:56:36 +0000 (19:56 -0800)]
Revert "UPSTREAM: mmc: dw_mmc: correct the calculation for CLKDIV"
This reverts commit
abde7fecdb4aa9cdf11fc90c6bef5ddf8c193265
For some reason, with this patch my daisy kernel won't boot on my Lucas. Reverting for now for more investigation later.
BUG=chromium-os:39730
TEST=built & tested on daisy. Chrome OS boots w/out black screen.
Change-Id: I0b9f9bf363fcf87766299e76152d2a03ad89e469
Reviewed-on: https://gerrit.chromium.org/gerrit/44910
Commit-Queue: Daniel Kurtz <djkurtz@chromium.org>
Reviewed-by: Daniel Kurtz <djkurtz@chromium.org>
Tested-by: Daniel Kurtz <djkurtz@chromium.org>
Seungwon Jeon [Tue, 22 May 2012 04:01:21 +0000 (13:01 +0900)]
UPSTREAM: mmc: dw_mmc: correct the calculation for CLKDIV
In case of "host->bus_hz < slot->clock", divider value is
miscalculated. And clock divider register value is multiple of 2. If
calculated divider value is odd number, result can be over-clocking.
Signed-off-by: Seungwon Jeon <tgih.jun@samsung.com>
Acked-by: Will Newton <will.newton@gmail.com>
Signed-off-by: Chris Ball <cjb@laptop.org>
BUG=chrome-os-partner:16752
TEST=Boot spring+HS200 eMMC and check dmesg for mmc.0 output.
Signed-off-by: Grant Grundler <grundler@chromium.org>
Resolved conflict with previously backported:
Author: Abhilash Kesavan <a.kesavan@samsung.com>
Date: Mon Nov 19 10:26:21 2012 +0530
mmc: dw_mmc: Add sdio power bindings
Add dt-based retrieval of host sdio pm capabilities. Based on
the dt based discovery do a bus init in the resume function.
Change-Id: I50a5e258c2fc0985bed327f898bd9c7cac86bd3f
Reviewed-on: https://gerrit.chromium.org/gerrit/44788
Reviewed-by: Doug Anderson <dianders@chromium.org>
Commit-Queue: Grant Grundler <grundler@chromium.org>
Reviewed-by: Grant Grundler <grundler@chromium.org>
Tested-by: Grant Grundler <grundler@chromium.org>
Simon Glass [Sun, 17 Jun 2012 16:51:09 +0000 (09:51 -0700)]
CHROMIUM: power: tps65090: Add charger regulator and device tree support
Add a simple fdt binding to this driver. Also use a static struct to
provide the required power supply detail instead of assigning them at
run-time.
If the fdt node is not present or is disabled, we do not register the
driver. If the charger sub-node is not present, we do not register the
regulator, and operate entirely in passive mode (as the driver always
did before this change).
BUG=chrome-os-partner:10617
TEST=build and boot to kernel prompt on snow
Change-Id: I93ec83b44f53f497d1adf745ddb45e2d438402e4
Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/40166
Reviewed-by: Benson Leung <bleung@chromium.org>
Simon Glass [Sun, 3 Feb 2013 22:30:20 +0000 (14:30 -0800)]
CHROMIUM: Update tps65090 device tree entry for charger
Add a sub-node for charger. We do not specify a name for the regulator
since that would enable this function of the driver, although it would
not really have any effect. Still, we don't want this until/unless
charger-manager is enabled.
BUG=chrome-os-partner:10617
TEST=build and boot to kernel prompt on snow
With other changes, see that the charger can be enabled and disabled under
charger-manager control.
Change-Id: Ida12beedae31e848e775b7083ea2c998a35bda32
Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/43024
Paul Stewart [Wed, 6 Mar 2013 21:45:00 +0000 (13:45 -0800)]
Revert "CHROMEOS: config: Enable addrtype iptables match"
The addrtype rule ended up unused for multicast-reply
classification since this rule appears to interact improperly with NFQUEUE rules. As such, since it is unused,
it should be removed.
This reverts commit
2dba2b3b1c217795cc72dc5b61057d7020e1b3f7
BUG=chromium-os:38605
TEST=Compile kernel
Change-Id: I4b05b73252a054249a4dd46f029277867798f2a5
Reviewed-on: https://gerrit.chromium.org/gerrit/44758
Reviewed-by: Grant Grundler <grundler@chromium.org>
Commit-Queue: Paul Stewart <pstew@chromium.org>
Tested-by: Paul Stewart <pstew@chromium.org>
Reviewed-by: Jorge Lucangeli Obes <jorgelo@chromium.org>
Ashok Nagarajan [Thu, 21 Feb 2013 03:07:23 +0000 (19:07 -0800)]
CHROMIUM: Trigger a card reset on reaching tx_timeout threshold
tx_timeout doesn't always lead to a cmd_timeout. There are occurrences where
cmd_timeout never gets triggered for a long time and we encounter a kernel
crash. In this patch, we track the consecutive timeouts (tx_timeout_cnt). When
tx_timeout_cnt exceeds the threshold, trigger a card reset thereby avoiding a
kernel crash.
BUG=chrome-os-partner:15129
TEST=trigger tx_timeout and check if we see chip is reset after reaching
threshold
Change-Id: Ie893630ef3da9a091b178843bdec6e0bb88eb16d
Signed-off-by: Ashok Nagarajan <asnagarajan@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/43696
Todd Broch [Tue, 5 Mar 2013 21:22:42 +0000 (13:22 -0800)]
CHROMIUM: dts: spring: Enable cros_ec-charger in device tree.
Signed-off-by: Todd Broch <tbroch@chromium.org>
BUG=chrome-os-partner:17927
TEST=manual,
1. boot kernel, login as root
2. plug in various PSU's
3. check online status
power-supply-info | grep online
online: yes
4. unplug PSU
power-supply-info | grep online
online: no
Change-Id: Idc1d9fb52f9288ca6b0cce243be18087a51a1803
Reviewed-on: https://gerrit.chromium.org/gerrit/44683
Reviewed-by: Vincent Palatin <vpalatin@chromium.org>
Commit-Queue: Todd Broch <tbroch@chromium.org>
Tested-by: Todd Broch <tbroch@chromium.org>
Todd Broch [Tue, 5 Mar 2013 21:19:02 +0000 (13:19 -0800)]
CHROMIUM: config: exynos5: Enable cros_ec-charger driver.
Signed-off-by: Todd Broch <tbroch@chromium.org>
BUG=chrome-os-partner:17927
TEST=compile kernel successfully and see object file created.
CC drivers/power/chromeos_ec-charger.o
Change-Id: Idbb099932810e6d46a1ba65ccd711251caa98244
Reviewed-on: https://gerrit.chromium.org/gerrit/44682
Reviewed-by: Vincent Palatin <vpalatin@chromium.org>
Commit-Queue: Todd Broch <tbroch@chromium.org>
Tested-by: Todd Broch <tbroch@chromium.org>
Todd Broch [Fri, 1 Mar 2013 15:30:32 +0000 (07:30 -0800)]
CHROMIUM: power: chromeos_ec: charger driver.
On spring, the charger (tps65090) is abstracted via EC interface.
This CL creates a driver for the charger using EC's MKBP interface
(EC_CMD_POWER_INFO) and provides power supply property
POWER_SUPPLY_PROP_ONLINE.
Signed-off-by: Todd Broch <tbroch@chromium.org>
BUG=chrome-os-partner:17927
TEST=code compiles
Change-Id: I03c444e82771871f47dbd12a7f4f282c2e95be3d
Reviewed-on: https://gerrit.chromium.org/gerrit/44681
Reviewed-by: Vincent Palatin <vpalatin@chromium.org>
Commit-Queue: Todd Broch <tbroch@chromium.org>
Tested-by: Todd Broch <tbroch@chromium.org>
Luigi Semenzato [Tue, 5 Mar 2013 21:01:21 +0000 (13:01 -0800)]
Revert "CHROMIUM: TEMPORARY: dump stack to help debug p/17609"
This reverts commit
0af3fa94028ea0279311f81c0788910da770ce30.
Bug was reproduced, stack trace was achieved, done with this.
BUG=chrome-os-partner:17609
TEST=none
Change-Id: Ic8cc3dcc39dba88c43e3f22186c7b2feaa6036fe
Signed-off-by: Luigi Semenzato <semenzato@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/44665
Reviewed-by: Doug Anderson <dianders@chromium.org>
Vincent Palatin [Tue, 5 Mar 2013 02:22:41 +0000 (18:22 -0800)]
CHROMIUM: drm/bridge: control LCD and backlight FETs
Ensure we are powering on and off the FETs controlling the backlight and
the LCD VDD.
Signed-off-by: Vincent Palatin <vpalatin@chromium.org>
BUG=chrome-os-partner:18122
TEST=on Spring, use "powerd_suspend" to suspend the machine, and check
the state of the TPS65090 FETs by using the "pmu" on the EC command
line.
Change-Id: I3a0d03fdac18b4d13de2d33de6ba2e0429dd0daf
Reviewed-on: https://gerrit.chromium.org/gerrit/44599
Reviewed-by: Todd Broch <tbroch@chromium.org>
Reviewed-by: Stéphane Marchesin <marcheu@chromium.org>
Commit-Queue: Vincent Palatin <vpalatin@chromium.org>
Tested-by: Vincent Palatin <vpalatin@chromium.org>
Vincent Palatin [Tue, 5 Mar 2013 01:47:35 +0000 (17:47 -0800)]
CHROMIUM: mfd: init/link earlier
Move multi function devices earlier in the link sequence, in parity with
regulators.
The eDP bridge loaded by the DRM driver needs to be able to control the
screen regulators.
The regulators linking was moved earlier to have them available for
other subsystems :
https://lkml.org/lkml/2008/12/2/10
Now a lot of regulators are instantiated from MFD, so we need to move
the MFD to keep this benefit.
Signed-off-by: Vincent Palatin <vpalatin@chromium.org>
BUG=chrome-os-partner:18122
TEST=boot on Spring and see the traces from the virtual TPS65090
regulators earlier than the display port initialization.
Change-Id: I62223ea9fa79651a787754d45e05dd26edb7a029
Reviewed-on: https://gerrit.chromium.org/gerrit/44598
Reviewed-by: Todd Broch <tbroch@chromium.org>
Commit-Queue: Vincent Palatin <vpalatin@chromium.org>
Tested-by: Vincent Palatin <vpalatin@chromium.org>
Prathyush K [Tue, 31 Jul 2012 07:50:52 +0000 (13:20 +0530)]
exynos/mfc: add sysmmu power on/off calls
This patch calls the sysmmu driver helper functions for resuming
and suspending its two sysmmus during mfc power on/off. This is required
for the sysmmus to resume/suspend along with the parent mfc device.
BUG=chrome-os-partner:11793
TEST=MFC/GSC/Sysmmu get suspended after probe and resume upon
video playback. Tested on Daisy.
Change-Id: I989af8bb0aacb9991443ca90eb47068c67623a38
Signed-off-by: Prathyush K <prathyush.k@samsung.com>
Reviewed-on: https://gerrit.chromium.org/gerrit/29165
Tested-by: Prathyush Kalashwaram <prathyush@chromium.org>
Reviewed-by: Olof Johansson <olofj@chromium.org>
Commit-Ready: Olof Johansson <olofj@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/42960
Commit-Queue: John Sheu <sheu@chromium.org>
Reviewed-by: John Sheu <sheu@chromium.org>
Tested-by: John Sheu <sheu@chromium.org>
Arjun KV [Thu, 5 Jul 2012 09:47:48 +0000 (15:17 +0530)]
exynos: mfc: Increase the IOMMU memory size from 128MB to 256MB
This change is required for 1080p multiple instance video playback.
We need to increase the MFC, GSC and DRM-FIMD IOMMU memory size
from 128MB to 256MB.
With this change all VDA scenarios including multi instance playback
are handled.
BUG=None
TEST=emerge-daisy chromeos-kernel,
run 4 instance 1080p h264 video.
Change-Id: Iabbbccdc366145891b0e0f4eb12a41e68fe62451
Signed-off-by: Arjun KV <arjun.kv@samsung.com>
Reviewed-on: https://gerrit.chromium.org/gerrit/26813
Reviewed-by: kiran <kiran@chromium.org>
Tested-by: kiran <kiran@chromium.org>
Reviewed-by: Sunil M <sunilm.samsung@gmail.com>
Reviewed-by: Subash Patel <subash@chromium.org>
Reviewed-by: Pawel Osciak <posciak@google.com>
Reviewed-on: https://gerrit.chromium.org/gerrit/42959
Commit-Queue: John Sheu <sheu@chromium.org>
Reviewed-by: John Sheu <sheu@chromium.org>
Tested-by: John Sheu <sheu@chromium.org>
Sean Paul [Wed, 27 Feb 2013 06:45:05 +0000 (01:45 -0500)]
drm/bridge: Convert ps8622 into a drm_bridge
Change ps8622 driver from an i2c driver to a drm_bridge. This allows us
to control the bridge with dpms, as well as more tightly control the
order of power on.
BUG=chrome-os-partner:17557
TEST=Builds
Change-Id: Ie98b5728ee99cad311c72122fdf781b40467c126
Signed-off-by: Sean Paul <seanpaul@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/43941
Reviewed-by: Stéphane Marchesin <marcheu@chromium.org>
Commit-Queue: Vincent Palatin <vpalatin@chromium.org>
Tested-by: Vincent Palatin <vpalatin@chromium.org>
Sean Paul [Mon, 25 Feb 2013 20:52:26 +0000 (15:52 -0500)]
CHROMIUM: CONFIG: Change PS8622 to DRM_PS8622
The config option changed, update to reflect the new name.
BUG=chrome-os-partner:17557
TEST=Builds
Change-Id: Id904cf20c2bda00dd7a2a9d59c70297ef1e05e2d
Signed-off-by: Sean Paul <seanpaul@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/43940
Reviewed-by: Stéphane Marchesin <marcheu@chromium.org>
Commit-Queue: Vincent Palatin <vpalatin@chromium.org>
Tested-by: Vincent Palatin <vpalatin@chromium.org>
Sean Paul [Mon, 25 Feb 2013 20:35:25 +0000 (15:35 -0500)]
drm/bridge: Move ps8622 driver into drm/bridge
Move the ps8622 bridge driver into drm/bridge.
BUG=chrome-os-partner:17557
TEST=Builds
Change-Id: I153539311c5a31aafab9deff1f74384a70bc48c4
Signed-off-by: Sean Paul <seanpaul@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/43939
Reviewed-by: Stéphane Marchesin <marcheu@chromium.org>
Commit-Queue: Vincent Palatin <vpalatin@chromium.org>
Tested-by: Vincent Palatin <vpalatin@chromium.org>
Sean Paul [Mon, 25 Feb 2013 20:26:25 +0000 (15:26 -0500)]
drm/exynos: Convert ptn bridge to drm_bridge
BUG=chrome-os-partner:17557
TEST=Tested on snow
Change-Id: Ie9cc502325953bcb97b69660bebfe4641cda4acd
Signed-off-by: Sean Paul <seanpaul@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/43926
Reviewed-by: Stéphane Marchesin <marcheu@chromium.org>
Commit-Queue: Vincent Palatin <vpalatin@chromium.org>
Tested-by: Vincent Palatin <vpalatin@chromium.org>
Sean Paul [Fri, 22 Feb 2013 20:17:24 +0000 (15:17 -0500)]
drm/i2c: Move ptn3460 from i2c to bridge directory
In preparation of drm_bridge-ifying the ptn3460 driver.
BUG=chrome-os-partner:17557
TEST=Build kernel for daisy
Change-Id: Ia17fe2d4de3c23734e86716b47ee0337c55f518b
Signed-off-by: Sean Paul <seanpaul@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/43925
Reviewed-by: Stéphane Marchesin <marcheu@chromium.org>
Commit-Queue: Vincent Palatin <vpalatin@chromium.org>
Tested-by: Vincent Palatin <vpalatin@chromium.org>
Sean Paul [Mon, 25 Feb 2013 19:52:41 +0000 (14:52 -0500)]
drm/exynos: Move dp training into mode_set
Move the DP link training from the interrupt worker to the mode_set
callback.
BUG=chrome-os-partner:17557
TEST=Tested on snow, no regressions noted
Change-Id: I06fecce43500e4a2b64eda4aca18c889a811b1ed
Signed-off-by: Sean Paul <seanpaul@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/43924
Reviewed-by: Stéphane Marchesin <marcheu@chromium.org>
Commit-Queue: Vincent Palatin <vpalatin@chromium.org>
Tested-by: Vincent Palatin <vpalatin@chromium.org>
John Sheu [Thu, 7 Feb 2013 01:13:54 +0000 (17:13 -0800)]
ARM: EXYNOS: MFC: Add IOMMU mapping to MFC probe
IOMMU mapping is created for mfc device during probe. This
requires the sysmmu_l and sysmmu_r property be set in the DTS
file. First, the sysmmu device nodes are found and then the
sysmmu platform devices are retrieved. A IOMMU mapping is then created
for mfc_l and mfc_r devices.
Change-Id: I270211bd2583492818d2f2eb2c9bac73ba3956cd
Signed-off-by: Prathyush K <prathyush.k@samsung.com>
Reviewed-on: https://gerrit.chromium.org/gerrit/42958
Reviewed-by: Pawel Osciak <posciak@chromium.org>
Commit-Queue: John Sheu <sheu@chromium.org>
Tested-by: John Sheu <sheu@chromium.org>
John Sheu [Thu, 7 Feb 2013 00:23:15 +0000 (16:23 -0800)]
CHROMIUM: s5p-mfc: backport upstream s5p-mfc driver.
<UPSTREAM MERGE NOT REQUIRED>
Backport the upstream driver, for the purpose of enabling s5p-mfc hardware
video encoding.
Backport of changes up to
734d1ece37fbf3d2ddfc71bc6c69e0fe35f02542 from
linuxtv/staging/for_v3.9
Signed-off-by: John Sheu <sheu@google.com>
BUG=chromium-os:38376
BUG=chromium:167417
TEST=local build, run on snow
Change-Id: Iae484f49a16a8e753b8951b2db4433bc549a5e97
Reviewed-on: https://gerrit.chromium.org/gerrit/42957
Commit-Queue: John Sheu <sheu@chromium.org>
Reviewed-by: John Sheu <sheu@chromium.org>
Tested-by: John Sheu <sheu@chromium.org>
Steev Klimaszewski [Wed, 20 Feb 2013 20:12:03 +0000 (14:12 -0600)]
CHROMIUM:config:Enable CP210X module
The CP210X is another fairly common serial adapter.
BUG=None
TEST=Compile, boot kernel, plug in cp210x adapter, check that you get a
/dev/ttyUSB0 device.
Change-Id: Ibf79904fef9f93efca135960d48f7200b8c5fef8
Signed-off-by: Steev Klimaszewski <threeway@gmail.com>
Reviewed-on: https://gerrit.chromium.org/gerrit/43625
Commit-Queue: Olof Johansson <olofj@chromium.org>
Reviewed-by: Olof Johansson <olofj@chromium.org>
Arjun KV [Wed, 19 Dec 2012 06:54:53 +0000 (12:24 +0530)]
ARM: GPU: MALI: G3D ASV Lock Bit implementation
If G3D ASV lock bit is configured, all voltages in the G3D ASV table
have to be increased by 25mV.
BUG=chrome-os-partner:16615
TEST=Compile and boot kernel, cannot test
the exact changes till we get the new chip.
Change-Id: I8784ed290807ac5db86c706177403260742bbe89
Signed-off-by: Arjun.K.V <arjun.kv@samsung.com>
Reviewed-on: https://gerrit.chromium.org/gerrit/39467
Reviewed-by: Doug Anderson <dianders@chromium.org>
Tested-by: Doug Anderson <dianders@chromium.org>
Commit-Queue: Doug Anderson <dianders@chromium.org>
Arjun KV [Wed, 19 Dec 2012 06:10:25 +0000 (11:40 +0530)]
arm: exynos5: INT ASV Lock Bit implementation
If INT ASV lock bit is configured, all voltages in the INT ASV table
have to be increased by 25mV.
BUG=chrome-os-partner:16615
TEST=Compile and boot kernel, cannot test
the exact changes till we get the new chip.
Change-Id: I64ec69874bd4753b61efd46708cdf82046310dd2
Signed-off-by: Arjun.K.V <arjun.kv@samsung.com>
Reviewed-on: https://gerrit.chromium.org/gerrit/39466
Reviewed-by: Doug Anderson <dianders@chromium.org>
Tested-by: Doug Anderson <dianders@chromium.org>
Commit-Queue: Doug Anderson <dianders@chromium.org>
Arjun KV [Wed, 19 Dec 2012 05:29:00 +0000 (10:59 +0530)]
arm: exynos5: ARM ASV Lock Bit implementation
If lock bit is configured, voltage for cpu frequency in some
ranges(800-200MHz, 1000-200MHz, 1100-200MHz) should be locked with the
voltage of the locked cpu frequency. e.g. in 800-200MHz range all
frequencies below 800MHz will be configured with same voltage as
800MHz.
BUG=chrome-os-partner:16615
TEST=Compile and boot kernel. Add printouts to
exynos5250_cpufreq_get_asv() to confirm that the min_t() doesn't
actually change the index on existing systems where lock bits are all
0. Check that `dmesg` contains "EXYNOS5250: ASV lock int: 0 g3d: 0
arm: 0" which means that lock bits are all disabled.
[dianders cleaned up patch and CL description]
Change-Id: If5fcfae38af1bd01a5646ae94f7b010e564411cd
Signed-off-by: Arjun.K.V <arjun.kv@samsung.com>
Signed-off-by: Doug Anderson <dianders@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/39465
Yufeng Shen [Wed, 27 Feb 2013 23:21:56 +0000 (18:21 -0500)]
CHROMEOS: config: turn on HID_BATTERY_STRENGTH
This option allows external HID device to report its battery info
under /sys/class/power_supply/hid-xxx-battery
Signed-off-by: Yufeng Shen <miletus@chromium.org>
BUG=chromium-os:39317
TEST=Tested on Link with the new kernel, connect an Apple Magic Mouse
to it, and the battery info is shown under
/sys/class/power_supply/hid-xxx-battery
Change-Id: Ia05d8593673d5d1bd0e3f0def643713d8cb81e8e
Reviewed-on: https://gerrit.chromium.org/gerrit/44245
Reviewed-by: Olof Johansson <olofj@chromium.org>
Commit-Queue: Yufeng Shen <miletus@chromium.org>
Tested-by: Yufeng Shen <miletus@chromium.org>
Jiri Kosina [Tue, 24 Apr 2012 08:51:30 +0000 (10:51 +0200)]
UPSTREAM: HID: add Kconfig text to HID_BATTERY_STRENGTH
HID_BATTERY_STRENGTH is missing both help text and description text.
BUG=chromium-os:39317
TEST=set CONFIG_HID_BATTERY_STRENGTH=y in base.config. build the
kernel, and check that this option is enabled in the built kernel
cherry-picked from upstream commit
692d30d63b80b174d0ed24bbffb7a1ea536d5fee
Reported-by: Geert Uytterhoeven <geert@linux-m68k.org>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Change-Id: I2925c344b918e8b03953679ee5f856860fa09aa7
Reviewed-on: https://gerrit.chromium.org/gerrit/44249
Reviewed-by: Olof Johansson <olofj@chromium.org>
Commit-Queue: Yufeng Shen <miletus@chromium.org>
Reviewed-by: Yufeng Shen <miletus@chromium.org>
Tested-by: Yufeng Shen <miletus@chromium.org>
Doug Anderson [Thu, 28 Feb 2013 21:57:05 +0000 (13:57 -0800)]
CHROMIUM: config: Renormalize splitconfig
Just ran: ./chromeos/scripts/kernelconfig oldconfig
...and hit return for everything. AKA: no functional change
here, this just tells us where we are.
BUG=None
TEST=Compiled and booted on one device.
Change-Id: I92d6e364e9c95882e5c8bc10450fe97c79115e76
Signed-off-by: Doug Anderson <dianders@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/44312
Reviewed-by: Mike Frysinger <vapier@chromium.org>
Doug Anderson [Thu, 28 Feb 2013 21:58:11 +0000 (13:58 -0800)]
CHROMIUM: config: Build spidev into the kernel (not a module)
A recovery image needs to be able to access SPI in order to reflash
the firmware, but the recovery image doesn't include any modules.
Make spidev part of the kernel to avoid having yet another weird
config difference for the recovery kernel.
BUG=chrome-os-partner:13068
TEST=Manual:
1. Get an official recovery image (that is marked to do a firmware
flash) that contains this CL plus the modification to
mod_image_for_recovery.sh that enables it.
2. Boot on snow.
3. After reboot confirm that firmware got updated.
4. Also after reboot look in console-ramoops. If you see this:
[ 1157.020235] Chromium OS LSM: init_module locked module=
"/lib/modules/3.4.0/kernel/drivers/spi/spidev.ko" pid=1574
cmdline="modprobe spidev"
...then that's bad and it means that we loaded the spidev module
from the target USB key which isn't what we want to do.
TEST=Manual:
1. Hack up recovery image as described in chrome-os-partner:13068.
2. From first shell prompt in hacked recovery image type:
chroot /usb /usr/sbin/flashrom -r /tmp/foo.bin
3. Confirm that flashrom reports no errors.
4. Type lsmod
5. Confirm that spidev is not listed
Change-Id: Ic156895cb186d04d2c32370d7cf70a3ec4af55bc
Signed-off-by: Doug Anderson <dianders@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/44311
Reviewed-by: Mike Frysinger <vapier@chromium.org>
Kees Cook [Thu, 28 Feb 2013 00:01:13 +0000 (16:01 -0800)]
CHROMIUM: eCryptfs: allow userspace messaging to be disabled
When the userspace messaging (needed for ecryptfsd) is not needed, allow
eCryptfs to build with it removed. This saves on kernel code size and
reduces potential attack surface by removing the /dev/ecryptfs node.
BUG=chromium-os:35732
TEST=link build, /dev/ecryptfs is gone, eCryptfs still works.
[sent upstream for review:
http://marc.info/?l=ecryptfs-users&m=
136204079607329&w=2]
Change-Id: I1b2be61e0a455fc9f6e09a9f4a1b1f6d65d1903a
Signed-off-by: Kees Cook <keescook@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/44278
Reviewed-by: Will Drewry <wad@chromium.org>
Tyler Hicks [Thu, 13 Sep 2012 19:00:56 +0000 (12:00 -0700)]
UPSTREAM: eCryptfs: Copy up attributes of the lower target inode after rename
After calling into the lower filesystem to do a rename, the lower target
inode's attributes were not copied up to the eCryptfs target inode. This
resulted in the eCryptfs target inode staying around, rather than being
evicted, because i_nlink was not updated for the eCryptfs inode. This
also meant that eCryptfs didn't do the final iput() on the lower target
inode so it stayed around, as well. This would result in a failure to
free up space occupied by the target file in the rename() operation.
Both target inodes would eventually be evicted when the eCryptfs
filesystem was unmounted.
This patch calls fsstack_copy_attr_all() after the lower filesystem
does its ->rename() so that important inode attributes, such as i_nlink,
are updated at the eCryptfs layer. ecryptfs_evict_inode() is now called
and eCryptfs can drop its final reference on the lower inode.
http://launchpad.net/bugs/561129
Signed-off-by: Tyler Hicks <tyhicks@canonical.com>
Tested-by: Colin Ian King <colin.king@canonical.com>
Cc: <stable@vger.kernel.org> [2.6.39+]
BUG=chromium-os:35732
TEST=daisy build, ENOSPC bubbles up to userspace
(cherry picked from upstream commit
8335eafc2859e1a26282bef7c3d19f3d68868b8a)
Signed-off-by: Kees Cook <keescook@chromium.org>
Change-Id: I9d4aa7e91b6f132a1f16d9a8b509681977091907
Reviewed-on: https://gerrit.chromium.org/gerrit/44158
Tested-by: Kees Cook <keescook@chromium.org>
Reviewed-by: Will Drewry <wad@chromium.org>
Commit-Queue: Kees Cook <keescook@chromium.org>
Tyler Hicks [Thu, 13 Sep 2012 01:38:00 +0000 (18:38 -0700)]
UPSTREAM: eCryptfs: Call lower ->flush() from ecryptfs_flush()
Since eCryptfs only calls fput() on the lower file in
ecryptfs_release(), eCryptfs should call the lower filesystem's
->flush() from ecryptfs_flush().
If the lower filesystem implements ->flush(), then eCryptfs should try
to flush out any dirty pages prior to calling the lower ->flush(). If
the lower filesystem does not implement ->flush(), then eCryptfs has no
need to do anything in ecryptfs_flush() since dirty pages are now
written out to the lower filesystem in ecryptfs_release().
Signed-off-by: Tyler Hicks <tyhicks@canonical.com>
BUG=chromium-os:35732
TEST=daisy build, ENOSPC bubbles up to userspace
(cherry picked from upstream commit
64e6651dcc10e9d2cc6230208a8e6c2cfd19ae18)
Signed-off-by: Kees Cook <keescook@chromium.org>
Change-Id: I44d6ba0eb30b6eebbfbedf3a1d7a8d7eaed28c01
Reviewed-on: https://gerrit.chromium.org/gerrit/44157
Tested-by: Kees Cook <keescook@chromium.org>
Reviewed-by: Will Drewry <wad@chromium.org>
Commit-Queue: Kees Cook <keescook@chromium.org>
Tyler Hicks [Thu, 13 Sep 2012 01:02:46 +0000 (18:02 -0700)]
UPSTREAM: eCryptfs: Write out all dirty pages just before releasing the lower file
Fixes a regression caused by:
821f749 eCryptfs: Revert to a writethrough cache model
That patch reverted some code (specifically,
32001d6f) that was
necessary to properly handle open() -> mmap() -> close() -> dirty pages
-> munmap(), because the lower file could be closed before the dirty
pages are written out.
Rather than reapplying
32001d6f, this approach is a better way of
ensuring that the lower file is still open in order to handle writing
out the dirty pages. It is called from ecryptfs_release(), while we have
a lock on the lower file pointer, just before the lower file gets the
final fput() and we overwrite the pointer.
https://launchpad.net/bugs/
1047261
Signed-off-by: Tyler Hicks <tyhicks@canonical.com>
Reported-by: Artemy Tregubenko <me@arty.name>
Tested-by: Artemy Tregubenko <me@arty.name>
Tested-by: Colin Ian King <colin.king@canonical.com>
BUG=chromium-os:35732
TEST=daisy build, ENOSPC bubbles up to userspace
(cherry picked from upstream commit
7149f2558d5b5b988726662fe58b1c388337805b)
Signed-off-by: Kees Cook <keescook@chromium.org>
Change-Id: Ie713a160fb3899869af63fcf4ad0c29a2ab8ea79
Reviewed-on: https://gerrit.chromium.org/gerrit/44156
Tested-by: Kees Cook <keescook@chromium.org>
Reviewed-by: Will Drewry <wad@chromium.org>
Commit-Queue: Kees Cook <keescook@chromium.org>
Tim Sally [Thu, 12 Jul 2012 23:10:24 +0000 (19:10 -0400)]
UPSTREAM: eCryptfs: check for eCryptfs cipher support at mount
The issue occurs when eCryptfs is mounted with a cipher supported by
the crypto subsystem but not by eCryptfs. The mount succeeds and an
error does not occur until a write. This change checks for eCryptfs
cipher support at mount time.
Resolves Launchpad issue #338914, reported by Tyler Hicks in 03/2009.
https://bugs.launchpad.net/ecryptfs/+bug/338914
Signed-off-by: Tim Sally <tsally@atomicpeace.com>
Signed-off-by: Tyler Hicks <tyhicks@canonical.com>
BUG=chromium-os:35732
TEST=daisy build, ENOSPC bubbles up to userspace
(cherry picked from upstream commit
5f5b331d5c21228a6519dcb793fc1629646c51a6)
Signed-off-by: Kees Cook <keescook@chromium.org>
Change-Id: If3d6f7f13047e7a9a64c0f79441ca52ebab17979
Reviewed-on: https://gerrit.chromium.org/gerrit/44155
Tested-by: Kees Cook <keescook@chromium.org>
Reviewed-by: Will Drewry <wad@chromium.org>
Commit-Queue: Kees Cook <keescook@chromium.org>
Tyler Hicks [Tue, 3 Jul 2012 23:50:57 +0000 (16:50 -0700)]
UPSTREAM: eCryptfs: Revert to a writethrough cache model
A change was made about a year ago to get eCryptfs to better utilize its
page cache during writes. The idea was to do the page encryption
operations during page writeback, rather than doing them when initially
writing into the page cache, to reduce the number of page encryption
operations during sequential writes. This meant that the encrypted page
would only be written to the lower filesystem during page writeback,
which was a change from how eCryptfs had previously wrote to the lower
filesystem in ecryptfs_write_end().
The change caused a few eCryptfs-internal bugs that were shook out.
Unfortunately, more grave side effects have been identified that will
force changes outside of eCryptfs. Because the lower filesystem isn't
consulted until page writeback, eCryptfs has no way to pass lower write
errors (ENOSPC, mainly) back to userspace. Additionaly, it was reported
that quotas could be bypassed because of the way eCryptfs may sometimes
open the lower filesystem using a privileged kthread.
It would be nice to resolve the latest issues, but it is best if the
eCryptfs commits be reverted to the old behavior in the meantime.
This reverts:
32001d6f "eCryptfs: Flush file in vma close"
5be79de2 "eCryptfs: Flush dirty pages in setattr"
57db4e8d "ecryptfs: modify write path to encrypt page in writepage"
Signed-off-by: Tyler Hicks <tyhicks@canonical.com>
Tested-by: Colin King <colin.king@canonical.com>
Cc: Colin King <colin.king@canonical.com>
Cc: Thieu Le <thieule@google.com>
BUG=chromium-os:35732
TEST=daisy build, ENOSPC bubbles up to userspace
(cherry picked from upstream commit
821f7494a77627fb1ab539591c57b22cdca702d6)
Signed-off-by: Kees Cook <keescook@chromium.org>
Change-Id: I78b810a47117ddc53f641150a6d097fd95856ae7
Reviewed-on: https://gerrit.chromium.org/gerrit/44154
Tested-by: Kees Cook <keescook@chromium.org>
Reviewed-by: Will Drewry <wad@chromium.org>
Commit-Queue: Kees Cook <keescook@chromium.org>
Tyler Hicks [Thu, 21 Jun 2012 06:50:59 +0000 (23:50 -0700)]
UPSTREAM: eCryptfs: Initialize empty lower files when opening them
Historically, eCryptfs has only initialized lower files in the
ecryptfs_create() path. Lower file initialization is the act of writing
the cryptographic metadata from the inode's crypt_stat to the header of
the file. The ecryptfs_open() path already expects that metadata to be
in the header of the file.
A number of users have reported empty lower files in beneath their
eCryptfs mounts. Most of the causes for those empty files being left
around have been addressed, but the presence of empty files causes
problems due to the lack of proper cryptographic metadata.
To transparently solve this problem, this patch initializes empty lower
files in the ecryptfs_open() error path. If the metadata is unreadable
due to the lower inode size being 0, plaintext passthrough support is
not in use, and the metadata is stored in the header of the file (as
opposed to the user.ecryptfs extended attribute), the lower file will be
initialized.
The number of nested conditionals in ecryptfs_open() was getting out of
hand, so a helper function was created. To avoid the same nested
conditional problem, the conditional logic was reversed inside of the
helper function.
https://launchpad.net/bugs/911507
Signed-off-by: Tyler Hicks <tyhicks@canonical.com>
Cc: John Johansen <john.johansen@canonical.com>
Cc: Colin Ian King <colin.king@canonical.com>
BUG=chromium-os:35732
TEST=daisy build, ENOSPC bubbles up to userspace
(cherry picked from upstream commit
e3ccaa9761200952cc269b1f4b7d7bb77a5e071b)
Signed-off-by: Kees Cook <keescook@chromium.org>
Change-Id: Ic6b303d2b8ff2690bc938adce850b2eaedab98a7
Reviewed-on: https://gerrit.chromium.org/gerrit/44153
Tested-by: Kees Cook <keescook@chromium.org>
Reviewed-by: Will Drewry <wad@chromium.org>
Commit-Queue: Kees Cook <keescook@chromium.org>
Tyler Hicks [Tue, 22 May 2012 20:09:50 +0000 (15:09 -0500)]
UPSTREAM: eCryptfs: Unlink lower inode when ecryptfs_create() fails
ecryptfs_create() creates a lower inode, allocates an eCryptfs inode,
initializes the eCryptfs inode and cryptographic metadata attached to
the inode, and then writes the metadata to the header of the file.
If an error was to occur after the lower inode was created, an empty
lower file would be left in the lower filesystem. This is a problem
because ecryptfs_open() refuses to open any lower files which do not
have the appropriate metadata in the file header.
This patch properly unlinks the lower inode when an error occurs in the
later stages of ecryptfs_create(), reducing the chance that an empty
lower file will be left in the lower filesystem.
https://launchpad.net/bugs/872905
Signed-off-by: Tyler Hicks <tyhicks@canonical.com>
Cc: John Johansen <john.johansen@canonical.com>
Cc: Colin Ian King <colin.king@canonical.com>
BUG=chromium-os:35732
TEST=daisy build, ENOSPC bubbles up to userspace
(cherry picked from upstream commit
8bc2d3cf612994a960c2e8eaea37f6676f67082a)
Signed-off-by: Kees Cook <keescook@chromium.org>
Change-Id: I9ef97db96f1e1e594e5f995ae6c1293d1b3527e0
Reviewed-on: https://gerrit.chromium.org/gerrit/44152
Tested-by: Kees Cook <keescook@chromium.org>
Reviewed-by: Will Drewry <wad@chromium.org>
Commit-Queue: Kees Cook <keescook@chromium.org>
Tyler Hicks [Mon, 11 Jun 2012 22:42:32 +0000 (15:42 -0700)]
UPSTREAM: eCryptfs: Copy up POSIX ACL and read-only flags from lower mount
When the eCryptfs mount options do not include '-o acl', but the lower
filesystem's mount options do include 'acl', the MS_POSIXACL flag is not
flipped on in the eCryptfs super block flags. This flag is what the VFS
checks in do_last() when deciding if the current umask should be applied
to a newly created inode's mode or not. When a default POSIX ACL mask is
set on a directory, the current umask is incorrectly applied to new
inodes created in the directory. This patch ignores the MS_POSIXACL flag
passed into ecryptfs_mount() and sets the flag on the eCryptfs super
block depending on the flag's presence on the lower super block.
Additionally, it is incorrect to allow a writeable eCryptfs mount on top
of a read-only lower mount. This missing check did not allow writes to
the read-only lower mount because permissions checks are still performed
on the lower filesystem's objects but it is best to simply not allow a
rw mount on top of ro mount. However, a ro eCryptfs mount on top of a rw
mount is valid and still allowed.
https://launchpad.net/bugs/
1009207
Signed-off-by: Tyler Hicks <tyhicks@canonical.com>
Reported-by: Stefan Beller <stefanbeller@googlemail.com>
Cc: John Johansen <john.johansen@canonical.com>
BUG=chromium-os:35732
TEST=daisy build, ENOSPC bubbles up to userspace
(cherry picked from upstream commit
069ddcda37b2cf5bb4b6031a944c0e9359213262)
Signed-off-by: Kees Cook <keescook@chromium.org>
Change-Id: I1c087b735bbead871d8420c0346a25468539a6cd
Reviewed-on: https://gerrit.chromium.org/gerrit/44151
Tested-by: Kees Cook <keescook@chromium.org>
Reviewed-by: Will Drewry <wad@chromium.org>
Commit-Queue: Kees Cook <keescook@chromium.org>
Tyler Hicks [Mon, 11 Jun 2012 16:24:11 +0000 (09:24 -0700)]
UPSTREAM: eCryptfs: Gracefully refuse miscdev file ops on inherited/passed files
File operations on /dev/ecryptfs would BUG() when the operations were
performed by processes other than the process that originally opened the
file. This could happen with open files inherited after fork() or file
descriptors passed through IPC mechanisms. Rather than calling BUG(), an
error code can be safely returned in most situations.
In ecryptfs_miscdev_release(), eCryptfs still needs to handle the
release even if the last file reference is being held by a process that
didn't originally open the file. ecryptfs_find_daemon_by_euid() will not
be successful, so a pointer to the daemon is stored in the file's
private_data. The private_data pointer is initialized when the miscdev
file is opened and only used when the file is released.
https://launchpad.net/bugs/994247
Signed-off-by: Tyler Hicks <tyhicks@canonical.com>
Reported-by: Sasha Levin <levinsasha928@gmail.com>
Tested-by: Sasha Levin <levinsasha928@gmail.com>
BUG=chromium-os:35732
TEST=daisy build, ENOSPC bubbles up to userspace
(cherry picked from upstream commit
8dc6780587c99286c0d3de747a2946a76989414a)
Signed-off-by: Kees Cook <keescook@chromium.org>
Change-Id: I2d877799e3e4c6f4126f28cfacaca4c6e7f729a9
Reviewed-on: https://gerrit.chromium.org/gerrit/44150
Tested-by: Kees Cook <keescook@chromium.org>
Reviewed-by: Will Drewry <wad@chromium.org>
Commit-Queue: Kees Cook <keescook@chromium.org>
Tyler Hicks [Mon, 11 Jun 2012 17:21:34 +0000 (10:21 -0700)]
UPSTREAM: eCryptfs: Fix lockdep warning in miscdev operations
Don't grab the daemon mutex while holding the message context mutex.
Addresses this lockdep warning:
ecryptfsd/2141 is trying to acquire lock:
(&ecryptfs_msg_ctx_arr[i].mux){+.+.+.}, at: [<
ffffffffa029c213>] ecryptfs_miscdev_read+0x143/0x470 [ecryptfs]
but task is already holding lock:
(&(*daemon)->mux){+.+...}, at: [<
ffffffffa029c2ec>] ecryptfs_miscdev_read+0x21c/0x470 [ecryptfs]
which lock already depends on the new lock.
the existing dependency chain (in reverse order) is:
-> #1 (&(*daemon)->mux){+.+...}:
[<
ffffffff810a3b8d>] lock_acquire+0x9d/0x220
[<
ffffffff8151c6da>] __mutex_lock_common+0x5a/0x4b0
[<
ffffffff8151cc64>] mutex_lock_nested+0x44/0x50
[<
ffffffffa029c5d7>] ecryptfs_send_miscdev+0x97/0x120 [ecryptfs]
[<
ffffffffa029b744>] ecryptfs_send_message+0x134/0x1e0 [ecryptfs]
[<
ffffffffa029a24e>] ecryptfs_generate_key_packet_set+0x2fe/0xa80 [ecryptfs]
[<
ffffffffa02960f8>] ecryptfs_write_metadata+0x108/0x250 [ecryptfs]
[<
ffffffffa0290f80>] ecryptfs_create+0x130/0x250 [ecryptfs]
[<
ffffffff811963a4>] vfs_create+0xb4/0x120
[<
ffffffff81197865>] do_last+0x8c5/0xa10
[<
ffffffff811998f9>] path_openat+0xd9/0x460
[<
ffffffff81199da2>] do_filp_open+0x42/0xa0
[<
ffffffff81187998>] do_sys_open+0xf8/0x1d0
[<
ffffffff81187a91>] sys_open+0x21/0x30
[<
ffffffff81527d69>] system_call_fastpath+0x16/0x1b
-> #0 (&ecryptfs_msg_ctx_arr[i].mux){+.+.+.}:
[<
ffffffff810a3418>] __lock_acquire+0x1bf8/0x1c50
[<
ffffffff810a3b8d>] lock_acquire+0x9d/0x220
[<
ffffffff8151c6da>] __mutex_lock_common+0x5a/0x4b0
[<
ffffffff8151cc64>] mutex_lock_nested+0x44/0x50
[<
ffffffffa029c213>] ecryptfs_miscdev_read+0x143/0x470 [ecryptfs]
[<
ffffffff811887d3>] vfs_read+0xb3/0x180
[<
ffffffff811888ed>] sys_read+0x4d/0x90
[<
ffffffff81527d69>] system_call_fastpath+0x16/0x1b
Signed-off-by: Tyler Hicks <tyhicks@canonical.com>
BUG=chromium-os:35732
TEST=daisy build, ENOSPC bubbles up to userspace
(cherry picked from upstream commit
60d65f1f07a7d81d3eb3b91fc13fca80f2fdbb12)
Signed-off-by: Kees Cook <keescook@chromium.org>
Change-Id: I243163c4ca70dbc74d85a6fa59f5fb4d8b586103
Reviewed-on: https://gerrit.chromium.org/gerrit/44149
Tested-by: Kees Cook <keescook@chromium.org>
Reviewed-by: Sonny Rao <sonnyrao@chromium.org>
Commit-Queue: Kees Cook <keescook@chromium.org>
Tyler Hicks [Tue, 12 Jun 2012 18:17:01 +0000 (11:17 -0700)]
UPSTREAM: eCryptfs: Properly check for O_RDONLY flag before doing privileged open
If the first attempt at opening the lower file read/write fails,
eCryptfs will retry using a privileged kthread. However, the privileged
retry should not happen if the lower file's inode is read-only because a
read/write open will still be unsuccessful.
The check for determining if the open should be retried was intended to
be based on the access mode of the lower file's open flags being
O_RDONLY, but the check was incorrectly performed. This would cause the
open to be retried by the privileged kthread, resulting in a second
failed open of the lower file. This patch corrects the check to
determine if the open request should be handled by the privileged
kthread.
Signed-off-by: Tyler Hicks <tyhicks@canonical.com>
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Acked-by: Dan Carpenter <dan.carpenter@oracle.com>
BUG=chromium-os:35732
TEST=daisy build, ENOSPC bubbles up to userspace
(cherry picked from commit
9fe79d7600497ed8a95c3981cbe5b73ab98222f0)
Signed-off-by: Kees Cook <keescook@chromium.org>
Change-Id: I748856005c76dd310a5a1d8a053bcba01ddded77
Reviewed-on: https://gerrit.chromium.org/gerrit/44148
Tested-by: Kees Cook <keescook@chromium.org>
Reviewed-by: Will Drewry <wad@chromium.org>
Commit-Queue: Kees Cook <keescook@chromium.org>
Simon Glass [Sun, 10 Feb 2013 03:48:20 +0000 (19:48 -0800)]
CHROMIUM: charger-manager: Pass IRQ to wakeup check function
Since charger-manager knows the IRQ number it is looking for in the
wake-up check (it gets it from the RTC class), pass it to the platform
function so that this does not need to be hard-coded.
Add a function to exynos which return true if a particular GPIO is known
to be the sole reason for the wakeup event.
BUG=chrome-os-partner:10617
TEST=build and boot to kernel prompt on snow
Turn on debugging in setup-charger. Try waking up on snow using the
keyboard, the lid and a timer ('rtcwake -s 35 -d /dev/rtc1 -m mem').
See that only the timer causes this function to return true.
Note I did not test simultaneous wakeup. This could perhaps be done by
introducing a long delay in the function, to give me time to cause another
type of wakeup event. However, I did see an EC wakeup event at one point
and this caused the function to return false as required.
Change-Id: I96eb0387e36c097f0df0256c6be4879b3180d259
Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/43022
Simon Glass [Sun, 10 Feb 2013 04:09:47 +0000 (20:09 -0800)]
CHROMIUM: charger-manager: Tidy up suspend_again() device resume/suspend
The current implementation is pretty-much hard-coded. It doesn't really
provide for different devices to be easy connected or specified via the
device tree.
During suspend_again(), create a list of devices that need to be resumed
by walking up through the parents of the power supply and rtc devices.
Resume the list in reverse order so that parents come first. Then suspend
the list in forward order so that the children are suspended first.
This provides more flexibility for devices to be specified at run-time.
BUG=chrome-os-partner:10617
TEST=build and boot to kernel prompt on snow
Tested with charger-manager with other changes. See that it can remain
suspended (i.e. returns to suspend automatically after each wake).
Change-Id: I7c9f04330c437b3da32e58dd1e53e0e550b37a71
Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/43023
Reviewed-by: Benson Leung <bleung@chromium.org>
Bing Zhao [Tue, 26 Feb 2013 23:22:17 +0000 (15:22 -0800)]
Add debugging to trace the loss of hidden ssid
This patch will help to trace if hidden ssid is lost in firmware or driver.
SSID and mac address should be anonymized.
BUG=chrome-os-partner:17989
TEST=trigger a scan and grep for "inform bss" in dmesg/messages. Submit a
feedback report and verify if SSIDs and mac addresses are anonymized. Verified
with the feedback report
718249759.
Change-Id: I0df02a9f8eb1898f6f3af2438c614031bb44f329
Signed-off-by: Bing Zhao <bzhao@marvell.com>
Signed-off-by: Ashok Nagarajan <asnagarajan@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/44124
Reviewed-by: Darin Petkov <petkov@chromium.org>
Reviewed-by: mukesh agrawal <quiche@chromium.org>
Bernie Thompson [Wed, 27 Feb 2013 18:56:59 +0000 (10:56 -0800)]
CHROMIUM: mmc: Add in support to expose PRV for v4 MMCs
The JEDEC MMC v4 spec defines a new PRV value in place of the original
fwrev and hwrev specified in v1. We can expose this in the kernel to enable
user space to more easily determine the product revision of a given MMC.
BUG=chrome-os-partner:17640
TEST=emerge-daisy_spring chromeos-kernel
Check for /sys/devices/dw_mmc.0/mmc_host/mmc0/mmc0:0001/prv
Change-Id: Ia241c743e64749909ad18851425a551e04d8cdb3
Signed-off-by: Bernie Thompson <bhthompson@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/44190
Reviewed-by: Grant Grundler <grundler@chromium.org>
Reviewed-by: Olof Johansson <olofj@chromium.org>
Luigi Semenzato [Wed, 27 Feb 2013 17:41:54 +0000 (09:41 -0800)]
CHROMIUM: TEMPORARY: dump stack to help debug p/17609
This doesn't happen very often, so the dump_stack should
be tolerable. I tried with a WARN_ON, but it made some
of our automated tests fail.
BUG=chrome-os-partner:17609
TEST=none
Change-Id: I3d5a0ebc25d272901e713209dc5d655322804f91
Signed-off-by: Luigi Semenzato <semenzato@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/44178
Reviewed-by: Sonny Rao <sonnyrao@chromium.org>
Luigi Semenzato [Wed, 27 Feb 2013 16:56:34 +0000 (08:56 -0800)]
Revert "CHROMIUM: TEMPORARY: instrumentation for crosbug.com/p/17609"
This reverts commit
046efd1b7dceabe4cc38c61c355a34c2bf657ca3.
The WARN_ON makes some automated tests fail.
BUG=chrome-os-partner:17609
TEST=none
Change-Id: I07da232e7d2f7456da41ea373dfa00275a8effa0
Signed-off-by: Luigi Semenzato <semenzato@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/44174
Commit-Queue: Grant Grundler <grundler@chromium.org>
Reviewed-by: Grant Grundler <grundler@chromium.org>
Sean Paul [Fri, 22 Feb 2013 19:01:26 +0000 (14:01 -0500)]
drm: Add drm_bridge between encoder and connector
This patch adds the notion of a drm_bridge between the encoder and the
connector. This allows us to handle bridge chips gracefully with dpms
and hotplug.
BUG=chrome-os-partner:17557
TEST=Tested on snow
Change-Id: I66b9f631bb924e443e79419a3dc3af0ef41fb70d
Signed-off-by: Sean Paul <seanpaul@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/43912
Luigi Semenzato [Fri, 22 Feb 2013 22:51:39 +0000 (14:51 -0800)]
CHROMIUM: TEMPORARY: instrumentation for crosbug.com/p/17609
We have a hard time reproducing crosbug.com/p/17609. It seems
to be correlated with a reset of the device. We don't understand
why the reset happens and we're hoping that a stack trace will
give us some information.
From the logs we've seen, this doesn't happen very often, so
chances of spewing are low. We get Link feedback reports with
this error almost daily.
BUG=chrome-os-partner:17609
TEST=not tested, or, rather, YOU test it
BRANCH=none
Signed-off-by: Luigi Semenzato <semenzato@chromium.org>
Change-Id: If24b4f2490919905d79cdf4e5b8b159cbe8aee6c
Reviewed-on: https://gerrit.chromium.org/gerrit/43832
Tested-by: Luigi Semenzato <semenzato@chromium.org>
Reviewed-by: Sonny Rao <sonnyrao@chromium.org>
Commit-Queue: Luigi Semenzato <semenzato@chromium.org>
Derek Basehore [Fri, 8 Feb 2013 05:26:32 +0000 (21:26 -0800)]
CHROMIUM: dark resume: Make rtc_cmos part of kernel
This change makes the rtc_cmos driver part of the kernel instead of a module.
This allows us to modify sysfs files for it (such as dark_resume_source) as part
of an upstart script. We need to change the owner of the dark_resume_source file
to power so powerd can enable the rtc cmos as a wake source.
BUG=chrome-os-partner:9812
TEST=check that rtc cmos is probed before user space starts.
Change-Id: Ie562fe78ade4f6b46ee1de970401435f52200fa4
Signed-off-by: Derek Basehore <dbasehore@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/42926
Reviewed-by: Olof Johansson <olofj@chromium.org>
Reviewed-by: Sameer Nanda <snanda@chromium.org>