Merge 4.19.301 into android-4.19-stable
Changes in 4.19.301 driver core: Release all resources during unbind before updating device links RDMA/irdma: Prevent zero-length STAG registration drm/panel: simple: Fix Innolux G101ICE-L01 timings ata: pata_isapnp: Add missing error check for devm_ioport_map() drm/rockchip: vop: Fix color for RGB888/BGR888 format on VOP full HID: core: store the unique system identifier in hid_device HID: fix HID device resource race between HID core and debugging support ipv4: Correct/silence an endian warning in __ip_do_redirect net: usb: ax88179_178a: fix failed operations during ax88179_reset arm/xen: fix xen_vcpu_info allocation alignment amd-xgbe: handle corner-case during sfp hotplug amd-xgbe: handle the corner-case during tx completion amd-xgbe: propagate the correct speed and duplex status net: axienet: Fix check for partial TX checksum MIPS: KVM: Fix a build warning about variable set but not used arm64: cpufeature: Extract capped perfmon fields KVM: arm64: limit PMU version to PMUv3 for ARMv8.1 mtd: rawnand: brcmnand: Fix ecc chunk calculation for erased page bitfips bcache: replace a mistaken IS_ERR() by IS_ERR_OR_NULL() in btree_gc_coalesce() s390/dasd: protect device queue against concurrent access USB: serial: option: add Luat Air72*U series products hv_netvsc: Fix race of register_netdevice_notifier and VF register hv_netvsc: Mark VF as slave before exposing it to user-mode dm-delay: fix a race between delay_presuspend and delay_bio bcache: check return value from btree_node_alloc_replacement() bcache: prevent potential division by zero error USB: serial: option: add Fibocom L7xx modules USB: serial: option: fix FM101R-GL defines USB: serial: option: don't claim interface 4 for ZTE MF290 USB: dwc2: write HCINT with INTMASK applied usb: dwc3: set the dma max_seg_size USB: dwc3: qcom: fix wakeup after probe deferral pinctrl: avoid reload of p state in list iteration firewire: core: fix possible memory leak in create_units() mmc: block: Do not lose cache flush during CQE error recovery ALSA: hda: Disable power-save on KONTRON SinglePC ALSA: hda/realtek: Headset Mic VREF to 100% dm-verity: align struct dm_verity_fec_io properly dm verity: don't perform FEC for failed readahead IO bcache: revert replacing IS_ERR_OR_NULL with IS_ERR powerpc: Don't clobber f0/vs0 during fp|altivec register save btrfs: fix off-by-one when checking chunk map includes logical address btrfs: send: ensure send_fd is writable Input: xpad - add HyperX Clutch Gladiate Support ipv4: igmp: fix refcnt uaf issue when receiving igmp query packet ravb: Fix races between ravb_tx_timeout_work() and net related ops net: ravb: Start TX queues after HW initialization succeeded smb3: fix touch -h of symlink s390/mm: fix phys vs virt confusion in mark_kernel_pXd() functions family s390/cmma: fix detection of DAT pages mtd: cfi_cmdset_0001: Support the absence of protection registers mtd: cfi_cmdset_0001: Byte swap OTP info fbdev: stifb: Make the STI next font pointer a 32-bit signed offset ima: annotate iint mutex to avoid lockdep false positive warnings ovl: skip overlayfs superblocks at global sync ima: detect changes to the backing overlay file cpufreq: imx6q: don't warn for disabling a non-existing frequency cpufreq: imx6q: Don't disable 792 Mhz OPP unnecessarily mmc: cqhci: Increase recovery halt timeout mmc: cqhci: Warn of halt or task clear failure mmc: cqhci: Fix task clearing in CQE error recovery mmc: core: convert comma to semicolon mmc: block: Retry commands in CQE error recovery Linux 4.19.301 Change-Id: I51ad863523191dbe636079135c4b706c1a317d26 Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
This commit is contained in:
2
Makefile
2
Makefile
@@ -1,7 +1,7 @@
|
|||||||
# SPDX-License-Identifier: GPL-2.0
|
# SPDX-License-Identifier: GPL-2.0
|
||||||
VERSION = 4
|
VERSION = 4
|
||||||
PATCHLEVEL = 19
|
PATCHLEVEL = 19
|
||||||
SUBLEVEL = 300
|
SUBLEVEL = 301
|
||||||
EXTRAVERSION =
|
EXTRAVERSION =
|
||||||
NAME = "People's Front"
|
NAME = "People's Front"
|
||||||
|
|
||||||
|
|||||||
@@ -388,7 +388,8 @@ static int __init xen_guest_init(void)
|
|||||||
* for secondary CPUs as they are brought up.
|
* for secondary CPUs as they are brought up.
|
||||||
* For uniformity we use VCPUOP_register_vcpu_info even on cpu0.
|
* For uniformity we use VCPUOP_register_vcpu_info even on cpu0.
|
||||||
*/
|
*/
|
||||||
xen_vcpu_info = alloc_percpu(struct vcpu_info);
|
xen_vcpu_info = __alloc_percpu(sizeof(struct vcpu_info),
|
||||||
|
1 << fls(sizeof(struct vcpu_info) - 1));
|
||||||
if (xen_vcpu_info == NULL)
|
if (xen_vcpu_info == NULL)
|
||||||
return -ENOMEM;
|
return -ENOMEM;
|
||||||
|
|
||||||
|
|||||||
@@ -422,6 +422,29 @@ cpuid_feature_extract_unsigned_field(u64 features, int field)
|
|||||||
return cpuid_feature_extract_unsigned_field_width(features, field, 4);
|
return cpuid_feature_extract_unsigned_field_width(features, field, 4);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Fields that identify the version of the Performance Monitors Extension do
|
||||||
|
* not follow the standard ID scheme. See ARM DDI 0487E.a page D13-2825,
|
||||||
|
* "Alternative ID scheme used for the Performance Monitors Extension version".
|
||||||
|
*/
|
||||||
|
static inline u64 __attribute_const__
|
||||||
|
cpuid_feature_cap_perfmon_field(u64 features, int field, u64 cap)
|
||||||
|
{
|
||||||
|
u64 val = cpuid_feature_extract_unsigned_field(features, field);
|
||||||
|
u64 mask = GENMASK_ULL(field + 3, field);
|
||||||
|
|
||||||
|
/* Treat IMPLEMENTATION DEFINED functionality as unimplemented */
|
||||||
|
if (val == 0xf)
|
||||||
|
val = 0;
|
||||||
|
|
||||||
|
if (val > cap) {
|
||||||
|
features &= ~mask;
|
||||||
|
features |= (cap << field) & mask;
|
||||||
|
}
|
||||||
|
|
||||||
|
return features;
|
||||||
|
}
|
||||||
|
|
||||||
static inline u64 arm64_ftr_mask(const struct arm64_ftr_bits *ftrp)
|
static inline u64 arm64_ftr_mask(const struct arm64_ftr_bits *ftrp)
|
||||||
{
|
{
|
||||||
return (u64)GENMASK(ftrp->shift + ftrp->width - 1, ftrp->shift);
|
return (u64)GENMASK(ftrp->shift + ftrp->width - 1, ftrp->shift);
|
||||||
|
|||||||
@@ -632,6 +632,12 @@
|
|||||||
#define ID_AA64DFR0_TRACEVER_SHIFT 4
|
#define ID_AA64DFR0_TRACEVER_SHIFT 4
|
||||||
#define ID_AA64DFR0_DEBUGVER_SHIFT 0
|
#define ID_AA64DFR0_DEBUGVER_SHIFT 0
|
||||||
|
|
||||||
|
#define ID_AA64DFR0_PMUVER_8_1 0x4
|
||||||
|
|
||||||
|
#define ID_DFR0_PERFMON_SHIFT 24
|
||||||
|
|
||||||
|
#define ID_DFR0_PERFMON_8_1 0x4
|
||||||
|
|
||||||
#define ID_ISAR5_RDM_SHIFT 24
|
#define ID_ISAR5_RDM_SHIFT 24
|
||||||
#define ID_ISAR5_CRC32_SHIFT 16
|
#define ID_ISAR5_CRC32_SHIFT 16
|
||||||
#define ID_ISAR5_SHA2_SHIFT 12
|
#define ID_ISAR5_SHA2_SHIFT 12
|
||||||
|
|||||||
@@ -1049,6 +1049,16 @@ static u64 read_id_reg(struct sys_reg_desc const *r, bool raz)
|
|||||||
kvm_debug("LORegions unsupported for guests, suppressing\n");
|
kvm_debug("LORegions unsupported for guests, suppressing\n");
|
||||||
|
|
||||||
val &= ~(0xfUL << ID_AA64MMFR1_LOR_SHIFT);
|
val &= ~(0xfUL << ID_AA64MMFR1_LOR_SHIFT);
|
||||||
|
} else if (id == SYS_ID_AA64DFR0_EL1) {
|
||||||
|
/* Limit guests to PMUv3 for ARMv8.1 */
|
||||||
|
val = cpuid_feature_cap_perfmon_field(val,
|
||||||
|
ID_AA64DFR0_PMUVER_SHIFT,
|
||||||
|
ID_AA64DFR0_PMUVER_8_1);
|
||||||
|
} else if (id == SYS_ID_DFR0_EL1) {
|
||||||
|
/* Limit guests to PMUv3 for ARMv8.1 */
|
||||||
|
val = cpuid_feature_cap_perfmon_field(val,
|
||||||
|
ID_DFR0_PERFMON_SHIFT,
|
||||||
|
ID_DFR0_PERFMON_8_1);
|
||||||
}
|
}
|
||||||
|
|
||||||
return val;
|
return val;
|
||||||
|
|||||||
@@ -692,7 +692,7 @@ static int kvm_mips_map_page(struct kvm_vcpu *vcpu, unsigned long gpa,
|
|||||||
gfn_t gfn = gpa >> PAGE_SHIFT;
|
gfn_t gfn = gpa >> PAGE_SHIFT;
|
||||||
int srcu_idx, err;
|
int srcu_idx, err;
|
||||||
kvm_pfn_t pfn;
|
kvm_pfn_t pfn;
|
||||||
pte_t *ptep, entry, old_pte;
|
pte_t *ptep, entry;
|
||||||
bool writeable;
|
bool writeable;
|
||||||
unsigned long prot_bits;
|
unsigned long prot_bits;
|
||||||
unsigned long mmu_seq;
|
unsigned long mmu_seq;
|
||||||
@@ -765,7 +765,6 @@ static int kvm_mips_map_page(struct kvm_vcpu *vcpu, unsigned long gpa,
|
|||||||
entry = pfn_pte(pfn, __pgprot(prot_bits));
|
entry = pfn_pte(pfn, __pgprot(prot_bits));
|
||||||
|
|
||||||
/* Write the PTE */
|
/* Write the PTE */
|
||||||
old_pte = *ptep;
|
|
||||||
set_pte(ptep, entry);
|
set_pte(ptep, entry);
|
||||||
|
|
||||||
err = 0;
|
err = 0;
|
||||||
|
|||||||
@@ -29,6 +29,15 @@
|
|||||||
#include <asm/feature-fixups.h>
|
#include <asm/feature-fixups.h>
|
||||||
|
|
||||||
#ifdef CONFIG_VSX
|
#ifdef CONFIG_VSX
|
||||||
|
#define __REST_1FPVSR(n,c,base) \
|
||||||
|
BEGIN_FTR_SECTION \
|
||||||
|
b 2f; \
|
||||||
|
END_FTR_SECTION_IFSET(CPU_FTR_VSX); \
|
||||||
|
REST_FPR(n,base); \
|
||||||
|
b 3f; \
|
||||||
|
2: REST_VSR(n,c,base); \
|
||||||
|
3:
|
||||||
|
|
||||||
#define __REST_32FPVSRS(n,c,base) \
|
#define __REST_32FPVSRS(n,c,base) \
|
||||||
BEGIN_FTR_SECTION \
|
BEGIN_FTR_SECTION \
|
||||||
b 2f; \
|
b 2f; \
|
||||||
@@ -47,9 +56,11 @@ END_FTR_SECTION_IFSET(CPU_FTR_VSX); \
|
|||||||
2: SAVE_32VSRS(n,c,base); \
|
2: SAVE_32VSRS(n,c,base); \
|
||||||
3:
|
3:
|
||||||
#else
|
#else
|
||||||
|
#define __REST_1FPVSR(n,b,base) REST_FPR(n, base)
|
||||||
#define __REST_32FPVSRS(n,b,base) REST_32FPRS(n, base)
|
#define __REST_32FPVSRS(n,b,base) REST_32FPRS(n, base)
|
||||||
#define __SAVE_32FPVSRS(n,b,base) SAVE_32FPRS(n, base)
|
#define __SAVE_32FPVSRS(n,b,base) SAVE_32FPRS(n, base)
|
||||||
#endif
|
#endif
|
||||||
|
#define REST_1FPVSR(n,c,base) __REST_1FPVSR(n,__REG_##c,__REG_##base)
|
||||||
#define REST_32FPVSRS(n,c,base) __REST_32FPVSRS(n,__REG_##c,__REG_##base)
|
#define REST_32FPVSRS(n,c,base) __REST_32FPVSRS(n,__REG_##c,__REG_##base)
|
||||||
#define SAVE_32FPVSRS(n,c,base) __SAVE_32FPVSRS(n,__REG_##c,__REG_##base)
|
#define SAVE_32FPVSRS(n,c,base) __SAVE_32FPVSRS(n,__REG_##c,__REG_##base)
|
||||||
|
|
||||||
@@ -72,6 +83,7 @@ _GLOBAL(store_fp_state)
|
|||||||
SAVE_32FPVSRS(0, R4, R3)
|
SAVE_32FPVSRS(0, R4, R3)
|
||||||
mffs fr0
|
mffs fr0
|
||||||
stfd fr0,FPSTATE_FPSCR(r3)
|
stfd fr0,FPSTATE_FPSCR(r3)
|
||||||
|
REST_1FPVSR(0, R4, R3)
|
||||||
blr
|
blr
|
||||||
EXPORT_SYMBOL(store_fp_state)
|
EXPORT_SYMBOL(store_fp_state)
|
||||||
|
|
||||||
@@ -136,6 +148,7 @@ _GLOBAL(save_fpu)
|
|||||||
2: SAVE_32FPVSRS(0, R4, R6)
|
2: SAVE_32FPVSRS(0, R4, R6)
|
||||||
mffs fr0
|
mffs fr0
|
||||||
stfd fr0,FPSTATE_FPSCR(r6)
|
stfd fr0,FPSTATE_FPSCR(r6)
|
||||||
|
REST_1FPVSR(0, R4, R6)
|
||||||
blr
|
blr
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|||||||
@@ -31,6 +31,7 @@ _GLOBAL(store_vr_state)
|
|||||||
mfvscr v0
|
mfvscr v0
|
||||||
li r4, VRSTATE_VSCR
|
li r4, VRSTATE_VSCR
|
||||||
stvx v0, r4, r3
|
stvx v0, r4, r3
|
||||||
|
lvx v0, 0, r3
|
||||||
blr
|
blr
|
||||||
EXPORT_SYMBOL(store_vr_state)
|
EXPORT_SYMBOL(store_vr_state)
|
||||||
|
|
||||||
@@ -101,6 +102,7 @@ _GLOBAL(save_altivec)
|
|||||||
mfvscr v0
|
mfvscr v0
|
||||||
li r4,VRSTATE_VSCR
|
li r4,VRSTATE_VSCR
|
||||||
stvx v0,r4,r7
|
stvx v0,r4,r7
|
||||||
|
lvx v0,0,r7
|
||||||
blr
|
blr
|
||||||
|
|
||||||
#ifdef CONFIG_VSX
|
#ifdef CONFIG_VSX
|
||||||
|
|||||||
@@ -118,7 +118,7 @@ static void mark_kernel_pmd(pud_t *pud, unsigned long addr, unsigned long end)
|
|||||||
next = pmd_addr_end(addr, end);
|
next = pmd_addr_end(addr, end);
|
||||||
if (pmd_none(*pmd) || pmd_large(*pmd))
|
if (pmd_none(*pmd) || pmd_large(*pmd))
|
||||||
continue;
|
continue;
|
||||||
page = virt_to_page(pmd_val(*pmd));
|
page = phys_to_page(pmd_val(*pmd));
|
||||||
set_bit(PG_arch_1, &page->flags);
|
set_bit(PG_arch_1, &page->flags);
|
||||||
} while (pmd++, addr = next, addr != end);
|
} while (pmd++, addr = next, addr != end);
|
||||||
}
|
}
|
||||||
@@ -136,8 +136,8 @@ static void mark_kernel_pud(p4d_t *p4d, unsigned long addr, unsigned long end)
|
|||||||
if (pud_none(*pud) || pud_large(*pud))
|
if (pud_none(*pud) || pud_large(*pud))
|
||||||
continue;
|
continue;
|
||||||
if (!pud_folded(*pud)) {
|
if (!pud_folded(*pud)) {
|
||||||
page = virt_to_page(pud_val(*pud));
|
page = phys_to_page(pud_val(*pud));
|
||||||
for (i = 0; i < 3; i++)
|
for (i = 0; i < 4; i++)
|
||||||
set_bit(PG_arch_1, &page[i].flags);
|
set_bit(PG_arch_1, &page[i].flags);
|
||||||
}
|
}
|
||||||
mark_kernel_pmd(pud, addr, next);
|
mark_kernel_pmd(pud, addr, next);
|
||||||
@@ -157,8 +157,8 @@ static void mark_kernel_p4d(pgd_t *pgd, unsigned long addr, unsigned long end)
|
|||||||
if (p4d_none(*p4d))
|
if (p4d_none(*p4d))
|
||||||
continue;
|
continue;
|
||||||
if (!p4d_folded(*p4d)) {
|
if (!p4d_folded(*p4d)) {
|
||||||
page = virt_to_page(p4d_val(*p4d));
|
page = phys_to_page(p4d_val(*p4d));
|
||||||
for (i = 0; i < 3; i++)
|
for (i = 0; i < 4; i++)
|
||||||
set_bit(PG_arch_1, &page[i].flags);
|
set_bit(PG_arch_1, &page[i].flags);
|
||||||
}
|
}
|
||||||
mark_kernel_pud(p4d, addr, next);
|
mark_kernel_pud(p4d, addr, next);
|
||||||
@@ -179,8 +179,8 @@ static void mark_kernel_pgd(void)
|
|||||||
if (pgd_none(*pgd))
|
if (pgd_none(*pgd))
|
||||||
continue;
|
continue;
|
||||||
if (!pgd_folded(*pgd)) {
|
if (!pgd_folded(*pgd)) {
|
||||||
page = virt_to_page(pgd_val(*pgd));
|
page = phys_to_page(pgd_val(*pgd));
|
||||||
for (i = 0; i < 3; i++)
|
for (i = 0; i < 4; i++)
|
||||||
set_bit(PG_arch_1, &page[i].flags);
|
set_bit(PG_arch_1, &page[i].flags);
|
||||||
}
|
}
|
||||||
mark_kernel_p4d(pgd, addr, next);
|
mark_kernel_p4d(pgd, addr, next);
|
||||||
|
|||||||
@@ -81,6 +81,9 @@ static int isapnp_init_one(struct pnp_dev *idev, const struct pnp_device_id *dev
|
|||||||
if (pnp_port_valid(idev, 1)) {
|
if (pnp_port_valid(idev, 1)) {
|
||||||
ctl_addr = devm_ioport_map(&idev->dev,
|
ctl_addr = devm_ioport_map(&idev->dev,
|
||||||
pnp_port_start(idev, 1), 1);
|
pnp_port_start(idev, 1), 1);
|
||||||
|
if (!ctl_addr)
|
||||||
|
return -ENOMEM;
|
||||||
|
|
||||||
ap->ioaddr.altstatus_addr = ctl_addr;
|
ap->ioaddr.altstatus_addr = ctl_addr;
|
||||||
ap->ioaddr.ctl_addr = ctl_addr;
|
ap->ioaddr.ctl_addr = ctl_addr;
|
||||||
ap->ops = &isapnp_port_ops;
|
ap->ops = &isapnp_port_ops;
|
||||||
|
|||||||
@@ -995,8 +995,6 @@ static void __device_release_driver(struct device *dev, struct device *parent)
|
|||||||
else if (drv->remove)
|
else if (drv->remove)
|
||||||
drv->remove(dev);
|
drv->remove(dev);
|
||||||
|
|
||||||
device_links_driver_cleanup(dev);
|
|
||||||
|
|
||||||
devres_release_all(dev);
|
devres_release_all(dev);
|
||||||
dma_deconfigure(dev);
|
dma_deconfigure(dev);
|
||||||
dev->driver = NULL;
|
dev->driver = NULL;
|
||||||
@@ -1006,6 +1004,8 @@ static void __device_release_driver(struct device *dev, struct device *parent)
|
|||||||
pm_runtime_reinit(dev);
|
pm_runtime_reinit(dev);
|
||||||
dev_pm_set_driver_flags(dev, 0);
|
dev_pm_set_driver_flags(dev, 0);
|
||||||
|
|
||||||
|
device_links_driver_cleanup(dev);
|
||||||
|
|
||||||
klist_remove(&dev->p->knode_driver);
|
klist_remove(&dev->p->knode_driver);
|
||||||
device_pm_check_callbacks(dev);
|
device_pm_check_callbacks(dev);
|
||||||
if (dev->bus)
|
if (dev->bus)
|
||||||
|
|||||||
@@ -240,6 +240,14 @@ static struct cpufreq_driver imx6q_cpufreq_driver = {
|
|||||||
.suspend = cpufreq_generic_suspend,
|
.suspend = cpufreq_generic_suspend,
|
||||||
};
|
};
|
||||||
|
|
||||||
|
static void imx6x_disable_freq_in_opp(struct device *dev, unsigned long freq)
|
||||||
|
{
|
||||||
|
int ret = dev_pm_opp_disable(dev, freq);
|
||||||
|
|
||||||
|
if (ret < 0 && ret != -ENODEV)
|
||||||
|
dev_warn(dev, "failed to disable %ldMHz OPP\n", freq / 1000000);
|
||||||
|
}
|
||||||
|
|
||||||
#define OCOTP_CFG3 0x440
|
#define OCOTP_CFG3 0x440
|
||||||
#define OCOTP_CFG3_SPEED_SHIFT 16
|
#define OCOTP_CFG3_SPEED_SHIFT 16
|
||||||
#define OCOTP_CFG3_SPEED_1P2GHZ 0x3
|
#define OCOTP_CFG3_SPEED_1P2GHZ 0x3
|
||||||
@@ -275,17 +283,15 @@ static void imx6q_opp_check_speed_grading(struct device *dev)
|
|||||||
val &= 0x3;
|
val &= 0x3;
|
||||||
|
|
||||||
if (val < OCOTP_CFG3_SPEED_996MHZ)
|
if (val < OCOTP_CFG3_SPEED_996MHZ)
|
||||||
if (dev_pm_opp_disable(dev, 996000000))
|
imx6x_disable_freq_in_opp(dev, 996000000);
|
||||||
dev_warn(dev, "failed to disable 996MHz OPP\n");
|
|
||||||
|
|
||||||
if (of_machine_is_compatible("fsl,imx6q") ||
|
if (of_machine_is_compatible("fsl,imx6q") ||
|
||||||
of_machine_is_compatible("fsl,imx6qp")) {
|
of_machine_is_compatible("fsl,imx6qp")) {
|
||||||
if (val != OCOTP_CFG3_SPEED_852MHZ)
|
if (val != OCOTP_CFG3_SPEED_852MHZ)
|
||||||
if (dev_pm_opp_disable(dev, 852000000))
|
imx6x_disable_freq_in_opp(dev, 852000000);
|
||||||
dev_warn(dev, "failed to disable 852MHz OPP\n");
|
|
||||||
if (val != OCOTP_CFG3_SPEED_1P2GHZ)
|
if (val != OCOTP_CFG3_SPEED_1P2GHZ)
|
||||||
if (dev_pm_opp_disable(dev, 1200000000))
|
imx6x_disable_freq_in_opp(dev, 1200000000);
|
||||||
dev_warn(dev, "failed to disable 1.2GHz OPP\n");
|
|
||||||
}
|
}
|
||||||
iounmap(base);
|
iounmap(base);
|
||||||
put_node:
|
put_node:
|
||||||
@@ -338,20 +344,16 @@ static int imx6ul_opp_check_speed_grading(struct device *dev)
|
|||||||
val >>= OCOTP_CFG3_SPEED_SHIFT;
|
val >>= OCOTP_CFG3_SPEED_SHIFT;
|
||||||
val &= 0x3;
|
val &= 0x3;
|
||||||
|
|
||||||
if (of_machine_is_compatible("fsl,imx6ul")) {
|
if (of_machine_is_compatible("fsl,imx6ul"))
|
||||||
if (val != OCOTP_CFG3_6UL_SPEED_696MHZ)
|
if (val != OCOTP_CFG3_6UL_SPEED_696MHZ)
|
||||||
if (dev_pm_opp_disable(dev, 696000000))
|
imx6x_disable_freq_in_opp(dev, 696000000);
|
||||||
dev_warn(dev, "failed to disable 696MHz OPP\n");
|
|
||||||
}
|
|
||||||
|
|
||||||
if (of_machine_is_compatible("fsl,imx6ull")) {
|
if (of_machine_is_compatible("fsl,imx6ull")) {
|
||||||
if (val != OCOTP_CFG3_6ULL_SPEED_792MHZ)
|
if (val < OCOTP_CFG3_6ULL_SPEED_792MHZ)
|
||||||
if (dev_pm_opp_disable(dev, 792000000))
|
imx6x_disable_freq_in_opp(dev, 792000000);
|
||||||
dev_warn(dev, "failed to disable 792MHz OPP\n");
|
|
||||||
|
|
||||||
if (val != OCOTP_CFG3_6ULL_SPEED_900MHZ)
|
if (val != OCOTP_CFG3_6ULL_SPEED_900MHZ)
|
||||||
if (dev_pm_opp_disable(dev, 900000000))
|
imx6x_disable_freq_in_opp(dev, 900000000);
|
||||||
dev_warn(dev, "failed to disable 900MHz OPP\n");
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return ret;
|
return ret;
|
||||||
|
|||||||
@@ -732,14 +732,11 @@ static void create_units(struct fw_device *device)
|
|||||||
fw_unit_attributes,
|
fw_unit_attributes,
|
||||||
&unit->attribute_group);
|
&unit->attribute_group);
|
||||||
|
|
||||||
if (device_register(&unit->device) < 0)
|
|
||||||
goto skip_unit;
|
|
||||||
|
|
||||||
fw_device_get(device);
|
fw_device_get(device);
|
||||||
continue;
|
if (device_register(&unit->device) < 0) {
|
||||||
|
put_device(&unit->device);
|
||||||
skip_unit:
|
continue;
|
||||||
kfree(unit);
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1261,13 +1261,13 @@ static const struct panel_desc innolux_g070y2_l01 = {
|
|||||||
static const struct display_timing innolux_g101ice_l01_timing = {
|
static const struct display_timing innolux_g101ice_l01_timing = {
|
||||||
.pixelclock = { 60400000, 71100000, 74700000 },
|
.pixelclock = { 60400000, 71100000, 74700000 },
|
||||||
.hactive = { 1280, 1280, 1280 },
|
.hactive = { 1280, 1280, 1280 },
|
||||||
.hfront_porch = { 41, 80, 100 },
|
.hfront_porch = { 30, 60, 70 },
|
||||||
.hback_porch = { 40, 79, 99 },
|
.hback_porch = { 30, 60, 70 },
|
||||||
.hsync_len = { 1, 1, 1 },
|
.hsync_len = { 22, 40, 60 },
|
||||||
.vactive = { 800, 800, 800 },
|
.vactive = { 800, 800, 800 },
|
||||||
.vfront_porch = { 5, 11, 14 },
|
.vfront_porch = { 3, 8, 14 },
|
||||||
.vback_porch = { 4, 11, 14 },
|
.vback_porch = { 3, 8, 14 },
|
||||||
.vsync_len = { 1, 1, 1 },
|
.vsync_len = { 4, 7, 12 },
|
||||||
.flags = DISPLAY_FLAGS_DE_HIGH,
|
.flags = DISPLAY_FLAGS_DE_HIGH,
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
@@ -204,14 +204,22 @@ static inline void vop_cfg_done(struct vop *vop)
|
|||||||
VOP_REG_SET(vop, common, cfg_done, 1);
|
VOP_REG_SET(vop, common, cfg_done, 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
static bool has_rb_swapped(uint32_t format)
|
static bool has_rb_swapped(uint32_t version, uint32_t format)
|
||||||
{
|
{
|
||||||
switch (format) {
|
switch (format) {
|
||||||
case DRM_FORMAT_XBGR8888:
|
case DRM_FORMAT_XBGR8888:
|
||||||
case DRM_FORMAT_ABGR8888:
|
case DRM_FORMAT_ABGR8888:
|
||||||
case DRM_FORMAT_BGR888:
|
|
||||||
case DRM_FORMAT_BGR565:
|
case DRM_FORMAT_BGR565:
|
||||||
return true;
|
return true;
|
||||||
|
/*
|
||||||
|
* full framework (IP version 3.x) only need rb swapped for RGB888 and
|
||||||
|
* little framework (IP version 2.x) only need rb swapped for BGR888,
|
||||||
|
* check for 3.x to also only rb swap BGR888 for unknown vop version
|
||||||
|
*/
|
||||||
|
case DRM_FORMAT_RGB888:
|
||||||
|
return VOP_MAJOR(version) == 3;
|
||||||
|
case DRM_FORMAT_BGR888:
|
||||||
|
return VOP_MAJOR(version) != 3;
|
||||||
default:
|
default:
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@@ -798,7 +806,7 @@ static void vop_plane_atomic_update(struct drm_plane *plane,
|
|||||||
VOP_WIN_SET(vop, win, dsp_info, dsp_info);
|
VOP_WIN_SET(vop, win, dsp_info, dsp_info);
|
||||||
VOP_WIN_SET(vop, win, dsp_st, dsp_st);
|
VOP_WIN_SET(vop, win, dsp_st, dsp_st);
|
||||||
|
|
||||||
rb_swap = has_rb_swapped(fb->format->format);
|
rb_swap = has_rb_swapped(vop->data->version, fb->format->format);
|
||||||
VOP_WIN_SET(vop, win, rb_swap, rb_swap);
|
VOP_WIN_SET(vop, win, rb_swap, rb_swap);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|||||||
@@ -701,15 +701,22 @@ static void hid_close_report(struct hid_device *device)
|
|||||||
* Free a device structure, all reports, and all fields.
|
* Free a device structure, all reports, and all fields.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
static void hid_device_release(struct device *dev)
|
void hiddev_free(struct kref *ref)
|
||||||
{
|
{
|
||||||
struct hid_device *hid = to_hid_device(dev);
|
struct hid_device *hid = container_of(ref, struct hid_device, ref);
|
||||||
|
|
||||||
hid_close_report(hid);
|
hid_close_report(hid);
|
||||||
kfree(hid->dev_rdesc);
|
kfree(hid->dev_rdesc);
|
||||||
kfree(hid);
|
kfree(hid);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static void hid_device_release(struct device *dev)
|
||||||
|
{
|
||||||
|
struct hid_device *hid = to_hid_device(dev);
|
||||||
|
|
||||||
|
kref_put(&hid->ref, hiddev_free);
|
||||||
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Fetch a report description item from the data stream. We support long
|
* Fetch a report description item from the data stream. We support long
|
||||||
* items, though they are not used yet.
|
* items, though they are not used yet.
|
||||||
@@ -2259,10 +2266,12 @@ int hid_add_device(struct hid_device *hdev)
|
|||||||
hid_warn(hdev, "bad device descriptor (%d)\n", ret);
|
hid_warn(hdev, "bad device descriptor (%d)\n", ret);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
hdev->id = atomic_inc_return(&id);
|
||||||
|
|
||||||
/* XXX hack, any other cleaner solution after the driver core
|
/* XXX hack, any other cleaner solution after the driver core
|
||||||
* is converted to allow more than 20 bytes as the device name? */
|
* is converted to allow more than 20 bytes as the device name? */
|
||||||
dev_set_name(&hdev->dev, "%04X:%04X:%04X.%04X", hdev->bus,
|
dev_set_name(&hdev->dev, "%04X:%04X:%04X.%04X", hdev->bus,
|
||||||
hdev->vendor, hdev->product, atomic_inc_return(&id));
|
hdev->vendor, hdev->product, hdev->id);
|
||||||
|
|
||||||
hid_debug_register(hdev, dev_name(&hdev->dev));
|
hid_debug_register(hdev, dev_name(&hdev->dev));
|
||||||
ret = device_add(&hdev->dev);
|
ret = device_add(&hdev->dev);
|
||||||
@@ -2305,6 +2314,7 @@ struct hid_device *hid_allocate_device(void)
|
|||||||
spin_lock_init(&hdev->debug_list_lock);
|
spin_lock_init(&hdev->debug_list_lock);
|
||||||
sema_init(&hdev->driver_input_lock, 1);
|
sema_init(&hdev->driver_input_lock, 1);
|
||||||
mutex_init(&hdev->ll_open_lock);
|
mutex_init(&hdev->ll_open_lock);
|
||||||
|
kref_init(&hdev->ref);
|
||||||
|
|
||||||
return hdev;
|
return hdev;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1096,6 +1096,7 @@ static int hid_debug_events_open(struct inode *inode, struct file *file)
|
|||||||
goto out;
|
goto out;
|
||||||
}
|
}
|
||||||
list->hdev = (struct hid_device *) inode->i_private;
|
list->hdev = (struct hid_device *) inode->i_private;
|
||||||
|
kref_get(&list->hdev->ref);
|
||||||
file->private_data = list;
|
file->private_data = list;
|
||||||
mutex_init(&list->read_mutex);
|
mutex_init(&list->read_mutex);
|
||||||
|
|
||||||
@@ -1188,6 +1189,8 @@ static int hid_debug_events_release(struct inode *inode, struct file *file)
|
|||||||
list_del(&list->node);
|
list_del(&list->node);
|
||||||
spin_unlock_irqrestore(&list->hdev->debug_list_lock, flags);
|
spin_unlock_irqrestore(&list->hdev->debug_list_lock, flags);
|
||||||
kfifo_free(&list->hid_debug_fifo);
|
kfifo_free(&list->hid_debug_fifo);
|
||||||
|
|
||||||
|
kref_put(&list->hdev->ref, hiddev_free);
|
||||||
kfree(list);
|
kfree(list);
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
|
|||||||
@@ -2945,6 +2945,9 @@ static enum i40iw_status_code i40iw_sc_alloc_stag(
|
|||||||
u64 header;
|
u64 header;
|
||||||
enum i40iw_page_size page_size;
|
enum i40iw_page_size page_size;
|
||||||
|
|
||||||
|
if (!info->total_len && !info->all_memory)
|
||||||
|
return -EINVAL;
|
||||||
|
|
||||||
page_size = (info->page_size == 0x200000) ? I40IW_PAGE_SIZE_2M : I40IW_PAGE_SIZE_4K;
|
page_size = (info->page_size == 0x200000) ? I40IW_PAGE_SIZE_2M : I40IW_PAGE_SIZE_4K;
|
||||||
cqp = dev->cqp;
|
cqp = dev->cqp;
|
||||||
wqe = i40iw_sc_cqp_get_next_send_wqe(cqp, scratch);
|
wqe = i40iw_sc_cqp_get_next_send_wqe(cqp, scratch);
|
||||||
@@ -3003,6 +3006,9 @@ static enum i40iw_status_code i40iw_sc_mr_reg_non_shared(
|
|||||||
u8 addr_type;
|
u8 addr_type;
|
||||||
enum i40iw_page_size page_size;
|
enum i40iw_page_size page_size;
|
||||||
|
|
||||||
|
if (!info->total_len && !info->all_memory)
|
||||||
|
return -EINVAL;
|
||||||
|
|
||||||
page_size = (info->page_size == 0x200000) ? I40IW_PAGE_SIZE_2M : I40IW_PAGE_SIZE_4K;
|
page_size = (info->page_size == 0x200000) ? I40IW_PAGE_SIZE_2M : I40IW_PAGE_SIZE_4K;
|
||||||
if (info->access_rights & (I40IW_ACCESS_FLAGS_REMOTEREAD_ONLY |
|
if (info->access_rights & (I40IW_ACCESS_FLAGS_REMOTEREAD_ONLY |
|
||||||
I40IW_ACCESS_FLAGS_REMOTEWRITE_ONLY))
|
I40IW_ACCESS_FLAGS_REMOTEWRITE_ONLY))
|
||||||
|
|||||||
@@ -779,6 +779,7 @@ struct i40iw_allocate_stag_info {
|
|||||||
bool use_hmc_fcn_index;
|
bool use_hmc_fcn_index;
|
||||||
u8 hmc_fcn_index;
|
u8 hmc_fcn_index;
|
||||||
bool use_pf_rid;
|
bool use_pf_rid;
|
||||||
|
bool all_memory;
|
||||||
};
|
};
|
||||||
|
|
||||||
struct i40iw_reg_ns_stag_info {
|
struct i40iw_reg_ns_stag_info {
|
||||||
@@ -797,6 +798,7 @@ struct i40iw_reg_ns_stag_info {
|
|||||||
bool use_hmc_fcn_index;
|
bool use_hmc_fcn_index;
|
||||||
u8 hmc_fcn_index;
|
u8 hmc_fcn_index;
|
||||||
bool use_pf_rid;
|
bool use_pf_rid;
|
||||||
|
bool all_memory;
|
||||||
};
|
};
|
||||||
|
|
||||||
struct i40iw_fast_reg_stag_info {
|
struct i40iw_fast_reg_stag_info {
|
||||||
|
|||||||
@@ -1581,7 +1581,8 @@ static int i40iw_handle_q_mem(struct i40iw_device *iwdev,
|
|||||||
static int i40iw_hw_alloc_stag(struct i40iw_device *iwdev, struct i40iw_mr *iwmr)
|
static int i40iw_hw_alloc_stag(struct i40iw_device *iwdev, struct i40iw_mr *iwmr)
|
||||||
{
|
{
|
||||||
struct i40iw_allocate_stag_info *info;
|
struct i40iw_allocate_stag_info *info;
|
||||||
struct i40iw_pd *iwpd = to_iwpd(iwmr->ibmr.pd);
|
struct ib_pd *pd = iwmr->ibmr.pd;
|
||||||
|
struct i40iw_pd *iwpd = to_iwpd(pd);
|
||||||
enum i40iw_status_code status;
|
enum i40iw_status_code status;
|
||||||
int err = 0;
|
int err = 0;
|
||||||
struct i40iw_cqp_request *cqp_request;
|
struct i40iw_cqp_request *cqp_request;
|
||||||
@@ -1598,6 +1599,7 @@ static int i40iw_hw_alloc_stag(struct i40iw_device *iwdev, struct i40iw_mr *iwmr
|
|||||||
info->stag_idx = iwmr->stag >> I40IW_CQPSQ_STAG_IDX_SHIFT;
|
info->stag_idx = iwmr->stag >> I40IW_CQPSQ_STAG_IDX_SHIFT;
|
||||||
info->pd_id = iwpd->sc_pd.pd_id;
|
info->pd_id = iwpd->sc_pd.pd_id;
|
||||||
info->total_len = iwmr->length;
|
info->total_len = iwmr->length;
|
||||||
|
info->all_memory = pd->flags & IB_PD_UNSAFE_GLOBAL_RKEY;
|
||||||
info->remote_access = true;
|
info->remote_access = true;
|
||||||
cqp_info->cqp_cmd = OP_ALLOC_STAG;
|
cqp_info->cqp_cmd = OP_ALLOC_STAG;
|
||||||
cqp_info->post_sq = 1;
|
cqp_info->post_sq = 1;
|
||||||
@@ -1651,6 +1653,8 @@ static struct ib_mr *i40iw_alloc_mr(struct ib_pd *pd,
|
|||||||
iwmr->type = IW_MEMREG_TYPE_MEM;
|
iwmr->type = IW_MEMREG_TYPE_MEM;
|
||||||
palloc = &iwpbl->pble_alloc;
|
palloc = &iwpbl->pble_alloc;
|
||||||
iwmr->page_cnt = max_num_sg;
|
iwmr->page_cnt = max_num_sg;
|
||||||
|
/* Use system PAGE_SIZE as the sg page sizes are unknown at this point */
|
||||||
|
iwmr->length = max_num_sg * PAGE_SIZE;
|
||||||
mutex_lock(&iwdev->pbl_mutex);
|
mutex_lock(&iwdev->pbl_mutex);
|
||||||
status = i40iw_get_pble(&iwdev->sc_dev, iwdev->pble_rsrc, palloc, iwmr->page_cnt);
|
status = i40iw_get_pble(&iwdev->sc_dev, iwdev->pble_rsrc, palloc, iwmr->page_cnt);
|
||||||
mutex_unlock(&iwdev->pbl_mutex);
|
mutex_unlock(&iwdev->pbl_mutex);
|
||||||
@@ -1747,7 +1751,8 @@ static int i40iw_hwreg_mr(struct i40iw_device *iwdev,
|
|||||||
{
|
{
|
||||||
struct i40iw_pbl *iwpbl = &iwmr->iwpbl;
|
struct i40iw_pbl *iwpbl = &iwmr->iwpbl;
|
||||||
struct i40iw_reg_ns_stag_info *stag_info;
|
struct i40iw_reg_ns_stag_info *stag_info;
|
||||||
struct i40iw_pd *iwpd = to_iwpd(iwmr->ibmr.pd);
|
struct ib_pd *pd = iwmr->ibmr.pd;
|
||||||
|
struct i40iw_pd *iwpd = to_iwpd(pd);
|
||||||
struct i40iw_pble_alloc *palloc = &iwpbl->pble_alloc;
|
struct i40iw_pble_alloc *palloc = &iwpbl->pble_alloc;
|
||||||
enum i40iw_status_code status;
|
enum i40iw_status_code status;
|
||||||
int err = 0;
|
int err = 0;
|
||||||
@@ -1767,6 +1772,7 @@ static int i40iw_hwreg_mr(struct i40iw_device *iwdev,
|
|||||||
stag_info->total_len = iwmr->length;
|
stag_info->total_len = iwmr->length;
|
||||||
stag_info->access_rights = access;
|
stag_info->access_rights = access;
|
||||||
stag_info->pd_id = iwpd->sc_pd.pd_id;
|
stag_info->pd_id = iwpd->sc_pd.pd_id;
|
||||||
|
stag_info->all_memory = pd->flags & IB_PD_UNSAFE_GLOBAL_RKEY;
|
||||||
stag_info->addr_type = I40IW_ADDR_TYPE_VA_BASED;
|
stag_info->addr_type = I40IW_ADDR_TYPE_VA_BASED;
|
||||||
stag_info->page_size = iwmr->page_size;
|
stag_info->page_size = iwmr->page_size;
|
||||||
|
|
||||||
|
|||||||
@@ -133,6 +133,7 @@ static const struct xpad_device {
|
|||||||
{ 0x044f, 0x0f07, "Thrustmaster, Inc. Controller", 0, XTYPE_XBOX },
|
{ 0x044f, 0x0f07, "Thrustmaster, Inc. Controller", 0, XTYPE_XBOX },
|
||||||
{ 0x044f, 0x0f10, "Thrustmaster Modena GT Wheel", 0, XTYPE_XBOX },
|
{ 0x044f, 0x0f10, "Thrustmaster Modena GT Wheel", 0, XTYPE_XBOX },
|
||||||
{ 0x044f, 0xb326, "Thrustmaster Gamepad GP XID", 0, XTYPE_XBOX360 },
|
{ 0x044f, 0xb326, "Thrustmaster Gamepad GP XID", 0, XTYPE_XBOX360 },
|
||||||
|
{ 0x03f0, 0x0495, "HyperX Clutch Gladiate", 0, XTYPE_XBOXONE },
|
||||||
{ 0x045e, 0x0202, "Microsoft X-Box pad v1 (US)", 0, XTYPE_XBOX },
|
{ 0x045e, 0x0202, "Microsoft X-Box pad v1 (US)", 0, XTYPE_XBOX },
|
||||||
{ 0x045e, 0x0285, "Microsoft X-Box pad (Japan)", 0, XTYPE_XBOX },
|
{ 0x045e, 0x0285, "Microsoft X-Box pad (Japan)", 0, XTYPE_XBOX },
|
||||||
{ 0x045e, 0x0287, "Microsoft Xbox Controller S", 0, XTYPE_XBOX },
|
{ 0x045e, 0x0287, "Microsoft Xbox Controller S", 0, XTYPE_XBOX },
|
||||||
@@ -445,6 +446,7 @@ static const struct usb_device_id xpad_table[] = {
|
|||||||
XPAD_XBOX360_VENDOR(0x0079), /* GPD Win 2 Controller */
|
XPAD_XBOX360_VENDOR(0x0079), /* GPD Win 2 Controller */
|
||||||
XPAD_XBOX360_VENDOR(0x03eb), /* Wooting Keyboards (Legacy) */
|
XPAD_XBOX360_VENDOR(0x03eb), /* Wooting Keyboards (Legacy) */
|
||||||
XPAD_XBOX360_VENDOR(0x044f), /* Thrustmaster X-Box 360 controllers */
|
XPAD_XBOX360_VENDOR(0x044f), /* Thrustmaster X-Box 360 controllers */
|
||||||
|
XPAD_XBOXONE_VENDOR(0x03f0), /* HP HyperX Xbox One Controllers */
|
||||||
XPAD_XBOX360_VENDOR(0x045e), /* Microsoft X-Box 360 controllers */
|
XPAD_XBOX360_VENDOR(0x045e), /* Microsoft X-Box 360 controllers */
|
||||||
XPAD_XBOXONE_VENDOR(0x045e), /* Microsoft X-Box One controllers */
|
XPAD_XBOXONE_VENDOR(0x045e), /* Microsoft X-Box One controllers */
|
||||||
XPAD_XBOX360_VENDOR(0x046d), /* Logitech X-Box 360 style controllers */
|
XPAD_XBOX360_VENDOR(0x046d), /* Logitech X-Box 360 style controllers */
|
||||||
|
|||||||
@@ -1379,7 +1379,7 @@ static int btree_gc_coalesce(struct btree *b, struct btree_op *op,
|
|||||||
memset(new_nodes, 0, sizeof(new_nodes));
|
memset(new_nodes, 0, sizeof(new_nodes));
|
||||||
closure_init_stack(&cl);
|
closure_init_stack(&cl);
|
||||||
|
|
||||||
while (nodes < GC_MERGE_NODES && !IS_ERR(r[nodes].b))
|
while (nodes < GC_MERGE_NODES && !IS_ERR_OR_NULL(r[nodes].b))
|
||||||
keys += r[nodes++].keys;
|
keys += r[nodes++].keys;
|
||||||
|
|
||||||
blocks = btree_default_blocks(b->c) * 2 / 3;
|
blocks = btree_default_blocks(b->c) * 2 / 3;
|
||||||
@@ -1526,7 +1526,7 @@ static int btree_gc_coalesce(struct btree *b, struct btree_op *op,
|
|||||||
atomic_dec(&b->c->prio_blocked);
|
atomic_dec(&b->c->prio_blocked);
|
||||||
|
|
||||||
for (i = 0; i < nodes; i++)
|
for (i = 0; i < nodes; i++)
|
||||||
if (!IS_ERR(new_nodes[i])) {
|
if (!IS_ERR_OR_NULL(new_nodes[i])) {
|
||||||
btree_node_free(new_nodes[i]);
|
btree_node_free(new_nodes[i]);
|
||||||
rw_unlock(true, new_nodes[i]);
|
rw_unlock(true, new_nodes[i]);
|
||||||
}
|
}
|
||||||
@@ -1543,6 +1543,8 @@ static int btree_gc_rewrite_node(struct btree *b, struct btree_op *op,
|
|||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
n = btree_node_alloc_replacement(replace, NULL);
|
n = btree_node_alloc_replacement(replace, NULL);
|
||||||
|
if (IS_ERR(n))
|
||||||
|
return 0;
|
||||||
|
|
||||||
/* recheck reserve after allocating replacement node */
|
/* recheck reserve after allocating replacement node */
|
||||||
if (btree_check_reserve(b, NULL)) {
|
if (btree_check_reserve(b, NULL)) {
|
||||||
|
|||||||
@@ -992,7 +992,7 @@ SHOW(__bch_cache)
|
|||||||
sum += INITIAL_PRIO - cached[i];
|
sum += INITIAL_PRIO - cached[i];
|
||||||
|
|
||||||
if (n)
|
if (n)
|
||||||
do_div(sum, n);
|
sum = div64_u64(sum, n);
|
||||||
|
|
||||||
for (i = 0; i < ARRAY_SIZE(q); i++)
|
for (i = 0; i < ARRAY_SIZE(q); i++)
|
||||||
q[i] = INITIAL_PRIO - cached[n * (i + 1) /
|
q[i] = INITIAL_PRIO - cached[n * (i + 1) /
|
||||||
|
|||||||
@@ -30,7 +30,7 @@ struct delay_c {
|
|||||||
struct workqueue_struct *kdelayd_wq;
|
struct workqueue_struct *kdelayd_wq;
|
||||||
struct work_struct flush_expired_bios;
|
struct work_struct flush_expired_bios;
|
||||||
struct list_head delayed_bios;
|
struct list_head delayed_bios;
|
||||||
atomic_t may_delay;
|
bool may_delay;
|
||||||
|
|
||||||
struct delay_class read;
|
struct delay_class read;
|
||||||
struct delay_class write;
|
struct delay_class write;
|
||||||
@@ -191,7 +191,7 @@ static int delay_ctr(struct dm_target *ti, unsigned int argc, char **argv)
|
|||||||
INIT_WORK(&dc->flush_expired_bios, flush_expired_bios);
|
INIT_WORK(&dc->flush_expired_bios, flush_expired_bios);
|
||||||
INIT_LIST_HEAD(&dc->delayed_bios);
|
INIT_LIST_HEAD(&dc->delayed_bios);
|
||||||
mutex_init(&dc->timer_lock);
|
mutex_init(&dc->timer_lock);
|
||||||
atomic_set(&dc->may_delay, 1);
|
dc->may_delay = true;
|
||||||
dc->argc = argc;
|
dc->argc = argc;
|
||||||
|
|
||||||
ret = delay_class_ctr(ti, &dc->read, argv);
|
ret = delay_class_ctr(ti, &dc->read, argv);
|
||||||
@@ -245,7 +245,7 @@ static int delay_bio(struct delay_c *dc, struct delay_class *c, struct bio *bio)
|
|||||||
struct dm_delay_info *delayed;
|
struct dm_delay_info *delayed;
|
||||||
unsigned long expires = 0;
|
unsigned long expires = 0;
|
||||||
|
|
||||||
if (!c->delay || !atomic_read(&dc->may_delay))
|
if (!c->delay)
|
||||||
return DM_MAPIO_REMAPPED;
|
return DM_MAPIO_REMAPPED;
|
||||||
|
|
||||||
delayed = dm_per_bio_data(bio, sizeof(struct dm_delay_info));
|
delayed = dm_per_bio_data(bio, sizeof(struct dm_delay_info));
|
||||||
@@ -254,6 +254,10 @@ static int delay_bio(struct delay_c *dc, struct delay_class *c, struct bio *bio)
|
|||||||
delayed->expires = expires = jiffies + msecs_to_jiffies(c->delay);
|
delayed->expires = expires = jiffies + msecs_to_jiffies(c->delay);
|
||||||
|
|
||||||
mutex_lock(&delayed_bios_lock);
|
mutex_lock(&delayed_bios_lock);
|
||||||
|
if (unlikely(!dc->may_delay)) {
|
||||||
|
mutex_unlock(&delayed_bios_lock);
|
||||||
|
return DM_MAPIO_REMAPPED;
|
||||||
|
}
|
||||||
c->ops++;
|
c->ops++;
|
||||||
list_add_tail(&delayed->list, &dc->delayed_bios);
|
list_add_tail(&delayed->list, &dc->delayed_bios);
|
||||||
mutex_unlock(&delayed_bios_lock);
|
mutex_unlock(&delayed_bios_lock);
|
||||||
@@ -267,7 +271,10 @@ static void delay_presuspend(struct dm_target *ti)
|
|||||||
{
|
{
|
||||||
struct delay_c *dc = ti->private;
|
struct delay_c *dc = ti->private;
|
||||||
|
|
||||||
atomic_set(&dc->may_delay, 0);
|
mutex_lock(&delayed_bios_lock);
|
||||||
|
dc->may_delay = false;
|
||||||
|
mutex_unlock(&delayed_bios_lock);
|
||||||
|
|
||||||
del_timer_sync(&dc->delay_timer);
|
del_timer_sync(&dc->delay_timer);
|
||||||
flush_bios(flush_delayed_bios(dc, 1));
|
flush_bios(flush_delayed_bios(dc, 1));
|
||||||
}
|
}
|
||||||
@@ -276,7 +283,7 @@ static void delay_resume(struct dm_target *ti)
|
|||||||
{
|
{
|
||||||
struct delay_c *dc = ti->private;
|
struct delay_c *dc = ti->private;
|
||||||
|
|
||||||
atomic_set(&dc->may_delay, 1);
|
dc->may_delay = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
static int delay_map(struct dm_target *ti, struct bio *bio)
|
static int delay_map(struct dm_target *ti, struct bio *bio)
|
||||||
|
|||||||
@@ -28,7 +28,8 @@ bool verity_fec_is_enabled(struct dm_verity *v)
|
|||||||
*/
|
*/
|
||||||
static inline struct dm_verity_fec_io *fec_io(struct dm_verity_io *io)
|
static inline struct dm_verity_fec_io *fec_io(struct dm_verity_io *io)
|
||||||
{
|
{
|
||||||
return (struct dm_verity_fec_io *) verity_io_digest_end(io->v, io);
|
return (struct dm_verity_fec_io *)
|
||||||
|
((char *)io + io->v->ti->per_io_data_size - sizeof(struct dm_verity_fec_io));
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|||||||
@@ -583,7 +583,9 @@ static void verity_end_io(struct bio *bio)
|
|||||||
struct dm_verity_io *io = bio->bi_private;
|
struct dm_verity_io *io = bio->bi_private;
|
||||||
|
|
||||||
if (bio->bi_status &&
|
if (bio->bi_status &&
|
||||||
(!verity_fec_is_enabled(io->v) || verity_is_system_shutting_down())) {
|
(!verity_fec_is_enabled(io->v) ||
|
||||||
|
verity_is_system_shutting_down() ||
|
||||||
|
(bio->bi_opf & REQ_RAHEAD))) {
|
||||||
verity_finish_io(io, bio->bi_status);
|
verity_finish_io(io, bio->bi_status);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -109,12 +109,6 @@ static inline u8 *verity_io_want_digest(struct dm_verity *v,
|
|||||||
return (u8 *)(io + 1) + v->ahash_reqsize + v->digest_size;
|
return (u8 *)(io + 1) + v->ahash_reqsize + v->digest_size;
|
||||||
}
|
}
|
||||||
|
|
||||||
static inline u8 *verity_io_digest_end(struct dm_verity *v,
|
|
||||||
struct dm_verity_io *io)
|
|
||||||
{
|
|
||||||
return verity_io_want_digest(v, io) + v->digest_size;
|
|
||||||
}
|
|
||||||
|
|
||||||
extern int verity_for_bv_block(struct dm_verity *v, struct dm_verity_io *io,
|
extern int verity_for_bv_block(struct dm_verity *v, struct dm_verity_io *io,
|
||||||
struct bvec_iter *iter,
|
struct bvec_iter *iter,
|
||||||
int (*process)(struct dm_verity *v,
|
int (*process)(struct dm_verity *v,
|
||||||
|
|||||||
@@ -1473,6 +1473,8 @@ static void mmc_blk_cqe_complete_rq(struct mmc_queue *mq, struct request *req)
|
|||||||
blk_mq_requeue_request(req, true);
|
blk_mq_requeue_request(req, true);
|
||||||
else
|
else
|
||||||
__blk_mq_end_request(req, BLK_STS_OK);
|
__blk_mq_end_request(req, BLK_STS_OK);
|
||||||
|
} else if (mq->in_recovery) {
|
||||||
|
blk_mq_requeue_request(req, true);
|
||||||
} else {
|
} else {
|
||||||
blk_mq_end_request(req, BLK_STS_OK);
|
blk_mq_end_request(req, BLK_STS_OK);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -567,22 +567,25 @@ int mmc_cqe_recovery(struct mmc_host *host)
|
|||||||
host->cqe_ops->cqe_recovery_start(host);
|
host->cqe_ops->cqe_recovery_start(host);
|
||||||
|
|
||||||
memset(&cmd, 0, sizeof(cmd));
|
memset(&cmd, 0, sizeof(cmd));
|
||||||
cmd.opcode = MMC_STOP_TRANSMISSION,
|
cmd.opcode = MMC_STOP_TRANSMISSION;
|
||||||
cmd.flags = MMC_RSP_R1B | MMC_CMD_AC,
|
cmd.flags = MMC_RSP_R1B | MMC_CMD_AC;
|
||||||
cmd.flags &= ~MMC_RSP_CRC; /* Ignore CRC */
|
cmd.flags &= ~MMC_RSP_CRC; /* Ignore CRC */
|
||||||
cmd.busy_timeout = MMC_CQE_RECOVERY_TIMEOUT,
|
cmd.busy_timeout = MMC_CQE_RECOVERY_TIMEOUT;
|
||||||
mmc_wait_for_cmd(host, &cmd, 0);
|
mmc_wait_for_cmd(host, &cmd, MMC_CMD_RETRIES);
|
||||||
|
|
||||||
memset(&cmd, 0, sizeof(cmd));
|
memset(&cmd, 0, sizeof(cmd));
|
||||||
cmd.opcode = MMC_CMDQ_TASK_MGMT;
|
cmd.opcode = MMC_CMDQ_TASK_MGMT;
|
||||||
cmd.arg = 1; /* Discard entire queue */
|
cmd.arg = 1; /* Discard entire queue */
|
||||||
cmd.flags = MMC_RSP_R1B | MMC_CMD_AC;
|
cmd.flags = MMC_RSP_R1B | MMC_CMD_AC;
|
||||||
cmd.flags &= ~MMC_RSP_CRC; /* Ignore CRC */
|
cmd.flags &= ~MMC_RSP_CRC; /* Ignore CRC */
|
||||||
cmd.busy_timeout = MMC_CQE_RECOVERY_TIMEOUT,
|
cmd.busy_timeout = MMC_CQE_RECOVERY_TIMEOUT;
|
||||||
err = mmc_wait_for_cmd(host, &cmd, 0);
|
err = mmc_wait_for_cmd(host, &cmd, MMC_CMD_RETRIES);
|
||||||
|
|
||||||
host->cqe_ops->cqe_recovery_finish(host);
|
host->cqe_ops->cqe_recovery_finish(host);
|
||||||
|
|
||||||
|
if (err)
|
||||||
|
err = mmc_wait_for_cmd(host, &cmd, MMC_CMD_RETRIES);
|
||||||
|
|
||||||
mmc_retune_release(host);
|
mmc_retune_release(host);
|
||||||
|
|
||||||
return err;
|
return err;
|
||||||
|
|||||||
@@ -884,8 +884,8 @@ static bool cqhci_clear_all_tasks(struct mmc_host *mmc, unsigned int timeout)
|
|||||||
ret = cqhci_tasks_cleared(cq_host);
|
ret = cqhci_tasks_cleared(cq_host);
|
||||||
|
|
||||||
if (!ret)
|
if (!ret)
|
||||||
pr_debug("%s: cqhci: Failed to clear tasks\n",
|
pr_warn("%s: cqhci: Failed to clear tasks\n",
|
||||||
mmc_hostname(mmc));
|
mmc_hostname(mmc));
|
||||||
|
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
@@ -918,7 +918,7 @@ static bool cqhci_halt(struct mmc_host *mmc, unsigned int timeout)
|
|||||||
ret = cqhci_halted(cq_host);
|
ret = cqhci_halted(cq_host);
|
||||||
|
|
||||||
if (!ret)
|
if (!ret)
|
||||||
pr_debug("%s: cqhci: Failed to halt\n", mmc_hostname(mmc));
|
pr_warn("%s: cqhci: Failed to halt\n", mmc_hostname(mmc));
|
||||||
|
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
@@ -926,10 +926,10 @@ static bool cqhci_halt(struct mmc_host *mmc, unsigned int timeout)
|
|||||||
/*
|
/*
|
||||||
* After halting we expect to be able to use the command line. We interpret the
|
* After halting we expect to be able to use the command line. We interpret the
|
||||||
* failure to halt to mean the data lines might still be in use (and the upper
|
* failure to halt to mean the data lines might still be in use (and the upper
|
||||||
* layers will need to send a STOP command), so we set the timeout based on a
|
* layers will need to send a STOP command), however failing to halt complicates
|
||||||
* generous command timeout.
|
* the recovery, so set a timeout that would reasonably allow I/O to complete.
|
||||||
*/
|
*/
|
||||||
#define CQHCI_START_HALT_TIMEOUT 5
|
#define CQHCI_START_HALT_TIMEOUT 500
|
||||||
|
|
||||||
static void cqhci_recovery_start(struct mmc_host *mmc)
|
static void cqhci_recovery_start(struct mmc_host *mmc)
|
||||||
{
|
{
|
||||||
@@ -1017,28 +1017,28 @@ static void cqhci_recovery_finish(struct mmc_host *mmc)
|
|||||||
|
|
||||||
ok = cqhci_halt(mmc, CQHCI_FINISH_HALT_TIMEOUT);
|
ok = cqhci_halt(mmc, CQHCI_FINISH_HALT_TIMEOUT);
|
||||||
|
|
||||||
if (!cqhci_clear_all_tasks(mmc, CQHCI_CLEAR_TIMEOUT))
|
|
||||||
ok = false;
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* The specification contradicts itself, by saying that tasks cannot be
|
* The specification contradicts itself, by saying that tasks cannot be
|
||||||
* cleared if CQHCI does not halt, but if CQHCI does not halt, it should
|
* cleared if CQHCI does not halt, but if CQHCI does not halt, it should
|
||||||
* be disabled/re-enabled, but not to disable before clearing tasks.
|
* be disabled/re-enabled, but not to disable before clearing tasks.
|
||||||
* Have a go anyway.
|
* Have a go anyway.
|
||||||
*/
|
*/
|
||||||
if (!ok) {
|
if (!cqhci_clear_all_tasks(mmc, CQHCI_CLEAR_TIMEOUT))
|
||||||
pr_debug("%s: cqhci: disable / re-enable\n", mmc_hostname(mmc));
|
ok = false;
|
||||||
cqcfg = cqhci_readl(cq_host, CQHCI_CFG);
|
|
||||||
cqcfg &= ~CQHCI_ENABLE;
|
/* Disable to make sure tasks really are cleared */
|
||||||
cqhci_writel(cq_host, cqcfg, CQHCI_CFG);
|
cqcfg = cqhci_readl(cq_host, CQHCI_CFG);
|
||||||
cqcfg |= CQHCI_ENABLE;
|
cqcfg &= ~CQHCI_ENABLE;
|
||||||
cqhci_writel(cq_host, cqcfg, CQHCI_CFG);
|
cqhci_writel(cq_host, cqcfg, CQHCI_CFG);
|
||||||
/* Be sure that there are no tasks */
|
|
||||||
ok = cqhci_halt(mmc, CQHCI_FINISH_HALT_TIMEOUT);
|
cqcfg = cqhci_readl(cq_host, CQHCI_CFG);
|
||||||
if (!cqhci_clear_all_tasks(mmc, CQHCI_CLEAR_TIMEOUT))
|
cqcfg |= CQHCI_ENABLE;
|
||||||
ok = false;
|
cqhci_writel(cq_host, cqcfg, CQHCI_CFG);
|
||||||
WARN_ON(!ok);
|
|
||||||
}
|
cqhci_halt(mmc, CQHCI_FINISH_HALT_TIMEOUT);
|
||||||
|
|
||||||
|
if (!ok)
|
||||||
|
cqhci_clear_all_tasks(mmc, CQHCI_CLEAR_TIMEOUT);
|
||||||
|
|
||||||
cqhci_recover_mrqs(cq_host);
|
cqhci_recover_mrqs(cq_host);
|
||||||
|
|
||||||
|
|||||||
@@ -420,8 +420,25 @@ read_pri_intelext(struct map_info *map, __u16 adr)
|
|||||||
extra_size = 0;
|
extra_size = 0;
|
||||||
|
|
||||||
/* Protection Register info */
|
/* Protection Register info */
|
||||||
extra_size += (extp->NumProtectionFields - 1) *
|
if (extp->NumProtectionFields) {
|
||||||
sizeof(struct cfi_intelext_otpinfo);
|
struct cfi_intelext_otpinfo *otp =
|
||||||
|
(struct cfi_intelext_otpinfo *)&extp->extra[0];
|
||||||
|
|
||||||
|
extra_size += (extp->NumProtectionFields - 1) *
|
||||||
|
sizeof(struct cfi_intelext_otpinfo);
|
||||||
|
|
||||||
|
if (extp_size >= sizeof(*extp) + extra_size) {
|
||||||
|
int i;
|
||||||
|
|
||||||
|
/* Do some byteswapping if necessary */
|
||||||
|
for (i = 0; i < extp->NumProtectionFields - 1; i++) {
|
||||||
|
otp->ProtRegAddr = le32_to_cpu(otp->ProtRegAddr);
|
||||||
|
otp->FactGroups = le16_to_cpu(otp->FactGroups);
|
||||||
|
otp->UserGroups = le16_to_cpu(otp->UserGroups);
|
||||||
|
otp++;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (extp->MinorVersion >= '1') {
|
if (extp->MinorVersion >= '1') {
|
||||||
@@ -695,14 +712,16 @@ static int cfi_intelext_partition_fixup(struct mtd_info *mtd,
|
|||||||
*/
|
*/
|
||||||
if (extp && extp->MajorVersion == '1' && extp->MinorVersion >= '3'
|
if (extp && extp->MajorVersion == '1' && extp->MinorVersion >= '3'
|
||||||
&& extp->FeatureSupport & (1 << 9)) {
|
&& extp->FeatureSupport & (1 << 9)) {
|
||||||
|
int offs = 0;
|
||||||
struct cfi_private *newcfi;
|
struct cfi_private *newcfi;
|
||||||
struct flchip *chip;
|
struct flchip *chip;
|
||||||
struct flchip_shared *shared;
|
struct flchip_shared *shared;
|
||||||
int offs, numregions, numparts, partshift, numvirtchips, i, j;
|
int numregions, numparts, partshift, numvirtchips, i, j;
|
||||||
|
|
||||||
/* Protection Register info */
|
/* Protection Register info */
|
||||||
offs = (extp->NumProtectionFields - 1) *
|
if (extp->NumProtectionFields)
|
||||||
sizeof(struct cfi_intelext_otpinfo);
|
offs = (extp->NumProtectionFields - 1) *
|
||||||
|
sizeof(struct cfi_intelext_otpinfo);
|
||||||
|
|
||||||
/* Burst Read info */
|
/* Burst Read info */
|
||||||
offs += extp->extra[offs+1]+2;
|
offs += extp->extra[offs+1]+2;
|
||||||
|
|||||||
@@ -1753,6 +1753,7 @@ static int brcmstb_nand_verify_erased_page(struct mtd_info *mtd,
|
|||||||
int bitflips = 0;
|
int bitflips = 0;
|
||||||
int page = addr >> chip->page_shift;
|
int page = addr >> chip->page_shift;
|
||||||
int ret;
|
int ret;
|
||||||
|
void *ecc_chunk;
|
||||||
|
|
||||||
if (!buf) {
|
if (!buf) {
|
||||||
buf = chip->data_buf;
|
buf = chip->data_buf;
|
||||||
@@ -1768,7 +1769,9 @@ static int brcmstb_nand_verify_erased_page(struct mtd_info *mtd,
|
|||||||
return ret;
|
return ret;
|
||||||
|
|
||||||
for (i = 0; i < chip->ecc.steps; i++, oob += sas) {
|
for (i = 0; i < chip->ecc.steps; i++, oob += sas) {
|
||||||
ret = nand_check_erased_ecc_chunk(buf, chip->ecc.size,
|
ecc_chunk = buf + chip->ecc.size * i;
|
||||||
|
ret = nand_check_erased_ecc_chunk(ecc_chunk,
|
||||||
|
chip->ecc.size,
|
||||||
oob, sas, NULL, 0,
|
oob, sas, NULL, 0,
|
||||||
chip->ecc.strength);
|
chip->ecc.strength);
|
||||||
if (ret < 0)
|
if (ret < 0)
|
||||||
|
|||||||
@@ -683,10 +683,24 @@ static void xgbe_service(struct work_struct *work)
|
|||||||
static void xgbe_service_timer(struct timer_list *t)
|
static void xgbe_service_timer(struct timer_list *t)
|
||||||
{
|
{
|
||||||
struct xgbe_prv_data *pdata = from_timer(pdata, t, service_timer);
|
struct xgbe_prv_data *pdata = from_timer(pdata, t, service_timer);
|
||||||
|
struct xgbe_channel *channel;
|
||||||
|
unsigned int i;
|
||||||
|
|
||||||
queue_work(pdata->dev_workqueue, &pdata->service_work);
|
queue_work(pdata->dev_workqueue, &pdata->service_work);
|
||||||
|
|
||||||
mod_timer(&pdata->service_timer, jiffies + HZ);
|
mod_timer(&pdata->service_timer, jiffies + HZ);
|
||||||
|
|
||||||
|
if (!pdata->tx_usecs)
|
||||||
|
return;
|
||||||
|
|
||||||
|
for (i = 0; i < pdata->channel_count; i++) {
|
||||||
|
channel = pdata->channel[i];
|
||||||
|
if (!channel->tx_ring || channel->tx_timer_active)
|
||||||
|
break;
|
||||||
|
channel->tx_timer_active = 1;
|
||||||
|
mod_timer(&channel->tx_timer,
|
||||||
|
jiffies + usecs_to_jiffies(pdata->tx_usecs));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
static void xgbe_init_timers(struct xgbe_prv_data *pdata)
|
static void xgbe_init_timers(struct xgbe_prv_data *pdata)
|
||||||
|
|||||||
@@ -314,10 +314,15 @@ static int xgbe_get_link_ksettings(struct net_device *netdev,
|
|||||||
|
|
||||||
cmd->base.phy_address = pdata->phy.address;
|
cmd->base.phy_address = pdata->phy.address;
|
||||||
|
|
||||||
cmd->base.autoneg = pdata->phy.autoneg;
|
if (netif_carrier_ok(netdev)) {
|
||||||
cmd->base.speed = pdata->phy.speed;
|
cmd->base.speed = pdata->phy.speed;
|
||||||
cmd->base.duplex = pdata->phy.duplex;
|
cmd->base.duplex = pdata->phy.duplex;
|
||||||
|
} else {
|
||||||
|
cmd->base.speed = SPEED_UNKNOWN;
|
||||||
|
cmd->base.duplex = DUPLEX_UNKNOWN;
|
||||||
|
}
|
||||||
|
|
||||||
|
cmd->base.autoneg = pdata->phy.autoneg;
|
||||||
cmd->base.port = PORT_NONE;
|
cmd->base.port = PORT_NONE;
|
||||||
|
|
||||||
XGBE_LM_COPY(cmd, supported, lks, supported);
|
XGBE_LM_COPY(cmd, supported, lks, supported);
|
||||||
|
|||||||
@@ -1178,7 +1178,19 @@ static int xgbe_phy_config_fixed(struct xgbe_prv_data *pdata)
|
|||||||
if (pdata->phy.duplex != DUPLEX_FULL)
|
if (pdata->phy.duplex != DUPLEX_FULL)
|
||||||
return -EINVAL;
|
return -EINVAL;
|
||||||
|
|
||||||
xgbe_set_mode(pdata, mode);
|
/* Force the mode change for SFI in Fixed PHY config.
|
||||||
|
* Fixed PHY configs needs PLL to be enabled while doing mode set.
|
||||||
|
* When the SFP module isn't connected during boot, driver assumes
|
||||||
|
* AN is ON and attempts autonegotiation. However, if the connected
|
||||||
|
* SFP comes up in Fixed PHY config, the link will not come up as
|
||||||
|
* PLL isn't enabled while the initial mode set command is issued.
|
||||||
|
* So, force the mode change for SFI in Fixed PHY configuration to
|
||||||
|
* fix link issues.
|
||||||
|
*/
|
||||||
|
if (mode == XGBE_MODE_SFI)
|
||||||
|
xgbe_change_mode(pdata, mode);
|
||||||
|
else
|
||||||
|
xgbe_set_mode(pdata, mode);
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1392,13 +1392,13 @@ static int ravb_open(struct net_device *ndev)
|
|||||||
if (priv->chip_id == RCAR_GEN2)
|
if (priv->chip_id == RCAR_GEN2)
|
||||||
ravb_ptp_init(ndev, priv->pdev);
|
ravb_ptp_init(ndev, priv->pdev);
|
||||||
|
|
||||||
netif_tx_start_all_queues(ndev);
|
|
||||||
|
|
||||||
/* PHY control start */
|
/* PHY control start */
|
||||||
error = ravb_phy_start(ndev);
|
error = ravb_phy_start(ndev);
|
||||||
if (error)
|
if (error)
|
||||||
goto out_ptp_stop;
|
goto out_ptp_stop;
|
||||||
|
|
||||||
|
netif_tx_start_all_queues(ndev);
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
out_ptp_stop:
|
out_ptp_stop:
|
||||||
@@ -1447,6 +1447,12 @@ static void ravb_tx_timeout_work(struct work_struct *work)
|
|||||||
struct net_device *ndev = priv->ndev;
|
struct net_device *ndev = priv->ndev;
|
||||||
int error;
|
int error;
|
||||||
|
|
||||||
|
if (!rtnl_trylock()) {
|
||||||
|
usleep_range(1000, 2000);
|
||||||
|
schedule_work(&priv->work);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
netif_tx_stop_all_queues(ndev);
|
netif_tx_stop_all_queues(ndev);
|
||||||
|
|
||||||
/* Stop PTP Clock driver */
|
/* Stop PTP Clock driver */
|
||||||
@@ -1479,7 +1485,7 @@ static void ravb_tx_timeout_work(struct work_struct *work)
|
|||||||
*/
|
*/
|
||||||
netdev_err(ndev, "%s: ravb_dmac_init() failed, error %d\n",
|
netdev_err(ndev, "%s: ravb_dmac_init() failed, error %d\n",
|
||||||
__func__, error);
|
__func__, error);
|
||||||
return;
|
goto out_unlock;
|
||||||
}
|
}
|
||||||
ravb_emac_init(ndev);
|
ravb_emac_init(ndev);
|
||||||
|
|
||||||
@@ -1489,6 +1495,9 @@ static void ravb_tx_timeout_work(struct work_struct *work)
|
|||||||
ravb_ptp_init(ndev, priv->pdev);
|
ravb_ptp_init(ndev, priv->pdev);
|
||||||
|
|
||||||
netif_tx_start_all_queues(ndev);
|
netif_tx_start_all_queues(ndev);
|
||||||
|
|
||||||
|
out_unlock:
|
||||||
|
rtnl_unlock();
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Packet transmit function for Ethernet AVB */
|
/* Packet transmit function for Ethernet AVB */
|
||||||
|
|||||||
@@ -702,7 +702,7 @@ axienet_start_xmit(struct sk_buff *skb, struct net_device *ndev)
|
|||||||
if (lp->features & XAE_FEATURE_FULL_TX_CSUM) {
|
if (lp->features & XAE_FEATURE_FULL_TX_CSUM) {
|
||||||
/* Tx Full Checksum Offload Enabled */
|
/* Tx Full Checksum Offload Enabled */
|
||||||
cur_p->app0 |= 2;
|
cur_p->app0 |= 2;
|
||||||
} else if (lp->features & XAE_FEATURE_PARTIAL_RX_CSUM) {
|
} else if (lp->features & XAE_FEATURE_PARTIAL_TX_CSUM) {
|
||||||
csum_start_off = skb_transport_offset(skb);
|
csum_start_off = skb_transport_offset(skb);
|
||||||
csum_index_off = csum_start_off + skb->csum_offset;
|
csum_index_off = csum_start_off + skb->csum_offset;
|
||||||
/* Tx Partial Checksum Offload Enabled */
|
/* Tx Partial Checksum Offload Enabled */
|
||||||
|
|||||||
@@ -2048,9 +2048,6 @@ static int netvsc_vf_join(struct net_device *vf_netdev,
|
|||||||
goto upper_link_failed;
|
goto upper_link_failed;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* set slave flag before open to prevent IPv6 addrconf */
|
|
||||||
vf_netdev->flags |= IFF_SLAVE;
|
|
||||||
|
|
||||||
schedule_delayed_work(&ndev_ctx->vf_takeover, VF_TAKEOVER_INT);
|
schedule_delayed_work(&ndev_ctx->vf_takeover, VF_TAKEOVER_INT);
|
||||||
|
|
||||||
call_netdevice_notifiers(NETDEV_JOIN, vf_netdev);
|
call_netdevice_notifiers(NETDEV_JOIN, vf_netdev);
|
||||||
@@ -2148,16 +2145,18 @@ static struct net_device *get_netvsc_byslot(const struct net_device *vf_netdev)
|
|||||||
return hv_get_drvdata(ndev_ctx->device_ctx);
|
return hv_get_drvdata(ndev_ctx->device_ctx);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Fallback path to check synthetic vf with
|
/* Fallback path to check synthetic vf with help of mac addr.
|
||||||
* help of mac addr
|
* Because this function can be called before vf_netdev is
|
||||||
|
* initialized (NETDEV_POST_INIT) when its perm_addr has not been copied
|
||||||
|
* from dev_addr, also try to match to its dev_addr.
|
||||||
|
* Note: On Hyper-V and Azure, it's not possible to set a MAC address
|
||||||
|
* on a VF that matches to the MAC of a unrelated NETVSC device.
|
||||||
*/
|
*/
|
||||||
list_for_each_entry(ndev_ctx, &netvsc_dev_list, list) {
|
list_for_each_entry(ndev_ctx, &netvsc_dev_list, list) {
|
||||||
ndev = hv_get_drvdata(ndev_ctx->device_ctx);
|
ndev = hv_get_drvdata(ndev_ctx->device_ctx);
|
||||||
if (ether_addr_equal(vf_netdev->perm_addr, ndev->perm_addr)) {
|
if (ether_addr_equal(vf_netdev->perm_addr, ndev->perm_addr) ||
|
||||||
netdev_notice(vf_netdev,
|
ether_addr_equal(vf_netdev->dev_addr, ndev->perm_addr))
|
||||||
"falling back to mac addr based matching\n");
|
|
||||||
return ndev;
|
return ndev;
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
netdev_notice(vf_netdev,
|
netdev_notice(vf_netdev,
|
||||||
@@ -2165,6 +2164,19 @@ static struct net_device *get_netvsc_byslot(const struct net_device *vf_netdev)
|
|||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static int netvsc_prepare_bonding(struct net_device *vf_netdev)
|
||||||
|
{
|
||||||
|
struct net_device *ndev;
|
||||||
|
|
||||||
|
ndev = get_netvsc_byslot(vf_netdev);
|
||||||
|
if (!ndev)
|
||||||
|
return NOTIFY_DONE;
|
||||||
|
|
||||||
|
/* set slave flag before open to prevent IPv6 addrconf */
|
||||||
|
vf_netdev->flags |= IFF_SLAVE;
|
||||||
|
return NOTIFY_DONE;
|
||||||
|
}
|
||||||
|
|
||||||
static int netvsc_register_vf(struct net_device *vf_netdev)
|
static int netvsc_register_vf(struct net_device *vf_netdev)
|
||||||
{
|
{
|
||||||
struct net_device_context *net_device_ctx;
|
struct net_device_context *net_device_ctx;
|
||||||
@@ -2481,6 +2493,8 @@ static int netvsc_netdev_event(struct notifier_block *this,
|
|||||||
return NOTIFY_DONE;
|
return NOTIFY_DONE;
|
||||||
|
|
||||||
switch (event) {
|
switch (event) {
|
||||||
|
case NETDEV_POST_INIT:
|
||||||
|
return netvsc_prepare_bonding(event_dev);
|
||||||
case NETDEV_REGISTER:
|
case NETDEV_REGISTER:
|
||||||
return netvsc_register_vf(event_dev);
|
return netvsc_register_vf(event_dev);
|
||||||
case NETDEV_UNREGISTER:
|
case NETDEV_UNREGISTER:
|
||||||
@@ -2514,12 +2528,17 @@ static int __init netvsc_drv_init(void)
|
|||||||
}
|
}
|
||||||
netvsc_ring_bytes = ring_size * PAGE_SIZE;
|
netvsc_ring_bytes = ring_size * PAGE_SIZE;
|
||||||
|
|
||||||
|
register_netdevice_notifier(&netvsc_netdev_notifier);
|
||||||
|
|
||||||
ret = vmbus_driver_register(&netvsc_drv);
|
ret = vmbus_driver_register(&netvsc_drv);
|
||||||
if (ret)
|
if (ret)
|
||||||
return ret;
|
goto err_vmbus_reg;
|
||||||
|
|
||||||
register_netdevice_notifier(&netvsc_netdev_notifier);
|
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
|
err_vmbus_reg:
|
||||||
|
unregister_netdevice_notifier(&netvsc_netdev_notifier);
|
||||||
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
MODULE_LICENSE("GPL");
|
MODULE_LICENSE("GPL");
|
||||||
|
|||||||
@@ -1610,11 +1610,11 @@ static int ax88179_reset(struct usbnet *dev)
|
|||||||
|
|
||||||
*tmp16 = AX_PHYPWR_RSTCTL_IPRL;
|
*tmp16 = AX_PHYPWR_RSTCTL_IPRL;
|
||||||
ax88179_write_cmd(dev, AX_ACCESS_MAC, AX_PHYPWR_RSTCTL, 2, 2, tmp16);
|
ax88179_write_cmd(dev, AX_ACCESS_MAC, AX_PHYPWR_RSTCTL, 2, 2, tmp16);
|
||||||
msleep(200);
|
msleep(500);
|
||||||
|
|
||||||
*tmp = AX_CLK_SELECT_ACS | AX_CLK_SELECT_BCS;
|
*tmp = AX_CLK_SELECT_ACS | AX_CLK_SELECT_BCS;
|
||||||
ax88179_write_cmd(dev, AX_ACCESS_MAC, AX_CLK_SELECT, 1, 1, tmp);
|
ax88179_write_cmd(dev, AX_ACCESS_MAC, AX_CLK_SELECT, 1, 1, tmp);
|
||||||
msleep(100);
|
msleep(200);
|
||||||
|
|
||||||
/* Ethernet PHY Auto Detach*/
|
/* Ethernet PHY Auto Detach*/
|
||||||
ax88179_auto_detach(dev, 0);
|
ax88179_auto_detach(dev, 0);
|
||||||
|
|||||||
@@ -1224,17 +1224,17 @@ EXPORT_SYMBOL_GPL(pinctrl_lookup_state);
|
|||||||
static int pinctrl_commit_state(struct pinctrl *p, struct pinctrl_state *state)
|
static int pinctrl_commit_state(struct pinctrl *p, struct pinctrl_state *state)
|
||||||
{
|
{
|
||||||
struct pinctrl_setting *setting, *setting2;
|
struct pinctrl_setting *setting, *setting2;
|
||||||
struct pinctrl_state *old_state = p->state;
|
struct pinctrl_state *old_state = READ_ONCE(p->state);
|
||||||
int ret;
|
int ret;
|
||||||
|
|
||||||
if (p->state) {
|
if (old_state) {
|
||||||
/*
|
/*
|
||||||
* For each pinmux setting in the old state, forget SW's record
|
* For each pinmux setting in the old state, forget SW's record
|
||||||
* of mux owner for that pingroup. Any pingroups which are
|
* of mux owner for that pingroup. Any pingroups which are
|
||||||
* still owned by the new state will be re-acquired by the call
|
* still owned by the new state will be re-acquired by the call
|
||||||
* to pinmux_enable_setting() in the loop below.
|
* to pinmux_enable_setting() in the loop below.
|
||||||
*/
|
*/
|
||||||
list_for_each_entry(setting, &p->state->settings, node) {
|
list_for_each_entry(setting, &old_state->settings, node) {
|
||||||
if (setting->type != PIN_MAP_TYPE_MUX_GROUP)
|
if (setting->type != PIN_MAP_TYPE_MUX_GROUP)
|
||||||
continue;
|
continue;
|
||||||
pinmux_disable_setting(setting);
|
pinmux_disable_setting(setting);
|
||||||
|
|||||||
@@ -725,18 +725,20 @@ static void dasd_profile_start(struct dasd_block *block,
|
|||||||
* we count each request only once.
|
* we count each request only once.
|
||||||
*/
|
*/
|
||||||
device = cqr->startdev;
|
device = cqr->startdev;
|
||||||
if (device->profile.data) {
|
if (!device->profile.data)
|
||||||
counter = 1; /* request is not yet queued on the start device */
|
return;
|
||||||
list_for_each(l, &device->ccw_queue)
|
|
||||||
if (++counter >= 31)
|
spin_lock(get_ccwdev_lock(device->cdev));
|
||||||
break;
|
counter = 1; /* request is not yet queued on the start device */
|
||||||
}
|
list_for_each(l, &device->ccw_queue)
|
||||||
|
if (++counter >= 31)
|
||||||
|
break;
|
||||||
|
spin_unlock(get_ccwdev_lock(device->cdev));
|
||||||
|
|
||||||
spin_lock(&device->profile.lock);
|
spin_lock(&device->profile.lock);
|
||||||
if (device->profile.data) {
|
device->profile.data->dasd_io_nr_req[counter]++;
|
||||||
device->profile.data->dasd_io_nr_req[counter]++;
|
if (rq_data_dir(req) == READ)
|
||||||
if (rq_data_dir(req) == READ)
|
device->profile.data->dasd_read_nr_req[counter]++;
|
||||||
device->profile.data->dasd_read_nr_req[counter]++;
|
|
||||||
}
|
|
||||||
spin_unlock(&device->profile.lock);
|
spin_unlock(&device->profile.lock);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -2045,15 +2045,17 @@ static void dwc2_hc_n_intr(struct dwc2_hsotg *hsotg, int chnum)
|
|||||||
{
|
{
|
||||||
struct dwc2_qtd *qtd;
|
struct dwc2_qtd *qtd;
|
||||||
struct dwc2_host_chan *chan;
|
struct dwc2_host_chan *chan;
|
||||||
u32 hcint, hcintmsk;
|
u32 hcint, hcintraw, hcintmsk;
|
||||||
|
|
||||||
chan = hsotg->hc_ptr_array[chnum];
|
chan = hsotg->hc_ptr_array[chnum];
|
||||||
|
|
||||||
hcint = dwc2_readl(hsotg, HCINT(chnum));
|
hcintraw = dwc2_readl(hsotg, HCINT(chnum));
|
||||||
hcintmsk = dwc2_readl(hsotg, HCINTMSK(chnum));
|
hcintmsk = dwc2_readl(hsotg, HCINTMSK(chnum));
|
||||||
|
hcint = hcintraw & hcintmsk;
|
||||||
|
dwc2_writel(hsotg, hcint, HCINT(chnum));
|
||||||
|
|
||||||
if (!chan) {
|
if (!chan) {
|
||||||
dev_err(hsotg->dev, "## hc_ptr_array for channel is NULL ##\n");
|
dev_err(hsotg->dev, "## hc_ptr_array for channel is NULL ##\n");
|
||||||
dwc2_writel(hsotg, hcint, HCINT(chnum));
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -2062,11 +2064,9 @@ static void dwc2_hc_n_intr(struct dwc2_hsotg *hsotg, int chnum)
|
|||||||
chnum);
|
chnum);
|
||||||
dev_vdbg(hsotg->dev,
|
dev_vdbg(hsotg->dev,
|
||||||
" hcint 0x%08x, hcintmsk 0x%08x, hcint&hcintmsk 0x%08x\n",
|
" hcint 0x%08x, hcintmsk 0x%08x, hcint&hcintmsk 0x%08x\n",
|
||||||
hcint, hcintmsk, hcint & hcintmsk);
|
hcintraw, hcintmsk, hcint);
|
||||||
}
|
}
|
||||||
|
|
||||||
dwc2_writel(hsotg, hcint, HCINT(chnum));
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* If we got an interrupt after someone called
|
* If we got an interrupt after someone called
|
||||||
* dwc2_hcd_endpoint_disable() we don't want to crash below
|
* dwc2_hcd_endpoint_disable() we don't want to crash below
|
||||||
@@ -2076,8 +2076,7 @@ static void dwc2_hc_n_intr(struct dwc2_hsotg *hsotg, int chnum)
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
chan->hcint = hcint;
|
chan->hcint = hcintraw;
|
||||||
hcint &= hcintmsk;
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* If the channel was halted due to a dequeue, the qtd list might
|
* If the channel was halted due to a dequeue, the qtd list might
|
||||||
|
|||||||
@@ -1530,6 +1530,8 @@ static int dwc3_probe(struct platform_device *pdev)
|
|||||||
|
|
||||||
pm_runtime_put(dev);
|
pm_runtime_put(dev);
|
||||||
|
|
||||||
|
dma_set_max_seg_size(dev, UINT_MAX);
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
err5:
|
err5:
|
||||||
|
|||||||
@@ -329,7 +329,7 @@ static int dwc3_qcom_setup_irq(struct platform_device *pdev)
|
|||||||
irq_set_status_flags(irq, IRQ_NOAUTOEN);
|
irq_set_status_flags(irq, IRQ_NOAUTOEN);
|
||||||
ret = devm_request_threaded_irq(qcom->dev, irq, NULL,
|
ret = devm_request_threaded_irq(qcom->dev, irq, NULL,
|
||||||
qcom_dwc3_resume_irq,
|
qcom_dwc3_resume_irq,
|
||||||
IRQF_TRIGGER_HIGH | IRQF_ONESHOT,
|
IRQF_ONESHOT,
|
||||||
"qcom_dwc3 HS", qcom);
|
"qcom_dwc3 HS", qcom);
|
||||||
if (ret) {
|
if (ret) {
|
||||||
dev_err(qcom->dev, "hs_phy_irq failed: %d\n", ret);
|
dev_err(qcom->dev, "hs_phy_irq failed: %d\n", ret);
|
||||||
@@ -343,7 +343,7 @@ static int dwc3_qcom_setup_irq(struct platform_device *pdev)
|
|||||||
irq_set_status_flags(irq, IRQ_NOAUTOEN);
|
irq_set_status_flags(irq, IRQ_NOAUTOEN);
|
||||||
ret = devm_request_threaded_irq(qcom->dev, irq, NULL,
|
ret = devm_request_threaded_irq(qcom->dev, irq, NULL,
|
||||||
qcom_dwc3_resume_irq,
|
qcom_dwc3_resume_irq,
|
||||||
IRQF_TRIGGER_HIGH | IRQF_ONESHOT,
|
IRQF_ONESHOT,
|
||||||
"qcom_dwc3 DP_HS", qcom);
|
"qcom_dwc3 DP_HS", qcom);
|
||||||
if (ret) {
|
if (ret) {
|
||||||
dev_err(qcom->dev, "dp_hs_phy_irq failed: %d\n", ret);
|
dev_err(qcom->dev, "dp_hs_phy_irq failed: %d\n", ret);
|
||||||
@@ -357,7 +357,7 @@ static int dwc3_qcom_setup_irq(struct platform_device *pdev)
|
|||||||
irq_set_status_flags(irq, IRQ_NOAUTOEN);
|
irq_set_status_flags(irq, IRQ_NOAUTOEN);
|
||||||
ret = devm_request_threaded_irq(qcom->dev, irq, NULL,
|
ret = devm_request_threaded_irq(qcom->dev, irq, NULL,
|
||||||
qcom_dwc3_resume_irq,
|
qcom_dwc3_resume_irq,
|
||||||
IRQF_TRIGGER_HIGH | IRQF_ONESHOT,
|
IRQF_ONESHOT,
|
||||||
"qcom_dwc3 DM_HS", qcom);
|
"qcom_dwc3 DM_HS", qcom);
|
||||||
if (ret) {
|
if (ret) {
|
||||||
dev_err(qcom->dev, "dm_hs_phy_irq failed: %d\n", ret);
|
dev_err(qcom->dev, "dm_hs_phy_irq failed: %d\n", ret);
|
||||||
@@ -371,7 +371,7 @@ static int dwc3_qcom_setup_irq(struct platform_device *pdev)
|
|||||||
irq_set_status_flags(irq, IRQ_NOAUTOEN);
|
irq_set_status_flags(irq, IRQ_NOAUTOEN);
|
||||||
ret = devm_request_threaded_irq(qcom->dev, irq, NULL,
|
ret = devm_request_threaded_irq(qcom->dev, irq, NULL,
|
||||||
qcom_dwc3_resume_irq,
|
qcom_dwc3_resume_irq,
|
||||||
IRQF_TRIGGER_HIGH | IRQF_ONESHOT,
|
IRQF_ONESHOT,
|
||||||
"qcom_dwc3 SS", qcom);
|
"qcom_dwc3 SS", qcom);
|
||||||
if (ret) {
|
if (ret) {
|
||||||
dev_err(qcom->dev, "ss_phy_irq failed: %d\n", ret);
|
dev_err(qcom->dev, "ss_phy_irq failed: %d\n", ret);
|
||||||
|
|||||||
@@ -203,8 +203,8 @@ static void option_instat_callback(struct urb *urb);
|
|||||||
#define DELL_PRODUCT_5829E_ESIM 0x81e4
|
#define DELL_PRODUCT_5829E_ESIM 0x81e4
|
||||||
#define DELL_PRODUCT_5829E 0x81e6
|
#define DELL_PRODUCT_5829E 0x81e6
|
||||||
|
|
||||||
#define DELL_PRODUCT_FM101R 0x8213
|
#define DELL_PRODUCT_FM101R_ESIM 0x8213
|
||||||
#define DELL_PRODUCT_FM101R_ESIM 0x8215
|
#define DELL_PRODUCT_FM101R 0x8215
|
||||||
|
|
||||||
#define KYOCERA_VENDOR_ID 0x0c88
|
#define KYOCERA_VENDOR_ID 0x0c88
|
||||||
#define KYOCERA_PRODUCT_KPC650 0x17da
|
#define KYOCERA_PRODUCT_KPC650 0x17da
|
||||||
@@ -609,6 +609,8 @@ static void option_instat_callback(struct urb *urb);
|
|||||||
#define UNISOC_VENDOR_ID 0x1782
|
#define UNISOC_VENDOR_ID 0x1782
|
||||||
/* TOZED LT70-C based on UNISOC SL8563 uses UNISOC's vendor ID */
|
/* TOZED LT70-C based on UNISOC SL8563 uses UNISOC's vendor ID */
|
||||||
#define TOZED_PRODUCT_LT70C 0x4055
|
#define TOZED_PRODUCT_LT70C 0x4055
|
||||||
|
/* Luat Air72*U series based on UNISOC UIS8910 uses UNISOC's vendor ID */
|
||||||
|
#define LUAT_PRODUCT_AIR720U 0x4e00
|
||||||
|
|
||||||
/* Device flags */
|
/* Device flags */
|
||||||
|
|
||||||
@@ -1546,7 +1548,8 @@ static const struct usb_device_id option_ids[] = {
|
|||||||
{ USB_DEVICE_AND_INTERFACE_INFO(ZTE_VENDOR_ID, 0x0165, 0xff, 0xff, 0xff) },
|
{ USB_DEVICE_AND_INTERFACE_INFO(ZTE_VENDOR_ID, 0x0165, 0xff, 0xff, 0xff) },
|
||||||
{ USB_DEVICE_AND_INTERFACE_INFO(ZTE_VENDOR_ID, 0x0167, 0xff, 0xff, 0xff),
|
{ USB_DEVICE_AND_INTERFACE_INFO(ZTE_VENDOR_ID, 0x0167, 0xff, 0xff, 0xff),
|
||||||
.driver_info = RSVD(4) },
|
.driver_info = RSVD(4) },
|
||||||
{ USB_DEVICE_AND_INTERFACE_INFO(ZTE_VENDOR_ID, 0x0189, 0xff, 0xff, 0xff) },
|
{ USB_DEVICE_AND_INTERFACE_INFO(ZTE_VENDOR_ID, 0x0189, 0xff, 0xff, 0xff),
|
||||||
|
.driver_info = RSVD(4) },
|
||||||
{ USB_DEVICE_AND_INTERFACE_INFO(ZTE_VENDOR_ID, 0x0191, 0xff, 0xff, 0xff), /* ZTE EuFi890 */
|
{ USB_DEVICE_AND_INTERFACE_INFO(ZTE_VENDOR_ID, 0x0191, 0xff, 0xff, 0xff), /* ZTE EuFi890 */
|
||||||
.driver_info = RSVD(4) },
|
.driver_info = RSVD(4) },
|
||||||
{ USB_DEVICE_AND_INTERFACE_INFO(ZTE_VENDOR_ID, 0x0196, 0xff, 0xff, 0xff) },
|
{ USB_DEVICE_AND_INTERFACE_INFO(ZTE_VENDOR_ID, 0x0196, 0xff, 0xff, 0xff) },
|
||||||
@@ -2249,6 +2252,7 @@ static const struct usb_device_id option_ids[] = {
|
|||||||
.driver_info = RSVD(4) | RSVD(5) | RSVD(6) },
|
.driver_info = RSVD(4) | RSVD(5) | RSVD(6) },
|
||||||
{ USB_DEVICE(0x1782, 0x4d10) }, /* Fibocom L610 (AT mode) */
|
{ USB_DEVICE(0x1782, 0x4d10) }, /* Fibocom L610 (AT mode) */
|
||||||
{ USB_DEVICE_INTERFACE_CLASS(0x1782, 0x4d11, 0xff) }, /* Fibocom L610 (ECM/RNDIS mode) */
|
{ USB_DEVICE_INTERFACE_CLASS(0x1782, 0x4d11, 0xff) }, /* Fibocom L610 (ECM/RNDIS mode) */
|
||||||
|
{ USB_DEVICE_AND_INTERFACE_INFO(0x2cb7, 0x0001, 0xff, 0xff, 0xff) }, /* Fibocom L716-EU (ECM/RNDIS mode) */
|
||||||
{ USB_DEVICE(0x2cb7, 0x0104), /* Fibocom NL678 series */
|
{ USB_DEVICE(0x2cb7, 0x0104), /* Fibocom NL678 series */
|
||||||
.driver_info = RSVD(4) | RSVD(5) },
|
.driver_info = RSVD(4) | RSVD(5) },
|
||||||
{ USB_DEVICE_INTERFACE_CLASS(0x2cb7, 0x0105, 0xff), /* Fibocom NL678 series */
|
{ USB_DEVICE_INTERFACE_CLASS(0x2cb7, 0x0105, 0xff), /* Fibocom NL678 series */
|
||||||
@@ -2271,6 +2275,7 @@ static const struct usb_device_id option_ids[] = {
|
|||||||
{ USB_DEVICE_AND_INTERFACE_INFO(SIERRA_VENDOR_ID, SIERRA_PRODUCT_EM9191, 0xff, 0xff, 0x40) },
|
{ USB_DEVICE_AND_INTERFACE_INFO(SIERRA_VENDOR_ID, SIERRA_PRODUCT_EM9191, 0xff, 0xff, 0x40) },
|
||||||
{ USB_DEVICE_AND_INTERFACE_INFO(SIERRA_VENDOR_ID, SIERRA_PRODUCT_EM9191, 0xff, 0, 0) },
|
{ USB_DEVICE_AND_INTERFACE_INFO(SIERRA_VENDOR_ID, SIERRA_PRODUCT_EM9191, 0xff, 0, 0) },
|
||||||
{ USB_DEVICE_AND_INTERFACE_INFO(UNISOC_VENDOR_ID, TOZED_PRODUCT_LT70C, 0xff, 0, 0) },
|
{ USB_DEVICE_AND_INTERFACE_INFO(UNISOC_VENDOR_ID, TOZED_PRODUCT_LT70C, 0xff, 0, 0) },
|
||||||
|
{ USB_DEVICE_AND_INTERFACE_INFO(UNISOC_VENDOR_ID, LUAT_PRODUCT_AIR720U, 0xff, 0, 0) },
|
||||||
{ } /* Terminating entry */
|
{ } /* Terminating entry */
|
||||||
};
|
};
|
||||||
MODULE_DEVICE_TABLE(usb, option_ids);
|
MODULE_DEVICE_TABLE(usb, option_ids);
|
||||||
|
|||||||
@@ -237,7 +237,7 @@ struct sti_rom_font {
|
|||||||
u8 height;
|
u8 height;
|
||||||
u8 font_type; /* language type */
|
u8 font_type; /* language type */
|
||||||
u8 bytes_per_char;
|
u8 bytes_per_char;
|
||||||
u32 next_font;
|
s32 next_font; /* note: signed int */
|
||||||
u8 underline_height;
|
u8 underline_height;
|
||||||
u8 underline_pos;
|
u8 underline_pos;
|
||||||
u8 res008[2];
|
u8 res008[2];
|
||||||
|
|||||||
@@ -6860,7 +6860,7 @@ long btrfs_ioctl_send(struct file *mnt_file, struct btrfs_ioctl_send_args *arg)
|
|||||||
sctx->flags = arg->flags;
|
sctx->flags = arg->flags;
|
||||||
|
|
||||||
sctx->send_filp = fget(arg->send_fd);
|
sctx->send_filp = fget(arg->send_fd);
|
||||||
if (!sctx->send_filp) {
|
if (!sctx->send_filp || !(sctx->send_filp->f_mode & FMODE_WRITE)) {
|
||||||
ret = -EBADF;
|
ret = -EBADF;
|
||||||
goto out;
|
goto out;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -2760,7 +2760,7 @@ static struct extent_map *get_chunk_map(struct btrfs_fs_info *fs_info,
|
|||||||
return ERR_PTR(-EINVAL);
|
return ERR_PTR(-EINVAL);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (em->start > logical || em->start + em->len < logical) {
|
if (em->start > logical || em->start + em->len <= logical) {
|
||||||
btrfs_crit(fs_info,
|
btrfs_crit(fs_info,
|
||||||
"found a bad mapping, wanted %llu-%llu, found %llu-%llu",
|
"found a bad mapping, wanted %llu-%llu, found %llu-%llu",
|
||||||
logical, length, em->start, em->start + em->len);
|
logical, length, em->start, em->start + em->len);
|
||||||
|
|||||||
@@ -970,6 +970,7 @@ const struct inode_operations cifs_file_inode_ops = {
|
|||||||
|
|
||||||
const struct inode_operations cifs_symlink_inode_ops = {
|
const struct inode_operations cifs_symlink_inode_ops = {
|
||||||
.get_link = cifs_get_link,
|
.get_link = cifs_get_link,
|
||||||
|
.setattr = cifs_setattr,
|
||||||
.permission = cifs_permission,
|
.permission = cifs_permission,
|
||||||
.listxattr = cifs_listxattr,
|
.listxattr = cifs_listxattr,
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -273,8 +273,8 @@ static int ovl_sync_fs(struct super_block *sb, int wait)
|
|||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* If this is a sync(2) call or an emergency sync, all the super blocks
|
* Not called for sync(2) call or an emergency sync (SB_I_SKIP_SYNC).
|
||||||
* will be iterated, including upper_sb, so no need to do anything.
|
* All the super blocks will be iterated, including upper_sb.
|
||||||
*
|
*
|
||||||
* If this is a syncfs(2) call, then we do need to call
|
* If this is a syncfs(2) call, then we do need to call
|
||||||
* sync_filesystem() on upper_sb, but enough if we do it when being
|
* sync_filesystem() on upper_sb, but enough if we do it when being
|
||||||
@@ -1703,6 +1703,7 @@ static int ovl_fill_super(struct super_block *sb, void *data, int silent)
|
|||||||
sb->s_xattr = ovl_xattr_handlers;
|
sb->s_xattr = ovl_xattr_handlers;
|
||||||
sb->s_fs_info = ofs;
|
sb->s_fs_info = ofs;
|
||||||
sb->s_flags |= SB_POSIXACL;
|
sb->s_flags |= SB_POSIXACL;
|
||||||
|
sb->s_iflags |= SB_I_SKIP_SYNC;
|
||||||
|
|
||||||
err = -ENOMEM;
|
err = -ENOMEM;
|
||||||
root_dentry = d_make_root(ovl_new_inode(sb, S_IFDIR, 0));
|
root_dentry = d_make_root(ovl_new_inode(sb, S_IFDIR, 0));
|
||||||
|
|||||||
@@ -76,7 +76,8 @@ static void sync_inodes_one_sb(struct super_block *sb, void *arg)
|
|||||||
|
|
||||||
static void sync_fs_one_sb(struct super_block *sb, void *arg)
|
static void sync_fs_one_sb(struct super_block *sb, void *arg)
|
||||||
{
|
{
|
||||||
if (!sb_rdonly(sb) && sb->s_op->sync_fs)
|
if (!sb_rdonly(sb) && !(sb->s_iflags & SB_I_SKIP_SYNC) &&
|
||||||
|
sb->s_op->sync_fs)
|
||||||
sb->s_op->sync_fs(sb, *(int *)arg);
|
sb->s_op->sync_fs(sb, *(int *)arg);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1392,6 +1392,8 @@ extern int send_sigurg(struct fown_struct *fown);
|
|||||||
#define SB_I_IMA_UNVERIFIABLE_SIGNATURE 0x00000020
|
#define SB_I_IMA_UNVERIFIABLE_SIGNATURE 0x00000020
|
||||||
#define SB_I_UNTRUSTED_MOUNTER 0x00000040
|
#define SB_I_UNTRUSTED_MOUNTER 0x00000040
|
||||||
|
|
||||||
|
#define SB_I_SKIP_SYNC 0x00000100 /* Skip superblock at global sync */
|
||||||
|
|
||||||
/* Possible states of 'frozen' field */
|
/* Possible states of 'frozen' field */
|
||||||
enum {
|
enum {
|
||||||
SB_UNFROZEN = 0, /* FS is unfrozen */
|
SB_UNFROZEN = 0, /* FS is unfrozen */
|
||||||
|
|||||||
@@ -625,8 +625,13 @@ struct hid_device { /* device report descriptor */
|
|||||||
struct list_head debug_list;
|
struct list_head debug_list;
|
||||||
spinlock_t debug_list_lock;
|
spinlock_t debug_list_lock;
|
||||||
wait_queue_head_t debug_wait;
|
wait_queue_head_t debug_wait;
|
||||||
|
struct kref ref;
|
||||||
|
|
||||||
|
unsigned int id; /* system unique id */
|
||||||
};
|
};
|
||||||
|
|
||||||
|
void hiddev_free(struct kref *ref);
|
||||||
|
|
||||||
#define to_hid_device(pdev) \
|
#define to_hid_device(pdev) \
|
||||||
container_of(pdev, struct hid_device, dev)
|
container_of(pdev, struct hid_device, dev)
|
||||||
|
|
||||||
|
|||||||
@@ -221,8 +221,10 @@ static void igmp_start_timer(struct ip_mc_list *im, int max_delay)
|
|||||||
int tv = prandom_u32() % max_delay;
|
int tv = prandom_u32() % max_delay;
|
||||||
|
|
||||||
im->tm_running = 1;
|
im->tm_running = 1;
|
||||||
if (!mod_timer(&im->timer, jiffies+tv+2))
|
if (refcount_inc_not_zero(&im->refcnt)) {
|
||||||
refcount_inc(&im->refcnt);
|
if (mod_timer(&im->timer, jiffies + tv + 2))
|
||||||
|
ip_ma_put(im);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
static void igmp_gq_start_timer(struct in_device *in_dev)
|
static void igmp_gq_start_timer(struct in_device *in_dev)
|
||||||
|
|||||||
@@ -791,7 +791,7 @@ static void __ip_do_redirect(struct rtable *rt, struct sk_buff *skb, struct flow
|
|||||||
goto reject_redirect;
|
goto reject_redirect;
|
||||||
}
|
}
|
||||||
|
|
||||||
n = __ipv4_neigh_lookup(rt->dst.dev, new_gw);
|
n = __ipv4_neigh_lookup(rt->dst.dev, (__force u32)new_gw);
|
||||||
if (!n)
|
if (!n)
|
||||||
n = neigh_create(&arp_tbl, &new_gw, rt->dst.dev);
|
n = neigh_create(&arp_tbl, &new_gw, rt->dst.dev);
|
||||||
if (!IS_ERR(n)) {
|
if (!IS_ERR(n)) {
|
||||||
|
|||||||
@@ -69,9 +69,32 @@ struct integrity_iint_cache *integrity_iint_find(struct inode *inode)
|
|||||||
return iint;
|
return iint;
|
||||||
}
|
}
|
||||||
|
|
||||||
static void iint_free(struct integrity_iint_cache *iint)
|
#define IMA_MAX_NESTING (FILESYSTEM_MAX_STACK_DEPTH+1)
|
||||||
|
|
||||||
|
/*
|
||||||
|
* It is not clear that IMA should be nested at all, but as long is it measures
|
||||||
|
* files both on overlayfs and on underlying fs, we need to annotate the iint
|
||||||
|
* mutex to avoid lockdep false positives related to IMA + overlayfs.
|
||||||
|
* See ovl_lockdep_annotate_inode_mutex_key() for more details.
|
||||||
|
*/
|
||||||
|
static inline void iint_lockdep_annotate(struct integrity_iint_cache *iint,
|
||||||
|
struct inode *inode)
|
||||||
|
{
|
||||||
|
#ifdef CONFIG_LOCKDEP
|
||||||
|
static struct lock_class_key iint_mutex_key[IMA_MAX_NESTING];
|
||||||
|
|
||||||
|
int depth = inode->i_sb->s_stack_depth;
|
||||||
|
|
||||||
|
if (WARN_ON_ONCE(depth < 0 || depth >= IMA_MAX_NESTING))
|
||||||
|
depth = 0;
|
||||||
|
|
||||||
|
lockdep_set_class(&iint->mutex, &iint_mutex_key[depth]);
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
|
static void iint_init_always(struct integrity_iint_cache *iint,
|
||||||
|
struct inode *inode)
|
||||||
{
|
{
|
||||||
kfree(iint->ima_hash);
|
|
||||||
iint->ima_hash = NULL;
|
iint->ima_hash = NULL;
|
||||||
iint->version = 0;
|
iint->version = 0;
|
||||||
iint->flags = 0UL;
|
iint->flags = 0UL;
|
||||||
@@ -83,6 +106,14 @@ static void iint_free(struct integrity_iint_cache *iint)
|
|||||||
iint->ima_creds_status = INTEGRITY_UNKNOWN;
|
iint->ima_creds_status = INTEGRITY_UNKNOWN;
|
||||||
iint->evm_status = INTEGRITY_UNKNOWN;
|
iint->evm_status = INTEGRITY_UNKNOWN;
|
||||||
iint->measured_pcrs = 0;
|
iint->measured_pcrs = 0;
|
||||||
|
mutex_init(&iint->mutex);
|
||||||
|
iint_lockdep_annotate(iint, inode);
|
||||||
|
}
|
||||||
|
|
||||||
|
static void iint_free(struct integrity_iint_cache *iint)
|
||||||
|
{
|
||||||
|
kfree(iint->ima_hash);
|
||||||
|
mutex_destroy(&iint->mutex);
|
||||||
kmem_cache_free(iint_cache, iint);
|
kmem_cache_free(iint_cache, iint);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -107,6 +138,8 @@ struct integrity_iint_cache *integrity_inode_get(struct inode *inode)
|
|||||||
if (!iint)
|
if (!iint)
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
||||||
|
iint_init_always(iint, inode);
|
||||||
|
|
||||||
write_lock(&integrity_iint_lock);
|
write_lock(&integrity_iint_lock);
|
||||||
|
|
||||||
p = &integrity_iint_tree.rb_node;
|
p = &integrity_iint_tree.rb_node;
|
||||||
@@ -156,25 +189,18 @@ void integrity_inode_free(struct inode *inode)
|
|||||||
iint_free(iint);
|
iint_free(iint);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void init_once(void *foo)
|
static void iint_init_once(void *foo)
|
||||||
{
|
{
|
||||||
struct integrity_iint_cache *iint = foo;
|
struct integrity_iint_cache *iint = foo;
|
||||||
|
|
||||||
memset(iint, 0, sizeof(*iint));
|
memset(iint, 0, sizeof(*iint));
|
||||||
iint->ima_file_status = INTEGRITY_UNKNOWN;
|
|
||||||
iint->ima_mmap_status = INTEGRITY_UNKNOWN;
|
|
||||||
iint->ima_bprm_status = INTEGRITY_UNKNOWN;
|
|
||||||
iint->ima_read_status = INTEGRITY_UNKNOWN;
|
|
||||||
iint->ima_creds_status = INTEGRITY_UNKNOWN;
|
|
||||||
iint->evm_status = INTEGRITY_UNKNOWN;
|
|
||||||
mutex_init(&iint->mutex);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static int __init integrity_iintcache_init(void)
|
static int __init integrity_iintcache_init(void)
|
||||||
{
|
{
|
||||||
iint_cache =
|
iint_cache =
|
||||||
kmem_cache_create("iint_cache", sizeof(struct integrity_iint_cache),
|
kmem_cache_create("iint_cache", sizeof(struct integrity_iint_cache),
|
||||||
0, SLAB_PANIC, init_once);
|
0, SLAB_PANIC, iint_init_once);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
security_initcall(integrity_iintcache_init);
|
security_initcall(integrity_iintcache_init);
|
||||||
|
|||||||
@@ -201,6 +201,7 @@ int ima_collect_measurement(struct integrity_iint_cache *iint,
|
|||||||
{
|
{
|
||||||
const char *audit_cause = "failed";
|
const char *audit_cause = "failed";
|
||||||
struct inode *inode = file_inode(file);
|
struct inode *inode = file_inode(file);
|
||||||
|
struct inode *real_inode = d_real_inode(file_dentry(file));
|
||||||
const char *filename = file->f_path.dentry->d_name.name;
|
const char *filename = file->f_path.dentry->d_name.name;
|
||||||
int result = 0;
|
int result = 0;
|
||||||
int length;
|
int length;
|
||||||
@@ -243,6 +244,10 @@ int ima_collect_measurement(struct integrity_iint_cache *iint,
|
|||||||
iint->ima_hash = tmpbuf;
|
iint->ima_hash = tmpbuf;
|
||||||
memcpy(iint->ima_hash, &hash, length);
|
memcpy(iint->ima_hash, &hash, length);
|
||||||
iint->version = i_version;
|
iint->version = i_version;
|
||||||
|
if (real_inode != inode) {
|
||||||
|
iint->real_ino = real_inode->i_ino;
|
||||||
|
iint->real_dev = real_inode->i_sb->s_dev;
|
||||||
|
}
|
||||||
|
|
||||||
/* Possibly temporary failure due to type of read (eg. O_DIRECT) */
|
/* Possibly temporary failure due to type of read (eg. O_DIRECT) */
|
||||||
if (!result)
|
if (!result)
|
||||||
|
|||||||
@@ -29,6 +29,7 @@
|
|||||||
#include <linux/ima.h>
|
#include <linux/ima.h>
|
||||||
#include <linux/iversion.h>
|
#include <linux/iversion.h>
|
||||||
#include <linux/fs.h>
|
#include <linux/fs.h>
|
||||||
|
#include <linux/iversion.h>
|
||||||
|
|
||||||
#include "ima.h"
|
#include "ima.h"
|
||||||
|
|
||||||
@@ -170,7 +171,7 @@ static int process_measurement(struct file *file, const struct cred *cred,
|
|||||||
u32 secid, char *buf, loff_t size, int mask,
|
u32 secid, char *buf, loff_t size, int mask,
|
||||||
enum ima_hooks func)
|
enum ima_hooks func)
|
||||||
{
|
{
|
||||||
struct inode *inode = file_inode(file);
|
struct inode *backing_inode, *inode = file_inode(file);
|
||||||
struct integrity_iint_cache *iint = NULL;
|
struct integrity_iint_cache *iint = NULL;
|
||||||
struct ima_template_desc *template_desc;
|
struct ima_template_desc *template_desc;
|
||||||
char *pathbuf = NULL;
|
char *pathbuf = NULL;
|
||||||
@@ -242,6 +243,19 @@ static int process_measurement(struct file *file, const struct cred *cred,
|
|||||||
iint->measured_pcrs = 0;
|
iint->measured_pcrs = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Detect and re-evaluate changes made to the backing file. */
|
||||||
|
backing_inode = d_real_inode(file_dentry(file));
|
||||||
|
if (backing_inode != inode &&
|
||||||
|
(action & IMA_DO_MASK) && (iint->flags & IMA_DONE_MASK)) {
|
||||||
|
if (!IS_I_VERSION(backing_inode) ||
|
||||||
|
backing_inode->i_sb->s_dev != iint->real_dev ||
|
||||||
|
backing_inode->i_ino != iint->real_ino ||
|
||||||
|
!inode_eq_iversion(backing_inode, iint->version)) {
|
||||||
|
iint->flags &= ~IMA_DONE_MASK;
|
||||||
|
iint->measured_pcrs = 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/* Determine if already appraised/measured based on bitmask
|
/* Determine if already appraised/measured based on bitmask
|
||||||
* (IMA_MEASURE, IMA_MEASURED, IMA_XXXX_APPRAISE, IMA_XXXX_APPRAISED,
|
* (IMA_MEASURE, IMA_MEASURED, IMA_XXXX_APPRAISE, IMA_XXXX_APPRAISED,
|
||||||
* IMA_AUDIT, IMA_AUDITED)
|
* IMA_AUDIT, IMA_AUDITED)
|
||||||
|
|||||||
@@ -122,6 +122,8 @@ struct integrity_iint_cache {
|
|||||||
unsigned long flags;
|
unsigned long flags;
|
||||||
unsigned long measured_pcrs;
|
unsigned long measured_pcrs;
|
||||||
unsigned long atomic_flags;
|
unsigned long atomic_flags;
|
||||||
|
unsigned long real_ino;
|
||||||
|
dev_t real_dev;
|
||||||
enum integrity_status ima_file_status:4;
|
enum integrity_status ima_file_status:4;
|
||||||
enum integrity_status ima_mmap_status:4;
|
enum integrity_status ima_mmap_status:4;
|
||||||
enum integrity_status ima_bprm_status:4;
|
enum integrity_status ima_bprm_status:4;
|
||||||
|
|||||||
@@ -2371,6 +2371,8 @@ static struct snd_pci_quirk power_save_blacklist[] = {
|
|||||||
SND_PCI_QUIRK(0x17aa, 0x36a7, "Lenovo C50 All in one", 0),
|
SND_PCI_QUIRK(0x17aa, 0x36a7, "Lenovo C50 All in one", 0),
|
||||||
/* https://bugs.launchpad.net/bugs/1821663 */
|
/* https://bugs.launchpad.net/bugs/1821663 */
|
||||||
SND_PCI_QUIRK(0x1631, 0xe017, "Packard Bell NEC IMEDIA 5204", 0),
|
SND_PCI_QUIRK(0x1631, 0xe017, "Packard Bell NEC IMEDIA 5204", 0),
|
||||||
|
/* KONTRON SinglePC may cause a stall at runtime resume */
|
||||||
|
SND_PCI_QUIRK(0x1734, 0x1232, "KONTRON SinglePC", 0),
|
||||||
{}
|
{}
|
||||||
};
|
};
|
||||||
#endif /* CONFIG_PM */
|
#endif /* CONFIG_PM */
|
||||||
|
|||||||
@@ -1917,6 +1917,7 @@ enum {
|
|||||||
ALC887_FIXUP_ASUS_AUDIO,
|
ALC887_FIXUP_ASUS_AUDIO,
|
||||||
ALC887_FIXUP_ASUS_HMIC,
|
ALC887_FIXUP_ASUS_HMIC,
|
||||||
ALCS1200A_FIXUP_MIC_VREF,
|
ALCS1200A_FIXUP_MIC_VREF,
|
||||||
|
ALC888VD_FIXUP_MIC_100VREF,
|
||||||
};
|
};
|
||||||
|
|
||||||
static void alc889_fixup_coef(struct hda_codec *codec,
|
static void alc889_fixup_coef(struct hda_codec *codec,
|
||||||
@@ -2470,6 +2471,13 @@ static const struct hda_fixup alc882_fixups[] = {
|
|||||||
{}
|
{}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
[ALC888VD_FIXUP_MIC_100VREF] = {
|
||||||
|
.type = HDA_FIXUP_PINCTLS,
|
||||||
|
.v.pins = (const struct hda_pintbl[]) {
|
||||||
|
{ 0x18, PIN_VREF100 }, /* headset mic */
|
||||||
|
{}
|
||||||
|
}
|
||||||
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
static const struct snd_pci_quirk alc882_fixup_tbl[] = {
|
static const struct snd_pci_quirk alc882_fixup_tbl[] = {
|
||||||
@@ -2539,6 +2547,7 @@ static const struct snd_pci_quirk alc882_fixup_tbl[] = {
|
|||||||
SND_PCI_QUIRK(0x106b, 0x4a00, "Macbook 5,2", ALC889_FIXUP_MBA11_VREF),
|
SND_PCI_QUIRK(0x106b, 0x4a00, "Macbook 5,2", ALC889_FIXUP_MBA11_VREF),
|
||||||
|
|
||||||
SND_PCI_QUIRK(0x1071, 0x8258, "Evesham Voyaeger", ALC882_FIXUP_EAPD),
|
SND_PCI_QUIRK(0x1071, 0x8258, "Evesham Voyaeger", ALC882_FIXUP_EAPD),
|
||||||
|
SND_PCI_QUIRK(0x10ec, 0x12d8, "iBase Elo Touch", ALC888VD_FIXUP_MIC_100VREF),
|
||||||
SND_PCI_QUIRK(0x13fe, 0x1009, "Advantech MIT-W101", ALC886_FIXUP_EAPD),
|
SND_PCI_QUIRK(0x13fe, 0x1009, "Advantech MIT-W101", ALC886_FIXUP_EAPD),
|
||||||
SND_PCI_QUIRK(0x1458, 0xa002, "Gigabyte EP45-DS3/Z87X-UD3H", ALC889_FIXUP_FRONT_HP_NO_PRESENCE),
|
SND_PCI_QUIRK(0x1458, 0xa002, "Gigabyte EP45-DS3/Z87X-UD3H", ALC889_FIXUP_FRONT_HP_NO_PRESENCE),
|
||||||
SND_PCI_QUIRK(0x1458, 0xa0b8, "Gigabyte AZ370-Gaming", ALC1220_FIXUP_GB_DUAL_CODECS),
|
SND_PCI_QUIRK(0x1458, 0xa0b8, "Gigabyte AZ370-Gaming", ALC1220_FIXUP_GB_DUAL_CODECS),
|
||||||
|
|||||||
Reference in New Issue
Block a user