diff options
author | Koen Kooi <koen@openembedded.org> | 2011-01-12 17:01:42 +0100 |
---|---|---|
committer | Koen Kooi <koen@openembedded.org> | 2011-01-12 19:27:34 +0100 |
commit | 6e749b6713943cae1031178179df4f42e59aa912 (patch) | |
tree | 609f08846f31634791d314c5c190bd70ef7b408c /recipes | |
parent | 163019f7508b0c7b1f77c37845b84dee748d7d9d (diff) | |
download | openembedded-6e749b6713943cae1031178179df4f42e59aa912.tar.gz |
linux-omap: move to 2.6.37 final
There is no 2.6.37-omap1 tag and linus' tree is missing fixes, so patch up -rc8 with the patches from mainline
Signed-off-by: Koen Kooi <koen@openembedded.org>
Diffstat (limited to 'recipes')
126 files changed, 5562 insertions, 153 deletions
diff --git a/recipes/linux/linux-omap-2.6.37rc/base/0001-ARM-OMAP-Power-on-EHCI-serial-camera-and-DVI-on-beag.patch b/recipes/linux/linux-omap-2.6.37/base/0001-ARM-OMAP-Power-on-EHCI-serial-camera-and-DVI-on-beag.patch index 3455fa0395..53ef772c2a 100644 --- a/recipes/linux/linux-omap-2.6.37rc/base/0001-ARM-OMAP-Power-on-EHCI-serial-camera-and-DVI-on-beag.patch +++ b/recipes/linux/linux-omap-2.6.37/base/0001-ARM-OMAP-Power-on-EHCI-serial-camera-and-DVI-on-beag.patch @@ -1,7 +1,7 @@ -From d6d5641d45a971ebae2838b03fc6ed8cac095254 Mon Sep 17 00:00:00 2001 +From 5bae403e0f66a67c222ce124422d43b8b9307041 Mon Sep 17 00:00:00 2001 From: Koen Kooi <koen@dominion.thruhere.net> Date: Thu, 7 Oct 2010 09:25:45 +0200 -Subject: [PATCH 01/48] ARM: OMAP: Power on EHCI, serial, camera and DVI on beagleboard-xM +Subject: [PATCH 01/26] ARM: OMAP: Power on EHCI, serial, camera and DVI on beagleboard-xM Signed-off-by: Koen Kooi <koen@beagleboard.org> --- diff --git a/recipes/linux/linux-omap-2.6.37rc/base/0002-omap-Beagle-detect-new-xM-revision-B.patch b/recipes/linux/linux-omap-2.6.37/base/0002-omap-Beagle-detect-new-xM-revision-B.patch index 1ea76d26de..ba1915111c 100644 --- a/recipes/linux/linux-omap-2.6.37rc/base/0002-omap-Beagle-detect-new-xM-revision-B.patch +++ b/recipes/linux/linux-omap-2.6.37/base/0002-omap-Beagle-detect-new-xM-revision-B.patch @@ -1,7 +1,7 @@ -From cdcf48554a1691090c4d5383014d23405b5b2047 Mon Sep 17 00:00:00 2001 +From 3258ce5493fd9e603a31cc4156892f08ee1500e9 Mon Sep 17 00:00:00 2001 From: Robert Nelson <robertcnelson@gmail.com> Date: Tue, 9 Nov 2010 08:34:55 -0600 -Subject: [PATCH 02/48] omap: Beagle: detect new xM revision B +Subject: [PATCH 02/26] omap: Beagle: detect new xM revision B The xM B uses a DM3730 ES1.1 over the ES1.0 on xM A's, no other board changes. diff --git a/recipes/linux/linux-omap-2.6.37rc/base/0003-ARM-OMAP-beagleboard-Add-infrastructure-to-do-fixups.patch b/recipes/linux/linux-omap-2.6.37/base/0003-ARM-OMAP-beagleboard-Add-infrastructure-to-do-fixups.patch index e53553e48e..dcbf910a4d 100644 --- a/recipes/linux/linux-omap-2.6.37rc/base/0003-ARM-OMAP-beagleboard-Add-infrastructure-to-do-fixups.patch +++ b/recipes/linux/linux-omap-2.6.37/base/0003-ARM-OMAP-beagleboard-Add-infrastructure-to-do-fixups.patch @@ -1,7 +1,7 @@ -From 8214dad3691e6a6b7bbcdc60095ba1ecd0dce6d8 Mon Sep 17 00:00:00 2001 +From 116a1ffd21e520b0a6c7a91576605bc6151138cb Mon Sep 17 00:00:00 2001 From: Koen Kooi <koen@dominion.thruhere.net> Date: Wed, 6 Oct 2010 10:19:34 +0200 -Subject: [PATCH 03/48] ARM: OMAP: beagleboard: Add infrastructure to do fixups based on expansionboard name passed by u-boot +Subject: [PATCH 03/26] ARM: OMAP: beagleboard: Add infrastructure to do fixups based on expansionboard name passed by u-boot Add support for Tincantools Zippy and Zippy2 expansionboards as well diff --git a/recipes/linux/linux-omap-2.6.37rc/base/0004-ARM-OMAP-beagleboard-pre-export-GPIOs-to-userspace-w.patch b/recipes/linux/linux-omap-2.6.37/base/0004-ARM-OMAP-beagleboard-pre-export-GPIOs-to-userspace-w.patch index f0f8b10444..41af353473 100644 --- a/recipes/linux/linux-omap-2.6.37rc/base/0004-ARM-OMAP-beagleboard-pre-export-GPIOs-to-userspace-w.patch +++ b/recipes/linux/linux-omap-2.6.37/base/0004-ARM-OMAP-beagleboard-pre-export-GPIOs-to-userspace-w.patch @@ -1,7 +1,7 @@ -From e7cd2f89a99dc1bc54dc8caf93134060641a3746 Mon Sep 17 00:00:00 2001 +From 64215e5d75084b49c490d2aad78c8d3702e6c419 Mon Sep 17 00:00:00 2001 From: Koen Kooi <koen@dominion.thruhere.net> Date: Sun, 5 Dec 2010 13:25:00 +0100 -Subject: [PATCH 04/48] ARM: OMAP: beagleboard: pre-export GPIOs to userspace when using a Tincantools trainerboard +Subject: [PATCH 04/26] ARM: OMAP: beagleboard: pre-export GPIOs to userspace when using a Tincantools trainerboard This really needs a for loop, patches welcome diff --git a/recipes/linux/linux-omap-2.6.37rc/base/0005-modedb.c-add-proper-720p60-mode.patch b/recipes/linux/linux-omap-2.6.37/base/0005-modedb.c-add-proper-720p60-mode.patch index a82fa3ef9a..34e09c02a6 100644 --- a/recipes/linux/linux-omap-2.6.37rc/base/0005-modedb.c-add-proper-720p60-mode.patch +++ b/recipes/linux/linux-omap-2.6.37/base/0005-modedb.c-add-proper-720p60-mode.patch @@ -1,7 +1,7 @@ -From 10f3992d9dd3d12610c837d1cc7a71d0eba905e2 Mon Sep 17 00:00:00 2001 +From 84b16387417976abbba2dd1608147ab0c7692093 Mon Sep 17 00:00:00 2001 From: Koen Kooi <koen@dominion.thruhere.net> Date: Mon, 8 Mar 2010 14:38:31 +0100 -Subject: [PATCH 05/48] modedb.c: add proper 720p60 mode +Subject: [PATCH 05/26] modedb.c: add proper 720p60 mode Signed-off-by: Koen Kooi <koen@beagleboard.org> --- diff --git a/recipes/linux/linux-omap-2.6.37rc/base/0006-mmc-don-t-display-single-block-read-console-messages.patch b/recipes/linux/linux-omap-2.6.37/base/0006-mmc-don-t-display-single-block-read-console-messages.patch index 2731663a84..25aa9f867a 100644 --- a/recipes/linux/linux-omap-2.6.37rc/base/0006-mmc-don-t-display-single-block-read-console-messages.patch +++ b/recipes/linux/linux-omap-2.6.37/base/0006-mmc-don-t-display-single-block-read-console-messages.patch @@ -1,7 +1,7 @@ -From 0fa5b36359835190e97d4671387a57f9af8ab235 Mon Sep 17 00:00:00 2001 +From 11aba6aa87fc0d7c452324d002578aa54d3c9a6b Mon Sep 17 00:00:00 2001 From: Steve Sakoman <steve@sakoman.com> Date: Mon, 4 Jan 2010 19:20:25 -0800 -Subject: [PATCH 06/48] mmc: don't display single block read console messages +Subject: [PATCH 06/26] mmc: don't display single block read console messages mmc: don't display single block read console messages --- diff --git a/recipes/linux/linux-omap-2.6.37rc/base/0007-MTD-silence-ecc-errors-on-mtdblock0.patch b/recipes/linux/linux-omap-2.6.37/base/0007-MTD-silence-ecc-errors-on-mtdblock0.patch index f7952cfa0f..9f3623142b 100644 --- a/recipes/linux/linux-omap-2.6.37rc/base/0007-MTD-silence-ecc-errors-on-mtdblock0.patch +++ b/recipes/linux/linux-omap-2.6.37/base/0007-MTD-silence-ecc-errors-on-mtdblock0.patch @@ -1,7 +1,7 @@ -From cfdca2f7a22519047edf1c7c038f325da6d9672b Mon Sep 17 00:00:00 2001 +From 7f3e88e66f1dd872ed087372d6cd81fce5d96d24 Mon Sep 17 00:00:00 2001 From: Steve Sakoman <steve@sakoman.com> Date: Mon, 26 Apr 2010 11:17:26 -0700 -Subject: [PATCH 07/48] MTD: silence ecc errors on mtdblock0 +Subject: [PATCH 07/26] MTD: silence ecc errors on mtdblock0 mtdblock0 is the x-load partition, which uses hw ecc this confuses linux, which uses sw ecc diff --git a/recipes/linux/linux-omap-2.6.37rc/base/0008-Miracle-patch.patch b/recipes/linux/linux-omap-2.6.37/base/0008-Miracle-patch.patch index d035579ef3..54e3690ab6 100644 --- a/recipes/linux/linux-omap-2.6.37rc/base/0008-Miracle-patch.patch +++ b/recipes/linux/linux-omap-2.6.37/base/0008-Miracle-patch.patch @@ -1,7 +1,7 @@ -From c5d05544833f27d0f54694134088f864b595ba01 Mon Sep 17 00:00:00 2001 +From d7dbe93075a4e7b5c0fa2a2b745440a53ad26a72 Mon Sep 17 00:00:00 2001 From: Mike Galbraith <efault@gmx.de> Date: Fri, 19 Nov 2010 12:52:42 +0100 -Subject: [PATCH 08/48] Miracle patch +Subject: [PATCH 08/26] Miracle patch MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit @@ -113,7 +113,7 @@ Signed-off-by: Mike Galbraith <efault@gmx.de> create mode 100644 kernel/sched_autogroup.h diff --git a/Documentation/kernel-parameters.txt b/Documentation/kernel-parameters.txt -index 8b61c93..9408728 100644 +index 01ece1b..1031923 100644 --- a/Documentation/kernel-parameters.txt +++ b/Documentation/kernel-parameters.txt @@ -1622,6 +1622,8 @@ and is between 256 and 4096 characters. It is defined in the file diff --git a/recipes/linux/linux-omap-2.6.37rc/base/0009-ARM-OMAP-add-omap_rev_-macros.patch b/recipes/linux/linux-omap-2.6.37/base/0009-ARM-OMAP-add-omap_rev_-macros.patch index 21e531dd24..12b3f5cba6 100644 --- a/recipes/linux/linux-omap-2.6.37rc/base/0009-ARM-OMAP-add-omap_rev_-macros.patch +++ b/recipes/linux/linux-omap-2.6.37/base/0009-ARM-OMAP-add-omap_rev_-macros.patch @@ -1,7 +1,7 @@ -From 02e05895eeadaf265e4096d31598f5916dc075bf Mon Sep 17 00:00:00 2001 +From d378376ed64b5506c352b33085baeb21013e55f2 Mon Sep 17 00:00:00 2001 From: Koen Kooi <koen@dominion.thruhere.net> Date: Tue, 23 Nov 2010 11:40:20 +0100 -Subject: [PATCH 09/48] ARM: OMAP: add omap_rev_* macros +Subject: [PATCH 09/26] ARM: OMAP: add omap_rev_* macros This is just to make the SGX modules build that depend on omap_rev_lt_3_0 diff --git a/recipes/linux/linux-omap-2.6.37rc/base/0010-OMAP-DSS2-enable-hsclk-in-dsi_pll_init-for-OMAP36XX.patch b/recipes/linux/linux-omap-2.6.37/base/0010-OMAP-DSS2-enable-hsclk-in-dsi_pll_init-for-OMAP36XX.patch index 175c7a9f0b..c190c1708e 100644 --- a/recipes/linux/linux-omap-2.6.37rc/base/0010-OMAP-DSS2-enable-hsclk-in-dsi_pll_init-for-OMAP36XX.patch +++ b/recipes/linux/linux-omap-2.6.37/base/0010-OMAP-DSS2-enable-hsclk-in-dsi_pll_init-for-OMAP36XX.patch @@ -1,7 +1,7 @@ -From 8c471fd98797978dbe7141a516f86b34c76218fd Mon Sep 17 00:00:00 2001 +From b5e34d9e5b20b412686f84ea8f4e56245f7d5f7f Mon Sep 17 00:00:00 2001 From: Steve Sakoman <steve@sakoman.com> Date: Mon, 10 May 2010 20:44:09 -0700 -Subject: [PATCH 10/48] OMAP: DSS2: enable hsclk in dsi_pll_init for OMAP36XX +Subject: [PATCH 10/26] OMAP: DSS2: enable hsclk in dsi_pll_init for OMAP36XX Signed-off-by: Koen Kooi <koen@beagleboard.org> --- diff --git a/recipes/linux/linux-omap-2.6.37rc/base/0011-omap3-beagleboard-add-WIP-support-for-beagleboardtoy.patch b/recipes/linux/linux-omap-2.6.37/base/0011-omap3-beagleboard-add-WIP-support-for-beagleboardtoy.patch index 0c02dbedb6..391c01a615 100644 --- a/recipes/linux/linux-omap-2.6.37rc/base/0011-omap3-beagleboard-add-WIP-support-for-beagleboardtoy.patch +++ b/recipes/linux/linux-omap-2.6.37/base/0011-omap3-beagleboard-add-WIP-support-for-beagleboardtoy.patch @@ -1,7 +1,7 @@ -From fab0e0773974c1f8e9d9f3fedb231a6ead136ceb Mon Sep 17 00:00:00 2001 +From 7bd039c94c36e206ffeb521e2facab7dc9737eaf Mon Sep 17 00:00:00 2001 From: Koen Kooi <koen@beagleboard.org> Date: Mon, 20 Dec 2010 11:57:56 +0100 -Subject: [PATCH 11/48] omap3: beagleboard: add WIP support for beagleboardtoys WL12xx board +Subject: [PATCH 11/26] omap3: beagleboard: add WIP support for beagleboardtoys WL12xx board Based on a patch by Luciano Coelho <luciano.coelho@nokia.com> diff --git a/recipes/linux/linux-omap-2.6.37rc/base/0012-drivers-net-smsc911x-return-ENODEV-if-device-is-not-.patch b/recipes/linux/linux-omap-2.6.37/base/0012-drivers-net-smsc911x-return-ENODEV-if-device-is-not-.patch index e7abf32514..e7c84adb20 100644 --- a/recipes/linux/linux-omap-2.6.37rc/base/0012-drivers-net-smsc911x-return-ENODEV-if-device-is-not-.patch +++ b/recipes/linux/linux-omap-2.6.37/base/0012-drivers-net-smsc911x-return-ENODEV-if-device-is-not-.patch @@ -1,7 +1,7 @@ -From b2d3dab78e0447a9e9b1f231f397f5a4661a8c0f Mon Sep 17 00:00:00 2001 +From 9eb52cc853ca5aae2cf2b8c4df8ecfd3b666d560 Mon Sep 17 00:00:00 2001 From: Steve Sakoman <sakoman@gmail.com> Date: Tue, 15 Dec 2009 15:17:44 -0800 -Subject: [PATCH 12/48] drivers: net: smsc911x: return ENODEV if device is not found +Subject: [PATCH 12/26] drivers: net: smsc911x: return ENODEV if device is not found Signed-off-by: Steve Sakoman <sakoman@gmail.com> --- diff --git a/recipes/linux/linux-omap-2.6.37rc/base/0013-drivers-input-touchscreen-ads7846-return-ENODEV-if-d.patch b/recipes/linux/linux-omap-2.6.37/base/0013-drivers-input-touchscreen-ads7846-return-ENODEV-if-d.patch index 166a5bc597..7e49d72690 100644 --- a/recipes/linux/linux-omap-2.6.37rc/base/0013-drivers-input-touchscreen-ads7846-return-ENODEV-if-d.patch +++ b/recipes/linux/linux-omap-2.6.37/base/0013-drivers-input-touchscreen-ads7846-return-ENODEV-if-d.patch @@ -1,7 +1,7 @@ -From ba056c5593760c687cd0e7e8b71aebea37744e11 Mon Sep 17 00:00:00 2001 +From 090cbb4e522ea0a7e31508435fa1852eecef2fea Mon Sep 17 00:00:00 2001 From: Steve Sakoman <sakoman@gmail.com> Date: Tue, 15 Dec 2009 15:24:10 -0800 -Subject: [PATCH 13/48] drivers: input: touchscreen: ads7846: return ENODEV if device is not found +Subject: [PATCH 13/26] drivers: input: touchscreen: ads7846: return ENODEV if device is not found Signed-off-by: Steve Sakoman <sakoman@gmail.com> --- diff --git a/recipes/linux/linux-omap-2.6.37rc/base/0014-ASoC-enable-audio-capture-by-default-for-twl4030.patch b/recipes/linux/linux-omap-2.6.37/base/0014-ASoC-enable-audio-capture-by-default-for-twl4030.patch index 4547fe98ea..37bf75ef1e 100644 --- a/recipes/linux/linux-omap-2.6.37rc/base/0014-ASoC-enable-audio-capture-by-default-for-twl4030.patch +++ b/recipes/linux/linux-omap-2.6.37/base/0014-ASoC-enable-audio-capture-by-default-for-twl4030.patch @@ -1,7 +1,7 @@ -From 7223af75a651593d131ec4d84cd2abde88c7d69f Mon Sep 17 00:00:00 2001 +From 3afe141cc65d54db2bfc82683d7ac5e142d48dad Mon Sep 17 00:00:00 2001 From: Steve Sakoman <steve@sakoman.com> Date: Thu, 17 Dec 2009 12:45:20 -0800 -Subject: [PATCH 14/48] ASoC: enable audio capture by default for twl4030 +Subject: [PATCH 14/26] ASoC: enable audio capture by default for twl4030 --- sound/soc/codecs/twl4030.c | 4 ++-- diff --git a/recipes/linux/linux-omap-2.6.37rc/base/0015-MFD-enable-madc-clock.patch b/recipes/linux/linux-omap-2.6.37/base/0015-MFD-enable-madc-clock.patch index ebf6bc423f..57619585d8 100644 --- a/recipes/linux/linux-omap-2.6.37rc/base/0015-MFD-enable-madc-clock.patch +++ b/recipes/linux/linux-omap-2.6.37/base/0015-MFD-enable-madc-clock.patch @@ -1,7 +1,7 @@ -From 403c50b666c184e66b50157eda5ab94ddf33cf0d Mon Sep 17 00:00:00 2001 +From f749aa37992fe966db530bd1d3ff00ea0eb8e13f Mon Sep 17 00:00:00 2001 From: Steve Sakoman <steve@sakoman.com> Date: Sat, 23 Jan 2010 06:26:54 -0800 -Subject: [PATCH 15/48] MFD: enable madc clock +Subject: [PATCH 15/26] MFD: enable madc clock --- drivers/mfd/twl-core.c | 8 ++++++++ diff --git a/recipes/linux/linux-omap-2.6.37rc/base/0016-MFD-add-twl4030-madc-driver.patch b/recipes/linux/linux-omap-2.6.37/base/0016-MFD-add-twl4030-madc-driver.patch index 55556337f0..84aff8f2fc 100644 --- a/recipes/linux/linux-omap-2.6.37rc/base/0016-MFD-add-twl4030-madc-driver.patch +++ b/recipes/linux/linux-omap-2.6.37/base/0016-MFD-add-twl4030-madc-driver.patch @@ -1,7 +1,7 @@ -From 8f8e87e19cc494a5dff58f8dc59b6967c02cda1d Mon Sep 17 00:00:00 2001 +From bd8ef0fcbab561b010735e12e18946da7a2d81f4 Mon Sep 17 00:00:00 2001 From: Steve Sakoman <steve@sakoman.com> Date: Thu, 17 Dec 2009 14:19:34 -0800 -Subject: [PATCH 16/48] MFD: add twl4030 madc driver +Subject: [PATCH 16/26] MFD: add twl4030 madc driver --- drivers/mfd/Kconfig | 21 ++ diff --git a/recipes/linux/linux-omap-2.6.37rc/base/0017-ARM-OMAP-Add-twl4030-madc-support-to-Overo.patch b/recipes/linux/linux-omap-2.6.37/base/0017-ARM-OMAP-Add-twl4030-madc-support-to-Overo.patch index d28e34de54..fe1f651b71 100644 --- a/recipes/linux/linux-omap-2.6.37rc/base/0017-ARM-OMAP-Add-twl4030-madc-support-to-Overo.patch +++ b/recipes/linux/linux-omap-2.6.37/base/0017-ARM-OMAP-Add-twl4030-madc-support-to-Overo.patch @@ -1,7 +1,7 @@ -From b74561518fc3fd865fe6c288c9ceb7519407c3bf Mon Sep 17 00:00:00 2001 +From e8f9b322f40b10dbd947281203411c9b0c9cb458 Mon Sep 17 00:00:00 2001 From: Steve Sakoman <steve@sakoman.com> Date: Thu, 17 Dec 2009 14:27:15 -0800 -Subject: [PATCH 17/48] ARM: OMAP: Add twl4030 madc support to Overo +Subject: [PATCH 17/26] ARM: OMAP: Add twl4030 madc support to Overo --- arch/arm/mach-omap2/board-overo.c | 5 +++++ diff --git a/recipes/linux/linux-omap-2.6.37rc/base/0018-ARM-OMAP-Add-twl4030-madc-support-to-Beagle.patch b/recipes/linux/linux-omap-2.6.37/base/0018-ARM-OMAP-Add-twl4030-madc-support-to-Beagle.patch index 2e5bfa42fc..2960c4b49a 100644 --- a/recipes/linux/linux-omap-2.6.37rc/base/0018-ARM-OMAP-Add-twl4030-madc-support-to-Beagle.patch +++ b/recipes/linux/linux-omap-2.6.37/base/0018-ARM-OMAP-Add-twl4030-madc-support-to-Beagle.patch @@ -1,7 +1,7 @@ -From cc86c2f6f472d78b7cb83c16659768ddb0103c39 Mon Sep 17 00:00:00 2001 +From d37c0152c00ea15b488b2274544dcb30758fb8ca Mon Sep 17 00:00:00 2001 From: Steve Sakoman <steve@sakoman.com> Date: Thu, 17 Dec 2009 14:32:36 -0800 -Subject: [PATCH 18/48] ARM: OMAP: Add twl4030 madc support to Beagle +Subject: [PATCH 18/26] ARM: OMAP: Add twl4030 madc support to Beagle --- arch/arm/mach-omap2/board-omap3beagle.c | 5 +++++ diff --git a/recipes/linux/linux-omap-2.6.37rc/base/0019-OMAP-DSS2-Add-support-for-Samsung-LTE430WQ-F0C-panel.patch b/recipes/linux/linux-omap-2.6.37/base/0019-OMAP-DSS2-Add-support-for-Samsung-LTE430WQ-F0C-panel.patch index cb40b8ec5c..84e19a5651 100644 --- a/recipes/linux/linux-omap-2.6.37rc/base/0019-OMAP-DSS2-Add-support-for-Samsung-LTE430WQ-F0C-panel.patch +++ b/recipes/linux/linux-omap-2.6.37/base/0019-OMAP-DSS2-Add-support-for-Samsung-LTE430WQ-F0C-panel.patch @@ -1,7 +1,7 @@ -From a23b9064217c6ea6f04e71063c2dc90d121269b8 Mon Sep 17 00:00:00 2001 +From b8983a303fe84ba5a2ff5075edee0071c0b982ae Mon Sep 17 00:00:00 2001 From: Steve Sakoman <steve@sakoman.com> Date: Tue, 23 Feb 2010 14:40:27 -0800 -Subject: [PATCH 19/48] OMAP: DSS2: Add support for Samsung LTE430WQ-F0C panel +Subject: [PATCH 19/26] OMAP: DSS2: Add support for Samsung LTE430WQ-F0C panel --- .../omap2/displays/panel-samsung-lte430wq-f0c.c | 154 ++++++++++++++++++++ diff --git a/recipes/linux/linux-omap-2.6.37rc/base/0020-OMAP-DSS2-Add-support-for-LG-Philips-LB035Q02-panel.patch b/recipes/linux/linux-omap-2.6.37/base/0020-OMAP-DSS2-Add-support-for-LG-Philips-LB035Q02-panel.patch index 8529c2600a..42bb5d1e80 100644 --- a/recipes/linux/linux-omap-2.6.37rc/base/0020-OMAP-DSS2-Add-support-for-LG-Philips-LB035Q02-panel.patch +++ b/recipes/linux/linux-omap-2.6.37/base/0020-OMAP-DSS2-Add-support-for-LG-Philips-LB035Q02-panel.patch @@ -1,7 +1,7 @@ -From ae9500a932f6e8d4f0d35b91231957727428c5cc Mon Sep 17 00:00:00 2001 +From 571cdd24aee8cd6091bcc4dac0d8a0affc3500bf Mon Sep 17 00:00:00 2001 From: Steve Sakoman <steve@sakoman.com> Date: Thu, 17 Dec 2009 15:05:30 -0800 -Subject: [PATCH 20/48] OMAP: DSS2: Add support for LG Philips LB035Q02 panel +Subject: [PATCH 20/26] OMAP: DSS2: Add support for LG Philips LB035Q02 panel --- drivers/video/omap2/displays/Kconfig | 12 + diff --git a/recipes/linux/linux-omap-2.6.37rc/base/0021-OMAP-DSS2-add-bootarg-for-selecting-svideo-or-compos.patch b/recipes/linux/linux-omap-2.6.37/base/0021-OMAP-DSS2-add-bootarg-for-selecting-svideo-or-compos.patch index d5606dcf35..b3b2d12dcc 100644 --- a/recipes/linux/linux-omap-2.6.37rc/base/0021-OMAP-DSS2-add-bootarg-for-selecting-svideo-or-compos.patch +++ b/recipes/linux/linux-omap-2.6.37/base/0021-OMAP-DSS2-add-bootarg-for-selecting-svideo-or-compos.patch @@ -1,7 +1,7 @@ -From efb2df7456804141345eb16e81f9699e50d9790a Mon Sep 17 00:00:00 2001 +From d4ae1b11c94e268467ff6cb6143b934733ed762a Mon Sep 17 00:00:00 2001 From: Steve Sakoman <steve@sakoman.com> Date: Tue, 19 Jan 2010 21:19:15 -0800 -Subject: [PATCH 21/48] OMAP: DSS2: add bootarg for selecting svideo or composite for tv output +Subject: [PATCH 21/26] OMAP: DSS2: add bootarg for selecting svideo or composite for tv output also add pal-16 and ntsc-16 omapfb.mode settings for 16bpp --- diff --git a/recipes/linux/linux-omap-2.6.37rc/base/0022-ARM-OMAP2-mmc-twl4030-move-clock-input-selection-pri.patch b/recipes/linux/linux-omap-2.6.37/base/0022-ARM-OMAP2-mmc-twl4030-move-clock-input-selection-pri.patch index 6284725c6e..d0462fc32d 100644 --- a/recipes/linux/linux-omap-2.6.37rc/base/0022-ARM-OMAP2-mmc-twl4030-move-clock-input-selection-pri.patch +++ b/recipes/linux/linux-omap-2.6.37/base/0022-ARM-OMAP2-mmc-twl4030-move-clock-input-selection-pri.patch @@ -1,7 +1,7 @@ -From 2ad52b20e2f1cdb591a7ed027a01e6825eb45548 Mon Sep 17 00:00:00 2001 +From d0f67e031cd9eb514bbcff3147bf6644b92c5ee4 Mon Sep 17 00:00:00 2001 From: Steve Sakoman <steve@sakoman.com> Date: Sun, 24 Jan 2010 09:33:56 -0800 -Subject: [PATCH 22/48] ARM: OMAP2: mmc-twl4030: move clock input selection prior to vcc test +Subject: [PATCH 22/26] ARM: OMAP2: mmc-twl4030: move clock input selection prior to vcc test otherwise it is not executed on systems that use non-twl regulators --- diff --git a/recipes/linux/linux-omap-2.6.37rc/base/0023-RTC-add-support-for-backup-battery-recharge.patch b/recipes/linux/linux-omap-2.6.37/base/0023-RTC-add-support-for-backup-battery-recharge.patch index 8e7b6d44a9..9754c7419a 100644 --- a/recipes/linux/linux-omap-2.6.37rc/base/0023-RTC-add-support-for-backup-battery-recharge.patch +++ b/recipes/linux/linux-omap-2.6.37/base/0023-RTC-add-support-for-backup-battery-recharge.patch @@ -1,7 +1,7 @@ -From baf0a85e8458058ca0c508939b16337f8f385c78 Mon Sep 17 00:00:00 2001 +From 27f251ad46eeda205c220f89b4f9fbeaf930ae54 Mon Sep 17 00:00:00 2001 From: Steve Sakoman <steve@sakoman.com> Date: Thu, 4 Feb 2010 12:26:22 -0800 -Subject: [PATCH 23/48] RTC: add support for backup battery recharge +Subject: [PATCH 23/26] RTC: add support for backup battery recharge --- drivers/rtc/rtc-twl.c | 25 +++++++++++++++++++++++++ diff --git a/recipes/linux/linux-omap-2.6.37rc/base/0024-ARM-OMAP-automatically-set-musb-mode-in-platform-dat.patch b/recipes/linux/linux-omap-2.6.37/base/0024-ARM-OMAP-automatically-set-musb-mode-in-platform-dat.patch index 6b85d0754f..37a15ced9c 100644 --- a/recipes/linux/linux-omap-2.6.37rc/base/0024-ARM-OMAP-automatically-set-musb-mode-in-platform-dat.patch +++ b/recipes/linux/linux-omap-2.6.37/base/0024-ARM-OMAP-automatically-set-musb-mode-in-platform-dat.patch @@ -1,7 +1,7 @@ -From 684902cfd776bdaf46d302d63be1d52edeb11428 Mon Sep 17 00:00:00 2001 +From 4eedcb7fb5101a042102355463a213fa51e52e4f Mon Sep 17 00:00:00 2001 From: Steve Sakoman <steve@sakoman.com> Date: Wed, 24 Feb 2010 10:37:22 -0800 -Subject: [PATCH 24/48] ARM: OMAP: automatically set musb mode in platform data based on CONFIG options +Subject: [PATCH 24/26] ARM: OMAP: automatically set musb mode in platform data based on CONFIG options --- arch/arm/mach-omap2/board-omap3beagle.c | 6 ++++++ diff --git a/recipes/linux/linux-omap-2.6.37rc/base/0025-OMAP-DSS2-check-for-both-cpu-type-and-revision-rathe.patch b/recipes/linux/linux-omap-2.6.37/base/0025-OMAP-DSS2-check-for-both-cpu-type-and-revision-rathe.patch index 7adec6c700..7805899237 100644 --- a/recipes/linux/linux-omap-2.6.37rc/base/0025-OMAP-DSS2-check-for-both-cpu-type-and-revision-rathe.patch +++ b/recipes/linux/linux-omap-2.6.37/base/0025-OMAP-DSS2-check-for-both-cpu-type-and-revision-rathe.patch @@ -1,7 +1,7 @@ -From 786949054cbaf6698cc45bebf8802407932c3399 Mon Sep 17 00:00:00 2001 +From 3e9463eb0f8c54286c086f259a598415ba28c28f Mon Sep 17 00:00:00 2001 From: Steve Sakoman <steve@sakoman.com> Date: Mon, 10 May 2010 13:59:14 -0700 -Subject: [PATCH 25/48] OMAP: DSS2: check for both cpu type and revision, rather than just revision +Subject: [PATCH 25/26] OMAP: DSS2: check for both cpu type and revision, rather than just revision --- drivers/video/omap2/dss/dispc.c | 4 ++-- diff --git a/recipes/linux/linux-omap-2.6.37rc/base/0026-OMAP-DSS2-Add-DSS2-support-for-Overo.patch b/recipes/linux/linux-omap-2.6.37/base/0026-OMAP-DSS2-Add-DSS2-support-for-Overo.patch index 71bb32c3ab..56a73345a1 100644 --- a/recipes/linux/linux-omap-2.6.37rc/base/0026-OMAP-DSS2-Add-DSS2-support-for-Overo.patch +++ b/recipes/linux/linux-omap-2.6.37/base/0026-OMAP-DSS2-Add-DSS2-support-for-Overo.patch @@ -1,7 +1,7 @@ -From db865112f6dc08f364675177eafd24ccffb3d4da Mon Sep 17 00:00:00 2001 +From 5ac69358c0af66eadb86561fb99a661280f61f78 Mon Sep 17 00:00:00 2001 From: Steve Sakoman <steve@sakoman.com> Date: Fri, 18 Dec 2009 06:39:24 -0800 -Subject: [PATCH 26/48] OMAP: DSS2: Add DSS2 support for Overo +Subject: [PATCH 26/26] OMAP: DSS2: Add DSS2 support for Overo --- arch/arm/mach-omap2/board-overo.c | 238 +++++++++++++++++++++++++++++++------ diff --git a/recipes/linux/linux-omap-2.6.37rc/beagleboard/defconfig b/recipes/linux/linux-omap-2.6.37/beagleboard/defconfig index d6d7cb89e4..d6d7cb89e4 100644 --- a/recipes/linux/linux-omap-2.6.37rc/beagleboard/defconfig +++ b/recipes/linux/linux-omap-2.6.37/beagleboard/defconfig diff --git a/recipes/linux/linux-omap-2.6.37rc/beagleboard/logo_linux_clut224.ppm b/recipes/linux/linux-omap-2.6.37/beagleboard/logo_linux_clut224.ppm index d29fc1c544..d29fc1c544 100644 --- a/recipes/linux/linux-omap-2.6.37rc/beagleboard/logo_linux_clut224.ppm +++ b/recipes/linux/linux-omap-2.6.37/beagleboard/logo_linux_clut224.ppm diff --git a/recipes/linux/linux-omap-2.6.37rc/dvfs/0001-OMAP3-PM-Adding-T2-enabling-of-smartreflex.patch b/recipes/linux/linux-omap-2.6.37/dvfs/0001-OMAP3-PM-Adding-T2-enabling-of-smartreflex.patch index 216ab42569..868906c9ad 100644 --- a/recipes/linux/linux-omap-2.6.37rc/dvfs/0001-OMAP3-PM-Adding-T2-enabling-of-smartreflex.patch +++ b/recipes/linux/linux-omap-2.6.37/dvfs/0001-OMAP3-PM-Adding-T2-enabling-of-smartreflex.patch @@ -1,4 +1,4 @@ -From 5142c7c3afc5d77b451a10ff6e491c837fd57387 Mon Sep 17 00:00:00 2001 +From 405be95c4b7c397815b20052dbaa43ce36c1a724 Mon Sep 17 00:00:00 2001 From: Thara Gopinath <thara@ti.com> Date: Fri, 31 Dec 2010 13:35:02 +0530 Subject: [PATCH 01/19] OMAP3: PM: Adding T2 enabling of smartreflex diff --git a/recipes/linux/linux-omap-2.6.37rc/dvfs/0001-omap3-add-support-for-720MHz-MPU-OPP.patch b/recipes/linux/linux-omap-2.6.37/dvfs/0001-omap3-add-support-for-720MHz-MPU-OPP.patch index f9236394a7..f9236394a7 100644 --- a/recipes/linux/linux-omap-2.6.37rc/dvfs/0001-omap3-add-support-for-720MHz-MPU-OPP.patch +++ b/recipes/linux/linux-omap-2.6.37/dvfs/0001-omap3-add-support-for-720MHz-MPU-OPP.patch diff --git a/recipes/linux/linux-omap-2.6.37rc/dvfs/0002-OMAP-CPUfreq-ensure-driver-initializes-after-cpufreq.patch b/recipes/linux/linux-omap-2.6.37/dvfs/0002-OMAP-CPUfreq-ensure-driver-initializes-after-cpufreq.patch index 99e8205d80..cf3cae6241 100644 --- a/recipes/linux/linux-omap-2.6.37rc/dvfs/0002-OMAP-CPUfreq-ensure-driver-initializes-after-cpufreq.patch +++ b/recipes/linux/linux-omap-2.6.37/dvfs/0002-OMAP-CPUfreq-ensure-driver-initializes-after-cpufreq.patch @@ -1,4 +1,4 @@ -From dd8daed0e5ebb6fe97d519af14087e64badf99b3 Mon Sep 17 00:00:00 2001 +From a1df976c51e22bed9d95fcb07832571ef3520f2a Mon Sep 17 00:00:00 2001 From: Peter 'p2' De Schrijver <peter.de-schrijver@nokia.com> Date: Wed, 11 Aug 2010 17:02:43 -0700 Subject: [PATCH 02/19] OMAP: CPUfreq: ensure driver initializes after cpufreq framework and governors diff --git a/recipes/linux/linux-omap-2.6.37rc/dvfs/0002-OMAP35x-Add-support-for-720MHz-part.patch b/recipes/linux/linux-omap-2.6.37/dvfs/0002-OMAP35x-Add-support-for-720MHz-part.patch index c771b09159..c771b09159 100644 --- a/recipes/linux/linux-omap-2.6.37rc/dvfs/0002-OMAP35x-Add-support-for-720MHz-part.patch +++ b/recipes/linux/linux-omap-2.6.37/dvfs/0002-OMAP35x-Add-support-for-720MHz-part.patch diff --git a/recipes/linux/linux-omap-2.6.37rc/dvfs/0003-OMAP-CPUfreq-ensure-policy-is-fully-initialized.patch b/recipes/linux/linux-omap-2.6.37/dvfs/0003-OMAP-CPUfreq-ensure-policy-is-fully-initialized.patch index 0b298f290b..61486e824d 100644 --- a/recipes/linux/linux-omap-2.6.37rc/dvfs/0003-OMAP-CPUfreq-ensure-policy-is-fully-initialized.patch +++ b/recipes/linux/linux-omap-2.6.37/dvfs/0003-OMAP-CPUfreq-ensure-policy-is-fully-initialized.patch @@ -1,4 +1,4 @@ -From f8a4f82bc912cbb223bdf40496c4c6e879339479 Mon Sep 17 00:00:00 2001 +From fe6bc036ebf31ca377051ff0ea99da3cdc66854f Mon Sep 17 00:00:00 2001 From: Kevin Hilman <khilman@deeprootsystems.com> Date: Wed, 11 Aug 2010 17:05:38 -0700 Subject: [PATCH 03/19] OMAP: CPUfreq: ensure policy is fully initialized diff --git a/recipes/linux/linux-omap-2.6.37rc/dvfs/0003-OMAP3-beagle-C4-enable-upto-720MHz-OPP.patch b/recipes/linux/linux-omap-2.6.37/dvfs/0003-OMAP3-beagle-C4-enable-upto-720MHz-OPP.patch index a2141bb841..a2141bb841 100644 --- a/recipes/linux/linux-omap-2.6.37rc/dvfs/0003-OMAP3-beagle-C4-enable-upto-720MHz-OPP.patch +++ b/recipes/linux/linux-omap-2.6.37/dvfs/0003-OMAP3-beagle-C4-enable-upto-720MHz-OPP.patch diff --git a/recipes/linux/linux-omap-2.6.37rc/dvfs/0004-OMAP3-Overo-Tide-enable-upto-720MHz-OPP.patch b/recipes/linux/linux-omap-2.6.37/dvfs/0004-OMAP3-Overo-Tide-enable-upto-720MHz-OPP.patch index 5061daac3e..5061daac3e 100644 --- a/recipes/linux/linux-omap-2.6.37rc/dvfs/0004-OMAP3-Overo-Tide-enable-upto-720MHz-OPP.patch +++ b/recipes/linux/linux-omap-2.6.37/dvfs/0004-OMAP3-Overo-Tide-enable-upto-720MHz-OPP.patch diff --git a/recipes/linux/linux-omap-2.6.37rc/dvfs/0004-OMAP3-PM-CPUFreq-driver-for-OMAP3.patch b/recipes/linux/linux-omap-2.6.37/dvfs/0004-OMAP3-PM-CPUFreq-driver-for-OMAP3.patch index 7ea106398b..c4eb1a09b6 100644 --- a/recipes/linux/linux-omap-2.6.37rc/dvfs/0004-OMAP3-PM-CPUFreq-driver-for-OMAP3.patch +++ b/recipes/linux/linux-omap-2.6.37/dvfs/0004-OMAP3-PM-CPUFreq-driver-for-OMAP3.patch @@ -1,4 +1,4 @@ -From f096ac097f75fae48eb6c02e69ec9fee5acc7b70 Mon Sep 17 00:00:00 2001 +From f7580811a6d3ac015a8401388124e746651ab64c Mon Sep 17 00:00:00 2001 From: Rajendra Nayak <rnayak@ti.com> Date: Mon, 10 Nov 2008 17:00:25 +0530 Subject: [PATCH 04/19] OMAP3 PM: CPUFreq driver for OMAP3 diff --git a/recipes/linux/linux-omap-2.6.37rc/dvfs/0005-OMAP-PM-CPUFREQ-Fix-conditional-compilation.patch b/recipes/linux/linux-omap-2.6.37/dvfs/0005-OMAP-PM-CPUFREQ-Fix-conditional-compilation.patch index 03d42c3fe4..e0c5da39db 100644 --- a/recipes/linux/linux-omap-2.6.37rc/dvfs/0005-OMAP-PM-CPUFREQ-Fix-conditional-compilation.patch +++ b/recipes/linux/linux-omap-2.6.37/dvfs/0005-OMAP-PM-CPUFREQ-Fix-conditional-compilation.patch @@ -1,4 +1,4 @@ -From b0a84aba56da151763058c73d5b11b4424761421 Mon Sep 17 00:00:00 2001 +From 3a51f3ffe8299bcc28a6be1bdcd0e0ea39af2042 Mon Sep 17 00:00:00 2001 From: Silesh C V <silesh@ti.com> Date: Wed, 29 Sep 2010 14:52:54 +0530 Subject: [PATCH 05/19] OMAP: PM: CPUFREQ: Fix conditional compilation diff --git a/recipes/linux/linux-omap-2.6.37rc/dvfs/0006-OMAP-Introduce-a-user-list-for-each-voltage-domain-i.patch b/recipes/linux/linux-omap-2.6.37/dvfs/0006-OMAP-Introduce-a-user-list-for-each-voltage-domain-i.patch index 15f8a9b760..31c57d76ea 100644 --- a/recipes/linux/linux-omap-2.6.37rc/dvfs/0006-OMAP-Introduce-a-user-list-for-each-voltage-domain-i.patch +++ b/recipes/linux/linux-omap-2.6.37/dvfs/0006-OMAP-Introduce-a-user-list-for-each-voltage-domain-i.patch @@ -1,4 +1,4 @@ -From 08c4a96fac60350914f42557b7d43cf3a49061ed Mon Sep 17 00:00:00 2001 +From c37bb21e4f82e5d88af21f7dbcef407e7a9d5306 Mon Sep 17 00:00:00 2001 From: Thara Gopinath <thara@ti.com> Date: Fri, 29 Oct 2010 20:43:07 +0530 Subject: [PATCH 06/19] OMAP: Introduce a user list for each voltage domain instance in the voltage driver. diff --git a/recipes/linux/linux-omap-2.6.37rc/dvfs/0007-OMAP-Introduce-API-in-the-OPP-layer-to-find-the-opp-.patch b/recipes/linux/linux-omap-2.6.37/dvfs/0007-OMAP-Introduce-API-in-the-OPP-layer-to-find-the-opp-.patch index fd2a8c6516..b7ea04a3c1 100644 --- a/recipes/linux/linux-omap-2.6.37rc/dvfs/0007-OMAP-Introduce-API-in-the-OPP-layer-to-find-the-opp-.patch +++ b/recipes/linux/linux-omap-2.6.37/dvfs/0007-OMAP-Introduce-API-in-the-OPP-layer-to-find-the-opp-.patch @@ -1,4 +1,4 @@ -From d11d1b439fd20557813154c6d8c92d1f7e21f975 Mon Sep 17 00:00:00 2001 +From 717bd73868e57fde49a25104af9bb8b9c6400b67 Mon Sep 17 00:00:00 2001 From: Thara Gopinath <thara@ti.com> Date: Fri, 29 Oct 2010 20:43:10 +0530 Subject: [PATCH 07/19] OMAP: Introduce API in the OPP layer to find the opp entry corresponding to a voltage. diff --git a/recipes/linux/linux-omap-2.6.37rc/dvfs/0008-OMAP-Introduce-API-to-register-a-device-with-a-volta.patch b/recipes/linux/linux-omap-2.6.37/dvfs/0008-OMAP-Introduce-API-to-register-a-device-with-a-volta.patch index fe8f8ad4a3..b69e6f6af9 100644 --- a/recipes/linux/linux-omap-2.6.37rc/dvfs/0008-OMAP-Introduce-API-to-register-a-device-with-a-volta.patch +++ b/recipes/linux/linux-omap-2.6.37/dvfs/0008-OMAP-Introduce-API-to-register-a-device-with-a-volta.patch @@ -1,4 +1,4 @@ -From 5c54feed711491e187784004348b73bff75335c1 Mon Sep 17 00:00:00 2001 +From be5bdabb6206f106f0dcf91b0e90474d23773416 Mon Sep 17 00:00:00 2001 From: Thara Gopinath <thara@ti.com> Date: Fri, 29 Oct 2010 20:43:24 +0530 Subject: [PATCH 08/19] OMAP: Introduce API to register a device with a voltagedomain diff --git a/recipes/linux/linux-omap-2.6.37rc/dvfs/0009-OMAP-Introduce-device-specific-set-rate-and-get-rate.patch b/recipes/linux/linux-omap-2.6.37/dvfs/0009-OMAP-Introduce-device-specific-set-rate-and-get-rate.patch index 8f40e0dcef..308710af14 100644 --- a/recipes/linux/linux-omap-2.6.37rc/dvfs/0009-OMAP-Introduce-device-specific-set-rate-and-get-rate.patch +++ b/recipes/linux/linux-omap-2.6.37/dvfs/0009-OMAP-Introduce-device-specific-set-rate-and-get-rate.patch @@ -1,4 +1,4 @@ -From 15e8b40fdbcc2b6037d8e13b146eb841fd582fbe Mon Sep 17 00:00:00 2001 +From 50f4db415d1ee9ee5100214cc89cf5df1ee1c1e2 Mon Sep 17 00:00:00 2001 From: Thara Gopinath <thara@ti.com> Date: Fri, 29 Oct 2010 20:43:29 +0530 Subject: [PATCH 09/19] OMAP: Introduce device specific set rate and get rate in omap_device structure diff --git a/recipes/linux/linux-omap-2.6.37rc/dvfs/0010-OMAP-Voltage-layer-changes-to-support-DVFS.patch b/recipes/linux/linux-omap-2.6.37/dvfs/0010-OMAP-Voltage-layer-changes-to-support-DVFS.patch index 97d36258e6..f50aedd9d6 100644 --- a/recipes/linux/linux-omap-2.6.37rc/dvfs/0010-OMAP-Voltage-layer-changes-to-support-DVFS.patch +++ b/recipes/linux/linux-omap-2.6.37/dvfs/0010-OMAP-Voltage-layer-changes-to-support-DVFS.patch @@ -1,4 +1,4 @@ -From 3ca22f6068d133ad1ddc578d7eaec6a3b08bd58a Mon Sep 17 00:00:00 2001 +From 3a9b78f58772645a9e1337454faed4e313e55368 Mon Sep 17 00:00:00 2001 From: Thara Gopinath <thara@ti.com> Date: Fri, 29 Oct 2010 20:43:34 +0530 Subject: [PATCH 10/19] OMAP: Voltage layer changes to support DVFS. diff --git a/recipes/linux/linux-omap-2.6.37rc/dvfs/0011-OMAP-Introduce-dependent-voltage-domain-support.patch b/recipes/linux/linux-omap-2.6.37/dvfs/0011-OMAP-Introduce-dependent-voltage-domain-support.patch index 5e39857342..814643f79d 100644 --- a/recipes/linux/linux-omap-2.6.37rc/dvfs/0011-OMAP-Introduce-dependent-voltage-domain-support.patch +++ b/recipes/linux/linux-omap-2.6.37/dvfs/0011-OMAP-Introduce-dependent-voltage-domain-support.patch @@ -1,4 +1,4 @@ -From d9699d436927644fbe6567082703d9f3c733925c Mon Sep 17 00:00:00 2001 +From 444b19e90ae45ccd68c84285fe8339d797a08911 Mon Sep 17 00:00:00 2001 From: Thara Gopinath <thara@ti.com> Date: Fri, 2 Jul 2010 13:06:57 +0530 Subject: [PATCH 11/19] OMAP: Introduce dependent voltage domain support. diff --git a/recipes/linux/linux-omap-2.6.37rc/dvfs/0012-OMAP-Introduce-device-scale.patch b/recipes/linux/linux-omap-2.6.37/dvfs/0012-OMAP-Introduce-device-scale.patch index 348ef89e97..e96d064b54 100644 --- a/recipes/linux/linux-omap-2.6.37rc/dvfs/0012-OMAP-Introduce-device-scale.patch +++ b/recipes/linux/linux-omap-2.6.37/dvfs/0012-OMAP-Introduce-device-scale.patch @@ -1,4 +1,4 @@ -From 9753d84bdd3903574e9be1c895dcc91524a70463 Mon Sep 17 00:00:00 2001 +From 40c41b250b9430b9d9998751fdf7e03201d1784e Mon Sep 17 00:00:00 2001 From: Thara Gopinath <thara@ti.com> Date: Fri, 2 Jul 2010 13:07:35 +0530 Subject: [PATCH 12/19] OMAP: Introduce device scale diff --git a/recipes/linux/linux-omap-2.6.37rc/dvfs/0013-OMAP-Disable-smartreflex-across-DVFS.patch b/recipes/linux/linux-omap-2.6.37/dvfs/0013-OMAP-Disable-smartreflex-across-DVFS.patch index e7128239f8..3be289dcbb 100644 --- a/recipes/linux/linux-omap-2.6.37rc/dvfs/0013-OMAP-Disable-smartreflex-across-DVFS.patch +++ b/recipes/linux/linux-omap-2.6.37/dvfs/0013-OMAP-Disable-smartreflex-across-DVFS.patch @@ -1,4 +1,4 @@ -From ef538867a4de14bfe5b6d7f2e7cdf1704c9e0bb4 Mon Sep 17 00:00:00 2001 +From 72eb0b4978e15f56c99900ec8da10b91864eda98 Mon Sep 17 00:00:00 2001 From: Thara Gopinath <thara@ti.com> Date: Fri, 2 Jul 2010 13:06:57 +0530 Subject: [PATCH 13/19] OMAP: Disable smartreflex across DVFS diff --git a/recipes/linux/linux-omap-2.6.37rc/dvfs/0014-OMAP3-Introduce-custom-set-rate-and-get-rate-APIs-fo.patch b/recipes/linux/linux-omap-2.6.37/dvfs/0014-OMAP3-Introduce-custom-set-rate-and-get-rate-APIs-fo.patch index 9321464149..20e03866fd 100644 --- a/recipes/linux/linux-omap-2.6.37rc/dvfs/0014-OMAP3-Introduce-custom-set-rate-and-get-rate-APIs-fo.patch +++ b/recipes/linux/linux-omap-2.6.37/dvfs/0014-OMAP3-Introduce-custom-set-rate-and-get-rate-APIs-fo.patch @@ -1,4 +1,4 @@ -From d3c60c04fac19bde2dd3b930fd659426557d9cae Mon Sep 17 00:00:00 2001 +From 42e395f0dcc618300267f440f613572635eb2e55 Mon Sep 17 00:00:00 2001 From: Thara Gopinath <thara@ti.com> Date: Wed, 18 Aug 2010 16:22:32 +0530 Subject: [PATCH 14/19] OMAP3: Introduce custom set rate and get rate APIs for scalable devices diff --git a/recipes/linux/linux-omap-2.6.37rc/dvfs/0015-OMAP3-Update-cpufreq-driver-to-use-the-new-set_rate-.patch b/recipes/linux/linux-omap-2.6.37/dvfs/0015-OMAP3-Update-cpufreq-driver-to-use-the-new-set_rate-.patch index c3b5ba6899..90e29e7aeb 100644 --- a/recipes/linux/linux-omap-2.6.37rc/dvfs/0015-OMAP3-Update-cpufreq-driver-to-use-the-new-set_rate-.patch +++ b/recipes/linux/linux-omap-2.6.37/dvfs/0015-OMAP3-Update-cpufreq-driver-to-use-the-new-set_rate-.patch @@ -1,4 +1,4 @@ -From 7fbd0c4b60534401287ae4a0410e82853f7dc015 Mon Sep 17 00:00:00 2001 +From 0c5c41f6bcf77b388f49615ac28ccde294e7a5bd Mon Sep 17 00:00:00 2001 From: Thara Gopinath <thara@ti.com> Date: Fri, 2 Jul 2010 13:07:49 +0530 Subject: [PATCH 15/19] OMAP3: Update cpufreq driver to use the new set_rate API diff --git a/recipes/linux/linux-omap-2.6.37rc/dvfs/0016-OMAP3-Introduce-voltage-domain-info-in-the-hwmod-str.patch b/recipes/linux/linux-omap-2.6.37/dvfs/0016-OMAP3-Introduce-voltage-domain-info-in-the-hwmod-str.patch index 304c05de39..e8b9e51ab6 100644 --- a/recipes/linux/linux-omap-2.6.37rc/dvfs/0016-OMAP3-Introduce-voltage-domain-info-in-the-hwmod-str.patch +++ b/recipes/linux/linux-omap-2.6.37/dvfs/0016-OMAP3-Introduce-voltage-domain-info-in-the-hwmod-str.patch @@ -1,4 +1,4 @@ -From e6d31285f54a9ba2bd6b73f4562e2d28b06c8141 Mon Sep 17 00:00:00 2001 +From a66e4a5a5ee1d98fafab60935bddd28bbd440628 Mon Sep 17 00:00:00 2001 From: Thara Gopinath <thara@ti.com> Date: Wed, 18 Aug 2010 16:22:43 +0530 Subject: [PATCH 16/19] OMAP3: Introduce voltage domain info in the hwmod structures. diff --git a/recipes/linux/linux-omap-2.6.37rc/dvfs/0017-OMAP3-Add-voltage-dependency-table-for-VDD1.patch b/recipes/linux/linux-omap-2.6.37/dvfs/0017-OMAP3-Add-voltage-dependency-table-for-VDD1.patch index 9d693738f3..e1e4a0ec80 100644 --- a/recipes/linux/linux-omap-2.6.37rc/dvfs/0017-OMAP3-Add-voltage-dependency-table-for-VDD1.patch +++ b/recipes/linux/linux-omap-2.6.37/dvfs/0017-OMAP3-Add-voltage-dependency-table-for-VDD1.patch @@ -1,4 +1,4 @@ -From 355fc21a8cc5ba290bb5f2c0c059356cec84d3b0 Mon Sep 17 00:00:00 2001 +From 6e99ca0e5780932988471f106099c98595cb0aa3 Mon Sep 17 00:00:00 2001 From: Thara Gopinath <thara@ti.com> Date: Wed, 18 Aug 2010 16:22:49 +0530 Subject: [PATCH 17/19] OMAP3: Add voltage dependency table for VDD1. diff --git a/recipes/linux/linux-omap-2.6.37rc/dvfs/0018-omap3-4-opp-make-omapx_opp_init-non-static.patch b/recipes/linux/linux-omap-2.6.37/dvfs/0018-omap3-4-opp-make-omapx_opp_init-non-static.patch index b0a5aae233..d60222e027 100644 --- a/recipes/linux/linux-omap-2.6.37rc/dvfs/0018-omap3-4-opp-make-omapx_opp_init-non-static.patch +++ b/recipes/linux/linux-omap-2.6.37/dvfs/0018-omap3-4-opp-make-omapx_opp_init-non-static.patch @@ -1,4 +1,4 @@ -From 68c0c6abf0d44bb8b04a52de25d46b943f144ee7 Mon Sep 17 00:00:00 2001 +From 53d08ca85f9b623e25ba9a976bc3315f3784a3a7 Mon Sep 17 00:00:00 2001 From: Nishanth Menon <nm@ti.com> Date: Wed, 5 Jan 2011 14:14:55 -0600 Subject: [PATCH 18/19] omap3|4: opp: make omapx_opp_init non-static diff --git a/recipes/linux/linux-omap-2.6.37rc/dvfs/0019-OMAP3-beagle-xm-enable-upto-1GHz-OPP.patch b/recipes/linux/linux-omap-2.6.37/dvfs/0019-OMAP3-beagle-xm-enable-upto-1GHz-OPP.patch index 673aa5e2ba..27104c33e5 100644 --- a/recipes/linux/linux-omap-2.6.37rc/dvfs/0019-OMAP3-beagle-xm-enable-upto-1GHz-OPP.patch +++ b/recipes/linux/linux-omap-2.6.37/dvfs/0019-OMAP3-beagle-xm-enable-upto-1GHz-OPP.patch @@ -1,4 +1,4 @@ -From bdb9ac28213f647a620f4df4a50d94953db5184f Mon Sep 17 00:00:00 2001 +From 1f77cf1150d5e0205ab3f588ab25cbdf65acdc40 Mon Sep 17 00:00:00 2001 From: Nishanth Menon <nm@ti.com> Date: Wed, 5 Jan 2011 14:16:59 -0600 Subject: [PATCH 19/19] OMAP3: beagle xm: enable upto 1GHz OPP diff --git a/recipes/linux/linux-omap-2.6.37/linus/0001-ARM-pxa-PXA_ESERIES-depends-on-FB_W100.patch b/recipes/linux/linux-omap-2.6.37/linus/0001-ARM-pxa-PXA_ESERIES-depends-on-FB_W100.patch new file mode 100644 index 0000000000..25952cc44a --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0001-ARM-pxa-PXA_ESERIES-depends-on-FB_W100.patch @@ -0,0 +1,29 @@ +From a74b74a5555c741ed3df896096e33b853995631e Mon Sep 17 00:00:00 2001 +From: Lennert Buytenhek <buytenh@wantstofly.org> +Date: Wed, 15 Dec 2010 07:20:16 +0800 +Subject: [PATCH 01/66] ARM: pxa: PXA_ESERIES depends on FB_W100. + +As arch/arm/mach-pxa/eseries.c references w100fb_gpio_{read,write}() +directly. + +Signed-off-by: Lennert Buytenhek <buytenh@secretlab.ca> +Signed-off-by: Eric Miao <eric.y.miao@gmail.com> +--- + arch/arm/mach-pxa/Kconfig | 1 + + 1 files changed, 1 insertions(+), 0 deletions(-) + +diff --git a/arch/arm/mach-pxa/Kconfig b/arch/arm/mach-pxa/Kconfig +index dd235ec..c93e73d 100644 +--- a/arch/arm/mach-pxa/Kconfig ++++ b/arch/arm/mach-pxa/Kconfig +@@ -540,6 +540,7 @@ config MACH_ICONTROL + config ARCH_PXA_ESERIES + bool "PXA based Toshiba e-series PDAs" + select PXA25x ++ select FB_W100 + + config MACH_E330 + bool "Toshiba e330" +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0002-ARM-smp-avoid-incrementing-mm_users-on-CPU-startup.patch b/recipes/linux/linux-omap-2.6.37/linus/0002-ARM-smp-avoid-incrementing-mm_users-on-CPU-startup.patch new file mode 100644 index 0000000000..18a31eec6d --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0002-ARM-smp-avoid-incrementing-mm_users-on-CPU-startup.patch @@ -0,0 +1,32 @@ +From 1ae1b5f053cf36bd0f913e83f3b136fec8152d4d Mon Sep 17 00:00:00 2001 +From: Russell King <rmk+kernel@arm.linux.org.uk> +Date: Sat, 18 Dec 2010 13:57:00 +0000 +Subject: [PATCH 02/66] ARM: smp: avoid incrementing mm_users on CPU startup + +We should not be incrementing mm_users when we startup a secondary +CPU - doing so results in mm_users incrementing by one each time we +hotplug a CPU, which will eventually wrap, and will cause problems. + +Other architectures such as x86 do not increment mm_users, but only +mm_count, so we follow that pattern. + +Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk> +--- + arch/arm/kernel/smp.c | 1 - + 1 files changed, 0 insertions(+), 1 deletions(-) + +diff --git a/arch/arm/kernel/smp.c b/arch/arm/kernel/smp.c +index 8c19595..9066473 100644 +--- a/arch/arm/kernel/smp.c ++++ b/arch/arm/kernel/smp.c +@@ -310,7 +310,6 @@ asmlinkage void __cpuinit secondary_start_kernel(void) + * All kernel threads share the same mm context; grab a + * reference and switch to it. + */ +- atomic_inc(&mm->mm_users); + atomic_inc(&mm->mm_count); + current->active_mm = mm; + cpumask_set_cpu(cpu, mm_cpumask(mm)); +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0003-ARM-get-rid-of-kmap_high_l1_vipt.patch b/recipes/linux/linux-omap-2.6.37/linus/0003-ARM-get-rid-of-kmap_high_l1_vipt.patch new file mode 100644 index 0000000000..1e3e26b538 --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0003-ARM-get-rid-of-kmap_high_l1_vipt.patch @@ -0,0 +1,186 @@ +From 39af22a79232373764904576f31572f1db76af10 Mon Sep 17 00:00:00 2001 +From: Nicolas Pitre <nicolas.pitre@linaro.org> +Date: Wed, 15 Dec 2010 15:14:45 -0500 +Subject: [PATCH 03/66] ARM: get rid of kmap_high_l1_vipt() + +Since commit 3e4d3af501 "mm: stack based kmap_atomic()", it is no longer +necessary to carry an ad hoc version of kmap_atomic() added in commit +7e5a69e83b "ARM: 6007/1: fix highmem with VIPT cache and DMA" to cope +with reentrancy. + +In fact, it is now actively wrong to rely on fixed kmap type indices +(namely KM_L1_CACHE) as kmap_atomic() totally ignores them now and a +concurrent instance of it may reuse any slot for any purpose. + +Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org> +--- + arch/arm/include/asm/highmem.h | 3 - + arch/arm/mm/dma-mapping.c | 7 ++- + arch/arm/mm/flush.c | 7 ++- + arch/arm/mm/highmem.c | 87 ---------------------------------------- + 4 files changed, 8 insertions(+), 96 deletions(-) + +diff --git a/arch/arm/include/asm/highmem.h b/arch/arm/include/asm/highmem.h +index 1fc684e..7080e2c 100644 +--- a/arch/arm/include/asm/highmem.h ++++ b/arch/arm/include/asm/highmem.h +@@ -25,9 +25,6 @@ extern void *kmap_high(struct page *page); + extern void *kmap_high_get(struct page *page); + extern void kunmap_high(struct page *page); + +-extern void *kmap_high_l1_vipt(struct page *page, pte_t *saved_pte); +-extern void kunmap_high_l1_vipt(struct page *page, pte_t saved_pte); +- + /* + * The following functions are already defined by <linux/highmem.h> + * when CONFIG_HIGHMEM is not set. +diff --git a/arch/arm/mm/dma-mapping.c b/arch/arm/mm/dma-mapping.c +index ac6a361..809f1bf 100644 +--- a/arch/arm/mm/dma-mapping.c ++++ b/arch/arm/mm/dma-mapping.c +@@ -17,6 +17,7 @@ + #include <linux/init.h> + #include <linux/device.h> + #include <linux/dma-mapping.h> ++#include <linux/highmem.h> + + #include <asm/memory.h> + #include <asm/highmem.h> +@@ -480,10 +481,10 @@ static void dma_cache_maint_page(struct page *page, unsigned long offset, + op(vaddr, len, dir); + kunmap_high(page); + } else if (cache_is_vipt()) { +- pte_t saved_pte; +- vaddr = kmap_high_l1_vipt(page, &saved_pte); ++ /* unmapped pages might still be cached */ ++ vaddr = kmap_atomic(page); + op(vaddr + offset, len, dir); +- kunmap_high_l1_vipt(page, saved_pte); ++ kunmap_atomic(vaddr); + } + } else { + vaddr = page_address(page) + offset; +diff --git a/arch/arm/mm/flush.c b/arch/arm/mm/flush.c +index 391ffae..c29f283 100644 +--- a/arch/arm/mm/flush.c ++++ b/arch/arm/mm/flush.c +@@ -10,6 +10,7 @@ + #include <linux/module.h> + #include <linux/mm.h> + #include <linux/pagemap.h> ++#include <linux/highmem.h> + + #include <asm/cacheflush.h> + #include <asm/cachetype.h> +@@ -180,10 +181,10 @@ void __flush_dcache_page(struct address_space *mapping, struct page *page) + __cpuc_flush_dcache_area(addr, PAGE_SIZE); + kunmap_high(page); + } else if (cache_is_vipt()) { +- pte_t saved_pte; +- addr = kmap_high_l1_vipt(page, &saved_pte); ++ /* unmapped pages might still be cached */ ++ addr = kmap_atomic(page); + __cpuc_flush_dcache_area(addr, PAGE_SIZE); +- kunmap_high_l1_vipt(page, saved_pte); ++ kunmap_atomic(addr); + } + } + +diff --git a/arch/arm/mm/highmem.c b/arch/arm/mm/highmem.c +index c435fd9..807c057 100644 +--- a/arch/arm/mm/highmem.c ++++ b/arch/arm/mm/highmem.c +@@ -140,90 +140,3 @@ struct page *kmap_atomic_to_page(const void *ptr) + pte = TOP_PTE(vaddr); + return pte_page(*pte); + } +- +-#ifdef CONFIG_CPU_CACHE_VIPT +- +-#include <linux/percpu.h> +- +-/* +- * The VIVT cache of a highmem page is always flushed before the page +- * is unmapped. Hence unmapped highmem pages need no cache maintenance +- * in that case. +- * +- * However unmapped pages may still be cached with a VIPT cache, and +- * it is not possible to perform cache maintenance on them using physical +- * addresses unfortunately. So we have no choice but to set up a temporary +- * virtual mapping for that purpose. +- * +- * Yet this VIPT cache maintenance may be triggered from DMA support +- * functions which are possibly called from interrupt context. As we don't +- * want to keep interrupt disabled all the time when such maintenance is +- * taking place, we therefore allow for some reentrancy by preserving and +- * restoring the previous fixmap entry before the interrupted context is +- * resumed. If the reentrancy depth is 0 then there is no need to restore +- * the previous fixmap, and leaving the current one in place allow it to +- * be reused the next time without a TLB flush (common with DMA). +- */ +- +-static DEFINE_PER_CPU(int, kmap_high_l1_vipt_depth); +- +-void *kmap_high_l1_vipt(struct page *page, pte_t *saved_pte) +-{ +- unsigned int idx, cpu; +- int *depth; +- unsigned long vaddr, flags; +- pte_t pte, *ptep; +- +- if (!in_interrupt()) +- preempt_disable(); +- +- cpu = smp_processor_id(); +- depth = &per_cpu(kmap_high_l1_vipt_depth, cpu); +- +- idx = KM_L1_CACHE + KM_TYPE_NR * cpu; +- vaddr = __fix_to_virt(FIX_KMAP_BEGIN + idx); +- ptep = TOP_PTE(vaddr); +- pte = mk_pte(page, kmap_prot); +- +- raw_local_irq_save(flags); +- (*depth)++; +- if (pte_val(*ptep) == pte_val(pte)) { +- *saved_pte = pte; +- } else { +- *saved_pte = *ptep; +- set_pte_ext(ptep, pte, 0); +- local_flush_tlb_kernel_page(vaddr); +- } +- raw_local_irq_restore(flags); +- +- return (void *)vaddr; +-} +- +-void kunmap_high_l1_vipt(struct page *page, pte_t saved_pte) +-{ +- unsigned int idx, cpu = smp_processor_id(); +- int *depth = &per_cpu(kmap_high_l1_vipt_depth, cpu); +- unsigned long vaddr, flags; +- pte_t pte, *ptep; +- +- idx = KM_L1_CACHE + KM_TYPE_NR * cpu; +- vaddr = __fix_to_virt(FIX_KMAP_BEGIN + idx); +- ptep = TOP_PTE(vaddr); +- pte = mk_pte(page, kmap_prot); +- +- BUG_ON(pte_val(*ptep) != pte_val(pte)); +- BUG_ON(*depth <= 0); +- +- raw_local_irq_save(flags); +- (*depth)--; +- if (*depth != 0 && pte_val(pte) != pte_val(saved_pte)) { +- set_pte_ext(ptep, saved_pte, 0); +- local_flush_tlb_kernel_page(vaddr); +- } +- raw_local_irq_restore(flags); +- +- if (!in_interrupt()) +- preempt_enable(); +-} +- +-#endif /* CONFIG_CPU_CACHE_VIPT */ +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0004-ARM-fix-cache-xsc3l2-after-stack-based-kmap_atomic.patch b/recipes/linux/linux-omap-2.6.37/linus/0004-ARM-fix-cache-xsc3l2-after-stack-based-kmap_atomic.patch new file mode 100644 index 0000000000..8dccad065d --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0004-ARM-fix-cache-xsc3l2-after-stack-based-kmap_atomic.patch @@ -0,0 +1,189 @@ +From 25cbe45440ea89a3b0f6f7ed326d3d476d53068b Mon Sep 17 00:00:00 2001 +From: Nicolas Pitre <nicolas.pitre@linaro.org> +Date: Wed, 15 Dec 2010 23:29:04 -0500 +Subject: [PATCH 04/66] ARM: fix cache-xsc3l2 after stack based kmap_atomic() + +Since commit 3e4d3af501 "mm: stack based kmap_atomic()", it is actively +wrong to rely on fixed kmap type indices (namely KM_L2_CACHE) as +kmap_atomic() totally ignores them and a concurrent instance of it may +happily reuse any slot for any purpose. Because kmap_atomic() is now +able to deal with reentrancy, we can get rid of the ad hoc mapping here, +and we even don't have to disable IRQs anymore (highmem case). + +While the code is made much simpler, there is a needless cache flush +introduced by the usage of __kunmap_atomic(). It is not clear if the +performance difference to remove that is worth the cost in code +maintenance (I don't think there are that many highmem users on that +platform if at all anyway). + +Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org> +--- + arch/arm/mm/cache-xsc3l2.c | 57 ++++++++++++++++--------------------------- + 1 files changed, 21 insertions(+), 36 deletions(-) + +diff --git a/arch/arm/mm/cache-xsc3l2.c b/arch/arm/mm/cache-xsc3l2.c +index c315492..5a32020 100644 +--- a/arch/arm/mm/cache-xsc3l2.c ++++ b/arch/arm/mm/cache-xsc3l2.c +@@ -17,14 +17,10 @@ + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + */ + #include <linux/init.h> ++#include <linux/highmem.h> + #include <asm/system.h> + #include <asm/cputype.h> + #include <asm/cacheflush.h> +-#include <asm/kmap_types.h> +-#include <asm/fixmap.h> +-#include <asm/pgtable.h> +-#include <asm/tlbflush.h> +-#include "mm.h" + + #define CR_L2 (1 << 26) + +@@ -71,16 +67,15 @@ static inline void xsc3_l2_inv_all(void) + dsb(); + } + ++static inline void l2_unmap_va(unsigned long va) ++{ + #ifdef CONFIG_HIGHMEM +-#define l2_map_save_flags(x) raw_local_save_flags(x) +-#define l2_map_restore_flags(x) raw_local_irq_restore(x) +-#else +-#define l2_map_save_flags(x) ((x) = 0) +-#define l2_map_restore_flags(x) ((void)(x)) ++ if (va != -1) ++ kunmap_atomic((void *)va); + #endif ++} + +-static inline unsigned long l2_map_va(unsigned long pa, unsigned long prev_va, +- unsigned long flags) ++static inline unsigned long l2_map_va(unsigned long pa, unsigned long prev_va) + { + #ifdef CONFIG_HIGHMEM + unsigned long va = prev_va & PAGE_MASK; +@@ -89,17 +84,10 @@ static inline unsigned long l2_map_va(unsigned long pa, unsigned long prev_va, + /* + * Switching to a new page. Because cache ops are + * using virtual addresses only, we must put a mapping +- * in place for it. We also enable interrupts for a +- * short while and disable them again to protect this +- * mapping. ++ * in place for it. + */ +- unsigned long idx; +- raw_local_irq_restore(flags); +- idx = KM_L2_CACHE + KM_TYPE_NR * smp_processor_id(); +- va = __fix_to_virt(FIX_KMAP_BEGIN + idx); +- raw_local_irq_restore(flags | PSR_I_BIT); +- set_pte_ext(TOP_PTE(va), pfn_pte(pa >> PAGE_SHIFT, PAGE_KERNEL), 0); +- local_flush_tlb_kernel_page(va); ++ l2_unmap_va(prev_va); ++ va = (unsigned long)kmap_atomic_pfn(pa >> PAGE_SHIFT); + } + return va + (pa_offset >> (32 - PAGE_SHIFT)); + #else +@@ -109,7 +97,7 @@ static inline unsigned long l2_map_va(unsigned long pa, unsigned long prev_va, + + static void xsc3_l2_inv_range(unsigned long start, unsigned long end) + { +- unsigned long vaddr, flags; ++ unsigned long vaddr; + + if (start == 0 && end == -1ul) { + xsc3_l2_inv_all(); +@@ -117,13 +105,12 @@ static void xsc3_l2_inv_range(unsigned long start, unsigned long end) + } + + vaddr = -1; /* to force the first mapping */ +- l2_map_save_flags(flags); + + /* + * Clean and invalidate partial first cache line. + */ + if (start & (CACHE_LINE_SIZE - 1)) { +- vaddr = l2_map_va(start & ~(CACHE_LINE_SIZE - 1), vaddr, flags); ++ vaddr = l2_map_va(start & ~(CACHE_LINE_SIZE - 1), vaddr); + xsc3_l2_clean_mva(vaddr); + xsc3_l2_inv_mva(vaddr); + start = (start | (CACHE_LINE_SIZE - 1)) + 1; +@@ -133,7 +120,7 @@ static void xsc3_l2_inv_range(unsigned long start, unsigned long end) + * Invalidate all full cache lines between 'start' and 'end'. + */ + while (start < (end & ~(CACHE_LINE_SIZE - 1))) { +- vaddr = l2_map_va(start, vaddr, flags); ++ vaddr = l2_map_va(start, vaddr); + xsc3_l2_inv_mva(vaddr); + start += CACHE_LINE_SIZE; + } +@@ -142,31 +129,30 @@ static void xsc3_l2_inv_range(unsigned long start, unsigned long end) + * Clean and invalidate partial last cache line. + */ + if (start < end) { +- vaddr = l2_map_va(start, vaddr, flags); ++ vaddr = l2_map_va(start, vaddr); + xsc3_l2_clean_mva(vaddr); + xsc3_l2_inv_mva(vaddr); + } + +- l2_map_restore_flags(flags); ++ l2_unmap_va(vaddr); + + dsb(); + } + + static void xsc3_l2_clean_range(unsigned long start, unsigned long end) + { +- unsigned long vaddr, flags; ++ unsigned long vaddr; + + vaddr = -1; /* to force the first mapping */ +- l2_map_save_flags(flags); + + start &= ~(CACHE_LINE_SIZE - 1); + while (start < end) { +- vaddr = l2_map_va(start, vaddr, flags); ++ vaddr = l2_map_va(start, vaddr); + xsc3_l2_clean_mva(vaddr); + start += CACHE_LINE_SIZE; + } + +- l2_map_restore_flags(flags); ++ l2_unmap_va(vaddr); + + dsb(); + } +@@ -193,7 +179,7 @@ static inline void xsc3_l2_flush_all(void) + + static void xsc3_l2_flush_range(unsigned long start, unsigned long end) + { +- unsigned long vaddr, flags; ++ unsigned long vaddr; + + if (start == 0 && end == -1ul) { + xsc3_l2_flush_all(); +@@ -201,17 +187,16 @@ static void xsc3_l2_flush_range(unsigned long start, unsigned long end) + } + + vaddr = -1; /* to force the first mapping */ +- l2_map_save_flags(flags); + + start &= ~(CACHE_LINE_SIZE - 1); + while (start < end) { +- vaddr = l2_map_va(start, vaddr, flags); ++ vaddr = l2_map_va(start, vaddr); + xsc3_l2_clean_mva(vaddr); + xsc3_l2_inv_mva(vaddr); + start += CACHE_LINE_SIZE; + } + +- l2_map_restore_flags(flags); ++ l2_unmap_va(vaddr); + + dsb(); + } +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0005-ARM-fix-cache-feroceon-l2-after-stack-based-kmap_ato.patch b/recipes/linux/linux-omap-2.6.37/linus/0005-ARM-fix-cache-feroceon-l2-after-stack-based-kmap_ato.patch new file mode 100644 index 0000000000..03cb474182 --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0005-ARM-fix-cache-feroceon-l2-after-stack-based-kmap_ato.patch @@ -0,0 +1,119 @@ +From 6d3e6d3640052cac958d61c44597cc216f6ee09f Mon Sep 17 00:00:00 2001 +From: Nicolas Pitre <nicolas.pitre@linaro.org> +Date: Thu, 16 Dec 2010 14:56:34 -0500 +Subject: [PATCH 05/66] ARM: fix cache-feroceon-l2 after stack based kmap_atomic() + +Since commit 3e4d3af501 "mm: stack based kmap_atomic()", it is actively +wrong to rely on fixed kmap type indices (namely KM_L2_CACHE) as +kmap_atomic() totally ignores them and a concurrent instance of it may +happily reuse any slot for any purpose. Because kmap_atomic() is now +able to deal with reentrancy, we can get rid of the ad hoc mapping here. + +While the code is made much simpler, there is a needless cache flush +introduced by the usage of __kunmap_atomic(). It is not clear if the +performance difference to remove that is worth the cost in code +maintenance (I don't think there are that many highmem users on that +platform anyway) but that should be reconsidered when/if someone cares +enough to do some measurements. + +Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org> +--- + arch/arm/mm/cache-feroceon-l2.c | 37 +++++++++++++++++++------------------ + 1 files changed, 19 insertions(+), 18 deletions(-) + +diff --git a/arch/arm/mm/cache-feroceon-l2.c b/arch/arm/mm/cache-feroceon-l2.c +index 6e77c04..e0b0e7a 100644 +--- a/arch/arm/mm/cache-feroceon-l2.c ++++ b/arch/arm/mm/cache-feroceon-l2.c +@@ -13,13 +13,9 @@ + */ + + #include <linux/init.h> ++#include <linux/highmem.h> + #include <asm/cacheflush.h> +-#include <asm/kmap_types.h> +-#include <asm/fixmap.h> +-#include <asm/pgtable.h> +-#include <asm/tlbflush.h> + #include <plat/cache-feroceon-l2.h> +-#include "mm.h" + + /* + * Low-level cache maintenance operations. +@@ -39,27 +35,30 @@ + * between which we don't want to be preempted. + */ + +-static inline unsigned long l2_start_va(unsigned long paddr) ++static inline unsigned long l2_get_va(unsigned long paddr) + { + #ifdef CONFIG_HIGHMEM + /* +- * Let's do our own fixmap stuff in a minimal way here. + * Because range ops can't be done on physical addresses, + * we simply install a virtual mapping for it only for the + * TLB lookup to occur, hence no need to flush the untouched +- * memory mapping. This is protected with the disabling of +- * interrupts by the caller. ++ * memory mapping afterwards (note: a cache flush may happen ++ * in some circumstances depending on the path taken in kunmap_atomic). + */ +- unsigned long idx = KM_L2_CACHE + KM_TYPE_NR * smp_processor_id(); +- unsigned long vaddr = __fix_to_virt(FIX_KMAP_BEGIN + idx); +- set_pte_ext(TOP_PTE(vaddr), pfn_pte(paddr >> PAGE_SHIFT, PAGE_KERNEL), 0); +- local_flush_tlb_kernel_page(vaddr); +- return vaddr + (paddr & ~PAGE_MASK); ++ void *vaddr = kmap_atomic_pfn(paddr >> PAGE_SHIFT); ++ return (unsigned long)vaddr + (paddr & ~PAGE_MASK); + #else + return __phys_to_virt(paddr); + #endif + } + ++static inline void l2_put_va(unsigned long vaddr) ++{ ++#ifdef CONFIG_HIGHMEM ++ kunmap_atomic((void *)vaddr); ++#endif ++} ++ + static inline void l2_clean_pa(unsigned long addr) + { + __asm__("mcr p15, 1, %0, c15, c9, 3" : : "r" (addr)); +@@ -76,13 +75,14 @@ static inline void l2_clean_pa_range(unsigned long start, unsigned long end) + */ + BUG_ON((start ^ end) >> PAGE_SHIFT); + +- raw_local_irq_save(flags); +- va_start = l2_start_va(start); ++ va_start = l2_get_va(start); + va_end = va_start + (end - start); ++ raw_local_irq_save(flags); + __asm__("mcr p15, 1, %0, c15, c9, 4\n\t" + "mcr p15, 1, %1, c15, c9, 5" + : : "r" (va_start), "r" (va_end)); + raw_local_irq_restore(flags); ++ l2_put_va(va_start); + } + + static inline void l2_clean_inv_pa(unsigned long addr) +@@ -106,13 +106,14 @@ static inline void l2_inv_pa_range(unsigned long start, unsigned long end) + */ + BUG_ON((start ^ end) >> PAGE_SHIFT); + +- raw_local_irq_save(flags); +- va_start = l2_start_va(start); ++ va_start = l2_get_va(start); + va_end = va_start + (end - start); ++ raw_local_irq_save(flags); + __asm__("mcr p15, 1, %0, c15, c11, 4\n\t" + "mcr p15, 1, %1, c15, c11, 5" + : : "r" (va_start), "r" (va_end)); + raw_local_irq_restore(flags); ++ l2_put_va(va_start); + } + + static inline void l2_inv_all(void) +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0006-drm-i915-Set-the-required-VFMUNIT-clock-gating-disab.patch b/recipes/linux/linux-omap-2.6.37/linus/0006-drm-i915-Set-the-required-VFMUNIT-clock-gating-disab.patch new file mode 100644 index 0000000000..6abd601e84 --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0006-drm-i915-Set-the-required-VFMUNIT-clock-gating-disab.patch @@ -0,0 +1,45 @@ +From 06f37751af77192b424b2b0ff17dc08de65faba0 Mon Sep 17 00:00:00 2001 +From: Eric Anholt <eric@anholt.net> +Date: Tue, 14 Dec 2010 10:06:46 -0800 +Subject: [PATCH 06/66] drm/i915: Set the required VFMUNIT clock gating disable on Ironlake. + +It's required by the specs, but we don't know why. Let's not find out +why. + +Signed-off-by: Eric Anholt <eric@anholt.net> +Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> +--- + drivers/gpu/drm/i915/i915_reg.h | 3 +++ + drivers/gpu/drm/i915/intel_display.c | 2 ++ + 2 files changed, 5 insertions(+), 0 deletions(-) + +diff --git a/drivers/gpu/drm/i915/i915_reg.h b/drivers/gpu/drm/i915/i915_reg.h +index 878fc76..8470a97 100644 +--- a/drivers/gpu/drm/i915/i915_reg.h ++++ b/drivers/gpu/drm/i915/i915_reg.h +@@ -2471,6 +2471,9 @@ + # define MARIUNIT_CLOCK_GATE_DISABLE (1 << 18) + # define SVSMUNIT_CLOCK_GATE_DISABLE (1 << 1) + ++#define PCH_3DCGDIS1 0x46024 ++# define VFMUNIT_CLOCK_GATE_DISABLE (1 << 11) ++ + #define FDI_PLL_FREQ_CTL 0x46030 + #define FDI_PLL_FREQ_CHANGE_REQUEST (1<<24) + #define FDI_PLL_FREQ_LOCK_LIMIT_MASK 0xfff00 +diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c +index d9b7092..97e374e 100644 +--- a/drivers/gpu/drm/i915/intel_display.c ++++ b/drivers/gpu/drm/i915/intel_display.c +@@ -5825,6 +5825,8 @@ void intel_init_clock_gating(struct drm_device *dev) + I915_WRITE(PCH_3DCGDIS0, + MARIUNIT_CLOCK_GATE_DISABLE | + SVSMUNIT_CLOCK_GATE_DISABLE); ++ I915_WRITE(PCH_3DCGDIS1, ++ VFMUNIT_CLOCK_GATE_DISABLE); + } + + I915_WRITE(PCH_DSPCLK_GATE_D, dspclk_gate); +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0007-drm-i915-sdvo-Add-hdmi-connector-properties-after-in.patch b/recipes/linux/linux-omap-2.6.37/linus/0007-drm-i915-sdvo-Add-hdmi-connector-properties-after-in.patch new file mode 100644 index 0000000000..98012d6758 --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0007-drm-i915-sdvo-Add-hdmi-connector-properties-after-in.patch @@ -0,0 +1,38 @@ +From f797d22121404eac7b63f1291409f96bcab51c11 Mon Sep 17 00:00:00 2001 +From: Chris Wilson <chris@chris-wilson.co.uk> +Date: Thu, 23 Dec 2010 09:43:48 +0000 +Subject: [PATCH 07/66] drm/i915/sdvo: Add hdmi connector properties after initing the connector +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=25012 +Reported-by: Tõnu Raitviir <jussuf@linux.ee> +Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> +--- + drivers/gpu/drm/i915/intel_sdvo.c | 3 ++- + 1 files changed, 2 insertions(+), 1 deletions(-) + +diff --git a/drivers/gpu/drm/i915/intel_sdvo.c b/drivers/gpu/drm/i915/intel_sdvo.c +index 27e63ab..6bc42fa 100644 +--- a/drivers/gpu/drm/i915/intel_sdvo.c ++++ b/drivers/gpu/drm/i915/intel_sdvo.c +@@ -2040,13 +2040,14 @@ intel_sdvo_dvi_init(struct intel_sdvo *intel_sdvo, int device) + SDVO_COLORIMETRY_RGB256); + connector->connector_type = DRM_MODE_CONNECTOR_HDMIA; + +- intel_sdvo_add_hdmi_properties(intel_sdvo_connector); + intel_sdvo->is_hdmi = true; + } + intel_sdvo->base.clone_mask = ((1 << INTEL_SDVO_NON_TV_CLONE_BIT) | + (1 << INTEL_ANALOG_CLONE_BIT)); + + intel_sdvo_connector_init(intel_sdvo_connector, intel_sdvo); ++ if (intel_sdvo->is_hdmi) ++ intel_sdvo_add_hdmi_properties(intel_sdvo_connector); + + return true; + } +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0008-drm-i915-intel_ips-When-i915-loads-after-IPS-make-IP.patch b/recipes/linux/linux-omap-2.6.37/linus/0008-drm-i915-intel_ips-When-i915-loads-after-IPS-make-IP.patch new file mode 100644 index 0000000000..f28473b519 --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0008-drm-i915-intel_ips-When-i915-loads-after-IPS-make-IP.patch @@ -0,0 +1,190 @@ +From 63ee41d794d9c555f84205517a68509848988760 Mon Sep 17 00:00:00 2001 +From: Eric Anholt <eric@anholt.net> +Date: Mon, 20 Dec 2010 18:40:06 -0800 +Subject: [PATCH 08/66] drm/i915, intel_ips: When i915 loads after IPS, make IPS relink to i915. + +The IPS driver is designed to be able to run detached from i915 and +just not enable GPU turbo in that case, in order to avoid module +dependencies between the two drivers. This means that we don't know +what the load order between the two is going to be, and we had +previously only supported IPS after (optionally) i915, but not i915 +after IPS. If the wrong order was chosen, you'd get no GPU turbo, and +something like half the possible graphics performance. + +Signed-off-by: Eric Anholt <eric@anholt.net> +Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> +Cc: stable@kernel.org +--- + drivers/gpu/drm/i915/i915_dma.c | 23 +++++++++++++++++++++++ + drivers/platform/x86/intel_ips.c | 36 +++++++++++++++++++++++++++++++++--- + drivers/platform/x86/intel_ips.h | 21 +++++++++++++++++++++ + 3 files changed, 77 insertions(+), 3 deletions(-) + create mode 100644 drivers/platform/x86/intel_ips.h + +diff --git a/drivers/gpu/drm/i915/i915_dma.c b/drivers/gpu/drm/i915/i915_dma.c +index e680081..cb900dc 100644 +--- a/drivers/gpu/drm/i915/i915_dma.c ++++ b/drivers/gpu/drm/i915/i915_dma.c +@@ -34,6 +34,7 @@ + #include "i915_drm.h" + #include "i915_drv.h" + #include "i915_trace.h" ++#include "../../../platform/x86/intel_ips.h" + #include <linux/pci.h> + #include <linux/vgaarb.h> + #include <linux/acpi.h> +@@ -1871,6 +1872,26 @@ out_unlock: + EXPORT_SYMBOL_GPL(i915_gpu_turbo_disable); + + /** ++ * Tells the intel_ips driver that the i915 driver is now loaded, if ++ * IPS got loaded first. ++ * ++ * This awkward dance is so that neither module has to depend on the ++ * other in order for IPS to do the appropriate communication of ++ * GPU turbo limits to i915. ++ */ ++static void ++ips_ping_for_i915_load(void) ++{ ++ void (*link)(void); ++ ++ link = symbol_get(ips_link_to_i915_driver); ++ if (link) { ++ link(); ++ symbol_put(ips_link_to_i915_driver); ++ } ++} ++ ++/** + * i915_driver_load - setup chip and create an initial config + * @dev: DRM device + * @flags: startup flags +@@ -2075,6 +2096,8 @@ int i915_driver_load(struct drm_device *dev, unsigned long flags) + dev_priv->mchdev_lock = &mchdev_lock; + spin_unlock(&mchdev_lock); + ++ ips_ping_for_i915_load(); ++ + return 0; + + out_workqueue_free: +diff --git a/drivers/platform/x86/intel_ips.c b/drivers/platform/x86/intel_ips.c +index c44a5e8..f0b3ad1 100644 +--- a/drivers/platform/x86/intel_ips.c ++++ b/drivers/platform/x86/intel_ips.c +@@ -75,6 +75,7 @@ + #include <drm/i915_drm.h> + #include <asm/msr.h> + #include <asm/processor.h> ++#include "intel_ips.h" + + #define PCI_DEVICE_ID_INTEL_THERMAL_SENSOR 0x3b32 + +@@ -245,6 +246,7 @@ + #define thm_writel(off, val) writel((val), ips->regmap + (off)) + + static const int IPS_ADJUST_PERIOD = 5000; /* ms */ ++static bool late_i915_load = false; + + /* For initial average collection */ + static const int IPS_SAMPLE_PERIOD = 200; /* ms */ +@@ -339,6 +341,9 @@ struct ips_driver { + u64 orig_turbo_ratios; + }; + ++static bool ++ips_gpu_turbo_enabled(struct ips_driver *ips); ++ + /** + * ips_cpu_busy - is CPU busy? + * @ips: IPS driver struct +@@ -517,7 +522,7 @@ static void ips_disable_cpu_turbo(struct ips_driver *ips) + */ + static bool ips_gpu_busy(struct ips_driver *ips) + { +- if (!ips->gpu_turbo_enabled) ++ if (!ips_gpu_turbo_enabled(ips)) + return false; + + return ips->gpu_busy(); +@@ -532,7 +537,7 @@ static bool ips_gpu_busy(struct ips_driver *ips) + */ + static void ips_gpu_raise(struct ips_driver *ips) + { +- if (!ips->gpu_turbo_enabled) ++ if (!ips_gpu_turbo_enabled(ips)) + return; + + if (!ips->gpu_raise()) +@@ -549,7 +554,7 @@ static void ips_gpu_raise(struct ips_driver *ips) + */ + static void ips_gpu_lower(struct ips_driver *ips) + { +- if (!ips->gpu_turbo_enabled) ++ if (!ips_gpu_turbo_enabled(ips)) + return; + + if (!ips->gpu_lower()) +@@ -1454,6 +1459,31 @@ out_err: + return false; + } + ++static bool ++ips_gpu_turbo_enabled(struct ips_driver *ips) ++{ ++ if (!ips->gpu_busy && late_i915_load) { ++ if (ips_get_i915_syms(ips)) { ++ dev_info(&ips->dev->dev, ++ "i915 driver attached, reenabling gpu turbo\n"); ++ ips->gpu_turbo_enabled = !(thm_readl(THM_HTS) & HTS_GTD_DIS); ++ } ++ } ++ ++ return ips->gpu_turbo_enabled; ++} ++ ++void ++ips_link_to_i915_driver() ++{ ++ /* We can't cleanly get at the various ips_driver structs from ++ * this caller (the i915 driver), so just set a flag saying ++ * that it's time to try getting the symbols again. ++ */ ++ late_i915_load = true; ++} ++EXPORT_SYMBOL_GPL(ips_link_to_i915_driver); ++ + static DEFINE_PCI_DEVICE_TABLE(ips_id_table) = { + { PCI_DEVICE(PCI_VENDOR_ID_INTEL, + PCI_DEVICE_ID_INTEL_THERMAL_SENSOR), }, +diff --git a/drivers/platform/x86/intel_ips.h b/drivers/platform/x86/intel_ips.h +new file mode 100644 +index 0000000..73299be +--- /dev/null ++++ b/drivers/platform/x86/intel_ips.h +@@ -0,0 +1,21 @@ ++/* ++ * Copyright (c) 2010 Intel Corporation ++ * ++ * This program is free software; you can redistribute it and/or modify it ++ * under the terms and conditions of the GNU General Public License, ++ * version 2, as published by the Free Software Foundation. ++ * ++ * This program is distributed in the hope it will be useful, but WITHOUT ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for ++ * more details. ++ * ++ * You should have received a copy of the GNU General Public License along with ++ * this program; if not, write to the Free Software Foundation, Inc., ++ * 51 Franklin St - Fifth Floor, Boston, MA 02110-1301 USA. ++ * ++ * The full GNU General Public License is included in this distribution in ++ * the file called "COPYING". ++ */ ++ ++void ips_link_to_i915_driver(void); +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0009-drm-i915-Verify-Ironlake-eDP-presence-on-DP_A-using-.patch b/recipes/linux/linux-omap-2.6.37/linus/0009-drm-i915-Verify-Ironlake-eDP-presence-on-DP_A-using-.patch new file mode 100644 index 0000000000..7a9caf6e0f --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0009-drm-i915-Verify-Ironlake-eDP-presence-on-DP_A-using-.patch @@ -0,0 +1,69 @@ +From 4d3024428f5c3ef5295e6f6fb257ae118b3f93a1 Mon Sep 17 00:00:00 2001 +From: Chris Wilson <chris@chris-wilson.co.uk> +Date: Tue, 14 Dec 2010 19:21:29 +0000 +Subject: [PATCH 09/66] drm/i915: Verify Ironlake eDP presence on DP_A using the capability fuse + +Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> +--- + drivers/gpu/drm/i915/i915_reg.h | 7 +++++++ + drivers/gpu/drm/i915/intel_display.c | 19 ++++++++++++++++++- + 2 files changed, 25 insertions(+), 1 deletions(-) + +diff --git a/drivers/gpu/drm/i915/i915_reg.h b/drivers/gpu/drm/i915/i915_reg.h +index 8470a97..cb8f434 100644 +--- a/drivers/gpu/drm/i915/i915_reg.h ++++ b/drivers/gpu/drm/i915/i915_reg.h +@@ -2591,6 +2591,13 @@ + #define ILK_DISPLAY_CHICKEN2 0x42004 + #define ILK_DPARB_GATE (1<<22) + #define ILK_VSDPFD_FULL (1<<21) ++#define ILK_DISPLAY_CHICKEN_FUSES 0x42014 ++#define ILK_INTERNAL_GRAPHICS_DISABLE (1<<31) ++#define ILK_INTERNAL_DISPLAY_DISABLE (1<<30) ++#define ILK_DISPLAY_DEBUG_DISABLE (1<<29) ++#define ILK_HDCP_DISABLE (1<<25) ++#define ILK_eDP_A_DISABLE (1<<24) ++#define ILK_DESKTOP (1<<23) + #define ILK_DSPCLK_GATE 0x42020 + #define ILK_DPARB_CLK_GATE (1<<5) + /* According to spec this bit 7/8/9 of 0x42020 should be set to enable FBC */ +diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c +index 97e374e..fca5232 100644 +--- a/drivers/gpu/drm/i915/intel_display.c ++++ b/drivers/gpu/drm/i915/intel_display.c +@@ -5379,6 +5379,23 @@ static int intel_encoder_clones(struct drm_device *dev, int type_mask) + return index_mask; + } + ++static bool has_edp_a(struct drm_device *dev) ++{ ++ struct drm_i915_private *dev_priv = dev->dev_private; ++ ++ if (!IS_MOBILE(dev)) ++ return false; ++ ++ if ((I915_READ(DP_A) & DP_DETECTED) == 0) ++ return false; ++ ++ if (IS_GEN5(dev) && ++ (I915_READ(ILK_DISPLAY_CHICKEN_FUSES) & ILK_eDP_A_DISABLE)) ++ return false; ++ ++ return true; ++} ++ + static void intel_setup_outputs(struct drm_device *dev) + { + struct drm_i915_private *dev_priv = dev->dev_private; +@@ -5396,7 +5413,7 @@ static void intel_setup_outputs(struct drm_device *dev) + if (HAS_PCH_SPLIT(dev)) { + dpd_is_edp = intel_dpd_is_edp(dev); + +- if (IS_MOBILE(dev) && (I915_READ(DP_A) & DP_DETECTED)) ++ if (has_edp_a(dev)) + intel_dp_init(dev, DP_A); + + if (dpd_is_edp && (I915_READ(PCH_DP_D) & DP_DETECTED)) +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0010-ARM-6536-1-Add-missing-SZ_-32-64-128.patch b/recipes/linux/linux-omap-2.6.37/linus/0010-ARM-6536-1-Add-missing-SZ_-32-64-128.patch new file mode 100644 index 0000000000..11d6a44d95 --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0010-ARM-6536-1-Add-missing-SZ_-32-64-128.patch @@ -0,0 +1,42 @@ +From 537de3a67c0c86586eacffde40673b727242dc3a Mon Sep 17 00:00:00 2001 +From: Stephen Warren <swarren@nvidia.com> +Date: Wed, 22 Dec 2010 04:52:05 +0100 +Subject: [PATCH 10/66] ARM: 6536/1: Add missing SZ_{32,64,128} + +... and also remove misleading comment stating that this header is +auto-generated. + +Signed-off-by: Stephen Warren <swarren@nvidia.com> +Acked-by: Uwe Kleine-Knig <u.kleine-koenig@pengutronix.de> +Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk> +--- + arch/arm/include/asm/sizes.h | 6 +++--- + 1 files changed, 3 insertions(+), 3 deletions(-) + +diff --git a/arch/arm/include/asm/sizes.h b/arch/arm/include/asm/sizes.h +index 4fc1565..316bb2b 100644 +--- a/arch/arm/include/asm/sizes.h ++++ b/arch/arm/include/asm/sizes.h +@@ -13,9 +13,6 @@ + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + */ +-/* DO NOT EDIT!! - this file automatically generated +- * from .s file by awk -f s2h.awk +- */ + /* Size definitions + * Copyright (C) ARM Limited 1998. All rights reserved. + */ +@@ -25,6 +22,9 @@ + + /* handy sizes */ + #define SZ_16 0x00000010 ++#define SZ_32 0x00000020 ++#define SZ_64 0x00000040 ++#define SZ_128 0x00000080 + #define SZ_256 0x00000100 + #define SZ_512 0x00000200 + +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0011-ARM-6537-1-update-Nomadik-U300-and-Ux500-maintainers.patch b/recipes/linux/linux-omap-2.6.37/linus/0011-ARM-6537-1-update-Nomadik-U300-and-Ux500-maintainers.patch new file mode 100644 index 0000000000..8d7500307d --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0011-ARM-6537-1-update-Nomadik-U300-and-Ux500-maintainers.patch @@ -0,0 +1,65 @@ +From 875728807ff001b67a1e0535de5ad2cd3c41d47c Mon Sep 17 00:00:00 2001 +From: Linus Walleij <linus.walleij@stericsson.com> +Date: Wed, 22 Dec 2010 09:18:29 +0100 +Subject: [PATCH 11/66] ARM: 6537/1: update Nomadik, U300 and Ux500 maintainers + +Adding in self as maintainer for Nomadik and Ux500, I'm running +an active -next tree for that stuff now. Extend file matchers to +cover a few more relevant drivers and add git references. + +Cc: Alessandro Rubini <rubini@unipv.it> +Acked-by: Srinidhi Kasagar <srinidhi.kasagar@stericsson.com> +Signed-off-by: Linus Walleij <linus.walleij@stericsson.com> +Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk> +--- + MAINTAINERS | 17 ++++++++++++++++- + 1 files changed, 16 insertions(+), 1 deletions(-) + +diff --git a/MAINTAINERS b/MAINTAINERS +index 6a58887..4323f8f 100644 +--- a/MAINTAINERS ++++ b/MAINTAINERS +@@ -792,11 +792,14 @@ S: Maintained + + ARM/NOMADIK ARCHITECTURE + M: Alessandro Rubini <rubini@unipv.it> ++M: Linus Walleij <linus.walleij@stericsson.com> + M: STEricsson <STEricsson_nomadik_linux@list.st.com> + L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers) + S: Maintained + F: arch/arm/mach-nomadik/ + F: arch/arm/plat-nomadik/ ++F: drivers/i2c/busses/i2c-nomadik.c ++T: git git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-stericsson.git + + ARM/OPENMOKO NEO FREERUNNER (GTA02) MACHINE SUPPORT + M: Nelson Castillo <arhuaco@freaks-unidos.net> +@@ -998,12 +1001,24 @@ F: drivers/i2c/busses/i2c-stu300.c + F: drivers/rtc/rtc-coh901331.c + F: drivers/watchdog/coh901327_wdt.c + F: drivers/dma/coh901318* ++F: drivers/mfd/ab3100* ++F: drivers/rtc/rtc-ab3100.c ++F: drivers/rtc/rtc-coh901331.c ++T: git git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-stericsson.git + +-ARM/U8500 ARM ARCHITECTURE ++ARM/Ux500 ARM ARCHITECTURE + M: Srinidhi Kasagar <srinidhi.kasagar@stericsson.com> ++M: Linus Walleij <linus.walleij@stericsson.com> + L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers) + S: Maintained + F: arch/arm/mach-ux500/ ++F: drivers/dma/ste_dma40* ++F: drivers/mfd/ab3550* ++F: drivers/mfd/abx500* ++F: drivers/mfd/ab8500* ++F: drivers/mfd/stmpe* ++F: drivers/rtc/rtc-ab8500.c ++T: git git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-stericsson.git + + ARM/VFP SUPPORT + M: Russell King <linux@arm.linux.org.uk> +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0012-ARM-6540-1-Stop-irqsoff-trace-on-return-to-user.patch b/recipes/linux/linux-omap-2.6.37/linus/0012-ARM-6540-1-Stop-irqsoff-trace-on-return-to-user.patch new file mode 100644 index 0000000000..f2d4a0d420 --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0012-ARM-6540-1-Stop-irqsoff-trace-on-return-to-user.patch @@ -0,0 +1,44 @@ +From d13e5edd7284bedcf5952e1b6490e39ad843cb91 Mon Sep 17 00:00:00 2001 +From: Todd Android Poynor <toddpoynor@google.com> +Date: Thu, 23 Dec 2010 01:52:44 +0100 +Subject: [PATCH 12/66] ARM: 6540/1: Stop irqsoff trace on return to user + +If the irqsoff tracer is in use, stop tracing the interrupt disable +interval when returning to userspace. Tracing userspace execution time +as interrupts disabled time is not helpful for kernel performance +analysis purposes. Only do so if the irqsoff tracer is enabled, to +avoid overhead for lockdep, which doesn't care. + +Signed-off-by: Todd Poynor <toddpoynor@google.com> +Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk> +--- + arch/arm/kernel/entry-common.S | 6 ++++++ + 1 files changed, 6 insertions(+), 0 deletions(-) + +diff --git a/arch/arm/kernel/entry-common.S b/arch/arm/kernel/entry-common.S +index 8bfa987..80bf8cd 100644 +--- a/arch/arm/kernel/entry-common.S ++++ b/arch/arm/kernel/entry-common.S +@@ -29,6 +29,9 @@ ret_fast_syscall: + ldr r1, [tsk, #TI_FLAGS] + tst r1, #_TIF_WORK_MASK + bne fast_work_pending ++#if defined(CONFIG_IRQSOFF_TRACER) ++ asm_trace_hardirqs_on ++#endif + + /* perform architecture specific actions before user return */ + arch_ret_to_user r1, lr +@@ -65,6 +68,9 @@ ret_slow_syscall: + tst r1, #_TIF_WORK_MASK + bne work_pending + no_work_pending: ++#if defined(CONFIG_IRQSOFF_TRACER) ++ asm_trace_hardirqs_on ++#endif + /* perform architecture specific actions before user return */ + arch_ret_to_user r1, lr + +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0013-ueagle-atm-fix-PHY-signal-initialization-race.patch b/recipes/linux/linux-omap-2.6.37/linus/0013-ueagle-atm-fix-PHY-signal-initialization-race.patch new file mode 100644 index 0000000000..00ddde54e4 --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0013-ueagle-atm-fix-PHY-signal-initialization-race.patch @@ -0,0 +1,100 @@ +From 12f188f2e59394ec1f1c8c0a4439f48ec16bc336 Mon Sep 17 00:00:00 2001 +From: Dan Williams <dcbw@redhat.com> +Date: Sun, 19 Dec 2010 08:17:50 +0000 +Subject: [PATCH 13/66] ueagle-atm: fix PHY signal initialization race + +A race exists when initializing ueagle-atm devices where the generic atm +device may not yet be created before the driver attempts to initialize +it's PHY signal state, which checks whether the atm device has been +created or not. This often causes the sysfs 'carrier' attribute to be +'1' even though no signal has actually been found. + +uea_probe + usbatm_usb_probe + driver->bind (uea_bind) + uea_boot + kthread_run(uea_kthread) uea_kthread + usbatm_atm_init uea_start_reset + atm_dev_register UPDATE_ATM_SIGNAL + +UPDATE_ATM_SIGNAL checks whether the ATM device has been created and if +not, will not update the PHY signal state. Because of the race that +does not always happen in time, and the PHY signal state remains +ATM_PHY_SIG_FOUND even though no signal exists. + +To fix the race, just create the kthread during initialization, and only +after initialization is complete, start the thread that reboots the +device and initializes PHY state. + +[ 3030.490931] uea_probe: calling usbatm_usb_probe +[ 3030.490946] ueagle-atm 8-2:1.0: usbatm_usb_probe: trying driver ueagle-atm with vendor=1110, product=9031, ifnum 0 +[ 3030.493691] uea_bind: setting usbatm +[ 3030.496932] usb 8-2: [ueagle-atm] using iso mode +[ 3030.497283] ueagle-atm 8-2:1.0: usbatm_usb_probe: using 3021 byte buffer for rx channel 0xffff880125953508 + <kthread already started before usbatm_usb_probe() has returned> +[ 3030.497292] usb 8-2: [ueagle-atm] (re)booting started + <UPDATE_ATM_SIGNAL checks whether ATM device has been created yet before setting PHY state> +[ 3030.497298] uea_start_reset: atm dev (null) + <and since it hasn't been created yet PHY state is not set> +[ 3030.497306] ueagle-atm 8-2:1.0: usbatm_usb_probe: using 3392 byte buffer for tx channel 0xffff8801259535b8 +[ 3030.497374] usbatm_usb_probe: about to init +[ 3030.497379] usbatm_usb_probe: calling usbatm_atm_init + <atm device finally gets created> +[ 3030.497384] usbatm_atm_init: creating atm device! + +Signed-off-by: Dan Williams <dcbw@redhat.com> +Signed-off-by: David S. Miller <davem@davemloft.net> +--- + drivers/usb/atm/ueagle-atm.c | 22 +++++++++++++++++++--- + 1 files changed, 19 insertions(+), 3 deletions(-) + +diff --git a/drivers/usb/atm/ueagle-atm.c b/drivers/usb/atm/ueagle-atm.c +index 44447f5..99ac70e 100644 +--- a/drivers/usb/atm/ueagle-atm.c ++++ b/drivers/usb/atm/ueagle-atm.c +@@ -2206,8 +2206,11 @@ static int uea_boot(struct uea_softc *sc) + goto err1; + } + +- sc->kthread = kthread_run(uea_kthread, sc, "ueagle-atm"); +- if (sc->kthread == ERR_PTR(-ENOMEM)) { ++ /* Create worker thread, but don't start it here. Start it after ++ * all usbatm generic initialization is done. ++ */ ++ sc->kthread = kthread_create(uea_kthread, sc, "ueagle-atm"); ++ if (IS_ERR(sc->kthread)) { + uea_err(INS_TO_USBDEV(sc), "failed to create thread\n"); + goto err2; + } +@@ -2624,6 +2627,7 @@ static struct usbatm_driver uea_usbatm_driver = { + static int uea_probe(struct usb_interface *intf, const struct usb_device_id *id) + { + struct usb_device *usb = interface_to_usbdev(intf); ++ int ret; + + uea_enters(usb); + uea_info(usb, "ADSL device founded vid (%#X) pid (%#X) Rev (%#X): %s\n", +@@ -2637,7 +2641,19 @@ static int uea_probe(struct usb_interface *intf, const struct usb_device_id *id) + if (UEA_IS_PREFIRM(id)) + return uea_load_firmware(usb, UEA_CHIP_VERSION(id)); + +- return usbatm_usb_probe(intf, id, &uea_usbatm_driver); ++ ret = usbatm_usb_probe(intf, id, &uea_usbatm_driver); ++ if (ret == 0) { ++ struct usbatm_data *usbatm = usb_get_intfdata(intf); ++ struct uea_softc *sc = usbatm->driver_data; ++ ++ /* Ensure carrier is initialized to off as early as possible */ ++ UPDATE_ATM_SIGNAL(ATM_PHY_SIG_LOST); ++ ++ /* Only start the worker thread when all init is done */ ++ wake_up_process(sc->kthread); ++ } ++ ++ return ret; + } + + static void uea_disconnect(struct usb_interface *intf) +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0014-ehea-Avoid-changing-vlan-flags.patch b/recipes/linux/linux-omap-2.6.37/linus/0014-ehea-Avoid-changing-vlan-flags.patch new file mode 100644 index 0000000000..d3258e10a5 --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0014-ehea-Avoid-changing-vlan-flags.patch @@ -0,0 +1,34 @@ +From c4711786986af0cce654f493426ee0a1055e4b17 Mon Sep 17 00:00:00 2001 +From: Breno Leitao <leitao@linux.vnet.ibm.com> +Date: Mon, 20 Dec 2010 09:02:37 +0000 +Subject: [PATCH 14/66] ehea: Avoid changing vlan flags + +This patch avoids disabling the vlan flags using ethtool. + +Signed-off-by: Breno Leitao <leitao@linux.vnet.ibm.com> +Signed-off-by: David S. Miller <davem@davemloft.net> +--- + drivers/net/ehea/ehea_ethtool.c | 7 +++++++ + 1 files changed, 7 insertions(+), 0 deletions(-) + +diff --git a/drivers/net/ehea/ehea_ethtool.c b/drivers/net/ehea/ehea_ethtool.c +index 1f37ee6..d6cf502 100644 +--- a/drivers/net/ehea/ehea_ethtool.c ++++ b/drivers/net/ehea/ehea_ethtool.c +@@ -263,6 +263,13 @@ static void ehea_get_ethtool_stats(struct net_device *dev, + + static int ehea_set_flags(struct net_device *dev, u32 data) + { ++ /* Avoid changing the VLAN flags */ ++ if ((data & (ETH_FLAG_RXVLAN | ETH_FLAG_TXVLAN)) != ++ (ethtool_op_get_flags(dev) & (ETH_FLAG_RXVLAN | ++ ETH_FLAG_TXVLAN))){ ++ return -EINVAL; ++ } ++ + return ethtool_op_set_flags(dev, data, ETH_FLAG_LRO + | ETH_FLAG_TXVLAN + | ETH_FLAG_RXVLAN); +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0015-ppp-allow-disabling-multilink-protocol-ID-compressio.patch b/recipes/linux/linux-omap-2.6.37/linus/0015-ppp-allow-disabling-multilink-protocol-ID-compressio.patch new file mode 100644 index 0000000000..cfcac457e1 --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0015-ppp-allow-disabling-multilink-protocol-ID-compressio.patch @@ -0,0 +1,64 @@ +From d39cd5e99a0ad88aba6793fb5e5f34e29cda6e6f Mon Sep 17 00:00:00 2001 +From: stephen hemminger <shemminger@vyatta.com> +Date: Mon, 20 Dec 2010 17:58:33 +0000 +Subject: [PATCH 15/66] ppp: allow disabling multilink protocol ID compression + +Linux would not connect to other router running old version Cisco IOS (12.0). +This is most likely a bug in that version of IOS, since it is fixed +in later versions. As a workaround this patch allows a module parameter +to be set to disable compressing the protocol ID. + +See: https://bugzilla.vyatta.com/show_bug.cgi?id=3979 + +RFC 1990 allows an implementation to formulate MP fragments as if protocol +compression had been negotiated. This allows us to always send compressed +protocol IDs. But some implementations don't accept MP fragments with +compressed protocol IDs. This parameter allows us to interoperate with +them. The default value of the configurable parameter is the same as the +current behavior: protocol compression is enabled. If protocol compression +is disabled we will not send compressed protocol IDs. + +This is based on an earlier patch by Bob Gilligan (using a sysctl). +Module parameter is writable to allow for enabling even if ppp +is already loaded for other uses. + +Signed-off-by: Stephen Hemminger <shemminger@vyatta.com> +Acked-by: Eric Dumazet <eric.dumazet@gmail.com> +Acked-by: Paul Mackerras <paulus@samba.org> +Signed-off-by: David S. Miller <davem@davemloft.net> +--- + drivers/net/ppp_generic.c | 9 +++++++-- + 1 files changed, 7 insertions(+), 2 deletions(-) + +diff --git a/drivers/net/ppp_generic.c b/drivers/net/ppp_generic.c +index 3965997..89294b4 100644 +--- a/drivers/net/ppp_generic.c ++++ b/drivers/net/ppp_generic.c +@@ -1285,6 +1285,11 @@ ppp_push(struct ppp *ppp) + } + + #ifdef CONFIG_PPP_MULTILINK ++static bool mp_protocol_compress __read_mostly = true; ++module_param(mp_protocol_compress, bool, S_IRUGO | S_IWUSR); ++MODULE_PARM_DESC(mp_protocol_compress, ++ "compress protocol id in multilink fragments"); ++ + /* + * Divide a packet to be transmitted into fragments and + * send them out the individual links. +@@ -1347,10 +1352,10 @@ static int ppp_mp_explode(struct ppp *ppp, struct sk_buff *skb) + if (nfree == 0 || nfree < navail / 2) + return 0; /* can't take now, leave it in xmit_pending */ + +- /* Do protocol field compression (XXX this should be optional) */ ++ /* Do protocol field compression */ + p = skb->data; + len = skb->len; +- if (*p == 0) { ++ if (*p == 0 && mp_protocol_compress) { + ++p; + --len; + } +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0016-skfp-testing-the-wrong-variable-in-skfp_driver_init.patch b/recipes/linux/linux-omap-2.6.37/linus/0016-skfp-testing-the-wrong-variable-in-skfp_driver_init.patch new file mode 100644 index 0000000000..55b887a78f --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0016-skfp-testing-the-wrong-variable-in-skfp_driver_init.patch @@ -0,0 +1,31 @@ +From 4a5fc4e179d79c79ad87bfc12a2d7e9b2371e40c Mon Sep 17 00:00:00 2001 +From: Dan Carpenter <error27@gmail.com> +Date: Thu, 23 Dec 2010 19:17:34 +0000 +Subject: [PATCH 16/66] skfp: testing the wrong variable in skfp_driver_init() + +The intent here was to test if the allocation failed but we tested +"SharedMemSize" instead of "SharedMemAddr" by mistake. + +Signed-off-by: Dan Carpenter <error27@gmail.com> +Reviewed-by: Jiri Pirko <jpirko@redhat.com> +Signed-off-by: David S. Miller <davem@davemloft.net> +--- + drivers/net/skfp/skfddi.c | 2 +- + 1 files changed, 1 insertions(+), 1 deletions(-) + +diff --git a/drivers/net/skfp/skfddi.c b/drivers/net/skfp/skfddi.c +index 0a66fed..16c6265 100644 +--- a/drivers/net/skfp/skfddi.c ++++ b/drivers/net/skfp/skfddi.c +@@ -412,7 +412,7 @@ static int skfp_driver_init(struct net_device *dev) + bp->SharedMemAddr = pci_alloc_consistent(&bp->pdev, + bp->SharedMemSize, + &bp->SharedMemDMA); +- if (!bp->SharedMemSize) { ++ if (!bp->SharedMemAddr) { + printk("could not allocate mem for "); + printk("hardware module: %ld byte\n", + bp->SharedMemSize); +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0017-ASoC-codecs-Add-missing-control_type-initialization.patch b/recipes/linux/linux-omap-2.6.37/linus/0017-ASoC-codecs-Add-missing-control_type-initialization.patch new file mode 100644 index 0000000000..59adbc736a --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0017-ASoC-codecs-Add-missing-control_type-initialization.patch @@ -0,0 +1,84 @@ +From 7f984b55acb6530bf854bfcac13104228f3336c1 Mon Sep 17 00:00:00 2001 +From: Lars-Peter Clausen <lars@metafoo.de> +Date: Tue, 28 Dec 2010 21:08:57 +0100 +Subject: [PATCH 17/66] ASoC: codecs: Add missing control_type initialization + +Some codec drivers do not initialize the control_type field in their private +device struct, but still use it when calling snd_soc_codec_set_cache_io. +This patch fixes the issue by properly initializing it in the drivers probe +functions. + +Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> +Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> +Cc: stable@kernel.org (for 2.6.37 only) +--- + sound/soc/codecs/wm8940.c | 1 + + sound/soc/codecs/wm8955.c | 1 + + sound/soc/codecs/wm8960.c | 1 + + sound/soc/codecs/wm8971.c | 1 + + sound/soc/codecs/wm9081.c | 1 + + 5 files changed, 5 insertions(+), 0 deletions(-) + +diff --git a/sound/soc/codecs/wm8940.c b/sound/soc/codecs/wm8940.c +index 2cb16f8..23086e2 100644 +--- a/sound/soc/codecs/wm8940.c ++++ b/sound/soc/codecs/wm8940.c +@@ -768,6 +768,7 @@ static __devinit int wm8940_i2c_probe(struct i2c_client *i2c, + + i2c_set_clientdata(i2c, wm8940); + wm8940->control_data = i2c; ++ wm8940->control_type = SND_SOC_I2C; + + ret = snd_soc_register_codec(&i2c->dev, + &soc_codec_dev_wm8940, &wm8940_dai, 1); +diff --git a/sound/soc/codecs/wm8955.c b/sound/soc/codecs/wm8955.c +index 9cbab8e..a2ad91d 100644 +--- a/sound/soc/codecs/wm8955.c ++++ b/sound/soc/codecs/wm8955.c +@@ -1003,6 +1003,7 @@ static __devinit int wm8955_i2c_probe(struct i2c_client *i2c, + return -ENOMEM; + + i2c_set_clientdata(i2c, wm8955); ++ wm8955->control_type = SND_SOC_I2C; + + ret = snd_soc_register_codec(&i2c->dev, + &soc_codec_dev_wm8955, &wm8955_dai, 1); +diff --git a/sound/soc/codecs/wm8960.c b/sound/soc/codecs/wm8960.c +index 21986c4..ff6ff2f 100644 +--- a/sound/soc/codecs/wm8960.c ++++ b/sound/soc/codecs/wm8960.c +@@ -1013,6 +1013,7 @@ static __devinit int wm8960_i2c_probe(struct i2c_client *i2c, + return -ENOMEM; + + i2c_set_clientdata(i2c, wm8960); ++ wm8960->control_type = SND_SOC_I2C; + wm8960->control_data = i2c; + + ret = snd_soc_register_codec(&i2c->dev, +diff --git a/sound/soc/codecs/wm8971.c b/sound/soc/codecs/wm8971.c +index 63f6dbf..9f18db6 100644 +--- a/sound/soc/codecs/wm8971.c ++++ b/sound/soc/codecs/wm8971.c +@@ -718,6 +718,7 @@ static __devinit int wm8971_i2c_probe(struct i2c_client *i2c, + if (wm8971 == NULL) + return -ENOMEM; + ++ wm8971->control_type = SND_SOC_I2C; + i2c_set_clientdata(i2c, wm8971); + + ret = snd_soc_register_codec(&i2c->dev, +diff --git a/sound/soc/codecs/wm9081.c b/sound/soc/codecs/wm9081.c +index ecc7c37..a486670 100644 +--- a/sound/soc/codecs/wm9081.c ++++ b/sound/soc/codecs/wm9081.c +@@ -1335,6 +1335,7 @@ static __devinit int wm9081_i2c_probe(struct i2c_client *i2c, + return -ENOMEM; + + i2c_set_clientdata(i2c, wm9081); ++ wm9081->control_type = SND_SOC_I2C; + wm9081->control_data = i2c; + + ret = snd_soc_register_codec(&i2c->dev, +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0018-ASoC-codecs-max98088-Fix-register-cache-incoherency.patch b/recipes/linux/linux-omap-2.6.37/linus/0018-ASoC-codecs-max98088-Fix-register-cache-incoherency.patch new file mode 100644 index 0000000000..5080cc6737 --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0018-ASoC-codecs-max98088-Fix-register-cache-incoherency.patch @@ -0,0 +1,72 @@ +From d24eb0db9c8a7ceecae860bdc636ed1e8a86943a Mon Sep 17 00:00:00 2001 +From: Lars-Peter Clausen <lars@metafoo.de> +Date: Tue, 28 Dec 2010 21:37:56 +0100 +Subject: [PATCH 18/66] ASoC: codecs: max98088: Fix register cache incoherency + +The multi-component patch(commit f0fba2ad1) moved the allocation of the +register cache from the driver to the ASoC core. Most drivers where adjusted to +this, but the max98088 driver still uses its own register cache for its +private functions, while functions from the ASoC core use the generic cache. +Thus we end up with two from each other incoherent caches, which can lead to +undefined behaviour. +This patch fixes the issue by changing the max98088 driver to use the +generic register cache in its private functions. + +Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> +Cc: Peter Hsiang <Peter.Hsiang@maxim-ic.com> +Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> +Cc: stable@kernel.org (for 2.6.37 only) +--- + sound/soc/codecs/max98088.c | 10 ++++------ + 1 files changed, 4 insertions(+), 6 deletions(-) + +diff --git a/sound/soc/codecs/max98088.c b/sound/soc/codecs/max98088.c +index d63e287..6447dbb 100644 +--- a/sound/soc/codecs/max98088.c ++++ b/sound/soc/codecs/max98088.c +@@ -40,7 +40,6 @@ struct max98088_cdata { + }; + + struct max98088_priv { +- u8 reg_cache[M98088_REG_CNT]; + enum max98088_type devtype; + void *control_data; + struct max98088_pdata *pdata; +@@ -1588,7 +1587,7 @@ static int max98088_dai2_set_fmt(struct snd_soc_dai *codec_dai, + + static void max98088_sync_cache(struct snd_soc_codec *codec) + { +- struct max98088_priv *max98088 = snd_soc_codec_get_drvdata(codec); ++ u16 *reg_cache = codec->reg_cache; + int i; + + if (!codec->cache_sync) +@@ -1599,14 +1598,14 @@ static void max98088_sync_cache(struct snd_soc_codec *codec) + /* write back cached values if they're writeable and + * different from the hardware default. + */ +- for (i = 1; i < ARRAY_SIZE(max98088->reg_cache); i++) { ++ for (i = 1; i < codec->driver->reg_cache_size; i++) { + if (!max98088_access[i].writable) + continue; + +- if (max98088->reg_cache[i] == max98088_reg[i]) ++ if (reg_cache[i] == max98088_reg[i]) + continue; + +- snd_soc_write(codec, i, max98088->reg_cache[i]); ++ snd_soc_write(codec, i, reg_cache[i]); + } + + codec->cache_sync = 0; +@@ -1951,7 +1950,6 @@ static int max98088_probe(struct snd_soc_codec *codec) + int ret = 0; + + codec->cache_sync = 1; +- memcpy(codec->reg_cache, max98088_reg, sizeof(max98088_reg)); + + ret = snd_soc_codec_set_cache_io(codec, 8, 8, SND_SOC_I2C); + if (ret != 0) { +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0019-ASoC-codecs-wm8523-Fix-register-cache-incoherency.patch b/recipes/linux/linux-omap-2.6.37/linus/0019-ASoC-codecs-wm8523-Fix-register-cache-incoherency.patch new file mode 100644 index 0000000000..6d40a00458 --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0019-ASoC-codecs-wm8523-Fix-register-cache-incoherency.patch @@ -0,0 +1,74 @@ +From beebca312009e9567d5e0229ea6b82bdf9a864cf Mon Sep 17 00:00:00 2001 +From: Lars-Peter Clausen <lars@metafoo.de> +Date: Tue, 28 Dec 2010 21:37:57 +0100 +Subject: [PATCH 19/66] ASoC: codecs: wm8523: Fix register cache incoherency + +The multi-component patch(commit f0fba2ad1) moved the allocation of the +register cache from the driver to the ASoC core. Most drivers where adjusted to +this, but the wm8523 driver still uses its own register cache for its +private functions, while functions from the ASoC core use the generic cache. +Thus we end up with two from each other incoherent caches, which can lead to +undefined behaviour. +This patch fixes the issue by changing the wm8523 driver to use the +generic register cache in its private functions. + +Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> +Cc: Ian Lartey <ian@opensource.wolfsonmicro.com> +Cc: Dimitris Papastamos <dp@opensource.wolfsonmicro.com> +Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> +Cc: stable@kernel.org (for 2.6.37 only) +--- + sound/soc/codecs/wm8523.c | 9 +++++---- + 1 files changed, 5 insertions(+), 4 deletions(-) + +diff --git a/sound/soc/codecs/wm8523.c b/sound/soc/codecs/wm8523.c +index 9a433a5..deca79e 100644 +--- a/sound/soc/codecs/wm8523.c ++++ b/sound/soc/codecs/wm8523.c +@@ -41,7 +41,6 @@ static const char *wm8523_supply_names[WM8523_NUM_SUPPLIES] = { + /* codec private data */ + struct wm8523_priv { + enum snd_soc_control_type control_type; +- u16 reg_cache[WM8523_REGISTER_COUNT]; + struct regulator_bulk_data supplies[WM8523_NUM_SUPPLIES]; + unsigned int sysclk; + unsigned int rate_constraint_list[WM8523_NUM_RATES]; +@@ -314,6 +313,7 @@ static int wm8523_set_bias_level(struct snd_soc_codec *codec, + enum snd_soc_bias_level level) + { + struct wm8523_priv *wm8523 = snd_soc_codec_get_drvdata(codec); ++ u16 *reg_cache = codec->reg_cache; + int ret, i; + + switch (level) { +@@ -344,7 +344,7 @@ static int wm8523_set_bias_level(struct snd_soc_codec *codec, + /* Sync back default/cached values */ + for (i = WM8523_AIF_CTRL1; + i < WM8523_MAX_REGISTER; i++) +- snd_soc_write(codec, i, wm8523->reg_cache[i]); ++ snd_soc_write(codec, i, reg_cache[i]); + + + msleep(100); +@@ -414,6 +414,7 @@ static int wm8523_resume(struct snd_soc_codec *codec) + static int wm8523_probe(struct snd_soc_codec *codec) + { + struct wm8523_priv *wm8523 = snd_soc_codec_get_drvdata(codec); ++ u16 *reg_cache = codec->reg_cache; + int ret, i; + + codec->hw_write = (hw_write_t)i2c_master_send; +@@ -470,8 +471,8 @@ static int wm8523_probe(struct snd_soc_codec *codec) + } + + /* Change some default settings - latch VU and enable ZC */ +- wm8523->reg_cache[WM8523_DAC_GAINR] |= WM8523_DACR_VU; +- wm8523->reg_cache[WM8523_DAC_CTRL3] |= WM8523_ZC; ++ reg_cache[WM8523_DAC_GAINR] |= WM8523_DACR_VU; ++ reg_cache[WM8523_DAC_CTRL3] |= WM8523_ZC; + + wm8523_set_bias_level(codec, SND_SOC_BIAS_STANDBY); + +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0020-ASoC-codecs-wm8741-Fix-register-cache-incoherency.patch b/recipes/linux/linux-omap-2.6.37/linus/0020-ASoC-codecs-wm8741-Fix-register-cache-incoherency.patch new file mode 100644 index 0000000000..160440c69a --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0020-ASoC-codecs-wm8741-Fix-register-cache-incoherency.patch @@ -0,0 +1,61 @@ +From 52ca353bc8597dcc1d6d7abc03eecc1b452d79c9 Mon Sep 17 00:00:00 2001 +From: Lars-Peter Clausen <lars@metafoo.de> +Date: Tue, 28 Dec 2010 21:37:58 +0100 +Subject: [PATCH 20/66] ASoC: codecs: wm8741: Fix register cache incoherency + +The multi-component patch(commit f0fba2ad1) moved the allocation of the +register cache from the driver to the ASoC core. Most drivers where adjusted to +this, but the wm8741 driver still uses its own register cache for its +private functions, while functions from the ASoC core use the generic cache. +Thus we end up with two from each other incoherent caches, which can lead to +undefined behaviour. +This patch fixes the issue by changing the wm8741 driver to use the +generic register cache in its private functions. + +Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> +Cc: Ian Lartey <ian@opensource.wolfsonmicro.com> +Cc: Dimitris Papastamos <dp@opensource.wolfsonmicro.com> +Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> +Cc: stable@kernel.org (for 2.6.37 only) +--- + sound/soc/codecs/wm8741.c | 10 +++++----- + 1 files changed, 5 insertions(+), 5 deletions(-) + +diff --git a/sound/soc/codecs/wm8741.c b/sound/soc/codecs/wm8741.c +index 90e31e9..aea60ef 100644 +--- a/sound/soc/codecs/wm8741.c ++++ b/sound/soc/codecs/wm8741.c +@@ -41,7 +41,6 @@ static const char *wm8741_supply_names[WM8741_NUM_SUPPLIES] = { + /* codec private data */ + struct wm8741_priv { + enum snd_soc_control_type control_type; +- u16 reg_cache[WM8741_REGISTER_COUNT]; + struct regulator_bulk_data supplies[WM8741_NUM_SUPPLIES]; + unsigned int sysclk; + struct snd_pcm_hw_constraint_list *sysclk_constraints; +@@ -422,6 +421,7 @@ static int wm8741_resume(struct snd_soc_codec *codec) + static int wm8741_probe(struct snd_soc_codec *codec) + { + struct wm8741_priv *wm8741 = snd_soc_codec_get_drvdata(codec); ++ u16 *reg_cache = codec->reg_cache; + int ret = 0; + + ret = snd_soc_codec_set_cache_io(codec, 7, 9, wm8741->control_type); +@@ -437,10 +437,10 @@ static int wm8741_probe(struct snd_soc_codec *codec) + } + + /* Change some default settings - latch VU */ +- wm8741->reg_cache[WM8741_DACLLSB_ATTENUATION] |= WM8741_UPDATELL; +- wm8741->reg_cache[WM8741_DACLMSB_ATTENUATION] |= WM8741_UPDATELM; +- wm8741->reg_cache[WM8741_DACRLSB_ATTENUATION] |= WM8741_UPDATERL; +- wm8741->reg_cache[WM8741_DACRLSB_ATTENUATION] |= WM8741_UPDATERM; ++ reg_cache[WM8741_DACLLSB_ATTENUATION] |= WM8741_UPDATELL; ++ reg_cache[WM8741_DACLMSB_ATTENUATION] |= WM8741_UPDATELM; ++ reg_cache[WM8741_DACRLSB_ATTENUATION] |= WM8741_UPDATERL; ++ reg_cache[WM8741_DACRLSB_ATTENUATION] |= WM8741_UPDATERM; + + snd_soc_add_controls(codec, wm8741_snd_controls, + ARRAY_SIZE(wm8741_snd_controls)); +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0021-ASoC-codecs-wm8904-Fix-register-cache-incoherency.patch b/recipes/linux/linux-omap-2.6.37/linus/0021-ASoC-codecs-wm8904-Fix-register-cache-incoherency.patch new file mode 100644 index 0000000000..932f529da5 --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0021-ASoC-codecs-wm8904-Fix-register-cache-incoherency.patch @@ -0,0 +1,131 @@ +From f578a188e8b21be623b48bb0eb3a92174c2e5b82 Mon Sep 17 00:00:00 2001 +From: Lars-Peter Clausen <lars@metafoo.de> +Date: Tue, 28 Dec 2010 21:37:59 +0100 +Subject: [PATCH 21/66] ASoC: codecs: wm8904: Fix register cache incoherency + +The multi-component patch(commit f0fba2ad1) moved the allocation of the +register cache from the driver to the ASoC core. Most drivers where adjusted to +this, but the wm8904 driver still uses its own register cache for its +private functions, while functions from the ASoC core use the generic cache. +Thus we end up with two from each other incoherent caches, which can lead to +undefined behaviour. +This patch fixes the issue by changing the wm8904 driver to use the +generic register cache in its private functions. + +Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> +Cc: Ian Lartey <ian@opensource.wolfsonmicro.com> +Cc: Dimitris Papastamos <dp@opensource.wolfsonmicro.com> +Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> +Cc: stable@kernel.org (for 2.6.37 only) +--- + sound/soc/codecs/wm8904.c | 37 ++++++++++++++++++------------------- + 1 files changed, 18 insertions(+), 19 deletions(-) + +diff --git a/sound/soc/codecs/wm8904.c b/sound/soc/codecs/wm8904.c +index 9001cc4..1ec12ef 100644 +--- a/sound/soc/codecs/wm8904.c ++++ b/sound/soc/codecs/wm8904.c +@@ -50,8 +50,6 @@ static const char *wm8904_supply_names[WM8904_NUM_SUPPLIES] = { + /* codec private data */ + struct wm8904_priv { + +- u16 reg_cache[WM8904_MAX_REGISTER + 1]; +- + enum wm8904_type devtype; + void *control_data; + +@@ -2094,7 +2092,7 @@ static int wm8904_digital_mute(struct snd_soc_dai *codec_dai, int mute) + + static void wm8904_sync_cache(struct snd_soc_codec *codec) + { +- struct wm8904_priv *wm8904 = snd_soc_codec_get_drvdata(codec); ++ u16 *reg_cache = codec->reg_cache; + int i; + + if (!codec->cache_sync) +@@ -2105,14 +2103,14 @@ static void wm8904_sync_cache(struct snd_soc_codec *codec) + /* Sync back cached values if they're different from the + * hardware default. + */ +- for (i = 1; i < ARRAY_SIZE(wm8904->reg_cache); i++) { ++ for (i = 1; i < codec->driver->reg_cache_size; i++) { + if (!wm8904_access[i].writable) + continue; + +- if (wm8904->reg_cache[i] == wm8904_reg[i]) ++ if (reg_cache[i] == wm8904_reg[i]) + continue; + +- snd_soc_write(codec, i, wm8904->reg_cache[i]); ++ snd_soc_write(codec, i, reg_cache[i]); + } + + codec->cache_sync = 0; +@@ -2371,6 +2369,7 @@ static int wm8904_probe(struct snd_soc_codec *codec) + { + struct wm8904_priv *wm8904 = snd_soc_codec_get_drvdata(codec); + struct wm8904_pdata *pdata = wm8904->pdata; ++ u16 *reg_cache = codec->reg_cache; + int ret, i; + + codec->cache_sync = 1; +@@ -2437,19 +2436,19 @@ static int wm8904_probe(struct snd_soc_codec *codec) + } + + /* Change some default settings - latch VU and enable ZC */ +- wm8904->reg_cache[WM8904_ADC_DIGITAL_VOLUME_LEFT] |= WM8904_ADC_VU; +- wm8904->reg_cache[WM8904_ADC_DIGITAL_VOLUME_RIGHT] |= WM8904_ADC_VU; +- wm8904->reg_cache[WM8904_DAC_DIGITAL_VOLUME_LEFT] |= WM8904_DAC_VU; +- wm8904->reg_cache[WM8904_DAC_DIGITAL_VOLUME_RIGHT] |= WM8904_DAC_VU; +- wm8904->reg_cache[WM8904_ANALOGUE_OUT1_LEFT] |= WM8904_HPOUT_VU | ++ reg_cache[WM8904_ADC_DIGITAL_VOLUME_LEFT] |= WM8904_ADC_VU; ++ reg_cache[WM8904_ADC_DIGITAL_VOLUME_RIGHT] |= WM8904_ADC_VU; ++ reg_cache[WM8904_DAC_DIGITAL_VOLUME_LEFT] |= WM8904_DAC_VU; ++ reg_cache[WM8904_DAC_DIGITAL_VOLUME_RIGHT] |= WM8904_DAC_VU; ++ reg_cache[WM8904_ANALOGUE_OUT1_LEFT] |= WM8904_HPOUT_VU | + WM8904_HPOUTLZC; +- wm8904->reg_cache[WM8904_ANALOGUE_OUT1_RIGHT] |= WM8904_HPOUT_VU | ++ reg_cache[WM8904_ANALOGUE_OUT1_RIGHT] |= WM8904_HPOUT_VU | + WM8904_HPOUTRZC; +- wm8904->reg_cache[WM8904_ANALOGUE_OUT2_LEFT] |= WM8904_LINEOUT_VU | ++ reg_cache[WM8904_ANALOGUE_OUT2_LEFT] |= WM8904_LINEOUT_VU | + WM8904_LINEOUTLZC; +- wm8904->reg_cache[WM8904_ANALOGUE_OUT2_RIGHT] |= WM8904_LINEOUT_VU | ++ reg_cache[WM8904_ANALOGUE_OUT2_RIGHT] |= WM8904_LINEOUT_VU | + WM8904_LINEOUTRZC; +- wm8904->reg_cache[WM8904_CLOCK_RATES_0] &= ~WM8904_SR_MODE; ++ reg_cache[WM8904_CLOCK_RATES_0] &= ~WM8904_SR_MODE; + + /* Apply configuration from the platform data. */ + if (wm8904->pdata) { +@@ -2457,23 +2456,23 @@ static int wm8904_probe(struct snd_soc_codec *codec) + if (!pdata->gpio_cfg[i]) + continue; + +- wm8904->reg_cache[WM8904_GPIO_CONTROL_1 + i] ++ reg_cache[WM8904_GPIO_CONTROL_1 + i] + = pdata->gpio_cfg[i] & 0xffff; + } + + /* Zero is the default value for these anyway */ + for (i = 0; i < WM8904_MIC_REGS; i++) +- wm8904->reg_cache[WM8904_MIC_BIAS_CONTROL_0 + i] ++ reg_cache[WM8904_MIC_BIAS_CONTROL_0 + i] + = pdata->mic_cfg[i]; + } + + /* Set Class W by default - this will be managed by the Class + * G widget at runtime where bypass paths are available. + */ +- wm8904->reg_cache[WM8904_CLASS_W_0] |= WM8904_CP_DYN_PWR; ++ reg_cache[WM8904_CLASS_W_0] |= WM8904_CP_DYN_PWR; + + /* Use normal bias source */ +- wm8904->reg_cache[WM8904_BIAS_CONTROL_0] &= ~WM8904_POBCTRL; ++ reg_cache[WM8904_BIAS_CONTROL_0] &= ~WM8904_POBCTRL; + + wm8904_set_bias_level(codec, SND_SOC_BIAS_STANDBY); + +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0022-ASoC-codecs-wm8955-Fix-register-cache-incoherency.patch b/recipes/linux/linux-omap-2.6.37/linus/0022-ASoC-codecs-wm8955-Fix-register-cache-incoherency.patch new file mode 100644 index 0000000000..e3b620f392 --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0022-ASoC-codecs-wm8955-Fix-register-cache-incoherency.patch @@ -0,0 +1,107 @@ +From 715920d04c787ed718327da53cf51689e51ef3ce Mon Sep 17 00:00:00 2001 +From: Lars-Peter Clausen <lars@metafoo.de> +Date: Tue, 28 Dec 2010 21:38:00 +0100 +Subject: [PATCH 22/66] ASoC: codecs: wm8955: Fix register cache incoherency + +The multi-component patch(commit f0fba2ad1) moved the allocation of the +register cache from the driver to the ASoC core. Most drivers where adjusted to +this, but the wm8955 driver still uses its own register cache for its +private functions, while functions from the ASoC core use the generic cache. +Thus we end up with two from each other incoherent caches, which can lead to +undefined behaviour. +This patch fixes the issue by changing the wm8955 driver to use the +generic register cache in its private functions. + +Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> +Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> +Cc: stable@kernel.org (for 2.6.37 only) +--- + sound/soc/codecs/wm8955.c | 30 +++++++++++++++--------------- + 1 files changed, 15 insertions(+), 15 deletions(-) + +diff --git a/sound/soc/codecs/wm8955.c b/sound/soc/codecs/wm8955.c +index a2ad91d..2ac35b0 100644 +--- a/sound/soc/codecs/wm8955.c ++++ b/sound/soc/codecs/wm8955.c +@@ -42,8 +42,6 @@ static const char *wm8955_supply_names[WM8955_NUM_SUPPLIES] = { + struct wm8955_priv { + enum snd_soc_control_type control_type; + +- u16 reg_cache[WM8955_MAX_REGISTER + 1]; +- + unsigned int mclk_rate; + + int deemph; +@@ -768,6 +766,7 @@ static int wm8955_set_bias_level(struct snd_soc_codec *codec, + enum snd_soc_bias_level level) + { + struct wm8955_priv *wm8955 = snd_soc_codec_get_drvdata(codec); ++ u16 *reg_cache = codec->reg_cache; + int ret, i; + + switch (level) { +@@ -800,14 +799,14 @@ static int wm8955_set_bias_level(struct snd_soc_codec *codec, + /* Sync back cached values if they're + * different from the hardware default. + */ +- for (i = 0; i < ARRAY_SIZE(wm8955->reg_cache); i++) { ++ for (i = 0; i < codec->driver->reg_cache_size; i++) { + if (i == WM8955_RESET) + continue; + +- if (wm8955->reg_cache[i] == wm8955_reg[i]) ++ if (reg_cache[i] == wm8955_reg[i]) + continue; + +- snd_soc_write(codec, i, wm8955->reg_cache[i]); ++ snd_soc_write(codec, i, reg_cache[i]); + } + + /* Enable VREF and VMID */ +@@ -902,6 +901,7 @@ static int wm8955_probe(struct snd_soc_codec *codec) + { + struct wm8955_priv *wm8955 = snd_soc_codec_get_drvdata(codec); + struct wm8955_pdata *pdata = dev_get_platdata(codec->dev); ++ u16 *reg_cache = codec->reg_cache; + int ret, i; + + ret = snd_soc_codec_set_cache_io(codec, 7, 9, wm8955->control_type); +@@ -934,25 +934,25 @@ static int wm8955_probe(struct snd_soc_codec *codec) + } + + /* Change some default settings - latch VU and enable ZC */ +- wm8955->reg_cache[WM8955_LEFT_DAC_VOLUME] |= WM8955_LDVU; +- wm8955->reg_cache[WM8955_RIGHT_DAC_VOLUME] |= WM8955_RDVU; +- wm8955->reg_cache[WM8955_LOUT1_VOLUME] |= WM8955_LO1VU | WM8955_LO1ZC; +- wm8955->reg_cache[WM8955_ROUT1_VOLUME] |= WM8955_RO1VU | WM8955_RO1ZC; +- wm8955->reg_cache[WM8955_LOUT2_VOLUME] |= WM8955_LO2VU | WM8955_LO2ZC; +- wm8955->reg_cache[WM8955_ROUT2_VOLUME] |= WM8955_RO2VU | WM8955_RO2ZC; +- wm8955->reg_cache[WM8955_MONOOUT_VOLUME] |= WM8955_MOZC; ++ reg_cache[WM8955_LEFT_DAC_VOLUME] |= WM8955_LDVU; ++ reg_cache[WM8955_RIGHT_DAC_VOLUME] |= WM8955_RDVU; ++ reg_cache[WM8955_LOUT1_VOLUME] |= WM8955_LO1VU | WM8955_LO1ZC; ++ reg_cache[WM8955_ROUT1_VOLUME] |= WM8955_RO1VU | WM8955_RO1ZC; ++ reg_cache[WM8955_LOUT2_VOLUME] |= WM8955_LO2VU | WM8955_LO2ZC; ++ reg_cache[WM8955_ROUT2_VOLUME] |= WM8955_RO2VU | WM8955_RO2ZC; ++ reg_cache[WM8955_MONOOUT_VOLUME] |= WM8955_MOZC; + + /* Also enable adaptive bass boost by default */ +- wm8955->reg_cache[WM8955_BASS_CONTROL] |= WM8955_BB; ++ reg_cache[WM8955_BASS_CONTROL] |= WM8955_BB; + + /* Set platform data values */ + if (pdata) { + if (pdata->out2_speaker) +- wm8955->reg_cache[WM8955_ADDITIONAL_CONTROL_2] ++ reg_cache[WM8955_ADDITIONAL_CONTROL_2] + |= WM8955_ROUT2INV; + + if (pdata->monoin_diff) +- wm8955->reg_cache[WM8955_MONO_OUT_MIX_1] ++ reg_cache[WM8955_MONO_OUT_MIX_1] + |= WM8955_DMEN; + } + +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0023-ASoC-codecs-wm8962-Fix-register-cache-incoherency.patch b/recipes/linux/linux-omap-2.6.37/linus/0023-ASoC-codecs-wm8962-Fix-register-cache-incoherency.patch new file mode 100644 index 0000000000..378668533a --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0023-ASoC-codecs-wm8962-Fix-register-cache-incoherency.patch @@ -0,0 +1,151 @@ +From 7f87e30ef29951f4509a7f86acf00e1ba48af54a Mon Sep 17 00:00:00 2001 +From: Lars-Peter Clausen <lars@metafoo.de> +Date: Tue, 28 Dec 2010 21:38:01 +0100 +Subject: [PATCH 23/66] ASoC: codecs: wm8962: Fix register cache incoherency + +The multi-component patch(commit f0fba2ad1) moved the allocation of the +register cache from the driver to the ASoC core. Most drivers where adjusted to +this, but the wm8962 driver still uses its own register cache for its +private functions, while functions from the ASoC core use the generic cache. +Thus we end up with two from each other incoherent caches, which can lead to +undefined behaviour. +This patch fixes the issue by changing the wm8962 driver to use the +generic register cache in its private functions. + +Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> +Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> +Cc: stable@kernel.org (for 2.6.37 only) +--- + sound/soc/codecs/wm8962.c | 45 ++++++++++++++++++++------------------------- + 1 files changed, 20 insertions(+), 25 deletions(-) + +diff --git a/sound/soc/codecs/wm8962.c b/sound/soc/codecs/wm8962.c +index 1304ca9..7c421cc 100644 +--- a/sound/soc/codecs/wm8962.c ++++ b/sound/soc/codecs/wm8962.c +@@ -52,8 +52,6 @@ static const char *wm8962_supply_names[WM8962_NUM_SUPPLIES] = { + struct wm8962_priv { + struct snd_soc_codec *codec; + +- u16 reg_cache[WM8962_MAX_REGISTER + 1]; +- + int sysclk; + int sysclk_rate; + +@@ -1991,8 +1989,7 @@ static int wm8962_put_hp_sw(struct snd_kcontrol *kcontrol, + struct snd_ctl_elem_value *ucontrol) + { + struct snd_soc_codec *codec = snd_kcontrol_chip(kcontrol); +- struct wm8962_priv *wm8962 = snd_soc_codec_get_drvdata(codec); +- u16 *reg_cache = wm8962->reg_cache; ++ u16 *reg_cache = codec->reg_cache; + int ret; + + /* Apply the update (if any) */ +@@ -2020,8 +2017,7 @@ static int wm8962_put_spk_sw(struct snd_kcontrol *kcontrol, + struct snd_ctl_elem_value *ucontrol) + { + struct snd_soc_codec *codec = snd_kcontrol_chip(kcontrol); +- struct wm8962_priv *wm8962 = snd_soc_codec_get_drvdata(codec); +- u16 *reg_cache = wm8962->reg_cache; ++ u16 *reg_cache = codec->reg_cache; + int ret; + + /* Apply the update (if any) */ +@@ -2329,8 +2325,7 @@ static int out_pga_event(struct snd_soc_dapm_widget *w, + struct snd_kcontrol *kcontrol, int event) + { + struct snd_soc_codec *codec = w->codec; +- struct wm8962_priv *wm8962 = snd_soc_codec_get_drvdata(codec); +- u16 *reg_cache = wm8962->reg_cache; ++ u16 *reg_cache = codec->reg_cache; + int reg; + + switch (w->shift) { +@@ -2719,7 +2714,7 @@ static int wm8962_add_widgets(struct snd_soc_codec *codec) + + static void wm8962_sync_cache(struct snd_soc_codec *codec) + { +- struct wm8962_priv *wm8962 = snd_soc_codec_get_drvdata(codec); ++ u16 *reg_cache = codec->reg_cache; + int i; + + if (!codec->cache_sync) +@@ -2732,13 +2727,13 @@ static void wm8962_sync_cache(struct snd_soc_codec *codec) + /* Sync back cached values if they're different from the + * hardware default. + */ +- for (i = 1; i < ARRAY_SIZE(wm8962->reg_cache); i++) { ++ for (i = 1; i < codec->driver->reg_cache_size; i++) { + if (i == WM8962_SOFTWARE_RESET) + continue; +- if (wm8962->reg_cache[i] == wm8962_reg[i]) ++ if (reg_cache[i] == wm8962_reg[i]) + continue; + +- snd_soc_write(codec, i, wm8962->reg_cache[i]); ++ snd_soc_write(codec, i, reg_cache[i]); + } + + codec->cache_sync = 0; +@@ -3406,12 +3401,11 @@ EXPORT_SYMBOL_GPL(wm8962_mic_detect); + #ifdef CONFIG_PM + static int wm8962_resume(struct snd_soc_codec *codec) + { +- struct wm8962_priv *wm8962 = snd_soc_codec_get_drvdata(codec); + u16 *reg_cache = codec->reg_cache; + int i; + + /* Restore the registers */ +- for (i = 1; i < ARRAY_SIZE(wm8962->reg_cache); i++) { ++ for (i = 1; i < codec->driver->reg_cache_size; i++) { + switch (i) { + case WM8962_SOFTWARE_RESET: + continue; +@@ -3705,6 +3699,7 @@ static int wm8962_probe(struct snd_soc_codec *codec) + struct wm8962_pdata *pdata = dev_get_platdata(codec->dev); + struct i2c_client *i2c = container_of(codec->dev, struct i2c_client, + dev); ++ u16 *reg_cache = codec->reg_cache; + int i, trigger, irq_pol; + + wm8962->codec = codec; +@@ -3804,7 +3799,7 @@ static int wm8962_probe(struct snd_soc_codec *codec) + + /* Put the speakers into mono mode? */ + if (pdata->spk_mono) +- wm8962->reg_cache[WM8962_CLASS_D_CONTROL_2] ++ reg_cache[WM8962_CLASS_D_CONTROL_2] + |= WM8962_SPK_MONO; + + /* Micbias setup, detection enable and detection +@@ -3819,16 +3814,16 @@ static int wm8962_probe(struct snd_soc_codec *codec) + } + + /* Latch volume update bits */ +- wm8962->reg_cache[WM8962_LEFT_INPUT_VOLUME] |= WM8962_IN_VU; +- wm8962->reg_cache[WM8962_RIGHT_INPUT_VOLUME] |= WM8962_IN_VU; +- wm8962->reg_cache[WM8962_LEFT_ADC_VOLUME] |= WM8962_ADC_VU; +- wm8962->reg_cache[WM8962_RIGHT_ADC_VOLUME] |= WM8962_ADC_VU; +- wm8962->reg_cache[WM8962_LEFT_DAC_VOLUME] |= WM8962_DAC_VU; +- wm8962->reg_cache[WM8962_RIGHT_DAC_VOLUME] |= WM8962_DAC_VU; +- wm8962->reg_cache[WM8962_SPKOUTL_VOLUME] |= WM8962_SPKOUT_VU; +- wm8962->reg_cache[WM8962_SPKOUTR_VOLUME] |= WM8962_SPKOUT_VU; +- wm8962->reg_cache[WM8962_HPOUTL_VOLUME] |= WM8962_HPOUT_VU; +- wm8962->reg_cache[WM8962_HPOUTR_VOLUME] |= WM8962_HPOUT_VU; ++ reg_cache[WM8962_LEFT_INPUT_VOLUME] |= WM8962_IN_VU; ++ reg_cache[WM8962_RIGHT_INPUT_VOLUME] |= WM8962_IN_VU; ++ reg_cache[WM8962_LEFT_ADC_VOLUME] |= WM8962_ADC_VU; ++ reg_cache[WM8962_RIGHT_ADC_VOLUME] |= WM8962_ADC_VU; ++ reg_cache[WM8962_LEFT_DAC_VOLUME] |= WM8962_DAC_VU; ++ reg_cache[WM8962_RIGHT_DAC_VOLUME] |= WM8962_DAC_VU; ++ reg_cache[WM8962_SPKOUTL_VOLUME] |= WM8962_SPKOUT_VU; ++ reg_cache[WM8962_SPKOUTR_VOLUME] |= WM8962_SPKOUT_VU; ++ reg_cache[WM8962_HPOUTL_VOLUME] |= WM8962_HPOUT_VU; ++ reg_cache[WM8962_HPOUTR_VOLUME] |= WM8962_HPOUT_VU; + + wm8962_add_widgets(codec); + +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0024-ASoC-codecs-wm9090-Fix-register-cache-incoherency.patch b/recipes/linux/linux-omap-2.6.37/linus/0024-ASoC-codecs-wm9090-Fix-register-cache-incoherency.patch new file mode 100644 index 0000000000..c107a1dd5f --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0024-ASoC-codecs-wm9090-Fix-register-cache-incoherency.patch @@ -0,0 +1,75 @@ +From da280f51d0b341282b4181eb3235f774b0446584 Mon Sep 17 00:00:00 2001 +From: Lars-Peter Clausen <lars@metafoo.de> +Date: Tue, 28 Dec 2010 21:38:02 +0100 +Subject: [PATCH 24/66] ASoC: codecs: wm9090: Fix register cache incoherency + +The multi-component patch(commit f0fba2ad1) moved the allocation of the +register cache from the driver to the ASoC core. Most drivers where adjusted to +this, but the wm9090 driver still uses its own register cache for its +private functions, while functions from the ASoC core use the generic cache. +Thus we end up with two from each other incoherent caches, which can lead to +undefined behaviour. +This patch fixes the issue by changing the wm9090 driver to use the +generic register cache in its private functions. + +Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> +Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> +Cc: stable@kernel.org (for 2.6.37 only) +--- + sound/soc/codecs/wm9090.c | 18 +++++++++--------- + 1 files changed, 9 insertions(+), 9 deletions(-) + +diff --git a/sound/soc/codecs/wm9090.c b/sound/soc/codecs/wm9090.c +index 99c046b..6e5f64f 100644 +--- a/sound/soc/codecs/wm9090.c ++++ b/sound/soc/codecs/wm9090.c +@@ -141,7 +141,6 @@ static const u16 wm9090_reg_defaults[] = { + /* This struct is used to save the context */ + struct wm9090_priv { + struct mutex mutex; +- u16 reg_cache[WM9090_MAX_REGISTER + 1]; + struct wm9090_platform_data pdata; + void *control_data; + }; +@@ -552,6 +551,7 @@ static int wm9090_set_bias_level(struct snd_soc_codec *codec, + static int wm9090_probe(struct snd_soc_codec *codec) + { + struct wm9090_priv *wm9090 = snd_soc_codec_get_drvdata(codec); ++ u16 *reg_cache = codec->reg_cache; + int ret; + + codec->control_data = wm9090->control_data; +@@ -576,22 +576,22 @@ static int wm9090_probe(struct snd_soc_codec *codec) + /* Configure some defaults; they will be written out when we + * bring the bias up. + */ +- wm9090->reg_cache[WM9090_IN1_LINE_INPUT_A_VOLUME] |= WM9090_IN1_VU ++ reg_cache[WM9090_IN1_LINE_INPUT_A_VOLUME] |= WM9090_IN1_VU + | WM9090_IN1A_ZC; +- wm9090->reg_cache[WM9090_IN1_LINE_INPUT_B_VOLUME] |= WM9090_IN1_VU ++ reg_cache[WM9090_IN1_LINE_INPUT_B_VOLUME] |= WM9090_IN1_VU + | WM9090_IN1B_ZC; +- wm9090->reg_cache[WM9090_IN2_LINE_INPUT_A_VOLUME] |= WM9090_IN2_VU ++ reg_cache[WM9090_IN2_LINE_INPUT_A_VOLUME] |= WM9090_IN2_VU + | WM9090_IN2A_ZC; +- wm9090->reg_cache[WM9090_IN2_LINE_INPUT_B_VOLUME] |= WM9090_IN2_VU ++ reg_cache[WM9090_IN2_LINE_INPUT_B_VOLUME] |= WM9090_IN2_VU + | WM9090_IN2B_ZC; +- wm9090->reg_cache[WM9090_SPEAKER_VOLUME_LEFT] |= ++ reg_cache[WM9090_SPEAKER_VOLUME_LEFT] |= + WM9090_SPKOUT_VU | WM9090_SPKOUTL_ZC; +- wm9090->reg_cache[WM9090_LEFT_OUTPUT_VOLUME] |= ++ reg_cache[WM9090_LEFT_OUTPUT_VOLUME] |= + WM9090_HPOUT1_VU | WM9090_HPOUT1L_ZC; +- wm9090->reg_cache[WM9090_RIGHT_OUTPUT_VOLUME] |= ++ reg_cache[WM9090_RIGHT_OUTPUT_VOLUME] |= + WM9090_HPOUT1_VU | WM9090_HPOUT1R_ZC; + +- wm9090->reg_cache[WM9090_CLOCKING_1] |= WM9090_TOCLK_ENA; ++ reg_cache[WM9090_CLOCKING_1] |= WM9090_TOCLK_ENA; + + wm9090_set_bias_level(codec, SND_SOC_BIAS_STANDBY); + +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0025-ASoC-codecs-wm8753-Fix-register-cache-incoherency.patch b/recipes/linux/linux-omap-2.6.37/linus/0025-ASoC-codecs-wm8753-Fix-register-cache-incoherency.patch new file mode 100644 index 0000000000..bb8ca72cea --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0025-ASoC-codecs-wm8753-Fix-register-cache-incoherency.patch @@ -0,0 +1,514 @@ +From 776065e36de1d5eb9e33ff908352fef4050ab38d Mon Sep 17 00:00:00 2001 +From: Lars-Peter Clausen <lars@metafoo.de> +Date: Tue, 28 Dec 2010 21:38:03 +0100 +Subject: [PATCH 25/66] ASoC: codecs: wm8753: Fix register cache incoherency + +The multi-component patch(commit f0fba2ad1) moved the allocation of the +register cache from the driver to the ASoC core. Most drivers where adjusted to +this, but the wm8753 driver still uses its own register cache for its +private functions, while functions from the ASoC core use the generic cache. +Furthermore the generic cache uses zero-based numbering while the wm8753 cache +uses one-based numbering. +Thus we end up with two from each other incoherent caches, which leads to undefined +behaviour and crashes. +This patch fixes the issue by changing the wm8753 driver to use the generic +register cache in its private functions. + +Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> +Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> +--- + sound/soc/codecs/wm8753.c | 226 +++++++++++++++++---------------------------- + 1 files changed, 83 insertions(+), 143 deletions(-) + +diff --git a/sound/soc/codecs/wm8753.c b/sound/soc/codecs/wm8753.c +index 8f679a1..87caae5 100644 +--- a/sound/soc/codecs/wm8753.c ++++ b/sound/soc/codecs/wm8753.c +@@ -65,22 +65,22 @@ static void wm8753_set_dai_mode(struct snd_soc_codec *codec, + * are using 2 wire for device control, so we cache them instead. + */ + static const u16 wm8753_reg[] = { +- 0x0008, 0x0000, 0x000a, 0x000a, +- 0x0033, 0x0000, 0x0007, 0x00ff, +- 0x00ff, 0x000f, 0x000f, 0x007b, +- 0x0000, 0x0032, 0x0000, 0x00c3, +- 0x00c3, 0x00c0, 0x0000, 0x0000, ++ 0x0000, 0x0008, 0x0000, 0x000a, ++ 0x000a, 0x0033, 0x0000, 0x0007, ++ 0x00ff, 0x00ff, 0x000f, 0x000f, ++ 0x007b, 0x0000, 0x0032, 0x0000, ++ 0x00c3, 0x00c3, 0x00c0, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, +- 0x0000, 0x0000, 0x0000, 0x0055, +- 0x0005, 0x0050, 0x0055, 0x0050, +- 0x0055, 0x0050, 0x0055, 0x0079, +- 0x0079, 0x0079, 0x0079, 0x0079, + 0x0000, 0x0000, 0x0000, 0x0000, +- 0x0097, 0x0097, 0x0000, 0x0004, +- 0x0000, 0x0083, 0x0024, 0x01ba, +- 0x0000, 0x0083, 0x0024, 0x01ba, +- 0x0000, 0x0000, 0x0000 ++ 0x0055, 0x0005, 0x0050, 0x0055, ++ 0x0050, 0x0055, 0x0050, 0x0055, ++ 0x0079, 0x0079, 0x0079, 0x0079, ++ 0x0079, 0x0000, 0x0000, 0x0000, ++ 0x0000, 0x0097, 0x0097, 0x0000, ++ 0x0004, 0x0000, 0x0083, 0x0024, ++ 0x01ba, 0x0000, 0x0083, 0x0024, ++ 0x01ba, 0x0000, 0x0000, 0x0000 + }; + + /* codec private data */ +@@ -88,57 +88,10 @@ struct wm8753_priv { + enum snd_soc_control_type control_type; + unsigned int sysclk; + unsigned int pcmclk; +- u16 reg_cache[ARRAY_SIZE(wm8753_reg)]; + int dai_func; + }; + +-/* +- * read wm8753 register cache +- */ +-static inline unsigned int wm8753_read_reg_cache(struct snd_soc_codec *codec, +- unsigned int reg) +-{ +- u16 *cache = codec->reg_cache; +- if (reg < 1 || reg >= (ARRAY_SIZE(wm8753_reg) + 1)) +- return -1; +- return cache[reg - 1]; +-} +- +-/* +- * write wm8753 register cache +- */ +-static inline void wm8753_write_reg_cache(struct snd_soc_codec *codec, +- unsigned int reg, unsigned int value) +-{ +- u16 *cache = codec->reg_cache; +- if (reg < 1 || reg >= (ARRAY_SIZE(wm8753_reg) + 1)) +- return; +- cache[reg - 1] = value; +-} +- +-/* +- * write to the WM8753 register space +- */ +-static int wm8753_write(struct snd_soc_codec *codec, unsigned int reg, +- unsigned int value) +-{ +- u8 data[2]; +- +- /* data is +- * D15..D9 WM8753 register offset +- * D8...D0 register data +- */ +- data[0] = (reg << 1) | ((value >> 8) & 0x0001); +- data[1] = value & 0x00ff; +- +- wm8753_write_reg_cache(codec, reg, value); +- if (codec->hw_write(codec->control_data, data, 2) == 2) +- return 0; +- else +- return -EIO; +-} +- +-#define wm8753_reset(c) wm8753_write(c, WM8753_RESET, 0) ++#define wm8753_reset(c) snd_soc_write(c, WM8753_RESET, 0) + + /* + * WM8753 Controls +@@ -218,7 +171,7 @@ static int wm8753_get_dai(struct snd_kcontrol *kcontrol, + struct snd_ctl_elem_value *ucontrol) + { + struct snd_soc_codec *codec = snd_kcontrol_chip(kcontrol); +- int mode = wm8753_read_reg_cache(codec, WM8753_IOCTL); ++ int mode = snd_soc_read(codec, WM8753_IOCTL); + + ucontrol->value.integer.value[0] = (mode & 0xc) >> 2; + return 0; +@@ -228,7 +181,7 @@ static int wm8753_set_dai(struct snd_kcontrol *kcontrol, + struct snd_ctl_elem_value *ucontrol) + { + struct snd_soc_codec *codec = snd_kcontrol_chip(kcontrol); +- int mode = wm8753_read_reg_cache(codec, WM8753_IOCTL); ++ int mode = snd_soc_read(codec, WM8753_IOCTL); + struct wm8753_priv *wm8753 = snd_soc_codec_get_drvdata(codec); + + if (((mode & 0xc) >> 2) == ucontrol->value.integer.value[0]) +@@ -738,17 +691,17 @@ static int wm8753_set_dai_pll(struct snd_soc_dai *codec_dai, int pll_id, + if (pll_id == WM8753_PLL1) { + offset = 0; + enable = 0x10; +- reg = wm8753_read_reg_cache(codec, WM8753_CLOCK) & 0xffef; ++ reg = snd_soc_read(codec, WM8753_CLOCK) & 0xffef; + } else { + offset = 4; + enable = 0x8; +- reg = wm8753_read_reg_cache(codec, WM8753_CLOCK) & 0xfff7; ++ reg = snd_soc_read(codec, WM8753_CLOCK) & 0xfff7; + } + + if (!freq_in || !freq_out) { + /* disable PLL */ +- wm8753_write(codec, WM8753_PLL1CTL1 + offset, 0x0026); +- wm8753_write(codec, WM8753_CLOCK, reg); ++ snd_soc_write(codec, WM8753_PLL1CTL1 + offset, 0x0026); ++ snd_soc_write(codec, WM8753_CLOCK, reg); + return 0; + } else { + u16 value = 0; +@@ -759,20 +712,20 @@ static int wm8753_set_dai_pll(struct snd_soc_dai *codec_dai, int pll_id, + /* set up N and K PLL divisor ratios */ + /* bits 8:5 = PLL_N, bits 3:0 = PLL_K[21:18] */ + value = (pll_div.n << 5) + ((pll_div.k & 0x3c0000) >> 18); +- wm8753_write(codec, WM8753_PLL1CTL2 + offset, value); ++ snd_soc_write(codec, WM8753_PLL1CTL2 + offset, value); + + /* bits 8:0 = PLL_K[17:9] */ + value = (pll_div.k & 0x03fe00) >> 9; +- wm8753_write(codec, WM8753_PLL1CTL3 + offset, value); ++ snd_soc_write(codec, WM8753_PLL1CTL3 + offset, value); + + /* bits 8:0 = PLL_K[8:0] */ + value = pll_div.k & 0x0001ff; +- wm8753_write(codec, WM8753_PLL1CTL4 + offset, value); ++ snd_soc_write(codec, WM8753_PLL1CTL4 + offset, value); + + /* set PLL as input and enable */ +- wm8753_write(codec, WM8753_PLL1CTL1 + offset, 0x0027 | ++ snd_soc_write(codec, WM8753_PLL1CTL1 + offset, 0x0027 | + (pll_div.div2 << 3)); +- wm8753_write(codec, WM8753_CLOCK, reg | enable); ++ snd_soc_write(codec, WM8753_CLOCK, reg | enable); + } + return 0; + } +@@ -879,7 +832,7 @@ static int wm8753_vdac_adc_set_dai_fmt(struct snd_soc_dai *codec_dai, + unsigned int fmt) + { + struct snd_soc_codec *codec = codec_dai->codec; +- u16 voice = wm8753_read_reg_cache(codec, WM8753_PCM) & 0x01ec; ++ u16 voice = snd_soc_read(codec, WM8753_PCM) & 0x01ec; + + /* interface format */ + switch (fmt & SND_SOC_DAIFMT_FORMAT_MASK) { +@@ -901,7 +854,7 @@ static int wm8753_vdac_adc_set_dai_fmt(struct snd_soc_dai *codec_dai, + return -EINVAL; + } + +- wm8753_write(codec, WM8753_PCM, voice); ++ snd_soc_write(codec, WM8753_PCM, voice); + return 0; + } + +@@ -922,8 +875,8 @@ static int wm8753_pcm_hw_params(struct snd_pcm_substream *substream, + struct snd_soc_pcm_runtime *rtd = substream->private_data; + struct snd_soc_codec *codec = rtd->codec; + struct wm8753_priv *wm8753 = snd_soc_codec_get_drvdata(codec); +- u16 voice = wm8753_read_reg_cache(codec, WM8753_PCM) & 0x01f3; +- u16 srate = wm8753_read_reg_cache(codec, WM8753_SRATE1) & 0x017f; ++ u16 voice = snd_soc_read(codec, WM8753_PCM) & 0x01f3; ++ u16 srate = snd_soc_read(codec, WM8753_SRATE1) & 0x017f; + + /* bit size */ + switch (params_format(params)) { +@@ -943,9 +896,9 @@ static int wm8753_pcm_hw_params(struct snd_pcm_substream *substream, + /* sample rate */ + if (params_rate(params) * 384 == wm8753->pcmclk) + srate |= 0x80; +- wm8753_write(codec, WM8753_SRATE1, srate); ++ snd_soc_write(codec, WM8753_SRATE1, srate); + +- wm8753_write(codec, WM8753_PCM, voice); ++ snd_soc_write(codec, WM8753_PCM, voice); + return 0; + } + +@@ -958,8 +911,8 @@ static int wm8753_pcm_set_dai_fmt(struct snd_soc_dai *codec_dai, + struct snd_soc_codec *codec = codec_dai->codec; + u16 voice, ioctl; + +- voice = wm8753_read_reg_cache(codec, WM8753_PCM) & 0x011f; +- ioctl = wm8753_read_reg_cache(codec, WM8753_IOCTL) & 0x015d; ++ voice = snd_soc_read(codec, WM8753_PCM) & 0x011f; ++ ioctl = snd_soc_read(codec, WM8753_IOCTL) & 0x015d; + + /* set master/slave audio interface */ + switch (fmt & SND_SOC_DAIFMT_MASTER_MASK) { +@@ -1013,8 +966,8 @@ static int wm8753_pcm_set_dai_fmt(struct snd_soc_dai *codec_dai, + return -EINVAL; + } + +- wm8753_write(codec, WM8753_PCM, voice); +- wm8753_write(codec, WM8753_IOCTL, ioctl); ++ snd_soc_write(codec, WM8753_PCM, voice); ++ snd_soc_write(codec, WM8753_IOCTL, ioctl); + return 0; + } + +@@ -1026,16 +979,16 @@ static int wm8753_set_dai_clkdiv(struct snd_soc_dai *codec_dai, + + switch (div_id) { + case WM8753_PCMDIV: +- reg = wm8753_read_reg_cache(codec, WM8753_CLOCK) & 0x003f; +- wm8753_write(codec, WM8753_CLOCK, reg | div); ++ reg = snd_soc_read(codec, WM8753_CLOCK) & 0x003f; ++ snd_soc_write(codec, WM8753_CLOCK, reg | div); + break; + case WM8753_BCLKDIV: +- reg = wm8753_read_reg_cache(codec, WM8753_SRATE2) & 0x01c7; +- wm8753_write(codec, WM8753_SRATE2, reg | div); ++ reg = snd_soc_read(codec, WM8753_SRATE2) & 0x01c7; ++ snd_soc_write(codec, WM8753_SRATE2, reg | div); + break; + case WM8753_VXCLKDIV: +- reg = wm8753_read_reg_cache(codec, WM8753_SRATE2) & 0x003f; +- wm8753_write(codec, WM8753_SRATE2, reg | div); ++ reg = snd_soc_read(codec, WM8753_SRATE2) & 0x003f; ++ snd_soc_write(codec, WM8753_SRATE2, reg | div); + break; + default: + return -EINVAL; +@@ -1050,7 +1003,7 @@ static int wm8753_hdac_set_dai_fmt(struct snd_soc_dai *codec_dai, + unsigned int fmt) + { + struct snd_soc_codec *codec = codec_dai->codec; +- u16 hifi = wm8753_read_reg_cache(codec, WM8753_HIFI) & 0x01e0; ++ u16 hifi = snd_soc_read(codec, WM8753_HIFI) & 0x01e0; + + /* interface format */ + switch (fmt & SND_SOC_DAIFMT_FORMAT_MASK) { +@@ -1072,7 +1025,7 @@ static int wm8753_hdac_set_dai_fmt(struct snd_soc_dai *codec_dai, + return -EINVAL; + } + +- wm8753_write(codec, WM8753_HIFI, hifi); ++ snd_soc_write(codec, WM8753_HIFI, hifi); + return 0; + } + +@@ -1085,8 +1038,8 @@ static int wm8753_i2s_set_dai_fmt(struct snd_soc_dai *codec_dai, + struct snd_soc_codec *codec = codec_dai->codec; + u16 ioctl, hifi; + +- hifi = wm8753_read_reg_cache(codec, WM8753_HIFI) & 0x011f; +- ioctl = wm8753_read_reg_cache(codec, WM8753_IOCTL) & 0x00ae; ++ hifi = snd_soc_read(codec, WM8753_HIFI) & 0x011f; ++ ioctl = snd_soc_read(codec, WM8753_IOCTL) & 0x00ae; + + /* set master/slave audio interface */ + switch (fmt & SND_SOC_DAIFMT_MASTER_MASK) { +@@ -1140,8 +1093,8 @@ static int wm8753_i2s_set_dai_fmt(struct snd_soc_dai *codec_dai, + return -EINVAL; + } + +- wm8753_write(codec, WM8753_HIFI, hifi); +- wm8753_write(codec, WM8753_IOCTL, ioctl); ++ snd_soc_write(codec, WM8753_HIFI, hifi); ++ snd_soc_write(codec, WM8753_IOCTL, ioctl); + return 0; + } + +@@ -1162,8 +1115,8 @@ static int wm8753_i2s_hw_params(struct snd_pcm_substream *substream, + struct snd_soc_pcm_runtime *rtd = substream->private_data; + struct snd_soc_codec *codec = rtd->codec; + struct wm8753_priv *wm8753 = snd_soc_codec_get_drvdata(codec); +- u16 srate = wm8753_read_reg_cache(codec, WM8753_SRATE1) & 0x01c0; +- u16 hifi = wm8753_read_reg_cache(codec, WM8753_HIFI) & 0x01f3; ++ u16 srate = snd_soc_read(codec, WM8753_SRATE1) & 0x01c0; ++ u16 hifi = snd_soc_read(codec, WM8753_HIFI) & 0x01f3; + int coeff; + + /* is digital filter coefficient valid ? */ +@@ -1172,7 +1125,7 @@ static int wm8753_i2s_hw_params(struct snd_pcm_substream *substream, + printk(KERN_ERR "wm8753 invalid MCLK or rate\n"); + return coeff; + } +- wm8753_write(codec, WM8753_SRATE1, srate | (coeff_div[coeff].sr << 1) | ++ snd_soc_write(codec, WM8753_SRATE1, srate | (coeff_div[coeff].sr << 1) | + coeff_div[coeff].usb); + + /* bit size */ +@@ -1190,7 +1143,7 @@ static int wm8753_i2s_hw_params(struct snd_pcm_substream *substream, + break; + } + +- wm8753_write(codec, WM8753_HIFI, hifi); ++ snd_soc_write(codec, WM8753_HIFI, hifi); + return 0; + } + +@@ -1201,8 +1154,8 @@ static int wm8753_mode1v_set_dai_fmt(struct snd_soc_dai *codec_dai, + u16 clock; + + /* set clk source as pcmclk */ +- clock = wm8753_read_reg_cache(codec, WM8753_CLOCK) & 0xfffb; +- wm8753_write(codec, WM8753_CLOCK, clock); ++ clock = snd_soc_read(codec, WM8753_CLOCK) & 0xfffb; ++ snd_soc_write(codec, WM8753_CLOCK, clock); + + if (wm8753_vdac_adc_set_dai_fmt(codec_dai, fmt) < 0) + return -EINVAL; +@@ -1224,8 +1177,8 @@ static int wm8753_mode2_set_dai_fmt(struct snd_soc_dai *codec_dai, + u16 clock; + + /* set clk source as pcmclk */ +- clock = wm8753_read_reg_cache(codec, WM8753_CLOCK) & 0xfffb; +- wm8753_write(codec, WM8753_CLOCK, clock); ++ clock = snd_soc_read(codec, WM8753_CLOCK) & 0xfffb; ++ snd_soc_write(codec, WM8753_CLOCK, clock); + + if (wm8753_vdac_adc_set_dai_fmt(codec_dai, fmt) < 0) + return -EINVAL; +@@ -1239,8 +1192,8 @@ static int wm8753_mode3_4_set_dai_fmt(struct snd_soc_dai *codec_dai, + u16 clock; + + /* set clk source as mclk */ +- clock = wm8753_read_reg_cache(codec, WM8753_CLOCK) & 0xfffb; +- wm8753_write(codec, WM8753_CLOCK, clock | 0x4); ++ clock = snd_soc_read(codec, WM8753_CLOCK) & 0xfffb; ++ snd_soc_write(codec, WM8753_CLOCK, clock | 0x4); + + if (wm8753_hdac_set_dai_fmt(codec_dai, fmt) < 0) + return -EINVAL; +@@ -1252,19 +1205,19 @@ static int wm8753_mode3_4_set_dai_fmt(struct snd_soc_dai *codec_dai, + static int wm8753_mute(struct snd_soc_dai *dai, int mute) + { + struct snd_soc_codec *codec = dai->codec; +- u16 mute_reg = wm8753_read_reg_cache(codec, WM8753_DAC) & 0xfff7; ++ u16 mute_reg = snd_soc_read(codec, WM8753_DAC) & 0xfff7; + struct wm8753_priv *wm8753 = snd_soc_codec_get_drvdata(codec); + + /* the digital mute covers the HiFi and Voice DAC's on the WM8753. + * make sure we check if they are not both active when we mute */ + if (mute && wm8753->dai_func == 1) { + if (!codec->active) +- wm8753_write(codec, WM8753_DAC, mute_reg | 0x8); ++ snd_soc_write(codec, WM8753_DAC, mute_reg | 0x8); + } else { + if (mute) +- wm8753_write(codec, WM8753_DAC, mute_reg | 0x8); ++ snd_soc_write(codec, WM8753_DAC, mute_reg | 0x8); + else +- wm8753_write(codec, WM8753_DAC, mute_reg); ++ snd_soc_write(codec, WM8753_DAC, mute_reg); + } + + return 0; +@@ -1273,23 +1226,23 @@ static int wm8753_mute(struct snd_soc_dai *dai, int mute) + static int wm8753_set_bias_level(struct snd_soc_codec *codec, + enum snd_soc_bias_level level) + { +- u16 pwr_reg = wm8753_read_reg_cache(codec, WM8753_PWR1) & 0xfe3e; ++ u16 pwr_reg = snd_soc_read(codec, WM8753_PWR1) & 0xfe3e; + + switch (level) { + case SND_SOC_BIAS_ON: + /* set vmid to 50k and unmute dac */ +- wm8753_write(codec, WM8753_PWR1, pwr_reg | 0x00c0); ++ snd_soc_write(codec, WM8753_PWR1, pwr_reg | 0x00c0); + break; + case SND_SOC_BIAS_PREPARE: + /* set vmid to 5k for quick power up */ +- wm8753_write(codec, WM8753_PWR1, pwr_reg | 0x01c1); ++ snd_soc_write(codec, WM8753_PWR1, pwr_reg | 0x01c1); + break; + case SND_SOC_BIAS_STANDBY: + /* mute dac and set vmid to 500k, enable VREF */ +- wm8753_write(codec, WM8753_PWR1, pwr_reg | 0x0141); ++ snd_soc_write(codec, WM8753_PWR1, pwr_reg | 0x0141); + break; + case SND_SOC_BIAS_OFF: +- wm8753_write(codec, WM8753_PWR1, 0x0001); ++ snd_soc_write(codec, WM8753_PWR1, 0x0001); + break; + } + codec->bias_level = level; +@@ -1477,7 +1430,7 @@ static void wm8753_set_dai_mode(struct snd_soc_codec *codec, + else + dai->driver = &wm8753_all_dai[(wm8753->dai_func << 1) + 1]; + } +- wm8753_write(codec, WM8753_IOCTL, wm8753->dai_func); ++ snd_soc_write(codec, WM8753_IOCTL, wm8753->dai_func); + } + + static void wm8753_work(struct work_struct *work) +@@ -1495,22 +1448,19 @@ static int wm8753_suspend(struct snd_soc_codec *codec, pm_message_t state) + + static int wm8753_resume(struct snd_soc_codec *codec) + { ++ u16 *reg_cache = codec->reg_cache; + int i; +- u8 data[2]; +- u16 *cache = codec->reg_cache; + + /* Sync reg_cache with the hardware */ +- for (i = 0; i < ARRAY_SIZE(wm8753_reg); i++) { +- if (i + 1 == WM8753_RESET) ++ for (i = 1; i < ARRAY_SIZE(wm8753_reg); i++) { ++ if (i == WM8753_RESET) + continue; + + /* No point in writing hardware default values back */ +- if (cache[i] == wm8753_reg[i]) ++ if (reg_cache[i] == wm8753_reg[i]) + continue; + +- data[0] = ((i + 1) << 1) | ((cache[i] >> 8) & 0x0001); +- data[1] = cache[i] & 0x00ff; +- codec->hw_write(codec->control_data, data, 2); ++ snd_soc_write(codec, i, reg_cache[i]); + } + + wm8753_set_bias_level(codec, SND_SOC_BIAS_STANDBY); +@@ -1548,7 +1498,7 @@ static int run_delayed_work(struct delayed_work *dwork) + static int wm8753_probe(struct snd_soc_codec *codec) + { + struct wm8753_priv *wm8753 = snd_soc_codec_get_drvdata(codec); +- int ret = 0, reg; ++ int ret; + + INIT_DELAYED_WORK(&codec->delayed_work, wm8753_work); + +@@ -1573,26 +1523,16 @@ static int wm8753_probe(struct snd_soc_codec *codec) + msecs_to_jiffies(caps_charge)); + + /* set the update bits */ +- reg = wm8753_read_reg_cache(codec, WM8753_LDAC); +- wm8753_write(codec, WM8753_LDAC, reg | 0x0100); +- reg = wm8753_read_reg_cache(codec, WM8753_RDAC); +- wm8753_write(codec, WM8753_RDAC, reg | 0x0100); +- reg = wm8753_read_reg_cache(codec, WM8753_LADC); +- wm8753_write(codec, WM8753_LADC, reg | 0x0100); +- reg = wm8753_read_reg_cache(codec, WM8753_RADC); +- wm8753_write(codec, WM8753_RADC, reg | 0x0100); +- reg = wm8753_read_reg_cache(codec, WM8753_LOUT1V); +- wm8753_write(codec, WM8753_LOUT1V, reg | 0x0100); +- reg = wm8753_read_reg_cache(codec, WM8753_ROUT1V); +- wm8753_write(codec, WM8753_ROUT1V, reg | 0x0100); +- reg = wm8753_read_reg_cache(codec, WM8753_LOUT2V); +- wm8753_write(codec, WM8753_LOUT2V, reg | 0x0100); +- reg = wm8753_read_reg_cache(codec, WM8753_ROUT2V); +- wm8753_write(codec, WM8753_ROUT2V, reg | 0x0100); +- reg = wm8753_read_reg_cache(codec, WM8753_LINVOL); +- wm8753_write(codec, WM8753_LINVOL, reg | 0x0100); +- reg = wm8753_read_reg_cache(codec, WM8753_RINVOL); +- wm8753_write(codec, WM8753_RINVOL, reg | 0x0100); ++ snd_soc_update_bits(codec, WM8753_LDAC, 0x0100, 0x0100); ++ snd_soc_update_bits(codec, WM8753_RDAC, 0x0100, 0x0100); ++ snd_soc_update_bits(codec, WM8753_LDAC, 0x0100, 0x0100); ++ snd_soc_update_bits(codec, WM8753_RDAC, 0x0100, 0x0100); ++ snd_soc_update_bits(codec, WM8753_LOUT1V, 0x0100, 0x0100); ++ snd_soc_update_bits(codec, WM8753_ROUT1V, 0x0100, 0x0100); ++ snd_soc_update_bits(codec, WM8753_LOUT2V, 0x0100, 0x0100); ++ snd_soc_update_bits(codec, WM8753_ROUT2V, 0x0100, 0x0100); ++ snd_soc_update_bits(codec, WM8753_LINVOL, 0x0100, 0x0100); ++ snd_soc_update_bits(codec, WM8753_RINVOL, 0x0100, 0x0100); + + snd_soc_add_controls(codec, wm8753_snd_controls, + ARRAY_SIZE(wm8753_snd_controls)); +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0026-KVM-MMU-Fix-incorrect-direct-gfn-for-unpaged-mode-sh.patch b/recipes/linux/linux-omap-2.6.37/linus/0026-KVM-MMU-Fix-incorrect-direct-gfn-for-unpaged-mode-sh.patch new file mode 100644 index 0000000000..dd2c9b32be --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0026-KVM-MMU-Fix-incorrect-direct-gfn-for-unpaged-mode-sh.patch @@ -0,0 +1,35 @@ +From 649497d1a3676020802ebba04a3d9bb31253adb5 Mon Sep 17 00:00:00 2001 +From: Avi Kivity <avi@redhat.com> +Date: Tue, 28 Dec 2010 12:09:07 +0200 +Subject: [PATCH 26/66] KVM: MMU: Fix incorrect direct gfn for unpaged mode shadow + +We use the physical address instead of the base gfn for the four +PAE page directories we use in unpaged mode. When the guest accesses +an address above 1GB that is backed by a large host page, a BUG_ON() +in kvm_mmu_set_gfn() triggers. + +Resolves: https://bugzilla.kernel.org/show_bug.cgi?id=21962 +Reported-and-tested-by: Nicolas Prochazka <prochazka.nicolas@gmail.com> +KVM-Stable-Tag. +Signed-off-by: Avi Kivity <avi@redhat.com> +--- + arch/x86/kvm/mmu.c | 3 ++- + 1 files changed, 2 insertions(+), 1 deletions(-) + +diff --git a/arch/x86/kvm/mmu.c b/arch/x86/kvm/mmu.c +index fb8b376..fbb04ae 100644 +--- a/arch/x86/kvm/mmu.c ++++ b/arch/x86/kvm/mmu.c +@@ -2394,7 +2394,8 @@ static int mmu_alloc_direct_roots(struct kvm_vcpu *vcpu) + ASSERT(!VALID_PAGE(root)); + spin_lock(&vcpu->kvm->mmu_lock); + kvm_mmu_free_some_pages(vcpu); +- sp = kvm_mmu_get_page(vcpu, i << 30, i << 30, ++ sp = kvm_mmu_get_page(vcpu, i << (30 - PAGE_SHIFT), ++ i << 30, + PT32_ROOT_LEVEL, 1, ACC_ALL, + NULL); + root = __pa(sp->spt); +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0027-fix-freeing-user_struct-in-user-cache.patch b/recipes/linux/linux-omap-2.6.37/linus/0027-fix-freeing-user_struct-in-user-cache.patch new file mode 100644 index 0000000000..636f86ac1a --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0027-fix-freeing-user_struct-in-user-cache.patch @@ -0,0 +1,34 @@ +From 4ef9e11d6867f88951e30db910fa015300e31871 Mon Sep 17 00:00:00 2001 +From: Hillf Danton <dhillf@gmail.com> +Date: Wed, 29 Dec 2010 21:55:28 +0800 +Subject: [PATCH 27/66] fix freeing user_struct in user cache + +When racing on adding into user cache, the new allocated from mm slab +is freed without putting user namespace. + +Since the user namespace is already operated by getting, putting has +to be issued. + +Signed-off-by: Hillf Danton <dhillf@gmail.com> +Acked-by: Serge Hallyn <serge@hallyn.com> +Cc: stable@kernel.org +Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> +--- + kernel/user.c | 1 + + 1 files changed, 1 insertions(+), 0 deletions(-) + +diff --git a/kernel/user.c b/kernel/user.c +index 2c7d8d5..5c598ca 100644 +--- a/kernel/user.c ++++ b/kernel/user.c +@@ -158,6 +158,7 @@ struct user_struct *alloc_uid(struct user_namespace *ns, uid_t uid) + spin_lock_irq(&uidhash_lock); + up = uid_hash_find(uid, hashent); + if (up) { ++ put_user_ns(ns); + key_put(new->uid_keyring); + key_put(new->session_keyring); + kmem_cache_free(uid_cachep, new); +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0028-spi-omap2_mcspi.c-Force-CS-to-be-in-inactive-state-a.patch b/recipes/linux/linux-omap-2.6.37/linus/0028-spi-omap2_mcspi.c-Force-CS-to-be-in-inactive-state-a.patch new file mode 100644 index 0000000000..467265eeb4 --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0028-spi-omap2_mcspi.c-Force-CS-to-be-in-inactive-state-a.patch @@ -0,0 +1,111 @@ +From 42ce7fd6319bed8ecb26d656c476365da46b29e9 Mon Sep 17 00:00:00 2001 +From: Gregory CLEMENT <gregory.clement@free-electrons.com> +Date: Wed, 29 Dec 2010 11:52:53 +0100 +Subject: [PATCH 28/66] spi/omap2_mcspi.c: Force CS to be in inactive state after off-mode transition + +When SPI wake up from OFF mode, CS is in the wrong state: force it to the +inactive state. + +During the system life, I monitored the CS behavior using a oscilloscope. +I also activated debug in omap2_mcspi, so I saw when driver disable the clocks +and restore context when device is not used.Each time the CS was in the correct +state. It was only when system was put suspend to ram with off-mode activated +that on resume the CS was in wrong state( ie activated). + +Changelog: +* Change from v1 to v2: + - Rebase on linus/master (after 2.6.37-rc1) + - Do some clean-up and fix indentation on both patches + - Add more explanations for patch 2 + +* Change from v2 to v3: + - Use directly resume function of spi_master instead of using function + - from spi_device as Grant Likely pointed it out. + - Force this transition explicitly for each CS used by a device. + +* Change from v3 to v4: + - Patch clean-up according to Kevin Hilman and checkpatch. + - Now force CS to be in inactive state only if it was inactive when it was + suspended. + +* Change from v4 to v5: + - Rebase on linus/master (after 2.6.37-rc3) + - Collapse some lines as pointed by Grant Likely + - Fix a spelling + +* Change from v5 to v6: + - Rebase on linus/master (after 2.6.37-rc7) + - Use CONFIG_SUSPEND instead of CONFIG_PM + - Didn't use legacy PM methods anymore. Instead, add a struct dev_pm_ops and + add the resume method there. + - Fix multi-line comment style + +* Change from v6 to v7: + - Rebase on linus/master (after 2.6.37-rc8) + - Drop an extra line + +Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> +Acked-by: David Brownell <dbrownell@users.sourceforge.net> +Reviewed-by: Kevin Hilman <khilman@deeprootsystems.com> +Signed-off-by: Grant Likely <grant.likely@secretlab.ca> +--- + drivers/spi/omap2_mcspi.c | 39 +++++++++++++++++++++++++++++++++++++++ + 1 files changed, 39 insertions(+), 0 deletions(-) + +diff --git a/drivers/spi/omap2_mcspi.c b/drivers/spi/omap2_mcspi.c +index 2a651e6..951a160 100644 +--- a/drivers/spi/omap2_mcspi.c ++++ b/drivers/spi/omap2_mcspi.c +@@ -1305,10 +1305,49 @@ static int __exit omap2_mcspi_remove(struct platform_device *pdev) + /* work with hotplug and coldplug */ + MODULE_ALIAS("platform:omap2_mcspi"); + ++#ifdef CONFIG_SUSPEND ++/* ++ * When SPI wake up from off-mode, CS is in activate state. If it was in ++ * unactive state when driver was suspend, then force it to unactive state at ++ * wake up. ++ */ ++static int omap2_mcspi_resume(struct device *dev) ++{ ++ struct spi_master *master = dev_get_drvdata(dev); ++ struct omap2_mcspi *mcspi = spi_master_get_devdata(master); ++ struct omap2_mcspi_cs *cs; ++ ++ omap2_mcspi_enable_clocks(mcspi); ++ list_for_each_entry(cs, &omap2_mcspi_ctx[master->bus_num - 1].cs, ++ node) { ++ if ((cs->chconf0 & OMAP2_MCSPI_CHCONF_FORCE) == 0) { ++ ++ /* ++ * We need to toggle CS state for OMAP take this ++ * change in account. ++ */ ++ MOD_REG_BIT(cs->chconf0, OMAP2_MCSPI_CHCONF_FORCE, 1); ++ __raw_writel(cs->chconf0, cs->base + OMAP2_MCSPI_CHCONF0); ++ MOD_REG_BIT(cs->chconf0, OMAP2_MCSPI_CHCONF_FORCE, 0); ++ __raw_writel(cs->chconf0, cs->base + OMAP2_MCSPI_CHCONF0); ++ } ++ } ++ omap2_mcspi_disable_clocks(mcspi); ++ return 0; ++} ++#else ++#define omap2_mcspi_resume NULL ++#endif ++ ++static const struct dev_pm_ops omap2_mcspi_pm_ops = { ++ .resume = omap2_mcspi_resume, ++}; ++ + static struct platform_driver omap2_mcspi_driver = { + .driver = { + .name = "omap2_mcspi", + .owner = THIS_MODULE, ++ .pm = &omap2_mcspi_pm_ops + }, + .remove = __exit_p(omap2_mcspi_remove), + }; +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0029-kconfig-fix-undesirable-side-effect-of-adding-visibl.patch b/recipes/linux/linux-omap-2.6.37/linus/0029-kconfig-fix-undesirable-side-effect-of-adding-visibl.patch new file mode 100644 index 0000000000..2e282cd882 --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0029-kconfig-fix-undesirable-side-effect-of-adding-visibl.patch @@ -0,0 +1,49 @@ +From 7ad1227818f09242cfe9bf1845fd24211f5f99bd Mon Sep 17 00:00:00 2001 +From: Jan Beulich <JBeulich@novell.com> +Date: Thu, 9 Dec 2010 08:11:38 +0000 +Subject: [PATCH 29/66] kconfig: fix undesirable side effect of adding "visible" menu attribute + +This lead to non-selected, non-user-selectable options to be written +out to .config. This is not only pointless, but also preventing the +user to be prompted should any of those options eventually become +visible (e.g. by de-selecting the *_AUTO options the "visible" +attribute was added for. + +Furthermore it is quite logical for the "visible" attribute of a menu +to control the visibility of all contained prompts, which is what the +patch does. + +Signed-off-by: Jan Beulich <jbeulich@novell.com> +Signed-off-by: Michal Marek <mmarek@suse.cz> +--- + scripts/kconfig/menu.c | 14 ++++++++++++++ + 1 files changed, 14 insertions(+), 0 deletions(-) + +diff --git a/scripts/kconfig/menu.c b/scripts/kconfig/menu.c +index b9d9aa1..5f77dcb 100644 +--- a/scripts/kconfig/menu.c ++++ b/scripts/kconfig/menu.c +@@ -140,6 +140,20 @@ struct property *menu_add_prop(enum prop_type type, char *prompt, struct expr *e + } + if (current_entry->prompt && current_entry != &rootmenu) + prop_warn(prop, "prompt redefined"); ++ ++ /* Apply all upper menus' visibilities to actual prompts. */ ++ if(type == P_PROMPT) { ++ struct menu *menu = current_entry; ++ ++ while ((menu = menu->parent) != NULL) { ++ if (!menu->visibility) ++ continue; ++ prop->visible.expr ++ = expr_alloc_and(prop->visible.expr, ++ menu->visibility); ++ } ++ } ++ + current_entry->prompt = prop; + } + prop->text = prompt; +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0030-spi-m68knommu-Coldfire-QSPI-platform-support.patch b/recipes/linux/linux-omap-2.6.37/linus/0030-spi-m68knommu-Coldfire-QSPI-platform-support.patch new file mode 100644 index 0000000000..c911a2dc94 --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0030-spi-m68knommu-Coldfire-QSPI-platform-support.patch @@ -0,0 +1,33 @@ +From 0bc463426ab5eb39e76df637b29a4f191d01b8a0 Mon Sep 17 00:00:00 2001 +From: Jate Sujjavanich <jsujjavanich@syntech-fuelmaster.com> +Date: Wed, 29 Sep 2010 09:44:32 -0400 +Subject: [PATCH 30/66] spi/m68knommu: Coldfire QSPI platform support + +After grabbing a msg from the msgq, the mcfqspi_work function calls +list_del_init on the mcfqspi->msgq which unintentionally deletes the rest +of the list before it can be processed. If qspi call was made using +spi_sync, this can result in a process hang. + +Signed-off-by: Jate Sujjavanich <jsujjavanich@syntech-fuelmaster.com> +Acked-by: Steven King <sfking@fdwdc.com> +Signed-off-by: Grant Likely <grant.likely@secretlab.ca> +--- + drivers/spi/coldfire_qspi.c | 2 +- + 1 files changed, 1 insertions(+), 1 deletions(-) + +diff --git a/drivers/spi/coldfire_qspi.c b/drivers/spi/coldfire_qspi.c +index 052b3c7..8856bcc 100644 +--- a/drivers/spi/coldfire_qspi.c ++++ b/drivers/spi/coldfire_qspi.c +@@ -317,7 +317,7 @@ static void mcfqspi_work(struct work_struct *work) + msg = container_of(mcfqspi->msgq.next, struct spi_message, + queue); + +- list_del_init(&mcfqspi->msgq); ++ list_del_init(&msg->queue); + spin_unlock_irqrestore(&mcfqspi->lock, flags); + + spi = msg->spi; +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0031-sound-Prevent-buffer-overflow-in-OSS-load_mixer_volu.patch b/recipes/linux/linux-omap-2.6.37/linus/0031-sound-Prevent-buffer-overflow-in-OSS-load_mixer_volu.patch new file mode 100644 index 0000000000..6f8bccee71 --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0031-sound-Prevent-buffer-overflow-in-OSS-load_mixer_volu.patch @@ -0,0 +1,47 @@ +From d81a12bc29ae4038770e05dce4ab7f26fd5880fb Mon Sep 17 00:00:00 2001 +From: Dan Rosenberg <drosenberg@vsecurity.com> +Date: Sat, 25 Dec 2010 16:23:40 -0500 +Subject: [PATCH 31/66] sound: Prevent buffer overflow in OSS load_mixer_volumes + +The load_mixer_volumes() function, which can be triggered by +unprivileged users via the SOUND_MIXER_SETLEVELS ioctl, is vulnerable to +a buffer overflow. Because the provided "name" argument isn't +guaranteed to be NULL terminated at the expected 32 bytes, it's possible +to overflow past the end of the last element in the mixer_vols array. +Further exploitation can result in an arbitrary kernel write (via +subsequent calls to load_mixer_volumes()) leading to privilege +escalation, or arbitrary kernel reads via get_mixer_levels(). In +addition, the strcmp() may leak bytes beyond the mixer_vols array. + +Signed-off-by: Dan Rosenberg <drosenberg@vsecurity.com> +Cc: stable <stable@kernel.org> +Signed-off-by: Takashi Iwai <tiwai@suse.de> +--- + sound/oss/soundcard.c | 4 ++-- + 1 files changed, 2 insertions(+), 2 deletions(-) + +diff --git a/sound/oss/soundcard.c b/sound/oss/soundcard.c +index 46c0d03..fcb14a0 100644 +--- a/sound/oss/soundcard.c ++++ b/sound/oss/soundcard.c +@@ -87,7 +87,7 @@ int *load_mixer_volumes(char *name, int *levels, int present) + int i, n; + + for (i = 0; i < num_mixer_volumes; i++) { +- if (strcmp(name, mixer_vols[i].name) == 0) { ++ if (strncmp(name, mixer_vols[i].name, 32) == 0) { + if (present) + mixer_vols[i].num = i; + return mixer_vols[i].levels; +@@ -99,7 +99,7 @@ int *load_mixer_volumes(char *name, int *levels, int present) + } + n = num_mixer_volumes++; + +- strcpy(mixer_vols[n].name, name); ++ strncpy(mixer_vols[n].name, name, 32); + + if (present) + mixer_vols[n].num = n; +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0032-ALSA-hda-Use-LPIB-quirk-for-Dell-Inspiron-m101z-1120.patch b/recipes/linux/linux-omap-2.6.37/linus/0032-ALSA-hda-Use-LPIB-quirk-for-Dell-Inspiron-m101z-1120.patch new file mode 100644 index 0000000000..51b8ceba69 --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0032-ALSA-hda-Use-LPIB-quirk-for-Dell-Inspiron-m101z-1120.patch @@ -0,0 +1,32 @@ +From e03fa055bc126e536c7f65862e08a9b143138ea9 Mon Sep 17 00:00:00 2001 +From: Daniel T Chen <crimsun@ubuntu.com> +Date: Tue, 28 Dec 2010 17:20:02 -0500 +Subject: [PATCH 32/66] ALSA: hda: Use LPIB quirk for Dell Inspiron m101z/1120 + +Sjoerd Simons reports that, without using position_fix=1, recording +experiences overruns. Work around that by applying the LPIB quirk +for his hardware. + +Reported-and-tested-by: Sjoerd Simons <sjoerd@debian.org> +Cc: <stable@kernel.org> +Signed-off-by: Daniel T Chen <crimsun@ubuntu.com> +Signed-off-by: Takashi Iwai <tiwai@suse.de> +--- + sound/pci/hda/hda_intel.c | 1 + + 1 files changed, 1 insertions(+), 0 deletions(-) + +diff --git a/sound/pci/hda/hda_intel.c b/sound/pci/hda/hda_intel.c +index b030c8e..a1c4008 100644 +--- a/sound/pci/hda/hda_intel.c ++++ b/sound/pci/hda/hda_intel.c +@@ -2300,6 +2300,7 @@ static struct snd_pci_quirk position_fix_list[] __devinitdata = { + SND_PCI_QUIRK(0x1028, 0x01cc, "Dell D820", POS_FIX_LPIB), + SND_PCI_QUIRK(0x1028, 0x01de, "Dell Precision 390", POS_FIX_LPIB), + SND_PCI_QUIRK(0x1028, 0x01f6, "Dell Latitude 131L", POS_FIX_LPIB), ++ SND_PCI_QUIRK(0x1028, 0x0470, "Dell Inspiron 1120", POS_FIX_LPIB), + SND_PCI_QUIRK(0x103c, 0x306d, "HP dv3", POS_FIX_LPIB), + SND_PCI_QUIRK(0x1043, 0x813d, "ASUS P5AD2", POS_FIX_LPIB), + SND_PCI_QUIRK(0x1043, 0x81b3, "ASUS", POS_FIX_LPIB), +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0033-Revert-drm-i915-bios-Reverse-order-of-100-120-Mhz-SS.patch b/recipes/linux/linux-omap-2.6.37/linus/0033-Revert-drm-i915-bios-Reverse-order-of-100-120-Mhz-SS.patch new file mode 100644 index 0000000000..1b33453388 --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0033-Revert-drm-i915-bios-Reverse-order-of-100-120-Mhz-SS.patch @@ -0,0 +1,33 @@ +From bcfbbce822d219eb587acaba8a6e062bbeae4761 Mon Sep 17 00:00:00 2001 +From: Chris Wilson <chris@chris-wilson.co.uk> +Date: Thu, 30 Dec 2010 09:07:15 +0000 +Subject: [PATCH 33/66] Revert "drm/i915/bios: Reverse order of 100/120 Mhz SSC clocks" + +As I feared, whilst this fixed the clocks for the Lenovo U160, it broke +many other machines. So lets reverts commit 448f53a1ede54eb854d036abf +and search for the real bug. + +Reported-and-tested-by: Travis Hume <travis@computoring.org> [et al] +Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=25842 +Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=32698 +Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> +--- + drivers/gpu/drm/i915/intel_bios.c | 2 +- + 1 files changed, 1 insertions(+), 1 deletions(-) + +diff --git a/drivers/gpu/drm/i915/intel_bios.c b/drivers/gpu/drm/i915/intel_bios.c +index 2b20786..b0b1200 100644 +--- a/drivers/gpu/drm/i915/intel_bios.c ++++ b/drivers/gpu/drm/i915/intel_bios.c +@@ -270,7 +270,7 @@ parse_general_features(struct drm_i915_private *dev_priv, + general->ssc_freq ? 66 : 48; + else if (IS_GEN5(dev) || IS_GEN6(dev)) + dev_priv->lvds_ssc_freq = +- general->ssc_freq ? 120 : 100; ++ general->ssc_freq ? 100 : 120; + else + dev_priv->lvds_ssc_freq = + general->ssc_freq ? 100 : 96; +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0034-drm-i915-dvo-Report-LVDS-attached-to-ch701x-as-conne.patch b/recipes/linux/linux-omap-2.6.37/linus/0034-drm-i915-dvo-Report-LVDS-attached-to-ch701x-as-conne.patch new file mode 100644 index 0000000000..6c3d9105ee --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0034-drm-i915-dvo-Report-LVDS-attached-to-ch701x-as-conne.patch @@ -0,0 +1,30 @@ +From cc6455f82edd3f9da3b03870d41cde3cb22ad40d Mon Sep 17 00:00:00 2001 +From: Chris Wilson <chris@chris-wilson.co.uk> +Date: Thu, 30 Dec 2010 12:54:00 +0000 +Subject: [PATCH 34/66] drm/i915/dvo: Report LVDS attached to ch701x as connected + +As we have already detected something attached to the chip during +initialisation, always report the LVDS connector status as connected +during probing. + +Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> +--- + drivers/gpu/drm/i915/dvo_ch7017.c | 2 +- + 1 files changed, 1 insertions(+), 1 deletions(-) + +diff --git a/drivers/gpu/drm/i915/dvo_ch7017.c b/drivers/gpu/drm/i915/dvo_ch7017.c +index af70337..d3e8c54 100644 +--- a/drivers/gpu/drm/i915/dvo_ch7017.c ++++ b/drivers/gpu/drm/i915/dvo_ch7017.c +@@ -242,7 +242,7 @@ fail: + + static enum drm_connector_status ch7017_detect(struct intel_dvo_device *dvo) + { +- return connector_status_unknown; ++ return connector_status_connected; + } + + static enum drm_mode_status ch7017_mode_valid(struct intel_dvo_device *dvo, +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0035-update-Documentation-filesystems-Locking.patch b/recipes/linux/linux-omap-2.6.37/linus/0035-update-Documentation-filesystems-Locking.patch new file mode 100644 index 0000000000..3f09d91a2e --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0035-update-Documentation-filesystems-Locking.patch @@ -0,0 +1,402 @@ +From b83be6f20a0e468f715b14225c9f897538dfe5ad Mon Sep 17 00:00:00 2001 +From: Christoph Hellwig <hch> +Date: Thu, 16 Dec 2010 12:04:54 +0100 +Subject: [PATCH 35/66] update Documentation/filesystems/Locking + +Mostly inspired by all the recent BKL removal changes, but a lot of older +updates also weren't properly recorded. + +Signed-off-by: Christoph Hellwig <hch@lst.de> +Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> +--- + Documentation/filesystems/Locking | 214 ++++++++++++++++++------------------- + 1 files changed, 102 insertions(+), 112 deletions(-) + +diff --git a/Documentation/filesystems/Locking b/Documentation/filesystems/Locking +index b6426f1..7686e76 100644 +--- a/Documentation/filesystems/Locking ++++ b/Documentation/filesystems/Locking +@@ -18,7 +18,6 @@ prototypes: + char *(*d_dname)((struct dentry *dentry, char *buffer, int buflen); + + locking rules: +- none have BKL + dcache_lock rename_lock ->d_lock may block + d_revalidate: no no no yes + d_hash no no no yes +@@ -42,18 +41,23 @@ ata *); + int (*rename) (struct inode *, struct dentry *, + struct inode *, struct dentry *); + int (*readlink) (struct dentry *, char __user *,int); +- int (*follow_link) (struct dentry *, struct nameidata *); ++ void * (*follow_link) (struct dentry *, struct nameidata *); ++ void (*put_link) (struct dentry *, struct nameidata *, void *); + void (*truncate) (struct inode *); + int (*permission) (struct inode *, int, struct nameidata *); ++ int (*check_acl)(struct inode *, int); + int (*setattr) (struct dentry *, struct iattr *); + int (*getattr) (struct vfsmount *, struct dentry *, struct kstat *); + int (*setxattr) (struct dentry *, const char *,const void *,size_t,int); + ssize_t (*getxattr) (struct dentry *, const char *, void *, size_t); + ssize_t (*listxattr) (struct dentry *, char *, size_t); + int (*removexattr) (struct dentry *, const char *); ++ void (*truncate_range)(struct inode *, loff_t, loff_t); ++ long (*fallocate)(struct inode *inode, int mode, loff_t offset, loff_t len); ++ int (*fiemap)(struct inode *, struct fiemap_extent_info *, u64 start, u64 len); + + locking rules: +- all may block, none have BKL ++ all may block + i_mutex(inode) + lookup: yes + create: yes +@@ -66,19 +70,24 @@ rmdir: yes (both) (see below) + rename: yes (all) (see below) + readlink: no + follow_link: no ++put_link: no + truncate: yes (see below) + setattr: yes + permission: no ++check_acl: no + getattr: no + setxattr: yes + getxattr: no + listxattr: no + removexattr: yes ++truncate_range: yes ++fallocate: no ++fiemap: no + Additionally, ->rmdir(), ->unlink() and ->rename() have ->i_mutex on + victim. + cross-directory ->rename() has (per-superblock) ->s_vfs_rename_sem. + ->truncate() is never called directly - it's a callback, not a +-method. It's called by vmtruncate() - library function normally used by ++method. It's called by vmtruncate() - deprecated library function used by + ->setattr(). Locking information above applies to that call (i.e. is + inherited from ->setattr() - vmtruncate() is used when ATTR_SIZE had been + passed). +@@ -91,7 +100,7 @@ prototypes: + struct inode *(*alloc_inode)(struct super_block *sb); + void (*destroy_inode)(struct inode *); + void (*dirty_inode) (struct inode *); +- int (*write_inode) (struct inode *, int); ++ int (*write_inode) (struct inode *, struct writeback_control *wbc); + int (*drop_inode) (struct inode *); + void (*evict_inode) (struct inode *); + void (*put_super) (struct super_block *); +@@ -105,10 +114,11 @@ prototypes: + int (*show_options)(struct seq_file *, struct vfsmount *); + ssize_t (*quota_read)(struct super_block *, int, char *, size_t, loff_t); + ssize_t (*quota_write)(struct super_block *, int, const char *, size_t, loff_t); ++ int (*bdev_try_to_free_page)(struct super_block*, struct page*, gfp_t); ++ int (*trim_fs) (struct super_block *, struct fstrim_range *); + + locking rules: + All may block [not true, see below] +- None have BKL + s_umount + alloc_inode: + destroy_inode: +@@ -127,6 +137,8 @@ umount_begin: no + show_options: no (namespace_sem) + quota_read: no (see below) + quota_write: no (see below) ++bdev_try_to_free_page: no (see below) ++trim_fs: no + + ->statfs() has s_umount (shared) when called by ustat(2) (native or + compat), but that's an accident of bad API; s_umount is used to pin +@@ -139,19 +151,25 @@ be the only ones operating on the quota file by the quota code (via + dqio_sem) (unless an admin really wants to screw up something and + writes to quota files with quotas on). For other details about locking + see also dquot_operations section. ++->bdev_try_to_free_page is called from the ->releasepage handler of ++the block device inode. See there for more details. + + --------------------------- file_system_type --------------------------- + prototypes: + int (*get_sb) (struct file_system_type *, int, + const char *, void *, struct vfsmount *); ++ struct dentry *(*mount) (struct file_system_type *, int, ++ const char *, void *); + void (*kill_sb) (struct super_block *); + locking rules: +- may block BKL +-get_sb yes no +-kill_sb yes no ++ may block ++get_sb yes ++mount yes ++kill_sb yes + + ->get_sb() returns error or 0 with locked superblock attached to the vfsmount + (exclusive on ->s_umount). ++->mount() returns ERR_PTR or the root dentry. + ->kill_sb() takes a write-locked superblock, does all shutdown work on it, + unlocks and drops the reference. + +@@ -176,27 +194,35 @@ prototypes: + void (*freepage)(struct page *); + int (*direct_IO)(int, struct kiocb *, const struct iovec *iov, + loff_t offset, unsigned long nr_segs); +- int (*launder_page) (struct page *); ++ int (*get_xip_mem)(struct address_space *, pgoff_t, int, void **, ++ unsigned long *); ++ int (*migratepage)(struct address_space *, struct page *, struct page *); ++ int (*launder_page)(struct page *); ++ int (*is_partially_uptodate)(struct page *, read_descriptor_t *, unsigned long); ++ int (*error_remove_page)(struct address_space *, struct page *); + + locking rules: + All except set_page_dirty and freepage may block + +- BKL PageLocked(page) i_mutex +-writepage: no yes, unlocks (see below) +-readpage: no yes, unlocks +-sync_page: no maybe +-writepages: no +-set_page_dirty no no +-readpages: no +-write_begin: no locks the page yes +-write_end: no yes, unlocks yes +-perform_write: no n/a yes +-bmap: no +-invalidatepage: no yes +-releasepage: no yes +-freepage: no yes +-direct_IO: no +-launder_page: no yes ++ PageLocked(page) i_mutex ++writepage: yes, unlocks (see below) ++readpage: yes, unlocks ++sync_page: maybe ++writepages: ++set_page_dirty no ++readpages: ++write_begin: locks the page yes ++write_end: yes, unlocks yes ++bmap: ++invalidatepage: yes ++releasepage: yes ++freepage: yes ++direct_IO: ++get_xip_mem: maybe ++migratepage: yes (both) ++launder_page: yes ++is_partially_uptodate: yes ++error_remove_page: yes + + ->write_begin(), ->write_end(), ->sync_page() and ->readpage() + may be called from the request handler (/dev/loop). +@@ -276,9 +302,8 @@ under spinlock (it cannot block) and is sometimes called with the page + not locked. + + ->bmap() is currently used by legacy ioctl() (FIBMAP) provided by some +-filesystems and by the swapper. The latter will eventually go away. All +-instances do not actually need the BKL. Please, keep it that way and don't +-breed new callers. ++filesystems and by the swapper. The latter will eventually go away. Please, ++keep it that way and don't breed new callers. + + ->invalidatepage() is called when the filesystem must attempt to drop + some or all of the buffers from the page when it is being truncated. It +@@ -299,47 +324,37 @@ cleaned, or an error value if not. Note that in order to prevent the page + getting mapped back in and redirtied, it needs to be kept locked + across the entire operation. + +- Note: currently almost all instances of address_space methods are +-using BKL for internal serialization and that's one of the worst sources +-of contention. Normally they are calling library functions (in fs/buffer.c) +-and pass foo_get_block() as a callback (on local block-based filesystems, +-indeed). BKL is not needed for library stuff and is usually taken by +-foo_get_block(). It's an overkill, since block bitmaps can be protected by +-internal fs locking and real critical areas are much smaller than the areas +-filesystems protect now. +- + ----------------------- file_lock_operations ------------------------------ + prototypes: +- void (*fl_insert)(struct file_lock *); /* lock insertion callback */ +- void (*fl_remove)(struct file_lock *); /* lock removal callback */ + void (*fl_copy_lock)(struct file_lock *, struct file_lock *); + void (*fl_release_private)(struct file_lock *); + + + locking rules: +- BKL may block +-fl_insert: yes no +-fl_remove: yes no +-fl_copy_lock: yes no +-fl_release_private: yes yes ++ file_lock_lock may block ++fl_copy_lock: yes no ++fl_release_private: maybe no + + ----------------------- lock_manager_operations --------------------------- + prototypes: + int (*fl_compare_owner)(struct file_lock *, struct file_lock *); + void (*fl_notify)(struct file_lock *); /* unblock callback */ ++ int (*fl_grant)(struct file_lock *, struct file_lock *, int); + void (*fl_release_private)(struct file_lock *); + void (*fl_break)(struct file_lock *); /* break_lease callback */ ++ int (*fl_mylease)(struct file_lock *, struct file_lock *); ++ int (*fl_change)(struct file_lock **, int); + + locking rules: +- BKL may block +-fl_compare_owner: yes no +-fl_notify: yes no +-fl_release_private: yes yes +-fl_break: yes no +- +- Currently only NFSD and NLM provide instances of this class. None of the +-them block. If you have out-of-tree instances - please, show up. Locking +-in that area will change. ++ file_lock_lock may block ++fl_compare_owner: yes no ++fl_notify: yes no ++fl_grant: no no ++fl_release_private: maybe no ++fl_break: yes no ++fl_mylease: yes no ++fl_change yes no ++ + --------------------------- buffer_head ----------------------------------- + prototypes: + void (*b_end_io)(struct buffer_head *bh, int uptodate); +@@ -364,17 +379,17 @@ prototypes: + void (*swap_slot_free_notify) (struct block_device *, unsigned long); + + locking rules: +- BKL bd_mutex +-open: no yes +-release: no yes +-ioctl: no no +-compat_ioctl: no no +-direct_access: no no +-media_changed: no no +-unlock_native_capacity: no no +-revalidate_disk: no no +-getgeo: no no +-swap_slot_free_notify: no no (see below) ++ bd_mutex ++open: yes ++release: yes ++ioctl: no ++compat_ioctl: no ++direct_access: no ++media_changed: no ++unlock_native_capacity: no ++revalidate_disk: no ++getgeo: no ++swap_slot_free_notify: no (see below) + + media_changed, unlock_native_capacity and revalidate_disk are called only from + check_disk_change(). +@@ -413,34 +428,21 @@ prototypes: + unsigned long (*get_unmapped_area)(struct file *, unsigned long, + unsigned long, unsigned long, unsigned long); + int (*check_flags)(int); ++ int (*flock) (struct file *, int, struct file_lock *); ++ ssize_t (*splice_write)(struct pipe_inode_info *, struct file *, loff_t *, ++ size_t, unsigned int); ++ ssize_t (*splice_read)(struct file *, loff_t *, struct pipe_inode_info *, ++ size_t, unsigned int); ++ int (*setlease)(struct file *, long, struct file_lock **); + }; + + locking rules: +- All may block. +- BKL +-llseek: no (see below) +-read: no +-aio_read: no +-write: no +-aio_write: no +-readdir: no +-poll: no +-unlocked_ioctl: no +-compat_ioctl: no +-mmap: no +-open: no +-flush: no +-release: no +-fsync: no (see below) +-aio_fsync: no +-fasync: no +-lock: yes +-readv: no +-writev: no +-sendfile: no +-sendpage: no +-get_unmapped_area: no +-check_flags: no ++ All may block except for ->setlease. ++ No VFS locks held on entry except for ->fsync and ->setlease. ++ ++->fsync() has i_mutex on inode. ++ ++->setlease has the file_list_lock held and must not sleep. + + ->llseek() locking has moved from llseek to the individual llseek + implementations. If your fs is not using generic_file_llseek, you +@@ -450,17 +452,10 @@ mutex or just to use i_size_read() instead. + Note: this does not protect the file->f_pos against concurrent modifications + since this is something the userspace has to take care about. + +-Note: ext2_release() was *the* source of contention on fs-intensive +-loads and dropping BKL on ->release() helps to get rid of that (we still +-grab BKL for cases when we close a file that had been opened r/w, but that +-can and should be done using the internal locking with smaller critical areas). +-Current worst offender is ext2_get_block()... +- +-->fasync() is called without BKL protection, and is responsible for +-maintaining the FASYNC bit in filp->f_flags. Most instances call +-fasync_helper(), which does that maintenance, so it's not normally +-something one needs to worry about. Return values > 0 will be mapped to +-zero in the VFS layer. ++->fasync() is responsible for maintaining the FASYNC bit in filp->f_flags. ++Most instances call fasync_helper(), which does that maintenance, so it's ++not normally something one needs to worry about. Return values > 0 will be ++mapped to zero in the VFS layer. + + ->readdir() and ->ioctl() on directories must be changed. Ideally we would + move ->readdir() to inode_operations and use a separate method for directory +@@ -471,8 +466,6 @@ components. And there are other reasons why the current interface is a mess... + ->read on directories probably must go away - we should just enforce -EISDIR + in sys_read() and friends. + +-->fsync() has i_mutex on inode. +- + --------------------------- dquot_operations ------------------------------- + prototypes: + int (*write_dquot) (struct dquot *); +@@ -507,12 +500,12 @@ prototypes: + int (*access)(struct vm_area_struct *, unsigned long, void*, int, int); + + locking rules: +- BKL mmap_sem PageLocked(page) +-open: no yes +-close: no yes +-fault: no yes can return with page locked +-page_mkwrite: no yes can return with page locked +-access: no yes ++ mmap_sem PageLocked(page) ++open: yes ++close: yes ++fault: yes can return with page locked ++page_mkwrite: yes can return with page locked ++access: yes + + ->fault() is called when a previously not present pte is about + to be faulted in. The filesystem must find and return the page associated +@@ -539,6 +532,3 @@ VM_IO | VM_PFNMAP VMAs. + + (if you break something or notice that it is broken and do not fix it yourself + - at least put it here) +- +-ipc/shm.c::shm_delete() - may need BKL. +-->read() and ->write() in many drivers are (probably) missing BKL. +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0036-memcg-fix-wrong-VM_BUG_ON-in-try_charge-s-mm-owner-c.patch b/recipes/linux/linux-omap-2.6.37/linus/0036-memcg-fix-wrong-VM_BUG_ON-in-try_charge-s-mm-owner-c.patch new file mode 100644 index 0000000000..d883d08f55 --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0036-memcg-fix-wrong-VM_BUG_ON-in-try_charge-s-mm-owner-c.patch @@ -0,0 +1,63 @@ +From ebb76ce16daf6908dc030dec1c00827d37129fe5 Mon Sep 17 00:00:00 2001 +From: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com> +Date: Wed, 29 Dec 2010 14:07:11 -0800 +Subject: [PATCH 36/66] memcg: fix wrong VM_BUG_ON() in try_charge()'s mm->owner check + +At __mem_cgroup_try_charge(), VM_BUG_ON(!mm->owner) is checked. +But as commented in mem_cgroup_from_task(), mm->owner can be NULL +in some racy case. This check of VM_BUG_ON() is bad. + +A possible story to hit this is at swapoff()->try_to_unuse(). It passes +mm_struct to mem_cgroup_try_charge_swapin() while mm->owner is NULL. If we +can't get proper mem_cgroup from swap_cgroup information, mm->owner is used +as charge target and we see NULL. + +Cc: Daisuke Nishimura <nishimura@mxp.nes.nec.co.jp> +Cc: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com> +Reported-by: Hugh Dickins <hughd@google.com> +Reported-by: Thomas Meyer <thomas@m3y3r.de> +Signed-off-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com> +Reviewed-by: Balbir Singh <balbir@linux.vnet.ibm.com> +Signed-off-by: Hugh Dickins <hughd@google.com> +Cc: stable@kernel.org +Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> +--- + mm/memcontrol.c | 19 +++++++++---------- + 1 files changed, 9 insertions(+), 10 deletions(-) + +diff --git a/mm/memcontrol.c b/mm/memcontrol.c +index 7a22b41..00bb8a6 100644 +--- a/mm/memcontrol.c ++++ b/mm/memcontrol.c +@@ -1925,19 +1925,18 @@ again: + + rcu_read_lock(); + p = rcu_dereference(mm->owner); +- VM_BUG_ON(!p); + /* +- * because we don't have task_lock(), "p" can exit while +- * we're here. In that case, "mem" can point to root +- * cgroup but never be NULL. (and task_struct itself is freed +- * by RCU, cgroup itself is RCU safe.) Then, we have small +- * risk here to get wrong cgroup. But such kind of mis-account +- * by race always happens because we don't have cgroup_mutex(). +- * It's overkill and we allow that small race, here. ++ * Because we don't have task_lock(), "p" can exit. ++ * In that case, "mem" can point to root or p can be NULL with ++ * race with swapoff. Then, we have small risk of mis-accouning. ++ * But such kind of mis-account by race always happens because ++ * we don't have cgroup_mutex(). It's overkill and we allo that ++ * small race, here. ++ * (*) swapoff at el will charge against mm-struct not against ++ * task-struct. So, mm->owner can be NULL. + */ + mem = mem_cgroup_from_task(p); +- VM_BUG_ON(!mem); +- if (mem_cgroup_is_root(mem)) { ++ if (!mem || mem_cgroup_is_root(mem)) { + rcu_read_unlock(); + goto done; + } +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0037-Revert-Staging-zram-work-around-oops-due-to-startup-.patch b/recipes/linux/linux-omap-2.6.37/linus/0037-Revert-Staging-zram-work-around-oops-due-to-startup-.patch new file mode 100644 index 0000000000..60dcf07e8a --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0037-Revert-Staging-zram-work-around-oops-due-to-startup-.patch @@ -0,0 +1,54 @@ +From e983dc2428164698571e1dd1b25c4322181adbac Mon Sep 17 00:00:00 2001 +From: Nitin Gupta <ngupta@vflare.org> +Date: Thu, 30 Dec 2010 04:07:58 -0500 +Subject: [PATCH 37/66] Revert "Staging: zram: work around oops due to startup ordering snafu" + +This reverts commit 7e24cce38a99f373450db67bf576fe73e8168d66 because it +was never appropriate for mainline. + +Do not check for init flag before starting I/O - zram module is unusable +without this fix. + +The oops mentioned in the reverted commit message was actually a problem +only with the zram version as present in project's own repository where +we allocate struct zram_stats_cpu upon device initialization. OTOH, In +mainline/staging version of zram, we allocate struct stats upfront, so +this oops cannot happen in mainline version. + +Checking for init_done flag in zram_make_request() results in a *no-op* +for any I/O operation since we simply always return success. This flag +is actually set when the first write occurs on a zram disk which +triggers its initialization. + +Bug report: https://bugzilla.kernel.org/show_bug.cgi?id=25722 + +Reported-by: Dennis Jansen <dennis.jansen@web.de> +Signed-off-by: Nitin Gupta <ngupta@vflare.org> +Cc: Anton Blanchard <anton@samba.org> +Cc: Andrew Morton <akpm@linux-foundation.org> +Cc: Greg Kroah-Hartman <gregkh@suse.de> +Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> +--- + drivers/staging/zram/zram_drv.c | 6 ------ + 1 files changed, 0 insertions(+), 6 deletions(-) + +diff --git a/drivers/staging/zram/zram_drv.c b/drivers/staging/zram/zram_drv.c +index 8c3c057..d0e9e02 100644 +--- a/drivers/staging/zram/zram_drv.c ++++ b/drivers/staging/zram/zram_drv.c +@@ -435,12 +435,6 @@ static int zram_make_request(struct request_queue *queue, struct bio *bio) + int ret = 0; + struct zram *zram = queue->queuedata; + +- if (unlikely(!zram->init_done)) { +- set_bit(BIO_UPTODATE, &bio->bi_flags); +- bio_endio(bio, 0); +- return 0; +- } +- + if (!valid_io_request(zram, bio)) { + zram_stat64_inc(zram, &zram->stats.invalid_io); + bio_io_error(bio); +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0038-CAN-Use-inode-instead-of-kernel-address-for-proc-fil.patch b/recipes/linux/linux-omap-2.6.37/linus/0038-CAN-Use-inode-instead-of-kernel-address-for-proc-fil.patch new file mode 100644 index 0000000000..41d0192d5a --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0038-CAN-Use-inode-instead-of-kernel-address-for-proc-fil.patch @@ -0,0 +1,43 @@ +From 9f260e0efa4766e56d0ac14f1aeea6ee5eb8fe83 Mon Sep 17 00:00:00 2001 +From: Dan Rosenberg <drosenberg@vsecurity.com> +Date: Sun, 26 Dec 2010 06:54:53 +0000 +Subject: [PATCH 38/66] CAN: Use inode instead of kernel address for /proc file + +Since the socket address is just being used as a unique identifier, its +inode number is an alternative that does not leak potentially sensitive +information. + +CC-ing stable because MITRE has assigned CVE-2010-4565 to the issue. + +Signed-off-by: Dan Rosenberg <drosenberg@vsecurity.com> +Acked-by: Oliver Hartkopp <socketcan@hartkopp.net> +Signed-off-by: David S. Miller <davem@davemloft.net> +--- + net/can/bcm.c | 4 ++-- + 1 files changed, 2 insertions(+), 2 deletions(-) + +diff --git a/net/can/bcm.c b/net/can/bcm.c +index 6faa825..9d5e8ac 100644 +--- a/net/can/bcm.c ++++ b/net/can/bcm.c +@@ -125,7 +125,7 @@ struct bcm_sock { + struct list_head tx_ops; + unsigned long dropped_usr_msgs; + struct proc_dir_entry *bcm_proc_read; +- char procname [20]; /* pointer printed in ASCII with \0 */ ++ char procname [32]; /* inode number in decimal with \0 */ + }; + + static inline struct bcm_sock *bcm_sk(const struct sock *sk) +@@ -1521,7 +1521,7 @@ static int bcm_connect(struct socket *sock, struct sockaddr *uaddr, int len, + + if (proc_dir) { + /* unique socket address as filename */ +- sprintf(bo->procname, "%p", sock); ++ sprintf(bo->procname, "%lu", sock_i_ino(sk)); + bo->bcm_proc_read = proc_create_data(bo->procname, 0644, + proc_dir, + &bcm_proc_fops, sk); +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0039-ISDN-Gigaset-Fix-memory-leak-in-do_disconnect_req.patch b/recipes/linux/linux-omap-2.6.37/linus/0039-ISDN-Gigaset-Fix-memory-leak-in-do_disconnect_req.patch new file mode 100644 index 0000000000..64f6d6605e --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0039-ISDN-Gigaset-Fix-memory-leak-in-do_disconnect_req.patch @@ -0,0 +1,56 @@ +From 2393c944d5d60eedaede80273ede8a816b5fa3e0 Mon Sep 17 00:00:00 2001 +From: Jesper Juhl <jj@chaosbits.net> +Date: Sun, 26 Dec 2010 09:59:58 +0000 +Subject: [PATCH 39/66] ISDN, Gigaset: Fix memory leak in do_disconnect_req() + +Hi, + +In drivers/isdn/gigaset/capi.c::do_disconnect_req() we will leak the +memory allocated (with kmalloc) to 'b3cmsg' if the call to alloc_skb() +fails. + +... + b3cmsg = kmalloc(sizeof(*b3cmsg), GFP_KERNEL); + allocation here ------^ + if (!b3cmsg) { + dev_err(cs->dev, "%s: out of memory\n", __func__); + send_conf(iif, ap, skb, CAPI_MSGOSRESOURCEERR); + return; + } + capi_cmsg_header(b3cmsg, ap->id, CAPI_DISCONNECT_B3, CAPI_IND, + ap->nextMessageNumber++, + cmsg->adr.adrPLCI | (1 << 16)); + b3cmsg->Reason_B3 = CapiProtocolErrorLayer1; + b3skb = alloc_skb(CAPI_DISCONNECT_B3_IND_BASELEN, GFP_KERNEL); + if (b3skb == NULL) { + dev_err(cs->dev, "%s: out of memory\n", __func__); + send_conf(iif, ap, skb, CAPI_MSGOSRESOURCEERR); + return; + leak here ------^ +... + +This leak is easily fixed by just kfree()'ing the memory allocated to +'b3cmsg' right before we return. The following patch does that. + +Signed-off-by: Jesper Juhl <jj@chaosbits.net> +Acked-by: Tilman Schmidt <tilman@imap.cc> +Signed-off-by: David S. Miller <davem@davemloft.net> +--- + drivers/isdn/gigaset/capi.c | 1 + + 1 files changed, 1 insertions(+), 0 deletions(-) + +diff --git a/drivers/isdn/gigaset/capi.c b/drivers/isdn/gigaset/capi.c +index bcc174e..658e75f 100644 +--- a/drivers/isdn/gigaset/capi.c ++++ b/drivers/isdn/gigaset/capi.c +@@ -1900,6 +1900,7 @@ static void do_disconnect_req(struct gigaset_capi_ctr *iif, + if (b3skb == NULL) { + dev_err(cs->dev, "%s: out of memory\n", __func__); + send_conf(iif, ap, skb, CAPI_MSGOSRESOURCEERR); ++ kfree(b3cmsg); + return; + } + capi_cmsg2message(b3cmsg, +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0040-Broadcom-CNIC-core-network-driver-fix-mem-leak-on-al.patch b/recipes/linux/linux-omap-2.6.37/linus/0040-Broadcom-CNIC-core-network-driver-fix-mem-leak-on-al.patch new file mode 100644 index 0000000000..3117d390c1 --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0040-Broadcom-CNIC-core-network-driver-fix-mem-leak-on-al.patch @@ -0,0 +1,58 @@ +From f7e4c9775ea648deed4a8193951e50d0c7706173 Mon Sep 17 00:00:00 2001 +From: Jesper Juhl <jj@chaosbits.net> +Date: Fri, 31 Dec 2010 11:18:48 -0800 +Subject: [PATCH 40/66] Broadcom CNIC core network driver: fix mem leak on allocation failures in cnic_alloc_uio_rings() + +We are leaking memory in drivers/net/cnic.c::cnic_alloc_uio_rings() if +either of the calls to dma_alloc_coherent() fail. This patch fixes it by +freeing both the memory allocated with kzalloc() and memory allocated with +previous calls to dma_alloc_coherent() when there's a failure. + +Thanks to Joe Perches <joe@perches.com> for suggesting a better +implementation than my initial version. + +Signed-off-by: Jesper Juhl <jj@chaosbits.net> +Acked-by: Michael Chan <mchan@broadcom.com> +Signed-off-by: David S. Miller <davem@davemloft.net> +--- + drivers/net/cnic.c | 10 ++++++++-- + 1 files changed, 8 insertions(+), 2 deletions(-) + +diff --git a/drivers/net/cnic.c b/drivers/net/cnic.c +index 92bac19..6dff321 100644 +--- a/drivers/net/cnic.c ++++ b/drivers/net/cnic.c +@@ -940,7 +940,7 @@ static int cnic_alloc_uio_rings(struct cnic_dev *dev, int pages) + &udev->l2_ring_map, + GFP_KERNEL | __GFP_COMP); + if (!udev->l2_ring) +- return -ENOMEM; ++ goto err_udev; + + udev->l2_buf_size = (cp->l2_rx_ring_size + 1) * cp->l2_single_buf_size; + udev->l2_buf_size = PAGE_ALIGN(udev->l2_buf_size); +@@ -948,7 +948,7 @@ static int cnic_alloc_uio_rings(struct cnic_dev *dev, int pages) + &udev->l2_buf_map, + GFP_KERNEL | __GFP_COMP); + if (!udev->l2_buf) +- return -ENOMEM; ++ goto err_dma; + + write_lock(&cnic_dev_lock); + list_add(&udev->list, &cnic_udev_list); +@@ -959,6 +959,12 @@ static int cnic_alloc_uio_rings(struct cnic_dev *dev, int pages) + cp->udev = udev; + + return 0; ++ err_dma: ++ dma_free_coherent(&udev->pdev->dev, udev->l2_ring_size, ++ udev->l2_ring, udev->l2_ring_map); ++ err_udev: ++ kfree(udev); ++ return -ENOMEM; + } + + static int cnic_init_uio(struct cnic_dev *dev) +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0041-tg3-fix-return-value-check-in-tg3_read_vpd.patch b/recipes/linux/linux-omap-2.6.37/linus/0041-tg3-fix-return-value-check-in-tg3_read_vpd.patch new file mode 100644 index 0000000000..5f93a97617 --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0041-tg3-fix-return-value-check-in-tg3_read_vpd.patch @@ -0,0 +1,35 @@ +From 824f5f38d3005c346a043dedcfe8b048b699b81a Mon Sep 17 00:00:00 2001 +From: David Sterba <dsterba@suse.cz> +Date: Wed, 29 Dec 2010 03:40:31 +0000 +Subject: [PATCH 41/66] tg3: fix return value check in tg3_read_vpd() + +Besides -ETIMEDOUT and -EINTR, pci_read_vpd may return other error +values like -ENODEV or -EINVAL which are ignored due to the buggy +check, but the data are not read from VPD anyway and this is checked +subsequently with at most 3 needless loop iterations. This does not +show up as a runtime bug. + +CC: Matt Carlson <mcarlson@broadcom.com> +CC: Michael Chan <mchan@broadcom.com> +Signed-off-by: David Sterba <dsterba@suse.cz> +Signed-off-by: David S. Miller <davem@davemloft.net> +--- + drivers/net/tg3.c | 2 +- + 1 files changed, 1 insertions(+), 1 deletions(-) + +diff --git a/drivers/net/tg3.c b/drivers/net/tg3.c +index 30ccbb6..6f97b7b 100644 +--- a/drivers/net/tg3.c ++++ b/drivers/net/tg3.c +@@ -12658,7 +12658,7 @@ static void __devinit tg3_read_vpd(struct tg3 *tp) + cnt = pci_read_vpd(tp->pdev, pos, + TG3_NVM_VPD_LEN - pos, + &vpd_data[pos]); +- if (cnt == -ETIMEDOUT || -EINTR) ++ if (cnt == -ETIMEDOUT || cnt == -EINTR) + cnt = 0; + else if (cnt < 0) + goto out_not_found; +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0042-starfire-Fix-dma_addr_t-size-test-for-MIPS.patch b/recipes/linux/linux-omap-2.6.37/linus/0042-starfire-Fix-dma_addr_t-size-test-for-MIPS.patch new file mode 100644 index 0000000000..3ed2eb8e9b --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0042-starfire-Fix-dma_addr_t-size-test-for-MIPS.patch @@ -0,0 +1,37 @@ +From f4d5900a99dbc354ef1ba384d445ff80ae4d77b4 Mon Sep 17 00:00:00 2001 +From: Ben Hutchings <ben@decadent.org.uk> +Date: Wed, 29 Dec 2010 04:26:17 +0000 +Subject: [PATCH 42/66] starfire: Fix dma_addr_t size test for MIPS + +Commit 56543af "starfire: use BUILD_BUG_ON for netdrv_addr_t" revealed +that the preprocessor condition used to find the size of dma_addr_t +yielded the wrong result for some architectures and configurations. +This was kluged for 64-bit PowerPC in commit 3e502e6 by adding yet +another case to the condition. However, 64-bit MIPS configurations +are not detected reliably either. + +This should be fixed by using CONFIG_ARCH_DMA_ADDR_T_64BIT, but that +isn't yet defined everywhere it should be. + +Signed-off-by: Ben Hutchings <ben@decadent.org.uk> +Signed-off-by: David S. Miller <davem@davemloft.net> +--- + drivers/net/starfire.c | 2 +- + 1 files changed, 1 insertions(+), 1 deletions(-) + +diff --git a/drivers/net/starfire.c b/drivers/net/starfire.c +index 4adf124..a4f2bd5 100644 +--- a/drivers/net/starfire.c ++++ b/drivers/net/starfire.c +@@ -148,7 +148,7 @@ static int full_duplex[MAX_UNITS] = {0, }; + * This SUCKS. + * We need a much better method to determine if dma_addr_t is 64-bit. + */ +-#if (defined(__i386__) && defined(CONFIG_HIGHMEM64G)) || defined(__x86_64__) || defined (__ia64__) || defined(__alpha__) || defined(__mips64__) || (defined(__mips__) && defined(CONFIG_HIGHMEM) && defined(CONFIG_64BIT_PHYS_ADDR)) || (defined(__powerpc64__) || defined(CONFIG_PHYS_64BIT)) ++#if (defined(__i386__) && defined(CONFIG_HIGHMEM64G)) || defined(__x86_64__) || defined (__ia64__) || defined(__alpha__) || (defined(CONFIG_MIPS) && ((defined(CONFIG_HIGHMEM) && defined(CONFIG_64BIT_PHYS_ADDR)) || defined(CONFIG_64BIT))) || (defined(__powerpc64__) || defined(CONFIG_PHYS_64BIT)) + /* 64-bit dma_addr_t */ + #define ADDR_64BITS /* This chip uses 64 bit addresses. */ + #define netdrv_addr_t __le64 +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0043-drivers-atm-atmtcp.c-add-missing-atm_dev_put.patch b/recipes/linux/linux-omap-2.6.37/linus/0043-drivers-atm-atmtcp.c-add-missing-atm_dev_put.patch new file mode 100644 index 0000000000..b989cd3c06 --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0043-drivers-atm-atmtcp.c-add-missing-atm_dev_put.patch @@ -0,0 +1,50 @@ +From b9556f9a1abdc56a179ac7ba6053469373b6de0f Mon Sep 17 00:00:00 2001 +From: Julia Lawall <julia@diku.dk> +Date: Wed, 29 Dec 2010 04:01:03 +0000 +Subject: [PATCH 43/66] drivers/atm/atmtcp.c: add missing atm_dev_put + +The earlier call to atm_dev_lookup increases the reference count of dev, +so decrease it on the way out. + +The semantic match that finds this problem is as follows: +(http://coccinelle.lip6.fr/) + +// <smpl> +@@ +expression x, E; +constant C; +@@ + +x = atm_dev_lookup(...); +... when != false x != NULL + when != true x == NULL + when != \(E = x\|x = E\) + when != atm_dev_put(dev); +*return -C; +// </smpl> + +Signed-off-by: Julia Lawall <julia@diku.dk> +Signed-off-by: David S. Miller <davem@davemloft.net> +--- + drivers/atm/atmtcp.c | 5 ++++- + 1 files changed, 4 insertions(+), 1 deletions(-) + +diff --git a/drivers/atm/atmtcp.c b/drivers/atm/atmtcp.c +index 2b464b6..0b06250 100644 +--- a/drivers/atm/atmtcp.c ++++ b/drivers/atm/atmtcp.c +@@ -392,7 +392,10 @@ static int atmtcp_attach(struct atm_vcc *vcc,int itf) + atm_dev_put(dev); + return -EMEDIUMTYPE; + } +- if (PRIV(dev)->vcc) return -EBUSY; ++ if (PRIV(dev)->vcc) { ++ atm_dev_put(dev); ++ return -EBUSY; ++ } + } + else { + int error; +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0044-KVM-i8259-initialize-isr_ack.patch b/recipes/linux/linux-omap-2.6.37/linus/0044-KVM-i8259-initialize-isr_ack.patch new file mode 100644 index 0000000000..c491d36562 --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0044-KVM-i8259-initialize-isr_ack.patch @@ -0,0 +1,32 @@ +From d0dfc6b74a0c6e9ee46b62713256e2b025244d3c Mon Sep 17 00:00:00 2001 +From: Avi Kivity <avi@redhat.com> +Date: Fri, 31 Dec 2010 10:52:15 +0200 +Subject: [PATCH 44/66] KVM: i8259: initialize isr_ack + +isr_ack is never initialized. So, until the first PIC reset, interrupts +may fail to be injected. This can cause Windows XP to fail to boot, as +reported in the fallout from the fix to +https://bugzilla.kernel.org/show_bug.cgi?id=21962. + +Reported-and-tested-by: Nicolas Prochazka <prochazka.nicolas@gmail.com> +Signed-off-by: Avi Kivity <avi@redhat.com> +--- + arch/x86/kvm/i8259.c | 2 ++ + 1 files changed, 2 insertions(+), 0 deletions(-) + +diff --git a/arch/x86/kvm/i8259.c b/arch/x86/kvm/i8259.c +index f628234..3cece05 100644 +--- a/arch/x86/kvm/i8259.c ++++ b/arch/x86/kvm/i8259.c +@@ -575,6 +575,8 @@ struct kvm_pic *kvm_create_pic(struct kvm *kvm) + s->pics[1].elcr_mask = 0xde; + s->pics[0].pics_state = s; + s->pics[1].pics_state = s; ++ s->pics[0].isr_ack = 0xff; ++ s->pics[1].isr_ack = 0xff; + + /* + * Initialize PIO device +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0045-hwmon-s3c-hwmon-Fix-compilation.patch b/recipes/linux/linux-omap-2.6.37/linus/0045-hwmon-s3c-hwmon-Fix-compilation.patch new file mode 100644 index 0000000000..820ec792fa --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0045-hwmon-s3c-hwmon-Fix-compilation.patch @@ -0,0 +1,37 @@ +From b518a64983cbf2ff31aed530898de2d80e4573d5 Mon Sep 17 00:00:00 2001 +From: Maurus Cuelenaere <mcuelenaere@gmail.com> +Date: Sun, 2 Jan 2011 14:48:16 -0500 +Subject: [PATCH 45/66] hwmon: (s3c-hwmon) Fix compilation + +The owner field was removed from struct attribute in +6fd69dc578fa0b1bbc3aad70ae3af9a137211707, so don't assign it anymore. + +Signed-off-by: Maurus Cuelenaere <mcuelenaere@gmail.com> +Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com> +--- + drivers/hwmon/s3c-hwmon.c | 2 -- + 1 files changed, 0 insertions(+), 2 deletions(-) + +diff --git a/drivers/hwmon/s3c-hwmon.c b/drivers/hwmon/s3c-hwmon.c +index 05248f2..92b42db 100644 +--- a/drivers/hwmon/s3c-hwmon.c ++++ b/drivers/hwmon/s3c-hwmon.c +@@ -234,7 +234,6 @@ static int s3c_hwmon_create_attr(struct device *dev, + attr->index = channel; + attr->dev_attr.attr.name = attrs->in_name; + attr->dev_attr.attr.mode = S_IRUGO; +- attr->dev_attr.attr.owner = THIS_MODULE; + attr->dev_attr.show = s3c_hwmon_ch_show; + + ret = device_create_file(dev, &attr->dev_attr); +@@ -252,7 +251,6 @@ static int s3c_hwmon_create_attr(struct device *dev, + attr->index = channel; + attr->dev_attr.attr.name = attrs->label_name; + attr->dev_attr.attr.mode = S_IRUGO; +- attr->dev_attr.attr.owner = THIS_MODULE; + attr->dev_attr.show = s3c_hwmon_label_show; + + ret = device_create_file(dev, &attr->dev_attr); +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0046-watchdog-Improve-initialisation-error-message-and-do.patch b/recipes/linux/linux-omap-2.6.37/linus/0046-watchdog-Improve-initialisation-error-message-and-do.patch new file mode 100644 index 0000000000..c07fa41c49 --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0046-watchdog-Improve-initialisation-error-message-and-do.patch @@ -0,0 +1,58 @@ +From 551423748a4eba55f2eb0fc250d757986471f187 Mon Sep 17 00:00:00 2001 +From: Ben Hutchings <ben@decadent.org.uk> +Date: Sun, 2 Jan 2011 23:02:42 +0000 +Subject: [PATCH 46/66] watchdog: Improve initialisation error message and documentation + +The error message 'NMI watchdog failed to create perf event...' +does not make it clear that this is a fatal error for the +watchdog. It also currently prints the error value as a +pointer, rather than extracting the error code with PTR_ERR(). +Fix that. + +Add a note to the description of the 'nowatchdog' kernel +parameter to associate it with this message. + +Reported-by: Cesare Leonardi <celeonar@gmail.com> +Signed-off-by: Ben Hutchings <ben@decadent.org.uk> +Cc: 599368@bugs.debian.org +Cc: 608138@bugs.debian.org +Cc: Don Zickus <dzickus@redhat.com> +Cc: Frederic Weisbecker <fweisbec@gmail.com> +Cc: <stable@kernel.org> # .37.x and later +LKML-Reference: <1294009362.3167.126.camel@localhost> +Signed-off-by: Ingo Molnar <mingo@elte.hu> +--- + Documentation/kernel-parameters.txt | 2 +- + kernel/watchdog.c | 3 ++- + 2 files changed, 3 insertions(+), 2 deletions(-) + +diff --git a/Documentation/kernel-parameters.txt b/Documentation/kernel-parameters.txt +index 8b61c93..01ece1b 100644 +--- a/Documentation/kernel-parameters.txt ++++ b/Documentation/kernel-parameters.txt +@@ -1759,7 +1759,7 @@ and is between 256 and 4096 characters. It is defined in the file + + nousb [USB] Disable the USB subsystem + +- nowatchdog [KNL] Disable the lockup detector. ++ nowatchdog [KNL] Disable the lockup detector (NMI watchdog). + + nowb [ARM] + +diff --git a/kernel/watchdog.c b/kernel/watchdog.c +index 6e3c41a..5b08215 100644 +--- a/kernel/watchdog.c ++++ b/kernel/watchdog.c +@@ -364,7 +364,8 @@ static int watchdog_nmi_enable(int cpu) + goto out_save; + } + +- printk(KERN_ERR "NMI watchdog failed to create perf event on cpu%i: %p\n", cpu, event); ++ printk(KERN_ERR "NMI watchdog disabled for cpu%i: unable to create perf event: %ld\n", ++ cpu, PTR_ERR(event)); + return PTR_ERR(event); + + /* success path */ +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0047-ARM-6605-1-Add-missing-include-asm-memory.h.patch b/recipes/linux/linux-omap-2.6.37/linus/0047-ARM-6605-1-Add-missing-include-asm-memory.h.patch new file mode 100644 index 0000000000..bd1e892d2c --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0047-ARM-6605-1-Add-missing-include-asm-memory.h.patch @@ -0,0 +1,42 @@ +From 7c0ab43e6ab09d72dc8dbac2521b2f819ccc4026 Mon Sep 17 00:00:00 2001 +From: Axel Lin <axel.lin@gmail.com> +Date: Mon, 3 Jan 2011 02:26:53 +0100 +Subject: [PATCH 47/66] ARM: 6605/1: Add missing include "asm/memory.h" + +This patch fixes below build error by adding the missing asm/memory.h, +which is needed for arch_is_coherent(). + +$ make pxa3xx_defconfig; make + CC init/do_mounts_rd.o +In file included from include/linux/list_bl.h:5, + from include/linux/rculist_bl.h:7, + from include/linux/dcache.h:7, + from include/linux/fs.h:381, + from init/do_mounts_rd.c:3: +include/linux/bit_spinlock.h: In function 'bit_spin_unlock': +include/linux/bit_spinlock.h:61: error: implicit declaration of function 'arch_is_coherent' +make[1]: *** [init/do_mounts_rd.o] Error 1 +make: *** [init] Error 2 + +Signed-off-by: Axel Lin <axel.lin@gmail.com> +Acked-by: Peter Huewe <peterhuewe@gmx.de> +Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk> +--- + arch/arm/include/asm/system.h | 1 + + 1 files changed, 1 insertions(+), 0 deletions(-) + +diff --git a/arch/arm/include/asm/system.h b/arch/arm/include/asm/system.h +index 1120f18..8002594 100644 +--- a/arch/arm/include/asm/system.h ++++ b/arch/arm/include/asm/system.h +@@ -150,6 +150,7 @@ extern unsigned int user_debug; + #define rmb() dmb() + #define wmb() mb() + #else ++#include <asm/memory.h> + #define mb() do { if (arch_is_coherent()) dmb(); else barrier(); } while (0) + #define rmb() do { if (arch_is_coherent()) dmb(); else barrier(); } while (0) + #define wmb() do { if (arch_is_coherent()) dmb(); else barrier(); } while (0) +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0048-mv_xor-fix-race-in-tasklet-function.patch b/recipes/linux/linux-omap-2.6.37/linus/0048-mv_xor-fix-race-in-tasklet-function.patch new file mode 100644 index 0000000000..db13a16408 --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0048-mv_xor-fix-race-in-tasklet-function.patch @@ -0,0 +1,31 @@ +From 8333f65ef094e47020cd01452b4637e7daf5a77f Mon Sep 17 00:00:00 2001 +From: Saeed Bishara <saeed@marvell.com> +Date: Tue, 21 Dec 2010 16:53:39 +0200 +Subject: [PATCH 48/66] mv_xor: fix race in tasklet function + +use mv_xor_slot_cleanup() instead of __mv_xor_slot_cleanup() as the former function +aquires the spin lock that needed to protect the drivers data. + +Cc: <stable@kernel.org> +Signed-off-by: Saeed Bishara <saeed@marvell.com> +Signed-off-by: Dan Williams <dan.j.williams@intel.com> +--- + drivers/dma/mv_xor.c | 2 +- + 1 files changed, 1 insertions(+), 1 deletions(-) + +diff --git a/drivers/dma/mv_xor.c b/drivers/dma/mv_xor.c +index 411d5bf..a25f5f6 100644 +--- a/drivers/dma/mv_xor.c ++++ b/drivers/dma/mv_xor.c +@@ -449,7 +449,7 @@ mv_xor_slot_cleanup(struct mv_xor_chan *mv_chan) + static void mv_xor_tasklet(unsigned long data) + { + struct mv_xor_chan *chan = (struct mv_xor_chan *) data; +- __mv_xor_slot_cleanup(chan); ++ mv_xor_slot_cleanup(chan); + } + + static struct mv_xor_desc_slot * +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0049-dmaengine-provide-dummy-functions-for-DMA_ENGINE-n.patch b/recipes/linux/linux-omap-2.6.37/linus/0049-dmaengine-provide-dummy-functions-for-DMA_ENGINE-n.patch new file mode 100644 index 0000000000..442c5a1672 --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0049-dmaengine-provide-dummy-functions-for-DMA_ENGINE-n.patch @@ -0,0 +1,55 @@ +From 8f33d5277fada0291ea495f7fd44a3e7b7aa41d3 Mon Sep 17 00:00:00 2001 +From: Guennadi Liakhovetski <g.liakhovetski@gmx.de> +Date: Wed, 22 Dec 2010 14:46:46 +0100 +Subject: [PATCH 49/66] dmaengine: provide dummy functions for DMA_ENGINE=n + +This lets drivers, optionally using the dmaengine, build with DMA_ENGINE +unselected. + +Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> +Signed-off-by: Dan Williams <dan.j.williams@intel.com> +--- + include/linux/dmaengine.h | 13 ++++++++++--- + 1 files changed, 10 insertions(+), 3 deletions(-) + +diff --git a/include/linux/dmaengine.h b/include/linux/dmaengine.h +index 9d8688b..8cd00ad 100644 +--- a/include/linux/dmaengine.h ++++ b/include/linux/dmaengine.h +@@ -824,6 +824,8 @@ enum dma_status dma_sync_wait(struct dma_chan *chan, dma_cookie_t cookie); + #ifdef CONFIG_DMA_ENGINE + enum dma_status dma_wait_for_async_tx(struct dma_async_tx_descriptor *tx); + void dma_issue_pending_all(void); ++struct dma_chan *__dma_request_channel(dma_cap_mask_t *mask, dma_filter_fn fn, void *fn_param); ++void dma_release_channel(struct dma_chan *chan); + #else + static inline enum dma_status dma_wait_for_async_tx(struct dma_async_tx_descriptor *tx) + { +@@ -831,7 +833,14 @@ static inline enum dma_status dma_wait_for_async_tx(struct dma_async_tx_descript + } + static inline void dma_issue_pending_all(void) + { +- do { } while (0); ++} ++static inline struct dma_chan *__dma_request_channel(dma_cap_mask_t *mask, ++ dma_filter_fn fn, void *fn_param) ++{ ++ return NULL; ++} ++static inline void dma_release_channel(struct dma_chan *chan) ++{ + } + #endif + +@@ -842,8 +851,6 @@ void dma_async_device_unregister(struct dma_device *device); + void dma_run_dependencies(struct dma_async_tx_descriptor *tx); + struct dma_chan *dma_find_channel(enum dma_transaction_type tx_type); + #define dma_request_channel(mask, x, y) __dma_request_channel(&(mask), x, y) +-struct dma_chan *__dma_request_channel(dma_cap_mask_t *mask, dma_filter_fn fn, void *fn_param); +-void dma_release_channel(struct dma_chan *chan); + + /* --- Helper iov-locking functions --- */ + +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0050-media-cx25840-Prevent-device-probe-failure-due-to-vo.patch b/recipes/linux/linux-omap-2.6.37/linus/0050-media-cx25840-Prevent-device-probe-failure-due-to-vo.patch new file mode 100644 index 0000000000..115575aa7f --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0050-media-cx25840-Prevent-device-probe-failure-due-to-vo.patch @@ -0,0 +1,52 @@ +From f23b7952d37c69c0caa6c8dfb85dbf2eb9e5fcaa Mon Sep 17 00:00:00 2001 +From: Andy Walls <awalls@md.metrocast.net> +Date: Sun, 5 Dec 2010 19:42:30 -0300 +Subject: [PATCH 50/66] [media] cx25840: Prevent device probe failure due to volume control ERANGE error + +This patch fixes a regression that crept into 2.6.36. + +The volume control scale in the cx25840 driver has an unusual mapping +from register values to v4l2 volume control values. Enforce the mapping +limits, so that the default volume control setting does not fall out of +bounds to prevent the cx25840 module device probe from failing. + +Signed-off-by: Andy Walls <awalls@md.metrocast.net> +Cc: Hans Verkuil <hverkuil@xs4all.nl> +Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com> +--- + drivers/media/video/cx25840/cx25840-core.c | 19 +++++++++++++++++-- + 1 files changed, 17 insertions(+), 2 deletions(-) + +diff --git a/drivers/media/video/cx25840/cx25840-core.c b/drivers/media/video/cx25840/cx25840-core.c +index dfb198d..f164618 100644 +--- a/drivers/media/video/cx25840/cx25840-core.c ++++ b/drivers/media/video/cx25840/cx25840-core.c +@@ -1989,8 +1989,23 @@ static int cx25840_probe(struct i2c_client *client, + v4l2_ctrl_new_std(&state->hdl, &cx25840_ctrl_ops, + V4L2_CID_HUE, -128, 127, 1, 0); + if (!is_cx2583x(state)) { +- default_volume = 228 - cx25840_read(client, 0x8d4); +- default_volume = ((default_volume / 2) + 23) << 9; ++ default_volume = cx25840_read(client, 0x8d4); ++ /* ++ * Enforce the legacy PVR-350/MSP3400 to PVR-150/CX25843 volume ++ * scale mapping limits to avoid -ERANGE errors when ++ * initializing the volume control ++ */ ++ if (default_volume > 228) { ++ /* Bottom out at -96 dB, v4l2 vol range 0x2e00-0x2fff */ ++ default_volume = 228; ++ cx25840_write(client, 0x8d4, 228); ++ } ++ else if (default_volume < 20) { ++ /* Top out at + 8 dB, v4l2 vol range 0xfe00-0xffff */ ++ default_volume = 20; ++ cx25840_write(client, 0x8d4, 20); ++ } ++ default_volume = (((228 - default_volume) >> 1) + 23) << 9; + + state->volume = v4l2_ctrl_new_std(&state->hdl, + &cx25840_audio_ctrl_ops, V4L2_CID_AUDIO_VOLUME, +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0051-media-wm8775-Revert-changeset-fcb9757333-to-avoid-a-.patch b/recipes/linux/linux-omap-2.6.37/linus/0051-media-wm8775-Revert-changeset-fcb9757333-to-avoid-a-.patch new file mode 100644 index 0000000000..7d88bb0c65 --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0051-media-wm8775-Revert-changeset-fcb9757333-to-avoid-a-.patch @@ -0,0 +1,518 @@ +From 46e67acd5d4cacda758e871eebd15cef4e2c2665 Mon Sep 17 00:00:00 2001 +From: Mauro Carvalho Chehab <mchehab@redhat.com> +Date: Mon, 3 Jan 2011 09:09:56 -0200 +Subject: [PATCH 51/66] [media] wm8775: Revert changeset fcb9757333 to avoid a regression + +It seems that cx88 and ivtv use wm8775 on some different modes. The +patch that added support for a board with wm8775 broke ivtv boards with +this device. As we're too close to release 2.6.37, let's just revert +it. + +Reported-by: Andy Walls <awalls@md.metrocast.net> +Reported-by: Eric Sharkey <eric@lisaneric.org> +Reported-by: Auric <auric@aanet.com.au> +Reported by: David Gesswein <djg@pdp8online.com> +Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com> +--- + drivers/media/video/cx88/cx88-alsa.c | 99 ++++--------------------------- + drivers/media/video/cx88/cx88-cards.c | 7 ++ + drivers/media/video/cx88/cx88-video.c | 27 +-------- + drivers/media/video/cx88/cx88.h | 6 +- + drivers/media/video/wm8775.c | 104 ++++++++++++-------------------- + include/media/wm8775.h | 3 - + 6 files changed, 61 insertions(+), 185 deletions(-) + +diff --git a/drivers/media/video/cx88/cx88-alsa.c b/drivers/media/video/cx88/cx88-alsa.c +index 4aaa47c..54b7fcd 100644 +--- a/drivers/media/video/cx88/cx88-alsa.c ++++ b/drivers/media/video/cx88/cx88-alsa.c +@@ -40,7 +40,6 @@ + #include <sound/control.h> + #include <sound/initval.h> + #include <sound/tlv.h> +-#include <media/wm8775.h> + + #include "cx88.h" + #include "cx88-reg.h" +@@ -587,47 +586,26 @@ static int snd_cx88_volume_put(struct snd_kcontrol *kcontrol, + int left, right, v, b; + int changed = 0; + u32 old; +- struct v4l2_control client_ctl; +- +- /* Pass volume & balance onto any WM8775 */ +- if (value->value.integer.value[0] >= value->value.integer.value[1]) { +- v = value->value.integer.value[0] << 10; +- b = value->value.integer.value[0] ? +- (0x8000 * value->value.integer.value[1]) / value->value.integer.value[0] : +- 0x8000; +- } else { +- v = value->value.integer.value[1] << 10; +- b = value->value.integer.value[1] ? +- 0xffff - (0x8000 * value->value.integer.value[0]) / value->value.integer.value[1] : +- 0x8000; +- } +- client_ctl.value = v; +- client_ctl.id = V4L2_CID_AUDIO_VOLUME; +- call_hw(core, WM8775_GID, core, s_ctrl, &client_ctl); +- +- client_ctl.value = b; +- client_ctl.id = V4L2_CID_AUDIO_BALANCE; +- call_hw(core, WM8775_GID, core, s_ctrl, &client_ctl); + + left = value->value.integer.value[0] & 0x3f; + right = value->value.integer.value[1] & 0x3f; + b = right - left; + if (b < 0) { +- v = 0x3f - left; +- b = (-b) | 0x40; ++ v = 0x3f - left; ++ b = (-b) | 0x40; + } else { +- v = 0x3f - right; ++ v = 0x3f - right; + } + /* Do we really know this will always be called with IRQs on? */ + spin_lock_irq(&chip->reg_lock); + old = cx_read(AUD_VOL_CTL); + if (v != (old & 0x3f)) { +- cx_swrite(SHADOW_AUD_VOL_CTL, AUD_VOL_CTL, (old & ~0x3f) | v); +- changed = 1; ++ cx_write(AUD_VOL_CTL, (old & ~0x3f) | v); ++ changed = 1; + } +- if ((cx_read(AUD_BAL_CTL) & 0x7f) != b) { +- cx_write(AUD_BAL_CTL, b); +- changed = 1; ++ if (cx_read(AUD_BAL_CTL) != b) { ++ cx_write(AUD_BAL_CTL, b); ++ changed = 1; + } + spin_unlock_irq(&chip->reg_lock); + +@@ -640,7 +618,7 @@ static const struct snd_kcontrol_new snd_cx88_volume = { + .iface = SNDRV_CTL_ELEM_IFACE_MIXER, + .access = SNDRV_CTL_ELEM_ACCESS_READWRITE | + SNDRV_CTL_ELEM_ACCESS_TLV_READ, +- .name = "Analog-TV Volume", ++ .name = "Playback Volume", + .info = snd_cx88_volume_info, + .get = snd_cx88_volume_get, + .put = snd_cx88_volume_put, +@@ -671,14 +649,7 @@ static int snd_cx88_switch_put(struct snd_kcontrol *kcontrol, + vol = cx_read(AUD_VOL_CTL); + if (value->value.integer.value[0] != !(vol & bit)) { + vol ^= bit; +- cx_swrite(SHADOW_AUD_VOL_CTL, AUD_VOL_CTL, vol); +- /* Pass mute onto any WM8775 */ +- if ((1<<6) == bit) { +- struct v4l2_control client_ctl; +- client_ctl.value = 0 != (vol & bit); +- client_ctl.id = V4L2_CID_AUDIO_MUTE; +- call_hw(core, WM8775_GID, core, s_ctrl, &client_ctl); +- } ++ cx_write(AUD_VOL_CTL, vol); + ret = 1; + } + spin_unlock_irq(&chip->reg_lock); +@@ -687,7 +658,7 @@ static int snd_cx88_switch_put(struct snd_kcontrol *kcontrol, + + static const struct snd_kcontrol_new snd_cx88_dac_switch = { + .iface = SNDRV_CTL_ELEM_IFACE_MIXER, +- .name = "Audio-Out Switch", ++ .name = "Playback Switch", + .info = snd_ctl_boolean_mono_info, + .get = snd_cx88_switch_get, + .put = snd_cx88_switch_put, +@@ -696,49 +667,13 @@ static const struct snd_kcontrol_new snd_cx88_dac_switch = { + + static const struct snd_kcontrol_new snd_cx88_source_switch = { + .iface = SNDRV_CTL_ELEM_IFACE_MIXER, +- .name = "Analog-TV Switch", ++ .name = "Capture Switch", + .info = snd_ctl_boolean_mono_info, + .get = snd_cx88_switch_get, + .put = snd_cx88_switch_put, + .private_value = (1<<6), + }; + +-static int snd_cx88_alc_get(struct snd_kcontrol *kcontrol, +- struct snd_ctl_elem_value *value) +-{ +- snd_cx88_card_t *chip = snd_kcontrol_chip(kcontrol); +- struct cx88_core *core = chip->core; +- struct v4l2_control client_ctl; +- +- client_ctl.id = V4L2_CID_AUDIO_LOUDNESS; +- call_hw(core, WM8775_GID, core, g_ctrl, &client_ctl); +- value->value.integer.value[0] = client_ctl.value ? 1 : 0; +- +- return 0; +-} +- +-static int snd_cx88_alc_put(struct snd_kcontrol *kcontrol, +- struct snd_ctl_elem_value *value) +-{ +- snd_cx88_card_t *chip = snd_kcontrol_chip(kcontrol); +- struct cx88_core *core = chip->core; +- struct v4l2_control client_ctl; +- +- client_ctl.value = 0 != value->value.integer.value[0]; +- client_ctl.id = V4L2_CID_AUDIO_LOUDNESS; +- call_hw(core, WM8775_GID, core, s_ctrl, &client_ctl); +- +- return 0; +-} +- +-static struct snd_kcontrol_new snd_cx88_alc_switch = { +- .iface = SNDRV_CTL_ELEM_IFACE_MIXER, +- .name = "Line-In ALC Switch", +- .info = snd_ctl_boolean_mono_info, +- .get = snd_cx88_alc_get, +- .put = snd_cx88_alc_put, +-}; +- + /**************************************************************************** + Basic Flow for Sound Devices + ****************************************************************************/ +@@ -860,7 +795,6 @@ static int __devinit cx88_audio_initdev(struct pci_dev *pci, + { + struct snd_card *card; + snd_cx88_card_t *chip; +- struct v4l2_subdev *sd; + int err; + + if (devno >= SNDRV_CARDS) +@@ -896,15 +830,6 @@ static int __devinit cx88_audio_initdev(struct pci_dev *pci, + if (err < 0) + goto error; + +- /* If there's a wm8775 then add a Line-In ALC switch */ +- list_for_each_entry(sd, &chip->core->v4l2_dev.subdevs, list) { +- if (WM8775_GID == sd->grp_id) { +- snd_ctl_add(card, snd_ctl_new1(&snd_cx88_alc_switch, +- chip)); +- break; +- } +- } +- + strcpy (card->driver, "CX88x"); + sprintf(card->shortname, "Conexant CX%x", pci->device); + sprintf(card->longname, "%s at %#llx", +diff --git a/drivers/media/video/cx88/cx88-cards.c b/drivers/media/video/cx88/cx88-cards.c +index 9b9e169..0ccc2af 100644 +--- a/drivers/media/video/cx88/cx88-cards.c ++++ b/drivers/media/video/cx88/cx88-cards.c +@@ -1007,15 +1007,22 @@ static const struct cx88_board cx88_boards[] = { + .radio_type = UNSET, + .tuner_addr = ADDR_UNSET, + .radio_addr = ADDR_UNSET, ++ .audio_chip = V4L2_IDENT_WM8775, + .input = {{ + .type = CX88_VMUX_DVB, + .vmux = 0, ++ /* 2: Line-In */ ++ .audioroute = 2, + },{ + .type = CX88_VMUX_COMPOSITE1, + .vmux = 1, ++ /* 2: Line-In */ ++ .audioroute = 2, + },{ + .type = CX88_VMUX_SVIDEO, + .vmux = 2, ++ /* 2: Line-In */ ++ .audioroute = 2, + }}, + .mpeg = CX88_MPEG_DVB, + }, +diff --git a/drivers/media/video/cx88/cx88-video.c b/drivers/media/video/cx88/cx88-video.c +index 62cea95..d9249e5 100644 +--- a/drivers/media/video/cx88/cx88-video.c ++++ b/drivers/media/video/cx88/cx88-video.c +@@ -40,7 +40,6 @@ + #include "cx88.h" + #include <media/v4l2-common.h> + #include <media/v4l2-ioctl.h> +-#include <media/wm8775.h> + + MODULE_DESCRIPTION("v4l2 driver module for cx2388x based TV cards"); + MODULE_AUTHOR("Gerd Knorr <kraxel@bytesex.org> [SuSE Labs]"); +@@ -977,7 +976,6 @@ int cx88_set_control(struct cx88_core *core, struct v4l2_control *ctl) + const struct cx88_ctrl *c = NULL; + u32 value,mask; + int i; +- struct v4l2_control client_ctl; + + for (i = 0; i < CX8800_CTLS; i++) { + if (cx8800_ctls[i].v.id == ctl->id) { +@@ -991,27 +989,6 @@ int cx88_set_control(struct cx88_core *core, struct v4l2_control *ctl) + ctl->value = c->v.minimum; + if (ctl->value > c->v.maximum) + ctl->value = c->v.maximum; +- +- /* Pass changes onto any WM8775 */ +- client_ctl.id = ctl->id; +- switch (ctl->id) { +- case V4L2_CID_AUDIO_MUTE: +- client_ctl.value = ctl->value; +- break; +- case V4L2_CID_AUDIO_VOLUME: +- client_ctl.value = (ctl->value) ? +- (0x90 + ctl->value) << 8 : 0; +- break; +- case V4L2_CID_AUDIO_BALANCE: +- client_ctl.value = ctl->value << 9; +- break; +- default: +- client_ctl.id = 0; +- break; +- } +- if (client_ctl.id) +- call_hw(core, WM8775_GID, core, s_ctrl, &client_ctl); +- + mask=c->mask; + switch (ctl->id) { + case V4L2_CID_AUDIO_BALANCE: +@@ -1558,9 +1535,7 @@ static int radio_queryctrl (struct file *file, void *priv, + if (c->id < V4L2_CID_BASE || + c->id >= V4L2_CID_LASTP1) + return -EINVAL; +- if (c->id == V4L2_CID_AUDIO_MUTE || +- c->id == V4L2_CID_AUDIO_VOLUME || +- c->id == V4L2_CID_AUDIO_BALANCE) { ++ if (c->id == V4L2_CID_AUDIO_MUTE) { + for (i = 0; i < CX8800_CTLS; i++) { + if (cx8800_ctls[i].v.id == c->id) + break; +diff --git a/drivers/media/video/cx88/cx88.h b/drivers/media/video/cx88/cx88.h +index e8c732e..c9981e7 100644 +--- a/drivers/media/video/cx88/cx88.h ++++ b/drivers/media/video/cx88/cx88.h +@@ -398,19 +398,17 @@ static inline struct cx88_core *to_core(struct v4l2_device *v4l2_dev) + return container_of(v4l2_dev, struct cx88_core, v4l2_dev); + } + +-#define call_hw(core, grpid, o, f, args...) \ ++#define call_all(core, o, f, args...) \ + do { \ + if (!core->i2c_rc) { \ + if (core->gate_ctrl) \ + core->gate_ctrl(core, 1); \ +- v4l2_device_call_all(&core->v4l2_dev, grpid, o, f, ##args); \ ++ v4l2_device_call_all(&core->v4l2_dev, 0, o, f, ##args); \ + if (core->gate_ctrl) \ + core->gate_ctrl(core, 0); \ + } \ + } while (0) + +-#define call_all(core, o, f, args...) call_hw(core, 0, o, f, ##args) +- + struct cx8800_dev; + struct cx8802_dev; + +diff --git a/drivers/media/video/wm8775.c b/drivers/media/video/wm8775.c +index 1355256..fe8ef64 100644 +--- a/drivers/media/video/wm8775.c ++++ b/drivers/media/video/wm8775.c +@@ -35,7 +35,6 @@ + #include <media/v4l2-device.h> + #include <media/v4l2-chip-ident.h> + #include <media/v4l2-ctrls.h> +-#include <media/wm8775.h> + + MODULE_DESCRIPTION("wm8775 driver"); + MODULE_AUTHOR("Ulf Eklund, Hans Verkuil"); +@@ -51,16 +50,10 @@ enum { + TOT_REGS + }; + +-#define ALC_HOLD 0x85 /* R17: use zero cross detection, ALC hold time 42.6 ms */ +-#define ALC_EN 0x100 /* R17: ALC enable */ +- + struct wm8775_state { + struct v4l2_subdev sd; + struct v4l2_ctrl_handler hdl; + struct v4l2_ctrl *mute; +- struct v4l2_ctrl *vol; +- struct v4l2_ctrl *bal; +- struct v4l2_ctrl *loud; + u8 input; /* Last selected input (0-0xf) */ + }; + +@@ -92,30 +85,6 @@ static int wm8775_write(struct v4l2_subdev *sd, int reg, u16 val) + return -1; + } + +-static void wm8775_set_audio(struct v4l2_subdev *sd, int quietly) +-{ +- struct wm8775_state *state = to_state(sd); +- u8 vol_l, vol_r; +- int muted = 0 != state->mute->val; +- u16 volume = (u16)state->vol->val; +- u16 balance = (u16)state->bal->val; +- +- /* normalize ( 65535 to 0 -> 255 to 0 (+24dB to -103dB) ) */ +- vol_l = (min(65536 - balance, 32768) * volume) >> 23; +- vol_r = (min(balance, (u16)32768) * volume) >> 23; +- +- /* Mute */ +- if (muted || quietly) +- wm8775_write(sd, R21, 0x0c0 | state->input); +- +- wm8775_write(sd, R14, vol_l | 0x100); /* 0x100= Left channel ADC zero cross enable */ +- wm8775_write(sd, R15, vol_r | 0x100); /* 0x100= Right channel ADC zero cross enable */ +- +- /* Un-mute */ +- if (!muted) +- wm8775_write(sd, R21, state->input); +-} +- + static int wm8775_s_routing(struct v4l2_subdev *sd, + u32 input, u32 output, u32 config) + { +@@ -133,26 +102,25 @@ static int wm8775_s_routing(struct v4l2_subdev *sd, + state->input = input; + if (!v4l2_ctrl_g_ctrl(state->mute)) + return 0; +- if (!v4l2_ctrl_g_ctrl(state->vol)) +- return 0; +- if (!v4l2_ctrl_g_ctrl(state->bal)) +- return 0; +- wm8775_set_audio(sd, 1); ++ wm8775_write(sd, R21, 0x0c0); ++ wm8775_write(sd, R14, 0x1d4); ++ wm8775_write(sd, R15, 0x1d4); ++ wm8775_write(sd, R21, 0x100 + state->input); + return 0; + } + + static int wm8775_s_ctrl(struct v4l2_ctrl *ctrl) + { + struct v4l2_subdev *sd = to_sd(ctrl); ++ struct wm8775_state *state = to_state(sd); + + switch (ctrl->id) { + case V4L2_CID_AUDIO_MUTE: +- case V4L2_CID_AUDIO_VOLUME: +- case V4L2_CID_AUDIO_BALANCE: +- wm8775_set_audio(sd, 0); +- return 0; +- case V4L2_CID_AUDIO_LOUDNESS: +- wm8775_write(sd, R17, (ctrl->val ? ALC_EN : 0) | ALC_HOLD); ++ wm8775_write(sd, R21, 0x0c0); ++ wm8775_write(sd, R14, 0x1d4); ++ wm8775_write(sd, R15, 0x1d4); ++ if (!ctrl->val) ++ wm8775_write(sd, R21, 0x100 + state->input); + return 0; + } + return -EINVAL; +@@ -176,7 +144,16 @@ static int wm8775_log_status(struct v4l2_subdev *sd) + + static int wm8775_s_frequency(struct v4l2_subdev *sd, struct v4l2_frequency *freq) + { +- wm8775_set_audio(sd, 0); ++ struct wm8775_state *state = to_state(sd); ++ ++ /* If I remove this, then it can happen that I have no ++ sound the first time I tune from static to a valid channel. ++ It's difficult to reproduce and is almost certainly related ++ to the zero cross detect circuit. */ ++ wm8775_write(sd, R21, 0x0c0); ++ wm8775_write(sd, R14, 0x1d4); ++ wm8775_write(sd, R15, 0x1d4); ++ wm8775_write(sd, R21, 0x100 + state->input); + return 0; + } + +@@ -226,7 +203,6 @@ static int wm8775_probe(struct i2c_client *client, + { + struct wm8775_state *state; + struct v4l2_subdev *sd; +- int err; + + /* Check if the adapter supports the needed features */ + if (!i2c_check_functionality(client->adapter, I2C_FUNC_SMBUS_BYTE_DATA)) +@@ -240,21 +216,15 @@ static int wm8775_probe(struct i2c_client *client, + return -ENOMEM; + sd = &state->sd; + v4l2_i2c_subdev_init(sd, client, &wm8775_ops); +- sd->grp_id = WM8775_GID; /* subdev group id */ + state->input = 2; + +- v4l2_ctrl_handler_init(&state->hdl, 4); ++ v4l2_ctrl_handler_init(&state->hdl, 1); + state->mute = v4l2_ctrl_new_std(&state->hdl, &wm8775_ctrl_ops, + V4L2_CID_AUDIO_MUTE, 0, 1, 1, 0); +- state->vol = v4l2_ctrl_new_std(&state->hdl, &wm8775_ctrl_ops, +- V4L2_CID_AUDIO_VOLUME, 0, 65535, (65535+99)/100, 0xCF00); /* 0dB*/ +- state->bal = v4l2_ctrl_new_std(&state->hdl, &wm8775_ctrl_ops, +- V4L2_CID_AUDIO_BALANCE, 0, 65535, (65535+99)/100, 32768); +- state->loud = v4l2_ctrl_new_std(&state->hdl, &wm8775_ctrl_ops, +- V4L2_CID_AUDIO_LOUDNESS, 0, 1, 1, 1); + sd->ctrl_handler = &state->hdl; +- err = state->hdl.error; +- if (err) { ++ if (state->hdl.error) { ++ int err = state->hdl.error; ++ + v4l2_ctrl_handler_free(&state->hdl); + kfree(state); + return err; +@@ -266,25 +236,29 @@ static int wm8775_probe(struct i2c_client *client, + wm8775_write(sd, R23, 0x000); + /* Disable zero cross detect timeout */ + wm8775_write(sd, R7, 0x000); +- /* HPF enable, I2S mode, 24-bit */ +- wm8775_write(sd, R11, 0x022); ++ /* Left justified, 24-bit mode */ ++ wm8775_write(sd, R11, 0x021); + /* Master mode, clock ratio 256fs */ + wm8775_write(sd, R12, 0x102); + /* Powered up */ + wm8775_write(sd, R13, 0x000); +- /* ALC stereo, ALC target level -5dB FS, ALC max gain +8dB */ +- wm8775_write(sd, R16, 0x1bb); +- /* Set ALC mode and hold time */ +- wm8775_write(sd, R17, (state->loud->val ? ALC_EN : 0) | ALC_HOLD); ++ /* ADC gain +2.5dB, enable zero cross */ ++ wm8775_write(sd, R14, 0x1d4); ++ /* ADC gain +2.5dB, enable zero cross */ ++ wm8775_write(sd, R15, 0x1d4); ++ /* ALC Stereo, ALC target level -1dB FS max gain +8dB */ ++ wm8775_write(sd, R16, 0x1bf); ++ /* Enable gain control, use zero cross detection, ++ ALC hold time 42.6 ms */ ++ wm8775_write(sd, R17, 0x185); + /* ALC gain ramp up delay 34 s, ALC gain ramp down delay 33 ms */ + wm8775_write(sd, R18, 0x0a2); + /* Enable noise gate, threshold -72dBfs */ + wm8775_write(sd, R19, 0x005); +- /* Transient window 4ms, ALC min gain -5dB */ +- wm8775_write(sd, R20, 0x0fb); +- +- wm8775_set_audio(sd, 1); /* set volume/mute/mux */ +- ++ /* Transient window 4ms, lower PGA gain limit -1dB */ ++ wm8775_write(sd, R20, 0x07a); ++ /* LRBOTH = 1, use input 2. */ ++ wm8775_write(sd, R21, 0x102); + return 0; + } + +diff --git a/include/media/wm8775.h b/include/media/wm8775.h +index a1c4d41..60739c5 100644 +--- a/include/media/wm8775.h ++++ b/include/media/wm8775.h +@@ -32,7 +32,4 @@ + #define WM8775_AIN3 4 + #define WM8775_AIN4 8 + +-/* subdev group ID */ +-#define WM8775_GID (1 << 0) +- + #endif +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0052-media-em28xx-radio_fops-should-also-use-unlocked_ioc.patch b/recipes/linux/linux-omap-2.6.37/linus/0052-media-em28xx-radio_fops-should-also-use-unlocked_ioc.patch new file mode 100644 index 0000000000..5fe35438fd --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0052-media-em28xx-radio_fops-should-also-use-unlocked_ioc.patch @@ -0,0 +1,31 @@ +From 8fd0bda511406ef0e9dcce9be055d7ab931e92ba Mon Sep 17 00:00:00 2001 +From: Hans Verkuil <hverkuil@xs4all.nl> +Date: Sat, 18 Dec 2010 09:59:51 -0300 +Subject: [PATCH 52/66] [media] em28xx: radio_fops should also use unlocked_ioctl + +em28xx uses core assisted locking, so it shouldn't use .ioctl. +The .ioctl callback was replaced by .unlocked_ioctl for video nodes, +but not for radio nodes. This is now corrected. + +Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl> +Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com> +--- + drivers/media/video/em28xx/em28xx-video.c | 2 +- + 1 files changed, 1 insertions(+), 1 deletions(-) + +diff --git a/drivers/media/video/em28xx/em28xx-video.c b/drivers/media/video/em28xx/em28xx-video.c +index 908e3bc..2c30072 100644 +--- a/drivers/media/video/em28xx/em28xx-video.c ++++ b/drivers/media/video/em28xx/em28xx-video.c +@@ -2377,7 +2377,7 @@ static const struct v4l2_file_operations radio_fops = { + .owner = THIS_MODULE, + .open = em28xx_v4l2_open, + .release = em28xx_v4l2_close, +- .ioctl = video_ioctl2, ++ .unlocked_ioctl = video_ioctl2, + }; + + static const struct v4l2_ioctl_ops radio_ioctl_ops = { +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0053-arch-x86-oprofile-op_model_amd.c-Perform-initialisat.patch b/recipes/linux/linux-omap-2.6.37/linus/0053-arch-x86-oprofile-op_model_amd.c-Perform-initialisat.patch new file mode 100644 index 0000000000..d38d77a04e --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0053-arch-x86-oprofile-op_model_amd.c-Perform-initialisat.patch @@ -0,0 +1,81 @@ +From c7c25802b39c443b3745cfa973dc49a97a3491f8 Mon Sep 17 00:00:00 2001 +From: Robert Richter <robert.richter@amd.com> +Date: Mon, 3 Jan 2011 12:15:14 +0100 +Subject: [PATCH 53/66] arch/x86/oprofile/op_model_amd.c: Perform initialisation on a single CPU + +Disable preemption in init_ibs(). The function only checks the +ibs capabilities and sets up pci devices (if necessary). It runs +only on one cpu but operates with the local APIC and some MSRs, +thus it is better to disable preemption. + +[ 7.034377] BUG: using smp_processor_id() in preemptible [00000000] code: modprobe/483 +[ 7.034385] caller is setup_APIC_eilvt+0x155/0x180 +[ 7.034389] Pid: 483, comm: modprobe Not tainted 2.6.37-rc1-20101110+ #1 +[ 7.034392] Call Trace: +[ 7.034400] [<ffffffff812a2b72>] debug_smp_processor_id+0xd2/0xf0 +[ 7.034404] [<ffffffff8101e985>] setup_APIC_eilvt+0x155/0x180 +[ ... ] + +Addresses https://bugzilla.kernel.org/show_bug.cgi?id=22812 + +Reported-by: <atswartz@gmail.com> +Signed-off-by: Robert Richter <robert.richter@amd.com> +Cc: oprofile-list@lists.sourceforge.net <oprofile-list@lists.sourceforge.net> +Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> +Cc: Frederic Weisbecker <fweisbec@gmail.com> +Cc: Rafael J. Wysocki <rjw@sisk.pl> +Cc: Dan Carpenter <error27@gmail.com> +Cc: Andrew Morton <akpm@linux-foundation.org> +Cc: <stable@kernel.org> [2.6.37.x] +LKML-Reference: <20110103111514.GM4739@erda.amd.com> +[ small cleanups ] +Signed-off-by: Ingo Molnar <mingo@elte.hu> +--- + arch/x86/oprofile/op_model_amd.c | 24 ++++++++++++++++-------- + 1 files changed, 16 insertions(+), 8 deletions(-) + +diff --git a/arch/x86/oprofile/op_model_amd.c b/arch/x86/oprofile/op_model_amd.c +index a011bcc..7d90d47 100644 +--- a/arch/x86/oprofile/op_model_amd.c ++++ b/arch/x86/oprofile/op_model_amd.c +@@ -630,21 +630,29 @@ static int __init_ibs_nmi(void) + return 0; + } + +-/* initialize the APIC for the IBS interrupts if available */ ++/* ++ * check and reserve APIC extended interrupt LVT offset for IBS if ++ * available ++ * ++ * init_ibs() preforms implicitly cpu-local operations, so pin this ++ * thread to its current CPU ++ */ ++ + static void init_ibs(void) + { +- ibs_caps = get_ibs_caps(); ++ preempt_disable(); + ++ ibs_caps = get_ibs_caps(); + if (!ibs_caps) +- return; ++ goto out; + +- if (__init_ibs_nmi()) { ++ if (__init_ibs_nmi() < 0) + ibs_caps = 0; +- return; +- } ++ else ++ printk(KERN_INFO "oprofile: AMD IBS detected (0x%08x)\n", ibs_caps); + +- printk(KERN_INFO "oprofile: AMD IBS detected (0x%08x)\n", +- (unsigned)ibs_caps); ++out: ++ preempt_enable(); + } + + static int (*create_arch_files)(struct super_block *sb, struct dentry *root); +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0054-perf-Fix-callchain-hit-bad-cast-on-ascii-display.patch b/recipes/linux/linux-omap-2.6.37/linus/0054-perf-Fix-callchain-hit-bad-cast-on-ascii-display.patch new file mode 100644 index 0000000000..d98849e51a --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0054-perf-Fix-callchain-hit-bad-cast-on-ascii-display.patch @@ -0,0 +1,39 @@ +From d425de5436a620de506f9e4119bf8daa1cb93718 Mon Sep 17 00:00:00 2001 +From: Frederic Weisbecker <fweisbec@gmail.com> +Date: Mon, 3 Jan 2011 16:13:11 +0100 +Subject: [PATCH 54/66] perf: Fix callchain hit bad cast on ascii display + +ipchain__fprintf_graph() casts the number of hits in a branch as an +int, which means we lose its highests bits. + +This results in meaningless number of callchain hits in perf.data +that have a high number of hits recorded, typically those that have +callchain branches hits appearing more than INT_MAX. This happens +easily as those are pondered by the event period. + +Reported-by: Nick Piggin <npiggin@kernel.dk> +Signed-off-by: Frederic Weisbecker <fweisbec@gmail.com> +Cc: Ingo Molnar <mingo@elte.hu> +Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> +Cc: Arnaldo Carvalho de Melo <acme@redhat.com> +Cc: Paul Mackerras <paulus@samba.org> +--- + tools/perf/util/hist.c | 2 +- + 1 files changed, 1 insertions(+), 1 deletions(-) + +diff --git a/tools/perf/util/hist.c b/tools/perf/util/hist.c +index 2022e87..76bcc35 100644 +--- a/tools/perf/util/hist.c ++++ b/tools/perf/util/hist.c +@@ -356,7 +356,7 @@ static size_t ipchain__fprintf_graph_line(FILE *fp, int depth, int depth_mask, + + static size_t ipchain__fprintf_graph(FILE *fp, struct callchain_list *chain, + int depth, int depth_mask, int period, +- u64 total_samples, int hits, ++ u64 total_samples, u64 hits, + int left_margin) + { + int i; +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0055-ARM-pxa-PXA_ESERIES-depends-on-FB_W100.patch b/recipes/linux/linux-omap-2.6.37/linus/0055-ARM-pxa-PXA_ESERIES-depends-on-FB_W100.patch new file mode 100644 index 0000000000..c1b62385a1 --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0055-ARM-pxa-PXA_ESERIES-depends-on-FB_W100.patch @@ -0,0 +1,29 @@ +From 82427de2c7c39ee7bcaa4cb0260b4e9b9ab19eb8 Mon Sep 17 00:00:00 2001 +From: Lennert Buytenhek <buytenh@wantstofly.org> +Date: Wed, 15 Dec 2010 07:20:16 +0800 +Subject: [PATCH 55/66] ARM: pxa: PXA_ESERIES depends on FB_W100. + +As arch/arm/mach-pxa/eseries.c references w100fb_gpio_{read,write}() +directly. + +Signed-off-by: Lennert Buytenhek <buytenh@secretlab.ca> +Signed-off-by: Eric Miao <eric.y.miao@gmail.com> +--- + arch/arm/mach-pxa/Kconfig | 1 + + 1 files changed, 1 insertions(+), 0 deletions(-) + +diff --git a/arch/arm/mach-pxa/Kconfig b/arch/arm/mach-pxa/Kconfig +index dd235ec..c93e73d 100644 +--- a/arch/arm/mach-pxa/Kconfig ++++ b/arch/arm/mach-pxa/Kconfig +@@ -540,6 +540,7 @@ config MACH_ICONTROL + config ARCH_PXA_ESERIES + bool "PXA based Toshiba e-series PDAs" + select PXA25x ++ select FB_W100 + + config MACH_E330 + bool "Toshiba e330" +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0056-ARM-it8152-add-IT8152_LAST_IRQ-definition-to-fix-bui.patch b/recipes/linux/linux-omap-2.6.37/linus/0056-ARM-it8152-add-IT8152_LAST_IRQ-definition-to-fix-bui.patch new file mode 100644 index 0000000000..fadc8226de --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0056-ARM-it8152-add-IT8152_LAST_IRQ-definition-to-fix-bui.patch @@ -0,0 +1,40 @@ +From 823a2df258627b80df2e75056b850424a8eb5fed Mon Sep 17 00:00:00 2001 +From: Mike Rapoport <mike@compulab.co.il> +Date: Wed, 29 Dec 2010 09:06:26 +0200 +Subject: [PATCH 56/66] ARM: it8152: add IT8152_LAST_IRQ definition to fix build error + +The commit 6ac6b817f3f4c23c5febd960d8deb343e13af5f3 (ARM: pxa: encode +IRQ number into .nr_irqs) removed definition of ITE_LAST_IRQ which +caused the following build error: + +CC arch/arm/common/it8152.o +arch/arm/common/it8152.c: In function 'it8152_init_irq': +arch/arm/common/it8152.c:86: error: 'IT8152_LAST_IRQ' undeclared (first use in this function) +arch/arm/common/it8152.c:86: error: (Each undeclared identifier is reported only once +arch/arm/common/it8152.c:86: error: for each function it appears in.) +make[2]: *** [arch/arm/common/it8152.o] Error 1 + +Defining the IT8152_LAST_IRQ in the arch/arm/include/hardware/it8152.c +fixes the build. + +Signed-off-by: Mike Rapoport <mike@compulab.co.il> +Signed-off-by: Eric Miao <eric.y.miao@gmail.com> +--- + arch/arm/include/asm/hardware/it8152.h | 1 + + 1 files changed, 1 insertions(+), 0 deletions(-) + +diff --git a/arch/arm/include/asm/hardware/it8152.h b/arch/arm/include/asm/hardware/it8152.h +index 21fa272..b2f95c7 100644 +--- a/arch/arm/include/asm/hardware/it8152.h ++++ b/arch/arm/include/asm/hardware/it8152.h +@@ -76,6 +76,7 @@ extern unsigned long it8152_base_address; + IT8152_PD_IRQ(0) Audio controller (ACR) + */ + #define IT8152_IRQ(x) (IRQ_BOARD_START + (x)) ++#define IT8152_LAST_IRQ (IRQ_BOARD_START + 40) + + /* IRQ-sources in 3 groups - local devices, LPC (serial), and external PCI */ + #define IT8152_LD_IRQ_COUNT 9 +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0057-ARM-pxa-fix-page-table-corruption-on-resume.patch b/recipes/linux/linux-omap-2.6.37/linus/0057-ARM-pxa-fix-page-table-corruption-on-resume.patch new file mode 100644 index 0000000000..d8b784dbf9 --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0057-ARM-pxa-fix-page-table-corruption-on-resume.patch @@ -0,0 +1,46 @@ +From 24c78557741395e038e83f25367cf2bfd7f582b8 Mon Sep 17 00:00:00 2001 +From: Aric D. Blumer <aric@sdgsystems.com> +Date: Wed, 29 Dec 2010 11:18:29 -0500 +Subject: [PATCH 57/66] ARM: pxa: fix page table corruption on resume + +Before this patch, the following error would sometimes occur after a +resume on pxa3xx: + + /path/to/mm/memory.c:144: bad pmd 8040542e. + +The problem was that a temporary page table mapping was being improperly +restored. + +The PXA3xx resume code creates a temporary mapping of resume_turn_on_mmu +to avoid a prefetch abort. The pxa3xx_resume_after_mmu code requires +that the r1 register holding the address of this mapping not be +modified, however, resume_turn_on_mmu does modify it. It is mostly +correct in that r1 receives the base table address, but it may also +get other bits in 13:0. This results in pxa3xx_resume_after_mmu +restoring the original mapping to the wrong place, corrupting memory +and leaving the temporary mapping in place. + +Signed-off-by: Matt Reimer <mreimer@sdgsystems.com> +Signed-off-by: Eric Miao <eric.y.miao@gmail.com> +--- + arch/arm/mach-pxa/sleep.S | 4 ++-- + 1 files changed, 2 insertions(+), 2 deletions(-) + +diff --git a/arch/arm/mach-pxa/sleep.S b/arch/arm/mach-pxa/sleep.S +index 52c30b0..ae00811 100644 +--- a/arch/arm/mach-pxa/sleep.S ++++ b/arch/arm/mach-pxa/sleep.S +@@ -353,8 +353,8 @@ resume_turn_on_mmu: + + @ Let us ensure we jump to resume_after_mmu only when the mcr above + @ actually took effect. They call it the "cpwait" operation. +- mrc p15, 0, r1, c2, c0, 0 @ queue a dependency on CP15 +- sub pc, r2, r1, lsr #32 @ jump to virtual addr ++ mrc p15, 0, r0, c2, c0, 0 @ queue a dependency on CP15 ++ sub pc, r2, r0, lsr #32 @ jump to virtual addr + nop + nop + nop +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0058-atl1-fix-oops-when-changing-tx-rx-ring-params.patch b/recipes/linux/linux-omap-2.6.37/linus/0058-atl1-fix-oops-when-changing-tx-rx-ring-params.patch new file mode 100644 index 0000000000..5216f8eee2 --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0058-atl1-fix-oops-when-changing-tx-rx-ring-params.patch @@ -0,0 +1,63 @@ +From 2f32c867219734b06abc980d4812f67b6d6fe517 Mon Sep 17 00:00:00 2001 +From: J. K. Cliburn <jcliburn@gmail.com> +Date: Sat, 1 Jan 2011 05:02:12 +0000 +Subject: [PATCH 58/66] atl1: fix oops when changing tx/rx ring params +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +Commit 3f5a2a713aad28480d86b0add00c68484b54febc zeroes out the statistics +message block (SMB) and coalescing message block (CMB) when adapter ring +resources are freed. This is desirable behavior, but, as a side effect, +the commit leads to an oops when atl1_set_ringparam() attempts to alter +the number of rx or tx elements in the ring buffer (by using ethtool +-G, for example). We don't want SMB or CMB to change during this +operation. + +Modify atl1_set_ringparam() to preserve SMB and CMB when changing ring +parameters. + +Cc: stable@kernel.org +Signed-off-by: Jay Cliburn <jcliburn@gmail.com> +Reported-by: Tõnu Raitviir <jussuf@linux.ee> +Signed-off-by: David S. Miller <davem@davemloft.net> +--- + drivers/net/atlx/atl1.c | 10 ++++++++++ + 1 files changed, 10 insertions(+), 0 deletions(-) + +diff --git a/drivers/net/atlx/atl1.c b/drivers/net/atlx/atl1.c +index 5336310..3acf512 100644 +--- a/drivers/net/atlx/atl1.c ++++ b/drivers/net/atlx/atl1.c +@@ -3504,6 +3504,8 @@ static int atl1_set_ringparam(struct net_device *netdev, + struct atl1_rfd_ring rfd_old, rfd_new; + struct atl1_rrd_ring rrd_old, rrd_new; + struct atl1_ring_header rhdr_old, rhdr_new; ++ struct atl1_smb smb; ++ struct atl1_cmb cmb; + int err; + + tpd_old = adapter->tpd_ring; +@@ -3544,11 +3546,19 @@ static int atl1_set_ringparam(struct net_device *netdev, + adapter->rrd_ring = rrd_old; + adapter->tpd_ring = tpd_old; + adapter->ring_header = rhdr_old; ++ /* ++ * Save SMB and CMB, since atl1_free_ring_resources ++ * will clear them. ++ */ ++ smb = adapter->smb; ++ cmb = adapter->cmb; + atl1_free_ring_resources(adapter); + adapter->rfd_ring = rfd_new; + adapter->rrd_ring = rrd_new; + adapter->tpd_ring = tpd_new; + adapter->ring_header = rhdr_new; ++ adapter->smb = smb; ++ adapter->cmb = cmb; + + err = atl1_up(adapter); + if (err) +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0059-bridge-fix-br_multicast_ipv6_rcv-for-paged-skbs.patch b/recipes/linux/linux-omap-2.6.37/linus/0059-bridge-fix-br_multicast_ipv6_rcv-for-paged-skbs.patch new file mode 100644 index 0000000000..75f729517c --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0059-bridge-fix-br_multicast_ipv6_rcv-for-paged-skbs.patch @@ -0,0 +1,157 @@ +From 9d89081d698132b5f964aea88112f76492563ee9 Mon Sep 17 00:00:00 2001 +From: Tomas Winkler <tomas.winkler@intel.com> +Date: Mon, 3 Jan 2011 11:26:08 -0800 +Subject: [PATCH 59/66] bridge: fix br_multicast_ipv6_rcv for paged skbs + +use pskb_may_pull to access ipv6 header correctly for paged skbs +It was omitted in the bridge code leading to crash in blind +__skb_pull + +since the skb is cloned undonditionally we also simplify the +the exit path + +this fixes bug https://bugzilla.kernel.org/show_bug.cgi?id=25202 + +Dec 15 14:36:40 User-PC hostapd: wlan0: STA 00:15:00:60:5d:34 IEEE 802.11: authenticated +Dec 15 14:36:40 User-PC hostapd: wlan0: STA 00:15:00:60:5d:34 IEEE 802.11: associated (aid 2) +Dec 15 14:36:40 User-PC hostapd: wlan0: STA 00:15:00:60:5d:34 RADIUS: starting accounting session 4D0608A3-00000005 +Dec 15 14:36:41 User-PC kernel: [175576.120287] ------------[ cut here ]------------ +Dec 15 14:36:41 User-PC kernel: [175576.120452] kernel BUG at include/linux/skbuff.h:1178! +Dec 15 14:36:41 User-PC kernel: [175576.120609] invalid opcode: 0000 [#1] SMP +Dec 15 14:36:41 User-PC kernel: [175576.120749] last sysfs file: /sys/devices/pci0000:00/0000:00:1f.2/host0/target0:0:0/0:0:0:0/block/sda/uevent +Dec 15 14:36:41 User-PC kernel: [175576.121035] Modules linked in: approvals binfmt_misc bridge stp llc parport_pc ppdev arc4 iwlagn snd_hda_codec_realtek iwlcore i915 snd_hda_intel mac80211 joydev snd_hda_codec snd_hwdep snd_pcm snd_seq_midi drm_kms_helper snd_rawmidi drm snd_seq_midi_event snd_seq snd_timer snd_seq_device cfg80211 eeepc_wmi usbhid psmouse intel_agp i2c_algo_bit intel_gtt uvcvideo agpgart videodev sparse_keymap snd shpchp v4l1_compat lp hid video serio_raw soundcore output snd_page_alloc ahci libahci atl1c +Dec 15 14:36:41 User-PC kernel: [175576.122712] +Dec 15 14:36:41 User-PC kernel: [175576.122769] Pid: 0, comm: kworker/0:0 Tainted: G W 2.6.37-rc5-wl+ #3 1015PE/1016P +Dec 15 14:36:41 User-PC kernel: [175576.123012] EIP: 0060:[<f83edd65>] EFLAGS: 00010283 CPU: 1 +Dec 15 14:36:41 User-PC kernel: [175576.123193] EIP is at br_multicast_rcv+0xc95/0xe1c [bridge] +Dec 15 14:36:41 User-PC kernel: [175576.123362] EAX: 0000001c EBX: f5626318 ECX: 00000000 EDX: 00000000 +Dec 15 14:36:41 User-PC kernel: [175576.123550] ESI: ec512262 EDI: f5626180 EBP: f60b5ca0 ESP: f60b5bd8 +Dec 15 14:36:41 User-PC kernel: [175576.123737] DS: 007b ES: 007b FS: 00d8 GS: 00e0 SS: 0068 +Dec 15 14:36:41 User-PC kernel: [175576.123902] Process kworker/0:0 (pid: 0, ti=f60b4000 task=f60a8000 task.ti=f60b0000) +Dec 15 14:36:41 User-PC kernel: [175576.124137] Stack: +Dec 15 14:36:41 User-PC kernel: [175576.124181] ec556500 f6d06800 f60b5be8 c01087d8 ec512262 00000030 00000024 f5626180 +Dec 15 14:36:41 User-PC kernel: [175576.124181] f572c200 ef463440 f5626300 3affffff f6d06dd0 e60766a4 000000c4 f6d06860 +Dec 15 14:36:41 User-PC kernel: [175576.124181] ffffffff ec55652c 00000001 f6d06844 f60b5c64 c0138264 c016e451 c013e47d +Dec 15 14:36:41 User-PC kernel: [175576.124181] Call Trace: +Dec 15 14:36:41 User-PC kernel: [175576.124181] [<c01087d8>] ? sched_clock+0x8/0x10 +Dec 15 14:36:41 User-PC kernel: [175576.124181] [<c0138264>] ? enqueue_entity+0x174/0x440 +Dec 15 14:36:41 User-PC kernel: [175576.124181] [<c016e451>] ? sched_clock_cpu+0x131/0x190 +Dec 15 14:36:41 User-PC kernel: [175576.124181] [<c013e47d>] ? select_task_rq_fair+0x2ad/0x730 +Dec 15 14:36:41 User-PC kernel: [175576.124181] [<c0524fc1>] ? nf_iterate+0x71/0x90 +Dec 15 14:36:41 User-PC kernel: [175576.124181] [<f83e4914>] ? br_handle_frame_finish+0x184/0x220 [bridge] +Dec 15 14:36:41 User-PC kernel: [175576.124181] [<f83e4790>] ? br_handle_frame_finish+0x0/0x220 [bridge] +Dec 15 14:36:41 User-PC kernel: [175576.124181] [<f83e46e9>] ? br_handle_frame+0x189/0x230 [bridge] +Dec 15 14:36:41 User-PC kernel: [175576.124181] [<f83e4790>] ? br_handle_frame_finish+0x0/0x220 [bridge] +Dec 15 14:36:41 User-PC kernel: [175576.124181] [<f83e4560>] ? br_handle_frame+0x0/0x230 [bridge] +Dec 15 14:36:41 User-PC kernel: [175576.124181] [<c04ff026>] ? __netif_receive_skb+0x1b6/0x5b0 +Dec 15 14:36:41 User-PC kernel: [175576.124181] [<c04f7a30>] ? skb_copy_bits+0x110/0x210 +Dec 15 14:36:41 User-PC kernel: [175576.124181] [<c0503a7f>] ? netif_receive_skb+0x6f/0x80 +Dec 15 14:36:41 User-PC kernel: [175576.124181] [<f82cb74c>] ? ieee80211_deliver_skb+0x8c/0x1a0 [mac80211] +Dec 15 14:36:41 User-PC kernel: [175576.124181] [<f82cc836>] ? ieee80211_rx_handlers+0xeb6/0x1aa0 [mac80211] +Dec 15 14:36:41 User-PC kernel: [175576.124181] [<c04ff1f0>] ? __netif_receive_skb+0x380/0x5b0 +Dec 15 14:36:41 User-PC kernel: [175576.124181] [<c016e242>] ? sched_clock_local+0xb2/0x190 +Dec 15 14:36:41 User-PC kernel: [175576.124181] [<c012b688>] ? default_spin_lock_flags+0x8/0x10 +Dec 15 14:36:41 User-PC kernel: [175576.124181] [<c05d83df>] ? _raw_spin_lock_irqsave+0x2f/0x50 +Dec 15 14:36:41 User-PC kernel: [175576.124181] [<f82cd621>] ? ieee80211_prepare_and_rx_handle+0x201/0xa90 [mac80211] +Dec 15 14:36:41 User-PC kernel: [175576.124181] [<f82ce154>] ? ieee80211_rx+0x2a4/0x830 [mac80211] +Dec 15 14:36:41 User-PC kernel: [175576.124181] [<f815a8d6>] ? iwl_update_stats+0xa6/0x2a0 [iwlcore] +Dec 15 14:36:41 User-PC kernel: [175576.124181] [<f8499212>] ? iwlagn_rx_reply_rx+0x292/0x3b0 [iwlagn] +Dec 15 14:36:41 User-PC kernel: [175576.124181] [<c05d83df>] ? _raw_spin_lock_irqsave+0x2f/0x50 +Dec 15 14:36:41 User-PC kernel: [175576.124181] [<f8483697>] ? iwl_rx_handle+0xe7/0x350 [iwlagn] +Dec 15 14:36:41 User-PC kernel: [175576.124181] [<f8486ab7>] ? iwl_irq_tasklet+0xf7/0x5c0 [iwlagn] +Dec 15 14:36:41 User-PC kernel: [175576.124181] [<c01aece1>] ? __rcu_process_callbacks+0x201/0x2d0 +Dec 15 14:36:41 User-PC kernel: [175576.124181] [<c0150d05>] ? tasklet_action+0xc5/0x100 +Dec 15 14:36:41 User-PC kernel: [175576.124181] [<c0150a07>] ? __do_softirq+0x97/0x1d0 +Dec 15 14:36:41 User-PC kernel: [175576.124181] [<c05d910c>] ? nmi_stack_correct+0x2f/0x34 +Dec 15 14:36:41 User-PC kernel: [175576.124181] [<c0150970>] ? __do_softirq+0x0/0x1d0 +Dec 15 14:36:41 User-PC kernel: [175576.124181] <IRQ> +Dec 15 14:36:41 User-PC kernel: [175576.124181] [<c01508f5>] ? irq_exit+0x65/0x70 +Dec 15 14:36:41 User-PC kernel: [175576.124181] [<c05df062>] ? do_IRQ+0x52/0xc0 +Dec 15 14:36:41 User-PC kernel: [175576.124181] [<c01036b0>] ? common_interrupt+0x30/0x38 +Dec 15 14:36:41 User-PC kernel: [175576.124181] [<c03a1fc2>] ? intel_idle+0xc2/0x160 +Dec 15 14:36:41 User-PC kernel: [175576.124181] [<c04daebb>] ? cpuidle_idle_call+0x6b/0x100 +Dec 15 14:36:41 User-PC kernel: [175576.124181] [<c0101dea>] ? cpu_idle+0x8a/0xf0 +Dec 15 14:36:41 User-PC kernel: [175576.124181] [<c05d2702>] ? start_secondary+0x1e8/0x1ee + +Cc: David Miller <davem@davemloft.net> +Cc: Johannes Berg <johannes@sipsolutions.net> +Cc: Stephen Hemminger <shemminger@vyatta.com> +Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> +Signed-off-by: David S. Miller <davem@davemloft.net> +--- + net/bridge/br_multicast.c | 28 ++++++++++++++++++---------- + 1 files changed, 18 insertions(+), 10 deletions(-) + +diff --git a/net/bridge/br_multicast.c b/net/bridge/br_multicast.c +index f19e347..543b326 100644 +--- a/net/bridge/br_multicast.c ++++ b/net/bridge/br_multicast.c +@@ -1430,7 +1430,7 @@ static int br_multicast_ipv6_rcv(struct net_bridge *br, + struct net_bridge_port *port, + struct sk_buff *skb) + { +- struct sk_buff *skb2 = skb; ++ struct sk_buff *skb2; + struct ipv6hdr *ip6h; + struct icmp6hdr *icmp6h; + u8 nexthdr; +@@ -1469,15 +1469,15 @@ static int br_multicast_ipv6_rcv(struct net_bridge *br, + if (!skb2) + return -ENOMEM; + ++ err = -EINVAL; ++ if (!pskb_may_pull(skb2, offset + sizeof(struct icmp6hdr))) ++ goto out; ++ + len -= offset - skb_network_offset(skb2); + + __skb_pull(skb2, offset); + skb_reset_transport_header(skb2); + +- err = -EINVAL; +- if (!pskb_may_pull(skb2, sizeof(*icmp6h))) +- goto out; +- + icmp6h = icmp6_hdr(skb2); + + switch (icmp6h->icmp6_type) { +@@ -1516,7 +1516,12 @@ static int br_multicast_ipv6_rcv(struct net_bridge *br, + switch (icmp6h->icmp6_type) { + case ICMPV6_MGM_REPORT: + { +- struct mld_msg *mld = (struct mld_msg *)icmp6h; ++ struct mld_msg *mld; ++ if (!pskb_may_pull(skb2, sizeof(*mld))) { ++ err = -EINVAL; ++ goto out; ++ } ++ mld = (struct mld_msg *)skb_transport_header(skb2); + BR_INPUT_SKB_CB(skb2)->mrouters_only = 1; + err = br_ip6_multicast_add_group(br, port, &mld->mld_mca); + break; +@@ -1529,15 +1534,18 @@ static int br_multicast_ipv6_rcv(struct net_bridge *br, + break; + case ICMPV6_MGM_REDUCTION: + { +- struct mld_msg *mld = (struct mld_msg *)icmp6h; ++ struct mld_msg *mld; ++ if (!pskb_may_pull(skb2, sizeof(*mld))) { ++ err = -EINVAL; ++ goto out; ++ } ++ mld = (struct mld_msg *)skb_transport_header(skb2); + br_ip6_multicast_leave_group(br, port, &mld->mld_mca); + } + } + + out: +- __skb_push(skb2, offset); +- if (skb2 != skb) +- kfree_skb(skb2); ++ kfree_skb(skb2); + return err; + } + #endif +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0060-name_to_dev_t-must-not-call-__init-code.patch b/recipes/linux/linux-omap-2.6.37/linus/0060-name_to_dev_t-must-not-call-__init-code.patch new file mode 100644 index 0000000000..bdd9fd0d3e --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0060-name_to_dev_t-must-not-call-__init-code.patch @@ -0,0 +1,31 @@ +From a1cf11d8f673a3ad91012c5da96beed06ecefde1 Mon Sep 17 00:00:00 2001 +From: Jan Beulich <JBeulich@novell.com> +Date: Mon, 3 Jan 2011 15:07:02 +0000 +Subject: [PATCH 60/66] name_to_dev_t() must not call __init code + +The function can't be __init itself (being called from some sysfs +handler), and hence none of the functions it calls can be either. + +Signed-off-by: Jan Beulich <jbeulich@novell.com> +Acked-by: Randy Dunlap <randy.dunlap@oracle.com> +Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> +--- + init/do_mounts.c | 2 +- + 1 files changed, 1 insertions(+), 1 deletions(-) + +diff --git a/init/do_mounts.c b/init/do_mounts.c +index 830aaec..2b54bef 100644 +--- a/init/do_mounts.c ++++ b/init/do_mounts.c +@@ -93,7 +93,7 @@ no_match: + * + * Returns the matching dev_t on success or 0 on failure. + */ +-static dev_t __init devt_from_partuuid(char *uuid_str) ++static dev_t devt_from_partuuid(char *uuid_str) + { + dev_t res = 0; + struct device *dev = NULL; +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0061-bridge-stp-ensure-mac-header-is-set.patch b/recipes/linux/linux-omap-2.6.37/linus/0061-bridge-stp-ensure-mac-header-is-set.patch new file mode 100644 index 0000000000..f2c0e46891 --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0061-bridge-stp-ensure-mac-header-is-set.patch @@ -0,0 +1,38 @@ +From e6f26129ebbb0071016e2526036f42036ccf30e1 Mon Sep 17 00:00:00 2001 +From: Florian Westphal <fw@strlen.de> +Date: Mon, 3 Jan 2011 04:16:28 +0000 +Subject: [PATCH 61/66] bridge: stp: ensure mac header is set + +commit bf9ae5386bca8836c16e69ab8fdbe46767d7452a +(llc: use dev_hard_header) removed the +skb_reset_mac_header call from llc_mac_hdr_init. + +This seems fine itself, but br_send_bpdu() invokes ebtables LOCAL_OUT. + +We oops in ebt_basic_match() because it assumes eth_hdr(skb) returns +a meaningful result. + +Cc: acme@ghostprotocols.net +References: https://bugzilla.kernel.org/show_bug.cgi?id=24532 +Signed-off-by: Florian Westphal <fw@strlen.de> +Signed-off-by: David S. Miller <davem@davemloft.net> +--- + net/bridge/br_stp_bpdu.c | 2 ++ + 1 files changed, 2 insertions(+), 0 deletions(-) + +diff --git a/net/bridge/br_stp_bpdu.c b/net/bridge/br_stp_bpdu.c +index 35cf270..e3d7aef 100644 +--- a/net/bridge/br_stp_bpdu.c ++++ b/net/bridge/br_stp_bpdu.c +@@ -50,6 +50,8 @@ static void br_send_bpdu(struct net_bridge_port *p, + + llc_mac_hdr_init(skb, p->dev->dev_addr, p->br->group_addr); + ++ skb_reset_mac_header(skb); ++ + NF_HOOK(NFPROTO_BRIDGE, NF_BR_LOCAL_OUT, skb, NULL, skb->dev, + dev_queue_xmit); + } +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0062-ima-fix-add-LSM-rule-bug.patch b/recipes/linux/linux-omap-2.6.37/linus/0062-ima-fix-add-LSM-rule-bug.patch new file mode 100644 index 0000000000..775d2a6beb --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0062-ima-fix-add-LSM-rule-bug.patch @@ -0,0 +1,64 @@ +From 867c20265459d30a01b021a9c1e81fb4c5832aa9 Mon Sep 17 00:00:00 2001 +From: Mimi Zohar <zohar@linux.vnet.ibm.com> +Date: Mon, 3 Jan 2011 14:59:10 -0800 +Subject: [PATCH 62/66] ima: fix add LSM rule bug + +If security_filter_rule_init() doesn't return a rule, then not everything +is as fine as the return code implies. + +This bug only occurs when the LSM (eg. SELinux) is disabled at runtime. + +Adding an empty LSM rule causes ima_match_rules() to always succeed, +ignoring any remaining rules. + + default IMA TCB policy: + # PROC_SUPER_MAGIC + dont_measure fsmagic=0x9fa0 + # SYSFS_MAGIC + dont_measure fsmagic=0x62656572 + # DEBUGFS_MAGIC + dont_measure fsmagic=0x64626720 + # TMPFS_MAGIC + dont_measure fsmagic=0x01021994 + # SECURITYFS_MAGIC + dont_measure fsmagic=0x73636673 + + < LSM specific rule > + dont_measure obj_type=var_log_t + + measure func=BPRM_CHECK + measure func=FILE_MMAP mask=MAY_EXEC + measure func=FILE_CHECK mask=MAY_READ uid=0 + +Thus without the patch, with the boot parameters 'tcb selinux=0', adding +the above 'dont_measure obj_type=var_log_t' rule to the default IMA TCB +measurement policy, would result in nothing being measured. The patch +prevents the default TCB policy from being replaced. + +Signed-off-by: Mimi Zohar <zohar@us.ibm.com> +Cc: James Morris <jmorris@namei.org> +Acked-by: Serge Hallyn <serge.hallyn@canonical.com> +Cc: David Safford <safford@watson.ibm.com> +Cc: <stable@kernel.org> +Signed-off-by: Andrew Morton <akpm@linux-foundation.org> +Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> +--- + security/integrity/ima/ima_policy.c | 2 ++ + 1 files changed, 2 insertions(+), 0 deletions(-) + +diff --git a/security/integrity/ima/ima_policy.c b/security/integrity/ima/ima_policy.c +index aef8c0a..d661afb 100644 +--- a/security/integrity/ima/ima_policy.c ++++ b/security/integrity/ima/ima_policy.c +@@ -253,6 +253,8 @@ static int ima_lsm_rule_init(struct ima_measure_rule_entry *entry, + result = security_filter_rule_init(entry->lsm[lsm_rule].type, + Audit_equal, args, + &entry->lsm[lsm_rule].rule); ++ if (!entry->lsm[lsm_rule].rule) ++ return -EINVAL; + return result; + } + +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0063-arch-mn10300-kernel-irq.c-fix-build.patch b/recipes/linux/linux-omap-2.6.37/linus/0063-arch-mn10300-kernel-irq.c-fix-build.patch new file mode 100644 index 0000000000..cf6a5c7540 --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0063-arch-mn10300-kernel-irq.c-fix-build.patch @@ -0,0 +1,31 @@ +From d9a1abe4844e7591cd82e167a1a09e6546f6c45e Mon Sep 17 00:00:00 2001 +From: Andrew Morton <akpm@linux-foundation.org> +Date: Mon, 3 Jan 2011 14:59:11 -0800 +Subject: [PATCH 63/66] arch/mn10300/kernel/irq.c: fix build + +Addresses https://bugzilla.kernel.org/show_bug.cgi?id=25702 + +Reported-by: Martin Ettl <ettl.martin@gmx.de> +Cc: David Howells <dhowells@redhat.com> +Signed-off-by: Andrew Morton <akpm@linux-foundation.org> +Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> +--- + arch/mn10300/kernel/irq.c | 2 +- + 1 files changed, 1 insertions(+), 1 deletions(-) + +diff --git a/arch/mn10300/kernel/irq.c b/arch/mn10300/kernel/irq.c +index c2e4459..ac11754 100644 +--- a/arch/mn10300/kernel/irq.c ++++ b/arch/mn10300/kernel/irq.c +@@ -459,7 +459,7 @@ void migrate_irqs(void) + tmp = CROSS_GxICR(irq, new); + + x &= GxICR_LEVEL | GxICR_ENABLE; +- if (GxICR(irq) & GxICR_REQUEST) { ++ if (GxICR(irq) & GxICR_REQUEST) + x |= GxICR_REQUEST | GxICR_DETECT; + CROSS_GxICR(irq, new) = x; + tmp = CROSS_GxICR(irq, new); +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0064-remove-trim_fs-method-from-Documentation-filesystems.patch b/recipes/linux/linux-omap-2.6.37/linus/0064-remove-trim_fs-method-from-Documentation-filesystems.patch new file mode 100644 index 0000000000..e9d78f52dd --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0064-remove-trim_fs-method-from-Documentation-filesystems.patch @@ -0,0 +1,38 @@ +From 8a87694ed159d7abd2c9ed657416696c05db2252 Mon Sep 17 00:00:00 2001 +From: Christoph Hellwig <hch@lst.de> +Date: Tue, 4 Jan 2011 07:14:24 +0100 +Subject: [PATCH 64/66] remove trim_fs method from Documentation/filesystems/Locking + +The ->trim_fs has been removed meanwhile, so remove it from the documentation +as well. + +Signed-off-by: Christoph Hellwig <hch@lst.de> +Reported-by: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp> +Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> +--- + Documentation/filesystems/Locking | 2 -- + 1 files changed, 0 insertions(+), 2 deletions(-) + +diff --git a/Documentation/filesystems/Locking b/Documentation/filesystems/Locking +index 7686e76..33fa3e5 100644 +--- a/Documentation/filesystems/Locking ++++ b/Documentation/filesystems/Locking +@@ -115,7 +115,6 @@ prototypes: + ssize_t (*quota_read)(struct super_block *, int, char *, size_t, loff_t); + ssize_t (*quota_write)(struct super_block *, int, const char *, size_t, loff_t); + int (*bdev_try_to_free_page)(struct super_block*, struct page*, gfp_t); +- int (*trim_fs) (struct super_block *, struct fstrim_range *); + + locking rules: + All may block [not true, see below] +@@ -138,7 +137,6 @@ show_options: no (namespace_sem) + quota_read: no (see below) + quota_write: no (see below) + bdev_try_to_free_page: no (see below) +-trim_fs: no + + ->statfs() has s_umount (shared) when called by ustat(2) (native or + compat), but that's an accident of bad API; s_umount is used to pin +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0065-ipv4-route.c-respect-prefsrc-for-local-routes.patch b/recipes/linux/linux-omap-2.6.37/linus/0065-ipv4-route.c-respect-prefsrc-for-local-routes.patch new file mode 100644 index 0000000000..5f57d4cf72 --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0065-ipv4-route.c-respect-prefsrc-for-local-routes.patch @@ -0,0 +1,57 @@ +From 9fc3bbb4a752f108cf096d96640f3b548bbbce6c Mon Sep 17 00:00:00 2001 +From: Joel Sing <jsing@google.com> +Date: Mon, 3 Jan 2011 20:24:20 +0000 +Subject: [PATCH 65/66] ipv4/route.c: respect prefsrc for local routes + +The preferred source address is currently ignored for local routes, +which results in all local connections having a src address that is the +same as the local dst address. Fix this by respecting the preferred source +address when it is provided for local routes. + +This bug can be demonstrated as follows: + + # ifconfig dummy0 192.168.0.1 + # ip route show table local | grep local.*dummy0 + local 192.168.0.1 dev dummy0 proto kernel scope host src 192.168.0.1 + # ip route change table local local 192.168.0.1 dev dummy0 \ + proto kernel scope host src 127.0.0.1 + # ip route show table local | grep local.*dummy0 + local 192.168.0.1 dev dummy0 proto kernel scope host src 127.0.0.1 + +We now establish a local connection and verify the source IP +address selection: + + # nc -l 192.168.0.1 3128 & + # nc 192.168.0.1 3128 & + # netstat -ant | grep 192.168.0.1:3128.*EST + tcp 0 0 192.168.0.1:3128 192.168.0.1:33228 ESTABLISHED + tcp 0 0 192.168.0.1:33228 192.168.0.1:3128 ESTABLISHED + +Signed-off-by: Joel Sing <jsing@google.com> +Signed-off-by: David S. Miller <davem@davemloft.net> +--- + net/ipv4/route.c | 8 ++++++-- + 1 files changed, 6 insertions(+), 2 deletions(-) + +diff --git a/net/ipv4/route.c b/net/ipv4/route.c +index df948b0..93bfd95 100644 +--- a/net/ipv4/route.c ++++ b/net/ipv4/route.c +@@ -2649,8 +2649,12 @@ static int ip_route_output_slow(struct net *net, struct rtable **rp, + } + + if (res.type == RTN_LOCAL) { +- if (!fl.fl4_src) +- fl.fl4_src = fl.fl4_dst; ++ if (!fl.fl4_src) { ++ if (res.fi->fib_prefsrc) ++ fl.fl4_src = res.fi->fib_prefsrc; ++ else ++ fl.fl4_src = fl.fl4_dst; ++ } + dev_out = net->loopback_dev; + fl.oif = dev_out->ifindex; + res.fi = NULL; +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37/linus/0066-Linux-2.6.37.patch b/recipes/linux/linux-omap-2.6.37/linus/0066-Linux-2.6.37.patch new file mode 100644 index 0000000000..3c1055a4e1 --- /dev/null +++ b/recipes/linux/linux-omap-2.6.37/linus/0066-Linux-2.6.37.patch @@ -0,0 +1,25 @@ +From 3c0eee3fe6a3a1c745379547c7e7c904aa64f6d5 Mon Sep 17 00:00:00 2001 +From: Linus Torvalds <torvalds@linux-foundation.org> +Date: Tue, 4 Jan 2011 16:50:19 -0800 +Subject: [PATCH 66/66] Linux 2.6.37 + +--- + Makefile | 2 +- + 1 files changed, 1 insertions(+), 1 deletions(-) + +diff --git a/Makefile b/Makefile +index e7c41f1..74b2555 100644 +--- a/Makefile ++++ b/Makefile +@@ -1,7 +1,7 @@ + VERSION = 2 + PATCHLEVEL = 6 + SUBLEVEL = 37 +-EXTRAVERSION = -rc8 ++EXTRAVERSION = + NAME = Flesh-Eating Bats with Fangs + + # *DOCUMENTATION* +-- +1.6.6.1 + diff --git a/recipes/linux/linux-omap-2.6.37rc/omap3-touchbook/defconfig b/recipes/linux/linux-omap-2.6.37/omap3-touchbook/defconfig index 44e34a711f..44e34a711f 120000 --- a/recipes/linux/linux-omap-2.6.37rc/omap3-touchbook/defconfig +++ b/recipes/linux/linux-omap-2.6.37/omap3-touchbook/defconfig diff --git a/recipes/linux/linux-omap-2.6.37rc/omap3evm/defconfig b/recipes/linux/linux-omap-2.6.37/omap3evm/defconfig index 44e34a711f..44e34a711f 120000 --- a/recipes/linux/linux-omap-2.6.37rc/omap3evm/defconfig +++ b/recipes/linux/linux-omap-2.6.37/omap3evm/defconfig diff --git a/recipes/linux/linux-omap-2.6.37rc/overo/defconfig b/recipes/linux/linux-omap-2.6.37/overo/defconfig index 44e34a711f..44e34a711f 120000 --- a/recipes/linux/linux-omap-2.6.37rc/overo/defconfig +++ b/recipes/linux/linux-omap-2.6.37/overo/defconfig diff --git a/recipes/linux/linux-omap-2.6.37rc/usrp-e1xx/defconfig b/recipes/linux/linux-omap-2.6.37/usrp-e1xx/defconfig index 44e34a711f..44e34a711f 120000 --- a/recipes/linux/linux-omap-2.6.37rc/usrp-e1xx/defconfig +++ b/recipes/linux/linux-omap-2.6.37/usrp-e1xx/defconfig diff --git a/recipes/linux/linux-omap-2.6.37rc/usrp/0001-Add-defines-to-set-config-options-in-GPMC-per-CS-con.patch b/recipes/linux/linux-omap-2.6.37/usrp/0001-Add-defines-to-set-config-options-in-GPMC-per-CS-con.patch index 2fcef66a91..2fcef66a91 100644 --- a/recipes/linux/linux-omap-2.6.37rc/usrp/0001-Add-defines-to-set-config-options-in-GPMC-per-CS-con.patch +++ b/recipes/linux/linux-omap-2.6.37/usrp/0001-Add-defines-to-set-config-options-in-GPMC-per-CS-con.patch diff --git a/recipes/linux/linux-omap-2.6.37rc/usrp/0002-Add-functions-to-dma.c-to-set-address-and-length-for.patch b/recipes/linux/linux-omap-2.6.37/usrp/0002-Add-functions-to-dma.c-to-set-address-and-length-for.patch index 22305f3519..22305f3519 100644 --- a/recipes/linux/linux-omap-2.6.37rc/usrp/0002-Add-functions-to-dma.c-to-set-address-and-length-for.patch +++ b/recipes/linux/linux-omap-2.6.37/usrp/0002-Add-functions-to-dma.c-to-set-address-and-length-for.patch diff --git a/recipes/linux/linux-omap-2.6.37rc/usrp/0003-usrp-embedded-Add-driver-for-USRP-Embedded-FPGA-inte.patch b/recipes/linux/linux-omap-2.6.37/usrp/0003-usrp-embedded-Add-driver-for-USRP-Embedded-FPGA-inte.patch index 98a6d3b711..98a6d3b711 100644 --- a/recipes/linux/linux-omap-2.6.37rc/usrp/0003-usrp-embedded-Add-driver-for-USRP-Embedded-FPGA-inte.patch +++ b/recipes/linux/linux-omap-2.6.37/usrp/0003-usrp-embedded-Add-driver-for-USRP-Embedded-FPGA-inte.patch diff --git a/recipes/linux/linux-omap_2.6.37.bb b/recipes/linux/linux-omap_2.6.37.bb new file mode 100644 index 0000000000..e3b8c6fa54 --- /dev/null +++ b/recipes/linux/linux-omap_2.6.37.bb @@ -0,0 +1,147 @@ +require multi-kernel.inc + +DESCRIPTION = "Linux kernel for OMAP processors" +KERNEL_IMAGETYPE = "uImage" + +COMPATIBLE_MACHINE = "(beagleboard|overo|omap3evm|omap3-touchbook|usrp-e1xx)" + +# The main PR is now using MACHINE_KERNEL_PR, for omap3 see conf/machine/include/omap3.inc +PV = "2.6.37" +MACHINE_KERNEL_PR_append = "a+gitr${SRCREV}" +SRCREV = "fa3b4e23ec20cfc944db7cc2b30b0d82c20e4472" + +FILESPATHPKG_prepend = "linux-omap-2.6.37:" + +SRC_URI = "git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap-2.6.git;protocol=git \ + file://defconfig" + +SRC_URI_append = " \ + file://linus/0001-ARM-pxa-PXA_ESERIES-depends-on-FB_W100.patch \ + file://linus/0002-ARM-smp-avoid-incrementing-mm_users-on-CPU-startup.patch \ + file://linus/0003-ARM-get-rid-of-kmap_high_l1_vipt.patch \ + file://linus/0004-ARM-fix-cache-xsc3l2-after-stack-based-kmap_atomic.patch \ + file://linus/0005-ARM-fix-cache-feroceon-l2-after-stack-based-kmap_ato.patch \ + file://linus/0006-drm-i915-Set-the-required-VFMUNIT-clock-gating-disab.patch \ + file://linus/0007-drm-i915-sdvo-Add-hdmi-connector-properties-after-in.patch \ + file://linus/0008-drm-i915-intel_ips-When-i915-loads-after-IPS-make-IP.patch \ + file://linus/0009-drm-i915-Verify-Ironlake-eDP-presence-on-DP_A-using-.patch \ + file://linus/0010-ARM-6536-1-Add-missing-SZ_-32-64-128.patch \ + file://linus/0011-ARM-6537-1-update-Nomadik-U300-and-Ux500-maintainers.patch \ + file://linus/0012-ARM-6540-1-Stop-irqsoff-trace-on-return-to-user.patch \ + file://linus/0013-ueagle-atm-fix-PHY-signal-initialization-race.patch \ + file://linus/0014-ehea-Avoid-changing-vlan-flags.patch \ + file://linus/0015-ppp-allow-disabling-multilink-protocol-ID-compressio.patch \ + file://linus/0016-skfp-testing-the-wrong-variable-in-skfp_driver_init.patch \ + file://linus/0017-ASoC-codecs-Add-missing-control_type-initialization.patch \ + file://linus/0018-ASoC-codecs-max98088-Fix-register-cache-incoherency.patch \ + file://linus/0019-ASoC-codecs-wm8523-Fix-register-cache-incoherency.patch \ + file://linus/0020-ASoC-codecs-wm8741-Fix-register-cache-incoherency.patch \ + file://linus/0021-ASoC-codecs-wm8904-Fix-register-cache-incoherency.patch \ + file://linus/0022-ASoC-codecs-wm8955-Fix-register-cache-incoherency.patch \ + file://linus/0023-ASoC-codecs-wm8962-Fix-register-cache-incoherency.patch \ + file://linus/0024-ASoC-codecs-wm9090-Fix-register-cache-incoherency.patch \ + file://linus/0025-ASoC-codecs-wm8753-Fix-register-cache-incoherency.patch \ + file://linus/0026-KVM-MMU-Fix-incorrect-direct-gfn-for-unpaged-mode-sh.patch \ + file://linus/0027-fix-freeing-user_struct-in-user-cache.patch \ + file://linus/0028-spi-omap2_mcspi.c-Force-CS-to-be-in-inactive-state-a.patch \ + file://linus/0029-kconfig-fix-undesirable-side-effect-of-adding-visibl.patch \ + file://linus/0030-spi-m68knommu-Coldfire-QSPI-platform-support.patch \ + file://linus/0031-sound-Prevent-buffer-overflow-in-OSS-load_mixer_volu.patch \ + file://linus/0032-ALSA-hda-Use-LPIB-quirk-for-Dell-Inspiron-m101z-1120.patch \ + file://linus/0033-Revert-drm-i915-bios-Reverse-order-of-100-120-Mhz-SS.patch \ + file://linus/0034-drm-i915-dvo-Report-LVDS-attached-to-ch701x-as-conne.patch \ + file://linus/0035-update-Documentation-filesystems-Locking.patch \ + file://linus/0036-memcg-fix-wrong-VM_BUG_ON-in-try_charge-s-mm-owner-c.patch \ + file://linus/0037-Revert-Staging-zram-work-around-oops-due-to-startup-.patch \ + file://linus/0038-CAN-Use-inode-instead-of-kernel-address-for-proc-fil.patch \ + file://linus/0039-ISDN-Gigaset-Fix-memory-leak-in-do_disconnect_req.patch \ + file://linus/0040-Broadcom-CNIC-core-network-driver-fix-mem-leak-on-al.patch \ + file://linus/0041-tg3-fix-return-value-check-in-tg3_read_vpd.patch \ + file://linus/0042-starfire-Fix-dma_addr_t-size-test-for-MIPS.patch \ + file://linus/0043-drivers-atm-atmtcp.c-add-missing-atm_dev_put.patch \ + file://linus/0044-KVM-i8259-initialize-isr_ack.patch \ + file://linus/0045-hwmon-s3c-hwmon-Fix-compilation.patch \ + file://linus/0046-watchdog-Improve-initialisation-error-message-and-do.patch \ + file://linus/0047-ARM-6605-1-Add-missing-include-asm-memory.h.patch \ + file://linus/0048-mv_xor-fix-race-in-tasklet-function.patch \ + file://linus/0049-dmaengine-provide-dummy-functions-for-DMA_ENGINE-n.patch \ + file://linus/0050-media-cx25840-Prevent-device-probe-failure-due-to-vo.patch \ + file://linus/0051-media-wm8775-Revert-changeset-fcb9757333-to-avoid-a-.patch \ + file://linus/0052-media-em28xx-radio_fops-should-also-use-unlocked_ioc.patch \ + file://linus/0053-arch-x86-oprofile-op_model_amd.c-Perform-initialisat.patch \ + file://linus/0054-perf-Fix-callchain-hit-bad-cast-on-ascii-display.patch \ + file://linus/0056-ARM-it8152-add-IT8152_LAST_IRQ-definition-to-fix-bui.patch \ + file://linus/0057-ARM-pxa-fix-page-table-corruption-on-resume.patch \ + file://linus/0058-atl1-fix-oops-when-changing-tx-rx-ring-params.patch \ + file://linus/0059-bridge-fix-br_multicast_ipv6_rcv-for-paged-skbs.patch \ + file://linus/0060-name_to_dev_t-must-not-call-__init-code.patch \ + file://linus/0061-bridge-stp-ensure-mac-header-is-set.patch \ + file://linus/0062-ima-fix-add-LSM-rule-bug.patch \ + file://linus/0063-arch-mn10300-kernel-irq.c-fix-build.patch \ + file://linus/0064-remove-trim_fs-method-from-Documentation-filesystems.patch \ + file://linus/0065-ipv4-route.c-respect-prefsrc-for-local-routes.patch \ + file://linus/0066-Linux-2.6.37.patch \ + \ + file://base/0001-ARM-OMAP-Power-on-EHCI-serial-camera-and-DVI-on-beag.patch \ + file://base/0002-omap-Beagle-detect-new-xM-revision-B.patch \ + file://base/0003-ARM-OMAP-beagleboard-Add-infrastructure-to-do-fixups.patch \ + file://base/0004-ARM-OMAP-beagleboard-pre-export-GPIOs-to-userspace-w.patch \ + file://base/0005-modedb.c-add-proper-720p60-mode.patch \ + file://base/0006-mmc-don-t-display-single-block-read-console-messages.patch \ + file://base/0007-MTD-silence-ecc-errors-on-mtdblock0.patch \ + file://base/0008-Miracle-patch.patch \ + file://base/0009-ARM-OMAP-add-omap_rev_-macros.patch \ + file://base/0010-OMAP-DSS2-enable-hsclk-in-dsi_pll_init-for-OMAP36XX.patch \ + file://base/0011-omap3-beagleboard-add-WIP-support-for-beagleboardtoy.patch \ + file://base/0012-drivers-net-smsc911x-return-ENODEV-if-device-is-not-.patch \ + file://base/0013-drivers-input-touchscreen-ads7846-return-ENODEV-if-d.patch \ + file://base/0014-ASoC-enable-audio-capture-by-default-for-twl4030.patch \ + file://base/0015-MFD-enable-madc-clock.patch \ + file://base/0016-MFD-add-twl4030-madc-driver.patch \ + file://base/0017-ARM-OMAP-Add-twl4030-madc-support-to-Overo.patch \ + file://base/0018-ARM-OMAP-Add-twl4030-madc-support-to-Beagle.patch \ + file://base/0019-OMAP-DSS2-Add-support-for-Samsung-LTE430WQ-F0C-panel.patch \ + file://base/0020-OMAP-DSS2-Add-support-for-LG-Philips-LB035Q02-panel.patch \ + file://base/0021-OMAP-DSS2-add-bootarg-for-selecting-svideo-or-compos.patch \ + file://base/0022-ARM-OMAP2-mmc-twl4030-move-clock-input-selection-pri.patch \ + file://base/0023-RTC-add-support-for-backup-battery-recharge.patch \ + file://base/0024-ARM-OMAP-automatically-set-musb-mode-in-platform-dat.patch \ + file://base/0025-OMAP-DSS2-check-for-both-cpu-type-and-revision-rathe.patch \ + file://base/0026-OMAP-DSS2-Add-DSS2-support-for-Overo.patch \ + \ + file://dvfs/0001-OMAP3-PM-Adding-T2-enabling-of-smartreflex.patch \ + file://dvfs/0002-OMAP-CPUfreq-ensure-driver-initializes-after-cpufreq.patch \ + file://dvfs/0003-OMAP-CPUfreq-ensure-policy-is-fully-initialized.patch \ + file://dvfs/0004-OMAP3-PM-CPUFreq-driver-for-OMAP3.patch \ + file://dvfs/0005-OMAP-PM-CPUFREQ-Fix-conditional-compilation.patch \ + file://dvfs/0006-OMAP-Introduce-a-user-list-for-each-voltage-domain-i.patch \ + file://dvfs/0007-OMAP-Introduce-API-in-the-OPP-layer-to-find-the-opp-.patch \ + file://dvfs/0008-OMAP-Introduce-API-to-register-a-device-with-a-volta.patch \ + file://dvfs/0009-OMAP-Introduce-device-specific-set-rate-and-get-rate.patch \ + file://dvfs/0010-OMAP-Voltage-layer-changes-to-support-DVFS.patch \ + file://dvfs/0011-OMAP-Introduce-dependent-voltage-domain-support.patch \ + file://dvfs/0012-OMAP-Introduce-device-scale.patch \ + file://dvfs/0013-OMAP-Disable-smartreflex-across-DVFS.patch \ + file://dvfs/0014-OMAP3-Introduce-custom-set-rate-and-get-rate-APIs-fo.patch \ + file://dvfs/0015-OMAP3-Update-cpufreq-driver-to-use-the-new-set_rate-.patch \ + file://dvfs/0016-OMAP3-Introduce-voltage-domain-info-in-the-hwmod-str.patch \ + file://dvfs/0017-OMAP3-Add-voltage-dependency-table-for-VDD1.patch \ + file://dvfs/0018-omap3-4-opp-make-omapx_opp_init-non-static.patch \ + file://dvfs/0019-OMAP3-beagle-xm-enable-upto-1GHz-OPP.patch \ + \ + file://dvfs/0001-omap3-add-support-for-720MHz-MPU-OPP.patch \ + file://dvfs/0002-OMAP35x-Add-support-for-720MHz-part.patch \ + file://dvfs/0003-OMAP3-beagle-C4-enable-upto-720MHz-OPP.patch \ + file://dvfs/0004-OMAP3-Overo-Tide-enable-upto-720MHz-OPP.patch \ + " + +SRC_URI_append_usrp-e1xx = "\ + file://usrp/0001-Add-defines-to-set-config-options-in-GPMC-per-CS-con.patch \ + file://usrp/0002-Add-functions-to-dma.c-to-set-address-and-length-for.patch \ + file://usrp/0003-usrp-embedded-Add-driver-for-USRP-Embedded-FPGA-inte.patch \ +" + +SRC_URI_append_beagleboard = " file://logo_linux_clut224.ppm \ +" + +S = "${WORKDIR}/git" diff --git a/recipes/linux/linux-omap_2.6.37rc.bb b/recipes/linux/linux-omap_2.6.37rc.bb deleted file mode 100644 index e0db191e07..0000000000 --- a/recipes/linux/linux-omap_2.6.37rc.bb +++ /dev/null @@ -1,81 +0,0 @@ -require multi-kernel.inc - -DESCRIPTION = "Linux kernel for OMAP processors" -KERNEL_IMAGETYPE = "uImage" - -COMPATIBLE_MACHINE = "(beagleboard|overo|omap3evm|omap3-touchbook|usrp-e1xx)" - -# The main PR is now using MACHINE_KERNEL_PR, for omap3 see conf/machine/include/omap3.inc -PV = "2.6.36+2.6.37-rc8" -MACHINE_KERNEL_PR_append = "a+gitr${SRCREV}" -SRCREV = "fa3b4e23ec20cfc944db7cc2b30b0d82c20e4472" - -FILESPATHPKG_prepend = "linux-omap-2.6.37rc:" - -SRC_URI = "git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap-2.6.git;protocol=git \ - file://defconfig" - -SRC_URI_append = " \ - file://base/0001-ARM-OMAP-Power-on-EHCI-serial-camera-and-DVI-on-beag.patch \ - file://base/0002-omap-Beagle-detect-new-xM-revision-B.patch \ - file://base/0003-ARM-OMAP-beagleboard-Add-infrastructure-to-do-fixups.patch \ - file://base/0004-ARM-OMAP-beagleboard-pre-export-GPIOs-to-userspace-w.patch \ - file://base/0005-modedb.c-add-proper-720p60-mode.patch \ - file://base/0006-mmc-don-t-display-single-block-read-console-messages.patch \ - file://base/0007-MTD-silence-ecc-errors-on-mtdblock0.patch \ - file://base/0008-Miracle-patch.patch \ - file://base/0009-ARM-OMAP-add-omap_rev_-macros.patch \ - file://base/0010-OMAP-DSS2-enable-hsclk-in-dsi_pll_init-for-OMAP36XX.patch \ - file://base/0011-omap3-beagleboard-add-WIP-support-for-beagleboardtoy.patch \ - file://base/0012-drivers-net-smsc911x-return-ENODEV-if-device-is-not-.patch \ - file://base/0013-drivers-input-touchscreen-ads7846-return-ENODEV-if-d.patch \ - file://base/0014-ASoC-enable-audio-capture-by-default-for-twl4030.patch \ - file://base/0015-MFD-enable-madc-clock.patch \ - file://base/0016-MFD-add-twl4030-madc-driver.patch \ - file://base/0017-ARM-OMAP-Add-twl4030-madc-support-to-Overo.patch \ - file://base/0018-ARM-OMAP-Add-twl4030-madc-support-to-Beagle.patch \ - file://base/0019-OMAP-DSS2-Add-support-for-Samsung-LTE430WQ-F0C-panel.patch \ - file://base/0020-OMAP-DSS2-Add-support-for-LG-Philips-LB035Q02-panel.patch \ - file://base/0021-OMAP-DSS2-add-bootarg-for-selecting-svideo-or-compos.patch \ - file://base/0022-ARM-OMAP2-mmc-twl4030-move-clock-input-selection-pri.patch \ - file://base/0023-RTC-add-support-for-backup-battery-recharge.patch \ - file://base/0024-ARM-OMAP-automatically-set-musb-mode-in-platform-dat.patch \ - file://base/0025-OMAP-DSS2-check-for-both-cpu-type-and-revision-rathe.patch \ - file://base/0026-OMAP-DSS2-Add-DSS2-support-for-Overo.patch \ - \ - file://dvfs/0001-OMAP3-PM-Adding-T2-enabling-of-smartreflex.patch \ - file://dvfs/0002-OMAP-CPUfreq-ensure-driver-initializes-after-cpufreq.patch \ - file://dvfs/0003-OMAP-CPUfreq-ensure-policy-is-fully-initialized.patch \ - file://dvfs/0004-OMAP3-PM-CPUFreq-driver-for-OMAP3.patch \ - file://dvfs/0005-OMAP-PM-CPUFREQ-Fix-conditional-compilation.patch \ - file://dvfs/0006-OMAP-Introduce-a-user-list-for-each-voltage-domain-i.patch \ - file://dvfs/0007-OMAP-Introduce-API-in-the-OPP-layer-to-find-the-opp-.patch \ - file://dvfs/0008-OMAP-Introduce-API-to-register-a-device-with-a-volta.patch \ - file://dvfs/0009-OMAP-Introduce-device-specific-set-rate-and-get-rate.patch \ - file://dvfs/0010-OMAP-Voltage-layer-changes-to-support-DVFS.patch \ - file://dvfs/0011-OMAP-Introduce-dependent-voltage-domain-support.patch \ - file://dvfs/0012-OMAP-Introduce-device-scale.patch \ - file://dvfs/0013-OMAP-Disable-smartreflex-across-DVFS.patch \ - file://dvfs/0014-OMAP3-Introduce-custom-set-rate-and-get-rate-APIs-fo.patch \ - file://dvfs/0015-OMAP3-Update-cpufreq-driver-to-use-the-new-set_rate-.patch \ - file://dvfs/0016-OMAP3-Introduce-voltage-domain-info-in-the-hwmod-str.patch \ - file://dvfs/0017-OMAP3-Add-voltage-dependency-table-for-VDD1.patch \ - file://dvfs/0018-omap3-4-opp-make-omapx_opp_init-non-static.patch \ - file://dvfs/0019-OMAP3-beagle-xm-enable-upto-1GHz-OPP.patch \ - \ - file://dvfs/0001-omap3-add-support-for-720MHz-MPU-OPP.patch \ - file://dvfs/0002-OMAP35x-Add-support-for-720MHz-part.patch \ - file://dvfs/0003-OMAP3-beagle-C4-enable-upto-720MHz-OPP.patch \ - file://dvfs/0004-OMAP3-Overo-Tide-enable-upto-720MHz-OPP.patch \ - " - -SRC_URI_append_usrp-e1xx = "\ - file://usrp/0001-Add-defines-to-set-config-options-in-GPMC-per-CS-con.patch \ - file://usrp/0002-Add-functions-to-dma.c-to-set-address-and-length-for.patch \ - file://usrp/0003-usrp-embedded-Add-driver-for-USRP-Embedded-FPGA-inte.patch \ -" - -SRC_URI_append_beagleboard = " file://logo_linux_clut224.ppm \ -" - -S = "${WORKDIR}/git" |