Commit Graph

798598 Commits

Author SHA1 Message Date
Mark Salyzyn
08bcbfbf7c ANDROID: GKI: arm64: fault: do_tlb_conf_fault_cb register fault callback
Allow for vendor components or modules to override
"TLB conflict abort" handler,

Signed-off-by: Mark Salyzyn <salyzyn@google.com>
Test: Verified with scripts/gki/device_snapshot
Test: No impact on /sys/ (except new module files) and /dev/
Test: All devices probed as before
Bug: 141888626
Change-Id: I7d0a4d7440412f2ffc611fe597d5d39d18a2a03a
(cherry picked from commit 75c07a4fbd301fbff1522e66996bad91617cd06f)
Bug: 149990629
2020-04-08 19:49:42 +00:00
Lina Iyer
723feab600 ANDROID: GKI: QoS: Enhance framework to support cpu/irq specific QoS requests
QoS request for CPU_DMA_LATENCY can be better optimized if the request
can be set only for the required cpus and not all cpus. This helps save
power on other cores, while still gauranteeing the quality of service.

Enhance the QoS constraints data structures to support target value for
each core. Requests specify if the QoS is applicable to all cores
(default) or to a selective subset of the cores or to a core(s), that the
IRQ is affine to.

QoS requests that need to track an IRQ can be set to apply only on the
cpus to which the IRQ's smp_affinity attribute is set to. The QoS
framework will automatically track IRQ migration between the cores. The
QoS is updated to be applied only to the core(s) that the IRQ has been
migrated to.

Idle and interested drivers can request a PM QoS value for a constraint
across all cpus, or a specific cpu or a set of cpus. Separate APIs have
been added to request for individual cpu or a cpumask.  The default
behaviour of PM QoS is maintained i.e, requests that do not specify a
type of the request will continue to be effected on all cores.  Requests
that want to specify an affinity of cpu(s) or an irq, can modify the PM
QoS request data structures by specifying the type of the request and
either the mask of the cpus or the IRQ number depending on the type.
Updating the request does not reset the type of the request.

The userspace sysfs interface does not support CPU/IRQ affinity.

Signed-off-by: Lina Iyer <ilina@codeaurora.org>
(cherry picked from commit 16cafdb44fb3a66a7d06936d775efe483ad62b7d)

Bug: 153463922
Test: build
Signed-off-by: Suren Baghdasaryan <surenb@google.com>
Change-Id: I1aad836a985fd303f2254fe607bb909a6b720dd5
2020-04-08 16:37:25 +00:00
Saravana Kannan
b55bfe2fd5 ANDROID: GKI: Bulk ABI update
Leaf changes summary: 2 artifacts changed
Changed leaf types summary: 2 leaf types 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

'struct devfreq at devfreq.h:148:1' changed:
  type size changed from 13824 to 14144 (in bits)
  2 data member insertions:
    'mutex devfreq::event_lock', at offset 384 (in bits) at devfreq.h:152:1
    'bool devfreq::dev_suspended', at offset 14080 (in bits) at devfreq.h:178:1
  there are data member changes:
    'device devfreq::dev' offset changed from 384 to 640 (in bits) (by +256 bits)
    'devfreq_dev_profile* devfreq::profile' offset changed from 6656 to 6912 (in bits) (by +256 bits)
    'const devfreq_governor* devfreq::governor' offset changed from 6720 to 6976 (in bits) (by +256 bits)
    'char devfreq::governor_name[16]' offset changed from 6784 to 7040 (in bits) (by +256 bits)
    'notifier_block devfreq::nb' offset changed from 6912 to 7168 (in bits) (by +256 bits)
    'delayed_work devfreq::work' offset changed from 7104 to 7360 (in bits) (by +256 bits)
    'unsigned long int devfreq::previous_freq' offset changed from 7808 to 8064 (in bits) (by +256 bits)
    'devfreq_dev_status devfreq::last_status' offset changed from 7872 to 8128 (in bits) (by +256 bits)
    'void* devfreq::data' offset changed from 8128 to 8384 (in bits) (by +256 bits)
    'unsigned long int devfreq::min_freq' offset changed from 8192 to 8448 (in bits) (by +256 bits)
    'unsigned long int devfreq::max_freq' offset changed from 8256 to 8512 (in bits) (by +256 bits)
    'unsigned long int devfreq::scaling_min_freq' offset changed from 8320 to 8576 (in bits) (by +256 bits)
    'unsigned long int devfreq::scaling_max_freq' offset changed from 8384 to 8640 (in bits) (by +256 bits)
    'bool devfreq::stop_polling' offset changed from 8448 to 8704 (in bits) (by +256 bits)
    'unsigned int devfreq::total_trans' offset changed from 8480 to 8736 (in bits) (by +256 bits)
    'unsigned int* devfreq::trans_table' offset changed from 8512 to 8768 (in bits) (by +256 bits)
    'unsigned long int* devfreq::time_in_state' offset changed from 8576 to 8832 (in bits) (by +256 bits)
    'unsigned long int devfreq::last_stat_updated' offset changed from 8640 to 8896 (in bits) (by +256 bits)
    'srcu_notifier_head devfreq::transition_notifier_list' offset changed from 8704 to 8960 (in bits) (by +256 bits)
  20 impacted interfaces:
    function devfreq* devfreq_add_device(device*, devfreq_dev_profile*, const char*, void*)
    function int devfreq_add_governor(devfreq_governor*)
    function void devfreq_interval_update(devfreq*, unsigned int*)
    function void devfreq_monitor_resume(devfreq*)
    function void devfreq_monitor_start(devfreq*)
    function void devfreq_monitor_stop(devfreq*)
    function void devfreq_monitor_suspend(devfreq*)
    function int devfreq_remove_device(devfreq*)
    function int devfreq_remove_governor(devfreq_governor*)
    function int devfreq_resume_device(devfreq*)
    function int devfreq_suspend_device(devfreq*)
    function devfreq* devm_devfreq_add_device(device*, devfreq_dev_profile*, const char*, void*)
    function thermal_cooling_device* of_devfreq_cooling_register(device_node*, devfreq*)
    function int ufshcd_dme_get_attr(ufs_hba*, u32, u32*, u8)
    function int ufshcd_dme_set_attr(ufs_hba*, u32, u8, u32, u8)
    function u32 ufshcd_get_local_unipro_ver(ufs_hba*)
    function int ufshcd_hold(ufs_hba*, bool)
    function void ufshcd_release(ufs_hba*)
    function void ufshcd_remove(ufs_hba*)
    function int update_devfreq(devfreq*)

'struct regmap_irq_chip at regmap.h:1138:1' changed:
  type size hasn't changed
  1 data member insertion:
    'unsigned int regmap_irq_chip::clear_ack', at offset 288 (in bits) at regmap.h:1148:1
  there are data member changes:
    'bool regmap_irq_chip::type_invert' offset changed from 288 to 320 (in bits) (by +32 bits)
    'int regmap_irq_chip::num_regs' offset changed from 320 to 352 (in bits) (by +32 bits)
  3 impacted interfaces:
    function int devm_regmap_add_irq_chip(device*, regmap*, int, int, int, const regmap_irq_chip*, regmap_irq_chip_data**)
    function void devm_regmap_del_irq_chip(device*, int, regmap_irq_chip_data*)
    function int regmap_irq_get_virq(regmap_irq_chip_data*, int)

Bug: 149430094
Signed-off-by: Saravana Kannan <saravanak@google.com>
Change-Id: I1ce004bc7d52ef153ef54be9feb7f32cd031288e
2020-04-08 00:38:26 -07:00
Rama Aparna Mallavarapu
4f9183cc24 ANDROID: GKI: PM/devfreq: Do not switch governors from sysfs when device is suspended
There is a possibility to switch the governors from sysfs even when the
device is in suspended state. This can cause a NOC error at times when
trying to access the device's monitor registers in a suspended state. This
change fixes this issue. Introduce a variable dev_suspended to know if
the device is in suspended state or not. Check if the device is suspended
before switching the governor from sysfs.

Change-Id: I15055aa51daa35272be4667e5bafb8ccd7933098
Signed-off-by: Rama Aparna Mallavarapu <aparnam@codeaurora.org>
Bug: 152343889
(cherry picked from commit 9c41437c072048a9487353b85a452114c4031659)
Signed-off-by: Saravana Kannan <saravanak@google.com>
2020-04-08 00:21:28 -07:00
Rama Aparna Mallavarapu
902ad8fa08 ANDROID: GKI: PM / devfreq: Fix race condition between suspend/resume and governor_store
There is a race condition when the event governor_store is being executed
from sysfs and the device issues a suspend. The devfreq data structures
would become stale when the suspend tries to access them in the middle
of the governor_store operation. Fix this issue by taking a lock around
suspend and resume operations so that these operations are not concurrent
with the other events from sysfs.

Also rename the sysfs_lock as event_lock since the same lock is used
for non sysfs operations like suspend and resume as well.

Change-Id: Ifa0e93915a920cec3e0429966328a1128d61098b
Signed-off-by: Rama Aparna Mallavarapu <aparnam@codeaurora.org>
Bug: 152343889
(cherry picked from commit 8bf200e7136a6896e429e9bfab116238c1d99be6)
Signed-off-by: Saravana Kannan <saravanak@google.com>
2020-04-08 00:21:28 -07:00
Jonathan Avila
8f43993c58 ANDROID: GKI: PM / devfreq: Introduce a sysfs lock
Currently, concurrent writes to sysfs entries leave the	possibility
for race conditions within the devfreq framework.  For example,
concurrently executing max_freq_store and governor_store can result
in attempting to perform an update_devfreq() before the new governor's
start handler can be executed.

A more concrete case is a race between polling_interval_store and
governor_store.  Because no lock is used after calling into the event
handler of the old governor and there's nothing preventing work from
being queued after the monitor is stopped, it's possible to
accidentally cause delayed work to be queued on the governor being
switched to.  This can be seen if you create two threads, one which
changes a device's governor between simple_ondemand and performance,
and one which changes its polling interval between 45 and 50.

All of these races can be addressed with the introduction of a lock
that prevents sysfs operations from interleaving in this fashion.

Change-Id: Ia6887dcb2d69dc2576837a6c09fed55a28943abc
Signed-off-by: Jonathan Avila <avilaj@codeaurora.org>
Signed-off-by: Rama Aparna Mallavarapu <aparnam@codeaurora.org>
Bug: 152343889
(cherry picked from commit 78fdd25c1abb1f23f43243f09c3d81cccaa844bc)
[saravanak Fixed some conflicts]
Signed-off-by: Saravana Kannan <saravanak@google.com>
2020-04-08 00:21:28 -07:00
Ramprasad Katkam
171d2c87ca ANDROID: GKI: regmap: irq: Add support to clear ack registers
WCD codec requires clear registers to be written '1' and
'0' for clearing interrupts. Add this support in regmap irq
to clear ack registers.

Change-Id: I399592fc0ee7f3a01a32267684a9be340076ffb1
Signed-off-by: Ramprasad Katkam <katkam@codeaurora.org>
Bug: 153500481
[saravanak Minor edit to commit text]
(cherry picked from commit 25401ed921044cafdf588efb2e6ba19e8454f14a)
Signed-off-by: Saravana Kannan <saravanak@google.com>
2020-04-08 00:21:27 -07:00
Alistair Delva
6b5a4bd4a4 ANDROID: GKI: Remove SCHED_AUTOGROUP
This feature is undesirable and not required by Android.

Bug: 153460450
Change-Id: I548bb44b9fecc90ba2589fb74b4e4693e639a8c9
Signed-off-by: Alistair Delva <adelva@google.com>
Signed-off-by: Will McVicker <willmcvicker@google.com>
2020-04-08 05:59:48 +00:00
Will McVicker
a4923652a4 ANDROID: ignore compiler tag __must_check for GENKSYMS
GENKSYMS shouldn't care about the __must_check compiler flag. So strip
it out for GENKSYMS.

Signed-off-by: Will McVicker <willmcvicker@google.com>
Bug: 153478475
Test: compile, check crc
Change-Id: I512639a4f719037728ffbfa48e7b766510c7d726
2020-04-07 21:31:57 +00:00
Hridya Valsaraju
28551438a1 ANDROID: GKI: Bulk update ABI
Leaf changes summary: 16 artifacts changed (1 filtered out)
Changed leaf types summary: 5 (1 filtered out) leaf types changed
Removed/Changed/Added functions summary: 0 Removed, 0 Changed, 11 Added functions
Removed/Changed/Added variables summary: 0 Removed, 0 Changed, 0 Added variable

11 Added functions:

  [A] 'function int br_dev_queue_push_xmit(net*, sock*, sk_buff*)'
  [A] 'function int br_forward_finish(net*, sock*, sk_buff*)'
  [A] 'function int br_handle_frame_finish(net*, sock*, sk_buff*)'
  [A] 'function snd_soc_component* soc_find_component(const device_node*, const char*)'
  [A] 'function int usb_sec_event_ring_cleanup(usb_device*, unsigned int)'
  [A] 'function int usb_sec_event_ring_setup(usb_device*, unsigned int)'
  [A] 'function int xhci_gen_setup(usb_hcd*, void ()*)'
  [A] 'function void xhci_init_driver(hc_driver*, const xhci_driver_overrides*)'
  [A] 'function int xhci_resume(xhci_hcd*, bool)'
  [A] 'function int xhci_run(usb_hcd*)'
  [A] 'function int xhci_suspend(xhci_hcd*, bool)'

Test: build
Bug: 149945768
Bug: 151372815
Change-Id: I7c4a209df0bdc60c56cbc4216d5dc84aeb485f71
Signed-off-by: Hridya Valsaraju <hridya@google.com>
2020-04-07 11:05:17 -07:00
Hridya Valsaraju
8c83a60c3b ANDROID: GKI: Fix ABI diff for struct thermal_cooling_device_ops
Adds members set/get_min_state() to struct
thermal_cooling_device_ops.

Also adds the field min_state_throttle to struct thermal_governor.

Test: build
Bug: 149945768
Change-Id: I085feb9d3b818dcf9754f0f624166c360593bce6
Signed-off-by: Ram Chandrasekar <rkumbako@codeaurora.org>
(cherry picked from commit 8a12149c264c7b871932ad90f76e5981452bb4bb)
[hridya: cherry-picked only the ABI diff]
Signed-off-by: Hridya Valsaraju <hridya@google.com>
2020-04-07 11:05:17 -07:00
Banajit Goswami
e000f4e8d5 ANDROID: GKI: ASoC: soc-core: export function to find components
Drivers may need to use the ASoC core function to
find out whether a particular component is already
registered with ALSA core or not.
Export the function so that drivers can use it outside
of the file.

Bug: 151372815
Test: build
Change-Id: I13e4a053de085974b0b53c392a9453e46f1aa66d
Signed-off-by: Banajit Goswami <bgoswami@codeaurora.org>
(cherry picked from commit fbcf71fe2dadcfbfe6b60f49534dd0312fd3b9d6)
Signed-off-by: Hridya Valsaraju <hridya@google.com>
2020-04-07 11:05:17 -07:00
Hridya Valsaraju
9159a8134c ANDROID: GKI: thermal: thermal_sys: Add configurable thermal trip points.
Modify enum thermal_trip_type to add configurable thermal
trip points of THERMAL_TRIP_CONFIGURABLE_HI,
THERMAL_TRIP_CONFIGURABLE_LOW, and THERMAL_TRIP_CRITICAL_LOW.

Bug: 149945768
Change-Id: I25c9c3bcfd58e44da5369187d1095559062f1860
Signed-off-by: Siddartha Mohanadoss <smohanad@codeaurora.org>
Signed-off-by: David Brown <davidb@codeaurora.org>
(cherry picked from commit 3f67fe6c0a924f23ba19033a0f55b7d82e268926)
[hridya: commit amended to only include ABI diff].
Signed-off-by: Hridya Valsaraju <hridya@google.com>
2020-04-07 11:05:17 -07:00
Eric Biggers
b30501efe9 ANDROID: fscrypt: fall back to filesystem-layer crypto when needed
When the filesystem is mounted with '-o inlinecrypt', make fscrypt fall
back to filesystem-layer crypto when inline crypto won't work, e.g. due
to the hardware not supporting the encryption algorithm.

When blk-crypto-fallback is disabled, this fixes '-o inlinecrypt' to not
break any fscrypt policies that would otherwise work.

This is needed for VtsKernelEncryptionTest to pass on some devices.

Bug: 137270441
Bug: 151100202
Test: 'atest vts_kernel_encryption_test' on Pixel 4 with the
      inline crypto patches backported, and also on Cuttlefish.
Change-Id: I3e730df4608efb12d7126d1a85faddcccb566764
Signed-off-by: Eric Biggers <ebiggers@google.com>
2020-04-07 17:57:41 +00:00
Eric Biggers
8f078b1b3a ANDROID: block: require drivers to declare supported crypto key type(s)
We need a way to tell which type of keys the inline crypto hardware
supports (standard, wrapped, or both), so that fallbacks can be used
when needed (either blk-crypto-fallback, or fscrypt fs-layer crypto).

We can't simply assume that

    keyslot_mgmt_ll_ops::derive_raw_secret == NULL

means only standard keys are supported and that

    keyslot_mgmt_ll_ops::derive_raw_secret != NULL

means that only wrapped keys are supported, because device-mapper
devices always implement this method.  Also, hardware might support both
types of keys.

Therefore, add a field keyslot_manager::features which contains a
bitmask of flags which indicate the supported types of keys.  Drivers
will need to fill this in.  This patch makes the UFS standard crypto
code set BLK_CRYPTO_FEATURE_STANDARD_KEYS, but UFS variant drivers may
need to set BLK_CRYPTO_FEATURE_WRAPPED_KEYS instead.

Then, make keyslot_manager_crypto_mode_supported() take the key type
into account.

Bug: 137270441
Bug: 151100202
Test: 'atest vts_kernel_encryption_test' on Pixel 4 with the
      inline crypto patches backported, and also on Cuttlefish.
Change-Id: Ied846c2767c1fd2f438792dcfd3649157e68b005
Signed-off-by: Eric Biggers <ebiggers@google.com>
2020-04-07 17:57:33 +00:00
Eric Biggers
ce1ccfb9ef ANDROID: block: make blk_crypto_start_using_mode() properly check for support
If blk-crypto-fallback is needed but is disabled by kconfig, make
blk_crypto_start_using_mode() return an error rather than succeeding.
Use ENOPKG, which matches the error code used by fscrypt when crypto API
support is missing with fs-layer encryption.

Also, if blk-crypto-fallback is needed but the algorithm is missing from
the kernel's crypto API, change the error code from ENOENT to ENOPKG.

This is needed for VtsKernelEncryptionTest to pass on some devices.

Bug: 137270441
Bug: 151100202
Test: 'atest vts_kernel_encryption_test' on Pixel 4 with the
      inline crypto patches backported, and also on Cuttlefish.
Change-Id: Iedf00ca8e48c74a5d4c40b12712f38738a04ef11
Signed-off-by: Eric Biggers <ebiggers@google.com>
2020-04-07 17:57:24 +00:00
Mark Salyzyn
0134f3d545 ANDROID: GKI: power: supply: format regression
Build error results in excess arguments provided from
commit 7c4bd0cdf4eff0dd6774183435fc8139743cd6e4
("power_supply: support for CHARGE_DISABLE")

Change introduced in partial cherry pick of the above in
commit 2d02a30a0b896e6ab970837cf54477550c34c31a
("ANDROID: GKI: power: supply: Add POWER_SUPPLY_PROP_CHARGE_DISABLE")

Removed excess unused argument.

Signed-off-by: Mark Salyzyn <salyzyn@google.com>
Cc: AleX Pelosi <apelosi@google.com>
Cc: Jack Wu <wjack@google.com>
Bug: 150789066
Change-Id: I5be743eecffa0be7b8ec4969963f0a283f5684c5
2020-04-07 17:08:46 +00:00
Subbaraman Narayanamurthy
9cbe2f0b9b ANDROID: GKI: kobject: increase number of kobject uevent pointers to 64
Power supply framework uses uevents to notify the power supply
change events to the userspace. Some power supplies have their
properties increasing thus overflowing the number of kobject
uevent pointers, triggering warning shown below.

[   10.577545] WARNING: CPU: 3 PID: 406 at kernel/lib/kobject_uevent.c:393 add_uevent_var+0xc0/0x100()
[   10.589680] add_uevent_var: too many keys
[   10.593809] Modules linked in:
[   10.596686] CPU: 3 PID: 406 Comm: kworker/3:2 Tainted: G        W      3.18.20-g5e99605-00057-gd18285f #603
[   10.606373] Hardware name: Qualcomm Technologies, Inc. MSM 8996 v3 + PMI8996 MTP (DT)
[   10.614188] Workqueue: events power_supply_changed_work
[   10.619366] Call trace:
[   10.621803] [<ffffffc00008881c>] dump_backtrace+0x0/0x130
[   10.627175] [<ffffffc00008895c>] show_stack+0x10/0x1c
[   10.632237] [<ffffffc000cc4d00>] dump_stack+0x74/0xb8
[   10.637253] [<ffffffc0000a0fec>] warn_slowpath_common+0x90/0xb8
[   10.643170] [<ffffffc0000a1060>] warn_slowpath_fmt+0x4c/0x58
[   10.648814] [<ffffffc00031121c>] add_uevent_var+0xbc/0x100
[   10.654259] [<ffffffc0003116f8>] kobject_uevent_env+0x498/0x5a8
[   10.660185] [<ffffffc000311814>] kobject_uevent+0xc/0x18
[   10.665457] [<ffffffc0007fd3c0>] power_supply_changed_work+0xb0/0xf0
[   10.671830] [<ffffffc0000b617c>] process_one_work+0x23c/0x3f4
[   10.677529] [<ffffffc0000b7338>] worker_thread+0x280/0x3a8
[   10.683017] [<ffffffc0000bb384>] kthread+0xe0/0xec

Fix this warning by increasing the number of kobject uevent
pointers from 32 to 64.

CRs-Fixed: 971954
Bug: 148872640
Signed-off-by: Subbaraman Narayanamurthy <subbaram@codeaurora.org>
Signed-off-by: Will McVicker <willmcvicker@google.com>
Signed-off-by: Saravana Kannan <saravanak@google.com>
[saravanak Increase uevent buffer size too]
(cherry picked from commit d09cd0dd75f95acedd3fa63d67ca3fbc92d21272)
Change-Id: Ide942d25006abd36ba7be945be397a535e91d970
2020-04-07 06:07:41 +00:00
Ram Chandrasekar
7e9cfddda4 ANDROID: GKI: drivers: video: backlight: Fix ABI diff for struct backlight_device
The following members are added to struct backlight_device:
struct thermal_cooling_device *cdev;
int thermal_brightness_limit;
int usr_brightness_req;

Change-Id: I1405ddd6c3cfff99cd84842d3773851168dcfe78
Signed-off-by: Ram Chandrasekar <rkumbako@codeaurora.org>
(cherry picked from commit 6cd31b3ff45ab44f3624e9139a0602e3a1a6f9ea)
[connoro: commit amended to include only ABI diff]
Bug: 153189857
Signed-off-by: Connor O'Brien <connoro@google.com>
2020-04-06 16:26:54 -07:00
Hemant Kumar
5dfdaa15ca ANDROID: GKI: usb: xhci: Add support for secondary interrupters
Implement APIs to dynamically allocate and free secondary
event rings based upon interrupter number. Also add exported
APIs in usb core layer which allows secondary event ring
management via remote processor entity.

Change-Id: I5ee7d44d6cad8e35e22d3c1a027a1eec5d208585
Signed-off-by: Hemant Kumar <hemantk@codeaurora.org>
Signed-off-by: Jack Pham <jackp@codeaurora.org>
Signed-off-by: Mayank Rana <mrana@codeaurora.org>
(cherry picked from commit 8d48fb820fb849cee2474354f75ef5a78044bd19)
[connoro: squashed the following commits:
          a44f0d73af95 usb: xhci: Clear event handler busy flag upon
          event ring cleanup
          a1504b40da0e usb: xhci: Acknowledge pending events in
          secondary event ring
          a7e7dd8a3499 usb: host: xhci: Fix bound check for
          interrupter number
          c4d9817a3cc6 usb: core: Allow secondary event ring clean
          upon disconnect
          576c1e1fe65b usb: host: xhci: Fix secondary event ring
          setup]
Bug: 151258428
Signed-off-by: Connor O'Brien <connoro@google.com>
2020-04-06 16:26:54 -07:00
Hemant Kumar
a6c834c026 ANDROID: GKI: usb: host: xhci: Add support for usb core indexing
Unique usb core id is used to differentiate between
different usb controllers.

[jackp@codeaurora.org: squashed with usb: host: Fix passing of
core-id property to xhci-plat]
Signed-off-by: Hemant Kumar <hemantk@codeaurora.org>
(cherry picked from commit 4c874ac2de1e09d148aeb47362e89f60b2743280)
[connoro: commit amended to include only the ABI diff]
Signed-off-by: Connor O'Brien <connoro@google.com>
Bug: 151258428
Change-Id: I736d5a99f51820e562311c988ea9fd09b3e7117b
2020-04-06 16:26:54 -07:00
Connor O'Brien
a1b446aa69 ANDROID: gki_defconfig: enable USB_XHCI_HCD
set CONFIG_USB_HCI_HCD=y for arm64 and x86 gki defconfigs

Bug: 151258428
Signed-off-by: Connor O'Brien <connoro@google.com>
Change-Id: I74e9a1fbc5efbbfacbe5046c1604afc05fad6bf9
2020-04-06 16:26:54 -07:00
Connor O'Brien
16bf78bd46 ANDROID: gki_defconfig: enable CONFIG_BRIDGE
Set CONFIG_BRIDGE=y for arm64 and x86 gki defconfigs

Bug: 151683251
Signed-off-by: Connor O'Brien <connoro@google.com>
Change-Id: Ifa34d56b2b8e497d3d696f8c80e137ffc4a93280
2020-04-06 16:26:54 -07:00
Suren Baghdasaryan
be4d1de13e ANDROID: GKI: Update ABI report
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 set_update_ipi_history_callback(void ()*)'

Bug: 152652820
Test: build
Signed-off-by: Suren Baghdasaryan <surenb@google.com>
Change-Id: Id1882b5c611fdcae4d1e9a694d636d09973542a5
2020-04-06 20:50:40 +00:00
Will McVicker
8d3bea1aed ANDROID: GKI: arm64: smp: Add set_update_ipi_history_callback
Provide set_update_ipi_history_callback allowing modules to register
a callback for monitoring interrupt rescheduling events.

Bug: 147267745
Bug: 152652820
Test: compile
Signed-off-by: Will McVicker <willmcvicker@google.com>
(cherry picked from commit 356d92323654c149933fa0eacaba7ab464381f8e)
[surenb: resolve merge conflicts]
Signed-off-by: Suren Baghdasaryan <surenb@google.com>
Change-Id: Icae6ba1f671967723667dc51f8337dbef03e89f3
2020-04-06 20:50:30 +00:00
Sami Tolvanen
166a538d15 ANDROID: kbuild: ensure __cfi_check is correctly aligned
On modules with no executable code, LLVM generates a __cfi_check stub,
but won't align it to page size as expected. This change ensures the
function is at the beginning of the .text section and correctly aligned
for the CFI shadow.

Bug: 148458318
Change-Id: I85ea31fa851bc23988f649b021b3ac7e9d9dcb38
Signed-off-by: Sami Tolvanen <samitolvanen@google.com>
2020-04-06 20:34:01 +00:00
Eric Biggers
a898a4764c FROMLIST: kmod: make request_module() return an error when autoloading is disabled
It's long been possible to disable kernel module autoloading completely
(while still allowing manual module insertion) by setting
/proc/sys/kernel/modprobe to the empty string.  This can be preferable
to setting it to a nonexistent file since it avoids the overhead of an
attempted execve(), avoids potential deadlocks, and avoids the call to
security_kernel_module_request() and thus on SELinux-based systems
eliminates the need to write SELinux rules to dontaudit module_request.

However, when module autoloading is disabled in this way,
request_module() returns 0.  This is broken because callers expect 0 to
mean that the module was successfully loaded.

Apparently this was never noticed because this method of disabling
module autoloading isn't used much, and also most callers don't use the
return value of request_module() since it's always necessary to check
whether the module registered its functionality or not anyway.  But
improperly returning 0 can indeed confuse a few callers, for example
get_fs_type() in fs/filesystems.c where it causes a WARNING to be hit:

	if (!fs && (request_module("fs-%.*s", len, name) == 0)) {
		fs = __get_fs_type(name, len);
		WARN_ONCE(!fs, "request_module fs-%.*s succeeded, but still no fs?\n", len, name);
	}

This is easily reproduced with:

	echo > /proc/sys/kernel/modprobe
	mount -t NONEXISTENT none /

It causes:

	request_module fs-NONEXISTENT succeeded, but still no fs?
	WARNING: CPU: 1 PID: 1106 at fs/filesystems.c:275 get_fs_type+0xd6/0xf0
	[...]

This should actually use pr_warn_once() rather than WARN_ONCE(), since
it's also user-reachable if userspace immediately unloads the module.
Regardless, request_module() should correctly return an error when it
fails.  So let's make it return -ENOENT, which matches the error when
the modprobe binary doesn't exist.

I've also sent patches to document and test this case.

Acked-by: Luis Chamberlain <mcgrof@kernel.org>
Reviewed-by: Jessica Yu <jeyu@kernel.org>
Reviewed-by: Kees Cook <keescook@chromium.org>
Cc: stable@vger.kernel.org
Cc: Alexei Starovoitov <ast@kernel.org>
Cc: Andrew Morton <akpm@linux-foundation.org>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: Jeff Vander Stoep <jeffv@google.com>
Cc: NeilBrown <neilb@suse.com>
Link: https://lore.kernel.org/r/20200318230515.171692-2-ebiggers@kernel.org
Bug: 151589316
Change-Id: I5e04f85e12a4f85da23e53bc11da1ade565abcd6
Signed-off-by: Eric Biggers <ebiggers@google.com>
2020-04-06 10:44:34 -07:00
Hridya Valsaraju
77333590dd ANDROID: GKI: Update ABI report
Leaf changes summary: 7 artifacts changed
Changed leaf types summary: 5 leaf types 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 void of_thermal_handle_trip(thermal_zone_device*)'
  [A] 'function void of_thermal_handle_trip_temp(thermal_zone_device*, int)'

Test: build
Bug: 149945768
Bug: 151372815
Change-Id: Iee07955ae17b629010acef55686e94fd56f23342
Signed-off-by: Hridya Valsaraju <hridya@google.com>
2020-04-06 07:28:09 -07:00
Hridya Valsaraju
cc7156f3c5 ANDROID: GKI: ARM64: dma-mapping: export symbol arch_setup_dma_ops
Fixes the following error on an allmodconfig build
ERROR: "arch_setup_dma_ops" [sound/soc/snd-soc-core.ko] undefined!

Bug: 151372815
Test: build
Change-Id: Id2fcb63664c8ac8879f2cf654ac1424577c46709
Signed-off-by: Hridya Valsaraju <hridya@google.com>
2020-04-06 07:17:39 -07:00
Hridya Valsaraju
195bdb8112 ANDROID: GKI: ARM: dma-mapping: export symbol arch_setup_dma_ops
Fixes the following error on an allmodconfig build
ERROR: "arch_setup_dma_ops" [sound/soc/snd-soc-core.ko] undefined!

Bug: 151372815
Test: build
Change-Id: Iddd3c5b79886e94b751840abad4a0652e3e8da3c
Signed-off-by: Hridya Valsaraju <hridya@google.com>
2020-04-06 07:17:39 -07:00
Sudheer Papothi
066f5e4cf4 ANDROID: GKI: ASoC: dapm: Avoid static route b/w cpu and codec dai
Currently ASoC core creates a static route b/w
playback/capture widgets of cpu and codec dai
if they are part of the same dai-link. However
this will cause codec path to get powered up
followed by the backend dai start during device
switch use-case where the front-end is not closed,
leading to audio playback failure if either bit-width
or sample rate is different.

Test: build
Bug: 151372815
Change-Id: Icd17677a73fdc4bd30e0918fcaa7e7f394245685
Signed-off-by: Sudheer Papothi <spapothi@codeaurora.org>
(cherry picked from commit 85a57fb9237c4021150e3a3ba9a274a7b78b79a5)
Signed-off-by: Hridya Valsaraju <hridya@google.com>
2020-04-06 07:17:39 -07:00
Banajit Goswami
645bb4d439 ANDROID: GKI: ASoC: pcm: Add support for hostless playback/capture
For playback/capture usecases in which host doesn't exchange
PCM data, audio driver creates hostless pcm devices.
This change squashes the below changes added to support
hostless pcm usecases-
   ASoC: core: Add support for no host mode
   ASoC: core: Update DMA mask for hostless pcm devices
   ASoC: pcm: increase the hostless buffer size
   soc: pcm: add arch_setup_dma_ops call

Test: build
Bug: 151372815
Change-Id: I82574c88847bcb9aa1a495c3690bba7f4e461979
Signed-off-by: Gopikrishnaiah Anandan <agopik@codeaurora.org>
Signed-off-by: Neema Shetty <nshetty@codeaurora.org>
Signed-off-by: Vidyakumar Athota <vathota@codeaurora.org>
Signed-off-by: Anish Kumar <kanish@codeaurora.org>
Signed-off-by: Shiv Maliyappanahalli <smaliyap@codeaurora.org>
Signed-off-by: Sudheer Papothi <spapothi@codeaurora.org>
Signed-off-by: Banajit Goswami <bgoswami@codeaurora.org>
Signed-off-by: Meng Wang <mwang@codeaurora.org>
(cherry picked from commit f156bb58247dfbfb91a6f5579f41b07e3c5e5b8b)
Signed-off-by: Hridya Valsaraju <hridya@google.com>
2020-04-06 07:17:39 -07:00
Liam Girdwood
aa5d0cdc64 ANDROID: GKI: ASoC: core - add hostless DAI support
Allow DAI's to be hostless so that no PCM data is sent between DAI
and CPU. This allows for power savings as there is no DMA or CPU
interaction required.

TODO: we shouldn't need to allocate a PAGE for a dummy DMA buffer.

Test: build
Bug: 151372815
Change-Id: I8947f1ad2c4a7013e92e21078b35e3cad332cf6f
Signed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Patrick Lai <plai@codeaurora.org>
Git-commit: b77e8f4fb684f8afd45d4276e3dba9edd4a0c4e0
Git-repo: https://source.codeaurora.org/quic/la/kernel/msm/log/?h=msm-2.6.38
[bgoswami@codeaurora.org: fix merge conflict by moving
 code to the right source file. Fix checkpatch errors
 for line over 80 character. Fix compilation errors.]
Signed-off-by: Banajit Goswami <bgoswami@codeaurora.org>
Signed-off-by: Meng Wang <mwang@codeaurora.org>
(cherry picked from commit c009f70138e1b66c6ae9597947b56a761f92bc0d)
Signed-off-by: Hridya Valsaraju <hridya@google.com>
2020-04-06 07:17:39 -07:00
Manaf Meethalavalappu Pallikunhi
4f04e3ea54 ANDROID: GKI: drivers: thermal: Resolve ABI diff for struct thermal_zone_device_ops
The following members are added to struct thermal_zone_device_ops:
int (*set_polling_delay)(struct thermal_zone_device *, int);
int (*set_passive_delay)(struct thermal_zone_device *, int);

Test: build and boot
Bug: 149945768
Signed-off-by: Manaf Meethalavalappu Pallikunhi <manafm@codeaurora.org>
(cherry picked from commit f68eb1a39e07a296ff4424c594c0fcc9b48240bc)
[hridya: commit amended to only include ABI diff]
Signed-off-by: Hridya Valsaraju <hridya@google.com>
Change-Id: Iad25d6585a35ecb71fdef36e27b27bece93a7c11
2020-04-06 07:17:39 -07:00
Ram Chandrasekar
10d3954a78 ANDROID: GKI: drivers: thermal: Add support for getting trip temperature
Add support for the sensor drivers using of-thermal interface to support
reading the trip temperature from the hardware using a callback. This
can be used in case, when the hardware works on a pre-configured
threshold different from the threshold set by software.

Test: build
Bug: 149945768
Change-Id: Ic5aaf1586b8dcbb3da0dd775718407c257b2064f
Signed-off-by: Ram Chandrasekar <rkumbako@codeaurora.org>
(cherry picked from commit 8a12149c264c7b871932ad90f76e5981452bb4bb)
[hridya: added an extra null pointer check, partial cherry-pick]
Signed-off-by: Hridya Valsaraju <hridya@google.com>
2020-04-06 07:17:39 -07:00
Hridya Valsaraju
5a7902fba4 ANDROID: GKI: Add functions of_thermal_handle_trip/of_thermal_handle_trip_temp
These APIs handle thermal trips from sensors.
These are required to reduce ABI diff.

Test: build
Bug: 149945768
Change-Id: I2ba4e91c954c9b13a323ec729b0c5a99f51e8fc3
(cherry picked from commit 8a12149c264c7b871932ad90f76e5981452bb4bb)
Signed-off-by: Ram Chandrasekar <rkumbako@codeaurora.org>
[hridya: commit amended to only include ABI diff, some pointer checks
added, also squashed 'c379a963e6ce9  drivers: thermal: Evaluate based on
trip temperature']
Signed-off-by: Hridya Valsaraju <hridya@google.com>
2020-04-06 07:17:39 -07:00
Manaf Meethalavalappu Pallikunhi
b078dd60e3 ANDROID: GKI: drivers: thermal: Add post suspend evaluate flag to thermal zone devicetree
Thermal core framework subscribes for suspend/resume notification.
On resume notification it re-evaluates each thermal zone for
temperature and cooling state update. For some devices,
a large number of thermal zones are enabled for different mitigations.
Re-evaluating each thermal zone during resume leads to multiple issues
including delay in back to back suspend resume scenario, power penalty
for frequent wake up due to re-setting trip threshold especially
during cold temperature usecases.

Add wake-capable-sensor property to thermal zone devicetree node to
denote that these sensors are wakeup capable. If a thermal zone has
this property defined, thermal framework ignores resume re-evaluation
and can service the threshold notification during the suspend/resume
path.

Test: build
Bug: 149945768
Change-Id: I07edf80ad29009378af4c70e750d01bde6f30806
Signed-off-by: Manaf Meethalavalappu Pallikunhi <manafm@codeaurora.org>
(cherry picked from commit a915ed479e624a1be30e34720b07207136fca0a9)
[hridya: added some pointer checks]
Signed-off-by: Hridya Valsaraju <hridya@google.com>
2020-04-06 07:17:38 -07:00
Martijn Coenen
30be971f3f UPSTREAM: loop: Only freeze block queue when needed.
__loop_update_dio() can be called as a part of loop_set_fd(), when the
block queue is not yet up and running; avoid freezing the block queue in
that case, since that is an expensive operation.

Bug: 148607611
Reviewed-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Chaitanya Kulkarni <chaitanya.kulkarni@wdc.com>
Signed-off-by: Martijn Coenen <maco@android.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
(cherry picked from commit 0fbcf57982)
Change-Id: I17d8de6b6b54a667703d60ea1c62449bb14331da
2020-04-04 16:33:15 +00:00
Martijn Coenen
456ce3aa8c UPSTREAM: loop: Only change blocksize when needed.
Return early in loop_set_block_size() if the requested block size is
identical to the one we already have; this avoids expensive calls to
freeze the block queue.

Bug: 148607611
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Martijn Coenen <maco@android.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
(cherry picked from commit 7e81f99afd)
Change-Id: I61778680579dbfeeb193133527a3926d376e0bac
2020-04-04 16:33:07 +00:00
Alistair Delva
182b38fc31 ANDROID: Fix wq fp check for CFI builds
A previous change added a test on the wrong config flag; rename
CFI to CFI_CLANG.

Bug: 145210207
Change-Id: Id8aead2eb2c75ad6442d10165f6cb86ccfb9c2f9
Signed-off-by: Alistair Delva <adelva@google.com>
2020-04-04 16:30:40 +00:00
Greg Kroah-Hartman
64f8bab38a ANDROID: GKI: update abi definition after CONFIG_DEBUG_LIST was enabled
Leaf changes summary: 2 artifacts changed
Changed leaf types summary: 0 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 bool __list_add_valid(list_head*, list_head*, list_head*)'
  [A] 'function bool __list_del_entry_valid(list_head*)'

Bug: 152470236
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Change-Id: Ieef7c50f4f5717a7f825a40617b97e0b3b7c9cd3
2020-04-04 14:02:31 +02:00
Greg Kroah-Hartman
d7304153b5 ANDROID: gki_defconfig: enable CONFIG_DEBUG_LIST
For lots of good security reasons, this config option needs to be
enabled

Bug: 152470236
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Change-Id: I96a88bbee9c4d17be97ed63262dbab2ef31fee79
(cherry picked from commit ab789e8750)
Signed-off-by: Will McVicker <willmcvicker@google.com>
2020-04-04 09:52:50 +00:00
Suren Baghdasaryan
b12d8a020f ANDROID: GKI: Update ABI definition
Leaf changes summary: 54 artifacts changed
Changed leaf types summary: 7 leaf types changed
Removed/Changed/Added functions summary: 0 Removed, 0 Changed, 47 Added functions
Removed/Changed/Added variables summary: 0 Removed, 0 Changed, 0 Added variable

47 Added functions:

  [A] 'function long int __ll_sc_atomic64_add_return(long int, atomic64_t*)'
  [A] 'function long int __ll_sc_atomic64_fetch_andnot(long int, atomic64_t*)'
  [A] 'function long int __ll_sc_atomic64_fetch_or(long int, atomic64_t*)'
  [A] 'function void __ll_sc_atomic64_xor(long int, atomic64_t*)'
  [A] 'function int __ll_sc_atomic_fetch_add(int, atomic_t*)'
  [A] 'function void __ll_sc_atomic_or(int, atomic_t*)'
  [A] 'function int __radix_tree_insert(radix_tree_root*, unsigned long int, unsigned int, void*)'
  [A] 'function int __skb_pad(sk_buff*, int, bool)'
  [A] 'function void _raw_read_lock_irq(rwlock_t*)'
  [A] 'function void _raw_read_unlock_irq(rwlock_t*)'
  [A] 'function unsigned long int _raw_write_lock_irqsave(rwlock_t*)'
  [A] 'function void _raw_write_unlock_irqrestore(rwlock_t*, unsigned long int)'
  [A] 'function sk_buff* alloc_skb_with_frags(unsigned long int, unsigned long int, int, int*, unsigned int)'
  [A] 'function int cpumask_next_and(int, const cpumask*, const cpumask*)'
  [A] 'function __poll_t datagram_poll(file*, socket*, poll_table*)'
  [A] 'function int devm_regulator_register_notifier(regulator*, notifier_block*)'
  [A] 'function int drm_crtc_vblank_get(drm_crtc*)'
  [A] 'function void drm_crtc_vblank_put(drm_crtc*)'
  [A] 'function gpio_desc* gpiod_get_from_of_node(device_node*, const char*, int, gpiod_flags, const char*)'
  [A] 'function int in_egroup_p(kgid_t)'
  [A] 'function ssize_t mipi_dsi_dcs_write(mipi_dsi_device*, u8, void*, size_t)'
  [A] 'function bool netlink_capable(const sk_buff*, int)'
  [A] 'function int of_n_addr_cells(device_node*)'
  [A] 'function int of_n_size_cells(device_node*)'
  [A] 'function void radix_tree_iter_delete(radix_tree_root*, radix_tree_iter*, void**)'
  [A] 'function void* radix_tree_lookup(const radix_tree_root*, unsigned long int)'
  [A] 'function void** radix_tree_next_chunk(const radix_tree_root*, radix_tree_iter*, unsigned int)'
  [A] 'function bool refcount_dec_not_one(refcount_struct*)'
  [A] 'function int regulator_get_voltage(regulator*)'
  [A] 'function int regulator_list_voltage_table(regulator_dev*, unsigned int)'
  [A] 'function int regulator_map_voltage_ascend(regulator_dev*, int, int)'
  [A] 'function int rtnl_register_module(module*, int, int, rtnl_doit_func, rtnl_dumpit_func, unsigned int)'
  [A] 'function int rtnl_unregister(int, int)'
  [A] 'function void save_stack_trace(stack_trace*)'
  [A] 'function void skb_condense(sk_buff*)'
  [A] 'function void skb_free_datagram(sock*, sk_buff*)'
  [A] 'function sk_buff* skb_recv_datagram(sock*, unsigned int, int, int*)'
  [A] 'function int skb_store_bits(sk_buff*, int, void*, int)'
  [A] 'function sk_buff* sock_alloc_send_skb(sock*, unsigned long int, int, int*)'
  [A] 'function int sock_create_kern(net*, int, int, int, socket**)'
  [A] 'function int sock_get_timestamp(sock*, timeval*)'
  [A] 'function int sock_no_shutdown(socket*, int)'
  [A] 'function bool timerqueue_add(timerqueue_head*, timerqueue_node*)'
  [A] 'function bool timerqueue_del(timerqueue_head*, timerqueue_node*)'
  [A] 'function timerqueue_node* timerqueue_iterate_next(timerqueue_node*)'
  [A] 'function config_group* usb_os_desc_prepare_interf_dir(config_group*, int, usb_os_desc**, char**, module*)'
  [A] 'function long int vfs_write(file*, const char*, unsigned long int, long long int*)'

Test: build
Bug: 152652820
Signed-off-by: Suren Baghdasaryan <surenb@google.com>
Change-Id: Ice5776d98cba4115220f38eeaff366f6b500af72
2020-04-03 15:35:27 -07:00
Suren Baghdasaryan
b33c657f7a ANDROID: GKI: remove condition causing sk_buff struct ABI differences
Remove condition for including struct sk_buff members based on
CONFIG_BRIDGE_NETFILTER config.

Bug: 151840548
Test: build
Signed-off-by: Suren Baghdasaryan <surenb@google.com>
Change-Id: Iee626843e107e8d64c3c6c4a1cc9c08f4e38f5af
Merged-In: Iee626843e107e8d64c3c6c4a1cc9c08f4e38f5af
2020-04-03 15:23:59 -07:00
Hridya Valsaraju
13630d0555 ANDROID: GKI: Export symbol arch_timer_mem_get_cval
Bug: 140652396
Test: build, boot

Signed-off-by: Hridya Valsaraju <hridya@google.com>
Bug: 152635062
Test: build
(cherry picked from commit e8c25076c4b591e186a4cf52faa7370d783f4475)
Signed-off-by: Suren Baghdasaryan <surenb@google.com>
Change-Id: I0260070ea060b5a56440760ed660373353329d6d
Merged-In: I0260070ea060b5a56440760ed660373353329d6d
2020-04-03 15:23:59 -07:00
Fenglin Wu
d892c9f357 ANDROID: GKI: pwm: core: Add option to config PWM duty/period with u64 data length
Currently, PWM core driver provides interfaces for configuring PWM
period and duty length in nanoseconds with an integer data type, so
the max period can be only set to ~2.147 seconds. Add interfaces which
can set PWM period and duty with u64 data type to remove this
limitation.

Signed-off-by: Fenglin Wu <fenglinw@codeaurora.org>
Bug: 152542675
Test: build and boot
(cherry picked from commit a691c36aef3f1123f41f12e8d508c5e3457fec7f)
[surenb: removed sysfs API changes, replaced 32-bit divisions with 64-bit
ones in the following drivers to fix allmodconfig build:
	drivers/clk/clk-pwm.c
	drivers/hwmon/pwm-fan.c
	drivers/pwm/pwm-clps711x.c
	drivers/pwm/pwm-sti.c
	drivers/pwm/pwm-sun4i.c
]
Signed-off-by: Suren Baghdasaryan <surenb@google.com>
Change-Id: I149c14b2d59b181344e7bb77393c64bcd9998de5
Merged-In: I149c14b2d59b181344e7bb77393c64bcd9998de5
2020-04-03 15:23:59 -07:00
Saravana Kannan
1f1eb8c282 ANDROID: Update ABI whitelist for qcom SoCs
Update the whitelist for qcom SoCs.

Bug: 149430094
Change-Id: I3bdf1a21e4d39a3be341bb65a968e48e99530e8a
Signed-off-by: Saravana Kannan <saravanak@google.com>
2020-04-03 12:15:01 -07:00
Paul Lawrence
ae41ea981b ANDROID: Incremental fs: Fix remount
Bug: 153017385
Test: incfs_test passes
Signed-off-by: Paul Lawrence <paullawrence@google.com>
Change-Id: I13f3a3c91d746d725e0e21b1e2bcfe0a64a13716
2020-04-03 17:25:37 +00:00
Paul Lawrence
e251cfe620 ANDROID: Incremental fs: Protect get_fill_block, and add a field
Since INCFS_IOC_GET_FILLED_BLOCKS potentially leaks information about usage
patterns, and is only useful to someone filling the file, best protect it in
the same way as INCFS_IOC_FILL_BLOCKS.

Add useful field data_block_out as well

Test: incfs_test passes
Bug: 152983639
Signed-off-by: Paul Lawrence <paullawrence@google.com>
Change-Id: I126a8cf711e56592479093e9aadbfd0e7f700752
2020-04-03 17:25:30 +00:00
Paul Lawrence
759d52ee9e ANDROID: Incremental fs: Fix crash polling 0 size read_log
When read log is 0 sized, we still need to init the wait queue to avoid
kernel panics if someone does decide to poll on the read log.

Test: Added test for this condition, incfs_test crashes
	With fix, incfs_test doesn't crash
Signed-off-by: Paul Lawrence <paullawrence@google.com>
Bug: 152909243
Change-Id: Ic3250523bb7ddb1839f8e95852c17103e5ffb782
2020-04-03 17:25:22 +00:00