mirror of
https://github.com/archlinuxarm/PKGBUILDs.git
synced 2024-11-08 22:45:43 +00:00
core/linux-odroid fix
This commit is contained in:
parent
4e8af75eef
commit
57cc3d74a1
2 changed files with 2 additions and 107 deletions
|
@ -1,100 +0,0 @@
|
|||
From 51bffe8798f00dc412767f4284e66c02cb82c786 Mon Sep 17 00:00:00 2001
|
||||
From: ckkim <ckkim@hardkernel.com>
|
||||
Date: Wed, 5 Feb 2014 15:50:07 +0900
|
||||
Subject: [PATCH] usb3503 hub mode switch modify
|
||||
|
||||
---
|
||||
drivers/usb/misc/usb3503.c | 37 +++++--------------------------------
|
||||
1 file changed, 5 insertions(+), 32 deletions(-)
|
||||
|
||||
diff --git a/drivers/usb/misc/usb3503.c b/drivers/usb/misc/usb3503.c
|
||||
index 2b62a87..3dd06e8 100644
|
||||
--- a/drivers/usb/misc/usb3503.c
|
||||
+++ b/drivers/usb/misc/usb3503.c
|
||||
@@ -53,7 +53,7 @@
|
||||
#define USB3503_MAX_2A (0x80 << 0)
|
||||
|
||||
#define USB3503_SP_ILOCK 0xe7
|
||||
-#define USB3503_OCS_PINSEL (1 << 4)
|
||||
+#define USB3503_OCS_PINSEL (1 << 5)
|
||||
#define USB3503_PRTPWR_PINSEL (1 << 4)
|
||||
#define USB3503_SPILOCK_CONNECT (1 << 1)
|
||||
#define USB3503_SPILOCK_CONFIG (1 << 0)
|
||||
@@ -173,12 +173,11 @@ static int usb3503_switch_mode(struct usb3503 *hub, enum usb3503_mode mode)
|
||||
|
||||
/* CFG1 : SELF_BUS_PWR -> Self-Powerd operation */
|
||||
err = usb3503_set_bits(i2c, USB3503_CFG1,
|
||||
- ( USB3503_SELF_BUS_PWR));
|
||||
+ ( USB3503_SELF_BUS_PWR ));
|
||||
if (err < 0) {
|
||||
dev_err(&i2c->dev, "CFG1 failed (%d)\n", err);
|
||||
goto err_hubmode;
|
||||
}
|
||||
-
|
||||
err = usb3503_clear_bits(i2c, USB3503_CFG1,
|
||||
( USB3503_MTT_ENABLE
|
||||
| USB3503_OCS_INDIVIDUAL
|
||||
@@ -188,29 +187,6 @@ static int usb3503_switch_mode(struct usb3503 *hub, enum usb3503_mode mode)
|
||||
goto err_hubmode;
|
||||
}
|
||||
|
||||
- err = usb3503_set_bits(i2c, USB3503_BSTUP3,
|
||||
- BOOST_IOOUT3_30);
|
||||
- if (err < 0) {
|
||||
- dev_err(&i2c->dev, "USB3503_BSTUP3 failed (%d)\n", err);
|
||||
- goto err_hubmode;
|
||||
- }
|
||||
-
|
||||
- err = usb3503_set_bits(i2c, USB3503_BSTUP21,
|
||||
- ( BOOST_IOOUT2_30
|
||||
- | BOOST_IOOUT1_30));
|
||||
- if (err < 0) {
|
||||
- dev_err(&i2c->dev, "USB3503_BSTUP21 failed (%d)\n", err);
|
||||
- goto err_hubmode;
|
||||
- }
|
||||
-
|
||||
- /* SP_LOCK: clear connect_n */
|
||||
- err = usb3503_clear_bits(i2c, USB3503_SP_ILOCK,
|
||||
- USB3503_SPILOCK_CONNECT);
|
||||
- if (err < 0) {
|
||||
- dev_err(&i2c->dev, "USB3503_SPILOCK_CONNECT failed (%d)\n", err);
|
||||
- goto err_hubmode;
|
||||
- }
|
||||
-
|
||||
/* USB3503_SP_ILOCK config_n lock */
|
||||
err = usb3503_set_bits(i2c, USB3503_SP_ILOCK,
|
||||
USB3503_SPILOCK_CONFIG);
|
||||
@@ -220,9 +196,8 @@ static int usb3503_switch_mode(struct usb3503 *hub, enum usb3503_mode mode)
|
||||
}
|
||||
|
||||
hub->mode = mode;
|
||||
- dev_info(&i2c->dev, "switched to HUB mode\n");
|
||||
-
|
||||
usb3503_connect(hub->gpio_connect, 1);
|
||||
+ dev_info(&i2c->dev, "switched to HUB mode\n");
|
||||
|
||||
break;
|
||||
|
||||
@@ -300,8 +275,7 @@ static int usb3503_probe(struct i2c_client *i2c, const struct i2c_device_id *id)
|
||||
goto err_gpio_reset;
|
||||
}
|
||||
|
||||
- gpio_direction_output(hub->gpio_reset, 0);
|
||||
-
|
||||
+ usb3503_reset(hub->gpio_reset, 0);
|
||||
if(hub->clk == USB3503_REFCLK_24M)
|
||||
gpio_direction_output(hub->gpio_intn, 0);
|
||||
else if(hub->clk == USB3503_REFCLK_26M)
|
||||
@@ -309,8 +283,7 @@ static int usb3503_probe(struct i2c_client *i2c, const struct i2c_device_id *id)
|
||||
else
|
||||
gpio_direction_output(hub->gpio_intn, 1);
|
||||
|
||||
- gpio_direction_output(hub->gpio_connect, 0);
|
||||
- msleep(10);
|
||||
+ usb3503_connect(hub->gpio_connect, 0);
|
||||
usb3503_reset(hub->gpio_reset, 1);
|
||||
|
||||
/* Hub Wait RefClk stage */
|
||||
--
|
||||
1.8.5.1
|
||||
|
|
@ -18,20 +18,15 @@ _commit=2680cd69d125530fade65f67ef97d6399a9e92d9
|
|||
source=("https://github.com/hardkernel/linux/archive/${_commit}.tar.gz"
|
||||
'config_x'
|
||||
'config_x2'
|
||||
'config_u2'
|
||||
'51bffe8798f00dc412767f4284e66c02cb82c786.patch')
|
||||
'config_u2')
|
||||
md5sums=('58d66b88a523b66c1962ad24b9bbf2d3'
|
||||
'bc5d01ed7e89cc13682683934fed7c33'
|
||||
'edc777c6e603f2ea3a453f405918fa2b'
|
||||
'75f29a3f1b7c80fa0fdb60f950ec325b'
|
||||
'b2e06972808314b76fe383d1d8e59bfc')
|
||||
'75f29a3f1b7c80fa0fdb60f950ec325b')
|
||||
|
||||
build() {
|
||||
cd "${srcdir}/linux-${_commit}"
|
||||
|
||||
# revert commit that breaks USB
|
||||
patch -p1 -Ri ../51bffe8798f00dc412767f4284e66c02cb82c786.patch
|
||||
|
||||
# add pkgrel to extraversion
|
||||
sed -ri "s|^(EXTRAVERSION =)(.*)|\1 \2-${pkgrel}|" Makefile
|
||||
|
||||
|
|
Loading…
Reference in a new issue