Skip to content
This repository has been archived by the owner on Jul 7, 2021. It is now read-only.

Commit

Permalink
Merge 4.14.174 into neutrino-msm-hotdogb-4.14
Browse files Browse the repository at this point in the history
Changes in 4.14.174: (100 commits)
        phy: Revert toggling reset changes.
        net: phy: Avoid multiple suspends
        cgroup, netclassid: periodically release file_lock on classid updating
        gre: fix uninit-value in __iptunnel_pull_header
        ipv6/addrconf: call ipv6_mc_up() for non-Ethernet interface
        ipvlan: add cond_resched_rcu() while processing muticast backlog
        ipvlan: do not use cond_resched_rcu() in ipvlan_process_multicast()
        netlink: Use netlink header as base to calculate bad attribute offset
        net: macsec: update SCI upon MAC address change.
        net: nfc: fix bounds checking bugs on "pipe"
        net/packet: tpacket_rcv: do not increment ring index on drop
        r8152: check disconnect status after long sleep
        sfc: detach from cb_page in efx_copy_channel()
        bnxt_en: reinitialize IRQs when MTU is modified
        cgroup: memcg: net: do not associate sock with unrelated cgroup
        net: memcg: late association of sock to memcg
        net: memcg: fix lockdep splat in inet_csk_accept()
        fib: add missing attribute validation for tun_id
        nl802154: add missing attribute validation
        nl802154: add missing attribute validation for dev_type
        can: add missing attribute validation for termination
        macsec: add missing attribute validation for port
        net: fq: add missing attribute validation for orphan mask
        team: add missing attribute validation for port ifindex
        team: add missing attribute validation for array index
        nfc: add missing attribute validation for SE API
        nfc: add missing attribute validation for vendor subcommand
        net: phy: fix MDIO bus PM PHY resuming
        bonding/alb: make sure arp header is pulled before accessing it
        slip: make slhc_compress() more robust against malicious packets
        net: fec: validate the new settings in fec_enet_set_coalesce()
        macvlan: add cond_resched() during multicast processing
        inet_diag: return classid for all socket types
        ipvlan: do not add hardware address of master to its unicast filter list
        ipvlan: egress mcast packets are not exceptional
        ipvlan: don't deref eth hdr before checking it's set
        cgroup: cgroup_procs_next should increase position index
        cgroup: Iterate tasks that did not finish do_exit()
        iwlwifi: mvm: Do not require PHY_SKU NVM section for 3168 devices
        virtio-blk: fix hw_queue stopped on arbitrary error
        iommu/vt-d: quirk_ioat_snb_local_iommu: replace WARN_TAINT with pr_warn + add_taint
        workqueue: don't use wq_select_unbound_cpu() for bound works
        drm/amd/display: remove duplicated assignment to grph_obj_type
        ktest: Add timeout for ssh sync testing
        cifs_atomic_open(): fix double-put on late allocation failure
        gfs2_atomic_open(): fix O_EXCL|O_CREAT handling on cold dcache
        KVM: x86: clear stale x86_emulate_ctxt->intercept value
        ARC: define __ALIGN_STR and __ALIGN symbols for ARC
        efi: Fix a race and a buffer overflow while reading efivars via sysfs
        x86/mce: Fix logic and comments around MSR_PPIN_CTL
        iommu/dma: Fix MSI reservation allocation
        iommu/vt-d: dmar: replace WARN_TAINT with pr_warn + add_taint
        iommu/vt-d: Fix a bug in intel_iommu_iova_to_phys() for huge page
        pinctrl: meson-gxl: fix GPIOX sdio pins
        pinctrl: core: Remove extra kref_get which blocks hogs being freed
        nl80211: add missing attribute validation for critical protocol indication
        nl80211: add missing attribute validation for beacon report scanning
        nl80211: add missing attribute validation for channel switch
        netfilter: cthelper: add missing attribute validation for cthelper
        netfilter: nft_payload: add missing attribute validation for payload csum flags
        iommu/vt-d: Fix the wrong printing in RHSA parsing
        iommu/vt-d: Ignore devices with out-of-spec domain number
        i2c: acpi: put device when verifying client fails
        ipv6: restrict IPV6_ADDRFORM operation
        net/smc: check for valid ib_client_data
        efi: Add a sanity check to efivar_store_raw()
        batman-adv: Avoid spurious warnings from bat_v neigh_cmp implementation
        batman-adv: Always initialize fragment header priority
        batman-adv: Fix check of retrieved orig_gw in batadv_v_gw_is_eligible
        batman-adv: Fix lock for ogm cnt access in batadv_iv_ogm_calc_tq
        batman-adv: Fix internal interface indices types
        batman-adv: update data pointers after skb_cow()
        batman-adv: Avoid race in TT TVLV allocator helper
        batman-adv: Fix TT sync flags for intermediate TT responses
        batman-adv: prevent TT request storms by not sending inconsistent TT TLVLs
        batman-adv: Fix debugfs path for renamed hardif
        batman-adv: Fix debugfs path for renamed softif
        batman-adv: Fix duplicated OGMs on NETDEV_UP
        batman-adv: Avoid free/alloc race when handling OGM2 buffer
        batman-adv: Avoid free/alloc race when handling OGM buffer
        batman-adv: Don't schedule OGM for disabled interface
        perf/amd/uncore: Replace manual sampling check with CAP_NO_INTERRUPT flag
        ACPI: watchdog: Allow disabling WDAT at boot
        HID: apple: Add support for recent firmware on Magic Keyboards
        HID: i2c-hid: add Trekstor Surfbook E11B to descriptor override
        cfg80211: check reg_rule for NULL in handle_channel_custom()
        scsi: libfc: free response frame from GPN_ID
        net: usb: qmi_wwan: restore mtu min/max values after raw_ip switch
        net: ks8851-ml: Fix IRQ handling and locking
        mac80211: rx: avoid RCU list traversal under mutex
        signal: avoid double atomic counter increments for user accounting
        slip: not call free_netdev before rtnl_unlock in slip_open
        hinic: fix a bug of setting hw_ioctxt
        net: rmnet: fix NULL pointer dereference in rmnet_newlink()
        jbd2: fix data races at struct journal_head
        ARM: 8957/1: VDSO: Match ARMv8 timer in cntvct_functional()
        ARM: 8958/1: rename missed uaccess .fixup section
        mm: slub: add missing TID bump in kmem_cache_alloc_bulk()
        ipv4: ensure rcu_read_lock() in cipso_v4_error()
        Linux 4.14.174

Signed-off-by: Adam W. Willis <return.of.octobot@gmail.com>
  • Loading branch information
0ctobot committed Mar 21, 2020
2 parents db9beba + 01364da commit 0d56071
Show file tree
Hide file tree
Showing 92 changed files with 763 additions and 294 deletions.
4 changes: 4 additions & 0 deletions Documentation/admin-guide/kernel-parameters.txt
Expand Up @@ -137,6 +137,10 @@
dynamic table installation which will install SSDT
tables to /sys/firmware/acpi/tables/dynamic.

acpi_no_watchdog [HW,ACPI,WDT]
Ignore the ACPI-based watchdog interface (WDAT) and let
a native driver control the watchdog device instead.

acpi_rsdp= [ACPI,EFI,KEXEC]
Pass the RSDP address to the kernel, mostly used
on machines running EFI runtime service to boot the
Expand Down
7 changes: 7 additions & 0 deletions Documentation/filesystems/porting
Expand Up @@ -606,3 +606,10 @@ in your dentry operations instead.
dentry separately, and it now has request_mask and query_flags arguments
to specify the fields and sync type requested by statx. Filesystems not
supporting any statx-specific features may ignore the new arguments.
--
[mandatory]

[should've been added in 2016] stale comment in finish_open()
nonwithstanding, failure exits in ->atomic_open() instances should
*NOT* fput() the file, no matter what. Everything is handled by the
caller.
2 changes: 1 addition & 1 deletion Makefile
@@ -1,7 +1,7 @@
# SPDX-License-Identifier: GPL-2.0
VERSION = 4
PATCHLEVEL = 14
SUBLEVEL = 173
SUBLEVEL = 174
EXTRAVERSION =
NAME = Petit Gorille

Expand Down
2 changes: 2 additions & 0 deletions arch/arc/include/asm/linkage.h
Expand Up @@ -14,6 +14,8 @@
#ifdef __ASSEMBLY__

#define ASM_NL ` /* use '`' to mark new line in macro */
#define __ALIGN .align 4
#define __ALIGN_STR __stringify(__ALIGN)

/* annotation for data we want in DCCM - if enabled in .config */
.macro ARCFP_DATA nm
Expand Down
2 changes: 2 additions & 0 deletions arch/arm/kernel/vdso.c
Expand Up @@ -103,6 +103,8 @@ static bool __init cntvct_functional(void)
* this.
*/
np = of_find_compatible_node(NULL, NULL, "arm,armv7-timer");
if (!np)
np = of_find_compatible_node(NULL, NULL, "arm,armv8-timer");
if (!np)
goto out_put;

Expand Down
2 changes: 1 addition & 1 deletion arch/arm/lib/copy_from_user.S
Expand Up @@ -100,7 +100,7 @@ ENTRY(arm_copy_from_user)

ENDPROC(arm_copy_from_user)

.pushsection .fixup,"ax"
.pushsection .text.fixup,"ax"
.align 0
copy_abort_preamble
ldmfd sp!, {r1, r2, r3}
Expand Down
14 changes: 7 additions & 7 deletions arch/x86/events/amd/uncore.c
Expand Up @@ -193,20 +193,18 @@ static int amd_uncore_event_init(struct perf_event *event)

/*
* NB and Last level cache counters (MSRs) are shared across all cores
* that share the same NB / Last level cache. Interrupts can be directed
* to a single target core, however, event counts generated by processes
* running on other cores cannot be masked out. So we do not support
* sampling and per-thread events.
* that share the same NB / Last level cache. On family 16h and below,
* Interrupts can be directed to a single target core, however, event
* counts generated by processes running on other cores cannot be masked
* out. So we do not support sampling and per-thread events via
* CAP_NO_INTERRUPT, and we do not enable counter overflow interrupts:
*/
if (is_sampling_event(event) || event->attach_state & PERF_ATTACH_TASK)
return -EINVAL;

/* NB and Last level cache counters do not have usr/os/guest/host bits */
if (event->attr.exclude_user || event->attr.exclude_kernel ||
event->attr.exclude_host || event->attr.exclude_guest)
return -EINVAL;

/* and we do not enable counter overflow interrupts */
hwc->config = event->attr.config & AMD64_RAW_EVENT_MASK_NB;
hwc->idx = -1;

Expand Down Expand Up @@ -314,6 +312,7 @@ static struct pmu amd_nb_pmu = {
.start = amd_uncore_start,
.stop = amd_uncore_stop,
.read = amd_uncore_read,
.capabilities = PERF_PMU_CAP_NO_INTERRUPT,
};

static struct pmu amd_llc_pmu = {
Expand All @@ -324,6 +323,7 @@ static struct pmu amd_llc_pmu = {
.start = amd_uncore_start,
.stop = amd_uncore_stop,
.read = amd_uncore_read,
.capabilities = PERF_PMU_CAP_NO_INTERRUPT,
};

static struct amd_uncore *amd_uncore_alloc(unsigned int cpu)
Expand Down
9 changes: 5 additions & 4 deletions arch/x86/kernel/cpu/mcheck/mce_intel.c
Expand Up @@ -489,17 +489,18 @@ static void intel_ppin_init(struct cpuinfo_x86 *c)
return;

if ((val & 3UL) == 1UL) {
/* PPIN available but disabled: */
/* PPIN locked in disabled mode */
return;
}

/* If PPIN is disabled, but not locked, try to enable: */
if (!(val & 3UL)) {
/* If PPIN is disabled, try to enable */
if (!(val & 2UL)) {
wrmsrl_safe(MSR_PPIN_CTL, val | 2UL);
rdmsrl_safe(MSR_PPIN_CTL, &val);
}

if ((val & 3UL) == 2UL)
/* Is the enable bit set? */
if (val & 2UL)
set_cpu_cap(c, X86_FEATURE_INTEL_PPIN);
}
}
Expand Down
1 change: 1 addition & 0 deletions arch/x86/kvm/emulate.c
Expand Up @@ -5062,6 +5062,7 @@ int x86_decode_insn(struct x86_emulate_ctxt *ctxt, void *insn, int insn_len)
ctxt->fetch.ptr = ctxt->fetch.data;
ctxt->fetch.end = ctxt->fetch.data + insn_len;
ctxt->opcode_len = 1;
ctxt->intercept = x86_intercept_none;
if (insn_len > 0)
memcpy(ctxt->fetch.data, insn, insn_len);
else {
Expand Down
12 changes: 11 additions & 1 deletion drivers/acpi/acpi_watchdog.c
Expand Up @@ -58,12 +58,14 @@ static bool acpi_watchdog_uses_rtc(const struct acpi_table_wdat *wdat)
}
#endif

static bool acpi_no_watchdog;

static const struct acpi_table_wdat *acpi_watchdog_get_wdat(void)
{
const struct acpi_table_wdat *wdat = NULL;
acpi_status status;

if (acpi_disabled)
if (acpi_disabled || acpi_no_watchdog)
return NULL;

status = acpi_get_table(ACPI_SIG_WDAT, 0,
Expand Down Expand Up @@ -91,6 +93,14 @@ bool acpi_has_watchdog(void)
}
EXPORT_SYMBOL_GPL(acpi_has_watchdog);

/* ACPI watchdog can be disabled on boot command line */
static int __init disable_acpi_watchdog(char *str)
{
acpi_no_watchdog = true;
return 1;
}
__setup("acpi_no_watchdog", disable_acpi_watchdog);

void __init acpi_watchdog_init(void)
{
const struct acpi_wdat_entry *entries;
Expand Down
8 changes: 5 additions & 3 deletions drivers/block/virtio_blk.c
Expand Up @@ -271,10 +271,12 @@ static blk_status_t virtio_queue_rq(struct blk_mq_hw_ctx *hctx,
err = virtblk_add_req(vblk->vqs[qid].vq, vbr, vbr->sg, num);
if (err) {
virtqueue_kick(vblk->vqs[qid].vq);
blk_mq_stop_hw_queue(hctx);
/* Don't stop the queue if -ENOMEM: we may have failed to
* bounce the buffer due to global resource outage.
*/
if (err == -ENOSPC)
blk_mq_stop_hw_queue(hctx);
spin_unlock_irqrestore(&vblk->vqs[qid].lock, flags);
/* Out of mem doesn't actually happen, since we fall back
* to direct descriptors */
if (err == -ENOMEM || err == -ENOSPC)
return BLK_STS_RESOURCE;
return BLK_STS_IOERR;
Expand Down
32 changes: 23 additions & 9 deletions drivers/firmware/efi/efivars.c
Expand Up @@ -139,13 +139,16 @@ static ssize_t
efivar_attr_read(struct efivar_entry *entry, char *buf)
{
struct efi_variable *var = &entry->var;
unsigned long size = sizeof(var->Data);
char *str = buf;
int ret;

if (!entry || !buf)
return -EINVAL;

var->DataSize = 1024;
if (efivar_entry_get(entry, &var->Attributes, &var->DataSize, var->Data))
ret = efivar_entry_get(entry, &var->Attributes, &size, var->Data);
var->DataSize = size;
if (ret)
return -EIO;

if (var->Attributes & EFI_VARIABLE_NON_VOLATILE)
Expand All @@ -172,13 +175,16 @@ static ssize_t
efivar_size_read(struct efivar_entry *entry, char *buf)
{
struct efi_variable *var = &entry->var;
unsigned long size = sizeof(var->Data);
char *str = buf;
int ret;

if (!entry || !buf)
return -EINVAL;

var->DataSize = 1024;
if (efivar_entry_get(entry, &var->Attributes, &var->DataSize, var->Data))
ret = efivar_entry_get(entry, &var->Attributes, &size, var->Data);
var->DataSize = size;
if (ret)
return -EIO;

str += sprintf(str, "0x%lx\n", var->DataSize);
Expand All @@ -189,12 +195,15 @@ static ssize_t
efivar_data_read(struct efivar_entry *entry, char *buf)
{
struct efi_variable *var = &entry->var;
unsigned long size = sizeof(var->Data);
int ret;

if (!entry || !buf)
return -EINVAL;

var->DataSize = 1024;
if (efivar_entry_get(entry, &var->Attributes, &var->DataSize, var->Data))
ret = efivar_entry_get(entry, &var->Attributes, &size, var->Data);
var->DataSize = size;
if (ret)
return -EIO;

memcpy(buf, var->Data, var->DataSize);
Expand Down Expand Up @@ -263,6 +272,9 @@ efivar_store_raw(struct efivar_entry *entry, const char *buf, size_t count)
u8 *data;
int err;

if (!entry || !buf)
return -EINVAL;

if (is_compat()) {
struct compat_efi_variable *compat;

Expand Down Expand Up @@ -314,14 +326,16 @@ efivar_show_raw(struct efivar_entry *entry, char *buf)
{
struct efi_variable *var = &entry->var;
struct compat_efi_variable *compat;
unsigned long datasize = sizeof(var->Data);
size_t size;
int ret;

if (!entry || !buf)
return 0;

var->DataSize = 1024;
if (efivar_entry_get(entry, &entry->var.Attributes,
&entry->var.DataSize, entry->var.Data))
ret = efivar_entry_get(entry, &var->Attributes, &datasize, var->Data);
var->DataSize = datasize;
if (ret)
return -EIO;

if (is_compat()) {
Expand Down
3 changes: 1 addition & 2 deletions drivers/gpu/drm/amd/amdgpu/amdgpu_atombios.c
Expand Up @@ -363,8 +363,7 @@ bool amdgpu_atombios_get_connector_info_from_object_table(struct amdgpu_device *
router.ddc_valid = false;
router.cd_valid = false;
for (j = 0; j < ((le16_to_cpu(path->usSize) - 8) / 2); j++) {
uint8_t grph_obj_type=
grph_obj_type =
uint8_t grph_obj_type =
(le16_to_cpu(path->usGraphicObjIds[j]) &
OBJECT_TYPE_MASK) >> OBJECT_TYPE_SHIFT;

Expand Down
3 changes: 2 additions & 1 deletion drivers/hid/hid-apple.c
Expand Up @@ -343,7 +343,8 @@ static int apple_input_mapping(struct hid_device *hdev, struct hid_input *hi,
unsigned long **bit, int *max)
{
if (usage->hid == (HID_UP_CUSTOM | 0x0003) ||
usage->hid == (HID_UP_MSVENDOR | 0x0003)) {
usage->hid == (HID_UP_MSVENDOR | 0x0003) ||
usage->hid == (HID_UP_HPVENDOR2 | 0x0003)) {
/* The fn key on Apple USB keyboards */
set_bit(EV_REP, hi->input->evbit);
hid_map_usage_clear(hi, usage, bit, max, EV_KEY, KEY_FN);
Expand Down
8 changes: 8 additions & 0 deletions drivers/hid/i2c-hid/i2c-hid-dmi-quirks.c
Expand Up @@ -341,6 +341,14 @@ static const struct dmi_system_id i2c_hid_dmi_desc_override_table[] = {
},
.driver_data = (void *)&sipodev_desc
},
{
.ident = "Trekstor SURFBOOK E11B",
.matches = {
DMI_EXACT_MATCH(DMI_SYS_VENDOR, "TREKSTOR"),
DMI_EXACT_MATCH(DMI_PRODUCT_NAME, "SURFBOOK E11B"),
},
.driver_data = (void *)&sipodev_desc
},
{
.ident = "Direkt-Tek DTLAPY116-2",
.matches = {
Expand Down
10 changes: 9 additions & 1 deletion drivers/i2c/i2c-core-acpi.c
Expand Up @@ -352,10 +352,18 @@ static struct i2c_adapter *i2c_acpi_find_adapter_by_handle(acpi_handle handle)
static struct i2c_client *i2c_acpi_find_client_by_adev(struct acpi_device *adev)
{
struct device *dev;
struct i2c_client *client;

dev = bus_find_device(&i2c_bus_type, NULL, adev,
i2c_acpi_find_match_device);
return dev ? i2c_verify_client(dev) : NULL;
if (!dev)
return NULL;

client = i2c_verify_client(dev);
if (!client)
put_device(dev);

return client;
}

static int i2c_acpi_notify(struct notifier_block *nb, unsigned long value,
Expand Down
16 changes: 8 additions & 8 deletions drivers/iommu/dma-iommu.c
Expand Up @@ -212,15 +212,15 @@ static int cookie_init_hw_msi_region(struct iommu_dma_cookie *cookie,
start -= iova_offset(iovad, start);
num_pages = iova_align(iovad, end - start) >> iova_shift(iovad);

msi_page = kcalloc(num_pages, sizeof(*msi_page), GFP_KERNEL);
if (!msi_page)
return -ENOMEM;

for (i = 0; i < num_pages; i++) {
msi_page[i].phys = start;
msi_page[i].iova = start;
INIT_LIST_HEAD(&msi_page[i].list);
list_add(&msi_page[i].list, &cookie->msi_page_list);
msi_page = kmalloc(sizeof(*msi_page), GFP_KERNEL);
if (!msi_page)
return -ENOMEM;

msi_page->phys = start;
msi_page->iova = start;
INIT_LIST_HEAD(&msi_page->list);
list_add(&msi_page->list, &cookie->msi_page_list);
start += iovad->granule;
}

Expand Down

0 comments on commit 0d56071

Please sign in to comment.