mirror of
https://github.com/a52xq-dev/kernel.git
synced 2026-10-18 13:48:09 +07:00
This is the 4.19.127 stable release
-----BEGIN PGP SIGNATURE----- iQIzBAABCAAdFiEEZH8oZUiU471FcZm+ONu9yGCSaT4FAl7czOcACgkQONu9yGCS aT4XBBAAvMwls1yBK2I/9kWES9aZv0zjHIGl9LimzsTysEDo+4gFGJU8fZoIH2T/ pFbUtmFMyvnAYXTg7QbDBGnzriflufekyBKlPlNqDmq3zv6kD9x6VklowZmW4c4m TkIeXTyhiZVLpYhJy5LGwmzEAJ8ZABbqq2YghSqWhvldYdDLT/bfXe+jEKildM7h 4YVtudfDrryK2pLo8rI3acWfoVnbRiuX7B77DJ+3qI0r1vps25Ht7lg957wvqMqC LbSrnrOxp3WaSgnCqBEUvMTP2G+JPgXeFF9LdmktjwiWT5yGsBPHb6EDeEZ4to9d WuSWttlRjAkwK1oe2Z0Er5Hahb98ZrIFmQsjuNpMGO29pT0IGbmOS6KJMz4uGhC0 5NUcf6Fcnez05B9Pi2XljlwaCLv/xyz4lPyqSs/KHyu4GxsOeeHrVpnHY5Ei41N2 Ujglqy0tNV1rgRZZCEQA7rGzvLta0JC3SEqeqcJFahvL+NYLRP/WK7eCGuzOUuMs vv727ewOj5znb9f4UHCLFB9au0YsjaPvsEhw9pfoePVMpOt+25kS96z872VnUsUV tESAK7+BAIQDV6Q63S9MrNEJPBLUEFnA4J2WrwE9+6v19Az0usH8hlB0Swxhn7xn B6q4d17FhNSyXFbqJYjcT0ddWVv5qDIyuLbTB8EdxH3D+cRfuAM= =+xz9 -----END PGP SIGNATURE----- Merge 4.19.127 into android-4.19-stable Changes in 4.19.127 Revert "cgroup: Add memory barriers to plug cgroup_rstat_updated() race window" libnvdimm: Fix endian conversion issues mm: Fix mremap not considering huge pmd devmap HID: sony: Fix for broken buttons on DS3 USB dongles HID: i2c-hid: add Schneider SCL142ALM to descriptor override p54usb: add AirVasT USB stick device-id kernel/relay.c: handle alloc_percpu returning NULL in relay_open mmc: fix compilation of user API scsi: ufs: Release clock if DMA map fails net: dsa: mt7530: set CPU port to fallback mode airo: Fix read overflows sending packets drm/i915: fix port checks for MST support on gen >= 11 scsi: hisi_sas: Check sas_port before using it powerpc/powernv: Avoid re-registration of imc debugfs directory spi: dw: use "smp_mb()" to avoid sending spi data error s390/ftrace: save traced function caller ARC: Fix ICCM & DCCM runtime size checks ARC: [plat-eznps]: Restrict to CONFIG_ISA_ARCOMPACT evm: Fix RCU list related warnings i2c: altera: Fix race between xfer_msg and isr thread x86/mmiotrace: Use cpumask_available() for cpumask_var_t variables net: bmac: Fix read of MAC address from ROM drm/edid: Add Oculus Rift S to non-desktop list s390/mm: fix set_huge_pte_at() for empty ptes null_blk: return error for invalid zone size net/ethernet/freescale: rework quiesce/activate for ucc_geth net: ethernet: stmmac: Enable interface clocks on probe for IPQ806x net: smsc911x: Fix runtime PM imbalance on error Linux 4.19.127 Signed-off-by: Greg Kroah-Hartman <gregkh@google.com> Change-Id: I0ba65b19a1f1d3d1767e8f5cccef4b2f320cdd59
This commit is contained in:
commit
8f1ab4ae37
35 changed files with 177 additions and 84 deletions
2
Makefile
2
Makefile
|
|
@ -1,7 +1,7 @@
|
|||
# SPDX-License-Identifier: GPL-2.0
|
||||
VERSION = 4
|
||||
PATCHLEVEL = 19
|
||||
SUBLEVEL = 126
|
||||
SUBLEVEL = 127
|
||||
EXTRAVERSION =
|
||||
NAME = "People's Front"
|
||||
|
||||
|
|
|
|||
|
|
@ -15,6 +15,7 @@
|
|||
#include <linux/clocksource.h>
|
||||
#include <linux/console.h>
|
||||
#include <linux/module.h>
|
||||
#include <linux/sizes.h>
|
||||
#include <linux/cpu.h>
|
||||
#include <linux/of_fdt.h>
|
||||
#include <linux/of.h>
|
||||
|
|
@ -406,12 +407,12 @@ static void arc_chk_core_config(void)
|
|||
if ((unsigned int)__arc_dccm_base != cpu->dccm.base_addr)
|
||||
panic("Linux built with incorrect DCCM Base address\n");
|
||||
|
||||
if (CONFIG_ARC_DCCM_SZ != cpu->dccm.sz)
|
||||
if (CONFIG_ARC_DCCM_SZ * SZ_1K != cpu->dccm.sz)
|
||||
panic("Linux built with incorrect DCCM Size\n");
|
||||
#endif
|
||||
|
||||
#ifdef CONFIG_ARC_HAS_ICCM
|
||||
if (CONFIG_ARC_ICCM_SZ != cpu->iccm.sz)
|
||||
if (CONFIG_ARC_ICCM_SZ * SZ_1K != cpu->iccm.sz)
|
||||
panic("Linux built with incorrect ICCM Size\n");
|
||||
#endif
|
||||
|
||||
|
|
|
|||
|
|
@ -6,6 +6,7 @@
|
|||
|
||||
menuconfig ARC_PLAT_EZNPS
|
||||
bool "\"EZchip\" ARC dev platform"
|
||||
depends on ISA_ARCOMPACT
|
||||
select CPU_BIG_ENDIAN
|
||||
select CLKSRC_NPS if !PHYS_ADDR_T_64BIT
|
||||
select EZNPS_GIC
|
||||
|
|
|
|||
|
|
@ -63,10 +63,6 @@ static void export_imc_mode_and_cmd(struct device_node *node,
|
|||
|
||||
imc_debugfs_parent = debugfs_create_dir("imc", powerpc_debugfs_root);
|
||||
|
||||
/*
|
||||
* Return here, either because 'imc' directory already exists,
|
||||
* Or failed to create a new one.
|
||||
*/
|
||||
if (!imc_debugfs_parent)
|
||||
return;
|
||||
|
||||
|
|
@ -139,7 +135,6 @@ static int imc_get_mem_addr_nest(struct device_node *node,
|
|||
}
|
||||
|
||||
pmu_ptr->imc_counter_mmaped = true;
|
||||
export_imc_mode_and_cmd(node, pmu_ptr);
|
||||
kfree(base_addr_arr);
|
||||
kfree(chipid_arr);
|
||||
return 0;
|
||||
|
|
@ -155,7 +150,7 @@ error:
|
|||
* and domain as the inputs.
|
||||
* Allocates memory for the struct imc_pmu, sets up its domain, size and offsets
|
||||
*/
|
||||
static int imc_pmu_create(struct device_node *parent, int pmu_index, int domain)
|
||||
static struct imc_pmu *imc_pmu_create(struct device_node *parent, int pmu_index, int domain)
|
||||
{
|
||||
int ret = 0;
|
||||
struct imc_pmu *pmu_ptr;
|
||||
|
|
@ -163,27 +158,23 @@ static int imc_pmu_create(struct device_node *parent, int pmu_index, int domain)
|
|||
|
||||
/* Return for unknown domain */
|
||||
if (domain < 0)
|
||||
return -EINVAL;
|
||||
return NULL;
|
||||
|
||||
/* memory for pmu */
|
||||
pmu_ptr = kzalloc(sizeof(*pmu_ptr), GFP_KERNEL);
|
||||
if (!pmu_ptr)
|
||||
return -ENOMEM;
|
||||
return NULL;
|
||||
|
||||
/* Set the domain */
|
||||
pmu_ptr->domain = domain;
|
||||
|
||||
ret = of_property_read_u32(parent, "size", &pmu_ptr->counter_mem_size);
|
||||
if (ret) {
|
||||
ret = -EINVAL;
|
||||
if (ret)
|
||||
goto free_pmu;
|
||||
}
|
||||
|
||||
if (!of_property_read_u32(parent, "offset", &offset)) {
|
||||
if (imc_get_mem_addr_nest(parent, pmu_ptr, offset)) {
|
||||
ret = -EINVAL;
|
||||
if (imc_get_mem_addr_nest(parent, pmu_ptr, offset))
|
||||
goto free_pmu;
|
||||
}
|
||||
}
|
||||
|
||||
/* Function to register IMC pmu */
|
||||
|
|
@ -194,14 +185,14 @@ static int imc_pmu_create(struct device_node *parent, int pmu_index, int domain)
|
|||
if (pmu_ptr->domain == IMC_DOMAIN_NEST)
|
||||
kfree(pmu_ptr->mem_info);
|
||||
kfree(pmu_ptr);
|
||||
return ret;
|
||||
return NULL;
|
||||
}
|
||||
|
||||
return 0;
|
||||
return pmu_ptr;
|
||||
|
||||
free_pmu:
|
||||
kfree(pmu_ptr);
|
||||
return ret;
|
||||
return NULL;
|
||||
}
|
||||
|
||||
static void disable_nest_pmu_counters(void)
|
||||
|
|
@ -258,6 +249,7 @@ int get_max_nest_dev(void)
|
|||
static int opal_imc_counters_probe(struct platform_device *pdev)
|
||||
{
|
||||
struct device_node *imc_dev = pdev->dev.of_node;
|
||||
struct imc_pmu *pmu;
|
||||
int pmu_count = 0, domain;
|
||||
bool core_imc_reg = false, thread_imc_reg = false;
|
||||
u32 type;
|
||||
|
|
@ -273,6 +265,7 @@ static int opal_imc_counters_probe(struct platform_device *pdev)
|
|||
}
|
||||
|
||||
for_each_compatible_node(imc_dev, NULL, IMC_DTB_UNIT_COMPAT) {
|
||||
pmu = NULL;
|
||||
if (of_property_read_u32(imc_dev, "type", &type)) {
|
||||
pr_warn("IMC Device without type property\n");
|
||||
continue;
|
||||
|
|
@ -294,9 +287,13 @@ static int opal_imc_counters_probe(struct platform_device *pdev)
|
|||
break;
|
||||
}
|
||||
|
||||
if (!imc_pmu_create(imc_dev, pmu_count, domain)) {
|
||||
if (domain == IMC_DOMAIN_NEST)
|
||||
pmu = imc_pmu_create(imc_dev, pmu_count, domain);
|
||||
if (pmu != NULL) {
|
||||
if (domain == IMC_DOMAIN_NEST) {
|
||||
if (!imc_debugfs_parent)
|
||||
export_imc_mode_and_cmd(imc_dev, pmu);
|
||||
pmu_count++;
|
||||
}
|
||||
if (domain == IMC_DOMAIN_CORE)
|
||||
core_imc_reg = true;
|
||||
if (domain == IMC_DOMAIN_THREAD)
|
||||
|
|
@ -304,10 +301,6 @@ static int opal_imc_counters_probe(struct platform_device *pdev)
|
|||
}
|
||||
}
|
||||
|
||||
/* If none of the nest units are registered, remove debugfs interface */
|
||||
if (pmu_count == 0)
|
||||
debugfs_remove_recursive(imc_debugfs_parent);
|
||||
|
||||
/* If core imc is not registered, unregister thread-imc */
|
||||
if (!core_imc_reg && thread_imc_reg)
|
||||
unregister_thread_imc();
|
||||
|
|
|
|||
|
|
@ -40,6 +40,7 @@ EXPORT_SYMBOL(_mcount)
|
|||
ENTRY(ftrace_caller)
|
||||
.globl ftrace_regs_caller
|
||||
.set ftrace_regs_caller,ftrace_caller
|
||||
stg %r14,(__SF_GPRS+8*8)(%r15) # save traced function caller
|
||||
lgr %r1,%r15
|
||||
#if !(defined(CC_USING_HOTPATCH) || defined(CC_USING_NOP_MCOUNT))
|
||||
aghi %r0,MCOUNT_RETURN_FIXUP
|
||||
|
|
|
|||
|
|
@ -159,10 +159,13 @@ void set_huge_pte_at(struct mm_struct *mm, unsigned long addr,
|
|||
rste &= ~_SEGMENT_ENTRY_NOEXEC;
|
||||
|
||||
/* Set correct table type for 2G hugepages */
|
||||
if ((pte_val(*ptep) & _REGION_ENTRY_TYPE_MASK) == _REGION_ENTRY_TYPE_R3)
|
||||
rste |= _REGION_ENTRY_TYPE_R3 | _REGION3_ENTRY_LARGE;
|
||||
else
|
||||
if ((pte_val(*ptep) & _REGION_ENTRY_TYPE_MASK) == _REGION_ENTRY_TYPE_R3) {
|
||||
if (likely(pte_present(pte)))
|
||||
rste |= _REGION3_ENTRY_LARGE;
|
||||
rste |= _REGION_ENTRY_TYPE_R3;
|
||||
} else if (likely(pte_present(pte)))
|
||||
rste |= _SEGMENT_ENTRY_LARGE;
|
||||
|
||||
clear_huge_pte_skeys(mm, rste);
|
||||
pte_val(*ptep) = rste;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -237,6 +237,7 @@ static inline int pmd_large(pmd_t pte)
|
|||
}
|
||||
|
||||
#ifdef CONFIG_TRANSPARENT_HUGEPAGE
|
||||
/* NOTE: when predicate huge page, consider also pmd_devmap, or use pmd_large */
|
||||
static inline int pmd_trans_huge(pmd_t pmd)
|
||||
{
|
||||
return (pmd_val(pmd) & (_PAGE_PSE|_PAGE_DEVMAP)) == _PAGE_PSE;
|
||||
|
|
|
|||
|
|
@ -384,7 +384,7 @@ static void enter_uniprocessor(void)
|
|||
int cpu;
|
||||
int err;
|
||||
|
||||
if (downed_cpus == NULL &&
|
||||
if (!cpumask_available(downed_cpus) &&
|
||||
!alloc_cpumask_var(&downed_cpus, GFP_KERNEL)) {
|
||||
pr_notice("Failed to allocate mask\n");
|
||||
goto out;
|
||||
|
|
@ -414,7 +414,7 @@ static void leave_uniprocessor(void)
|
|||
int cpu;
|
||||
int err;
|
||||
|
||||
if (downed_cpus == NULL || cpumask_weight(downed_cpus) == 0)
|
||||
if (!cpumask_available(downed_cpus) || cpumask_weight(downed_cpus) == 0)
|
||||
return;
|
||||
pr_notice("Re-enabling CPUs...\n");
|
||||
for_each_cpu(cpu, downed_cpus) {
|
||||
|
|
|
|||
|
|
@ -20,6 +20,10 @@ int null_zone_init(struct nullb_device *dev)
|
|||
pr_err("null_blk: zone_size must be power-of-two\n");
|
||||
return -EINVAL;
|
||||
}
|
||||
if (dev->zone_size > dev->size) {
|
||||
pr_err("Zone size larger than device capacity\n");
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
dev->zone_size_sects = dev->zone_size << ZONE_SIZE_SHIFT;
|
||||
dev->nr_zones = dev_size >>
|
||||
|
|
|
|||
|
|
@ -206,10 +206,11 @@ static const struct edid_quirk {
|
|||
{ "HVR", 0xaa01, EDID_QUIRK_NON_DESKTOP },
|
||||
{ "HVR", 0xaa02, EDID_QUIRK_NON_DESKTOP },
|
||||
|
||||
/* Oculus Rift DK1, DK2, and CV1 VR Headsets */
|
||||
/* Oculus Rift DK1, DK2, CV1 and Rift S VR Headsets */
|
||||
{ "OVR", 0x0001, EDID_QUIRK_NON_DESKTOP },
|
||||
{ "OVR", 0x0003, EDID_QUIRK_NON_DESKTOP },
|
||||
{ "OVR", 0x0004, EDID_QUIRK_NON_DESKTOP },
|
||||
{ "OVR", 0x0012, EDID_QUIRK_NON_DESKTOP },
|
||||
|
||||
/* Windows Mixed Reality Headsets */
|
||||
{ "ACR", 0x7fce, EDID_QUIRK_NON_DESKTOP },
|
||||
|
|
|
|||
|
|
@ -6288,11 +6288,8 @@ intel_dp_init_connector(struct intel_digital_port *intel_dig_port,
|
|||
intel_connector->get_hw_state = intel_connector_get_hw_state;
|
||||
|
||||
/* init MST on ports that can support it */
|
||||
if (HAS_DP_MST(dev_priv) && !intel_dp_is_edp(intel_dp) &&
|
||||
(port == PORT_B || port == PORT_C ||
|
||||
port == PORT_D || port == PORT_F))
|
||||
intel_dp_mst_encoder_init(intel_dig_port,
|
||||
intel_connector->base.base.id);
|
||||
intel_dp_mst_encoder_init(intel_dig_port,
|
||||
intel_connector->base.base.id);
|
||||
|
||||
if (!intel_edp_init_connector(intel_dp, intel_connector)) {
|
||||
intel_dp_aux_fini(intel_dp);
|
||||
|
|
|
|||
|
|
@ -588,21 +588,31 @@ intel_dp_create_fake_mst_encoders(struct intel_digital_port *intel_dig_port)
|
|||
int
|
||||
intel_dp_mst_encoder_init(struct intel_digital_port *intel_dig_port, int conn_base_id)
|
||||
{
|
||||
struct drm_i915_private *i915 = to_i915(intel_dig_port->base.base.dev);
|
||||
struct intel_dp *intel_dp = &intel_dig_port->dp;
|
||||
struct drm_device *dev = intel_dig_port->base.base.dev;
|
||||
enum port port = intel_dig_port->base.port;
|
||||
int ret;
|
||||
|
||||
intel_dp->can_mst = true;
|
||||
if (!HAS_DP_MST(i915) || intel_dp_is_edp(intel_dp))
|
||||
return 0;
|
||||
|
||||
if (INTEL_GEN(i915) < 12 && port == PORT_A)
|
||||
return 0;
|
||||
|
||||
if (INTEL_GEN(i915) < 11 && port == PORT_E)
|
||||
return 0;
|
||||
|
||||
intel_dp->mst_mgr.cbs = &mst_cbs;
|
||||
|
||||
/* create encoders */
|
||||
intel_dp_create_fake_mst_encoders(intel_dig_port);
|
||||
ret = drm_dp_mst_topology_mgr_init(&intel_dp->mst_mgr, dev,
|
||||
ret = drm_dp_mst_topology_mgr_init(&intel_dp->mst_mgr, &i915->drm,
|
||||
&intel_dp->aux, 16, 3, conn_base_id);
|
||||
if (ret) {
|
||||
intel_dp->can_mst = false;
|
||||
if (ret)
|
||||
return ret;
|
||||
}
|
||||
|
||||
intel_dp->can_mst = true;
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -869,6 +869,23 @@ static u8 *sony_report_fixup(struct hid_device *hdev, u8 *rdesc,
|
|||
if (sc->quirks & PS3REMOTE)
|
||||
return ps3remote_fixup(hdev, rdesc, rsize);
|
||||
|
||||
/*
|
||||
* Some knock-off USB dongles incorrectly report their button count
|
||||
* as 13 instead of 16 causing three non-functional buttons.
|
||||
*/
|
||||
if ((sc->quirks & SIXAXIS_CONTROLLER_USB) && *rsize >= 45 &&
|
||||
/* Report Count (13) */
|
||||
rdesc[23] == 0x95 && rdesc[24] == 0x0D &&
|
||||
/* Usage Maximum (13) */
|
||||
rdesc[37] == 0x29 && rdesc[38] == 0x0D &&
|
||||
/* Report Count (3) */
|
||||
rdesc[43] == 0x95 && rdesc[44] == 0x03) {
|
||||
hid_info(hdev, "Fixing up USB dongle report descriptor\n");
|
||||
rdesc[24] = 0x10;
|
||||
rdesc[38] = 0x10;
|
||||
rdesc[44] = 0x00;
|
||||
}
|
||||
|
||||
return rdesc;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -381,6 +381,14 @@ static const struct dmi_system_id i2c_hid_dmi_desc_override_table[] = {
|
|||
},
|
||||
.driver_data = (void *)&sipodev_desc
|
||||
},
|
||||
{
|
||||
.ident = "Schneider SCL142ALM",
|
||||
.matches = {
|
||||
DMI_EXACT_MATCH(DMI_SYS_VENDOR, "SCHNEIDER"),
|
||||
DMI_EXACT_MATCH(DMI_PRODUCT_NAME, "SCL142ALM"),
|
||||
},
|
||||
.driver_data = (void *)&sipodev_desc
|
||||
},
|
||||
{ } /* Terminate list */
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -81,6 +81,7 @@
|
|||
* @isr_mask: cached copy of local ISR enables.
|
||||
* @isr_status: cached copy of local ISR status.
|
||||
* @lock: spinlock for IRQ synchronization.
|
||||
* @isr_mutex: mutex for IRQ thread.
|
||||
*/
|
||||
struct altr_i2c_dev {
|
||||
void __iomem *base;
|
||||
|
|
@ -97,6 +98,7 @@ struct altr_i2c_dev {
|
|||
u32 isr_mask;
|
||||
u32 isr_status;
|
||||
spinlock_t lock; /* IRQ synchronization */
|
||||
struct mutex isr_mutex;
|
||||
};
|
||||
|
||||
static void
|
||||
|
|
@ -256,10 +258,11 @@ static irqreturn_t altr_i2c_isr(int irq, void *_dev)
|
|||
struct altr_i2c_dev *idev = _dev;
|
||||
u32 status = idev->isr_status;
|
||||
|
||||
mutex_lock(&idev->isr_mutex);
|
||||
if (!idev->msg) {
|
||||
dev_warn(idev->dev, "unexpected interrupt\n");
|
||||
altr_i2c_int_clear(idev, ALTR_I2C_ALL_IRQ);
|
||||
return IRQ_HANDLED;
|
||||
goto out;
|
||||
}
|
||||
read = (idev->msg->flags & I2C_M_RD) != 0;
|
||||
|
||||
|
|
@ -312,6 +315,8 @@ static irqreturn_t altr_i2c_isr(int irq, void *_dev)
|
|||
complete(&idev->msg_complete);
|
||||
dev_dbg(idev->dev, "Message Complete\n");
|
||||
}
|
||||
out:
|
||||
mutex_unlock(&idev->isr_mutex);
|
||||
|
||||
return IRQ_HANDLED;
|
||||
}
|
||||
|
|
@ -323,6 +328,7 @@ static int altr_i2c_xfer_msg(struct altr_i2c_dev *idev, struct i2c_msg *msg)
|
|||
u32 value;
|
||||
u8 addr = i2c_8bit_addr_from_msg(msg);
|
||||
|
||||
mutex_lock(&idev->isr_mutex);
|
||||
idev->msg = msg;
|
||||
idev->msg_len = msg->len;
|
||||
idev->buf = msg->buf;
|
||||
|
|
@ -347,6 +353,7 @@ static int altr_i2c_xfer_msg(struct altr_i2c_dev *idev, struct i2c_msg *msg)
|
|||
altr_i2c_int_enable(idev, imask, true);
|
||||
altr_i2c_fill_tx_fifo(idev);
|
||||
}
|
||||
mutex_unlock(&idev->isr_mutex);
|
||||
|
||||
time_left = wait_for_completion_timeout(&idev->msg_complete,
|
||||
ALTR_I2C_XFER_TIMEOUT);
|
||||
|
|
@ -420,6 +427,7 @@ static int altr_i2c_probe(struct platform_device *pdev)
|
|||
idev->dev = &pdev->dev;
|
||||
init_completion(&idev->msg_complete);
|
||||
spin_lock_init(&idev->lock);
|
||||
mutex_init(&idev->isr_mutex);
|
||||
|
||||
ret = device_property_read_u32(idev->dev, "fifo-size",
|
||||
&idev->fifo_size);
|
||||
|
|
|
|||
|
|
@ -860,10 +860,15 @@ mt7530_port_set_vlan_aware(struct dsa_switch *ds, int port)
|
|||
PCR_MATRIX_MASK, PCR_MATRIX(MT7530_ALL_MEMBERS));
|
||||
|
||||
/* Trapped into security mode allows packet forwarding through VLAN
|
||||
* table lookup.
|
||||
* table lookup. CPU port is set to fallback mode to let untagged
|
||||
* frames pass through.
|
||||
*/
|
||||
mt7530_rmw(priv, MT7530_PCR_P(port), PCR_PORT_VLAN_MASK,
|
||||
MT7530_PORT_SECURITY_MODE);
|
||||
if (dsa_is_cpu_port(ds, port))
|
||||
mt7530_rmw(priv, MT7530_PCR_P(port), PCR_PORT_VLAN_MASK,
|
||||
MT7530_PORT_FALLBACK_MODE);
|
||||
else
|
||||
mt7530_rmw(priv, MT7530_PCR_P(port), PCR_PORT_VLAN_MASK,
|
||||
MT7530_PORT_SECURITY_MODE);
|
||||
|
||||
/* Set the port as a user port which is to be able to recognize VID
|
||||
* from incoming packets before fetching entry within the VLAN table.
|
||||
|
|
|
|||
|
|
@ -148,6 +148,12 @@ enum mt7530_port_mode {
|
|||
/* Port Matrix Mode: Frames are forwarded by the PCR_MATRIX members. */
|
||||
MT7530_PORT_MATRIX_MODE = PORT_VLAN(0),
|
||||
|
||||
/* Fallback Mode: Forward received frames with ingress ports that do
|
||||
* not belong to the VLAN member. Frames whose VID is not listed on
|
||||
* the VLAN table are forwarded by the PCR_MATRIX members.
|
||||
*/
|
||||
MT7530_PORT_FALLBACK_MODE = PORT_VLAN(1),
|
||||
|
||||
/* Security Mode: Discard any frame due to ingress membership
|
||||
* violation or VID missed on the VLAN table.
|
||||
*/
|
||||
|
|
|
|||
|
|
@ -1181,7 +1181,7 @@ bmac_get_station_address(struct net_device *dev, unsigned char *ea)
|
|||
int i;
|
||||
unsigned short data;
|
||||
|
||||
for (i = 0; i < 6; i++)
|
||||
for (i = 0; i < 3; i++)
|
||||
{
|
||||
reset_and_select_srom(dev);
|
||||
data = read_srom(dev, i + EnetAddressOffset/2, SROMAddressBits);
|
||||
|
|
|
|||
|
|
@ -45,6 +45,7 @@
|
|||
#include <soc/fsl/qe/ucc.h>
|
||||
#include <soc/fsl/qe/ucc_fast.h>
|
||||
#include <asm/machdep.h>
|
||||
#include <net/sch_generic.h>
|
||||
|
||||
#include "ucc_geth.h"
|
||||
|
||||
|
|
@ -1551,11 +1552,8 @@ static int ugeth_disable(struct ucc_geth_private *ugeth, enum comm_dir mode)
|
|||
|
||||
static void ugeth_quiesce(struct ucc_geth_private *ugeth)
|
||||
{
|
||||
/* Prevent any further xmits, plus detach the device. */
|
||||
netif_device_detach(ugeth->ndev);
|
||||
|
||||
/* Wait for any current xmits to finish. */
|
||||
netif_tx_disable(ugeth->ndev);
|
||||
/* Prevent any further xmits */
|
||||
netif_tx_stop_all_queues(ugeth->ndev);
|
||||
|
||||
/* Disable the interrupt to avoid NAPI rescheduling. */
|
||||
disable_irq(ugeth->ug_info->uf_info.irq);
|
||||
|
|
@ -1568,7 +1566,10 @@ static void ugeth_activate(struct ucc_geth_private *ugeth)
|
|||
{
|
||||
napi_enable(&ugeth->napi);
|
||||
enable_irq(ugeth->ug_info->uf_info.irq);
|
||||
netif_device_attach(ugeth->ndev);
|
||||
|
||||
/* allow to xmit again */
|
||||
netif_tx_wake_all_queues(ugeth->ndev);
|
||||
__netdev_watchdog_up(ugeth->ndev);
|
||||
}
|
||||
|
||||
/* Called every time the controller might need to be made
|
||||
|
|
|
|||
|
|
@ -2515,20 +2515,20 @@ static int smsc911x_drv_probe(struct platform_device *pdev)
|
|||
|
||||
retval = smsc911x_init(dev);
|
||||
if (retval < 0)
|
||||
goto out_disable_resources;
|
||||
goto out_init_fail;
|
||||
|
||||
netif_carrier_off(dev);
|
||||
|
||||
retval = smsc911x_mii_init(pdev, dev);
|
||||
if (retval) {
|
||||
SMSC_WARN(pdata, probe, "Error %i initialising mii", retval);
|
||||
goto out_disable_resources;
|
||||
goto out_init_fail;
|
||||
}
|
||||
|
||||
retval = register_netdev(dev);
|
||||
if (retval) {
|
||||
SMSC_WARN(pdata, probe, "Error %i registering device", retval);
|
||||
goto out_disable_resources;
|
||||
goto out_init_fail;
|
||||
} else {
|
||||
SMSC_TRACE(pdata, probe,
|
||||
"Network interface: \"%s\"", dev->name);
|
||||
|
|
@ -2569,9 +2569,10 @@ static int smsc911x_drv_probe(struct platform_device *pdev)
|
|||
|
||||
return 0;
|
||||
|
||||
out_disable_resources:
|
||||
out_init_fail:
|
||||
pm_runtime_put(&pdev->dev);
|
||||
pm_runtime_disable(&pdev->dev);
|
||||
out_disable_resources:
|
||||
(void)smsc911x_disable_resources(pdev);
|
||||
out_enable_resources_fail:
|
||||
smsc911x_free_resources(pdev);
|
||||
|
|
|
|||
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue