This is the 4.9.297 stable release
-----BEGIN PGP SIGNATURE-----
iQIzBAABCAAdFiEEZH8oZUiU471FcZm+ONu9yGCSaT4FAmHdejgACgkQONu9yGCS
aT73xQ/+JkyRiZb0QcCNNPd3lFZ2ZmObHr3bXZGwn0BGsJ3aoqqG5PV9uUUAZH0d
BNsv+ETQOQ/4HDB3b+eYKxpnUeK1tXC6ZvqetADf5rSoDiCuHka4gFNHX8qUYwUv
YBicoYvx+6IStovLFCgGL1ZTXpn3aWU+oHzzNn4Kn1iniIf+faj391um9QYMjMOX
29M/PT4841onFjDsd1ndp0ONsQY1x1IGKOXwUgz9gd4xAbgBtAweb5+CtBwBPtw2
4BbPG/rYO+IGROoz29yNPZNaORX1jPOV+DUijklDmte2iIi5Abkh8SUZY78SwGDX
J2mj1PgsbNDO6svM1bZF7lopdbBmDpVfTAE+tALDSRv3h7KcLFwS8F0EieKmJGbN
Ixxm5gZ3D8xi9zgfolP4xbQ6oJJGxvjqcXyIeKXvs7aPCDbhSqjvsfkZBomSLMYQ
F3tIr7gkiLmr5QnRxcgwnmMlLXgH9cEiok0xD0qaMB+qZF26QGyT2WpniADamPkj
LXGEdYXKXN5LEb3EgYWPfZQiNX9DLkCiTtvWCIk2KlCXqkF68AlPWIe5t5TZaoOq
ag+BMvS8e8cMjNby7wR6X0LjmtdibtOr/tLD93tKRm0m6BlQv3LoxcINL+NiVRBx
QYmi0vriknJgNm8jS8GBoq89+tsQyJI3ehwBdV9whLUydANZ7V8=
=ECUm
-----END PGP SIGNATURE-----
Merge 4.9.297 into android-4.9-q
Changes in 4.9.297
Bluetooth: btusb: Apply QCA Rome patches for some ATH3012 models
tracing: Fix check for trace_percpu_buffer validity in get_trace_buf()
tracing: Tag trace_percpu_buffer as a percpu pointer
virtio_pci: Support surprise removal of virtio pci device
ieee802154: atusb: fix uninit value in atusb_set_extended_addr
mac80211: initialize variable have_higher_than_11mbit
i40e: Fix incorrect netdev's real number of RX/TX queues
sch_qfq: prevent shift-out-of-bounds in qfq_init_qdisc
xfs: map unwritten blocks in XFS_IOC_{ALLOC,FREE}SP just like fallocate
rndis_host: support Hytera digital radios
bug: split BUILD_BUG stuff out into <linux/build_bug.h>
arm64: Remove a redundancy in sysreg.h
arm64: reduce el2_setup branching
arm64: move !VHE work to end of el2_setup
arm64: sysreg: Move to use definitions for all the SCTLR bits
phonet: refcount leak in pep_sock_accep
scsi: libiscsi: Fix UAF in iscsi_conn_get_param()/iscsi_conn_teardown()
ip6_vti: initialize __ip6_tnl_parm struct in vti6_siocdevprivate
net: udp: fix alignment problem in udp4_seq_show()
mISDN: change function names to avoid conflicts
power: reset: ltc2952: Fix use of floating point literals
Linux 4.9.297
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Change-Id: I1b6c457971ca5e3b4d2354852a7eeeaccc965a46
This commit is contained in:
commit
93c6cebbd0
35 changed files with 308 additions and 195 deletions
2
Makefile
2
Makefile
|
|
@ -1,6 +1,6 @@
|
|||
VERSION = 4
|
||||
PATCHLEVEL = 9
|
||||
SUBLEVEL = 295
|
||||
SUBLEVEL = 297
|
||||
EXTRAVERSION =
|
||||
NAME = Roaring Lionus
|
||||
|
||||
|
|
|
|||
|
|
@ -20,6 +20,7 @@
|
|||
#ifndef __ASM_SYSREG_H
|
||||
#define __ASM_SYSREG_H
|
||||
|
||||
#include <asm/compiler.h>
|
||||
#include <linux/stringify.h>
|
||||
|
||||
#include <asm/opcodes.h>
|
||||
|
|
@ -88,25 +89,81 @@
|
|||
|
||||
/* Common SCTLR_ELx flags. */
|
||||
#define SCTLR_ELx_EE (1 << 25)
|
||||
#define SCTLR_ELx_WXN (1 << 19)
|
||||
#define SCTLR_ELx_I (1 << 12)
|
||||
#define SCTLR_ELx_SA (1 << 3)
|
||||
#define SCTLR_ELx_C (1 << 2)
|
||||
#define SCTLR_ELx_A (1 << 1)
|
||||
#define SCTLR_ELx_M 1
|
||||
|
||||
#define SCTLR_EL2_RES1 ((1 << 4) | (1 << 5) | (1 << 11) | (1 << 16) | \
|
||||
(1 << 16) | (1 << 18) | (1 << 22) | (1 << 23) | \
|
||||
(1 << 28) | (1 << 29))
|
||||
|
||||
#define SCTLR_ELx_FLAGS (SCTLR_ELx_M | SCTLR_ELx_A | SCTLR_ELx_C | \
|
||||
SCTLR_ELx_SA | SCTLR_ELx_I)
|
||||
|
||||
/* SCTLR_EL2 specific flags. */
|
||||
#define SCTLR_EL2_RES1 ((1 << 4) | (1 << 5) | (1 << 11) | (1 << 16) | \
|
||||
(1 << 18) | (1 << 22) | (1 << 23) | (1 << 28) | \
|
||||
(1 << 29))
|
||||
#define SCTLR_EL2_RES0 ((1 << 6) | (1 << 7) | (1 << 8) | (1 << 9) | \
|
||||
(1 << 10) | (1 << 13) | (1 << 14) | (1 << 15) | \
|
||||
(1 << 17) | (1 << 20) | (1 << 21) | (1 << 24) | \
|
||||
(1 << 26) | (1 << 27) | (1 << 30) | (1 << 31))
|
||||
|
||||
#ifdef CONFIG_CPU_BIG_ENDIAN
|
||||
#define ENDIAN_SET_EL2 SCTLR_ELx_EE
|
||||
#define ENDIAN_CLEAR_EL2 0
|
||||
#else
|
||||
#define ENDIAN_SET_EL2 0
|
||||
#define ENDIAN_CLEAR_EL2 SCTLR_ELx_EE
|
||||
#endif
|
||||
|
||||
/* SCTLR_EL2 value used for the hyp-stub */
|
||||
#define SCTLR_EL2_SET (ENDIAN_SET_EL2 | SCTLR_EL2_RES1)
|
||||
#define SCTLR_EL2_CLEAR (SCTLR_ELx_M | SCTLR_ELx_A | SCTLR_ELx_C | \
|
||||
SCTLR_ELx_SA | SCTLR_ELx_I | SCTLR_ELx_WXN | \
|
||||
ENDIAN_CLEAR_EL2 | SCTLR_EL2_RES0)
|
||||
|
||||
/* Check all the bits are accounted for */
|
||||
#define SCTLR_EL2_BUILD_BUG_ON_MISSING_BITS BUILD_BUG_ON((SCTLR_EL2_SET ^ SCTLR_EL2_CLEAR) != ~0)
|
||||
|
||||
|
||||
/* SCTLR_EL1 specific flags. */
|
||||
#define SCTLR_EL1_UCI (1 << 26)
|
||||
#define SCTLR_EL1_E0E (1 << 24)
|
||||
#define SCTLR_EL1_SPAN (1 << 23)
|
||||
#define SCTLR_EL1_NTWE (1 << 18)
|
||||
#define SCTLR_EL1_NTWI (1 << 16)
|
||||
#define SCTLR_EL1_UCT (1 << 15)
|
||||
#define SCTLR_EL1_DZE (1 << 14)
|
||||
#define SCTLR_EL1_UMA (1 << 9)
|
||||
#define SCTLR_EL1_SED (1 << 8)
|
||||
#define SCTLR_EL1_ITD (1 << 7)
|
||||
#define SCTLR_EL1_CP15BEN (1 << 5)
|
||||
#define SCTLR_EL1_SA0 (1 << 4)
|
||||
|
||||
#define SCTLR_EL1_RES1 ((1 << 11) | (1 << 20) | (1 << 22) | (1 << 28) | \
|
||||
(1 << 29))
|
||||
#define SCTLR_EL1_RES0 ((1 << 6) | (1 << 10) | (1 << 13) | (1 << 17) | \
|
||||
(1 << 21) | (1 << 27) | (1 << 30) | (1 << 31))
|
||||
|
||||
#ifdef CONFIG_CPU_BIG_ENDIAN
|
||||
#define ENDIAN_SET_EL1 (SCTLR_EL1_E0E | SCTLR_ELx_EE)
|
||||
#define ENDIAN_CLEAR_EL1 0
|
||||
#else
|
||||
#define ENDIAN_SET_EL1 0
|
||||
#define ENDIAN_CLEAR_EL1 (SCTLR_EL1_E0E | SCTLR_ELx_EE)
|
||||
#endif
|
||||
|
||||
#define SCTLR_EL1_SET (SCTLR_ELx_M | SCTLR_ELx_C | SCTLR_ELx_SA |\
|
||||
SCTLR_EL1_SA0 | SCTLR_EL1_SED | SCTLR_ELx_I |\
|
||||
SCTLR_EL1_DZE | SCTLR_EL1_UCT | SCTLR_EL1_NTWI |\
|
||||
SCTLR_EL1_NTWE | SCTLR_EL1_SPAN | ENDIAN_SET_EL1 |\
|
||||
SCTLR_EL1_UCI | SCTLR_EL1_RES1)
|
||||
#define SCTLR_EL1_CLEAR (SCTLR_ELx_A | SCTLR_EL1_CP15BEN | SCTLR_EL1_ITD |\
|
||||
SCTLR_EL1_UMA | SCTLR_ELx_WXN | ENDIAN_CLEAR_EL1 |\
|
||||
SCTLR_EL1_RES0)
|
||||
|
||||
/* Check all the bits are accounted for */
|
||||
#define SCTLR_EL1_BUILD_BUG_ON_MISSING_BITS BUILD_BUG_ON((SCTLR_EL1_SET ^ SCTLR_EL1_CLEAR) != ~0)
|
||||
|
||||
/* id_aa64isar0 */
|
||||
#define ID_AA64ISAR0_DP_SHIFT 44
|
||||
|
|
@ -248,6 +305,7 @@
|
|||
|
||||
#else
|
||||
|
||||
#include <linux/build_bug.h>
|
||||
#include <linux/types.h>
|
||||
|
||||
#define __DEFINE_MRS_MSR_S_REGNUM \
|
||||
|
|
@ -323,6 +381,9 @@ static inline void config_sctlr_el1(u32 clear, u32 set)
|
|||
{
|
||||
u32 val;
|
||||
|
||||
SCTLR_EL2_BUILD_BUG_ON_MISSING_BITS;
|
||||
SCTLR_EL1_BUILD_BUG_ON_MISSING_BITS;
|
||||
|
||||
val = read_sysreg(sctlr_el1);
|
||||
val &= ~clear;
|
||||
val |= set;
|
||||
|
|
|
|||
|
|
@ -490,21 +490,16 @@ ENTRY(el2_setup)
|
|||
msr SPsel, #1 // We want to use SP_EL{1,2}
|
||||
mrs x0, CurrentEL
|
||||
cmp x0, #CurrentEL_EL2
|
||||
b.ne 1f
|
||||
mrs x0, sctlr_el2
|
||||
CPU_BE( orr x0, x0, #(1 << 25) ) // Set the EE bit for EL2
|
||||
CPU_LE( bic x0, x0, #(1 << 25) ) // Clear the EE bit for EL2
|
||||
msr sctlr_el2, x0
|
||||
b 2f
|
||||
1: mrs x0, sctlr_el1
|
||||
CPU_BE( orr x0, x0, #(3 << 24) ) // Set the EE and E0E bits for EL1
|
||||
CPU_LE( bic x0, x0, #(3 << 24) ) // Clear the EE and E0E bits for EL1
|
||||
b.eq 1f
|
||||
mov_q x0, (SCTLR_EL1_RES1 | ENDIAN_SET_EL1)
|
||||
msr sctlr_el1, x0
|
||||
mov w0, #BOOT_CPU_MODE_EL1 // This cpu booted in EL1
|
||||
isb
|
||||
ret
|
||||
|
||||
2:
|
||||
1: mov_q x0, (SCTLR_EL2_RES1 | ENDIAN_SET_EL2)
|
||||
msr sctlr_el2, x0
|
||||
|
||||
#ifdef CONFIG_ARM64_VHE
|
||||
/*
|
||||
* Check for VHE being present. For the rest of the EL2 setup,
|
||||
|
|
@ -555,26 +550,6 @@ set_hcr:
|
|||
msr vpidr_el2, x0
|
||||
msr vmpidr_el2, x1
|
||||
|
||||
/*
|
||||
* When VHE is not in use, early init of EL2 and EL1 needs to be
|
||||
* done here.
|
||||
* When VHE _is_ in use, EL1 will not be used in the host and
|
||||
* requires no configuration, and all non-hyp-specific EL2 setup
|
||||
* will be done via the _EL1 system register aliases in __cpu_setup.
|
||||
*/
|
||||
cbnz x2, 1f
|
||||
|
||||
/* sctlr_el1 */
|
||||
mov x0, #0x0800 // Set/clear RES{1,0} bits
|
||||
CPU_BE( movk x0, #0x33d0, lsl #16 ) // Set EE and E0E on BE systems
|
||||
CPU_LE( movk x0, #0x30d0, lsl #16 ) // Clear EE and E0E on LE systems
|
||||
msr sctlr_el1, x0
|
||||
|
||||
/* Coprocessor traps. */
|
||||
mov x0, #0x33ff
|
||||
msr cptr_el2, x0 // Disable copro. traps to EL2
|
||||
1:
|
||||
|
||||
#ifdef CONFIG_COMPAT
|
||||
msr hstr_el2, xzr // Disable CP15 traps to EL2
|
||||
#endif
|
||||
|
|
@ -600,6 +575,20 @@ CPU_LE( movk x0, #0x30d0, lsl #16 ) // Clear EE and E0E on LE systems
|
|||
ret
|
||||
|
||||
install_el2_stub:
|
||||
/*
|
||||
* When VHE is not in use, early init of EL2 and EL1 needs to be
|
||||
* done here.
|
||||
* When VHE _is_ in use, EL1 will not be used in the host and
|
||||
* requires no configuration, and all non-hyp-specific EL2 setup
|
||||
* will be done via the _EL1 system register aliases in __cpu_setup.
|
||||
*/
|
||||
mov_q x0, (SCTLR_EL1_RES1 | ENDIAN_SET_EL1)
|
||||
msr sctlr_el1, x0
|
||||
|
||||
/* Coprocessor traps. */
|
||||
mov x0, #0x33ff
|
||||
msr cptr_el2, x0 // Disable copro. traps to EL2
|
||||
|
||||
/* Hypervisor stub */
|
||||
adrp x0, __hyp_stub_vectors
|
||||
add x0, x0, #:lo12:__hyp_stub_vectors
|
||||
|
|
|
|||
|
|
@ -428,11 +428,7 @@ ENTRY(__cpu_setup)
|
|||
/*
|
||||
* Prepare SCTLR
|
||||
*/
|
||||
adr x5, crval
|
||||
ldp w5, w6, [x5]
|
||||
mrs x0, sctlr_el1
|
||||
bic x0, x0, x5 // clear bits
|
||||
orr x0, x0, x6 // set bits
|
||||
mov_q x0, SCTLR_EL1_SET
|
||||
/*
|
||||
* Set/prepare TCR and TTBR. We use 512GB (39-bit) address range for
|
||||
* both user and kernel.
|
||||
|
|
@ -468,21 +464,3 @@ ENTRY(__cpu_setup)
|
|||
msr tcr_el1, x10
|
||||
ret // return to head.S
|
||||
ENDPROC(__cpu_setup)
|
||||
|
||||
/*
|
||||
* We set the desired value explicitly, including those of the
|
||||
* reserved bits. The values of bits EE & E0E were set early in
|
||||
* el2_setup, which are left untouched below.
|
||||
*
|
||||
* n n T
|
||||
* U E WT T UD US IHBS
|
||||
* CE0 XWHW CZ ME TEEA S
|
||||
* .... .IEE .... NEAI TE.I ..AD DEN0 ACAM
|
||||
* 0011 0... 1101 ..0. ..0. 10.. .0.. .... < hardware reserved
|
||||
* .... .1.. .... 01.1 11.1 ..01 0.01 1101 < software settings
|
||||
*/
|
||||
.type crval, #object
|
||||
crval:
|
||||
.word 0xfcffffff // clear
|
||||
.word 0x34d5d91d // set
|
||||
.popsection
|
||||
|
|
|
|||
|
|
@ -2442,11 +2442,9 @@ static const struct qca_device_info qca_devices_table[] = {
|
|||
{ 0x00000302, 28, 4, 18 }, /* Rome 3.2 */
|
||||
};
|
||||
|
||||
static int btusb_qca_send_vendor_req(struct hci_dev *hdev, u8 request,
|
||||
static int btusb_qca_send_vendor_req(struct usb_device *udev, u8 request,
|
||||
void *data, u16 size)
|
||||
{
|
||||
struct btusb_data *btdata = hci_get_drvdata(hdev);
|
||||
struct usb_device *udev = btdata->udev;
|
||||
int pipe, err;
|
||||
u8 *buf;
|
||||
|
||||
|
|
@ -2461,7 +2459,7 @@ static int btusb_qca_send_vendor_req(struct hci_dev *hdev, u8 request,
|
|||
err = usb_control_msg(udev, pipe, request, USB_TYPE_VENDOR | USB_DIR_IN,
|
||||
0, 0, buf, size, USB_CTRL_SET_TIMEOUT);
|
||||
if (err < 0) {
|
||||
BT_ERR("%s: Failed to access otp area (%d)", hdev->name, err);
|
||||
dev_err(&udev->dev, "Failed to access otp area (%d)", err);
|
||||
goto done;
|
||||
}
|
||||
|
||||
|
|
@ -2617,20 +2615,38 @@ static int btusb_setup_qca_load_nvm(struct hci_dev *hdev,
|
|||
return err;
|
||||
}
|
||||
|
||||
/* identify the ROM version and check whether patches are needed */
|
||||
static bool btusb_qca_need_patch(struct usb_device *udev)
|
||||
{
|
||||
struct qca_version ver;
|
||||
|
||||
if (btusb_qca_send_vendor_req(udev, QCA_GET_TARGET_VERSION, &ver,
|
||||
sizeof(ver)) < 0)
|
||||
return false;
|
||||
/* only low ROM versions need patches */
|
||||
return !(le32_to_cpu(ver.rom_version) & ~0xffffU);
|
||||
}
|
||||
|
||||
static int btusb_setup_qca(struct hci_dev *hdev)
|
||||
{
|
||||
struct btusb_data *btdata = hci_get_drvdata(hdev);
|
||||
struct usb_device *udev = btdata->udev;
|
||||
const struct qca_device_info *info = NULL;
|
||||
struct qca_version ver;
|
||||
u32 ver_rom;
|
||||
u8 status;
|
||||
int i, err;
|
||||
|
||||
err = btusb_qca_send_vendor_req(hdev, QCA_GET_TARGET_VERSION, &ver,
|
||||
err = btusb_qca_send_vendor_req(udev, QCA_GET_TARGET_VERSION, &ver,
|
||||
sizeof(ver));
|
||||
if (err < 0)
|
||||
return err;
|
||||
|
||||
ver_rom = le32_to_cpu(ver.rom_version);
|
||||
/* Don't care about high ROM versions */
|
||||
if (ver_rom & ~0xffffU)
|
||||
return 0;
|
||||
|
||||
for (i = 0; i < ARRAY_SIZE(qca_devices_table); i++) {
|
||||
if (ver_rom == qca_devices_table[i].rom_version)
|
||||
info = &qca_devices_table[i];
|
||||
|
|
@ -2641,7 +2657,7 @@ static int btusb_setup_qca(struct hci_dev *hdev)
|
|||
return -ENODEV;
|
||||
}
|
||||
|
||||
err = btusb_qca_send_vendor_req(hdev, QCA_CHECK_STATUS, &status,
|
||||
err = btusb_qca_send_vendor_req(udev, QCA_CHECK_STATUS, &status,
|
||||
sizeof(status));
|
||||
if (err < 0)
|
||||
return err;
|
||||
|
|
@ -2787,7 +2803,8 @@ static int btusb_probe(struct usb_interface *intf,
|
|||
|
||||
/* Old firmware would otherwise let ath3k driver load
|
||||
* patch and sysconfig files */
|
||||
if (le16_to_cpu(udev->descriptor.bcdDevice) <= 0x0001)
|
||||
if (le16_to_cpu(udev->descriptor.bcdDevice) <= 0x0001 &&
|
||||
!btusb_qca_need_patch(udev))
|
||||
return -ENODEV;
|
||||
}
|
||||
|
||||
|
|
@ -2937,6 +2954,7 @@ static int btusb_probe(struct usb_interface *intf,
|
|||
}
|
||||
|
||||
if (id->driver_info & BTUSB_ATH3012) {
|
||||
data->setup_on_usb = btusb_setup_qca;
|
||||
hdev->set_bdaddr = btusb_set_bdaddr_ath3012;
|
||||
set_bit(HCI_QUIRK_SIMULTANEOUS_DISCOVERY, &hdev->quirks);
|
||||
set_bit(HCI_QUIRK_STRICT_DUPLICATE_FILTER, &hdev->quirks);
|
||||
|
|
|
|||
|
|
@ -136,6 +136,7 @@ config HID_APPLEIR
|
|||
|
||||
config HID_ASUS
|
||||
tristate "Asus"
|
||||
depends on USB_HID
|
||||
depends on I2C_HID
|
||||
---help---
|
||||
Support for Asus notebook built-in keyboard via i2c.
|
||||
|
|
|
|||
|
|
@ -35,6 +35,7 @@
|
|||
#include <linux/module.h>
|
||||
#include <linux/input.h>
|
||||
#include <linux/serio.h>
|
||||
#include <asm/unaligned.h>
|
||||
|
||||
#define DRIVER_DESC "SpaceTec SpaceBall 2003/3003/4000 FLX driver"
|
||||
|
||||
|
|
@ -91,9 +92,15 @@ static void spaceball_process_packet(struct spaceball* spaceball)
|
|||
|
||||
case 'D': /* Ball data */
|
||||
if (spaceball->idx != 15) return;
|
||||
for (i = 0; i < 6; i++)
|
||||
/*
|
||||
* Skip first three bytes; read six axes worth of data.
|
||||
* Axis values are signed 16-bit big-endian.
|
||||
*/
|
||||
data += 3;
|
||||
for (i = 0; i < ARRAY_SIZE(spaceball_axes); i++) {
|
||||
input_report_abs(dev, spaceball_axes[i],
|
||||
(__s16)((data[2 * i + 3] << 8) | data[2 * i + 2]));
|
||||
(__s16)get_unaligned_be16(&data[i * 2]));
|
||||
}
|
||||
break;
|
||||
|
||||
case 'K': /* Button data */
|
||||
|
|
|
|||
|
|
@ -929,6 +929,8 @@ static int atp_probe(struct usb_interface *iface,
|
|||
set_bit(BTN_TOOL_TRIPLETAP, input_dev->keybit);
|
||||
set_bit(BTN_LEFT, input_dev->keybit);
|
||||
|
||||
INIT_WORK(&dev->work, atp_reinit);
|
||||
|
||||
error = input_register_device(dev->input);
|
||||
if (error)
|
||||
goto err_free_buffer;
|
||||
|
|
@ -936,8 +938,6 @@ static int atp_probe(struct usb_interface *iface,
|
|||
/* save our data pointer in this interface device */
|
||||
usb_set_intfdata(iface, dev);
|
||||
|
||||
INIT_WORK(&dev->work, atp_reinit);
|
||||
|
||||
return 0;
|
||||
|
||||
err_free_buffer:
|
||||
|
|
|
|||
|
|
@ -390,7 +390,7 @@ mISDNInit(void)
|
|||
err = mISDN_inittimer(&debug);
|
||||
if (err)
|
||||
goto error2;
|
||||
err = l1_init(&debug);
|
||||
err = Isdnl1_Init(&debug);
|
||||
if (err)
|
||||
goto error3;
|
||||
err = Isdnl2_Init(&debug);
|
||||
|
|
@ -404,7 +404,7 @@ mISDNInit(void)
|
|||
error5:
|
||||
Isdnl2_cleanup();
|
||||
error4:
|
||||
l1_cleanup();
|
||||
Isdnl1_cleanup();
|
||||
error3:
|
||||
mISDN_timer_cleanup();
|
||||
error2:
|
||||
|
|
@ -417,7 +417,7 @@ static void mISDN_cleanup(void)
|
|||
{
|
||||
misdn_sock_cleanup();
|
||||
Isdnl2_cleanup();
|
||||
l1_cleanup();
|
||||
Isdnl1_cleanup();
|
||||
mISDN_timer_cleanup();
|
||||
class_unregister(&mISDN_class);
|
||||
|
||||
|
|
|
|||
|
|
@ -69,8 +69,8 @@ struct Bprotocol *get_Bprotocol4id(u_int);
|
|||
extern int mISDN_inittimer(u_int *);
|
||||
extern void mISDN_timer_cleanup(void);
|
||||
|
||||
extern int l1_init(u_int *);
|
||||
extern void l1_cleanup(void);
|
||||
extern int Isdnl1_Init(u_int *);
|
||||
extern void Isdnl1_cleanup(void);
|
||||
extern int Isdnl2_Init(u_int *);
|
||||
extern void Isdnl2_cleanup(void);
|
||||
|
||||
|
|
|
|||
|
|
@ -407,7 +407,7 @@ create_l1(struct dchannel *dch, dchannel_l1callback *dcb) {
|
|||
EXPORT_SYMBOL(create_l1);
|
||||
|
||||
int
|
||||
l1_init(u_int *deb)
|
||||
Isdnl1_Init(u_int *deb)
|
||||
{
|
||||
debug = deb;
|
||||
l1fsm_s.state_count = L1S_STATE_COUNT;
|
||||
|
|
@ -419,7 +419,7 @@ l1_init(u_int *deb)
|
|||
}
|
||||
|
||||
void
|
||||
l1_cleanup(void)
|
||||
Isdnl1_cleanup(void)
|
||||
{
|
||||
mISDN_FsmFree(&l1fsm_s);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1658,7 +1658,7 @@ static int fman_port_probe(struct platform_device *of_dev)
|
|||
fman = dev_get_drvdata(&fm_pdev->dev);
|
||||
if (!fman) {
|
||||
err = -EINVAL;
|
||||
goto return_err;
|
||||
goto put_device;
|
||||
}
|
||||
|
||||
err = of_property_read_u32(port_node, "cell-index", &val);
|
||||
|
|
@ -1666,7 +1666,7 @@ static int fman_port_probe(struct platform_device *of_dev)
|
|||
dev_err(port->dev, "%s: reading cell-index for %s failed\n",
|
||||
__func__, port_node->full_name);
|
||||
err = -EINVAL;
|
||||
goto return_err;
|
||||
goto put_device;
|
||||
}
|
||||
port_id = (u8)val;
|
||||
port->dts_params.id = port_id;
|
||||
|
|
@ -1700,7 +1700,7 @@ static int fman_port_probe(struct platform_device *of_dev)
|
|||
} else {
|
||||
dev_err(port->dev, "%s: Illegal port type\n", __func__);
|
||||
err = -EINVAL;
|
||||
goto return_err;
|
||||
goto put_device;
|
||||
}
|
||||
|
||||
port->dts_params.type = port_type;
|
||||
|
|
@ -1714,7 +1714,7 @@ static int fman_port_probe(struct platform_device *of_dev)
|
|||
dev_err(port->dev, "%s: incorrect qman-channel-id\n",
|
||||
__func__);
|
||||
err = -EINVAL;
|
||||
goto return_err;
|
||||
goto put_device;
|
||||
}
|
||||
port->dts_params.qman_channel_id = qman_channel_id;
|
||||
}
|
||||
|
|
@ -1724,7 +1724,7 @@ static int fman_port_probe(struct platform_device *of_dev)
|
|||
dev_err(port->dev, "%s: of_address_to_resource() failed\n",
|
||||
__func__);
|
||||
err = -ENOMEM;
|
||||
goto return_err;
|
||||
goto put_device;
|
||||
}
|
||||
|
||||
port->dts_params.fman = fman;
|
||||
|
|
@ -1749,6 +1749,8 @@ static int fman_port_probe(struct platform_device *of_dev)
|
|||
|
||||
return 0;
|
||||
|
||||
put_device:
|
||||
put_device(&fm_pdev->dev);
|
||||
return_err:
|
||||
of_node_put(port_node);
|
||||
free_port:
|
||||
|
|
|
|||
|
|
@ -5429,6 +5429,27 @@ int i40e_open(struct net_device *netdev)
|
|||
return 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* i40e_netif_set_realnum_tx_rx_queues - Update number of tx/rx queues
|
||||
* @vsi: vsi structure
|
||||
*
|
||||
* This updates netdev's number of tx/rx queues
|
||||
*
|
||||
* Returns status of setting tx/rx queues
|
||||
**/
|
||||
static int i40e_netif_set_realnum_tx_rx_queues(struct i40e_vsi *vsi)
|
||||
{
|
||||
int ret;
|
||||
|
||||
ret = netif_set_real_num_rx_queues(vsi->netdev,
|
||||
vsi->num_queue_pairs);
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
return netif_set_real_num_tx_queues(vsi->netdev,
|
||||
vsi->num_queue_pairs);
|
||||
}
|
||||
|
||||
/**
|
||||
* i40e_vsi_open -
|
||||
* @vsi: the VSI to open
|
||||
|
|
@ -5463,13 +5484,7 @@ int i40e_vsi_open(struct i40e_vsi *vsi)
|
|||
goto err_setup_rx;
|
||||
|
||||
/* Notify the stack of the actual queue counts. */
|
||||
err = netif_set_real_num_tx_queues(vsi->netdev,
|
||||
vsi->num_queue_pairs);
|
||||
if (err)
|
||||
goto err_set_queues;
|
||||
|
||||
err = netif_set_real_num_rx_queues(vsi->netdev,
|
||||
vsi->num_queue_pairs);
|
||||
err = i40e_netif_set_realnum_tx_rx_queues(vsi);
|
||||
if (err)
|
||||
goto err_set_queues;
|
||||
|
||||
|
|
@ -9908,6 +9923,9 @@ struct i40e_vsi *i40e_vsi_setup(struct i40e_pf *pf, u8 type,
|
|||
case I40E_VSI_VMDQ2:
|
||||
case I40E_VSI_FCOE:
|
||||
ret = i40e_config_netdev(vsi);
|
||||
if (ret)
|
||||
goto err_netdev;
|
||||
ret = i40e_netif_set_realnum_tx_rx_queues(vsi);
|
||||
if (ret)
|
||||
goto err_netdev;
|
||||
ret = register_netdev(vsi->netdev);
|
||||
|
|
|
|||
|
|
@ -79,7 +79,9 @@ static int atusb_control_msg(struct atusb *atusb, unsigned int pipe,
|
|||
|
||||
ret = usb_control_msg(usb_dev, pipe, request, requesttype,
|
||||
value, index, data, size, timeout);
|
||||
if (ret < 0) {
|
||||
if (ret < size) {
|
||||
ret = ret < 0 ? ret : -ENODATA;
|
||||
|
||||
atusb->err = ret;
|
||||
dev_err(&usb_dev->dev,
|
||||
"atusb_control_msg: req 0x%02x val 0x%x idx 0x%x, error %d\n",
|
||||
|
|
@ -637,9 +639,9 @@ static int atusb_get_and_show_build(struct atusb *atusb)
|
|||
if (!build)
|
||||
return -ENOMEM;
|
||||
|
||||
ret = atusb_control_msg(atusb, usb_rcvctrlpipe(usb_dev, 0),
|
||||
ATUSB_BUILD, ATUSB_REQ_FROM_DEV, 0, 0,
|
||||
build, ATUSB_BUILD_SIZE, 1000);
|
||||
/* We cannot call atusb_control_msg() here, since this request may read various length data */
|
||||
ret = usb_control_msg(atusb->usb_dev, usb_rcvctrlpipe(usb_dev, 0), ATUSB_BUILD,
|
||||
ATUSB_REQ_FROM_DEV, 0, 0, build, ATUSB_BUILD_SIZE, 1000);
|
||||
if (ret >= 0) {
|
||||
build[ret] = 0;
|
||||
dev_info(&usb_dev->dev, "Firmware: build %s\n", build);
|
||||
|
|
|
|||
|
|
@ -619,6 +619,11 @@ static const struct usb_device_id products [] = {
|
|||
USB_DEVICE_AND_INTERFACE_INFO(0x1630, 0x0042,
|
||||
USB_CLASS_COMM, 2 /* ACM */, 0x0ff),
|
||||
.driver_info = (unsigned long) &rndis_poll_status_info,
|
||||
}, {
|
||||
/* Hytera Communications DMR radios' "Radio to PC Network" */
|
||||
USB_VENDOR_AND_INTERFACE_INFO(0x238b,
|
||||
USB_CLASS_COMM, 2 /* ACM */, 0x0ff),
|
||||
.driver_info = (unsigned long)&rndis_info,
|
||||
}, {
|
||||
/* RNDIS is MSFT's un-official variant of CDC ACM */
|
||||
USB_INTERFACE_INFO(USB_CLASS_COMM, 2 /* ACM */, 0x0ff),
|
||||
|
|
|
|||
|
|
@ -628,7 +628,7 @@ static int gmux_probe(struct pnp_dev *pnp, const struct pnp_device_id *id)
|
|||
}
|
||||
|
||||
gmux_data->iostart = res->start;
|
||||
gmux_data->iolen = res->end - res->start;
|
||||
gmux_data->iolen = resource_size(res);
|
||||
|
||||
if (gmux_data->iolen < GMUX_MIN_IO_LEN) {
|
||||
pr_err("gmux I/O region too small (%lu < %u)\n",
|
||||
|
|
|
|||
|
|
@ -169,8 +169,8 @@ static void ltc2952_poweroff_kill(void)
|
|||
|
||||
static void ltc2952_poweroff_default(struct ltc2952_poweroff *data)
|
||||
{
|
||||
data->wde_interval = ktime_set(0, 300L*1E6L);
|
||||
data->trigger_delay = ktime_set(2, 500L*1E6L);
|
||||
data->wde_interval = ktime_set(0, 300L * NSEC_PER_MSEC);
|
||||
data->trigger_delay = ktime_set(2, 500L * NSEC_PER_MSEC);
|
||||
|
||||
hrtimer_init(&data->timer_trigger, CLOCK_MONOTONIC, HRTIMER_MODE_REL);
|
||||
data->timer_trigger.function = ltc2952_poweroff_timer_trigger;
|
||||
|
|
|
|||
|
|
@ -2991,6 +2991,8 @@ void iscsi_conn_teardown(struct iscsi_cls_conn *cls_conn)
|
|||
{
|
||||
struct iscsi_conn *conn = cls_conn->dd_data;
|
||||
struct iscsi_session *session = conn->session;
|
||||
char *tmp_persistent_address = conn->persistent_address;
|
||||
char *tmp_local_ipaddr = conn->local_ipaddr;
|
||||
|
||||
del_timer_sync(&conn->transport_timer);
|
||||
|
||||
|
|
@ -3012,8 +3014,6 @@ void iscsi_conn_teardown(struct iscsi_cls_conn *cls_conn)
|
|||
spin_lock_bh(&session->frwd_lock);
|
||||
free_pages((unsigned long) conn->data,
|
||||
get_order(ISCSI_DEF_MAX_RECV_SEG_LEN));
|
||||
kfree(conn->persistent_address);
|
||||
kfree(conn->local_ipaddr);
|
||||
/* regular RX path uses back_lock */
|
||||
spin_lock_bh(&session->back_lock);
|
||||
kfifo_in(&session->cmdpool.queue, (void*)&conn->login_task,
|
||||
|
|
@ -3025,6 +3025,8 @@ void iscsi_conn_teardown(struct iscsi_cls_conn *cls_conn)
|
|||
mutex_unlock(&session->eh_mutex);
|
||||
|
||||
iscsi_destroy_conn(cls_conn);
|
||||
kfree(tmp_persistent_address);
|
||||
kfree(tmp_local_ipaddr);
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(iscsi_conn_teardown);
|
||||
|
||||
|
|
|
|||
|
|
@ -581,9 +581,12 @@ static void pvscsi_complete_request(struct pvscsi_adapter *adapter,
|
|||
* Commands like INQUIRY may transfer less data than
|
||||
* requested by the initiator via bufflen. Set residual
|
||||
* count to make upper layer aware of the actual amount
|
||||
* of data returned.
|
||||
* of data returned. There are cases when controller
|
||||
* returns zero dataLen with non zero data - do not set
|
||||
* residual count in that case.
|
||||
*/
|
||||
scsi_set_resid(cmd, scsi_bufflen(cmd) - e->dataLen);
|
||||
if (e->dataLen && (e->dataLen < scsi_bufflen(cmd)))
|
||||
scsi_set_resid(cmd, scsi_bufflen(cmd) - e->dataLen);
|
||||
cmd->result = (DID_OK << 16);
|
||||
break;
|
||||
|
||||
|
|
|
|||
|
|
@ -1667,11 +1667,15 @@ static void ffs_data_clear(struct ffs_data *ffs)
|
|||
|
||||
BUG_ON(ffs->gadget);
|
||||
|
||||
if (ffs->epfiles)
|
||||
if (ffs->epfiles) {
|
||||
ffs_epfiles_destroy(ffs->epfiles, ffs->eps_count);
|
||||
ffs->epfiles = NULL;
|
||||
}
|
||||
|
||||
if (ffs->ffs_eventfd)
|
||||
if (ffs->ffs_eventfd) {
|
||||
eventfd_ctx_put(ffs->ffs_eventfd);
|
||||
ffs->ffs_eventfd = NULL;
|
||||
}
|
||||
|
||||
kfree(ffs->raw_descs_data);
|
||||
kfree(ffs->raw_strings);
|
||||
|
|
@ -1684,7 +1688,6 @@ static void ffs_data_reset(struct ffs_data *ffs)
|
|||
|
||||
ffs_data_clear(ffs);
|
||||
|
||||
ffs->epfiles = NULL;
|
||||
ffs->raw_descs_data = NULL;
|
||||
ffs->raw_descs = NULL;
|
||||
ffs->raw_strings = NULL;
|
||||
|
|
|
|||
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue