Merge branch 'android12-5.10' into android12-5.10-lts
Sync up with android12-5.10 for the following commits:1efc36b815
ANDROID: sched: add a helper function to change PELT half-lifebda49ad060
FROMGIT: loop: Select I/O scheduler 'none' from inside add_disk()d8b946254e
FROMGIT: blk-mq: Introduce the BLK_MQ_F_NO_SCHED_BY_DEFAULT flag8914725a58
FROMGIT: usb: typec: tcpm: Keep other events when receiving FRS and Sourcing_vbus eventsbed43a725d
FROMGIT: usb: dwc3: gadget: Avoid runtime resume if disabling pullup41b79ac98d
FROMGIT: usb: dwc3: gadget: Use list_replace_init() before traversing lists58f1839adc
FROMGIT: arm64/cpufeature: Optionally disable MTE via command-line20c3903ad7
ANDROID: ABI: update ABI XMLe9ab28e1c5
ANDROID: ABI: update generic symbol listbce9e7942a
ANDROID: PCI/PM: Use usleep_range for d3hot_delay045204b080
FROMGIT: KVM: arm64: Unregister HYP sections from kmemleak in protected mode21e59d0563
FROMGIT: arm64: Move .hyp.rodata outside of the _sdata.._edata range Change-Id: I0e1e2203a0790184c2b0ac7acda39b9c384e60f7 Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
This commit is contained in:
commit
afeb953f87
@ -393,6 +393,9 @@
|
||||
arm64.nopauth [ARM64] Unconditionally disable Pointer Authentication
|
||||
support
|
||||
|
||||
arm64.nomte [ARM64] Unconditionally disable Memory Tagging Extension
|
||||
support
|
||||
|
||||
ataflop= [HW,M68k]
|
||||
|
||||
atarimouse= [HW,MOUSE] Atari Mouse
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -643,6 +643,7 @@
|
||||
drm_mode_equal
|
||||
drm_mode_equal_no_clocks
|
||||
drm_mode_object_find
|
||||
drm_mode_object_get
|
||||
drm_mode_object_put
|
||||
drm_mode_probed_add
|
||||
drm_modeset_acquire_fini
|
||||
@ -1342,6 +1343,7 @@
|
||||
phy_init
|
||||
phy_power_off
|
||||
phy_power_on
|
||||
pid_task
|
||||
pinconf_generic_dt_free_map
|
||||
pinconf_generic_dt_node_to_map
|
||||
pinctrl_add_gpio_range
|
||||
@ -1433,6 +1435,7 @@
|
||||
put_disk
|
||||
__put_net
|
||||
__put_page
|
||||
put_pid
|
||||
put_sg_io_hdr
|
||||
__put_task_struct
|
||||
put_unused_fd
|
||||
@ -1491,6 +1494,7 @@
|
||||
register_netdev
|
||||
register_netdevice
|
||||
register_netdevice_notifier
|
||||
register_oom_notifier
|
||||
register_pernet_device
|
||||
register_pernet_subsys
|
||||
register_pm_notifier
|
||||
@ -1893,6 +1897,7 @@
|
||||
time64_to_tm
|
||||
topology_set_thermal_pressure
|
||||
_totalram_pages
|
||||
__trace_bputs
|
||||
trace_event_buffer_commit
|
||||
trace_event_buffer_reserve
|
||||
trace_event_ignore_this_pid
|
||||
@ -1907,6 +1912,7 @@
|
||||
__traceiter_android_rvh_find_energy_efficient_cpu
|
||||
__traceiter_android_rvh_irqs_disable
|
||||
__traceiter_android_rvh_irqs_enable
|
||||
__traceiter_android_rvh_pci_d3_sleep
|
||||
__traceiter_android_rvh_post_init_entity_util_avg
|
||||
__traceiter_android_rvh_preempt_disable
|
||||
__traceiter_android_rvh_preempt_enable
|
||||
@ -1981,6 +1987,7 @@
|
||||
__tracepoint_android_rvh_find_energy_efficient_cpu
|
||||
__tracepoint_android_rvh_irqs_disable
|
||||
__tracepoint_android_rvh_irqs_enable
|
||||
__tracepoint_android_rvh_pci_d3_sleep
|
||||
__tracepoint_android_rvh_post_init_entity_util_avg
|
||||
__tracepoint_android_rvh_preempt_disable
|
||||
__tracepoint_android_rvh_preempt_enable
|
||||
@ -2104,6 +2111,7 @@
|
||||
unregister_netdevice_many
|
||||
unregister_netdevice_notifier
|
||||
unregister_netdevice_queue
|
||||
unregister_oom_notifier
|
||||
unregister_pernet_device
|
||||
unregister_pernet_subsys
|
||||
unregister_pm_notifier
|
||||
|
@ -684,8 +684,7 @@
|
||||
(SCTLR_ELx_M | SCTLR_ELx_C | SCTLR_ELx_SA | SCTLR_EL1_SA0 | \
|
||||
SCTLR_EL1_SED | SCTLR_ELx_I | SCTLR_EL1_DZE | SCTLR_EL1_UCT | \
|
||||
SCTLR_EL1_NTWE | SCTLR_ELx_IESB | SCTLR_EL1_SPAN | SCTLR_ELx_ITFSB | \
|
||||
SCTLR_ELx_ATA | SCTLR_EL1_ATA0 | ENDIAN_SET_EL1 | SCTLR_EL1_UCI | \
|
||||
SCTLR_EL1_RES1)
|
||||
ENDIAN_SET_EL1 | SCTLR_EL1_UCI | SCTLR_EL1_RES1)
|
||||
|
||||
/* MAIR_ELx memory attributes (used by Linux) */
|
||||
#define MAIR_ATTR_DEVICE_nGnRnE UL(0x00)
|
||||
|
@ -1835,6 +1835,9 @@ static void bti_enable(const struct arm64_cpu_capabilities *__unused)
|
||||
#ifdef CONFIG_ARM64_MTE
|
||||
static void cpu_enable_mte(struct arm64_cpu_capabilities const *cap)
|
||||
{
|
||||
sysreg_clear_set(sctlr_el1, 0, SCTLR_ELx_ATA | SCTLR_EL1_ATA0);
|
||||
isb();
|
||||
|
||||
/*
|
||||
* Clear the tags in the zero page. This needs to be done via the
|
||||
* linear map which has the Tagged attribute.
|
||||
|
@ -42,6 +42,7 @@ static const struct ftr_set_desc pfr1 __initconst = {
|
||||
.override = &id_aa64pfr1_override,
|
||||
.fields = {
|
||||
{ "bt", ID_AA64PFR1_BT_SHIFT },
|
||||
{ "mte", ID_AA64PFR1_MTE_SHIFT},
|
||||
{}
|
||||
},
|
||||
};
|
||||
@ -88,6 +89,7 @@ static const struct {
|
||||
{ "arm64.nopauth",
|
||||
"id_aa64isar1.gpi=0 id_aa64isar1.gpa=0 "
|
||||
"id_aa64isar1.api=0 id_aa64isar1.apa=0" },
|
||||
{ "arm64.nomte", "id_aa64pfr1.mte=0" },
|
||||
{ "nokaslr", "kaslr.disabled=1" },
|
||||
};
|
||||
|
||||
|
@ -181,6 +181,8 @@ SECTIONS
|
||||
/* everything from this point to __init_begin will be marked RO NX */
|
||||
RO_DATA(PAGE_SIZE)
|
||||
|
||||
HYPERVISOR_DATA_SECTIONS
|
||||
|
||||
idmap_pg_dir = .;
|
||||
. += IDMAP_DIR_SIZE;
|
||||
idmap_pg_end = .;
|
||||
@ -260,8 +262,6 @@ SECTIONS
|
||||
_sdata = .;
|
||||
RW_DATA(L1_CACHE_BYTES, PAGE_SIZE, THREAD_ALIGN)
|
||||
|
||||
HYPERVISOR_DATA_SECTIONS
|
||||
|
||||
/*
|
||||
* Data written with the MMU off but read with the MMU on requires
|
||||
* cache lines to be invalidated, discarding up to a Cache Writeback
|
||||
|
@ -15,6 +15,7 @@
|
||||
#include <linux/fs.h>
|
||||
#include <linux/mman.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/kmemleak.h>
|
||||
#include <linux/kvm.h>
|
||||
#include <linux/kvm_irqfd.h>
|
||||
#include <linux/irqbypass.h>
|
||||
@ -1945,6 +1946,12 @@ static int finalize_hyp_mode(void)
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
/*
|
||||
* Exclude HYP BSS from kmemleak so that it doesn't get peeked
|
||||
* at, which would end badly once the section is inaccessible.
|
||||
* None of other sections should ever be introspected.
|
||||
*/
|
||||
kmemleak_free_part(__hyp_bss_start, __hyp_bss_end - __hyp_bss_start);
|
||||
ret = pkvm_mark_hyp_section(__hyp_bss);
|
||||
if (ret)
|
||||
return ret;
|
||||
|
@ -621,6 +621,9 @@ static inline bool elv_support_iosched(struct request_queue *q)
|
||||
*/
|
||||
static struct elevator_type *elevator_get_default(struct request_queue *q)
|
||||
{
|
||||
if (q->tag_set && q->tag_set->flags & BLK_MQ_F_NO_SCHED_BY_DEFAULT)
|
||||
return NULL;
|
||||
|
||||
if (q->nr_hw_queues != 1)
|
||||
return NULL;
|
||||
|
||||
|
@ -73,6 +73,7 @@
|
||||
#include <trace/hooks/sound.h>
|
||||
#include <trace/hooks/snd_compr.h>
|
||||
#include <trace/hooks/ipv4.h>
|
||||
#include <trace/hooks/pci.h>
|
||||
|
||||
/*
|
||||
* Export tracepoints that act as a bare tracehook (ie: have no trace event
|
||||
@ -378,3 +379,4 @@ EXPORT_TRACEPOINT_SYMBOL_GPL(android_rvh_tcp_recvmsg);
|
||||
EXPORT_TRACEPOINT_SYMBOL_GPL(android_rvh_udp_sendmsg);
|
||||
EXPORT_TRACEPOINT_SYMBOL_GPL(android_rvh_udp_recvmsg);
|
||||
EXPORT_TRACEPOINT_SYMBOL_GPL(android_rvh_tcp_recvmsg_stat);
|
||||
EXPORT_TRACEPOINT_SYMBOL_GPL(android_rvh_pci_d3_sleep);
|
||||
|
@ -2117,7 +2117,8 @@ static int loop_add(struct loop_device **l, int i)
|
||||
lo->tag_set.queue_depth = 128;
|
||||
lo->tag_set.numa_node = NUMA_NO_NODE;
|
||||
lo->tag_set.cmd_size = sizeof(struct loop_cmd);
|
||||
lo->tag_set.flags = BLK_MQ_F_SHOULD_MERGE | BLK_MQ_F_STACKING;
|
||||
lo->tag_set.flags = BLK_MQ_F_SHOULD_MERGE | BLK_MQ_F_STACKING |
|
||||
BLK_MQ_F_NO_SCHED_BY_DEFAULT;
|
||||
lo->tag_set.driver_data = lo;
|
||||
|
||||
err = blk_mq_alloc_tag_set(&lo->tag_set);
|
||||
|
@ -31,6 +31,9 @@
|
||||
#include <linux/vmalloc.h>
|
||||
#include <asm/dma.h>
|
||||
#include <linux/aer.h>
|
||||
#ifndef __GENKSYMS__
|
||||
#include <trace/hooks/pci.h>
|
||||
#endif
|
||||
#include "pci.h"
|
||||
|
||||
DEFINE_MUTEX(pci_slot_mutex);
|
||||
@ -64,12 +67,16 @@ struct pci_pme_device {
|
||||
static void pci_dev_d3_sleep(struct pci_dev *dev)
|
||||
{
|
||||
unsigned int delay = dev->d3hot_delay;
|
||||
int err = -EOPNOTSUPP;
|
||||
|
||||
if (delay < pci_pm_d3hot_delay)
|
||||
delay = pci_pm_d3hot_delay;
|
||||
|
||||
if (delay)
|
||||
msleep(delay);
|
||||
if (delay) {
|
||||
trace_android_rvh_pci_d3_sleep(dev, delay, &err);
|
||||
if (err == -EOPNOTSUPP)
|
||||
msleep(delay);
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef CONFIG_PCI_DOMAINS
|
||||
|
@ -1924,9 +1924,13 @@ static void dwc3_gadget_ep_cleanup_cancelled_requests(struct dwc3_ep *dep)
|
||||
{
|
||||
struct dwc3_request *req;
|
||||
struct dwc3_request *tmp;
|
||||
struct list_head local;
|
||||
struct dwc3 *dwc = dep->dwc;
|
||||
|
||||
list_for_each_entry_safe(req, tmp, &dep->cancelled_list, list) {
|
||||
restart:
|
||||
list_replace_init(&dep->cancelled_list, &local);
|
||||
|
||||
list_for_each_entry_safe(req, tmp, &local, list) {
|
||||
dwc3_gadget_ep_skip_trbs(dep, req);
|
||||
switch (req->status) {
|
||||
case DWC3_REQUEST_STATUS_DISCONNECTED:
|
||||
@ -1944,6 +1948,9 @@ static void dwc3_gadget_ep_cleanup_cancelled_requests(struct dwc3_ep *dep)
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if (!list_empty(&dep->cancelled_list))
|
||||
goto restart;
|
||||
}
|
||||
|
||||
static int dwc3_gadget_ep_dequeue(struct usb_ep *ep,
|
||||
@ -2431,6 +2438,17 @@ static int dwc3_gadget_pullup(struct usb_gadget *g, int is_on)
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
* Avoid issuing a runtime resume if the device is already in the
|
||||
* suspended state during gadget disconnect. DWC3 gadget was already
|
||||
* halted/stopped during runtime suspend.
|
||||
*/
|
||||
if (!is_on) {
|
||||
pm_runtime_barrier(dwc->dev);
|
||||
if (pm_runtime_suspended(dwc->dev))
|
||||
return 0;
|
||||
}
|
||||
|
||||
/*
|
||||
* Check the return value for successful resume, or error. For a
|
||||
* successful resume, the DWC3 runtime PM resume routine will handle
|
||||
@ -3200,8 +3218,12 @@ static void dwc3_gadget_ep_cleanup_completed_requests(struct dwc3_ep *dep,
|
||||
{
|
||||
struct dwc3_request *req;
|
||||
struct dwc3_request *tmp;
|
||||
struct list_head local;
|
||||
|
||||
list_for_each_entry_safe(req, tmp, &dep->started_list, list) {
|
||||
restart:
|
||||
list_replace_init(&dep->started_list, &local);
|
||||
|
||||
list_for_each_entry_safe(req, tmp, &local, list) {
|
||||
int ret;
|
||||
|
||||
ret = dwc3_gadget_ep_cleanup_completed_request(dep, event,
|
||||
@ -3209,6 +3231,9 @@ static void dwc3_gadget_ep_cleanup_completed_requests(struct dwc3_ep *dep,
|
||||
if (ret)
|
||||
break;
|
||||
}
|
||||
|
||||
if (!list_empty(&dep->started_list))
|
||||
goto restart;
|
||||
}
|
||||
|
||||
static bool dwc3_gadget_ep_should_continue(struct dwc3_ep *dep)
|
||||
|
@ -5489,7 +5489,7 @@ EXPORT_SYMBOL_GPL(tcpm_pd_hard_reset);
|
||||
void tcpm_sink_frs(struct tcpm_port *port)
|
||||
{
|
||||
spin_lock(&port->pd_event_lock);
|
||||
port->pd_events = TCPM_FRS_EVENT;
|
||||
port->pd_events |= TCPM_FRS_EVENT;
|
||||
spin_unlock(&port->pd_event_lock);
|
||||
kthread_queue_work(port->wq, &port->event_work);
|
||||
}
|
||||
@ -5498,7 +5498,7 @@ EXPORT_SYMBOL_GPL(tcpm_sink_frs);
|
||||
void tcpm_sourcing_vbus(struct tcpm_port *port)
|
||||
{
|
||||
spin_lock(&port->pd_event_lock);
|
||||
port->pd_events = TCPM_SOURCING_VBUS;
|
||||
port->pd_events |= TCPM_SOURCING_VBUS;
|
||||
spin_unlock(&port->pd_event_lock);
|
||||
kthread_queue_work(port->wq, &port->event_work);
|
||||
}
|
||||
|
@ -394,7 +394,13 @@ enum {
|
||||
BLK_MQ_F_STACKING = 1 << 2,
|
||||
BLK_MQ_F_TAG_HCTX_SHARED = 1 << 3,
|
||||
BLK_MQ_F_BLOCKING = 1 << 5,
|
||||
/* Do not allow an I/O scheduler to be configured. */
|
||||
BLK_MQ_F_NO_SCHED = 1 << 6,
|
||||
/*
|
||||
* Select 'none' during queue registration in case of a single hwq
|
||||
* or shared hwqs instead of 'mq-deadline'.
|
||||
*/
|
||||
BLK_MQ_F_NO_SCHED_BY_DEFAULT = 1 << 7,
|
||||
BLK_MQ_F_ALLOC_POLICY_START_BIT = 8,
|
||||
BLK_MQ_F_ALLOC_POLICY_BITS = 1,
|
||||
|
||||
|
22
include/trace/hooks/pci.h
Normal file
22
include/trace/hooks/pci.h
Normal file
@ -0,0 +1,22 @@
|
||||
/* SPDX-License-Identifier: GPL-2.0 */
|
||||
#undef TRACE_SYSTEM
|
||||
#define TRACE_SYSTEM pci
|
||||
#define TRACE_INCLUDE_PATH trace/hooks
|
||||
|
||||
#if !defined(_TRACE_HOOK_PCI_H) || defined(TRACE_HEADER_MULTI_READ)
|
||||
#define _TRACE_HOOK_PCI_H
|
||||
#include <linux/tracepoint.h>
|
||||
#include <trace/hooks/vendor_hooks.h>
|
||||
/*
|
||||
* Following tracepoints are not exported in tracefs and provide a
|
||||
* mechanism for vendor modules to hook and extend functionality
|
||||
*/
|
||||
|
||||
DECLARE_RESTRICTED_HOOK(android_rvh_pci_d3_sleep,
|
||||
TP_PROTO(struct pci_dev *dev, unsigned int delay, int *err),
|
||||
TP_ARGS(dev, delay, err), 1);
|
||||
|
||||
#endif /* _TRACE_HOOK_PCI_H */
|
||||
|
||||
/* This part must be outside protection */
|
||||
#include <trace/define_trace.h>
|
@ -32,15 +32,16 @@ int pelt_load_avg_period = PELT32_LOAD_AVG_PERIOD;
|
||||
int pelt_load_avg_max = PELT32_LOAD_AVG_MAX;
|
||||
const u32 *pelt_runnable_avg_yN_inv = pelt32_runnable_avg_yN_inv;
|
||||
|
||||
static int __init set_pelt(char *str)
|
||||
int get_pelt_halflife(void)
|
||||
{
|
||||
int rc, num;
|
||||
return pelt_load_avg_period;
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(get_pelt_halflife);
|
||||
|
||||
rc = kstrtoint(str, 0, &num);
|
||||
if (rc) {
|
||||
pr_err("%s: kstrtoint failed. rc=%d\n", __func__, rc);
|
||||
return 0;
|
||||
}
|
||||
static int __set_pelt_halflife(void *data)
|
||||
{
|
||||
int rc = 0;
|
||||
int num = *(int *)data;
|
||||
|
||||
switch (num) {
|
||||
case PELT8_LOAD_AVG_PERIOD:
|
||||
@ -56,10 +57,32 @@ static int __init set_pelt(char *str)
|
||||
pr_info("PELT half life is set to %dms\n", num);
|
||||
break;
|
||||
default:
|
||||
pr_err("Default PELT half life is 32ms\n");
|
||||
rc = -EINVAL;
|
||||
pr_err("Failed to set PELT half life to %dms, the current value is %dms\n",
|
||||
num, pelt_load_avg_period);
|
||||
}
|
||||
|
||||
return 0;
|
||||
return rc;
|
||||
}
|
||||
|
||||
int set_pelt_halflife(int num)
|
||||
{
|
||||
return stop_machine(__set_pelt_halflife, &num, NULL);
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(set_pelt_halflife);
|
||||
|
||||
static int __init set_pelt(char *str)
|
||||
{
|
||||
int rc, num;
|
||||
|
||||
rc = kstrtoint(str, 0, &num);
|
||||
if (rc) {
|
||||
pr_err("%s: kstrtoint failed. rc=%d\n", __func__, rc);
|
||||
return 0;
|
||||
}
|
||||
|
||||
__set_pelt_halflife(&num);
|
||||
return rc;
|
||||
}
|
||||
|
||||
early_param("pelt", set_pelt);
|
||||
|
Loading…
Reference in New Issue
Block a user