kernel/4.3: update to version 4.3.3
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de SVN-Revision: 48224v19.07.3_mercusys_ac12_duma
parent
93b50ade93
commit
cdb83aaf5f
@ -1,59 +0,0 @@
|
||||
From 63243a4da7d0dfa19dcacd0a529782eeb2f86f92 Mon Sep 17 00:00:00 2001
|
||||
From: Simran Rai <ssimran@broadcom.com>
|
||||
Date: Mon, 19 Oct 2015 15:27:19 -0700
|
||||
Subject: [PATCH] clk: iproc: Fix PLL output frequency calculation
|
||||
|
||||
This patch affects the clocks that use fractional ndivider in their
|
||||
PLL output frequency calculation. Instead of 2^20 divide factor, the
|
||||
clock's ndiv integer shift was used. Fixed the bug by replacing ndiv
|
||||
integer shift with 2^20 factor.
|
||||
|
||||
Signed-off-by: Simran Rai <ssimran@broadcom.com>
|
||||
Signed-off-by: Ray Jui <rjui@broadcom.com>
|
||||
Reviewed-by: Scott Branden <sbranden@broadcom.com>
|
||||
Fixes: 5fe225c105fd ("clk: iproc: add initial common clock support")
|
||||
Cc: <stable@vger.kernel.org> # v4.1+
|
||||
Signed-off-by: Michael Turquette <mturquette@baylibre.com>
|
||||
---
|
||||
drivers/clk/bcm/clk-iproc-pll.c | 13 +++++--------
|
||||
1 file changed, 5 insertions(+), 8 deletions(-)
|
||||
|
||||
--- a/drivers/clk/bcm/clk-iproc-pll.c
|
||||
+++ b/drivers/clk/bcm/clk-iproc-pll.c
|
||||
@@ -345,8 +345,8 @@ static unsigned long iproc_pll_recalc_ra
|
||||
struct iproc_pll *pll = clk->pll;
|
||||
const struct iproc_pll_ctrl *ctrl = pll->ctrl;
|
||||
u32 val;
|
||||
- u64 ndiv;
|
||||
- unsigned int ndiv_int, ndiv_frac, pdiv;
|
||||
+ u64 ndiv, ndiv_int, ndiv_frac;
|
||||
+ unsigned int pdiv;
|
||||
|
||||
if (parent_rate == 0)
|
||||
return 0;
|
||||
@@ -366,22 +366,19 @@ static unsigned long iproc_pll_recalc_ra
|
||||
val = readl(pll->pll_base + ctrl->ndiv_int.offset);
|
||||
ndiv_int = (val >> ctrl->ndiv_int.shift) &
|
||||
bit_mask(ctrl->ndiv_int.width);
|
||||
- ndiv = (u64)ndiv_int << ctrl->ndiv_int.shift;
|
||||
+ ndiv = ndiv_int << 20;
|
||||
|
||||
if (ctrl->flags & IPROC_CLK_PLL_HAS_NDIV_FRAC) {
|
||||
val = readl(pll->pll_base + ctrl->ndiv_frac.offset);
|
||||
ndiv_frac = (val >> ctrl->ndiv_frac.shift) &
|
||||
bit_mask(ctrl->ndiv_frac.width);
|
||||
-
|
||||
- if (ndiv_frac != 0)
|
||||
- ndiv = ((u64)ndiv_int << ctrl->ndiv_int.shift) |
|
||||
- ndiv_frac;
|
||||
+ ndiv += ndiv_frac;
|
||||
}
|
||||
|
||||
val = readl(pll->pll_base + ctrl->pdiv.offset);
|
||||
pdiv = (val >> ctrl->pdiv.shift) & bit_mask(ctrl->pdiv.width);
|
||||
|
||||
- clk->rate = (ndiv * parent_rate) >> ctrl->ndiv_int.shift;
|
||||
+ clk->rate = (ndiv * parent_rate) >> 20;
|
||||
|
||||
if (pdiv == 0)
|
||||
clk->rate *= 2;
|
@ -1,114 +0,0 @@
|
||||
From 128524b9db3e4f4245226852bee771bd03db75be Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Petr=20=C5=A0tetiar?= <ynezz@true.cz>
|
||||
Date: Tue, 3 Nov 2015 11:01:42 +0100
|
||||
Subject: [PATCH 1/2] USB: qcserial: Add support for Quectel EC20 Mini PCIe
|
||||
module
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
It seems like this device has same vendor and product IDs as G2K
|
||||
devices, but it has different number of interfaces(4 vs 5) and also
|
||||
different interface layout which makes it currently unusable:
|
||||
|
||||
usbcore: registered new interface driver qcserial
|
||||
usbserial: USB Serial support registered for Qualcomm USB modem
|
||||
usb 2-1.2: unknown number of interfaces: 5
|
||||
|
||||
lsusb output:
|
||||
|
||||
Bus 002 Device 003: ID 05c6:9215 Qualcomm, Inc. Acer Gobi 2000 Wireless
|
||||
Device Descriptor:
|
||||
bLength 18
|
||||
bDescriptorType 1
|
||||
bcdUSB 2.00
|
||||
bDeviceClass 0 (Defined at Interface level)
|
||||
bDeviceSubClass 0
|
||||
bDeviceProtocol 0
|
||||
bMaxPacketSize0 64
|
||||
idVendor 0x05c6 Qualcomm, Inc.
|
||||
idProduct 0x9215 Acer Gobi 2000 Wireless Modem
|
||||
bcdDevice 2.32
|
||||
iManufacturer 1 Quectel
|
||||
iProduct 2 Quectel LTE Module
|
||||
iSerial 0
|
||||
bNumConfigurations 1
|
||||
Configuration Descriptor:
|
||||
bLength 9
|
||||
bDescriptorType 2
|
||||
wTotalLength 209
|
||||
bNumInterfaces 5
|
||||
bConfigurationValue 1
|
||||
iConfiguration 0
|
||||
bmAttributes 0xa0
|
||||
(Bus Powered)
|
||||
Remote Wakeup
|
||||
MaxPower 500mA
|
||||
|
||||
Signed-off-by: Petr Štetiar <ynezz@true.cz>
|
||||
---
|
||||
drivers/usb/serial/qcserial.c | 39 +++++++++++++++++++++++++++++++++++++++
|
||||
1 file changed, 39 insertions(+)
|
||||
|
||||
--- a/drivers/usb/serial/qcserial.c
|
||||
+++ b/drivers/usb/serial/qcserial.c
|
||||
@@ -22,6 +22,8 @@
|
||||
#define DRIVER_AUTHOR "Qualcomm Inc"
|
||||
#define DRIVER_DESC "Qualcomm USB Serial driver"
|
||||
|
||||
+#define QUECTEL_EC20_IDPRODUCT 0x9215
|
||||
+
|
||||
/* standard device layouts supported by this driver */
|
||||
enum qcserial_layouts {
|
||||
QCSERIAL_G2K = 0, /* Gobi 2000 */
|
||||
@@ -167,6 +169,38 @@ static const struct usb_device_id id_tab
|
||||
};
|
||||
MODULE_DEVICE_TABLE(usb, id_table);
|
||||
|
||||
+static int handle_quectel_ec20(struct device *dev, int ifnum)
|
||||
+{
|
||||
+ int altsetting = 0;
|
||||
+
|
||||
+ /*
|
||||
+ * Quectel EC20 Mini PCIe LTE module layout:
|
||||
+ * 0: DM/DIAG (use libqcdm from ModemManager for communication)
|
||||
+ * 1: NMEA
|
||||
+ * 2: AT-capable modem port
|
||||
+ * 3: Modem interface
|
||||
+ * 4: NDIS
|
||||
+ */
|
||||
+ switch (ifnum) {
|
||||
+ case 0:
|
||||
+ dev_dbg(dev, "Quectel EC20 DM/DIAG interface found\n");
|
||||
+ break;
|
||||
+ case 1:
|
||||
+ dev_dbg(dev, "Quectel EC20 NMEA GPS interface found\n");
|
||||
+ break;
|
||||
+ case 2:
|
||||
+ case 3:
|
||||
+ dev_dbg(dev, "Quectel EC20 Modem port found\n");
|
||||
+ break;
|
||||
+ case 4:
|
||||
+ /* Don't claim the QMI/net interface */
|
||||
+ altsetting = -1;
|
||||
+ break;
|
||||
+ }
|
||||
+
|
||||
+ return altsetting;
|
||||
+}
|
||||
+
|
||||
static int qcprobe(struct usb_serial *serial, const struct usb_device_id *id)
|
||||
{
|
||||
struct usb_host_interface *intf = serial->interface->cur_altsetting;
|
||||
@@ -235,6 +269,11 @@ static int qcprobe(struct usb_serial *se
|
||||
altsetting = -1;
|
||||
break;
|
||||
case QCSERIAL_G2K:
|
||||
+ if (nintf == 5 && id->idProduct == QUECTEL_EC20_IDPRODUCT) {
|
||||
+ altsetting = handle_quectel_ec20(dev, ifnum);
|
||||
+ goto done;
|
||||
+ }
|
||||
+
|
||||
/*
|
||||
* Gobi 2K+ USB layout:
|
||||
* 0: QMI/net
|
@ -1,58 +0,0 @@
|
||||
From patchwork Tue Nov 3 23:59:28 2015
|
||||
Content-Type: text/plain; charset="utf-8"
|
||||
MIME-Version: 1.0
|
||||
Content-Transfer-Encoding: 7bit
|
||||
Subject: net: Fix prefsrc lookups
|
||||
From: David Ahern <dsa@cumulusnetworks.com>
|
||||
X-Patchwork-Id: 539645
|
||||
Message-Id: <1446595168-27323-1-git-send-email-dsa@cumulusnetworks.com>
|
||||
To: netdev@vger.kernel.org
|
||||
Cc: vladi@aresgate.net, David Ahern <dsa@cumulusnetworks.com>
|
||||
Date: Tue, 3 Nov 2015 15:59:28 -0800
|
||||
|
||||
A bug report (https://bugzilla.kernel.org/show_bug.cgi?id=107071) noted
|
||||
that the follwoing ip command is failing with v4.3:
|
||||
|
||||
$ ip route add 10.248.5.0/24 dev bond0.250 table vlan_250 src 10.248.5.154
|
||||
RTNETLINK answers: Invalid argument
|
||||
|
||||
021dd3b8a142d changed the lookup of the given preferred source address to
|
||||
use the table id passed in, but this assumes the local entries are in the
|
||||
given table which is not necessarily true for non-VRF use cases. When
|
||||
validating the preferred source fallback to the local table on failure.
|
||||
|
||||
Fixes: 021dd3b8a142d ("net: Add routes to the table associated with the device")
|
||||
Signed-off-by: David Ahern <dsa@cumulusnetworks.com>
|
||||
---
|
||||
This is needed in v4.3.
|
||||
|
||||
net/ipv4/fib_semantics.c | 13 ++++++++++---
|
||||
1 file changed, 10 insertions(+), 3 deletions(-)
|
||||
|
||||
--- a/net/ipv4/fib_semantics.c
|
||||
+++ b/net/ipv4/fib_semantics.c
|
||||
@@ -864,14 +864,21 @@ static bool fib_valid_prefsrc(struct fib
|
||||
if (cfg->fc_type != RTN_LOCAL || !cfg->fc_dst ||
|
||||
fib_prefsrc != cfg->fc_dst) {
|
||||
u32 tb_id = cfg->fc_table;
|
||||
+ int rc;
|
||||
|
||||
if (tb_id == RT_TABLE_MAIN)
|
||||
tb_id = RT_TABLE_LOCAL;
|
||||
|
||||
- if (inet_addr_type_table(cfg->fc_nlinfo.nl_net,
|
||||
- fib_prefsrc, tb_id) != RTN_LOCAL) {
|
||||
- return false;
|
||||
+ rc = inet_addr_type_table(cfg->fc_nlinfo.nl_net,
|
||||
+ fib_prefsrc, tb_id);
|
||||
+
|
||||
+ if (rc != RTN_LOCAL && tb_id != RT_TABLE_LOCAL) {
|
||||
+ rc = inet_addr_type_table(cfg->fc_nlinfo.nl_net,
|
||||
+ fib_prefsrc, RT_TABLE_LOCAL);
|
||||
}
|
||||
+
|
||||
+ if (rc != RTN_LOCAL)
|
||||
+ return false;
|
||||
}
|
||||
return true;
|
||||
}
|
@ -1,31 +1,31 @@
|
||||
--- a/arch/mips/include/asm/octeon/cvmx-bootinfo.h
|
||||
+++ b/arch/mips/include/asm/octeon/cvmx-bootinfo.h
|
||||
@@ -283,6 +283,8 @@ enum cvmx_board_types_enum {
|
||||
*/
|
||||
CVMX_BOARD_TYPE_CUST_PRIVATE_MIN = 20001,
|
||||
CVMX_BOARD_TYPE_UBNT_E100 = 20002,
|
||||
*/
|
||||
CVMX_BOARD_TYPE_CUST_PRIVATE_MIN = 20001,
|
||||
CVMX_BOARD_TYPE_UBNT_E100 = 20002,
|
||||
+ CVMX_BOARD_TYPE_UBNT_E200 = 20003,
|
||||
+ CVMX_BOARD_TYPE_UBNT_E220 = 20005,
|
||||
CVMX_BOARD_TYPE_CUST_DSR1000N = 20006,
|
||||
CVMX_BOARD_TYPE_KONTRON_S1901 = 21901,
|
||||
CVMX_BOARD_TYPE_CUST_PRIVATE_MAX = 30000,
|
||||
CVMX_BOARD_TYPE_CUST_DSR1000N = 20006,
|
||||
CVMX_BOARD_TYPE_KONTRON_S1901 = 21901,
|
||||
CVMX_BOARD_TYPE_CUST_PRIVATE_MAX = 30000,
|
||||
@@ -384,6 +386,8 @@ static inline const char *cvmx_board_typ
|
||||
/* Customer private range */
|
||||
ENUM_BRD_TYPE_CASE(CVMX_BOARD_TYPE_CUST_PRIVATE_MIN)
|
||||
ENUM_BRD_TYPE_CASE(CVMX_BOARD_TYPE_UBNT_E100)
|
||||
/* Customer private range */
|
||||
ENUM_BRD_TYPE_CASE(CVMX_BOARD_TYPE_CUST_PRIVATE_MIN)
|
||||
ENUM_BRD_TYPE_CASE(CVMX_BOARD_TYPE_UBNT_E100)
|
||||
+ ENUM_BRD_TYPE_CASE(CVMX_BOARD_TYPE_UBNT_E200)
|
||||
+ ENUM_BRD_TYPE_CASE(CVMX_BOARD_TYPE_UBNT_E220)
|
||||
ENUM_BRD_TYPE_CASE(CVMX_BOARD_TYPE_CUST_DSR1000N)
|
||||
ENUM_BRD_TYPE_CASE(CVMX_BOARD_TYPE_KONTRON_S1901)
|
||||
ENUM_BRD_TYPE_CASE(CVMX_BOARD_TYPE_CUST_PRIVATE_MAX)
|
||||
ENUM_BRD_TYPE_CASE(CVMX_BOARD_TYPE_CUST_DSR1000N)
|
||||
ENUM_BRD_TYPE_CASE(CVMX_BOARD_TYPE_KONTRON_S1901)
|
||||
ENUM_BRD_TYPE_CASE(CVMX_BOARD_TYPE_CUST_PRIVATE_MAX)
|
||||
--- a/arch/mips/cavium-octeon/executive/cvmx-helper-board.c
|
||||
+++ b/arch/mips/cavium-octeon/executive/cvmx-helper-board.c
|
||||
@@ -195,6 +195,8 @@ int cvmx_helper_board_get_mii_address(in
|
||||
return 8;
|
||||
else
|
||||
return -1;
|
||||
return 8;
|
||||
else
|
||||
return -1;
|
||||
+ case CVMX_BOARD_TYPE_UBNT_E200:
|
||||
+ return -1;
|
||||
case CVMX_BOARD_TYPE_KONTRON_S1901:
|
||||
if (ipd_port == CVMX_HELPER_BOARD_MGMT_IPD_PORT)
|
||||
return 1;
|
||||
case CVMX_BOARD_TYPE_KONTRON_S1901:
|
||||
if (ipd_port == CVMX_HELPER_BOARD_MGMT_IPD_PORT)
|
||||
return 1;
|
||||
|
Loading…
Reference in New Issue