Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 18ffdaaa authored by Srinivasarao P's avatar Srinivasarao P
Browse files

Merge android-4.19-stable.113 (2b82910d) into msm-4.19



* refs/heads/tmp-2b82910d:
  Reverting incrementalfs, power,usb and scheduler changes
  ANDROID: Incremental fs: Fix four resource bugs
  ANDROID: Bulk update the ABI xml based on the referenced bugs.
  ANDROID: GKI: block: resolve ABI diff when CONFIG_BLK_DEV_BSG is unset
  ANDROID: GKI: bfq-iosched: update struct elevator_mq_ops ABI
  ANDROID: GKI: locking/rwsem: add vendor field to struct rw_semaphore
  ANDROID: GKI: fs: add umount_end() function to struct super_operations
  ANDROID: GKI: perf: Add fields for CPU hotplug feature
  ANDROID: GKI: perf: Add field for struct perf_event
  ANDROID: GKI: cpuset: add field for task affinity for cpusets
  UPSTREAM: ubifs: wire up FS_IOC_GET_ENCRYPTION_NONCE
  UPSTREAM: f2fs: wire up FS_IOC_GET_ENCRYPTION_NONCE
  UPSTREAM: ext4: wire up FS_IOC_GET_ENCRYPTION_NONCE
  UPSTREAM: fscrypt: add FS_IOC_GET_ENCRYPTION_NONCE ioctl
  UPSTREAM: usb: raw_gadget: fix compilation warnings in uapi headers
  BACKPORT: usb: gadget: add raw-gadget interface
  UPSTREAM: usb: gadget: move choice ... endchoice to legacy/Kconfig
  UPSTREAM: ipv6: ndisc: add support for 'PREF64' dns64 prefix identifier
  ANDROID: GKI: Removed cuttlefish configs
  ANDROID: GKI: Removed cuttlefish configs
  ANDROID: clang: update to 10.0.5
  FROMLIST: arm64: define __alloc_zeroed_user_highpage
  ANDROID: Incremental fs: Add INCFS_IOC_GET_FILLED_BLOCKS
  ANDROID: Incremental fs: Fix two typos
  ANDROID: GKI: Update ABI
  ANDROID: GKI: power_supply: add more soc properties
  ANDROID: GKI: Update ABI
  ANDROID: GKI: google_battery: return string type for serial_number property
  ANDROID: GKI: power: supply: Add APSD based power-supply properties
  ANDROID: GKI: power: supply: Remove "Wipower" PSY type
  ANDROID: GKI: power: supply: Add support for HVDCP_3P5
  ANDROID: GKI: power_supply: Define Debug Accessory Mode
  ANDROID: GKI: power: supply: Add POWER_SUPPLY_PROP_AICL_*
  ANDROID: GKI: power: supply: Add POWER_SUPPLY_PROP_ALIGNMENT
  ANDROID: GKI: power_supply: Add CP_ISNS_SLAVE power supply property
  ANDROID: GKI: power_supply: add properties to report parallel connection topology
  ANDROID: GKI: power_supply: add POWER_SUPPLY_PROP_IRQ_STATUS property
  ANDROID: GKI: power: supply: add CHARGE_CHARGER_STATE property
  ANDROID: GKI: power: supply: Add POWER_SUPPLY_PROP_PTMC_ID
  ANDROID: GKI: power: supply: Add POWER_SUPPLY_PROP_OTG_FASTROLESWAP
  ANDROID: GKI: power: supply: Add VOLTAGE_STEP property
  ANDROID: GKI: power: supply: Add AICL_DONE parameter
  ANDROID: GKI: power_supply: Add operating frequency property
  ANDROID: GKI: power: supply: Add POWER_SUPPLY_PROP_CC_UAH
  ANDROID: GKI: power: supply: Add POWER_SUPPLY_PROP_VOLTAGE_FIFO
  ANDROID: GKI: power: supply: Add capacity and resistance estimates
  ANDROID: GKI: power_supply: Add vendor specific dead battery property
  ANDROID: GKI: power-supply: add ADAPTER_DETAILS power supply property
  ANDROID: GKI: power: supply: Add POWER_SUPPLY_PROP_CHARGE_DISABLE
  ANDROID: GKI: power: power_supply: Add property to display skin thermal status
  ANDROID: GKI: power_supply: Add properties to support PPS constant current(CC) mode
  ANDROID: GKI: power: power_supply: Add REAL_CAPACITY property
  ANDROID: GKI: power_supply: Add VOLTAGE_MAX_LIMIT power supply property
  ANDROID: GKI: power_supply: Add DC_RESET power-supply property
  ANDROID: GKI: power_supply: Add "THERM_ICL_LIMIT" property
  ANDROID: GKI: power_supply: add CHIP_VERSION property
  ANDROID: GKI: power-supply: Add VOLTAGE_VPH power supply property
  ANDROID: GKI: power_supply: Add SCALE_MODE_EN power-supply property
  ANDROID: GKI: power_supply: Add local extensions of string property names properly
  ANDROID: GKI: power_supply: add batt_age_level property
  ANDROID: GKI: power-supply: Add CC_SOC power supply property
  ANDROID: GKI: power_supply: add property to disable QC userspace optimizations
  ANDROID: GKI: power: power_supply: Add FG_RESET power supply property
  ANDROID: GKI: power_supply: Add power supply type "Charge Pump"
  ANDROID: GKI: power: supply: Add snapshot of power supply framework files
  ANDROID: GKI: power: power_supply: Add property CHARGE_COUNTER_EXT and 64-bit precision properties
  ANDROID: GKI: power: power_supply: add POWER_SUPPLY_PROP_CHARGE_ENABLED
  ANDROID: GKI: power: power_supply: add POWER_SUPPLY_PROP_USB_OTG
  ANDROID: GKI: power: power_supply: Add custom property for USB High Current mode
  UPSTREAM: coresight: Potential uninitialized variable in probe()
  ANDROID: GKI: Update ABI.
  ANDROID: GKI: Add API to create pagetable mappings.
  ANDROID: GKI: drivers: usb: Add functions usb_func_ep_queue/usb_func_wakeup
  ANDROID: GKI: Add API usb_ep_autoconfig_by_name
  ANDROID: GKI: usb: core: Add helper function to return controller id
  ANDROID: dm-bow: Fix free_show value is incorrect
  ANDROID: GKI: update ABI after fixing cfg80211_chan_def diff
  BACKPORT: nl80211: Add support for EDMG channels
  FROMGIT: sched/rt: cpupri_find: Trigger a full search as fallback
  FROMGIT: sched/rt: Remove unnecessary push for unfit tasks
  BACKPORT: FROMGIT: sched/rt: Allow pulling unfitting task
  FROMGIT: sched/rt: Optimize cpupri_find() on non-heterogenous systems
  FROMGIT: sched/rt: Re-instate old behavior in select_task_rq_rt()
  BACKPORT: FROMGIT: sched/rt: cpupri_find: Implement fallback mechanism for !fit case
  ANDROID: GKI: re-enable LTO, CFI and SCS

 Conflicts:
	arch/arm64/mm/mmu.c
	drivers/net/wireless/ath/wil6210/cfg80211.c
	drivers/usb/gadget/Kconfig
	include/linux/memblock.h
	include/linux/perf_event.h
	include/linux/rwsem.h
	include/uapi/linux/nl80211.h

Change-Id: I7aa8a1712c323fc5a2eced52a07bfb6df6996ba0
Signed-off-by: default avatarSrinivasarao P <spathi@codeaurora.org>
parents c161b2d1 de3445c0
Loading
Loading
Loading
Loading
+11 −0
Original line number Diff line number Diff line
@@ -633,6 +633,17 @@ from a passphrase or other low-entropy user credential.
FS_IOC_GET_ENCRYPTION_PWSALT is deprecated.  Instead, prefer to
generate and manage any needed salt(s) in userspace.

Getting a file's encryption nonce
---------------------------------

Since Linux v5.7, the ioctl FS_IOC_GET_ENCRYPTION_NONCE is supported.
On encrypted files and directories it gets the inode's 16-byte nonce.
On unencrypted files and directories, it fails with ENODATA.

This ioctl can be useful for automated tests which verify that the
encryption is being done correctly.  It is not needed for normal use
of fscrypt.

Adding keys
-----------

+61 −0
Original line number Diff line number Diff line
==============
USB Raw Gadget
==============

USB Raw Gadget is a kernel module that provides a userspace interface for
the USB Gadget subsystem. Essentially it allows to emulate USB devices
from userspace. Enabled with CONFIG_USB_RAW_GADGET. Raw Gadget is
currently a strictly debugging feature and shouldn't be used in
production, use GadgetFS instead.

Comparison to GadgetFS
~~~~~~~~~~~~~~~~~~~~~~

Raw Gadget is similar to GadgetFS, but provides a more low-level and
direct access to the USB Gadget layer for the userspace. The key
differences are:

1. Every USB request is passed to the userspace to get a response, while
   GadgetFS responds to some USB requests internally based on the provided
   descriptors. However note, that the UDC driver might respond to some
   requests on its own and never forward them to the Gadget layer.

2. GadgetFS performs some sanity checks on the provided USB descriptors,
   while Raw Gadget allows you to provide arbitrary data as responses to
   USB requests.

3. Raw Gadget provides a way to select a UDC device/driver to bind to,
   while GadgetFS currently binds to the first available UDC.

4. Raw Gadget uses predictable endpoint names (handles) across different
   UDCs (as long as UDCs have enough endpoints of each required transfer
   type).

5. Raw Gadget has ioctl-based interface instead of a filesystem-based one.

Userspace interface
~~~~~~~~~~~~~~~~~~~

To create a Raw Gadget instance open /dev/raw-gadget. Multiple raw-gadget
instances (bound to different UDCs) can be used at the same time. The
interaction with the opened file happens through the ioctl() calls, see
comments in include/uapi/linux/usb/raw_gadget.h for details.

The typical usage of Raw Gadget looks like:

1. Open Raw Gadget instance via /dev/raw-gadget.
2. Initialize the instance via USB_RAW_IOCTL_INIT.
3. Launch the instance with USB_RAW_IOCTL_RUN.
4. In a loop issue USB_RAW_IOCTL_EVENT_FETCH calls to receive events from
   Raw Gadget and react to those depending on what kind of USB device
   needs to be emulated.

Potential future improvements
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

- Implement ioctl's for setting/clearing halt status on endpoints.

- Reporting more events (suspend, resume, etc.) through
  USB_RAW_IOCTL_EVENT_FETCH.

- Support O_NONBLOCK I/O.
+65880 −66628

File changed.

Preview size limit exceeded, changes collapsed.

+3 −0
Original line number Diff line number Diff line
@@ -78,6 +78,9 @@ CONFIG_ARM64_CRYPTO=y
CONFIG_CRYPTO_SHA2_ARM64_CE=y
CONFIG_CRYPTO_AES_ARM64_CE_BLK=y
CONFIG_JUMP_LABEL=y
CONFIG_LTO_CLANG=y
CONFIG_CFI_CLANG=y
CONFIG_SHADOW_CALL_STACK=y
CONFIG_MODULES=y
CONFIG_MODULE_UNLOAD=y
CONFIG_MODVERSIONS=y
+4 −0
Original line number Diff line number Diff line
@@ -32,6 +32,10 @@ extern void __cpu_copy_user_page(void *to, const void *from,
extern void copy_page(void *to, const void *from);
extern void clear_page(void *to);

#define __alloc_zeroed_user_highpage(movableflags, vma, vaddr) \
	alloc_page_vma(GFP_HIGHUSER | __GFP_ZERO | movableflags, vma, vaddr)
#define __HAVE_ARCH_ALLOC_ZEROED_USER_HIGHPAGE

#define clear_user_page(addr,vaddr,pg)  __cpu_clear_user_page(addr, vaddr)
#define copy_user_page(to,from,vaddr,pg) __cpu_copy_user_page(to, from, vaddr)

Loading