Merge branch 'android11-5.4' into 'android11-5.4-lts'

Sync up with android11-5.4 for the following commits:

09b63a9447 ANDROID: GKI: add allowed list for Exynosauto SoC
83e8d7513c ANDROID: GKI: update allowed list for Exynosauto SoC
4e20d65b72 UPSTREAM: mfd: sprd: Add wakeup capability for PMIC IRQ
5eaa11cf0d UPSTREAM: tick/common: Touch watchdog in tick_unfreeze() on all CPUs
70145df882 FROMLIST: thermal: Fix NULL pointer dereference issue
7982ae0c2c ANDROID: ABI: Update allowed list for QCOM
42e0a0e97f UPSTREAM: spi: Fix regression to return zero on success instead of positive value
f49688970b UPSTREAM: thermal: power_allocator: Fix Kconfig warning
e13d39a31f UPSTREAM: of/platform: Unconditionally pause/resume sync state during kernel init
26d0b8dd3a UPSTREAM: selinux: ensure the policy has been loaded before reading the sidtab stats
b1ab580076 UPSTREAM: MIPS: vdso: Define BUILD_VDSO32 when building a 32bit kernel
3ab3de2667 UPSTREAM: mfd: syscon: Fix syscon_regmap_lookup_by_phandle_args() dummy
fecd3edb95 UPSTREAM: ARM: bcm2835_defconfig: Explicitly restore CONFIG_DEBUG_FS
a268f056b7 UPSTREAM: ARM: socfpga_defconfig: Add back DEBUG_FS
9008abe0e4 UPSTREAM: um: Fix header inclusion
df1cc4066f UPSTREAM: net: fix fraglist segmentation reference count leak
223c666145 UPSTREAM: ipv6: ndisc: RFC-ietf-6man-ra-pref64-09 is now published as RFC8781
b01c286473 UPSTREAM: of: property: Fix create device links for all child-supplier dependencies
6ac5a61989 UPSTREAM: of: property: Do not link to disabled devices
2bef330246 UPSTREAM: mmc: sdhci: Fix SDHCI_QUIRK_BROKEN_CQE
1bd9ca0eb9 UPSTREAM: usb: renesas-xhci: include correct header for get_unaligned_le16()
cd63b9b3ef UPSTREAM: wil6210: account for napi_gro_receive never returning GRO_DROP
f1ed2a97d3 UPSTREAM: nl80211: fix memory leak when parsing NL80211_ATTR_HE_BSS_COLOR
8aff1e0e2a UPSTREAM: thermal/drivers/sprd: Fix return value of sprd_thm_probe()
23b53e4b2a UPSTREAM: fscrypt: restrict IV_INO_LBLK_* to AES-256-XTS
5eb84aafc7 UPSTREAM: fscrypt: use smp_load_acquire() for fscrypt_prepared_key
3fcaa86a3d UPSTREAM: nvmem: sprd: Fix return value of sprd_efuse_probe()
05f0c99de8 UPSTREAM: mac80211: fix warning in 6 GHz IE addition in mesh mode
67d571fe31 UPSTREAM: scsi: ufs: Fix interrupt error message for shared interrupts
91c21bea59 UPSTREAM: sched/fair: Fix wrong negative conversion in find_energy_efficient_cpu()
5eee799bec UPSTREAM: driver core: Fix device_pm_lock() locking for device links
8502859d46 UPSTREAM: fscrypt: restrict IV_INO_LBLK_32 to ino_bits <= 32
4a5e996245 UPSTREAM: scsi: ufs: ufs-mediatek: Eliminate error message for unbound mphy
c8f9209864 UPSTREAM: scsi: ufs: ufs-mediatek: Fix HOST_PA_TACTIVATE quirk
174953dd82 UPSTREAM: cfg80211: fix 6 GHz channel conversion

Change-Id: I94eb6c54684cfba1899e7d81caa5986d83212120
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
This commit is contained in:
Greg Kroah-Hartman 2020-11-18 09:08:50 +01:00
commit d0bd13a1b2
35 changed files with 950 additions and 684 deletions

File diff suppressed because it is too large Load diff

View file

@ -29,6 +29,7 @@
clk_bulk_unprepare
clk_disable
clk_enable
clk_get
clk_get_rate
clk_prepare
clk_put
@ -37,12 +38,14 @@
complete
complete_all
__const_udelay
cpu_bit_bitmap
cpu_hwcap_keys
cpu_hwcaps
cpumask_next
cpu_number
__cpu_online_mask
__cpu_possible_mask
crc32_le
delayed_work_timer_fn
del_timer
del_timer_sync
@ -50,7 +53,9 @@
dev_driver_string
_dev_emerg
_dev_err
device_create
device_create_file
device_destroy
device_for_each_child
device_initialize
device_init_wakeup
@ -64,6 +69,7 @@
devm_gpiod_get_optional
devm_gpio_request_one
devm_ioremap
devm_ioremap_nocache
devm_ioremap_resource
devm_kfree
devm_kmalloc
@ -116,7 +122,9 @@
dma_request_slave_channel
dma_set_coherent_mask
dma_set_mask
down
down_read
down_trylock
drm_add_edid_modes
drm_atomic_helper_connector_destroy_state
drm_atomic_helper_connector_duplicate_state
@ -156,6 +164,7 @@
generic_handle_irq
get_device
__get_free_pages
get_random_bytes
get_task_mm
get_unused_fd_flags
get_user_pages
@ -167,12 +176,14 @@
gpiod_to_irq
gpio_free
gpio_request
gpio_request_one
gpio_to_desc
handle_edge_irq
handle_level_irq
handle_nested_irq
i2c_add_numbered_adapter
i2c_del_driver
i2c_get_adapter
i2c_new_dummy
i2c_register_driver
i2c_transfer
@ -209,17 +220,23 @@
__kmalloc
kmalloc_caches
kmalloc_order_trace
kmem_cache_alloc
kmem_cache_alloc_trace
kmem_cache_free
kmemdup
kobject_create_and_add
krealloc
kstrdup
kstrtobool
kstrtoint
kstrtou8
kstrtouint
kstrtoull
kthread_create_on_node
__kthread_init_worker
kthread_queue_work
kthread_stop
kthread_worker_fn
ktime_get
ktime_get_mono_fast_ns
ktime_get_raw_ts64
@ -229,6 +246,7 @@
mdiobus_read
mdiobus_write
memcpy
memdup_user
memset
mfd_add_devices
mfd_remove_devices
@ -247,9 +265,12 @@
__msecs_to_jiffies
msleep
__mutex_init
mutex_is_locked
mutex_lock
mutex_unlock
names_cachep
netif_carrier_off
no_llseek
nr_cpu_ids
__num_online_cpus
of_address_to_resource
@ -360,6 +381,7 @@
refcount_inc_not_zero_checked
__refrigerator
register_pm_notifier
register_reboot_notifier
register_restart_handler
register_syscore_ops
regmap_read
@ -367,8 +389,10 @@
regmap_write
regulator_disable
regulator_enable
regulator_get_optional
regulator_list_voltage_linear
regulator_map_voltage_linear
regulator_put
regulator_register
regulator_unregister
release_firmware
@ -382,6 +406,7 @@
schedule_timeout
scnprintf
seq_printf
set_cpus_allowed_ptr
set_page_dirty_lock
sg_alloc_table
sg_alloc_table_from_pages
@ -417,6 +442,9 @@
sysfs_remove_group
system_freezing_cnt
system_wq
tasklet_init
tasklet_kill
__tasklet_schedule
_totalram_pages
trace_define_field
trace_event_buffer_commit
@ -431,6 +459,7 @@
__udelay
unregister_chrdev_region
unregister_pm_notifier
up
up_read
usb_add_hcd
usb_disabled
@ -445,11 +474,15 @@
v4l2_fh_del
v4l2_fh_exit
v4l2_fh_init
v4l2_subdev_init
vabits_actual
vb2_buffer_done
vb2_dqbuf
vb2_mmap
vb2_plane_cookie
vb2_plane_vaddr
vb2_poll
vb2_prepare_buf
vb2_qbuf
vb2_querybuf
vb2_queue_init
@ -786,6 +819,7 @@
drm_mode_object_put
drm_object_attach_property
drm_of_component_match_add
drm_of_crtc_port_mask
drm_of_find_possible_crtcs
drm_open
drm_panel_attach
@ -807,10 +841,8 @@
drm_release
drm_universal_plane_init
drm_vblank_init
kstrtou8
mipi_dsi_host_register
mipi_dsi_host_unregister
mutex_is_locked
of_drm_find_bridge
of_drm_find_panel
of_get_next_available_child
@ -838,20 +870,16 @@
dev_pm_opp_disable
dev_pm_opp_get_freq
dev_pm_opp_put
register_reboot_notifier
unregister_reboot_notifier
update_devfreq
# required by exynos_mfc.ko
clk_get
iommu_dma_reserve_iova
iommu_get_domain_for_dev
iommu_map_sg
iommu_unmap
mutex_lock_interruptible
ns_to_timeval
vb2_plane_vaddr
vb2_poll
# required by exynos_pm_qos.ko
kstrtoint_from_user
@ -891,7 +919,6 @@
# required by exynosauto9-itmon.ko
atomic_notifier_chain_unregister
devm_ioremap_nocache
# required by g2d.ko
__arch_copy_in_user
@ -911,17 +938,13 @@
i2c_adapter_type
i2c_bus_type
i2c_for_each_dev
i2c_get_adapter
i2c_put_adapter
i2c_smbus_xfer
i2c_transfer_buffer_flags
i2c_verify_client
memdup_user
no_llseek
register_chrdev_region
# required by i2c-exynosauto.ko
cpu_bit_bitmap
i2c_del_adapter
# required by ion_exynos_mod.ko
@ -954,6 +977,7 @@
# required by mali_kbase.ko
anon_inode_getfd
__arch_clear_user
__bitmap_weight
bpf_trace_run5
cache_line_size
@ -965,9 +989,7 @@
dev_pm_opp_put_regulators
dev_pm_opp_set_regulators
dma_fence_get_status
down
downgrade_write
down_trylock
down_write
dump_stack
__get_task_comm
@ -978,6 +1000,7 @@
hrtimer_forward
hrtimer_init
hrtimer_start_range_ns
kfree_call_rcu
kobject_put
ktime_get_raw
__mmdrop
@ -991,10 +1014,10 @@
rb_prev
rb_replace_node
register_shrinker
regulator_get_optional
regulator_put
remap_pfn_range
remap_vmalloc_range
static_key_slow_dec
static_key_slow_inc
strcspn
strncasecmp
synchronize_rcu
@ -1002,12 +1025,12 @@
sysfs_streq
system_highpri_wq
trace_output_call
__tracepoint_gpu_mem_total
trace_print_array_seq
trace_print_flags_seq
try_module_get
unmap_mapping_range
unregister_shrinker
up
up_write
vmalloc_user
vmf_insert_pfn_prot
@ -1044,16 +1067,10 @@
crypto_destroy_tfm
crypto_shash_final
crypto_shash_update
device_create
device_destroy
d_path
get_task_exe_file
get_zeroed_page
__kthread_init_worker
kthread_queue_work
kthread_worker_fn
release_pages
set_cpus_allowed_ptr
sg_miter_next
sg_miter_start
sg_miter_stop
@ -1066,6 +1083,17 @@
drm_panel_remove
videomode_from_timing
# required by pcie-exynos-dw-ep.ko
dw_pcie_ep_init
dw_pcie_read_dbi
dw_pcie_write_dbi
pci_epc_clear_bar
pci_epc_map_addr
pci_epc_mem_alloc_addr
pci_epc_mem_free_addr
pci_epc_set_bar
pci_epc_unmap_addr
# required by pcie-exynos-dw-rc.ko
bitmap_find_free_region
bitmap_release_region
@ -1150,9 +1178,6 @@
of_dma_controller_free
of_dma_controller_register
pm_runtime_irq_safe
tasklet_init
tasklet_kill
__tasklet_schedule
# required by rtc-s2vps01.ko
devm_rtc_device_register
@ -1171,6 +1196,38 @@
watchdog_set_restart_priority
watchdog_unregister_device
# required by sam-is-cis-4ec.ko
v4l2_i2c_subdev_init
# required by sam-is.ko
down_interruptible
filp_close
filp_open
get_random_u32
get_task_pid
i2c_new_device
jiffies_to_msecs
kstrtou16
kthread_flush_work
kthread_flush_worker
ktime_get_ts64
ktime_get_with_offset
mutex_trylock
ns_to_timespec
param_ops_string
phy_configure
pm_relax
pm_stay_awake
regulator_get_voltage
regulator_is_enabled
regulator_set_voltage
sched_setscheduler_nocheck
v4l2_device_register_subdev
v4l2_device_set_name
v4l2_device_unregister_subdev
v4l2_subdev_call_wrappers
vscnprintf
# required by samsung-iommu-group.ko
iommu_group_alloc
iommu_group_set_name
@ -1179,7 +1236,6 @@
alloc_etherdev_mqs
capable
consume_skb
crc32_le
dev_close
device_set_wakeup_capable
device_set_wakeup_enable
@ -1192,7 +1248,6 @@
ethtool_op_get_ts_info
eth_type_trans
free_netdev
get_random_bytes
in4_pton
in6_pton
jiffies_to_usecs
@ -1274,10 +1329,8 @@
iommu_group_set_iommudata
iommu_put_dma_cookie
iommu_report_device_fault
kmem_cache_alloc
kmem_cache_create
kmem_cache_destroy
kmem_cache_free
of_get_dma_window
pm_runtime_get_if_in_use
@ -1292,11 +1345,7 @@
v4l2_ctrl_new_std
v4l_bound_align_image
# required by sfi_ipc_test.ko
nsecs_to_jiffies
# required by spi-exynosauto.ko
gpio_request_one
loops_per_jiffy
__spi_alloc_controller
spi_controller_resume
@ -1305,6 +1354,16 @@
spi_register_controller
spi_unregister_controller
# required by spidev.ko
driver_unregister
find_next_zero_bit
__register_chrdev
__spi_register_driver
spi_setup
spi_sync
stream_open
__unregister_chrdev
# required by ufs-exynos-core.ko
ufshcd_config_pwr_mode
ufshcd_dme_get_attr
@ -1328,7 +1387,6 @@
v4l2_event_pending
vb2_create_bufs
vb2_expbuf
vb2_prepare_buf
vb2_request_object_is_buffer
# required by videobuf2-dma-sg.ko

View file

@ -1883,6 +1883,8 @@
register_shrinker
register_syscore_ops
register_sysctl_table
register_virtio_device
register_virtio_driver
regmap_bulk_read
regmap_bulk_write
regmap_field_read
@ -2486,6 +2488,8 @@
unregister_shrinker
unregister_syscore_ops
unregister_sysctl_table
unregister_virtio_device
unregister_virtio_driver
up
update_devfreq
up_read
@ -2742,6 +2746,29 @@
video_ioctl2
__video_register_device
video_unregister_device
virtio_check_driver_offered_feature
virtio_config_changed
virtio_max_dma_size
virtqueue_add_inbuf
virtqueue_add_inbuf_ctx
virtqueue_add_outbuf
virtqueue_add_sgs
virtqueue_detach_unused_buf
virtqueue_disable_cb
virtqueue_enable_cb
virtqueue_enable_cb_delayed
virtqueue_enable_cb_prepare
virtqueue_get_avail_addr
virtqueue_get_buf
virtqueue_get_buf_ctx
virtqueue_get_desc_addr
virtqueue_get_used_addr
virtqueue_get_vring_size
virtqueue_is_broken
virtqueue_kick
virtqueue_kick_prepare
virtqueue_notify
virtqueue_poll
vmalloc
vmalloc_to_page
vmalloc_user
@ -2755,6 +2782,10 @@
vm_map_ram
vm_unmap_ram
vprintk
vring_create_virtqueue
vring_del_virtqueue
vring_interrupt
vring_transport_features
vscnprintf
vsnprintf
vunmap

View file

@ -178,6 +178,7 @@ CONFIG_SCHED_TRACER=y
CONFIG_STACK_TRACER=y
CONFIG_FUNCTION_PROFILER=y
CONFIG_TEST_KSTRTOX=y
CONFIG_DEBUG_FS=y
CONFIG_KGDB=y
CONFIG_KGDB_KDB=y
CONFIG_STRICT_DEVMEM=y

View file

@ -157,6 +157,7 @@ CONFIG_NLS_ISO8859_1=y
CONFIG_PRINTK_TIME=y
CONFIG_DEBUG_INFO=y
CONFIG_MAGIC_SYSRQ=y
CONFIG_DEBUG_FS=y
CONFIG_DETECT_HUNG_TASK=y
# CONFIG_SCHED_DEBUG is not set
CONFIG_FUNCTION_TRACER=y

View file

@ -18,6 +18,10 @@ ccflags-vdso := \
$(filter -mno-loongson-%,$(KBUILD_CFLAGS)) \
-D__VDSO__
ifndef CONFIG_64BIT
ccflags-vdso += -DBUILD_VDSO32
endif
ifdef CONFIG_CC_IS_CLANG
ccflags-vdso += $(filter --target=%,$(KBUILD_CFLAGS))
endif

View file

@ -2,6 +2,11 @@
#ifndef _ASM_X86_VGTOD_H
#define _ASM_X86_VGTOD_H
/*
* This check is required to prevent ARCH=um to include
* unwanted headers.
*/
#ifdef CONFIG_GENERIC_GETTIMEOFDAY
#include <linux/compiler.h>
#include <asm/clocksource.h>
#include <vdso/datapage.h>
@ -14,6 +19,7 @@ typedef u64 gtod_long_t;
#else
typedef unsigned long gtod_long_t;
#endif
#endif /* CONFIG_GENERIC_GETTIMEOFDAY */
extern int vclocks_used;
static inline bool vclock_was_used(int vclock)

View file

@ -804,9 +804,7 @@ static void device_link_put_kref(struct device_link *link)
void device_link_del(struct device_link *link)
{
device_links_write_lock();
device_pm_lock();
device_link_put_kref(link);
device_pm_unlock();
device_links_write_unlock();
}
EXPORT_SYMBOL_GPL(device_link_del);
@ -827,7 +825,6 @@ void device_link_remove(void *consumer, struct device *supplier)
return;
device_links_write_lock();
device_pm_lock();
list_for_each_entry(link, &supplier->links.consumers, s_node) {
if (link->consumer == consumer) {
@ -836,7 +833,6 @@ void device_link_remove(void *consumer, struct device *supplier)
}
}
device_pm_unlock();
device_links_write_unlock();
}
EXPORT_SYMBOL_GPL(device_link_remove);

View file

@ -256,7 +256,7 @@ static int sprd_pmic_probe(struct spi_device *spi)
}
ret = devm_regmap_add_irq_chip(&spi->dev, ddata->regmap, ddata->irq,
IRQF_ONESHOT | IRQF_NO_SUSPEND, 0,
IRQF_ONESHOT, 0,
&ddata->irq_chip, &ddata->irq_data);
if (ret) {
dev_err(&spi->dev, "Failed to add PMIC irq chip %d\n", ret);
@ -272,9 +272,34 @@ static int sprd_pmic_probe(struct spi_device *spi)
return ret;
}
device_init_wakeup(&spi->dev, true);
return 0;
}
#ifdef CONFIG_PM_SLEEP
static int sprd_pmic_suspend(struct device *dev)
{
struct sprd_pmic *ddata = dev_get_drvdata(dev);
if (device_may_wakeup(dev))
enable_irq_wake(ddata->irq);
return 0;
}
static int sprd_pmic_resume(struct device *dev)
{
struct sprd_pmic *ddata = dev_get_drvdata(dev);
if (device_may_wakeup(dev))
disable_irq_wake(ddata->irq);
return 0;
}
#endif
static SIMPLE_DEV_PM_OPS(sprd_pmic_pm_ops, sprd_pmic_suspend, sprd_pmic_resume);
static const struct of_device_id sprd_pmic_match[] = {
{ .compatible = "sprd,sc2731", .data = &sc2731_data },
{},
@ -286,6 +311,7 @@ static struct spi_driver sprd_pmic_driver = {
.name = "sc27xx-pmic",
.bus = &spi_bus_type,
.of_match_table = sprd_pmic_match,
.pm = &sprd_pmic_pm_ops,
},
.probe = sprd_pmic_probe,
};

View file

@ -3898,9 +3898,6 @@ int sdhci_setup_host(struct sdhci_host *host)
mmc_hostname(mmc), host->version);
}
if (host->quirks & SDHCI_QUIRK_BROKEN_CQE)
mmc->caps2 &= ~MMC_CAP2_CQE;
if (host->quirks & SDHCI_QUIRK_FORCE_DMA)
host->flags |= SDHCI_USE_SDMA;
else if (!(host->caps & SDHCI_CAN_DO_SDMA))
@ -4420,6 +4417,12 @@ int __sdhci_add_host(struct sdhci_host *host)
struct mmc_host *mmc = host->mmc;
int ret;
if ((mmc->caps2 & MMC_CAP2_CQE) &&
(host->quirks & SDHCI_QUIRK_BROKEN_CQE)) {
mmc->caps2 &= ~MMC_CAP2_CQE;
mmc->cqe_ops = NULL;
}
host->complete_wq = alloc_workqueue("sdhci", flags, 0);
if (!host->complete_wq)
return -ENOMEM;

View file

@ -907,7 +907,6 @@ static void wil_rx_handle_eapol(struct wil6210_vif *vif, struct sk_buff *skb)
void wil_netif_rx(struct sk_buff *skb, struct net_device *ndev, int cid,
struct wil_net_stats *stats, bool gro)
{
gro_result_t rc = GRO_NORMAL;
struct wil6210_vif *vif = ndev_to_vif(ndev);
struct wil6210_priv *wil = ndev_to_wil(ndev);
struct wireless_dev *wdev = vif_to_wdev(vif);
@ -918,22 +917,16 @@ void wil_netif_rx(struct sk_buff *skb, struct net_device *ndev, int cid,
*/
int mcast = is_multicast_ether_addr(da);
struct sk_buff *xmit_skb = NULL;
static const char * const gro_res_str[] = {
[GRO_MERGED] = "GRO_MERGED",
[GRO_MERGED_FREE] = "GRO_MERGED_FREE",
[GRO_HELD] = "GRO_HELD",
[GRO_NORMAL] = "GRO_NORMAL",
[GRO_DROP] = "GRO_DROP",
[GRO_CONSUMED] = "GRO_CONSUMED",
};
if (wdev->iftype == NL80211_IFTYPE_STATION) {
sa = wil_skb_get_sa(skb);
if (mcast && ether_addr_equal(sa, ndev->dev_addr)) {
/* mcast packet looped back to us */
rc = GRO_DROP;
dev_kfree_skb(skb);
goto stats;
ndev->stats.rx_dropped++;
stats->rx_dropped++;
wil_dbg_txrx(wil, "Rx drop %d bytes\n", len);
return;
}
} else if (wdev->iftype == NL80211_IFTYPE_AP && !vif->ap_isolate) {
if (mcast) {
@ -977,26 +970,16 @@ void wil_netif_rx(struct sk_buff *skb, struct net_device *ndev, int cid,
wil_rx_handle_eapol(vif, skb);
if (gro)
rc = napi_gro_receive(&wil->napi_rx, skb);
napi_gro_receive(&wil->napi_rx, skb);
else
netif_rx_ni(skb);
wil_dbg_txrx(wil, "Rx complete %d bytes => %s\n",
len, gro_res_str[rc]);
}
stats:
/* statistics. rc set to GRO_NORMAL for AP bridging */
if (unlikely(rc == GRO_DROP)) {
ndev->stats.rx_dropped++;
stats->rx_dropped++;
wil_dbg_txrx(wil, "Rx drop %d bytes\n", len);
} else {
ndev->stats.rx_packets++;
stats->rx_packets++;
ndev->stats.rx_bytes += len;
stats->rx_bytes += len;
if (mcast)
ndev->stats.multicast++;
}
ndev->stats.rx_packets++;
stats->rx_packets++;
ndev->stats.rx_bytes += len;
stats->rx_bytes += len;
if (mcast)
ndev->stats.multicast++;
}
void wil_netif_rx_any(struct sk_buff *skb, struct net_device *ndev)

View file

@ -378,8 +378,8 @@ static int sprd_efuse_probe(struct platform_device *pdev)
return -ENOMEM;
efuse->base = devm_platform_ioremap_resource(pdev, 0);
if (!efuse->base)
return -ENOMEM;
if (IS_ERR(efuse->base))
return PTR_ERR(efuse->base);
ret = of_hwspin_lock_get_id(np, 0);
if (ret < 0) {

View file

@ -518,10 +518,11 @@ static int __init of_platform_default_populate_init(void)
{
struct device_node *node;
device_links_supplier_sync_state_pause();
if (!of_have_populated_dt())
return -ENODEV;
device_links_supplier_sync_state_pause();
/*
* Handle certain compatibles explicitly, since we don't want to create
* platform_devices for every node in /reserved-memory with a
@ -547,8 +548,7 @@ arch_initcall_sync(of_platform_default_populate_init);
static int __init of_platform_sync_state_init(void)
{
if (of_have_populated_dt())
device_links_supplier_sync_state_resume();
device_links_supplier_sync_state_resume();
return 0;
}
late_initcall_sync(of_platform_sync_state_init);

View file

@ -1031,8 +1031,20 @@ static int of_link_to_phandle(struct device *dev, struct device_node *sup_np,
* Find the device node that contains the supplier phandle. It may be
* @sup_np or it may be an ancestor of @sup_np.
*/
while (sup_np && !of_find_property(sup_np, "compatible", NULL))
while (sup_np) {
/* Don't allow linking to a disabled supplier */
if (!of_device_is_available(sup_np)) {
of_node_put(sup_np);
sup_np = NULL;
}
if (of_find_property(sup_np, "compatible", NULL))
break;
sup_np = of_get_next_parent(sup_np);
}
if (!sup_np) {
dev_dbg(dev, "Not linking to %pOFP - No device\n", tmp_np);
return -ENODEV;
@ -1311,7 +1323,7 @@ static int of_link_to_suppliers(struct device *dev,
if (of_link_property(dev, con_np, p->name))
ret = -ENODEV;
for_each_child_of_node(con_np, child)
for_each_available_child_of_node(con_np, child)
if (of_link_to_suppliers(dev, child) && !ret)
ret = -EAGAIN;

View file

@ -129,7 +129,10 @@ static int ufs_mtk_bind_mphy(struct ufs_hba *hba)
__func__, err);
} else if (IS_ERR(host->mphy)) {
err = PTR_ERR(host->mphy);
dev_info(dev, "%s: PHY get failed %d\n", __func__, err);
if (err != -ENODEV) {
dev_info(dev, "%s: PHY get failed %d\n", __func__,
err);
}
}
if (err)
@ -669,13 +672,7 @@ static int ufs_mtk_apply_dev_quirks(struct ufs_hba *hba)
static void ufs_mtk_fixup_dev_quirks(struct ufs_hba *hba)
{
struct ufs_dev_info *dev_info = &hba->dev_info;
u16 mid = dev_info->wmanufacturerid;
ufshcd_fixup_dev_quirks(hba, ufs_mtk_dev_fixups);
if (mid == UFS_VENDOR_SAMSUNG)
hba->dev_quirks &= ~UFS_DEVICE_QUIRK_HOST_PA_TACTIVATE;
}
/**

View file

@ -6258,7 +6258,7 @@ static irqreturn_t ufshcd_intr(int irq, void *__hba)
intr_status = ufshcd_readl(hba, REG_INTERRUPT_STATUS);
}
if (retval == IRQ_NONE) {
if (enabled_intr_status && retval == IRQ_NONE) {
dev_err(hba->dev, "%s: Unhandled interrupt 0x%08x\n",
__func__, intr_status);
ufshcd_dump_regs(hba, 0, UFSHCI_REG_SPACE_SIZE, "host_regs: ");

View file

@ -3124,6 +3124,15 @@ int spi_setup(struct spi_device *spi)
status);
return status;
}
/*
* We do not want to return positive value from pm_runtime_get,
* there are many instances of devices calling spi_setup() and
* checking for a non-zero return value instead of a negative
* return value.
*/
status = 0;
spi_set_cs(spi, false);
pm_runtime_mark_last_busy(spi->controller->dev.parent);
pm_runtime_put_autosuspend(spi->controller->dev.parent);

View file

@ -108,7 +108,7 @@ config THERMAL_DEFAULT_GOV_USER_SPACE
config THERMAL_DEFAULT_GOV_POWER_ALLOCATOR
bool "power_allocator"
select THERMAL_GOV_POWER_ALLOCATOR
depends on THERMAL_GOV_POWER_ALLOCATOR
help
Select this if you want to control temperature based on
system and device power allocation. This governor can only

View file

@ -348,8 +348,8 @@ static int sprd_thm_probe(struct platform_device *pdev)
thm->var_data = pdata;
thm->base = devm_platform_ioremap_resource(pdev, 0);
if (!thm->base)
return -ENOMEM;
if (IS_ERR(thm->base))
return PTR_ERR(thm->base);
thm->nr_sensors = of_get_child_count(np);
if (thm->nr_sensors == 0 || thm->nr_sensors > SPRD_THM_MAX_SENSOR) {

View file

@ -770,6 +770,9 @@ void thermal_cooling_device_stats_update(struct thermal_cooling_device *cdev,
{
struct cooling_dev_stats *stats = cdev->stats;
if (!stats)
return;
spin_lock(&stats->lock);
if (stats->state == new_state)

View file

@ -7,7 +7,7 @@
#include <linux/module.h>
#include <linux/pci.h>
#include <linux/slab.h>
#include <linux/unaligned/access_ok.h>
#include <asm/unaligned.h>
#include "xhci.h"
#include "xhci-trace.h"

View file

@ -363,13 +363,16 @@ fscrypt_is_key_prepared(struct fscrypt_prepared_key *prep_key,
const struct fscrypt_info *ci)
{
/*
* The READ_ONCE() here pairs with the smp_store_release() in
* fscrypt_prepare_key(). (This only matters for the per-mode keys,
* which are shared by multiple inodes.)
* The two smp_load_acquire()'s here pair with the smp_store_release()'s
* in fscrypt_prepare_inline_crypt_key() and fscrypt_prepare_key().
* I.e., in some cases (namely, if this prep_key is a per-mode
* encryption key) another task can publish blk_key or tfm concurrently,
* executing a RELEASE barrier. We need to use smp_load_acquire() here
* to safely ACQUIRE the memory the other task published.
*/
if (fscrypt_using_inline_encryption(ci))
return READ_ONCE(prep_key->blk_key) != NULL;
return READ_ONCE(prep_key->tfm) != NULL;
return smp_load_acquire(&prep_key->blk_key) != NULL;
return smp_load_acquire(&prep_key->tfm) != NULL;
}
#else /* CONFIG_FS_ENCRYPTION_INLINE_CRYPT */
@ -416,7 +419,7 @@ static inline bool
fscrypt_is_key_prepared(struct fscrypt_prepared_key *prep_key,
const struct fscrypt_info *ci)
{
return READ_ONCE(prep_key->tfm) != NULL;
return smp_load_acquire(&prep_key->tfm) != NULL;
}
#endif /* !CONFIG_FS_ENCRYPTION_INLINE_CRYPT */

View file

@ -202,8 +202,10 @@ int fscrypt_prepare_inline_crypt_key(struct fscrypt_prepared_key *prep_key,
}
}
/*
* Pairs with READ_ONCE() in fscrypt_is_key_prepared(). (Only matters
* for the per-mode keys, which are shared by multiple inodes.)
* Pairs with the smp_load_acquire() in fscrypt_is_key_prepared().
* I.e., here we publish ->blk_key with a RELEASE barrier so that
* concurrent tasks can ACQUIRE it. Note that this concurrency is only
* possible for per-mode keys, not for per-file keys.
*/
smp_store_release(&prep_key->blk_key, blk_key);
return 0;

View file

@ -134,8 +134,10 @@ int fscrypt_prepare_key(struct fscrypt_prepared_key *prep_key,
if (IS_ERR(tfm))
return PTR_ERR(tfm);
/*
* Pairs with READ_ONCE() in fscrypt_is_key_prepared(). (Only matters
* for the per-mode keys, which are shared by multiple inodes.)
* Pairs with the smp_load_acquire() in fscrypt_is_key_prepared().
* I.e., here we publish ->tfm with a RELEASE barrier so that
* concurrent tasks can ACQUIRE it. Note that this concurrency is only
* possible for per-mode keys, not for per-file keys.
*/
smp_store_release(&prep_key->tfm, tfm);
return 0;

View file

@ -77,6 +77,20 @@ static bool supported_iv_ino_lblk_policy(const struct fscrypt_policy_v2 *policy,
struct super_block *sb = inode->i_sb;
int ino_bits = 64, lblk_bits = 64;
/*
* IV_INO_LBLK_* exist only because of hardware limitations, and
* currently the only known use case for them involves AES-256-XTS.
* That's also all we test currently. For these reasons, for now only
* allow AES-256-XTS here. This can be relaxed later if a use case for
* IV_INO_LBLK_* with other encryption modes arises.
*/
if (policy->contents_encryption_mode != FSCRYPT_MODE_AES_256_XTS) {
fscrypt_warn(inode,
"Can't use %s policy with contents mode other than AES-256-XTS",
type);
return false;
}
/*
* It's unsafe to include inode numbers in the IVs if the filesystem can
* potentially renumber inodes, e.g. via filesystem shrinking.
@ -178,10 +192,15 @@ static bool fscrypt_supported_v2_policy(const struct fscrypt_policy_v2 *policy,
32, 32))
return false;
/*
* IV_INO_LBLK_32 hashes the inode number, so in principle it can
* support any ino_bits. However, currently the inode number is gotten
* from inode::i_ino which is 'unsigned long'. So for now the
* implementation limit is 32 bits.
*/
if ((policy->flags & FSCRYPT_POLICY_FLAG_IV_INO_LBLK_32) &&
/* This uses hashed inode numbers, so ino_bits doesn't matter. */
!supported_iv_ino_lblk_policy(policy, inode, "IV_INO_LBLK_32",
INT_MAX, 32))
32, 32))
return false;
if (memchr_inv(policy->__reserved, 0, sizeof(policy->__reserved))) {

View file

@ -51,7 +51,7 @@ static inline struct regmap *syscon_regmap_lookup_by_phandle(
return ERR_PTR(-ENOTSUPP);
}
static struct regmap *syscon_regmap_lookup_by_phandle_args(
static inline struct regmap *syscon_regmap_lookup_by_phandle_args(
struct device_node *np,
const char *property,
int arg_count,

View file

@ -41,7 +41,7 @@ enum {
ND_OPT_DNSSL = 31, /* RFC6106 */
ND_OPT_6CO = 34, /* RFC6775 */
ND_OPT_CAPTIVE_PORTAL = 37, /* RFC7710 */
ND_OPT_PREF64 = 38, /* RFC-ietf-6man-ra-pref64-09 */
ND_OPT_PREF64 = 38, /* RFC8781 */
__ND_OPT_MAX
};

View file

@ -6493,7 +6493,8 @@ static int find_energy_efficient_cpu(struct task_struct *p, int prev_cpu, int sy
util = cpu_util_next(cpu, p, cpu);
cpu_cap = capacity_of(cpu);
spare_cap = cpu_cap - util;
spare_cap = cpu_cap;
lsub_positive(&spare_cap, util);
/*
* Skip CPUs that cannot satisfy the capacity request.

View file

@ -11,6 +11,7 @@
#include <linux/err.h>
#include <linux/hrtimer.h>
#include <linux/interrupt.h>
#include <linux/nmi.h>
#include <linux/percpu.h>
#include <linux/profile.h>
#include <linux/sched.h>
@ -558,6 +559,7 @@ void tick_unfreeze(void)
trace_suspend_resume(TPS("timekeeping_freeze"),
smp_processor_id(), false);
} else {
touch_softlockup_watchdog();
tick_resume_local();
}

View file

@ -3671,6 +3671,7 @@ struct sk_buff *skb_segment_list(struct sk_buff *skb,
skb_push(nskb, -skb_network_offset(nskb) + offset);
skb_release_head_state(nskb);
__copy_skb_header(nskb, skb);
skb_headers_offset_update(nskb, skb_headroom(nskb) - skb_headroom(skb));

View file

@ -590,6 +590,19 @@ int mesh_add_he_oper_ie(struct ieee80211_sub_if_data *sdata,
int mesh_add_he_6ghz_cap_ie(struct ieee80211_sub_if_data *sdata,
struct sk_buff *skb)
{
struct ieee80211_supported_band *sband;
const struct ieee80211_sband_iftype_data *iftd;
sband = ieee80211_get_sband(sdata);
if (!sband)
return -EINVAL;
iftd = ieee80211_get_sband_iftype_data(sband,
NL80211_IFTYPE_MESH_POINT);
/* The device doesn't support HE in mesh mode or at all */
if (!iftd)
return 0;
ieee80211_ie_build_he_6ghz_cap(sdata, skb);
return 0;
}

View file

@ -2845,6 +2845,10 @@ void ieee80211_ie_build_he_6ghz_cap(struct ieee80211_sub_if_data *sdata,
if (WARN_ON(!iftd))
return;
/* Check for device HE 6 GHz capability before adding element */
if (!iftd->he_6ghz_capa.capa)
return;
cap = le16_to_cpu(iftd->he_6ghz_capa.capa);
cap &= ~IEEE80211_HE_6GHZ_CAP_SM_PS;

View file

@ -4999,7 +4999,7 @@ static int nl80211_start_ap(struct sk_buff *skb, struct genl_info *info)
info->attrs[NL80211_ATTR_HE_BSS_COLOR],
&params.he_bss_color);
if (err)
return err;
goto out;
}
nl80211_calculate_ap_params(&params);

View file

@ -95,7 +95,7 @@ u32 ieee80211_channel_to_freq_khz(int chan, enum nl80211_band band)
/* see 802.11ax D6.1 27.3.23.2 */
if (chan == 2)
return MHZ_TO_KHZ(5935);
if (chan <= 253)
if (chan <= 233)
return MHZ_TO_KHZ(5950 + chan * 5);
break;
case NL80211_BAND_60GHZ:

View file

@ -1261,6 +1261,12 @@ int security_sidtab_hash_stats(struct selinux_state *state, char *page)
{
int rc;
if (!state->initialized) {
pr_err("SELinux: %s: called before initial load_policy\n",
__func__);
return -EINVAL;
}
read_lock(&state->ss->policy_rwlock);
rc = sidtab_hash_stats(state->ss->sidtab, page);
read_unlock(&state->ss->policy_rwlock);