Commit Graph

979446 Commits

Author SHA1 Message Date
Chanho Park
d67fe0a88e ANDROID: GKI: sync allowed list for exynosauto SoC
This patch is for updating GKI allowed symbol list without adding any
new symbol. Next patch will introduce newly added symbols for Exynosauto
SoC GKI vendor modules.

Bug: 194547942
Signed-off-by: Chanho Park <chanho61.park@samsung.com>
Change-Id: I5f50e0c7b7991953aa40b9555277f6a208629303
2021-07-28 11:23:49 +00:00
Woogeun Lee
7a686fd9a5 ANDROID: ABI: update allowed list for galaxy
Leaf changes summary: 28 artifacts changed
Changed leaf types summary: 0 leaf type changed
Removed/Changed/Added functions summary: 0 Removed, 0 Changed, 26 Added functions
Removed/Changed/Added variables summary: 0 Removed, 0 Changed, 2 Added variables
Function symbols changes summary: 0 Removed, 1 Added function symbol not referenced by debug info
Variable symbols changes summary: 0 Removed, 0 Added variable symbol not referenced by debug info

26 Added functions:

  [A] 'function int __blk_mq_debugfs_rq_show(seq_file*, request*)'
  [A] 'function unsigned int __kfifo_out_peek(__kfifo*, void*, unsigned int)'
  [A] 'function void __kfree_skb(sk_buff*)'  [A] 'function void _dev_alert(const device*, const char*, ...)'
  [A] 'function bool blk_mq_sched_try_insert_merge(request_queue*, request*)'
  [A] 'function bool blk_mq_sched_try_merge(request_queue*, bio*, unsigned int, request**)'
  [A] 'function void* bsearch(void*, void*, size_t, size_t, cmp_func_t)'
  [A] 'function int cleancache_register_ops(const cleancache_ops*)'
  [A] 'function int device_match_of_node(device*, void*)'
  [A] 'function bool elv_bio_merge_ok(request*, bio*)'
  [A] 'function void elv_rb_add(rb_root*, request*)'
  [A] 'function void elv_rb_del(rb_root*, request*)'
  [A] 'function request* elv_rb_find(rb_root*, sector_t)'
  [A] 'function request* elv_rb_former_request(request_queue*, request*)'
  [A] 'function request* elv_rb_latter_request(request_queue*, request*)'
  [A] 'function void elv_rqhash_add(request_queue*, request*)'
  [A] 'function void elv_rqhash_del(request_queue*, request*)'
  [A] 'function char* get_options(const char*, int, int*)'
  [A] 'function ctl_table_header* register_net_sysctl(net*, const char*, ctl_table*)'
  [A] 'function int regulator_get_current_limit(regulator*)'
  [A] 'function bool rfkill_set_sw_state(rfkill*, bool)'
  [A] 'function int skb_copy_ubufs(sk_buff*, gfp_t)'
  [A] 'function int smpboot_register_percpu_thread(smp_hotplug_thread*)'
  [A] 'function void smpboot_unregister_percpu_thread(smp_hotplug_thread*)'
  [A] 'function int snd_soc_add_card_controls(snd_soc_card*, const snd_kcontrol_new*, int)'
  [A] 'function kuid_t sock_i_uid(sock*)'

2 Added variables:

  [A] 'tracepoint __tracepoint_android_vh_kfree_skb'
  [A] 'tracepoint __tracepoint_android_vh_ptype_head'

1 Added function symbol not referenced by debug info:

  [A] copy_page

Bug: 194749867
Signed-off-by: Woogeun Lee <woogeun.lee@samsung.com>
Change-Id: I96aedb7e3ac670dbce8c222859ed399be683f7c0
2021-07-28 10:22:22 +00:00
Chinwen Chang
3f153f7642 ANDROID: Update symbol list for mtk
Leaf changes summary: 6 artifacts changed
Changed leaf types summary: 0 leaf type changed
Removed/Changed/Added functions summary: 0 Removed, 0 Changed, 3 Added functions
Removed/Changed/Added variables summary: 0 Removed, 0 Changed, 3 Added variables

3 Added functions:

  [A] 'function int __traceiter_android_vh_check_bpf_syscall(void*, int, const bpf_attr*, unsigned int)'
  [A] 'function int __traceiter_android_vh_check_file_open(void*, const file*)'
  [A] 'function int __traceiter_android_vh_check_mmap_file(void*, const file*, unsigned long int, unsigned long int, unsigned long int)'

3 Added variables:

  [A] 'tracepoint __tracepoint_android_vh_check_bpf_syscall'
  [A] 'tracepoint __tracepoint_android_vh_check_file_open'
  [A] 'tracepoint __tracepoint_android_vh_check_mmap_file'

Bug: 194827890
Signed-off-by: Chinwen Chang <chinwen.chang@mediatek.com>
Change-Id: Id7a17c452a21294f018a86891385d22c0ec2f975
2021-07-28 08:56:55 +00:00
Liangliang Li
81c8161bed ANDROID: vendor_hooks: Add hooks to tcp/udp send/recv msg functions.
Add hook to tcp/udp to collect network info and do performance tuning.

Bug: 190523684

Change-Id: Id790a381d5ce6c35a747697510f14678ccf3ff2f
Signed-off-by: Liangliang Li <liliangliang@vivo.com>
2021-07-28 09:53:04 +08:00
Sandeep Patil
76879a1964 ANDROID: fs: pipe: wakeup readers on small writes even if pipe had data
commit '1b6b26ae7053 ("pipe: fix and clarify pipe write wakeup logic")'
change `pipe_write()` wakeup logic to wakeup readers only if the pipe
was empty.

This meant that applications that are not draining the pipe
before each write were exposed to unexpected timeouts / hangs in
epoll_wait() waiting for data in a pipe using EPOLLIN | EPOLLET flags.

This behaviour can be easily tested with android12-5.4 kernel where
the test that uses pipes for notifications in this way works while it
fails 100% with android12-5.10.

This change restores the old behavior to wakeup all pipe_readers if any
new data is written to the pipe.

Bug: 193851993
Bug: 193846582

Change-Id: If0c5a844091ccf16d5236bd072326325d4d5447a
Signed-off-by: Sandeep Patil <sspatil@google.com>
2021-07-27 17:35:49 +00:00
Greg Kroah-Hartman
989fb724d5 ANDROID: GKI: sort the list of symbol lists
Trying to verify that all of the proper files are being pulled in for
the ABI symbol list is easier if they are in sorted order.

Bug: 193853163
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Change-Id: I663313ea6d61b2ab80b3fd8e29098e694ff4ef00
2021-07-27 17:32:04 +02:00
Greg Kroah-Hartman
6d737c9d03 Revert "ANDROID: ABI: update symbols to unisoc whitelist for the fifth time"
This reverts commit 52f8b40ff6.

It turns out that the unisoc file was never even hooked up to the gki
symbol build script so this file is doing nothing at all.

I tried to add it, but it breaks the build as it includes a lot of
symbols that are not even part of this kernel tree, so it must have been
created from a different kernel version.

Please resubmit this file properly, and hook it up to the build process
(by adding it to the list in the build.config.gki.aarch64 file.)

Bug: 186088840
Signed-off-by: Jian Gong <jian.gong@unisoc.com>
Fixes: 52f8b40ff6 ("ANDROID: ABI: update symbols to unisoc whitelist for the fifth time")
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Change-Id: Ibdb7d57f0901aa7273c0c29e0a7e0eaf26909e26
2021-07-27 17:28:46 +02:00
hajun.sung
4d9d100eea ANDROID: Update the exynos symbol list
Leaf changes summary: 3 artifacts changed
Changed leaf types summary: 0 leaf type changed
Removed/Changed/Added functions summary: 0 Removed, 0 Changed, 3 Added functions
Removed/Changed/Added variables summary: 0 Removed, 0 Changed, 0 Added variable

3 Added functions:

  [A] 'function vm_struct* __get_vm_area_caller(unsigned long int, unsigned long int, unsigned long int, unsigned long int, void*)'
  [A] 'function int i3c_master_defslvs_locked(i3c_master_controller*)'
  [A] 'function int map_kernel_range(unsigned long int, unsigned long int, pgprot_t, page**)'

Bug: 194555897
Change-Id: I594de72ab153828260c85d2039a068d5945d2cab
Signed-off-by: Hajun Sung <hajun.sung@samsung.com>
2021-07-27 09:40:18 +00:00
fengmingli
c2af3663a8 ANDROID: GKI: Add some symbols to symbol list
Leaf changes summary: 22 artifacts changed
Changed leaf types summary: 0 leaf type changed
Removed/Changed/Added functions summary: 0 Removed, 0 Changed, 11 Added functions
Removed/Changed/Added variables summary: 0 Removed, 0 Changed, 11 Added variables

11 Added functions:

  [A] 'function int __traceiter_android_vh_mmc_attach_sd(void*, mmc_host*, u32, int)'
  [A] 'function int __traceiter_android_vh_mmc_blk_mq_rw_recovery(void*, mmc_card*)'
  [A] 'function int __traceiter_android_vh_mmc_blk_reset(void*, mmc_host*, int, bool*)'
  [A] 'function int __traceiter_android_vh_mmc_gpio_cd_irqt(void*, mmc_host*, bool*)'
  [A] 'function int __traceiter_android_vh_sd_update_bus_speed_mode(void*, mmc_card*)'
  [A] 'function int __traceiter_android_vh_sdhci_get_cd(void*, sdhci_host*, bool*)'
  [A] 'function int __traceiter_dwc3_complete_trb(void*, dwc3_ep*, dwc3_trb*)'
  [A] 'function int __traceiter_dwc3_ctrl_req(void*, usb_ctrlrequest*)'
  [A] 'function int __traceiter_dwc3_event(void*, u32, dwc3*)'
  [A] 'function int __traceiter_usb_gadget_connect(void*, usb_gadget*, int)'
  [A] 'function int __traceiter_usb_gadget_disconnect(void*, usb_gadget*, int)'

11 Added variables:

  [A] 'tracepoint __tracepoint_android_vh_mmc_attach_sd'
  [A] 'tracepoint __tracepoint_android_vh_mmc_blk_mq_rw_recovery'
  [A] 'tracepoint __tracepoint_android_vh_mmc_blk_reset'
  [A] 'tracepoint __tracepoint_android_vh_mmc_gpio_cd_irqt'
  [A] 'tracepoint __tracepoint_android_vh_sd_update_bus_speed_mode'
  [A] 'tracepoint __tracepoint_android_vh_sdhci_get_cd'
  [A] 'tracepoint __tracepoint_dwc3_complete_trb'
  [A] 'tracepoint __tracepoint_dwc3_ctrl_req'
  [A] 'tracepoint __tracepoint_dwc3_event'
  [A] 'tracepoint __tracepoint_usb_gadget_connect'
  [A] 'tracepoint __tracepoint_usb_gadget_disconnect'

Bug: 194373509

Change-Id: I9fa61c6416ade3031135b26871a67d61b316377d
Signed-off-by: fengmingli <mingli.feng@vivo.com>
2021-07-27 10:37:17 +08:00
Shaleen Agrawal
24ceda42e2 ANDROID: abi_gki_aarch64_qcom: Add additional symbols for show_cpufinfo_max_freq
Additional restricted vendor hook has been added.

Leaf changes summary: 2 artifacts changed
Changed leaf types summary: 0 leaf type changed
Removed/Changed/Added functions summary: 0 Removed, 0 Changed, 1 Added
function
Removed/Changed/Added variables summary: 0 Removed, 0 Changed, 1 Added
variable

1 Added function:

[A] 'function int __traceiter_android_rvh_show_max_freq(void*,
cpufreq_policy*, unsigned int*)'

1 Added variable:

[A] 'tracepoint __tracepoint_android_rvh_show_max_freq'

Bug: 194431527
Change-Id: Iaac280c8e3dbacd259a193bb199a92ac41151c8a
Signed-off-by: Shaleen Agrawal <shalagra@codeaurora.org>
2021-07-26 20:51:42 +00:00
Shaleen Agrawal
f3e3a45d2b ANDROID: sched: add restricted hook to override show_cpufinfo_max_freq
Need restricted hook so that it can sleep.

The old non-restricted versions need to stay in place as a consequence
of KMI freeze.

Bug: 194431527
Change-Id: I7093b66f95c3b9c473386ade60d8897426ddbb13
Signed-off-by: Shaleen Agrawal <shalagra@codeaurora.org>
2021-07-26 20:51:32 +00:00
Woogeun Lee
e30728e4ff ANDROID: ABI: initial update allowed list for galaxy
No additional symbol is added that is not on any pre-existing symbol
list.

Bug: 194634714
Signed-off-by: Woogeun Lee <woogeun.lee@samsung.com>
Change-Id: I1779540d56c977b8260ad1fc6481fd0a85d383a4
2021-07-26 14:40:15 +01:00
Mukesh Kumar Savaliya
13fe7b9964 ANDROID: abi_gki_aarch64_qcom: Add I3C interface symbols to qcom tree
This change adds I3C device inteface functions into the qcom
symbol list. Helps fixing the ABI differences. These functions
can be used by client driver registering with the i3c master.

Leaf changes summary: 9 artifacts changed
Changed leaf types summary: 0 leaf type changed
Removed/Changed/Added functions summary: 0 Removed, 0 Changed, 9 Added functions
Removed/Changed/Added variables summary: 0 Removed, 0 Changed, 0 Added variable

9 Added functions:

  [A] 'function int i3c_device_disable_ibi(i3c_device*)'
  [A] 'function int i3c_device_do_priv_xfers(i3c_device*, i3c_priv_xfer*, int)'
  [A] 'function int i3c_device_enable_ibi(i3c_device*)'
  [A] 'function void i3c_device_free_ibi(i3c_device*)'
  [A] 'function void i3c_device_get_info(i3c_device*, i3c_device_info*)'
  [A] 'function int i3c_device_request_ibi(i3c_device*, const i3c_ibi_setup*)'
  [A] 'function int i3c_driver_register_with_owner(i3c_driver*, module*)'
  [A] 'function void i3c_driver_unregister(i3c_driver*)'
  [A] 'function device* i3cdev_to_dev(i3c_device*)'

Bug: 194547961
Change-Id: Ie85412e101e9201d4eed212669731b46fb222ce2
Signed-off-by: Mukesh Kumar Savaliya <msavaliy@codeaurora.org>
2021-07-26 09:15:18 +00:00
Louis Kuo
1321fef6b8 ANDROID: Update symbol list for mtk
Leaf changes summary: 8 artifacts changed
Changed leaf types summary: 0 leaf type changed
Removed/Changed/Added functions summary: 0 Removed, 0 Changed, 4 Added functions
Removed/Changed/Added variables summary: 0 Removed, 0 Changed, 4 Added variables

4 Added functions:

  [A] 'function int __traceiter_android_rvh_media_device_setup_link(void*, media_link*, media_link_desc*, int*)'
  [A] 'function int __traceiter_android_rvh_v4l2subdev_set_fmt(void*, v4l2_subdev*, v4l2_subdev_pad_config*, v4l2_subdev_format*, int*)'
  [A] 'function int __traceiter_android_rvh_v4l2subdev_set_frame_interval(void*, v4l2_subdev*, v4l2_subdev_frame_interval*, int*)'
  [A] 'function int __traceiter_android_rvh_v4l2subdev_set_selection(void*, v4l2_subdev*, v4l2_subdev_pad_config*, v4l2_subdev_selection*, int*)'

4 Added variables:

  [A] 'tracepoint __tracepoint_android_rvh_media_device_setup_link'
  [A] 'tracepoint __tracepoint_android_rvh_v4l2subdev_set_fmt'
  [A] 'tracepoint __tracepoint_android_rvh_v4l2subdev_set_frame_interval'
  [A] 'tracepoint __tracepoint_android_rvh_v4l2subdev_set_selection'

Bug: 194349973

Signed-off-by: Louis Kuo <louis.kuo@mediatek.com>
Change-Id: I82acdbae39135574ae1312882e24a0545bd89f45
2021-07-25 23:54:57 +00:00
Shaleen Agrawal
0050b3de97 ANDROID: abi_gki_aarch64_qcom: Add additional symbols for after hooks
Need after enqueue and dequeue hooks for QC value adds.

Leaf changes summary: 2 artifacts changed
Changed leaf types summary: 0 leaf type changed
Removed/Changed/Added functions summary: 0 Removed, 0 Changed, 1 Added
function
Removed/Changed/Added variables summary: 0 Removed, 0 Changed, 1 Added
variable

1 Added function:

[A] 'function int __traceiter_android_rvh_after_dequeue_task(void*,
rq*, task_struct*)'

1 Added variable:

[A] 'tracepoint __tracepoint_android_rvh_after_dequeue_task'

Bug: 194487266
Change-Id: Id4ccde296a73c85e9e6e581773154378727c9c1d
Signed-off-by: Shaleen Agrawal <shalagra@codeaurora.org>
2021-07-25 12:26:43 +00:00
Jack Pham
583eba64fe FROMGIT: usb: gadget: composite: Allow bMaxPower=0 if self-powered
Currently the composite driver encodes the MaxPower field of
the configuration descriptor by reading the c->MaxPower of the
usb_configuration only if it is non-zero, otherwise it falls back
to using the value hard-coded in CONFIG_USB_GADGET_VBUS_DRAW.
However, there are cases when a configuration must explicitly set
bMaxPower to 0, particularly if its bmAttributes also has the
Self-Powered bit set, which is a valid combination.

This is specifically called out in the USB PD specification section
9.1, in which a PDUSB device "shall report zero in the bMaxPower
field after negotiating a mutually agreeable Contract", and also
verified by the USB Type-C Functional Test TD.4.10.2 Sink Power
Precedence Test.

The fix allows the c->MaxPower to be used for encoding the bMaxPower
even if it is 0, if the self-powered bit is also set.  An example
usage of this would be for a ConfigFS gadget to be dynamically
updated by userspace when the Type-C connection is determined to be
operating in Power Delivery mode.

Co-developed-by: Ronak Vijay Raheja <rraheja@codeaurora.org>
Acked-by: Felipe Balbi <balbi@kernel.org>
Signed-off-by: Ronak Vijay Raheja <rraheja@codeaurora.org>
Signed-off-by: Jack Pham <jackp@codeaurora.org>
Link: https://lore.kernel.org/r/20210720080907.30292-1-jackp@codeaurora.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

(cherry picked from commit bcacbf06c8
 https://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb.git usb-next)
Bug: 194455199
Change-Id: Ie2d04df6cf3c1c6cdaa9f0872774fd6e5788cade
Signed-off-by: Jack Pham <jackp@codeaurora.org>
2021-07-24 16:20:13 +00:00
Jaegeuk Kim
e33cf9dd43 FROMGIT: f2fs: let's keep writing IOs on SBI_NEED_FSCK
SBI_NEED_FSCK is an indicator that fsck.f2fs needs to be triggered, so it
is not fully critical to stop any IO writes. So, let's allow to write data
instead of reporting EIO forever given SBI_NEED_FSCK, but do keep OPU.

Bug: 193659742
Fixes: 9557727876 ("f2fs: drop inplace IO if fs status is abnormal")
Cc: <stable@kernel.org> # v5.13+
Reviewed-by: Chao Yu <chao@kernel.org>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
(cherry picked from commit 1ffc8f5f77
 git://git.kernel.org/pub/scm/linux/kernel/git/jaegeuk/f2fs.git dev)
Change-Id: I9585358c1cee864064d9d210ee643f49ff1e6749
2021-07-22 23:53:01 +00:00
Bart Van Assche
7f74a5165a FROMLIST: scsi: ufs: Fix memory corruption by ufshcd_read_desc_param()
Running the following commands on my test setup triggers stack corruption:

  cd /sys/devices/platform/14700000.ufs/host0/target0:0:0 &&
  for f in $(ls */unit_descriptor/hpb_pinned_region_start_offset | sort); do
    grep -aH . $f
  done

The above commands trigger stack corruption because these commands
assign the value 37 to the variable 'param_offset' and the value 35 to
'buff_len'. The following code changes param_size from 2 into 254 since
'param_size' has type u8:

        if (param_offset + param_size > buff_len)
                param_size = buff_len - param_offset;

The next statement triggers stack corruption since 'param_read_buf'
points at a two-byte stack array:

        memcpy(param_read_buf, &desc_buf[param_offset], param_size);

With this patch applied, the output of the above command on my test
setup is as follows:

0:0:0:0/unit_descriptor/hpb_pinned_region_start_offset:0x0000
0:0:0:1/unit_descriptor/hpb_pinned_region_start_offset:0x0000
0:0:0:2/unit_descriptor/hpb_pinned_region_start_offset:0x0000
0:0:0:3/unit_descriptor/hpb_pinned_region_start_offset:0x0000
grep: 0:0:0:49456/unit_descriptor/hpb_pinned_region_start_offset: Invalid argument
grep: 0:0:0:49476/unit_descriptor/hpb_pinned_region_start_offset: Invalid argument
grep: 0:0:0:49488/unit_descriptor/hpb_pinned_region_start_offset: Invalid argument

Link: https://lore.kernel.org/linux-scsi/20210719231127.869088-1-bvanassche@acm.org/T/#u
Bug: 194045295
Change-Id: I305c15b20f3ac3d6e3e97592566fcc51058195bb
Signed-off-by: Bart Van Assche <bvanassche@google.com>
2021-07-22 11:47:45 -07:00
Greg Kroah-Hartman
06e12b3d0a Revert "ANDROID: ABI: initial update allowed list for galaxy"
This reverts commit d6eeae59b5.

Reason for revert: the file is in DOS line-ends and the tools are
not picking it up at all.  So no .xml file updates were ever done
with this.

Bug: 193853163
Change-Id: I7bfc7a9d2c13015093bbb70c07d3906bdd7b7504
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
2021-07-22 16:36:44 +00:00
Greg Kroah-Hartman
66b6a4a736 Revert "ANDROID: ABI: update allowed list for galaxy"
This reverts commit ddabf14bea.

The file is in DOS format and no tools pick it up.  Because of this
there were additional symbols being added here that were never reflected
in the .xml update.

Bug: 193853163
Cc: Woogeun Lee <woogeun.lee@samsung.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Change-Id: I399e8a3509b74524852cb44a59a0f54ef9e6dbb8
2021-07-22 16:36:30 +00:00
Greg Kroah-Hartman
f3f9d49629 Revert "ANDROID: ABI: Update allowed list for galaxy"
This reverts commit 8e6d28165f.

Reason for revert: File has DOS line ends and no tool is picking it
up for the .xml update, so nothing is checking this.

Bug: 194367029
Change-Id: I0d908a709bdb1a76cc018c772376158762695d5b
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
2021-07-22 16:36:07 +00:00
Matthias Maennich
ef0c4c92e4 ANDROID: Use authoritative Dr. No list from android-mainline
An authoritative Dr. No reviewers list has been created in
android-mainline. Rather use this list for enforcement to avoid
duplication.

Bug: 194314089
Signed-off-by: Matthias Maennich <maennich@google.com>
Change-Id: Iab1e4bd427b500295158cef390ce10612b3f6d72
2021-07-22 15:25:25 +00:00
Ryun Park
8e6d28165f ANDROID: ABI: Update allowed list for galaxy
Leaf changes summary: 0 artifact changed
Changed leaf types summary: 0 leaf type changed
Removed/Changed/Added functions summary: 0 Removed, 0 Changed, 0 Added function
Removed/Changed/Added variables summary: 0 Removed, 0 Changed, 0 Added variable

Bug: 194367029
Change-Id: Ie8d495e3c2b73b57a6c586e958691dab80891e43
Signed-off-by: Ryun Park <ryun.park@samsung.com>
2021-07-22 11:48:47 +00:00
Charan Teja Reddy
90732d426e UPSTREAM: mm/compaction: correct deferral logic for proactive compaction
should_proactive_compact_node() returns true when sum of the weighted
fragmentation score of all the zones in the node is greater than the
wmark_high of compaction, which then triggers the proactive compaction
that operates on the individual zones of the node.  But proactive
compaction runs on the zone only when its weighted fragmentation score
is greater than wmark_low(=wmark_high - 10).

This means that the sum of the weighted fragmentation scores of all the
zones can exceed the wmark_high but individual weighted fragmentation zone
scores can still be less than wmark_low which makes the unnecessary
trigger of the proactive compaction only to return doing nothing.

Issue with the return of proactive compaction with out even trying is its
deferral.  It is simply deferred for 1 << COMPACT_MAX_DEFER_SHIFT if the
scores across the proactive compaction is same, thinking that compaction
didn't make any progress but in reality it didn't even try.  With the
delay between successive retries for proactive compaction is 500msec, it
can result into the deferral for ~30sec with out even trying the proactive
compaction.

Test scenario is that: compaction_proactiveness=50 thus the wmark_low = 50
and wmark_high = 60.  System have 2 zones(Normal and Movable) with sizes
5GB and 6GB respectively.  After opening some apps on the android, the
weighted fragmentation scores of these zones are 47 and 49 respectively.
Since the sum of these fragmentation scores are above the wmark_high which
triggers the proactive compaction and there since the individual zones
weighted fragmentation scores are below wmark_low, it returns without
trying the proactive compaction.  As a result the weighted fragmentation
scores of the zones are still 47 and 49 which makes the existing logic to
defer the compaction thinking that noprogress is made across the
compaction.

Fix this by checking just zone fragmentation score, not the weighted, in
__compact_finished() and use the zones weighted fragmentation score in
fragmentation_score_node().  In the test case above, If the weighted
average of is above wmark_high, then individual score (not adjusted) of
atleast one zone has to be above wmark_high.  Thus it avoids the
unnecessary trigger and deferrals of the proactive compaction.

Link: https://lkml.kernel.org/r/1610989938-31374-1-git-send-email-charante@codeaurora.org
Signed-off-by: Charan Teja Reddy <charante@codeaurora.org>
Suggested-by: Vlastimil Babka <vbabka@suse.cz>
Acked-by: Vlastimil Babka <vbabka@suse.cz>
Reviewed-by: Khalid Aziz <khalid.aziz@oracle.com>
Acked-by: David Rientjes <rientjes@google.com>
Cc: Michal Hocko <mhocko@suse.com>
Cc: Nitin Gupta <ngupta@nitingupta.dev>
Cc: Vinayak Menon <vinmenon@codeaurora.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>

(cherry picked from commit 40d7e20320)

Bug: 194263998
Signed-off-by: Suren Baghdasaryan <surenb@google.com>
Change-Id: I814b350368f2183f064ab71030e075dd7bea901b
2021-07-21 22:18:24 +00:00
Matthias Maennich
d0a88ae479 ANDROID: Enable GKI Dr. No Enforcement
This effectively locks down OWNERS approval to a small group to guard
the code base against unintentional breakages.

Bug: 194314089
Signed-off-by: Matthias Maennich <maennich@google.com>
Change-Id: Ifd1ea97639a622320ea83f901f6451e2e52b38d4
2021-07-21 20:51:47 +01:00
Louis Kuo
e6a59da61e ANDROID: media: v4l2-core: Fix deadlock in vendor hook
The vendor hook functions we implemented will invoke callback functions which have do some sleep or spinlock
operations and have risk of deadlock due to preemption disabled of normal vendor hook function.
So we have to use restricted vendor hook function instead.
Due to KMI freeze we could not change the existing hooks.

trace_android_rvh_media_device_setup_link	=>invoke setup_link, link_notify callback
trace_android_rvh_v4l2subdev_set_xxx		=>invoke set_xxx callback

Bug: 193870284

Signed-off-by: Louis Kuo <louis.kuo@mediatek.com>
Change-Id: I94fe2e112b6c3d9ac5177abb30a99b7007068f7e
2021-07-21 13:05:27 +00:00
Guangming Cao
fdb1cfe2d3 FROMGIT: dma_buf: remove dmabuf sysfs teardown before release
Dmabuf sysfs stat is used for dmabuf info track.
But these file maybe still in use after buffer released,
should clear it before buffer release.

Signed-off-by: Guangming Cao <Guangming.Cao@mediatek.com>

Bug: 193585160
(cherry picked from commit 63c57e8dc7
 https://anongit.freedesktop.org/git/drm/drm-misc.git drm-misc)
Link: https://patchwork.freedesktop.org/patch/445008/
Change-Id: I0715d265f1c363130bd6cf4c036a5fd3730e2b16
Signed-off-by: Guangming Cao <Guangming.Cao@mediatek.com>
2021-07-21 02:07:51 +00:00
chihhao.chen
1dc0dd2573 ANDROID: update mtk symbol list
Leaf changes summary: 2 artifacts changed
Changed leaf types summary: 0 leaf type changed
Removed/Changed/Added functions summary: 0 Removed, 0 Changed, 1 Added function
Removed/Changed/Added variables summary: 0 Removed, 0 Changed, 1 Added variable

1 Added function:

  [A] 'function int __traceiter_xhci_urb_giveback(void*, urb*)'

1 Added variable:

  [A] 'tracepoint __tracepoint_xhci_urb_giveback'

Bug: 194173482
Change-Id: I624429fa03a09edd01373273654429fc2e1ba61a
Signed-off-by: chihhao.chen <chihhao.chen@mediatek.com>
2021-07-20 23:56:23 +00:00
Allen Chiu
a669748346 UPSTREAM: mfd: syscon: Free the allocated name field of struct regmap_config
The commit 529a1101212a("mfd: syscon: Don't free allocated name
for regmap_config") doesn't free the allocated name field of struct
regmap_config, but introduce a memory leak. There is another
commit 94cc89eb8fa5("regmap: debugfs: Fix handling of name string
for debugfs init delays") fixing this debugfs init issue from root
cause. With this fixing, the name field in struct regmap_debugfs_node
is removed. When initialize debugfs for syscon driver, the name
field of struct regmap_config is not used anymore. So, the allocated
name field of struct regmap_config is need to be freed directly after
regmap initialization to avoid memory leak.

Cc: stable@vger.kernel.org
Fixes: 529a1101212a("mfd: syscon: Don't free allocated name for regmap_config")
Signed-off-by: Meng Li <Meng.Li@windriver.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
Link: https://lore.kernel.org/patchwork/patch/1408873/
Bug: 193747648

Signed-off-by: Allen Chiu <allen.chiu@mediatek.com>
Change-Id: Iadc628aae889f306afb6eefbf66fdd9143a91278
(cherry picked from commit 56a1188159)
2021-07-20 23:53:31 +00:00
Can Guo
cffe67a351 ANDROID: Give UIC cmd timeout a larger value
Current UIC cmd timeout (500ms) is too short, UIC cmd completion may
frequently time out when CPUs are shortly hogged by other subsystems.
Change UIC cmd timeout to 5s.

Bug: 193844987
Change-Id: Ia3db5fb4d9a49967e54a9d44676d884f77572831
Signed-off-by: Can Guo <cang@codeaurora.org>
2021-07-20 23:37:19 +00:00
Carlos Llamas
3bca0b5344 ANDROID: binder: retry security_secid_to_secctx()
security_secid_to_secctx() can fail because of a GFP_ATOMIC allocation
This needs to be retried from userspace. However, binder driver doesn't
propagate specific enough error codes just yet (WIP b/28321379). We'll
retry on the binder driver as a temporary work around until userspace
can do this instead.

Bug: 174806915
Signed-off-by: Carlos Llamas <cmllamas@google.com>
Change-Id: Ifebddeb7adf9707613512952b97ab702f0d2d592
2021-07-20 17:48:29 +00:00
Jing-Ting Wu
9fdfeda4c9 ANDROID: update new gki symbol for mtk
Leaf changes summary: 3 artifacts changed (1 filtered out)
Changed leaf types summary: 0 (1 filtered out) leaf type changed
Removed/Changed/Added functions summary: 0 Removed, 0 Changed, 1 Added function
Removed/Changed/Added variables summary: 0 Removed, 0 Changed, 2 Added variables

1 Added function:

[A] 'function int __traceiter_android_rvh_after_enqueue_task(void*, rq*, task_struct*)'

2 Added variables:

[A] 'tracepoint __tracepoint_android_rvh_after_enqueue_task'
[A] 'update_util_data* cpufreq_update_util_data'

Bug: 193861598
Signed-off-by: Jing-Ting Wu <Jing-Ting.Wu@mediatek.com>
Change-Id: Ie1ccd8a6428b773478e189ceeec319e622ea8507
2021-07-20 10:32:14 +00:00
Andrey Konovalov
1dd167be9f ANDROID: mm, kasan: fix for "integrate page_alloc init with HW_TAGS"
My commit "integrate page_alloc init with HW_TAGS" changed the order of
kernel_unpoison_pages() and kernel_init_free_pages() calls. This leads
to complaints from the page unpoisoning code, as the poison pattern gets
overwritten for __GFP_ZERO allocations.

Fix by restoring the initial order. Also add a warning comment.

Reported-by: Vlastimil Babka <vbabka@suse.cz>
Reported-by: Sergei Trofimovich <slyfox@gentoo.org>
Signed-off-by: Andrey Konovalov <andreyknvl@google.com>
Reviewed-by: Sergei Trofimovich <slyfox@gentoo.org>

The fix was included in upstream patch 1bb5eab30d 'kasan, mm: integrate page_alloc init with HW_TAGS'

Fixes: a15989497e ("FROMGIT: kasan, mm: integrate page_alloc init with HW_TAGS")
Bug: 192912968
Signed-off-by: Suren Baghdasaryan <surenb@google.com>
Change-Id: Ifc4ab7ed27b3c060f70ba5ca03117a36c9b4da08
2021-07-20 00:38:20 +00:00
Andrey Konovalov
f215850ea0 UPSTREAM: kasan: fix conflict with page poisoning
When page poisoning is enabled, it accesses memory that is marked as
poisoned by KASAN, which leas to false-positive KASAN reports.

Suppress the reports by adding KASAN annotations to unpoison_page()
(poison_page() already has them).

Link: https://lkml.kernel.org/r/2dc799014d31ac13fd97bd906bad33e16376fc67.1617118501.git.andreyknvl@google.com
Signed-off-by: Andrey Konovalov <andreyknvl@google.com>
Cc: Alexander Potapenko <glider@google.com>
Cc: Marco Elver <elver@google.com>
Cc: Dmitry Vyukov <dvyukov@google.com>
Cc: Andrey Ryabinin <aryabinin@virtuozzo.com>
Cc: Andrey Konovalov <andreyknvl@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>

(cherry picked from commit 06b1f85588)

Bug: 192912968
Signed-off-by: Suren Baghdasaryan <surenb@google.com>
Change-Id: Ica725587c8c72e7b96ac3948799c77a48f27c2e2
2021-07-19 20:39:17 +00:00
Jeongtae Park
a3da917661 ANDROID: GKI: Export two more mm symbols for GKI
__get_vm_area_caller(), map_kernel_range still be needed by a vendor
for their sub-system architecture that need to be improved.
Avoid using these symbols, becuase once the vendor improves
sub-system structure they will be unexported.

Bug: 181049185

Change-Id: I84d7c66351cc6d10798bc3a66f8325a90cec4324
Signed-off-by: Jeongtae Park <jtp.park@samsung.com>
2021-07-19 17:15:33 +00:00
Rocco Yue
0497b9601b ANDROID: Update symbol list for mtk
1. Generated with:
  BUILD_CONFIG=out/build.config OUT_DIR=out ./build/build_abi.sh --update

Leaf changes summary: 2 artifacts changed (1 filtered out)
Changed leaf types summary: 0 (1 filtered out) leaf type changed
Removed/Changed/Added functions summary: 0 Removed, 0 Changed, 1 Added function
Removed/Changed/Added variables summary: 0 Removed, 0 Changed, 1 Added variable

1 Added function:

  [A] 'function int __traceiter_android_vh_ipv6_gen_linklocal_addr(void*, net_device*, bool*)'

1 Added variable:

  [A] 'tracepoint __tracepoint_android_vh_ipv6_gen_linklocal_addr'

Bug: 193858365
Signed-off-by: Rocco Yue <rocco.yue@mediatek.com>
Change-Id: I263cf38e68d6c6a6c10f4fb00c5685cde5d3470b
2021-07-18 07:10:25 +00:00
Alexander Potapenko
0f27e1d317 FROMLIST: kfence: skip all GFP_ZONEMASK allocations
Allocation requests outside ZONE_NORMAL (MOVABLE, HIGHMEM or DMA) cannot
be fulfilled by KFENCE, because KFENCE memory pool is located in a
zone different from the requested one.

Because callers of kmem_cache_alloc() may actually rely on the
allocation to reside in the requested zone (e.g. memory allocations done
with __GFP_DMA must be DMAable), skip all allocations done with
GFP_ZONEMASK and/or respective SLAB flags (SLAB_CACHE_DMA and
SLAB_CACHE_DMA32).

Fixes: 0ce20dd840 ("mm: add Kernel Electric-Fence infrastructure")
Cc: Andrew Morton <akpm@linux-foundation.org>
Cc: Dmitry Vyukov <dvyukov@google.com>
Cc: Marco Elver <elver@google.com>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: Souptick Joarder <jrdr.linux@gmail.com>
Cc: stable@vger.kernel.org # 5.12+
Signed-off-by: Alexander Potapenko <glider@google.com>
Reviewed-by: Marco Elver <elver@google.com>
Acked-by: Souptick Joarder <jrdr.linux@gmail.com>

Bug: 192294212
Test: ran KFENCE test suite with __GFP_DMA on QEMU
Link: https://lore.kernel.org/linux-mm/20210714092222.1890268-2-glider@google.com/
Change-Id: I72d2e24185e213d0ce60155d5a78f29bca8c88cc
Signed-off-by: Alexander Potapenko <glider@google.com>
2021-07-16 11:03:06 +02:00
Alexander Potapenko
8478d8dc53 FROMLIST: kfence: move the size check to the beginning of __kfence_alloc()
Check the allocation size before toggling kfence_allocation_gate.
This way allocations that can't be served by KFENCE will not result in
waiting for another CONFIG_KFENCE_SAMPLE_INTERVAL without allocating
anything.

Suggested-by: Marco Elver <elver@google.com>
Cc: Andrew Morton <akpm@linux-foundation.org>
Cc: Dmitry Vyukov <dvyukov@google.com>
Cc: Marco Elver <elver@google.com>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: stable@vger.kernel.org # 5.12+
Signed-off-by: Alexander Potapenko <glider@google.com>
Reviewed-by: Marco Elver <elver@google.com>

Bug: 192294212
Test: ran KFENCE test suite with __GFP_DMA on QEMU
Link: https://lore.kernel.org/linux-mm/20210714092222.1890268-1-glider@google.com/
Change-Id: Ie69c6134fc1c3e68238457b146e26355c17f5295
Signed-off-by: Alexander Potapenko <glider@google.com>
2021-07-16 11:03:06 +02:00
Woogeun Lee
ddabf14bea ANDROID: ABI: update allowed list for galaxy
Leaf changes summary: 0 artifact changed (1 filtered out)
Changed leaf types summary: 0 (1 filtered out) leaf type changed
Removed/Changed/Added functions summary: 0 Removed, 0 Changed, 0 Added function
Removed/Changed/Added variables summary: 0 Removed, 0 Changed, 0 Added variable

Bug: 193853163
Signed-off-by: Woogeun Lee <woogeun.lee@samsung.com>
Change-Id: I8d090ef6282af83fe1b8e564ed09135f405161bd
2021-07-16 15:46:56 +09:00
Daeho Jeong
11cec52238 FROMGIT: f2fs: add sysfs nodes to get GC info for each GC mode
Added gc_reclaimed_segments and gc_segment_mode sysfs nodes.
1) "gc_reclaimed_segments" shows how many segments have been
reclaimed by GC during a specific GC mode.
2) "gc_segment_mode" is used to control for which gc mode
the "gc_reclaimed_segments" node shows.

Signed-off-by: Daeho Jeong <daehojeong@google.com>
Reviewed-by: Chao Yu <chao@kernel.org>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>

Bug: 182708936
(cherry picked from commit 07c6b5933e
 git://git.kernel.org/pub/scm/linux/kernel/git/jaegeuk/f2fs.git dev)
Change-Id: Ie8c2ccf5d36ce2f388c98b77e22848f3ff6645c3
Signed-off-by: Daeho Jeong <daehojeong@google.com>
2021-07-16 00:21:51 +00:00
Elliot Berman
fdc46110cb ANDROID: abi_gki_aarch64_qcom: Add android_debug_for_each_module
Add android_debug_for_each_module to QC ABI symbol list.

Leaf changes summary: 1 artifact changed
Changed leaf types summary: 0 leaf type changed
Removed/Changed/Added functions summary: 0 Removed, 0 Changed, 1 Added function
Removed/Changed/Added variables summary: 0 Removed, 0 Changed, 0 Added variable

1 Added function:

  [A] 'function void android_debug_for_each_module(int (const char*, void*, void*)*, void*)'

Bug: 193552324
Change-Id: If7be8567121a6c31aae66a15ac9cc72b504a0b98
Signed-off-by: Elliot Berman <quic_eberman@quicinc.com>
2021-07-15 14:06:29 -07:00
Elliot Berman
0bb433e014 ANDROID: debug_symbols: Add android_debug_for_each_module
Allow vendors to obtain a list of modules loaded at given time. Vendor
modules are able to register on part of notifier chain
(register_module_notifer), but a vendor module would never see modules
which are loaded before the one which registers on the notifier chain.
The kernel doesn't offer load order control, so a hook is necessary to
iterate through currently loaded kernel modules.

Bug: 193552324
Change-Id: I3b01cc1b90f8c0c7c21a37992cc7d607316efc7b
Signed-off-by: Elliot Berman <quic_eberman@quicinc.com>
2021-07-15 13:59:25 -07:00
Todd Kjos
a0429aa1d0 ANDROID: ABI: Update ABI for symbol list updates
Update ABI for update of oppo and mtk symbol-lists

Leaf changes summary: 2 artifacts changed (1 filtered out)
Changed leaf types summary: 0 (1 filtered out) leaf type changed
Removed/Changed/Added functions summary: 0 Removed, 0 Changed, 2 Added functions
Removed/Changed/Added variables summary: 0 Removed, 0 Changed, 0 Added variable

2 Added functions:

  [A] 'function int devres_destroy(device*, void (device*, void*)*, int (device*, void*, void*)*, void*)'
  [A] 'function void put_task_stack(task_struct*)'

Bug: 193384408
Bug: 192990535

Signed-off-by: Todd Kjos <tkjos@google.com>
Change-Id: Ie8f60676dc066f892a8e87a64bdfc3a480f9c9a3
2021-07-15 20:56:02 +00:00
huangqiujun
c68e5ca9f8 ANDROID: GKI: Update symbols to symbol list
Update symbols to symbol list externed by oem modules.

Leaf changes summary: 1 artifact changed
Changed leaf types summary: 0 leaf type changed
Removed/Changed/Added functions summary: 0 Removed, 0 Changed, 1 Added
function
Removed/Changed/Added variables summary: 0 Removed, 0 Changed, 0 Added
variable

1 Added function:

  [A] 'function int devres_destroy(device*, dr_release_t, dr_match_t,
void*)'

Bug: 193384408

Change-Id: I2102ff67f0f9b3a30464ad9a7070bb7ab26980a9
Signed-off-by: huangqiujun <huangqiujun@oppo.com>
2021-07-15 20:55:45 +00:00
chunhui.li
aac5a77959 ANDROID: Update symbol list for mtk
1. Generated with:
  BUILD_CONFIG=out/build.config OUT_DIR=out ./build/build_abi.sh --update

Leaf changes summary: 1 artifact changed
Changed leaf types summary: 0 leaf type changed
Removed/Changed/Added functions summary: 0 Removed, 0 Changed, 1 Added function
Removed/Changed/Added variables summary: 0 Removed, 0 Changed, 0 Added variable

1 Added function:

  [A] 'function void put_task_stack(task_struct*)'

Bug: 192990535

Signed-off-by: chunhui.li <chunhui.li@mediatek.com>
Change-Id: I49a2f5d60950ed5ac8a3028992fe6445073b86e8
2021-07-15 20:55:04 +00:00
Jia Cheng Hu
42fc1faf44 UPSTREAM: block, bfq: set next_rq to waker_bfqq->next_rq in waker injection
Since commit c5089591c3ba ("block, bfq: detect wakers and
unconditionally inject their I/O"), when the in-service bfq_queue, say
Q, is temporarily empty, BFQ checks whether there are I/O requests to
inject (also) from the waker bfq_queue for Q. To this goal, the value
pointed by bfqq->waker_bfqq->next_rq must be controlled. However, the
current implementation mistakenly looks at bfqq->next_rq, which
instead points to the next request of the currently served queue.

This mistake evidently causes losses of throughput in scenarios with
waker bfq_queues.

This commit corrects this mistake.

Fixes: c5089591c3ba ("block, bfq: detect wakers and unconditionally inject their I/O")
Signed-off-by: Jia Cheng Hu <jia.jiachenghu@gmail.com>
Signed-off-by: Jan Kara <jack@suse.cz>
Signed-off-by: Paolo Valente <paolo.valente@linaro.org>
Signed-off-by: Jens Axboe <axboe@kernel.dk>

Bug: 193744965
Change-Id: I2b31773e1f67e4828e33a32acfa29b59809be7e0
(cherry picked from commit d4fc3640ff)
Signed-off-by: Ed Tsai <ed.tsai@mediatek.com>
2021-07-15 19:42:16 +00:00
Aneesh Kumar K.V
e37cc8a09f UPSTREAM: mm/mremap: hold the rmap lock in write mode when moving page table entries.
To avoid a race between rmap walk and mremap, mremap does
take_rmap_locks().  The lock was taken to ensure that rmap walk don't miss
a page table entry due to PTE moves via move_pagetables().  The kernel
does further optimization of this lock such that if we are going to find
the newly added vma after the old vma, the rmap lock is not taken.  This
is because rmap walk would find the vmas in the same order and if we don't
find the page table attached to older vma we would find it with the new
vma which we would iterate later.

As explained in commit eb66ae0308 ("mremap: properly flush TLB before
releasing the page") mremap is special in that it doesn't take ownership
of the page.  The optimized version for PUD/PMD aligned mremap also
doesn't hold the ptl lock.  This can result in stale TLB entries as show
below.

This patch updates the rmap locking requirement in mremap to handle the race condition
explained below with optimized mremap::

Optmized PMD move

    CPU 1                           CPU 2                                   CPU 3

    mremap(old_addr, new_addr)      page_shrinker/try_to_unmap_one

    mmap_write_lock_killable()

                                    addr = old_addr
                                    lock(pte_ptl)
    lock(pmd_ptl)
    pmd = *old_pmd
    pmd_clear(old_pmd)
    flush_tlb_range(old_addr)

    *new_pmd = pmd
                                                                            *new_addr = 10; and fills
                                                                            TLB with new addr
                                                                            and old pfn

    unlock(pmd_ptl)
                                    ptep_clear_flush()
                                    old pfn is free.
                                                                            Stale TLB entry

Optimized PUD move also suffers from a similar race.  Both the above race
condition can be fixed if we force mremap path to take rmap lock.

Link: https://lkml.kernel.org/r/20210616045239.370802-7-aneesh.kumar@linux.ibm.com
Fixes: 2c91bd4a4e ("mm: speed up mremap by 20x on large regions")
Fixes: c49dd34018 ("mm: speedup mremap on 1GB or larger regions")
Link: https://lore.kernel.org/linux-mm/CAHk-=wgXVR04eBNtxQfevontWnP6FDm+oj5vauQXP3S-huwbPw@mail.gmail.com
Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.ibm.com>
Acked-by: Hugh Dickins <hughd@google.com>
Acked-by: Kirill A. Shutemov <kirill.shutemov@linux.intel.com>
Cc: Christophe Leroy <christophe.leroy@csgroup.eu>
Cc: Joel Fernandes <joel@joelfernandes.org>
Cc: Kalesh Singh <kaleshsingh@google.com>
Cc: Kirill A. Shutemov <kirill@shutemov.name>
Cc: Michael Ellerman <mpe@ellerman.id.au>
Cc: Nicholas Piggin <npiggin@gmail.com>
Cc: Stephen Rothwell <sfr@canb.auug.org.au>
Cc: <stable@vger.kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
(cherry picked from commit 97113eb39f)

Bug: 151772539
Signed-off-by: Kalesh Singh <kaleshsingh@google.com>
Change-Id: I5b7235e982ea2efdc155018271fbaf2711fac4c1
2021-07-15 18:39:14 +00:00
Prasad Sodagudi
9b136eab76 ANDROID: pstore/ram: Add backward compatibility for ramoops reserved region
Some of the platforms might be still expecting dedicated memory region
for ramoops node. So add logic to detect the start and size of the
ramoops memory region by looking up reserved memory region with
of_reserved_mem_lookup() when platform_get_resource() failed.

Bug: 191636717
Change-Id: Idc479b45fb3f637f7235efd6eabac62059d5e92b
Signed-off-by: Prasad Sodagudi <psodagud@codeaurora.org>
2021-07-15 18:27:15 +00:00
Louis Kuo
df97297651 ANDROID: Update symbol list for mtk
Leaf changes summary: 43 artifacts changed
Changed leaf types summary: 0 leaf type changed
Removed/Changed/Added functions summary: 0 Removed, 0 Changed, 36 Added functions
Removed/Changed/Added variables summary: 0 Removed, 0 Changed, 7 Added variables

36 Added functions:

  [A] 'function int __media_entity_setup_link(media_link*, u32)'
  [A] 'function int __traceiter_android_vh_clear_mask_adjust(void*, unsigned int, int*)'
  [A] 'function int __traceiter_android_vh_clear_reserved_fmt_fields(void*, v4l2_format*, int*)'
  [A] 'function int __traceiter_android_vh_fill_ext_fmtdesc(void*, v4l2_fmtdesc*, const char**)'
  [A] 'function int __traceiter_android_vh_media_device_setup_link(void*, media_link*, media_link_desc*, int*)'
  [A] 'function int __traceiter_android_vh_v4l2subdev_set_fmt(void*, v4l2_subdev*, v4l2_subdev_pad_config*, v4l2_subdev_format*, int*)'
  [A] 'function int __traceiter_android_vh_v4l2subdev_set_frame_interval(void*, v4l2_subdev*, v4l2_subdev_frame_interval*, int*)'
  [A] 'function int __traceiter_android_vh_v4l2subdev_set_selection(void*, v4l2_subdev*, v4l2_subdev_pad_config*, v4l2_subdev_selection*, int*)'
  [A] 'function int __v4l2_ctrl_modify_range(v4l2_ctrl*, s64, s64, u64, s64)'
  [A] 'function void* __v4l2_find_nearest_size(void*, size_t, size_t, size_t, size_t, s32, s32)'
  [A] 'function device* dev_pm_domain_attach_by_id(device*, unsigned int)'
  [A] 'function bool fwnode_device_is_available(const fwnode_handle*)'
  [A] 'function fwnode_handle* fwnode_graph_get_next_endpoint(const fwnode_handle*, fwnode_handle*)'
  [A] 'function fwnode_handle* fwnode_graph_get_port_parent(const fwnode_handle*)'
  [A] 'function fwnode_handle* fwnode_graph_get_remote_endpoint(const fwnode_handle*)'
  [A] 'function fwnode_handle* fwnode_graph_get_remote_port_parent(const fwnode_handle*)'
  [A] 'function int fwnode_graph_parse_endpoint(const fwnode_handle*, fwnode_endpoint*)'
  [A] 'function int fwnode_property_get_reference_args(const fwnode_handle*, const char*, const char*, unsigned int, unsigned int, fwnode_reference_args*)'
  [A] 'function int fwnode_property_read_u64_array(const fwnode_handle*, const char*, u64*, size_t)'
  [A] 'function media_pad* media_entity_remote_pad(const media_pad*)'
  [A] 'function media_entity* media_graph_walk_next(media_graph*)'
  [A] 'function void media_graph_walk_start(media_graph*, media_entity*)'
  [A] 'function media_request* media_request_get_by_fd(media_device*, int)'
  [A] 'function void media_request_object_complete(media_request_object*)'
  [A] 'function void media_request_put(media_request*)'
  [A] 'function device* rpmsg_find_device(device*, rpmsg_channel_info*)'
  [A] 'function int v4l2_async_notifier_add_subdev(v4l2_async_notifier*, v4l2_async_subdev*)'
  [A] 'function void v4l2_async_notifier_cleanup(v4l2_async_notifier*)'
  [A] 'function int v4l2_async_subdev_notifier_register(v4l2_subdev*, v4l2_async_notifier*)'
  [A] 'function s32 v4l2_ctrl_g_ctrl(v4l2_ctrl*)'
  [A] 'function s64 v4l2_ctrl_g_ctrl_int64(v4l2_ctrl*)'
  [A] 'function v4l2_ctrl* v4l2_ctrl_new_std_menu_items(v4l2_ctrl_handler*, const v4l2_ctrl_ops*, u32, u8, u64, u8, const char* const*)'
  [A] 'function int v4l2_ctrl_request_setup(media_request*, v4l2_ctrl_handler*)'
  [A] 'function int v4l2_ctrl_subdev_subscribe_event(v4l2_subdev*, v4l2_fh*, v4l2_event_subscription*)'
  [A] 'function const v4l2_format_info* v4l2_format_info(u32)'
  [A] 'function int v4l2_pipeline_link_notify(media_link*, u32, unsigned int)'

7 Added variables:

  [A] 'tracepoint __tracepoint_android_vh_clear_mask_adjust'
  [A] 'tracepoint __tracepoint_android_vh_clear_reserved_fmt_fields'
  [A] 'tracepoint __tracepoint_android_vh_fill_ext_fmtdesc'
  [A] 'tracepoint __tracepoint_android_vh_media_device_setup_link'
  [A] 'tracepoint __tracepoint_android_vh_v4l2subdev_set_fmt'
  [A] 'tracepoint __tracepoint_android_vh_v4l2subdev_set_frame_interval'
  [A] 'tracepoint __tracepoint_android_vh_v4l2subdev_set_selection'

Bug: 193623575

Signed-off-by: Louis Kuo <louis.kuo@mediatek.com>
Change-Id: If047e7c88ecd249c2b3a24bb9a86cf686f144021
2021-07-15 16:56:00 +00:00
xieliujie
4322bb07e8 ANDROID: vendor_hooks: Modify the function name
Vendor hook is add in the commit:
https://android-review.googlesource.com/c/kernel/common/+/1687592
When we register the vendor hook and build, there is build error:
too long symbol "__tracepoint_android_vh_binder_transaction_priority_skip"
So, I shorten the function name
android_vh_binder_transaction_priority_skip -->
android_vh_binder_priority_skip

Bug: 186482511

Signed-off-by: xieliujie <xieliujie@oppo.com>
Change-Id: I27f39dd32436b09257bcf6e746f4ccdfbd6d6cfe
2021-07-15 16:50:42 +00:00