summaryrefslogtreecommitdiffstats
path: root/target/linux/ipq806x/patches/0030-pinctrl-msm-Replace-lookup-tables-with-math.patch
diff options
context:
space:
mode:
authorJohn Crispin <john@openwrt.org>2015-02-11 10:09:23 +0000
committerJohn Crispin <john@openwrt.org>2015-02-11 10:09:23 +0000
commit88ddb3746188037afd38d631f7a893587fa8bdf0 (patch)
treedf4684db63441435126c4b6ff1fda4ce615e1ff0 /target/linux/ipq806x/patches/0030-pinctrl-msm-Replace-lookup-tables-with-math.patch
parentddcbef5766fa18f52e7a7d1928b25edc63e73937 (diff)
downloadmaster-31e0f0ae-88ddb3746188037afd38d631f7a893587fa8bdf0.tar.gz
master-31e0f0ae-88ddb3746188037afd38d631f7a893587fa8bdf0.tar.bz2
master-31e0f0ae-88ddb3746188037afd38d631f7a893587fa8bdf0.zip
ipq806x: update target to v3.18
Patches in the ipq806x/patches folder were out of tree in v3.14. The newest patch at the time was from June, so we can safely assume that either the patches have been merged, or they have been rejected for a good reason. If patches are seen missing, we'll cherry-pick them on a per-needed basis. This new kernel have been tested on AP148, which seems to works fine. Signed-off-by: Mathieu Olivari <mathieu@codeaurora.org> SVN-Revision: 44386
Diffstat (limited to 'target/linux/ipq806x/patches/0030-pinctrl-msm-Replace-lookup-tables-with-math.patch')
-rw-r--r--target/linux/ipq806x/patches/0030-pinctrl-msm-Replace-lookup-tables-with-math.patch61
1 files changed, 0 insertions, 61 deletions
diff --git a/target/linux/ipq806x/patches/0030-pinctrl-msm-Replace-lookup-tables-with-math.patch b/target/linux/ipq806x/patches/0030-pinctrl-msm-Replace-lookup-tables-with-math.patch
deleted file mode 100644
index 6bc94affdb..0000000000
--- a/target/linux/ipq806x/patches/0030-pinctrl-msm-Replace-lookup-tables-with-math.patch
+++ /dev/null
@@ -1,61 +0,0 @@
-From e34d9fdac8182f6ce8933501fea6e84664060bf0 Mon Sep 17 00:00:00 2001
-From: Stephen Boyd <sboyd@codeaurora.org>
-Date: Thu, 6 Mar 2014 22:44:44 -0800
-Subject: [PATCH 030/182] pinctrl: msm: Replace lookup tables with math
-
-We don't need to waste space with these lookup tables, just do
-the math directly.
-
-Signed-off-by: Stephen Boyd <sboyd@codeaurora.org>
-Acked-by: Bjorn Andersson <bjorn.andersson@sonymobile.com>
-Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
----
- drivers/pinctrl/pinctrl-msm.c | 14 ++++++++------
- 1 file changed, 8 insertions(+), 6 deletions(-)
-
---- a/drivers/pinctrl/pinctrl-msm.c
-+++ b/drivers/pinctrl/pinctrl-msm.c
-@@ -258,8 +258,10 @@ static int msm_config_set(struct pinctrl
- #define MSM_PULL_DOWN 1
- #define MSM_PULL_UP 3
-
--static const unsigned msm_regval_to_drive[] = { 2, 4, 6, 8, 10, 12, 14, 16 };
--static const unsigned msm_drive_to_regval[] = { -1, -1, 0, -1, 1, -1, 2, -1, 3, -1, 4, -1, 5, -1, 6, -1, 7 };
-+static unsigned msm_regval_to_drive(u32 val)
-+{
-+ return (val + 1) * 2;
-+}
-
- static int msm_config_group_get(struct pinctrl_dev *pctldev,
- unsigned int group,
-@@ -296,7 +298,7 @@ static int msm_config_group_get(struct p
- arg = arg == MSM_PULL_UP;
- break;
- case PIN_CONFIG_DRIVE_STRENGTH:
-- arg = msm_regval_to_drive[arg];
-+ arg = msm_regval_to_drive(arg);
- break;
- default:
- dev_err(pctrl->dev, "Unsupported config parameter: %x\n",
-@@ -349,10 +351,10 @@ static int msm_config_group_set(struct p
- break;
- case PIN_CONFIG_DRIVE_STRENGTH:
- /* Check for invalid values */
-- if (arg >= ARRAY_SIZE(msm_drive_to_regval))
-+ if (arg > 16 || arg < 2 || (arg % 2) != 0)
- arg = -1;
- else
-- arg = msm_drive_to_regval[arg];
-+ arg = (arg / 2) - 1;
- break;
- default:
- dev_err(pctrl->dev, "Unsupported config parameter: %x\n",
-@@ -531,7 +533,7 @@ static void msm_gpio_dbg_show_one(struct
- pull = (ctl_reg >> g->pull_bit) & 3;
-
- seq_printf(s, " %-8s: %-3s %d", g->name, is_out ? "out" : "in", func);
-- seq_printf(s, " %dmA", msm_regval_to_drive[drive]);
-+ seq_printf(s, " %dmA", msm_regval_to_drive(drive));
- seq_printf(s, " %s", pulls[pull]);
- }
-