d4414bc0e93d8da170fd0fc9fef65fe84015677d
78 Commits
| Author | SHA1 | Message | Date | |
|---|---|---|---|---|
|
|
9e5fcdf3d0 |
Merge android-4.19-stable (4.19.207) into android-msm-pixel-4.19-lts
Merge 4.19.207 into android-4.19-stable
Linux 4.19.207
s390/bpf: Fix 64-bit subtraction of the -0x80000000 constant
net: renesas: sh_eth: Fix freeing wrong tx descriptor
* ip_gre: validate csum_start only on pull
net/ipv4/ip_gre.c
qlcnic: Remove redundant unlock in qlcnic_pinit_from_rom
* fq_codel: reject silly quantum parameters
include/uapi/linux/pkt_sched.h
net/sched/sch_fq_codel.c
* netfilter: socket: icmp6: fix use-after-scope
net/ipv6/netfilter/nf_socket_ipv6.c
net: dsa: b53: Fix calculating number of switch ports
ARC: export clear_user_page() for modules
mtd: rawnand: cafe: Fix a resource leak in the error handling path of 'cafe_nand_probe()'
* PCI: Sync __pci_register_driver() stub for CONFIG_PCI=n
include/linux/pci.h
* KVM: arm64: Handle PSCI resets before userspace touches vCPU state
virt/kvm/arm/arm.c
* PCI: Fix pci_dev_str_match_path() alloc while atomic bug
drivers/pci/pci.c
mfd: axp20x: Update AXP288 volatile ranges
NTB: perf: Fix an error code in perf_setup_inbuf()
ethtool: Fix an error code in cxgb2.c
block, bfq: honor already-setup queue merges
net: usb: cdc_mbim: avoid altsetting toggling for Telit LN920
* PCI: Add ACS quirks for Cavium multi-function devices
drivers/pci/quirks.c
mfd: Don't use irq_create_mapping() to resolve a mapping
dt-bindings: mtd: gpmc: Fix the ECC bytes vs. OOB bytes equation
KVM: s390: index kvm->arch.idle_mask by vcpu_idx
* mm/memory_hotplug: use "unsigned long" for PFN in zone_for_pfn_range()
include/linux/memory_hotplug.h
mm/memory_hotplug.c
net: hns3: pad the short tunnel frame before sending to hardware
ibmvnic: check failover_pending in login response
qed: Handle management FW error
* tcp: fix tp->undo_retrans accounting in tcp_sacktag_one()
net/ipv4/tcp_input.c
* net: dsa: destroy the phylink instance on any error in dsa_slave_phy_setup
net/dsa/slave.c
* net/af_unix: fix a data-race in unix_dgram_poll
include/linux/skbuff.h
net/unix/af_unix.c
* events: Reuse value read using READ_ONCE instead of re-reading it
kernel/events/core.c
net/mlx5: Fix potential sleeping in atomic context
* perf machine: Initialize srcline string member in add_location struct
tools/perf/util/machine.c
* tipc: increase timeout in tipc_sk_enqueue()
net/tipc/socket.c
r6040: Restore MDIO clock frequency after MAC reset
* net/l2tp: Fix reference count leak in l2tp_udp_recv_core
net/l2tp/l2tp_core.c
* dccp: don't duplicate ccid when cloning dccp sock
net/dccp/minisocks.c
ptp: dp83640: don't define PAGE0
* net-caif: avoid user-triggerable WARN_ON(1)
net/caif/chnl_net.c
* tipc: fix an use-after-free issue in tipc_recvmsg
net/tipc/socket.c
x86/mm: Fix kern_addr_valid() to cope with existing but not present entries
* PCI: Add AMD GPU multi-function power dependencies
drivers/pci/quirks.c
PM: base: power: don't try to use non-existing RTC for storing data
* arm64/sve: Use correct size when reinitialising SVE state
arch/arm64/kernel/fpsimd.c
bnx2x: Fix enabling network interfaces without VFs
xen: reset legacy rtc flag for PV domU
dm thin metadata: Fix use-after-free in dm_bm_set_read_only
drm/amdgpu: Fix BUG_ON assert
platform/chrome: cros_ec_proto: Send command again when timeout occurs
* memcg: enable accounting for pids in nested pid namespaces
kernel/pid_namespace.c
* mm/hugetlb: initialize hugetlb_usage in mm_init
include/linux/hugetlb.h
kernel/fork.c
cpufreq: powernv: Fix init_chip_info initialization in numa=off
scsi: qla2xxx: Sync queue idx with queue_pair_map idx
scsi: BusLogic: Fix missing pr_cont() use
* ovl: fix BUG_ON() in may_delete() when called from ovl_cleanup()
fs/overlayfs/dir.c
parisc: fix crash with signals and alloca
net: w5100: check return value after calling platform_get_resource()
* net: fix NULL pointer reference in cipso_v4_doi_free
net/netlabel/netlabel_cipso_v4.c
ath9k: fix sleeping in atomic context
ath9k: fix OOB read ar9300_eeprom_restore_internal
parport: remove non-zero check on count
* ASoC: rockchip: i2s: Fixup config for DAIFMT_DSP_A/B
sound/soc/rockchip/rockchip_i2s.c
* ASoC: rockchip: i2s: Fix regmap_ops hang
sound/soc/rockchip/rockchip_i2s.c
usbip:vhci_hcd USB port can get stuck in the disabled state
usbip: give back URBs for unsent unlink requests during cleanup
usb: musb: musb_dsps: request_irq() after initializing musb
* Revert "USB: xhci: fix U1/U2 handling for hardware with XHCI_INTEL_HOST quirk set"
drivers/usb/host/xhci.c
* cifs: fix wrong release in sess_alloc_buffer() failed path
fs/cifs/sess.c
mmc: core: Return correct emmc response in case of ioctl error
* selftests/bpf: Enlarge select() timeout for test_maps
tools/testing/selftests/bpf/test_maps.c
mmc: rtsx_pci: Fix long reads when clock is prescaled
mmc: sdhci-of-arasan: Check return value of non-void funtions
* of: Don't allow __of_attached_node_sysfs() without CONFIG_SYSFS
drivers/of/kobj.c
* gfs2: Don't call dlm after protocol is unmounted
fs/gfs2/lock_dlm.c
staging: rts5208: Fix get_ms_information() heap buffer size
* rpc: fix gss_svc_init cleanup on failure
net/sunrpc/auth_gss/svcauth_gss.c
* tcp: enable data-less, empty-cookie SYN with TFO_SERVER_COOKIE_NOT_REQD
net/ipv4/tcp_fastopen.c
serial: sh-sci: fix break handling for sysrq
* Bluetooth: Fix handling of LE Enhanced Connection Complete
net/bluetooth/hci_event.c
ARM: tegra: tamonten: Fix UART pad setting
gpu: drm: amd: amdgpu: amdgpu_i2c: fix possible uninitialized-variable access in amdgpu_i2c_router_select_ddc_port()
* Bluetooth: avoid circular locks in sco_sock_connect
net/bluetooth/sco.c
* Bluetooth: schedule SCO timeouts with delayed_work
net/bluetooth/sco.c
net: ethernet: stmmac: Do not use unreachable() in ipq806x_gmac_probe()
arm64: dts: qcom: sdm660: use reg value for memory node
ARM: dts: imx53-ppd: Fix ACHC entry
media: tegra-cec: Handle errors of clk_prepare_enable()
media: TDA1997x: fix tda1997x_query_dv_timings() return value
* media: v4l2-dv-timings.c: fix wrong condition in two for-loops
drivers/media/v4l2-core/v4l2-dv-timings.c
media: imx258: Limit the max analogue gain to 480
media: imx258: Rectify mismatch of VTS value
* ASoC: Intel: bytcr_rt5640: Move "Platform Clock" routes to the maps for the matching in-/output
sound/soc/intel/boards/bytcr_rt5640.c
* bonding: 3ad: fix the concurrency between __bond_release_one() and bond_3ad_state_machine_handler()
drivers/net/bonding/bond_main.c
* Bluetooth: skip invalid hci_sync_conn_complete_evt
net/bluetooth/hci_event.c
ata: sata_dwc_460ex: No need to call phy_exit() befre phy_init()
* samples: bpf: Fix tracex7 error raised on the missing argument
samples/bpf/test_override_return.sh
samples/bpf/tracex7_user.c
staging: ks7010: Fix the initialization of the 'sleep_status' structure
serial: 8250_pci: make setup_port() parameters explicitly unsigned
hvsi: don't panic on tty_register_driver failure
xtensa: ISS: don't panic in rs_init
* serial: 8250: Define RX trigger levels for OxSemi 950 devices
include/uapi/linux/serial_reg.h
s390/jump_label: print real address in a case of a jump label bug
* flow_dissector: Fix out-of-bounds warnings
net/core/flow_dissector.c
* ipv4: ip_output.c: Fix out-of-bounds warning in ip_copy_addrs()
net/ipv4/ip_output.c
video: fbdev: riva: Error out if 'pixclock' equals zero
video: fbdev: kyro: Error out if 'pixclock' equals zero
video: fbdev: asiliantfb: Error out if 'pixclock' equals zero
* bpf/tests: Do not PASS tests without actually testing the result
lib/test_bpf.c
* bpf/tests: Fix copy-and-paste error in double word test
lib/test_bpf.c
drm/amd/amdgpu: Update debugfs link_settings output link_rate field in hex
tty: serial: jsm: hold port lock when reporting modem line changes
staging: board: Fix uninitialized spinlock when attaching genpd
* usb: gadget: composite: Allow bMaxPower=0 if self-powered
drivers/usb/gadget/composite.c
* usb: gadget: u_ether: fix a potential null pointer dereference
drivers/usb/gadget/function/u_ether.c
usb: host: fotg210: fix the actual_length of an iso packet
usb: host: fotg210: fix the endpoint's transactional opportunities calculation
* Smack: Fix wrong semantics in smk_access_entry()
security/smack/smack_access.c
* netlink: Deal with ESRCH error in nlmsg_notify()
net/netlink/af_netlink.c
video: fbdev: kyro: fix a DoS bug by restricting user input
ARM: dts: qcom: apq8064: correct clock names
iio: dac: ad5624r: Fix incorrect handling of an optional regulator.
* tipc: keep the skb in rcv queue until the whole data is read
net/tipc/socket.c
* PCI: Use pci_update_current_state() in pci_enable_device_flags()
drivers/pci/pci.c
crypto: mxs-dcp - Use sg_mapping_iter to copy data
media: dib8000: rewrite the init prbs logic
* userfaultfd: prevent concurrent API initialization
fs/userfaultfd.c
MIPS: Malta: fix alignment of the devicetree buffer
* f2fs: fix to unmap pages from userspace process in punch_hole()
fs/f2fs/file.c
* f2fs: fix to account missing .skipped_gc_rwsem
fs/f2fs/gc.c
* fscache: Fix cookie key hashing
fs/fscache/cookie.c
fs/fscache/internal.h
fs/fscache/main.c
platform/x86: dell-smbios-wmi: Add missing kfree in error-exit from run_smbios_call
scsi: qedi: Fix error codes in qedi_alloc_global_queues()
pinctrl: single: Fix error return code in pcs_parse_bits_in_pinctrl_entry()
openrisc: don't printk() unconditionally
powerpc/stacktrace: Include linux/delay.h
* vfio: Use config not menuconfig for VFIO_NOIOMMU
drivers/vfio/Kconfig
pinctrl: samsung: Fix pinctrl bank pin count
docs: Fix infiniband uverbs minor number
RDMA/iwcm: Release resources if iw_cm module initialization fails
* HID: input: do not report stylus battery state as "full"
drivers/hid/hid-input.c
PCI: aardvark: Fix masking and unmasking legacy INTx interrupts
PCI: aardvark: Increase polling delay to 1.5s while waiting for PIO response
PCI: xilinx-nwl: Enable the clock through CCF
* PCI: Return ~0 data on pciconfig_read() CAP_SYS_ADMIN failure
drivers/pci/syscall.c
* PCI: Restrict ASMedia ASM1062 SATA Max Payload Size Supported
drivers/pci/quirks.c
ARM: 9105/1: atags_to_fdt: don't warn about stack size
libata: add ATA_HORKAGE_NO_NCQ_TRIM for Samsung 860 and 870 SSDs
media: rc-loopback: return number of emitters rather than error
media: uvc: don't do DMA on stack
VMCI: fix NULL pointer dereference when unmapping queue pair
dm crypt: Avoid percpu_counter spinlock contention in crypt_page_alloc()
power: supply: max17042: handle fails of reading status register
block: bfq: fix bfq_set_next_ioprio_data()
* crypto: public_key: fix overflow during implicit conversion
include/crypto/public_key.h
* arm64: head: avoid over-mapping in map_memory
arch/arm64/include/asm/kernel-pgtable.h
arch/arm64/kernel/head.S
soc: aspeed: lpc-ctrl: Fix boundary check for mmap
* tools/thermal/tmon: Add cross compiling support
tools/thermal/tmon/Makefile
* bpf: Fix pointer arithmetic mask tightening under state pruning
include/linux/bpf_verifier.h
kernel/bpf/verifier.c
* bpf: verifier: Allocate idmap scratch in verifier env
include/linux/bpf_verifier.h
kernel/bpf/verifier.c
* bpf: Fix leakage due to insufficient speculative store bypass mitigation
include/linux/bpf_verifier.h
kernel/bpf/verifier.c
* bpf: Introduce BPF nospec instruction for mitigating Spectre v4
arch/arm64/net/bpf_jit_comp.c
include/linux/filter.h
kernel/bpf/core.c
kernel/bpf/disasm.c
* selftests/bpf: fix tests due to const spill/fill
tools/testing/selftests/bpf/test_verifier.c
* bpf: track spill/fill of constants
kernel/bpf/verifier.c
* selftests/bpf: Test variable offset stack access
tools/testing/selftests/bpf/test_verifier.c
* bpf: Sanity check max value for var_off stack access
kernel/bpf/verifier.c
* bpf: Reject indirect var_off stack access in unpriv mode
kernel/bpf/verifier.c
* bpf: Reject indirect var_off stack access in raw mode
kernel/bpf/verifier.c
* bpf: Support variable offset stack access from helpers
kernel/bpf/verifier.c
* bpf: correct slot_type marking logic to allow more stack slot sharing
kernel/bpf/verifier.c
tools/testing/selftests/bpf/test_verifier.c
* bpf/verifier: per-register parent pointers
include/linux/bpf_verifier.h
kernel/bpf/verifier.c
* 9p/xen: Fix end of loop tests for list_for_each_entry
net/9p/trans_xen.c
* include/linux/list.h: add a macro to test if entry is pointing to the head
include/linux/list.h
xen: fix setting of max_pfn in shared_info
powerpc/perf/hv-gpci: Fix counter value parsing
* PCI/MSI: Skip masking MSI-X on Xen PV
drivers/pci/msi.c
blk-zoned: allow BLKREPORTZONE without CAP_SYS_ADMIN
blk-zoned: allow zone management send operations without CAP_SYS_ADMIN
btrfs: reset replace target device to allocation state on close
rtc: tps65910: Correct driver module alias
clk: kirkwood: Fix a clocking boot regression
backlight: pwm_bl: Improve bootloader/kernel device handover
fbmem: don't allow too huge resolutions
* IMA: remove the dependency on CRYPTO_MD5
security/integrity/ima/Kconfig
* IMA: remove -Wmissing-prototypes warning
security/integrity/ima/ima_mok.c
KVM: x86: Update vCPU's hv_clock before back to guest when tsc_offset is adjusted
x86/resctrl: Fix a maybe-uninitialized build warning treated as error
* tty: Fix data race between tiocsti() and flush_to_ldisc()
drivers/tty/tty_io.c
* ubifs: report correct st_size for encrypted symlinks
fs/ubifs/file.c
* f2fs: report correct st_size for encrypted symlinks
fs/f2fs/namei.c
* ext4: report correct st_size for encrypted symlinks
fs/ext4/symlink.c
* fscrypt: add fscrypt_symlink_getattr() for computing st_size
fs/crypto/hooks.c
* netns: protect netns ID lookups with RCU
net/core/net_namespace.c
* ipv4: fix endianness issue in inet_rtm_getroute_build_skb()
net/ipv4/route.c
net: qualcomm: fix QCA7000 checksum handling
* net: sched: Fix qdisc_rate_table refcount leak when get tcf_block failed
net/sched/sch_cbq.c
* ipv4: make exception cache less predictible
net/ipv4/route.c
bcma: Fix memory leak for internally-handled cores
ath6kl: wmi: fix an error code in ath6kl_wmi_sync_point()
tty: serial: fsl_lpuart: fix the wrong mapbase value
usb: bdc: Fix an error handling path in 'bdc_probe()' when no suitable DMA config is available
usb: ehci-orion: Handle errors of clk_prepare_enable() in probe
i2c: mt65xx: fix IRQ check
* CIFS: Fix a potencially linear read overflow
fs/cifs/cifs_unicode.c
mmc: moxart: Fix issue with uninitialized dma_slave_config
mmc: dw_mmc: Fix issue with uninitialized dma_slave_config
i2c: s3c2410: fix IRQ check
i2c: iop3xx: fix deferred probing
* Bluetooth: add timeout sanity check to hci_inquiry
net/bluetooth/hci_core.c
usb: gadget: mv_u3d: request_irq() after initializing UDC
* mac80211: Fix insufficient headroom issue for AMSDU
net/mac80211/tx.c
usb: phy: tahvo: add IRQ check
usb: host: ohci-tmio: add IRQ check
* Bluetooth: Move shutdown callback before flushing tx and rx queue
net/bluetooth/hci_core.c
usb: phy: twl6030: add IRQ checks
usb: phy: fsl-usb: add IRQ check
usb: gadget: udc: at91: add IRQ check
drm/msm/dsi: Fix some reference counted resource leaks
* Bluetooth: fix repeated calls to sco_sock_kill
net/bluetooth/sco.c
arm64: dts: exynos: correct GIC CPU interfaces address range on Exynos7
drm/msm/dpu: make dpu_hw_ctl_clear_all_blendstages clear necessary LMs
* Bluetooth: increase BTNAMSIZ to 21 chars to fix potential buffer overflow
net/bluetooth/cmtp/cmtp.h
soc: qcom: smsm: Fix missed interrupts if state changes while masked
* PCI: PM: Enable PME if it can be signaled from D3cold
drivers/pci/pci.c
* PCI: PM: Avoid forcing PCI_D0 for wakeup reasons inconsistently
drivers/pci/pci.c
media: venus: venc: Fix potential null pointer dereference on pointer fmt
media: em28xx-input: fix refcount bug in em28xx_usb_disconnect
i2c: highlander: add IRQ check
* net: cipso: fix warnings in netlbl_cipsov4_add_std
net/netlabel/netlabel_cipso_v4.c
* tcp: seq_file: Avoid skipping sk during tcp_seek_last_pos
net/ipv4/tcp_ipv4.c
* Bluetooth: sco: prevent information leak in sco_conn_defer_accept()
net/bluetooth/sco.c
media: go7007: remove redundant initialization
media: dvb-usb: fix uninit-value in vp702x_read_mac_addr
media: dvb-usb: fix uninit-value in dvb_usb_adapter_dvb_init
* soc: rockchip: ROCKCHIP_GRF should not default to y, unconditionally
drivers/soc/rockchip/Kconfig
media: TDA1997x: enable EDID support
spi: sprd: Fix the wrong WDG_LOAD_VAL
* certs: Trigger creation of RSA module signing key if it's not an RSA key
certs/Makefile
crypto: qat - use proper type for vf_mask
clocksource/drivers/sh_cmt: Fix wrong setting if don't request IRQ for clock source channel
* lib/mpi: use kcalloc in mpi_resize
lib/mpi/mpiutil.c
spi: spi-pic32: Fix issue with uninitialized dma_slave_config
spi: spi-fsl-dspi: Fix issue with uninitialized dma_slave_config
m68k: emu: Fix invalid free in nfeth_cleanup()
* udf_get_extendedattr() had no boundary checks.
fs/udf/misc.c
* fcntl: fix potential deadlock for &fasync_struct.fa_lock
fs/fcntl.c
crypto: qat - do not export adf_iov_putmsg()
crypto: qat - fix naming for init/shutdown VF to PF notifications
crypto: qat - fix reuse of completion variable
crypto: qat - handle both source of interrupt in VF ISR
crypto: qat - do not ignore errors from enable_vf2pf_comms()
libata: fix ata_host_start()
s390/cio: add dev_busid sysfs entry for each subchannel
* power: supply: max17042_battery: fix typo in MAx17042_TOFF
include/linux/power/max17042_battery.h
nvme-rdma: don't update queue count when failing to set io queues
bcache: add proper error unwinding in bcache_device_init
* isofs: joliet: Fix iocharset=utf8 mount option
fs/isofs/inode.c
fs/isofs/isofs.h
fs/isofs/joliet.c
* udf: Check LVID earlier
fs/udf/super.c
* hrtimer: Avoid double reprogramming in __hrtimer_start_range_ns()
kernel/time/hrtimer.c
* sched/deadline: Fix missing clock update in migrate_task_rq_dl()
kernel/sched/deadline.c
crypto: omap-sham - clear dma flags only after omap_sham_update_dma_stop()
power: supply: axp288_fuel_gauge: Report register-address on readb / writeb errors
* sched/deadline: Fix reset_on_fork reporting of DL tasks
kernel/sched/deadline.c
kernel/sched/sched.h
crypto: mxs-dcp - Check for DMA mapping errors
* regmap: fix the offset of register error log
drivers/base/regmap/regmap.c
* locking/mutex: Fix HANDOFF condition
kernel/locking/mutex.c
* PCI: Call Max Payload Size-related fixup quirks early
drivers/pci/quirks.c
x86/reboot: Limit Dell Optiplex 990 quirk to early BIOS versions
usb: mtu3: fix the wrong HS mult value
usb: mtu3: use @mult for HS isoc or intr
usb: host: xhci-rcar: Don't reload firmware after the completion
* ALSA: usb-audio: Add registration quirk for JBL Quantum 800
sound/usb/quirks.c
Revert "btrfs: compression: don't try to compress if we don't have enough pages"
* mm/page_alloc: speed up the iteration of max_order
mm/page_alloc.c
net: ll_temac: Remove left-over debug message
powerpc/boot: Delete unneeded .globl _zimage_start
powerpc/module64: Fix comment in R_PPC64_ENTRY handling
crypto: talitos - reduce max key size for SEC1
* SUNRPC/nfs: Fix return value for nfs4_callback_compound()
fs/nfs/callback_xdr.c
include/linux/sunrpc/svc.h
net/sunrpc/svc.c
* ipv4/icmp: l3mdev: Perform icmp error route lookup on source device routing table (v2)
net/ipv4/icmp.c
USB: serial: mos7720: improve OOM-handling in read_mos_reg()
* igmp: Add ip_mc_list lock in ip_check_mc_rcu
net/ipv4/igmp.c
ARM: imx: fix missing 3rd argument in macro imx_mmdc_perf_init
ARM: imx: add missing clk_disable_unprepare()
media: stkwebcam: fix memory leak in stk_camera_probe
* clk: fix build warning for orphan_list
drivers/clk/clk.c
* ALSA: pcm: fix divide error in snd_pcm_lib_ioctl
sound/core/pcm_lib.c
ARM: 8918/2: only build return_address() if needed
* cryptoloop: add a deprecation warning
drivers/block/Kconfig
perf/x86/amd/ibs: Work around erratum #1197
perf/x86/intel/pt: Fix mask of num_address_ranges
qede: Fix memset corruption
net: macb: Add a NULL check on desc_ptp
qed: Fix the VF msix vectors flow
gpu: ipu-v3: Fix i.MX IPU-v3 offset calculations for (semi)planar U/V formats
xtensa: fix kconfig unmet dependency warning for HAVE_FUTEX_CMPXCHG
* ext4: fix race writing to an inline_data file while its xattrs are changing
fs/ext4/inline.c
Merge 4.19.206 into android-4.19-stable
Linux 4.19.206
* net: don't unconditionally copy_from_user a struct ifreq for socket ioctls
include/linux/netdevice.h
net/socket.c
Revert "floppy: reintroduce O_NDELAY fix"
KVM: x86/mmu: Treat NX as used (not reserved) for all !TDP shadow MMUs
fbmem: add margin check to fb_check_caps()
vt_kdsetmode: extend console locking
* net/rds: dma_map_sg is entitled to merge entries
net/rds/ib_frmr.c
drm/nouveau/disp: power down unused DP links during init
* drm: Copy drm_wait_vblank to user before returning
drivers/gpu/drm/drm_ioc32.c
qed: Fix null-pointer dereference in qed_rdma_create_qp()
qed: qed ll2 race condition fixes
vringh: Use wiov->used to check for read/write desc order
virtio_pci: Support surprise removal of virtio pci device
virtio: Improve vq->broken access to avoid any compiler optimization
* opp: remove WARN when no valid OPPs remain
drivers/opp/of.c
usb: gadget: u_audio: fix race condition on endpoint stop
net: hns3: fix get wrong pfc_en when query PFC configuration
net: marvell: fix MVNETA_TX_IN_PRGRS bit number
xgene-v2: Fix a resource leak in the error handling path of 'xge_probe()'
* ip_gre: add validation for csum_start
net/ipv4/ip_gre.c
e1000e: Fix the max snoop/no-snoop latency for 10M
IB/hfi1: Fix possible null-pointer dereference in _extend_sdma_tx_descs()
* usb: dwc3: gadget: Stop EP0 transfers during pullup disable
drivers/usb/dwc3/gadget.c
* usb: dwc3: gadget: Fix dwc3_calc_trbs_left()
drivers/usb/dwc3/gadget.c
USB: serial: option: add new VID/PID to support Fibocom FG150
Revert "USB: serial: ch341: fix character loss at high transfer rates"
can: usb: esd_usb2: esd_usb2_rx_event(): fix the interchange of the CAN RX and TX error counters
* once: Fix panic when module unload
include/linux/once.h
lib/once.c
* netfilter: conntrack: collect all entries in one cycle
net/netfilter/nf_conntrack_core.c
ARC: Fix CONFIG_STACKDEPOT
* bpf: Fix truncation handling for mod32 dst reg wrt zero
kernel/bpf/verifier.c
* bpf: Fix 32 bit src register truncation on div/mod
include/linux/filter.h
kernel/bpf/verifier.c
* bpf: Do not use ax register in interpreter on div/mod
kernel/bpf/core.c
* net: qrtr: fix another OOB Read in qrtr_endpoint_post
net/qrtr/qrtr.c
Bug: 201722185
Change-Id: Ib431fe52b39577bd49f14f4b28c49b54fa247c54
Signed-off-by: Wilson Sung <wilsonsung@google.com>
|
||
|
|
11156bde8d |
Merge 4.19.207 into android-4.19-stable
Changes in 4.19.207 ext4: fix race writing to an inline_data file while its xattrs are changing xtensa: fix kconfig unmet dependency warning for HAVE_FUTEX_CMPXCHG gpu: ipu-v3: Fix i.MX IPU-v3 offset calculations for (semi)planar U/V formats qed: Fix the VF msix vectors flow net: macb: Add a NULL check on desc_ptp qede: Fix memset corruption perf/x86/intel/pt: Fix mask of num_address_ranges perf/x86/amd/ibs: Work around erratum #1197 cryptoloop: add a deprecation warning ARM: 8918/2: only build return_address() if needed ALSA: pcm: fix divide error in snd_pcm_lib_ioctl clk: fix build warning for orphan_list media: stkwebcam: fix memory leak in stk_camera_probe ARM: imx: add missing clk_disable_unprepare() ARM: imx: fix missing 3rd argument in macro imx_mmdc_perf_init igmp: Add ip_mc_list lock in ip_check_mc_rcu USB: serial: mos7720: improve OOM-handling in read_mos_reg() ipv4/icmp: l3mdev: Perform icmp error route lookup on source device routing table (v2) SUNRPC/nfs: Fix return value for nfs4_callback_compound() crypto: talitos - reduce max key size for SEC1 powerpc/module64: Fix comment in R_PPC64_ENTRY handling powerpc/boot: Delete unneeded .globl _zimage_start net: ll_temac: Remove left-over debug message mm/page_alloc: speed up the iteration of max_order Revert "btrfs: compression: don't try to compress if we don't have enough pages" ALSA: usb-audio: Add registration quirk for JBL Quantum 800 usb: host: xhci-rcar: Don't reload firmware after the completion usb: mtu3: use @mult for HS isoc or intr usb: mtu3: fix the wrong HS mult value x86/reboot: Limit Dell Optiplex 990 quirk to early BIOS versions PCI: Call Max Payload Size-related fixup quirks early locking/mutex: Fix HANDOFF condition regmap: fix the offset of register error log crypto: mxs-dcp - Check for DMA mapping errors sched/deadline: Fix reset_on_fork reporting of DL tasks power: supply: axp288_fuel_gauge: Report register-address on readb / writeb errors crypto: omap-sham - clear dma flags only after omap_sham_update_dma_stop() sched/deadline: Fix missing clock update in migrate_task_rq_dl() hrtimer: Avoid double reprogramming in __hrtimer_start_range_ns() udf: Check LVID earlier isofs: joliet: Fix iocharset=utf8 mount option bcache: add proper error unwinding in bcache_device_init nvme-rdma: don't update queue count when failing to set io queues power: supply: max17042_battery: fix typo in MAx17042_TOFF s390/cio: add dev_busid sysfs entry for each subchannel libata: fix ata_host_start() crypto: qat - do not ignore errors from enable_vf2pf_comms() crypto: qat - handle both source of interrupt in VF ISR crypto: qat - fix reuse of completion variable crypto: qat - fix naming for init/shutdown VF to PF notifications crypto: qat - do not export adf_iov_putmsg() fcntl: fix potential deadlock for &fasync_struct.fa_lock udf_get_extendedattr() had no boundary checks. m68k: emu: Fix invalid free in nfeth_cleanup() spi: spi-fsl-dspi: Fix issue with uninitialized dma_slave_config spi: spi-pic32: Fix issue with uninitialized dma_slave_config lib/mpi: use kcalloc in mpi_resize clocksource/drivers/sh_cmt: Fix wrong setting if don't request IRQ for clock source channel crypto: qat - use proper type for vf_mask certs: Trigger creation of RSA module signing key if it's not an RSA key spi: sprd: Fix the wrong WDG_LOAD_VAL media: TDA1997x: enable EDID support soc: rockchip: ROCKCHIP_GRF should not default to y, unconditionally media: dvb-usb: fix uninit-value in dvb_usb_adapter_dvb_init media: dvb-usb: fix uninit-value in vp702x_read_mac_addr media: go7007: remove redundant initialization Bluetooth: sco: prevent information leak in sco_conn_defer_accept() tcp: seq_file: Avoid skipping sk during tcp_seek_last_pos net: cipso: fix warnings in netlbl_cipsov4_add_std i2c: highlander: add IRQ check media: em28xx-input: fix refcount bug in em28xx_usb_disconnect media: venus: venc: Fix potential null pointer dereference on pointer fmt PCI: PM: Avoid forcing PCI_D0 for wakeup reasons inconsistently PCI: PM: Enable PME if it can be signaled from D3cold soc: qcom: smsm: Fix missed interrupts if state changes while masked Bluetooth: increase BTNAMSIZ to 21 chars to fix potential buffer overflow drm/msm/dpu: make dpu_hw_ctl_clear_all_blendstages clear necessary LMs arm64: dts: exynos: correct GIC CPU interfaces address range on Exynos7 Bluetooth: fix repeated calls to sco_sock_kill drm/msm/dsi: Fix some reference counted resource leaks usb: gadget: udc: at91: add IRQ check usb: phy: fsl-usb: add IRQ check usb: phy: twl6030: add IRQ checks Bluetooth: Move shutdown callback before flushing tx and rx queue usb: host: ohci-tmio: add IRQ check usb: phy: tahvo: add IRQ check mac80211: Fix insufficient headroom issue for AMSDU usb: gadget: mv_u3d: request_irq() after initializing UDC Bluetooth: add timeout sanity check to hci_inquiry i2c: iop3xx: fix deferred probing i2c: s3c2410: fix IRQ check mmc: dw_mmc: Fix issue with uninitialized dma_slave_config mmc: moxart: Fix issue with uninitialized dma_slave_config CIFS: Fix a potencially linear read overflow i2c: mt65xx: fix IRQ check usb: ehci-orion: Handle errors of clk_prepare_enable() in probe usb: bdc: Fix an error handling path in 'bdc_probe()' when no suitable DMA config is available tty: serial: fsl_lpuart: fix the wrong mapbase value ath6kl: wmi: fix an error code in ath6kl_wmi_sync_point() bcma: Fix memory leak for internally-handled cores ipv4: make exception cache less predictible net: sched: Fix qdisc_rate_table refcount leak when get tcf_block failed net: qualcomm: fix QCA7000 checksum handling ipv4: fix endianness issue in inet_rtm_getroute_build_skb() netns: protect netns ID lookups with RCU fscrypt: add fscrypt_symlink_getattr() for computing st_size ext4: report correct st_size for encrypted symlinks f2fs: report correct st_size for encrypted symlinks ubifs: report correct st_size for encrypted symlinks tty: Fix data race between tiocsti() and flush_to_ldisc() x86/resctrl: Fix a maybe-uninitialized build warning treated as error KVM: x86: Update vCPU's hv_clock before back to guest when tsc_offset is adjusted IMA: remove -Wmissing-prototypes warning IMA: remove the dependency on CRYPTO_MD5 fbmem: don't allow too huge resolutions backlight: pwm_bl: Improve bootloader/kernel device handover clk: kirkwood: Fix a clocking boot regression rtc: tps65910: Correct driver module alias btrfs: reset replace target device to allocation state on close blk-zoned: allow zone management send operations without CAP_SYS_ADMIN blk-zoned: allow BLKREPORTZONE without CAP_SYS_ADMIN PCI/MSI: Skip masking MSI-X on Xen PV powerpc/perf/hv-gpci: Fix counter value parsing xen: fix setting of max_pfn in shared_info include/linux/list.h: add a macro to test if entry is pointing to the head 9p/xen: Fix end of loop tests for list_for_each_entry bpf/verifier: per-register parent pointers bpf: correct slot_type marking logic to allow more stack slot sharing bpf: Support variable offset stack access from helpers bpf: Reject indirect var_off stack access in raw mode bpf: Reject indirect var_off stack access in unpriv mode bpf: Sanity check max value for var_off stack access selftests/bpf: Test variable offset stack access bpf: track spill/fill of constants selftests/bpf: fix tests due to const spill/fill bpf: Introduce BPF nospec instruction for mitigating Spectre v4 bpf: Fix leakage due to insufficient speculative store bypass mitigation bpf: verifier: Allocate idmap scratch in verifier env bpf: Fix pointer arithmetic mask tightening under state pruning tools/thermal/tmon: Add cross compiling support soc: aspeed: lpc-ctrl: Fix boundary check for mmap arm64: head: avoid over-mapping in map_memory crypto: public_key: fix overflow during implicit conversion block: bfq: fix bfq_set_next_ioprio_data() power: supply: max17042: handle fails of reading status register dm crypt: Avoid percpu_counter spinlock contention in crypt_page_alloc() VMCI: fix NULL pointer dereference when unmapping queue pair media: uvc: don't do DMA on stack media: rc-loopback: return number of emitters rather than error libata: add ATA_HORKAGE_NO_NCQ_TRIM for Samsung 860 and 870 SSDs ARM: 9105/1: atags_to_fdt: don't warn about stack size PCI: Restrict ASMedia ASM1062 SATA Max Payload Size Supported PCI: Return ~0 data on pciconfig_read() CAP_SYS_ADMIN failure PCI: xilinx-nwl: Enable the clock through CCF PCI: aardvark: Increase polling delay to 1.5s while waiting for PIO response PCI: aardvark: Fix masking and unmasking legacy INTx interrupts HID: input: do not report stylus battery state as "full" RDMA/iwcm: Release resources if iw_cm module initialization fails docs: Fix infiniband uverbs minor number pinctrl: samsung: Fix pinctrl bank pin count vfio: Use config not menuconfig for VFIO_NOIOMMU powerpc/stacktrace: Include linux/delay.h openrisc: don't printk() unconditionally pinctrl: single: Fix error return code in pcs_parse_bits_in_pinctrl_entry() scsi: qedi: Fix error codes in qedi_alloc_global_queues() platform/x86: dell-smbios-wmi: Add missing kfree in error-exit from run_smbios_call fscache: Fix cookie key hashing f2fs: fix to account missing .skipped_gc_rwsem f2fs: fix to unmap pages from userspace process in punch_hole() MIPS: Malta: fix alignment of the devicetree buffer userfaultfd: prevent concurrent API initialization media: dib8000: rewrite the init prbs logic crypto: mxs-dcp - Use sg_mapping_iter to copy data PCI: Use pci_update_current_state() in pci_enable_device_flags() tipc: keep the skb in rcv queue until the whole data is read iio: dac: ad5624r: Fix incorrect handling of an optional regulator. ARM: dts: qcom: apq8064: correct clock names video: fbdev: kyro: fix a DoS bug by restricting user input netlink: Deal with ESRCH error in nlmsg_notify() Smack: Fix wrong semantics in smk_access_entry() usb: host: fotg210: fix the endpoint's transactional opportunities calculation usb: host: fotg210: fix the actual_length of an iso packet usb: gadget: u_ether: fix a potential null pointer dereference usb: gadget: composite: Allow bMaxPower=0 if self-powered staging: board: Fix uninitialized spinlock when attaching genpd tty: serial: jsm: hold port lock when reporting modem line changes drm/amd/amdgpu: Update debugfs link_settings output link_rate field in hex bpf/tests: Fix copy-and-paste error in double word test bpf/tests: Do not PASS tests without actually testing the result video: fbdev: asiliantfb: Error out if 'pixclock' equals zero video: fbdev: kyro: Error out if 'pixclock' equals zero video: fbdev: riva: Error out if 'pixclock' equals zero ipv4: ip_output.c: Fix out-of-bounds warning in ip_copy_addrs() flow_dissector: Fix out-of-bounds warnings s390/jump_label: print real address in a case of a jump label bug serial: 8250: Define RX trigger levels for OxSemi 950 devices xtensa: ISS: don't panic in rs_init hvsi: don't panic on tty_register_driver failure serial: 8250_pci: make setup_port() parameters explicitly unsigned staging: ks7010: Fix the initialization of the 'sleep_status' structure samples: bpf: Fix tracex7 error raised on the missing argument ata: sata_dwc_460ex: No need to call phy_exit() befre phy_init() Bluetooth: skip invalid hci_sync_conn_complete_evt bonding: 3ad: fix the concurrency between __bond_release_one() and bond_3ad_state_machine_handler() ASoC: Intel: bytcr_rt5640: Move "Platform Clock" routes to the maps for the matching in-/output media: imx258: Rectify mismatch of VTS value media: imx258: Limit the max analogue gain to 480 media: v4l2-dv-timings.c: fix wrong condition in two for-loops media: TDA1997x: fix tda1997x_query_dv_timings() return value media: tegra-cec: Handle errors of clk_prepare_enable() ARM: dts: imx53-ppd: Fix ACHC entry arm64: dts: qcom: sdm660: use reg value for memory node net: ethernet: stmmac: Do not use unreachable() in ipq806x_gmac_probe() Bluetooth: schedule SCO timeouts with delayed_work Bluetooth: avoid circular locks in sco_sock_connect gpu: drm: amd: amdgpu: amdgpu_i2c: fix possible uninitialized-variable access in amdgpu_i2c_router_select_ddc_port() ARM: tegra: tamonten: Fix UART pad setting Bluetooth: Fix handling of LE Enhanced Connection Complete serial: sh-sci: fix break handling for sysrq tcp: enable data-less, empty-cookie SYN with TFO_SERVER_COOKIE_NOT_REQD rpc: fix gss_svc_init cleanup on failure staging: rts5208: Fix get_ms_information() heap buffer size gfs2: Don't call dlm after protocol is unmounted of: Don't allow __of_attached_node_sysfs() without CONFIG_SYSFS mmc: sdhci-of-arasan: Check return value of non-void funtions mmc: rtsx_pci: Fix long reads when clock is prescaled selftests/bpf: Enlarge select() timeout for test_maps mmc: core: Return correct emmc response in case of ioctl error cifs: fix wrong release in sess_alloc_buffer() failed path Revert "USB: xhci: fix U1/U2 handling for hardware with XHCI_INTEL_HOST quirk set" usb: musb: musb_dsps: request_irq() after initializing musb usbip: give back URBs for unsent unlink requests during cleanup usbip:vhci_hcd USB port can get stuck in the disabled state ASoC: rockchip: i2s: Fix regmap_ops hang ASoC: rockchip: i2s: Fixup config for DAIFMT_DSP_A/B parport: remove non-zero check on count ath9k: fix OOB read ar9300_eeprom_restore_internal ath9k: fix sleeping in atomic context net: fix NULL pointer reference in cipso_v4_doi_free net: w5100: check return value after calling platform_get_resource() parisc: fix crash with signals and alloca ovl: fix BUG_ON() in may_delete() when called from ovl_cleanup() scsi: BusLogic: Fix missing pr_cont() use scsi: qla2xxx: Sync queue idx with queue_pair_map idx cpufreq: powernv: Fix init_chip_info initialization in numa=off mm/hugetlb: initialize hugetlb_usage in mm_init memcg: enable accounting for pids in nested pid namespaces platform/chrome: cros_ec_proto: Send command again when timeout occurs drm/amdgpu: Fix BUG_ON assert dm thin metadata: Fix use-after-free in dm_bm_set_read_only xen: reset legacy rtc flag for PV domU bnx2x: Fix enabling network interfaces without VFs arm64/sve: Use correct size when reinitialising SVE state PM: base: power: don't try to use non-existing RTC for storing data PCI: Add AMD GPU multi-function power dependencies x86/mm: Fix kern_addr_valid() to cope with existing but not present entries tipc: fix an use-after-free issue in tipc_recvmsg net-caif: avoid user-triggerable WARN_ON(1) ptp: dp83640: don't define PAGE0 dccp: don't duplicate ccid when cloning dccp sock net/l2tp: Fix reference count leak in l2tp_udp_recv_core r6040: Restore MDIO clock frequency after MAC reset tipc: increase timeout in tipc_sk_enqueue() perf machine: Initialize srcline string member in add_location struct net/mlx5: Fix potential sleeping in atomic context events: Reuse value read using READ_ONCE instead of re-reading it net/af_unix: fix a data-race in unix_dgram_poll net: dsa: destroy the phylink instance on any error in dsa_slave_phy_setup tcp: fix tp->undo_retrans accounting in tcp_sacktag_one() qed: Handle management FW error ibmvnic: check failover_pending in login response net: hns3: pad the short tunnel frame before sending to hardware mm/memory_hotplug: use "unsigned long" for PFN in zone_for_pfn_range() KVM: s390: index kvm->arch.idle_mask by vcpu_idx dt-bindings: mtd: gpmc: Fix the ECC bytes vs. OOB bytes equation mfd: Don't use irq_create_mapping() to resolve a mapping PCI: Add ACS quirks for Cavium multi-function devices net: usb: cdc_mbim: avoid altsetting toggling for Telit LN920 block, bfq: honor already-setup queue merges ethtool: Fix an error code in cxgb2.c NTB: perf: Fix an error code in perf_setup_inbuf() mfd: axp20x: Update AXP288 volatile ranges PCI: Fix pci_dev_str_match_path() alloc while atomic bug KVM: arm64: Handle PSCI resets before userspace touches vCPU state PCI: Sync __pci_register_driver() stub for CONFIG_PCI=n mtd: rawnand: cafe: Fix a resource leak in the error handling path of 'cafe_nand_probe()' ARC: export clear_user_page() for modules net: dsa: b53: Fix calculating number of switch ports netfilter: socket: icmp6: fix use-after-scope fq_codel: reject silly quantum parameters qlcnic: Remove redundant unlock in qlcnic_pinit_from_rom ip_gre: validate csum_start only on pull net: renesas: sh_eth: Fix freeing wrong tx descriptor s390/bpf: Fix 64-bit subtraction of the -0x80000000 constant Linux 4.19.207 Signed-off-by: Greg Kroah-Hartman <gregkh@google.com> Change-Id: I18108cb47ba9e95838ebe55aaabe34de345ee846 |
||
|
|
598e89bf33 |
Merge android-4.19-stable (4.19.171) into android-msm-pixel-4.19-lts
Merge 4.19.171 into android-4.19-stable
Linux 4.19.171
net: dsa: b53: fix an off by one in checking "vlan->vid"
* net: Disable NETIF_F_HW_TLS_RX when RXCSUM is disabled
net/core/dev.c
net: mscc: ocelot: allow offloading of bridge on top of LAG
* ipv6: set multicast flag on the multicast route
net/ipv6/addrconf.c
* net_sched: reject silly cell_log in qdisc_get_rtab()
net/sched/sch_api.c
net_sched: avoid shift-out-of-bounds in tcindex_set_parms()
* ipv6: create multicast route with RTPROT_KERNEL
net/ipv6/addrconf.c
* udp: mask TOS bits in udp_v4_early_demux()
net/ipv4/udp.c
kasan: fix incorrect arguments passing in kasan_add_zero_shadow
kasan: fix unaligned address is unhandled in kasan_remove_zero_shadow
* skbuff: back tiny skbs with kmalloc() in __netdev_alloc_skb() too
net/core/skbuff.c
sh_eth: Fix power down vs. is_opened flag ordering
sh: dma: fix kconfig dependency for G2_DMA
* netfilter: rpfilter: mask ecn bits before fib lookup
net/ipv4/netfilter/ipt_rpfilter.c
* driver core: Extend device_is_dependent()
drivers/base/core.c
xhci: tegra: Delay for disabling LFPS detector
* xhci: make sure TRB is fully written before giving it to the controller
drivers/usb/host/xhci-ring.c
* usb: bdc: Make bdc pci driver depend on BROKEN
drivers/usb/gadget/udc/bdc/Kconfig
* usb: udc: core: Use lock when write to soft_connect
drivers/usb/gadget/udc/core.c
usb: gadget: aspeed: fix stop dma register setting.
* USB: ehci: fix an interrupt calltrace error
drivers/usb/host/ehci-hub.c
* ehci: fix EHCI host controller initialization sequence
drivers/usb/host/ehci-hcd.c
serial: mvebu-uart: fix tx lost characters at power off
stm class: Fix module init return on allocation failure
intel_th: pci: Add Alder Lake-P support
irqchip/mips-cpu: Set IPI domain parent chip
iio: ad5504: Fix setting power-down state
can: peak_usb: fix use after free bugs
can: vxcan: vxcan_xmit: fix use after free bug
can: dev: can_restart: fix use after free bug
selftests: net: fib_tests: remove duplicate log test
platform/x86: intel-vbtn: Drop HP Stream x360 Convertible PC 11 from allow-list
i2c: octeon: check correct size of maximum RECV_LEN packet
scsi: megaraid_sas: Fix MEGASAS_IOC_FIRMWARE regression
drm/nouveau/kms/nv50-: fix case where notifier buffer is at offset 0
drm/nouveau/mmu: fix vram heap sizing
drm/nouveau/i2c/gm200: increase width of aux semaphore owner fields
drm/nouveau/privring: ack interrupts the same way as RM
drm/nouveau/bios: fix issue shadowing expansion ROMs
* xen: Fix event channel callback via INTX/GSI
include/xen/xenbus.h
clk: tegra30: Add hda clock default rates to clock driver
* HID: Ignore battery for Elan touchscreen on ASUS UX550
drivers/hid/hid-ids.h
drivers/hid/hid-input.c
riscv: Fix kernel time_init()
scsi: qedi: Correct max length of CHAP secret
* scsi: ufs: Correct the LUN used in eh_device_reset_handler() callback
drivers/scsi/ufs/ufshcd.c
ASoC: Intel: haswell: Add missing pm_ops
* drm/atomic: put state on error path
drivers/gpu/drm/drm_atomic_helper.c
dm integrity: fix a crash if "recalculate" used without "internal_hash"
* dm: avoid filesystem lookup in dm_get_dev_t()
drivers/md/dm-table.c
mmc: sdhci-xenon: fix 1.8v regulator stabilization
mmc: core: don't initialize block size from ext_csd if not present
btrfs: fix lockdep splat in btrfs_recover_relocation
ACPI: scan: Make acpi_bus_get_device() clear return pointer on error
ALSA: hda/via: Add minimum mute flag
ALSA: seq: oss: Fix missing error check in snd_seq_oss_synth_make_info()
i2c: bpmp-tegra: Ignore unknown I2C_M flags
* Revert "ANDROID: Incremental fs: RCU locks instead of mutex for pending_reads."
fs/incfs/data_mgmt.c
fs/incfs/data_mgmt.h
* Revert "ANDROID: Incremental fs: Fix minor bugs"
fs/incfs/data_mgmt.c
fs/incfs/vfs.c
* Revert "ANDROID: Incremental fs: dentry_revalidate should not return -EBADF."
fs/incfs/vfs.c
* Revert "ANDROID: Incremental fs: Remove annoying pr_debugs"
fs/incfs/data_mgmt.c
* Revert "ANDROID: Incremental fs: Remove unnecessary dependencies"
fs/incfs/Kconfig
* Revert "ANDROID: Incremental fs: Use R/W locks to read/write segment blockmap."
fs/incfs/data_mgmt.c
fs/incfs/data_mgmt.h
fs/incfs/vfs.c
Revert "ANDROID: Incremental fs: Stress tool"
Revert "ANDROID: Incremental fs: Adding perf test"
Revert "ANDROID: Incremental fs: Allow running a single test"
* Revert "ANDROID: Incremental fs: Fix incfs to work on virtio-9p"
fs/incfs/format.c
fs/incfs/vfs.c
* Revert "ANDROID: Incremental fs: Don't allow renaming .index directory."
fs/incfs/vfs.c
* Revert "ANDROID: Incremental fs: Create mapped file"
fs/incfs/data_mgmt.c
fs/incfs/data_mgmt.h
fs/incfs/format.c
fs/incfs/format.h
fs/incfs/vfs.c
include/uapi/linux/incrementalfs.h
* Revert "ANDROID: Incremental fs: Add UID to pending_read"
fs/incfs/data_mgmt.c
fs/incfs/data_mgmt.h
fs/incfs/main.c
fs/incfs/vfs.c
include/uapi/linux/incrementalfs.h
* Revert "ANDROID: Incremental fs: Separate pseudo-file code"
fs/incfs/Makefile
fs/incfs/pseudo_files.c
fs/incfs/pseudo_files.h
fs/incfs/vfs.c
fs/incfs/vfs.h
* Revert "ANDROID: Incremental fs: Add .blocks_written file"
fs/incfs/data_mgmt.c
fs/incfs/data_mgmt.h
fs/incfs/pseudo_files.c
fs/incfs/pseudo_files.h
include/uapi/linux/incrementalfs.h
* Revert "ANDROID: Incremental fs: Remove attributes from file"
fs/incfs/data_mgmt.c
fs/incfs/format.c
fs/incfs/format.h
fs/incfs/pseudo_files.c
* Revert "ANDROID: Incremental fs: Remove back links and crcs"
fs/incfs/format.c
fs/incfs/format.h
* Revert "ANDROID: Incremental fs: Remove block HASH flag"
fs/incfs/format.c
fs/incfs/format.h
* Revert "ANDROID: Incremental fs: Make compatible with existing files"
fs/incfs/format.c
fs/incfs/format.h
* Revert "ANDROID: Incremental fs: Add INCFS_IOC_GET_BLOCK_COUNT"
fs/incfs/data_mgmt.c
fs/incfs/data_mgmt.h
fs/incfs/format.c
fs/incfs/format.h
fs/incfs/vfs.c
include/uapi/linux/incrementalfs.h
* Revert "ANDROID: Incremental fs: Add hash block counts to IOC_IOCTL_GET_BLOCK_COUNT"
fs/incfs/data_mgmt.c
fs/incfs/data_mgmt.h
fs/incfs/format.c
fs/incfs/format.h
fs/incfs/vfs.c
include/uapi/linux/incrementalfs.h
* Revert "ANDROID: Incremental fs: Fix filled block count from get filled blocks"
fs/incfs/data_mgmt.c
fs/incfs/data_mgmt.h
fs/incfs/format.c
fs/incfs/format.h
fs/incfs/pseudo_files.c
fs/incfs/vfs.c
fs/incfs/vfs.h
* Revert "ANDROID: Incremental fs: Fix uninitialized variable"
fs/incfs/vfs.c
* Revert "ANDROID: Incremental fs: Fix dangling else"
fs/incfs/data_mgmt.c
* Revert "ANDROID: Incremental fs: Add .incomplete folder"
fs/incfs/data_mgmt.c
fs/incfs/data_mgmt.h
fs/incfs/pseudo_files.c
fs/incfs/vfs.c
* Revert "ANDROID: Incremental fs: Add per UID read timeouts"
fs/incfs/data_mgmt.c
fs/incfs/data_mgmt.h
fs/incfs/pseudo_files.c
fs/incfs/vfs.c
include/uapi/linux/incrementalfs.h
* Revert "ANDROID: Incremental fs: Fix misuse of cpu_to_leXX and poll return"
fs/incfs/format.c
fs/incfs/pseudo_files.c
Revert "ANDROID: Incremental fs: Fix read_log_test which failed sporadically"
* Revert "ANDROID: Incremental fs: Initialize mount options correctly"
fs/incfs/vfs.c
* Revert "ANDROID: Incremental fs: Small improvements"
fs/incfs/data_mgmt.c
fs/incfs/data_mgmt.h
fs/incfs/format.c
fs/incfs/format.h
fs/incfs/pseudo_files.c
fs/incfs/vfs.c
* Revert "ANDROID: Incremental fs: Add zstd compression support"
fs/incfs/Kconfig
fs/incfs/data_mgmt.c
fs/incfs/data_mgmt.h
fs/incfs/format.h
include/uapi/linux/incrementalfs.h
* Revert "ANDROID: Incremental fs: Add zstd feature flag"
fs/incfs/main.c
include/uapi/linux/incrementalfs.h
* Revert "ANDROID: Incremental fs: Add v2 feature flag"
fs/incfs/main.c
include/uapi/linux/incrementalfs.h
* Revert "ANDROID: Incremental fs: Change per UID timeouts to microseconds"
fs/incfs/data_mgmt.c
fs/incfs/data_mgmt.h
fs/incfs/pseudo_files.c
fs/incfs/vfs.c
include/uapi/linux/incrementalfs.h
Revert "ANDROID: Incremental fs: Fix incfs_test use of atol, open"
* Revert "ANDROID: Incremental fs: Set credentials before reading/writing"
fs/incfs/data_mgmt.c
fs/incfs/format.c
fs/incfs/format.h
fs/incfs/pseudo_files.c
ANDROID: GKI: Update ABI for clang bump
ANDROID: clang: update to 12.0.1
Revert "ANDROID: enable LLVM_IAS=1 for clang's integrated assembler for x86_64"
ANDROID: enable LLVM_IAS=1 for clang's integrated assembler for x86_64
Merge 4.19.170 into android-4.19-stable
Linux 4.19.170
spi: cadence: cache reference clock rate during probe
* net: ipv6: Validate GSO SKB before finish IPv6 processing
net/ipv6/ip6_output.c
* net: skbuff: disambiguate argument and member for skb_list_walk_safe helper
include/linux/skbuff.h
* net: introduce skb_list_walk_safe for skb segment walking
include/linux/skbuff.h
* tipc: fix NULL deref in tipc_link_xmit()
net/tipc/link.c
rxrpc: Fix handling of an unsupported token type in rxrpc_read()
* net: avoid 32 x truesize under-estimation for tiny skbs
net/core/skbuff.c
* net: sit: unregister_netdevice on newlink's error path
net/ipv6/sit.c
net: stmmac: Fixed mtu channged by cache aligned
rxrpc: Call state should be read with READ_ONCE() under some circumstances
net: dcb: Accept RTM_GETDCB messages carrying set-like DCB commands
net: dcb: Validate netlink message in DCB handler
* esp: avoid unneeded kmap_atomic call
net/ipv4/esp4.c
net/ipv6/esp6.c
rndis_host: set proper input size for OID_GEN_PHYSICAL_MEDIUM request
net: mvpp2: Remove Pause and Asym_Pause support
netxen_nic: fix MSI/MSI-x interrupts
* udp: Prevent reuseport_select_sock from reading uninitialized socks
net/core/sock_reuseport.c
nfsd4: readdirplus shouldn't return parent of export
crypto: x86/crc32c - fix building with clang ias
* dm integrity: fix flush with external metadata device
drivers/md/dm-bufio.c
include/linux/dm-bufio.h
* compiler.h: Raise minimum version of GCC to 5.1 for arm64
include/linux/compiler-gcc.h
* usb: ohci: Make distrust_firmware param default to false
drivers/usb/host/ohci-hcd.c
ANDROID: GKI: Update the ABI xml and symbol list
* ANDROID: GKI: genirq: export `kstat_irqs_usr` for watchdog
kernel/irq/irqdesc.c
* ANDROID: GKI: soc: qcom: export `irq_stack_ptr`
arch/arm64/kernel/irq.c
* ANDROID: ASoC: core: add locked version of soc_find_component
sound/soc/soc-core.c
* ANDROID: dm-user: Fix the list walk-and-delete code
drivers/md/dm-user.c
Merge 4.19.169 into android-4.19-stable
Linux 4.19.169
* kbuild: enforce -Werror=return-type
Makefile
* netfilter: nf_nat: Fix memleak in nf_nat_init
net/netfilter/nf_nat_core.c
* netfilter: conntrack: fix reading nf_conntrack_buckets
net/netfilter/nf_conntrack_standalone.c
ALSA: fireface: Fix integer overflow in transmit_midi_msg()
ALSA: firewire-tascam: Fix integer overflow in midi_port_work()
* dm: eliminate potential source of excessive kernel log noise
drivers/md/dm.c
net: sunrpc: interpret the return value of kstrtou32 correctly
* mm, slub: consider rest of partial list if acquire_slab() fails
mm/slub.c
RDMA/mlx5: Fix wrong free of blue flame register on error
RDMA/usnic: Fix memleak in find_free_vf_and_create_qp_grp
* ext4: fix superblock checksum failure when setting password salt
fs/ext4/ioctl.c
NFS: nfs_igrab_and_active must first reference the superblock
NFS/pNFS: Fix a leak of the layout 'plh_outstanding' counter
pNFS: Mark layout for return if return-on-close was not sent
NFS4: Fix use-after-free in trace_event_raw_event_nfs4_set_lock
ASoC: Intel: fix error code cnl_set_dsp_D0()
ASoC: meson: axg-tdm-interface: fix loopback
* dump_common_audit_data(): fix racy accesses to ->d_name
security/lsm_audit.c
ima: Remove __init annotation from ima_pcrread()
ARM: picoxcell: fix missing interrupt-parent properties
drm/msm: Call msm_init_vram before binding the gpu
* ACPI: scan: add stub acpi_create_platform_device() for !CONFIG_ACPI
include/linux/acpi.h
net: ethernet: fs_enet: Add missing MODULE_LICENSE
* misdn: dsp: select CONFIG_BITREVERSE
drivers/isdn/mISDN/Kconfig
arch/arc: add copy_user_page() to <asm/page.h> to fix build error on ARC
bfq: Fix computation of shallow depth
ethernet: ucc_geth: fix definition and size of ucc_geth_tx_global_pram
btrfs: fix transaction leak and crash after RO remount caused by qgroup rescan
ARC: build: add boot_targets to PHONY
ARC: build: add uImage.lzma to the top-level target
ARC: build: remove non-existing bootpImage from KBUILD_IMAGE
* ext4: fix bug for rename with RENAME_WHITEOUT
fs/ext4/namei.c
* r8152: Add Lenovo Powered USB-C Travel Hub
drivers/net/usb/cdc_ether.c
drivers/net/usb/r8152.c
dm integrity: fix the maximum number of arguments
* dm snapshot: flush merged data before committing metadata
drivers/md/dm-snap.c
mm/hugetlb: fix potential missing huge page size info
ACPI: scan: Harden acpi_device_add() against device ID overflows
MIPS: relocatable: fix possible boot hangup with KASLR enabled
MIPS: boot: Fix unaligned access with CONFIG_MIPS_RAW_APPENDED_DTB
* tracing/kprobes: Do the notrace functions check without kprobes on ftrace
kernel/trace/Kconfig
x86/hyperv: check cpu mask after interrupt has been disabled
* ASoC: dapm: remove widget from dirty list on free
sound/soc/soc-dapm.c
* Revert "BACKPORT: FROMGIT: mm: improve mprotect(R|W) efficiency on pages referenced once"
mm/mprotect.c
Merge 4.19.168 into android-4.19-stable
Linux 4.19.168
* regmap: debugfs: Fix a reversed if statement in regmap_debugfs_init()
drivers/base/regmap/regmap-debugfs.c
* net: drop bogus skb with CHECKSUM_PARTIAL and offset beyond end of trimmed packet
net/core/skbuff.c
* block: fix use-after-free in disk_part_iter_next
block/genhd.c
KVM: arm64: Don't access PMCR_EL0 when no PMU is available
* wan: ds26522: select CONFIG_BITREVERSE
drivers/net/wan/Kconfig
* regmap: debugfs: Fix a memory leak when calling regmap_attach_dev
drivers/base/regmap/regmap-debugfs.c
net/mlx5e: Fix two double free cases
net/mlx5e: Fix memleak in mlx5e_create_l2_table_groups
iommu/intel: Fix memleak in intel_irq_remapping_alloc
* lightnvm: select CONFIG_CRC32
drivers/lightnvm/Kconfig
* block: rsxx: select CONFIG_CRC32
drivers/block/Kconfig
* wil6210: select CONFIG_CRC32
drivers/net/wireless/ath/wil6210/Kconfig
dmaengine: xilinx_dma: fix mixed_enum_type coverity warning
dmaengine: xilinx_dma: fix incompatible param warning in _child_probe()
dmaengine: xilinx_dma: check dma_async_device_register return value
dmaengine: mediatek: mtk-hsdma: Fix a resource leak in the error handling path of the probe function
spi: stm32: FIFO threshold level - fix align packet size
cpufreq: powernow-k8: pass policy rather than use cpufreq_cpu_get()
i2c: sprd: use a specific timeout to avoid system hang up issue
ARM: OMAP2+: omap_device: fix idling of devices during probe
HID: wacom: Fix memory leakage caused by kfifo_alloc
iio: imu: st_lsm6dsx: fix edge-trigger interrupts
iio: imu: st_lsm6dsx: flip irq return logic
spi: pxa2xx: Fix use-after-free on unbind
drm/i915: Fix mismatch between misplaced vma check and vma insert
* vmlinux.lds.h: Add PGO and AutoFDO input sections
include/asm-generic/vmlinux.lds.h
x86/resctrl: Don't move a task to the same resource group
x86/resctrl: Use an IPI instead of task_work_add() to update PQR_ASSOC MSR
chtls: Fix chtls resources release sequence
chtls: Added a check to avoid NULL pointer dereference
chtls: Replace skb_dequeue with skb_peek
chtls: Fix panic when route to peer not configured
chtls: Remove invalid set_tcb call
chtls: Fix hardware tid leak
* net: ipv6: fib: flush exceptions when purging route
net/ipv6/ip6_fib.c
* net: fix pmtu check in nopmtudisc mode
net/ipv4/ip_tunnel.c
* net: ip: always refragment ip defragmented packets
net/ipv4/ip_output.c
net/sonic: Fix some resource leaks in error handling paths
net: vlan: avoid leaks on register_vlan_dev() failures
net: stmmac: dwmac-sun8i: Balance internal PHY power
net: stmmac: dwmac-sun8i: Balance internal PHY resource references
net: hns3: fix the number of queues actually used by ARQ
* net: cdc_ncm: correct overhead in delayed_ndp_size
drivers/net/usb/cdc_ncm.c
* BACKPORT: FROMGIT: mm: improve mprotect(R|W) efficiency on pages referenced once
mm/mprotect.c
* ANDROID: dm-user: fix typo in channel_free
drivers/md/dm-user.c
Merge 4.19.167 into android-4.19-stable
* ANDROID: dm-user: Add some missing static
drivers/md/dm-user.c
Linux 4.19.167
scsi: target: Fix XCOPY NAA identifier lookup
KVM: x86: fix shift out of bounds reported by UBSAN
x86/mtrr: Correct the range check before performing MTRR type lookups
netfilter: xt_RATEEST: reject non-null terminated string from userspace
netfilter: ipset: fix shift-out-of-bounds in htable_bits()
* netfilter: x_tables: Update remaining dereference to RCU
net/ipv4/netfilter/arp_tables.c
net/ipv4/netfilter/ip_tables.c
net/ipv6/netfilter/ip6_tables.c
xen/pvh: correctly setup the PV EFI interface for dom0
* Revert "device property: Keep secondary firmware node secondary by type"
drivers/base/core.c
btrfs: send: fix wrong file path when there is an inode with a pending rmdir
ALSA: hda/realtek - Fix speaker volume control on Lenovo C940
ALSA: hda/conexant: add a new hda codec CX11970
ALSA: hda/via: Fix runtime PM for Clevo W35xSS
x86/mm: Fix leak of pmd ptlock
USB: serial: keyspan_pda: remove unused variable
* usb: gadget: configfs: Fix use-after-free issue with udc_name
drivers/usb/gadget/configfs.c
* usb: gadget: configfs: Preserve function ordering after bind failure
drivers/usb/gadget/configfs.c
* usb: gadget: Fix spinlock lockup on usb_function_deactivate
drivers/usb/gadget/composite.c
USB: gadget: legacy: fix return error code in acm_ms_bind()
* usb: gadget: u_ether: Fix MTU size mismatch with RX packet size
drivers/usb/gadget/function/u_ether.c
usb: gadget: function: printer: Fix a memory leak for interface descriptor
usb: gadget: f_uac2: reset wMaxPacketSize
* usb: gadget: select CONFIG_CRC32
drivers/usb/gadget/Kconfig
* ALSA: usb-audio: Fix UBSAN warnings for MIDI jacks
sound/usb/midi.c
USB: usblp: fix DMA to stack
USB: yurex: fix control-URB timeout handling
USB: serial: option: add Quectel EM160R-GL
USB: serial: option: add LongSung M5710 module support
USB: serial: iuu_phoenix: fix DMA from stack
usb: uas: Add PNY USB Portable SSD to unusual_uas
usb: usbip: vhci_hcd: protect shift size
* USB: xhci: fix U1/U2 handling for hardware with XHCI_INTEL_HOST quirk set
drivers/usb/host/xhci.c
usb: chipidea: ci_hdrc_imx: add missing put_device() call in usbmisc_get_init_data()
* usb: dwc3: ulpi: Use VStsDone to detect PHY regs access completion
drivers/usb/dwc3/core.h
USB: cdc-wdm: Fix use after free in service_outstanding_interrupt().
USB: cdc-acm: blacklist another IR Droid device
* usb: gadget: enable super speed plus
drivers/usb/gadget/configfs.c
staging: mt7621-dma: Fix a resource leak in an error handling path
* crypto: ecdh - avoid buffer overflow in ecdh_set_secret()
crypto/ecdh.c
video: hyperv_fb: Fix the mmap() regression for v5.4.y and older
Bluetooth: revert: hci_h5: close serdev device and free hu in h5_close
net: systemport: set dev->max_mtu to UMAC_MAX_MTU_SIZE
* net-sysfs: take the rtnl lock when accessing xps_rxqs_map and num_tc
net/core/net-sysfs.c
* net-sysfs: take the rtnl lock when storing xps_rxqs
net/core/net-sysfs.c
* net: sched: prevent invalid Scell_log shift count
include/net/red.h
vhost_net: fix ubuf refcount incorrectly when sendmsg fails
r8169: work around power-saving bug on some chip versions
net: usb: qmi_wwan: add Quectel EM160R-GL
* CDC-NCM: remove "connected" log message
drivers/net/usb/cdc_ncm.c
net: hdlc_ppp: Fix issues when mod_timer is called while timer is running
* erspan: fix version 1 check in gre_parse_header()
net/ipv4/gre_demux.c
net: hns: fix return value check in __lb_other_process()
* ipv4: Ignore ECN bits for fib lookups in fib_compute_spec_dst()
net/ipv4/fib_frontend.c
* tun: fix return value when the number of iovs exceeds MAX_SKB_FRAGS
drivers/net/tun.c
net: ethernet: ti: cpts: fix ethtool output when no ptp_clock registered
* net-sysfs: take the rtnl lock when accessing xps_cpus_map and num_tc
net/core/net-sysfs.c
* net-sysfs: take the rtnl lock when storing xps_cpus
net/core/net-sysfs.c
net: ethernet: Fix memleak in ethoc_probe
net/ncsi: Use real net-device for response handler
virtio_net: Fix recursive call to cpus_read_lock()
qede: fix offload for IPIP tunnel packets
net: mvpp2: Fix GoP port 3 Networking Complex Control configurations
atm: idt77252: call pci_disable_device() on error path
ethernet: ucc_geth: set dev->max_mtu to 1518
ethernet: ucc_geth: fix use-after-free in ucc_geth_remove()
net: mvpp2: prs: fix PPPoE with ipv6 packet parse
net: mvpp2: Add TCAM entry to drop flow control pause frames
i40e: Fix Error I40E_AQ_RC_EINVAL when removing VFs
* proc: fix lookup in /proc/net subdirectories after setns(2)
fs/proc/generic.c
fs/proc/internal.h
fs/proc/proc_net.c
include/linux/proc_fs.h
* proc: change ->nlink under proc_subdir_lock
fs/proc/generic.c
depmod: handle the case of /sbin/depmod without /sbin in PATH
* lib/genalloc: fix the overflow when size is too big
lib/genalloc.c
scsi: scsi_transport_spi: Set RQF_PM for domain validation commands
scsi: ide: Do not set the RQF_PREEMPT flag for sense requests
scsi: ufs-pci: Ensure UFS device is in PowerDown mode for suspend-to-disk ->poweroff()
* scsi: ufs: Fix wrong print message in dev_err()
drivers/scsi/ufs/ufshcd.c
* workqueue: Kick a worker based on the actual activation of delayed works
kernel/workqueue.c
* kbuild: don't hardcode depmod path
Makefile
ANDROID: enable LLVM_IAS=1 for clang's integrated assembler for aarch64
* Revert "ANDROID: arm64: lse: fix LSE atomics with LTO"
arch/arm64/include/asm/lse.h
* ANDROID: uapi: Add dm-user structure definition
include/uapi/linux/dm-user.h
* ANDROID: dm: dm-user: New target that proxies BIOs to userspace
drivers/md/Kconfig
drivers/md/Makefile
drivers/md/dm-user.c
ANDROID: GKI: Enable XFRM_MIGRATE
Merge 4.19.166 into android-4.19-stable
Linux 4.19.166
mwifiex: Fix possible buffer overflows in mwifiex_cmd_802_11_ad_hoc_start
iio:magnetometer:mag3110: Fix alignment and data leak issues.
iio:imu:bmi160: Fix alignment and data leak issues
* kdev_t: always inline major/minor helper functions
include/linux/kdev_t.h
dmaengine: at_hdmac: add missing kfree() call in at_dma_xlate()
dmaengine: at_hdmac: add missing put_device() call in at_dma_xlate()
dmaengine: at_hdmac: Substitute kzalloc with kmalloc
Revert "mtd: spinand: Fix OOB read"
Merge 4.19.165 into android-4.19-stable
Linux 4.19.165
* dm verity: skip verity work if I/O error when system is shutting down
drivers/md/dm-verity-target.c
* ALSA: pcm: Clear the full allocated memory at hw_params
sound/core/pcm_native.c
* module: delay kobject uevent until after module init call
kernel/module.c
NFSv4: Fix a pNFS layout related use-after-free race when freeing the inode
powerpc: sysdev: add missing iounmap() on error in mpic_msgr_probe()
* quota: Don't overflow quota file offsets
fs/quota/quota_tree.c
* module: set MODULE_STATE_GOING state when a module fails to load
kernel/module.c
rtc: sun6i: Fix memleak in sun6i_rtc_clk_init
* fcntl: Fix potential deadlock in send_sig{io, urg}()
fs/fcntl.c
* ALSA: rawmidi: Access runtime->avail always in spinlock
sound/core/rawmidi.c
ALSA: seq: Use bool for snd_seq_queue internal flags
media: gp8psk: initialize stats at power control logic
misc: vmw_vmci: fix kernel info-leak by initializing dbells in vmci_ctx_get_chkpt_doorbells()
reiserfs: add check for an invalid ih_entry_count
Bluetooth: hci_h5: close serdev device and free hu in h5_close
* of: fix linker-section match-table corruption
include/linux/of.h
null_blk: Fix zone size initialization
xen/gntdev.c: Mark pages as dirty
powerpc/bitops: Fix possible undefined behaviour with fls() and fls64()
KVM: x86: reinstate vendor-agnostic check on SPEC_CTRL cpuid bits
KVM: SVM: relax conditions for allowing MSR_IA32_SPEC_CTRL accesses
* uapi: move constants from <linux/kernel.h> to <linux/const.h>
include/uapi/linux/const.h
include/uapi/linux/ethtool.h
include/uapi/linux/kernel.h
include/uapi/linux/lightnvm.h
include/uapi/linux/mroute6.h
include/uapi/linux/netfilter/x_tables.h
include/uapi/linux/netlink.h
include/uapi/linux/sysctl.h
* ext4: don't remount read-only with errors=continue on reboot
fs/ext4/super.c
vfio/pci: Move dummy_resources_list init in vfio_pci_probe()
ubifs: prevent creating duplicate encrypted filenames
* f2fs: prevent creating duplicate encrypted filenames
fs/f2fs/f2fs.h
* ext4: prevent creating duplicate encrypted filenames
fs/ext4/namei.c
* fscrypt: add fscrypt_is_nokey_name()
fs/crypto/hooks.c
md/raid10: initialize r10_bio->read_slot before use.
* ANDROID: usb: f_accessory: Don't drop NULL reference in acc_disconnect()
drivers/usb/gadget/function/f_accessory.c
* ANDROID: usb: f_accessory: Avoid bitfields for shared variables
drivers/usb/gadget/function/f_accessory.c
* ANDROID: usb: f_accessory: Cancel any pending work before teardown
drivers/usb/gadget/function/f_accessory.c
* ANDROID: usb: f_accessory: Don't corrupt global state on double registration
drivers/usb/gadget/function/f_accessory.c
* ANDROID: usb: f_accessory: Fix teardown ordering in acc_release()
drivers/usb/gadget/function/f_accessory.c
* ANDROID: usb: f_accessory: Add refcounting to global 'acc_dev'
drivers/usb/gadget/function/f_accessory.c
* ANDROID: usb: f_accessory: Wrap '_acc_dev' in get()/put() accessors
drivers/usb/gadget/function/f_accessory.c
* ANDROID: usb: f_accessory: Remove useless assignment
drivers/usb/gadget/function/f_accessory.c
* ANDROID: usb: f_accessory: Remove useless non-debug prints
drivers/usb/gadget/function/f_accessory.c
* ANDROID: usb: f_accessory: Remove stale comments
drivers/usb/gadget/function/f_accessory.c
* ANDROID: USB: f_accessory: Check dev pointer before decoding ctrl request
drivers/usb/gadget/function/f_accessory.c
* ANDROID: usb: gadget: f_accessory: fix CTS test stuck
drivers/usb/gadget/function/f_accessory.c
* Revert "seq_buf: Avoid type mismatch for seq_buf_init"
include/linux/seq_buf.h
include/linux/trace_seq.h
Merge 4.19.164 into android-4.19-stable
Linux 4.19.164
platform/x86: mlx-platform: remove an unused variable
* PCI: Fix pci_slot_release() NULL pointer dereference
drivers/pci/slot.c
platform/x86: intel-vbtn: Allow switch events on Acer Switch Alpha 12
libnvdimm/namespace: Fix reaping of invalidated block-window-namespace labels
xenbus/xenbus_backend: Disallow pending watch messages
* xen/xenbus: Count pending messages for each watch
include/xen/xenbus.h
xen/xenbus/xen_bus_type: Support will_handle watch callback
* xen/xenbus: Add 'will_handle' callback support in xenbus_watch_path()
include/xen/xenbus.h
* xen/xenbus: Allow watches discard events before queueing
include/xen/xenbus.h
xen-blkback: set ring->xenblkd to NULL after kthread_stop()
clk: mvebu: a3700: fix the XTAL MODE pin to MPP1_9
pinctrl: sunxi: Always call chained_irq_{enter, exit} in sunxi_pinctrl_irq_handler
md/cluster: fix deadlock when node is doing resync job
md/cluster: block reshape with remote resync job
iio:imu:bmi160: Fix too large a buffer.
iio:pressure:mpl3115: Force alignment of buffer
iio:light:st_uvis25: Fix timestamp alignment and prevent data leak.
iio:light:rpr0521: Fix timestamp alignment and prevent data leak.
iio: adc: rockchip_saradc: fix missing clk_disable_unprepare() on error in rockchip_saradc_resume
iio: buffer: Fix demux update
scsi: lpfc: Re-fix use after free in lpfc_rq_buf_free()
scsi: lpfc: Fix invalid sleeping context in lpfc_sli4_nvmet_alloc()
mtd: rawnand: qcom: Fix DMA sync on FLASH_STATUS register read
mtd: parser: cmdline: Fix parsing of part-names with colons
mtd: spinand: Fix OOB read
* soc: qcom: smp2p: Safely acquire spinlock without IRQs
drivers/soc/qcom/smp2p.c
spi: mt7621: fix missing clk_disable_unprepare() on error in mt7621_spi_probe
spi: st-ssc4: Fix unbalanced pm_runtime_disable() in probe error path
spi: sc18is602: Don't leak SPI master in probe error path
spi: rb4xx: Don't leak SPI master in probe error path
spi: pic32: Don't leak DMA channels in probe error path
spi: davinci: Fix use-after-free on unbind
spi: spi-sh: Fix use-after-free on unbind
drm/dp_aux_dev: check aux_dev before use in drm_dp_aux_dev_get_by_minor()
jfs: Fix array index bounds check in dbAdjTree
jffs2: Fix GC exit abnormally
ubifs: wbuf: Don't leak kernel memory to flash
SMB3.1.1: do not log warning message if server doesn't populate salt
SMB3: avoid confusing warning message on mount to Azure
ceph: fix race in concurrent __ceph_remove_cap invocations
ima: Don't modify file descriptor mode on the fly
powerpc/powernv/memtrace: Fix crashing the kernel when enabling concurrently
powerpc/powernv/memtrace: Don't leak kernel memory to user space
powerpc/xmon: Change printk() to pr_cont()
powerpc/rtas: Fix typo of ibm,open-errinjct in RTAS filter
powerpc: Fix incorrect stw{, ux, u, x} instructions in __set_pte_at
ARM: dts: at91: sama5d2: fix CAN message ram offset and size
ARM: dts: pandaboard: fix pinmux for gpio user button of Pandaboard ES
* KVM: arm64: Introduce handling of AArch32 TTBCR2 traps
arch/arm64/include/asm/kvm_host.h
* ext4: fix deadlock with fs freezing and EA inodes
fs/ext4/inode.c
* ext4: fix a memory leak of ext4_free_data
fs/ext4/mballoc.c
USB: serial: keyspan_pda: fix write unthrottling
USB: serial: keyspan_pda: fix tx-unthrottle use-after-free
USB: serial: keyspan_pda: fix write-wakeup use-after-free
USB: serial: keyspan_pda: fix stalled writes
USB: serial: keyspan_pda: fix write deadlock
USB: serial: keyspan_pda: fix dropped unthrottle interrupts
USB: serial: digi_acceleport: fix write-wakeup deadlocks
USB: serial: mos7720: fix parallel-port state restore
EDAC/amd64: Fix PCI component registration
* crypto: ecdh - avoid unaligned accesses in ecdh_set_secret()
crypto/ecdh.c
powerpc/perf: Exclude kernel samples while counting events in user space.
staging: comedi: mf6x4: Fix AI end-of-conversion detection
s390/dasd: fix list corruption of lcu list
s390/dasd: fix list corruption of pavgroup group list
s390/dasd: prevent inconsistent LCU device data
s390/dasd: fix hanging device offline processing
s390/kexec_file: fix diag308 subcode when loading crash kernel
s390/smp: perform initial CPU reset also for SMT siblings
* ALSA: usb-audio: Disable sample read check if firmware doesn't give back
sound/usb/clock.c
* ALSA: usb-audio: Add VID to support native DSD reproduction on FiiO devices
sound/usb/quirks.c
ALSA: hda/realtek: Apply jack fixup for Quanta NL3
ALSA: hda/realtek: Add quirk for MSI-GP73
ALSA: pcm: oss: Fix a few more UBSAN fixes
ALSA: hda/realtek - Enable headset mic of ASUS Q524UQK with ALC255
ALSA: hda/realtek - Enable headset mic of ASUS X430UN with ALC256
ALSA: hda: Fix regressions on clear and reconfig sysfs
ACPI: PNP: compare the string length in the matching_id()
Revert "ACPI / resources: Use AE_CTRL_TERMINATE to terminate resources walks"
* PM: ACPI: PCI: Drop acpi_pm_set_bridge_wakeup()
include/acpi/acpi_bus.h
ALSA: hda/ca0132 - Change Input Source enum strings.
Input: cyapa_gen6 - fix out-of-bounds stack access
media: ipu3-cio2: Make the field on subdev format V4L2_FIELD_NONE
media: ipu3-cio2: Validate mbus format in setting subdev format
media: ipu3-cio2: Serialise access to pad format
media: ipu3-cio2: Return actual subdev format
media: ipu3-cio2: Remove traces of returned buffers
media: netup_unidvb: Don't leak SPI master in probe error path
media: sunxi-cir: ensure IR is handled when it is continuous
media: gspca: Fix memory leak in probe
Input: goodix - add upside-down quirk for Teclast X98 Pro tablet
Input: cros_ec_keyb - send 'scancodes' in addition to key events
lwt: Disable BH too in run_lwt_bpf()
* fix namespaced fscaps when !CONFIG_SECURITY
include/linux/security.h
* cfg80211: initialize rekey_data
net/wireless/nl80211.c
ARM: sunxi: Add machine match for the Allwinner V3 SoC
* kconfig: fix return value of do_error_if()
scripts/kconfig/preprocess.c
clk: sunxi-ng: Make sure divider tables have sentinel
clk: s2mps11: Fix a resource leak in error handling paths in the probe function
qlcnic: Fix error code in probe
perf record: Fix memory leak when using '--user-regs=?' to list registers
pwm: lp3943: Dynamically allocate PWM chip base
pwm: zx: Add missing cleanup in error path
clk: ti: Fix memleak in ti_fapll_synth_setup
* watchdog: coh901327: add COMMON_CLK dependency
drivers/watchdog/Kconfig
watchdog: qcom: Avoid context switch in restart handler
libnvdimm/label: Return -ENXIO for no slot in __blk_label_update
net: korina: fix return value
net: allwinner: Fix some resources leak in the error handling path of the probe and in the remove function
net: bcmgenet: Fix a resource leak in an error handling path in the probe functin
checkpatch: fix unescaped left brace
powerpc/ps3: use dma_mapping_error()
nfc: s3fwrn5: Release the nfc firmware
um: chan_xterm: Fix fd leak
um: tty: Fix handling of close in tty lines
um: Monitor error events in IRQ controller
* watchdog: Fix potential dereferencing of null pointer
drivers/watchdog/watchdog_core.c
watchdog: sprd: check busy bit before new loading rather than after that
watchdog: sprd: remove watchdog disable from resume fail path
* watchdog: sirfsoc: Add missing dependency on HAS_IOMEM
drivers/watchdog/Kconfig
irqchip/alpine-msi: Fix freeing of interrupts on allocation error path
* ASoC: wm_adsp: remove "ctl" from list on error in wm_adsp_create_control()
sound/soc/codecs/wm_adsp.c
mac80211: don't set set TDLS STA bandwidth wider than possible
extcon: max77693: Fix modalias string
clk: tegra: Fix duplicated SE clock entry
bus: fsl-mc: fix error return code in fsl_mc_object_allocate()
x86/kprobes: Restore BTF if the single-stepping is cancelled
nfs_common: need lock during iterate through the list
nfsd: Fix message level for normal termination
speakup: fix uninitialized flush_lock
usb: oxu210hp-hcd: Fix memory leak in oxu_create
usb: ehci-omap: Fix PM disable depth umbalance in ehci_hcd_omap_probe
powerpc/pseries/hibernation: remove redundant cacheinfo update
powerpc/pseries/hibernation: drop pseries_suspend_begin() from suspend ops
platform/x86: mlx-platform: Fix item counter assignment for MSN2700, MSN24xx systems
scsi: fnic: Fix error return code in fnic_probe()
* seq_buf: Avoid type mismatch for seq_buf_init
include/linux/seq_buf.h
include/linux/trace_seq.h
scsi: pm80xx: Fix error return in pm8001_pci_probe()
scsi: qedi: Fix missing destroy_workqueue() on error in __qedi_probe
cpufreq: scpi: Add missing MODULE_ALIAS
cpufreq: loongson1: Add missing MODULE_ALIAS
cpufreq: st: Add missing MODULE_DEVICE_TABLE
cpufreq: mediatek: Add missing MODULE_DEVICE_TABLE
cpufreq: highbank: Add missing MODULE_DEVICE_TABLE
* clocksource/drivers/arm_arch_timer: Correct fault programming of CNTKCTL_EL1.EVNTI
drivers/clocksource/arm_arch_timer.c
* dm ioctl: fix error return code in target_message
drivers/md/dm-ioctl.c
ASoC: jz4740-i2s: add missed checks for clk_get()
net/mlx5: Properly convey driver version to firmware
memstick: r592: Fix error return in r592_probe()
arm64: dts: rockchip: Fix UART pull-ups on rk3328
pinctrl: falcon: add missing put_device() call in pinctrl_falcon_probe()
ARM: dts: at91: sama5d2: map securam as device
clocksource/drivers/cadence_ttc: Fix memory leak in ttc_setup_clockevent()
media: saa7146: fix array overflow in vidioc_s_audio()
vfio-pci: Use io_remap_pfn_range() for PCI IO memory
NFS: switch nfsiod to be an UNBOUND workqueue.
lockd: don't use interval-based rebinding over TCP
* SUNRPC: xprt_load_transport() needs to support the netid "rdma6"
include/linux/sunrpc/xprt.h
NFSv4.2: condition READDIR's mask for security label based on LSM state
ath10k: Release some resources in an error handling path
ath10k: Fix an error handling path
ath10k: Fix the parsing error in service available event
platform/x86: dell-smbios-base: Fix error return code in dell_smbios_init
ARM: dts: at91: at91sam9rl: fix ADC triggers
arm64: dts: meson: fix spi-max-frequency on Khadas VIM2
PCI: iproc: Fix out-of-bound array accesses
* PCI: Fix overflow in command-line resource alignment requests
drivers/pci/pci.c
* PCI: Bounds-check command-line resource alignment requests
drivers/pci/pci.c
* genirq/irqdomain: Don't try to free an interrupt that has no mapping
kernel/irq/irqdomain.c
power: supply: bq24190_charger: fix reference leak
power: supply: axp288_charger: Fix HP Pavilion x2 10 DMI matching
arm64: dts: rockchip: Set dr_mode to "host" for OTG on rk3328-roc-cc
ARM: dts: Remove non-existent i2c1 from 98dx3236
HSI: omap_ssi: Don't jump to free ID in ssi_add_controller()
slimbus: qcom-ngd-ctrl: Avoid sending power requests without QMI
media: max2175: fix max2175_set_csm_mode() error code
mips: cdmm: fix use-after-free in mips_cdmm_bus_discover
samples: bpf: Fix lwt_len_hist reusing previous BPF map
platform/x86: mlx-platform: Remove PSU EEPROM from MSN274x platform configuration
platform/x86: mlx-platform: Remove PSU EEPROM from default platform configuration
media: siano: fix memory leak of debugfs members in smsdvb_hotplug
dmaengine: mv_xor_v2: Fix error return code in mv_xor_v2_probe()
cw1200: fix missing destroy_workqueue() on error in cw1200_init_common
orinoco: Move context allocation after processing the skb
ARM: dts: at91: sama5d3_xplained: add pincontrol for USB Host
ARM: dts: at91: sama5d4_xplained: add pincontrol for USB Host
memstick: fix a double-free bug in memstick_check
RDMA/cxgb4: Validate the number of CQEs
Input: omap4-keypad - fix runtime PM error handling
drivers: soc: ti: knav_qmss_queue: Fix error return code in knav_queue_probe
soc: ti: Fix reference imbalance in knav_dma_probe
soc: ti: knav_qmss: fix reference leak in knav_queue_probe
* spi: fix resource leak for drivers without .remove callback
drivers/spi/spi.c
crypto: omap-aes - Fix PM disable depth imbalance in omap_aes_probe
crypto: crypto4xx - Replace bitwise OR with logical OR in crypto4xx_build_pd
powerpc/feature: Fix CPU_FTRS_ALWAYS by removing CPU_FTRS_GENERIC_32
spi: mxs: fix reference leak in mxs_spi_probe
usb/max3421: fix return error code in max3421_probe()
Input: ads7846 - fix unaligned access on 7845
Input: ads7846 - fix integer overflow on Rt calculation
Input: ads7846 - fix race that causes missing releases
drm/omap: dmm_tiler: fix return error code in omap_dmm_probe()
video: fbdev: atmel_lcdfb: fix return error code in atmel_lcdfb_of_init()
media: solo6x10: fix missing snd_card_free in error handling case
* scsi: core: Fix VPD LUN ID designator priorities
drivers/scsi/scsi_lib.c
* ASoC: meson: fix COMPILE_TEST error
sound/soc/meson/Kconfig
media: mtk-vcodec: add missing put_device() call in mtk_vcodec_release_dec_pm()
media: tm6000: Fix sizeof() mismatches
staging: gasket: interrupt: fix the missed eventfd_ctx_put() in gasket_interrupt.c
staging: greybus: codecs: Fix reference counter leak in error handling
crypto: qat - fix status check in qat_hal_put_rel_rd_xfer()
MIPS: BCM47XX: fix kconfig dependency bug for BCM47XX_BCMA
RDMa/mthca: Work around -Wenum-conversion warning
ASoC: arizona: Fix a wrong free in wm8997_probe
ASoC: wm8998: Fix PM disable depth imbalance on error
mwifiex: fix mwifiex_shutdown_sw() causing sw reset failure
spi: bcm63xx-hsspi: fix missing clk_disable_unprepare() on error in bcm63xx_hsspi_resume
spi: tegra114: fix reference leak in tegra spi ops
spi: tegra20-sflash: fix reference leak in tegra_sflash_resume
spi: tegra20-slink: fix reference leak in slink ops of tegra20
spi: spi-ti-qspi: fix reference leak in ti_qspi_setup
Bluetooth: hci_h5: fix memory leak in h5_close
* Bluetooth: Fix null pointer dereference in hci_event_packet()
net/bluetooth/hci_event.c
arm64: dts: exynos: Correct psci compatible used on Exynos7
arm64: dts: exynos: Include common syscon restart/poweroff for Exynos7
* selinux: fix inode_doinit_with_dentry() LABEL_INVALID error handling
security/selinux/hooks.c
* ASoC: pcm: DRAIN support reactivation
sound/soc/soc-pcm.c
drm/msm/dsi_pll_10nm: restore VCO rate during restore_state
spi: img-spfi: fix reference leak in img_spfi_resume
powerpc/64: Set up a kernel stack for secondaries before cpu_restore()
crypto: inside-secure - Fix sizeof() mismatch
crypto: talitos - Fix return type of current_desc_hdr()
crypto: talitos - Endianess in current_desc_hdr()
* sched: Reenable interrupts in do_sched_yield()
kernel/sched/core.c
* sched/deadline: Fix sched_dl_global_validate()
kernel/sched/deadline.c
kernel/sched/sched.h
x86/apic: Fix x2apic enablement without interrupt remapping
ARM: p2v: fix handling of LPAE translation in BE mode
x86/mm/ident_map: Check for errors from ident_pud_init()
RDMA/rxe: Compute PSN windows correctly
ARM: dts: aspeed: s2600wf: Fix VGA memory region location
* selinux: fix error initialization in inode_doinit_with_dentry()
security/selinux/hooks.c
RDMA/bnxt_re: Set queue pair state when being queried
soc: qcom: geni: More properly switch to DMA mode
soc: mediatek: Check if power domains can be powered on at boot time
soc: renesas: rmobile-sysc: Fix some leaks in rmobile_init_pm_domains()
drm/tve200: Fix handling of platform_get_irq() error
drm/gma500: fix double free of gma_connector
perf cs-etm: Move definition of 'traceid_list' global variable from header file
perf cs-etm: Change tuple from traceID-CPU# to traceID-metadata
md: fix a warning caused by a race between concurrent md_ioctl()s
* crypto: af_alg - avoid undefined behavior accessing salg_name
include/uapi/linux/if_alg.h
media: msi2500: assign SPI bus number dynamically
* quota: Sanity-check quota file headers on load
fs/quota/quota_v2.c
* Bluetooth: Fix slab-out-of-bounds read in hci_le_direct_adv_report_evt()
net/bluetooth/hci_event.c
* serial_core: Check for port state when tty is in error state
drivers/tty/serial/serial_core.c
HID: i2c-hid: add Vero K147 to descriptor override
scsi: megaraid_sas: Check user-provided offsets
* coresight: tmc-etr: Check if page is valid before dma_map_page()
drivers/hwtracing/coresight/coresight-tmc-etr.c
ARM: dts: exynos: fix USB 3.0 pins supply being turned off on Odroid XU
ARM: dts: exynos: fix USB 3.0 VBUS control and over-current pins on Exynos5410
ARM: dts: exynos: fix roles of USB 3.0 ports on Odroid XU
usb: chipidea: ci_hdrc_imx: Pass DISABLE_DEVICE_STREAMING flag to imx6ul
USB: gadget: f_rndis: fix bitrate for SuperSpeed and above
* usb: gadget: f_fs: Re-use SS descriptors for SuperSpeedPlus
drivers/usb/gadget/function/f_fs.c
* USB: gadget: f_midi: setup SuperSpeed Plus descriptors
drivers/usb/gadget/function/f_midi.c
USB: gadget: f_acm: add support for SuperSpeed Plus
USB: serial: option: add interface-number sanity check to flag handling
soc/tegra: fuse: Fix index bug in get_process_id
* dm table: Remove BUG_ON(in_interrupt())
drivers/md/dm-table.c
scsi: mpt3sas: Increase IOCInit request timeout to 30s
vxlan: Copy needed_tailroom from lowerdev
vxlan: Add needed_headroom for lower device
* arm64: syscall: exit userspace before unmasking exceptions
arch/arm64/kernel/syscall.c
drm/tegra: sor: Disable clocks on error in tegra_sor_init()
* kernel/cpu: add arch override for clear_tasks_mm_cpumask() mm handling
kernel/cpu.c
drm/tegra: replace idr_init() by idr_init_base()
ixgbe: avoid premature Rx buffer reuse
RDMA/cm: Fix an attempt to use non-valid pointer when cleaning timewait
selftests/bpf/test_offload.py: Reset ethtool features after failed setting
gpio: eic-sprd: break loop when getting NULL device resource
* netfilter: x_tables: Switch synchronization to RCU
include/linux/netfilter/x_tables.h
net/ipv4/netfilter/arp_tables.c
net/ipv4/netfilter/ip_tables.c
net/ipv6/netfilter/ip6_tables.c
net/netfilter/x_tables.c
* block: factor out requeue handling from dispatch code
block/blk-mq.c
clk: renesas: r9a06g032: Drop __packed for portability
can: softing: softing_netdev_open(): fix error handling
xsk: Fix xsk_poll()'s return type
* scsi: bnx2i: Requires MMU
drivers/scsi/bnx2i/Kconfig
gpio: mvebu: fix potential user-after-free on probe
ARM: dts: sun8i: v3s: fix GIC node memory range
pinctrl: baytrail: Avoid clearing debounce value when turning it off
pinctrl: merrifield: Set default bias in case no particular value given
x86/resctrl: Fix incorrect local bandwidth when mba_sc is enabled
x86/resctrl: Remove unused struct mbm_state::chunks_bw
* arm64: Change .weak to SYM_FUNC_START_WEAK_PI for arch/arm64/lib/mem*.S
arch/arm64/lib/memcpy.S
arch/arm64/lib/memmove.S
arch/arm64/lib/memset.S
* arm64: lse: Fix LSE atomics with LLVM
arch/arm64/include/asm/lse.h
* arm64: lse: fix LSE atomics with LLVM's integrated assembler
arch/arm64/include/asm/atomic_lse.h
arch/arm64/include/asm/lse.h
* drm: fix drm_dp_mst_port refcount leaks in drm_dp_mst_allocate_vcpi
drivers/gpu/drm/drm_dp_mst_topology.c
drm/xen-front: Fix misused IS_ERR_OR_NULL checks
serial: 8250_omap: Avoid FIFO corruption caused by MDR1 access
ALSA: pcm: oss: Fix potential out-of-bounds shift
* USB: sisusbvga: Make console support depend on BROKEN
drivers/usb/misc/sisusbvga/Kconfig
* USB: UAS: introduce a quirk to set no_write_same
drivers/usb/storage/usb.c
include/linux/usb_usual.h
* xhci: Give USB2 ports time to enter U3 in bus suspend
drivers/usb/host/xhci-hub.c
* ALSA: usb-audio: Fix control 'access overflow' errors from chmap
sound/usb/stream.c
* ALSA: usb-audio: Fix potential out-of-bounds shift
sound/usb/format.c
* USB: add RESET_RESUME quirk for Snapscan 1212
drivers/usb/core/quirks.c
USB: dummy-hcd: Fix uninitialized array use in init()
ktest.pl: If size of log is too big to email, email error message
net: bridge: vlan: fix error return code in __vlan_add()
net: stmmac: dwmac-meson8b: fix mask definition of the m250_sel mux
net: stmmac: delete the eee_ctrl_timer after napi disabled
net/mlx4_en: Handle TX error CQE
lan743x: fix for potential NULL pointer dereference with bare card
net/mlx4_en: Avoid scheduling restart task if it is already running
* tcp: fix cwnd-limited bug for TSO deferral where we send nothing
net/ipv4/tcp_output.c
* tcp: select sane initial rcvq_space.space for big MSS
net/ipv4/tcp_input.c
net: stmmac: free tx skb buffer in stmmac_resume()
mac80211: mesh: fix mesh_pathtbl_init() error path
PCI: qcom: Add missing reset for ipq806x
* compiler.h: fix barrier_data() on clang
include/linux/compiler-clang.h
include/linux/compiler-gcc.h
include/linux/compiler.h
x86/apic/vector: Fix ordering in vector assignment
x86/membarrier: Get rid of a dubious optimization
x86/mm/mem_encrypt: Fix definition of PMD_FLAGS_DEC_WP
scsi: be2iscsi: Revert "Fix a theoretical leak in beiscsi_create_eqs()"
* kbuild: avoid static_assert for genksyms
include/linux/build_bug.h
mmc: block: Fixup condition for CMD13 polling for RPMB requests
pinctrl: amd: remove debounce filter setting in IRQ type setting
Input: i8042 - add Acer laptops to the i8042 reset list
Input: cm109 - do not stomp on control URB
platform/x86: intel-vbtn: Support for tablet mode on HP Pavilion 13 x360 PC
platform/x86: acer-wmi: add automatic keyboard background light toggle key as KEY_LIGHTS_TOGGLE
platform/x86: thinkpad_acpi: Add BAT1 is primary battery quirk for Thinkpad Yoga 11e 4th gen
platform/x86: thinkpad_acpi: Do not report SW_TABLET_MODE on Yoga 11e
soc: fsl: dpio: Get the cpumask through cpumask_of(cpu)
* irqchip/gic-v3-its: Unconditionally save/restore the ITS state on suspend
drivers/irqchip/irq-gic-v3-its.c
* scsi: ufs: Make sure clk scaling happens only when HBA is runtime ACTIVE
drivers/scsi/ufs/ufshcd.c
ARC: stack unwinding: don't assume non-current task is sleeping
powerpc: Drop -me200 addition to build flags
iwlwifi: mvm: fix kernel panic in case of assert during CSA
arm64: dts: rockchip: Assign a fixed index to mmc devices on rk3399 boards.
iwlwifi: pcie: limit memory read spin time
spi: bcm2835aux: Restore err assignment in bcm2835aux_spi_probe
spi: bcm2835aux: Fix use-after-free on unbind
x86/lib: Change .weak to SYM_FUNC_START_WEAK for arch/x86/lib/mem*_64.S
* Kbuild: do not emit debug info for assembly with LLVM_IAS=1
Makefile
ANDROID: GKI: Update the ABI xml representation
* ANDROID: Incremental fs: Set credentials before reading/writing
fs/incfs/data_mgmt.c
fs/incfs/format.c
fs/incfs/format.h
fs/incfs/pseudo_files.c
ANDROID: Incremental fs: Fix incfs_test use of atol, open
* ANDROID: Incremental fs: Change per UID timeouts to microseconds
fs/incfs/data_mgmt.c
fs/incfs/data_mgmt.h
fs/incfs/pseudo_files.c
fs/incfs/vfs.c
include/uapi/linux/incrementalfs.h
* ANDROID: Incremental fs: Add v2 feature flag
fs/incfs/main.c
include/uapi/linux/incrementalfs.h
* ANDROID: Incremental fs: Add zstd feature flag
fs/incfs/main.c
include/uapi/linux/incrementalfs.h
Merge 4.19.163 into android-4.19-stable
Linux 4.19.163
Revert "geneve: pull IP header before ECN decapsulation"
x86/insn-eval: Use new for_each_insn_prefix() macro to loop over prefixes bytes
netfilter: nf_tables: avoid false-postive lockdep splat
Input: i8042 - fix error return code in i8042_setup_aux()
dm writecache: remove BUG() and fail gracefully instead
i2c: qup: Fix error return code in qup_i2c_bam_schedule_desc()
gfs2: check for empty rgrp tree in gfs2_ri_update
* tracing: Fix userstacktrace option for instances
kernel/trace/trace.c
kernel/trace/trace.h
spi: bcm2835: Release the DMA channel if probe fails after dma_init
spi: bcm2835: Fix use-after-free on unbind
spi: bcm-qspi: Fix use-after-free on unbind
* spi: Introduce device-managed SPI controller allocation
drivers/spi/spi.c
include/linux/spi/spi.h
iommu/amd: Set DTE[IntTabLen] to represent 512 IRTEs
speakup: Reject setting the speakup line discipline outside of speakup
i2c: imx: Check for I2SR_IAL after every byte
i2c: imx: Fix reset of I2SR_IAL flag
x86/uprobes: Do not use prefixes.nbytes when looping over prefixes.bytes
* mm/swapfile: do not sleep with a spin lock held
mm/swapfile.c
* mm: list_lru: set shrinker map bit when child nr_items is not zero
mm/list_lru.c
* dm: remove invalid sparse __acquires and __releases annotations
drivers/md/dm.c
dm writecache: fix the maximum number of arguments
scsi: mpt3sas: Fix ioctl timeout
i2c: imx: Don't generate STOP condition if arbitration has been lost
cifs: fix potential use-after-free in cifs_echo_request()
ftrace: Fix updating FTRACE_FL_TRAMP
ALSA: hda/generic: Add option to enforce preferred_dacs pairs
ALSA: hda/realtek - Add new codec supported for ALC897
ALSA: hda/realtek: Enable headset of ASUS UX482EG & B9400CEA with ALC294
ALSA: hda/realtek: Add mute LED quirk to yet another HP x360 model
* tty: Fix ->session locking
drivers/tty/tty_io.c
drivers/tty/tty_jobctrl.c
include/linux/tty.h
* tty: Fix ->pgrp locking in tiocspgrp()
drivers/tty/tty_jobctrl.c
USB: serial: option: fix Quectel BG96 matching
USB: serial: option: add support for Thales Cinterion EXS82
USB: serial: option: add Fibocom NL668 variants
USB: serial: ch341: sort device-id entries
USB: serial: ch341: add new Product ID for CH341A
USB: serial: kl5kusb105: fix memleak on open
* usb: gadget: f_fs: Use local copy of descriptors for userspace copy
drivers/usb/gadget/function/f_fs.c
pinctrl: baytrail: Fix pin being driven low for a while on gpiod_get(..., GPIOD_OUT_HIGH)
pinctrl: baytrail: Replace WARN with dev_info_once when setting direct-irq pin to output
ANDROID: Add symbol of get_next_event_cpu back
ANDROID: x86: configs: gki: add missing CONFIG_BLK_CGROUP
ANDROID: Add allowed symbols from sctp.ko and qrtr.ko
Merge 4.19.162 into android-4.19-stable
Linux 4.19.162
RDMA/i40iw: Address an mmap handler exploit in i40iw
tracing: Remove WARN_ON in start_thread()
Input: i8042 - add ByteSpeed touchpad to noloop table
* Input: xpad - support Ardwiino Controllers
drivers/input/joystick/xpad.c
* ALSA: usb-audio: US16x08: fix value count for level meters
sound/usb/mixer_us16x08.c
dt-bindings: net: correct interrupt flags in examples
chelsio/chtls: fix panic during unload reload chtls
net/mlx5: Fix wrong address reclaim when command interface is down
net: mvpp2: Fix error return code in mvpp2_open()
chelsio/chtls: fix a double free in chtls_setkey()
net: pasemi: fix error return code in pasemi_mac_open()
cxgb3: fix error return code in t3_sge_alloc_qset()
net/x25: prevent a couple of overflows
net: ip6_gre: set dev->hard_header_len when using header_ops
geneve: pull IP header before ECN decapsulation
ibmvnic: Fix TX completion error handling
ibmvnic: Ensure that SCRQ entry reads are correctly ordered
* ipv4: Fix tos mask in inet_rtm_getroute()
net/ipv4/route.c
netfilter: bridge: reset skb->pkt_type after NF_INET_POST_ROUTING traversal
* bonding: wait for sysfs kobject destruction before freeing struct slave
drivers/net/bonding/bond_main.c
drivers/net/bonding/bond_sysfs_slave.c
include/net/bonding.h
i40e: Fix removing driver while bare-metal VFs pass traffic
ibmvnic: fix call_netdevice_notifiers in do_reset
* net/tls: Protect from calling tls_dev_del for TLS RX twice
include/net/tls.h
usbnet: ipheth: fix connectivity with iOS 14
* tun: honor IOCB_NOWAIT flag
drivers/net/tun.c
* tcp: Set INET_ECN_xmit configuration in tcp_reinit_congestion_control
net/ipv4/tcp_cong.c
* sock: set sk_err to ee_errno on dequeue from errq
net/core/skbuff.c
rose: Fix Null pointer dereference in rose_send_frame()
net/tls: missing received data after fast remote close
net/af_iucv: set correct sk_protocol for child sockets
* ipv6: addrlabel: fix possible memory leak in ip6addrlbl_net_init
net/ipv6/addrlabel.c
* FROMLIST: Kbuild: do not emit debug info for assembly with LLVM_IAS=1
Makefile
* ANDROID: kbuild: use grep -F instead of fgrep
scripts/Kbuild.include
* ANDROID: GKI: usb: gadget: support claiming indexed endpoints by name
drivers/usb/gadget/epautoconf.c
* UPSTREAM: arm64: sysreg: Clean up instructions for modifying PSTATE fields
arch/arm64/include/asm/sysreg.h
arch/arm64/kernel/cpufeature.c
Revert "Revert "ANDROID: clang: update to 11.0.5""
* ANDROID: kbuild: speed up ksym_dep_filter
scripts/Kbuild.include
* Revert "drm/atomic_helper: Stop modesets on unregistered connectors harder"
drivers/gpu/drm/drm_atomic.c
drivers/gpu/drm/drm_atomic_helper.c
drivers/gpu/drm/drm_connector.c
include/drm/drm_connector.h
Merge 4.19.161 into android-4.19-stable
Linux 4.19.161
* USB: core: Fix regression in Hercules audio card
drivers/usb/core/quirks.c
x86/resctrl: Add necessary kernfs_put() calls to prevent refcount leak
x86/resctrl: Remove superfluous kernfs_get() calls to prevent refcount leak
x86/speculation: Fix prctl() when spectre_v2_user={seccomp,prctl},ibpb
usb: gadget: Fix memleak in gadgetfs_fill_super
* USB: quirks: Add USB_QUIRK_DISCONNECT_SUSPEND quirk for Lenovo A630Z TIO built-in usb-audio card
drivers/usb/core/quirks.c
* usb: gadget: f_midi: Fix memleak in f_midi_alloc
drivers/usb/gadget/function/f_midi.c
* USB: core: Change %pK for __user pointers to %px
drivers/usb/core/devio.c
perf probe: Fix to die_entrypc() returns error correctly
can: m_can: fix nominal bitiming tseg2 min for version >= 3.1
platform/x86: toshiba_acpi: Fix the wrong variable assignment
platform/x86: thinkpad_acpi: Send tablet mode switch at wakeup time
can: gs_usb: fix endianess problem with candleLight firmware
efivarfs: revert "fix memory leak in efivarfs_create()"
optee: add writeback to valid memory type
ibmvnic: fix NULL pointer dereference in ibmvic_reset_crq
ibmvnic: fix NULL pointer dereference in reset_sub_crq_queues
net: ena: set initial DMA width to avoid intel iommu issue
nfc: s3fwrn5: use signed integer for parsing GPIO numbers
IB/mthca: fix return value of error branch in mthca_init_cq()
s390/qeth: fix tear down of async TX buffers
cxgb4: fix the panic caused by non smac rewrite
bnxt_en: Release PCI regions when DMA mask setup fails during probe.
video: hyperv_fb: Fix the cache type when mapping the VRAM
bnxt_en: fix error return code in bnxt_init_board()
bnxt_en: fix error return code in bnxt_init_one()
* scsi: ufs: Fix race between shutdown and runtime resume flow
drivers/scsi/ufs/ufshcd.c
ARM: dts: dra76x: m_can: fix order of clocks
batman-adv: set .owner to THIS_MODULE
phy: tegra: xusb: Fix dangling pointer on probe failure
xtensa: uaccess: Add missing __user to strncpy_from_user() prototype
perf/x86: fix sysfs type mismatches
scsi: target: iscsi: Fix cmd abort fabric stop race
* scsi: libiscsi: Fix NOP race condition
include/scsi/libiscsi.h
dmaengine: pl330: _prep_dma_memcpy: Fix wrong burst size
nvme: free sq/cq dbbuf pointers when dbbuf set fails
* proc: don't allow async path resolution of /proc/self components
fs/proc/self.c
* HID: Add Logitech Dinovo Edge battery quirk
drivers/hid/hid-ids.h
drivers/hid/hid-input.c
x86/xen: don't unbind uninitialized lock_kicker_irq
dmaengine: xilinx_dma: use readl_poll_timeout_atomic variant
* HID: add HID_QUIRK_INCREMENT_USAGE_ON_DUPLICATE for Gamevice devices
drivers/hid/hid-ids.h
drivers/hid/hid-quirks.c
HID: hid-sensor-hub: Fix issue with devices with no report ID
Input: i8042 - allow insmod to succeed on devices without an i8042 controller
* HID: add support for Sega Saturn
drivers/hid/hid-ids.h
drivers/hid/hid-quirks.c
* HID: cypress: Support Varmilo Keyboards' media hotkeys
drivers/hid/hid-ids.h
ALSA: hda/hdmi: fix incorrect locking in hdmi_pcm_close
* drm/atomic_helper: Stop modesets on unregistered connectors harder
drivers/gpu/drm/drm_atomic.c
drivers/gpu/drm/drm_atomic_helper.c
drivers/gpu/drm/drm_connector.c
include/drm/drm_connector.h
* arm64: pgtable: Ensure dirty bit is preserved across pte_wrprotect()
arch/arm64/include/asm/pgtable.h
* arm64: pgtable: Fix pte_accessible()
arch/arm64/include/asm/pgtable.h
KVM: x86: Fix split-irqchip vs interrupt injection window request
KVM: x86: handle !lapic_in_kernel case in kvm_cpu_*_extint
KVM: arm64: vgic-v3: Drop the reporting of GICR_TYPER.Last for userspace
* wireless: Use linux/stddef.h instead of stddef.h
include/uapi/linux/wireless.h
btrfs: fix lockdep splat when reading qgroup config on mount
btrfs: don't access possibly stale fs_info data for printing duplicate device
* netfilter: clear skb->next in NF_HOOK_LIST()
include/linux/netfilter.h
perf event: Check ref_reloc_sym before using it
* ANDROID: vmlinux.lds.h: merge compound literal sections
include/asm-generic/vmlinux.lds.h
* BACKPORT: sched/fair: Fix overutilized update in enqueue_task_fair()
kernel/sched/fair.c
Bug: 180663378
Change-Id: Ie10d7527ff7d181fa122bbe77d6869c2b65cbe4e
Signed-off-by: Lucas Wei <lucaswei@google.com>
|
||
|
|
c0fc50e6a0 |
Merge 4.19.165 into android-4.19-stable
Changes in 4.19.165
md/raid10: initialize r10_bio->read_slot before use.
fscrypt: add fscrypt_is_nokey_name()
ext4: prevent creating duplicate encrypted filenames
f2fs: prevent creating duplicate encrypted filenames
ubifs: prevent creating duplicate encrypted filenames
vfio/pci: Move dummy_resources_list init in vfio_pci_probe()
ext4: don't remount read-only with errors=continue on reboot
uapi: move constants from <linux/kernel.h> to <linux/const.h>
KVM: SVM: relax conditions for allowing MSR_IA32_SPEC_CTRL accesses
KVM: x86: reinstate vendor-agnostic check on SPEC_CTRL cpuid bits
powerpc/bitops: Fix possible undefined behaviour with fls() and fls64()
xen/gntdev.c: Mark pages as dirty
null_blk: Fix zone size initialization
of: fix linker-section match-table corruption
Bluetooth: hci_h5: close serdev device and free hu in h5_close
reiserfs: add check for an invalid ih_entry_count
misc: vmw_vmci: fix kernel info-leak by initializing dbells in vmci_ctx_get_chkpt_doorbells()
media: gp8psk: initialize stats at power control logic
ALSA: seq: Use bool for snd_seq_queue internal flags
ALSA: rawmidi: Access runtime->avail always in spinlock
fcntl: Fix potential deadlock in send_sig{io, urg}()
rtc: sun6i: Fix memleak in sun6i_rtc_clk_init
module: set MODULE_STATE_GOING state when a module fails to load
quota: Don't overflow quota file offsets
powerpc: sysdev: add missing iounmap() on error in mpic_msgr_probe()
NFSv4: Fix a pNFS layout related use-after-free race when freeing the inode
module: delay kobject uevent until after module init call
ALSA: pcm: Clear the full allocated memory at hw_params
dm verity: skip verity work if I/O error when system is shutting down
Linux 4.19.165
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Change-Id: I211fed33aec407a84504c9031ad723890263d943
|
||
|
|
bd59edc2be |
Merge remote-tracking branch 'partner/upstream-f2fs-stable-linux-4.19.y' into android-msm-pixel-4.19
* partner/upstream-f2fs-stable-linux-4.19.y:
f2fs: compress: fix compression chksum
f2fs: fix shift-out-of-bounds in sanity_check_raw_super()
f2fs: fix race of pending_pages in decompression
f2fs: fix to account inline xattr correctly during recovery
f2fs: inline: fix wrong inline inode stat
f2fs: inline: correct comment in f2fs_recover_inline_data
f2fs: don't check PAGE_SIZE again in sanity_check_raw_super()
f2fs: convert to F2FS_*_INO macro
f2fs: introduce max_io_bytes, a sysfs entry, to limit bio size
f2fs: don't allow any writes on readonly mount
f2fs: avoid race condition for shrinker count
f2fs: add F2FS_IOC_DECOMPRESS_FILE and F2FS_IOC_COMPRESS_FILE
f2fs: add compress_mode mount option
f2fs: Remove unnecessary unlikely()
f2fs: init dirty_secmap incorrectly
f2fs: remove buffer_head which has 32bits limit
f2fs: fix wrong block count instead of bytes
f2fs: use new conversion functions between blks and bytes
f2fs: rename logical_to_blk and blk_to_logical
f2fs: fix kbytes written stat for multi-device case
f2fs: compress: support chksum
f2fs: fix to avoid REQ_TIME and CP_TIME collision
f2fs: change to use rwsem for cp_mutex
f2fs: Handle casefolding with Encryption
fscrypt: Have filesystems handle their d_ops
libfs: Add generic function for setting dentry_ops
f2fs: Remove the redundancy initialization
f2fs: remove writeback_inodes_sb in f2fs_remount
f2fs: fix double free of unicode map
f2fs: fix compat F2FS_IOC_{MOVE,GARBAGE_COLLECT}_RANGE
f2fs: avoid unneeded data copy in f2fs_ioc_move_range()
f2fs: add F2FS_IOC_SET_COMPRESS_OPTION ioctl
f2fs: add F2FS_IOC_GET_COMPRESS_OPTION ioctl
f2fs: move ioctl interface definitions to separated file
f2fs: fix to seek incorrect data offset in inline data file
f2fs: call f2fs_get_meta_page_retry for nat page
fscrypt: rename DCACHE_ENCRYPTED_NAME to DCACHE_NOKEY_NAME
fscrypt: don't call no-key names "ciphertext names"
fscrypt: export fscrypt_d_revalidate()
Bug: 174873661
Signed-off-by: Jaegeuk Kim <jaegeuk@google.com>
Change-Id: I31286969179237aeeafec3b9abeecb21fca08e08
|
||
|
|
04d57a86ea |
fscrypt: Have filesystems handle their d_ops
This shifts the responsibility of setting up dentry operations from fscrypt to the individual filesystems, allowing them to have their own operations while still setting fscrypt's d_revalidate as appropriate. Most filesystems can just use generic_set_encrypted_ci_d_ops, unless they have their own specific dentry operations as well. That operation will set the minimal d_ops required under the circumstances. Since the fscrypt d_ops are set later on, we must set all d_ops there, since we cannot adjust those later on. This should not result in any change in behavior. Signed-off-by: Daniel Rosenberg <drosen@google.com> Acked-by: Theodore Ts'o <tytso@mit.edu> Acked-by: Eric Biggers <ebiggers@google.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org> |
||
|
|
eb2969d863 |
fscrypt: rename DCACHE_ENCRYPTED_NAME to DCACHE_NOKEY_NAME
Originally we used the term "encrypted name" or "ciphertext name" to mean the encoded filename that is shown when an encrypted directory is listed without its key. But these terms are ambiguous since they also mean the filename stored on-disk. "Encrypted name" is especially ambiguous since it could also be understood to mean "this filename is encrypted on-disk", similar to "encrypted file". So we've started calling these encoded names "no-key names" instead. Therefore, rename DCACHE_ENCRYPTED_NAME to DCACHE_NOKEY_NAME to avoid confusion about what this flag means. Link: https://lore.kernel.org/r/20200924042624.98439-3-ebiggers@kernel.org Signed-off-by: Eric Biggers <ebiggers@google.com> |
||
|
|
c61bae0801 |
fscrypt: don't call no-key names "ciphertext names"
Currently we're using the term "ciphertext name" ambiguously because it can mean either the actual ciphertext filename, or the encoded filename that is shown when an encrypted directory is listed without its key. The latter we're now usually calling the "no-key name"; and while it's derived from the ciphertext name, it's not the same thing. To avoid this ambiguity, rename fscrypt_name::is_ciphertext_name to fscrypt_name::is_nokey_name, and update comments that say "ciphertext name" (or "encrypted name") to say "no-key name" instead when warranted. Link: https://lore.kernel.org/r/20200924042624.98439-2-ebiggers@kernel.org Signed-off-by: Eric Biggers <ebiggers@google.com> |
||
|
|
0f511eb410 |
fscrypt: export fscrypt_d_revalidate()
Dentries that represent no-key names must have a dentry_operations that includes fscrypt_d_revalidate(). Currently, this is handled by fscrypt_prepare_lookup() installing fscrypt_d_ops. However, ceph support for encryption (https://lore.kernel.org/r/20200914191707.380444-1-jlayton@kernel.org) can't use fscrypt_d_ops, since ceph already has its own dentry_operations. Similarly, ext4 and f2fs support for directories that are both encrypted and casefolded (https://lore.kernel.org/r/20200923010151.69506-1-drosen@google.com) can't use fscrypt_d_ops either, since casefolding requires some dentry operations too. To satisfy both users, we need to move the responsibility of installing the dentry_operations to filesystems. In preparation for this, export fscrypt_d_revalidate() and give it a !CONFIG_FS_ENCRYPTION stub. Reviewed-by: Jeff Layton <jlayton@kernel.org> Link: https://lore.kernel.org/r/20200924054721.187797-1-ebiggers@kernel.org Signed-off-by: Eric Biggers <ebiggers@google.com> |
||
|
|
b699b0067c |
fscrypt: fix race where ->lookup() marks plaintext dentry as ciphertext
commit b01531db6cec2aa330dbc91bfbfaaef4a0d387a4 upstream.
->lookup() in an encrypted directory begins as follows:
1. fscrypt_prepare_lookup():
a. Try to load the directory's encryption key.
b. If the key is unavailable, mark the dentry as a ciphertext name
via d_flags.
2. fscrypt_setup_filename():
a. Try to load the directory's encryption key.
b. If the key is available, encrypt the name (treated as a plaintext
name) to get the on-disk name. Otherwise decode the name
(treated as a ciphertext name) to get the on-disk name.
But if the key is concurrently added, it may be found at (2a) but not at
(1a). In this case, the dentry will be wrongly marked as a ciphertext
name even though it was actually treated as plaintext.
This will cause the dentry to be wrongly invalidated on the next lookup,
potentially causing problems. For example, if the racy ->lookup() was
part of sys_mount(), then the new mount will be detached when anything
tries to access it. This is despite the mountpoint having a plaintext
path, which should remain valid now that the key was added.
Of course, this is only possible if there's a userspace race. Still,
the additional kernel-side race is confusing and unexpected.
Close the kernel-side race by changing fscrypt_prepare_lookup() to also
set the on-disk filename (step 2b), consistent with the d_flags update.
Fixes:
|
||
|
|
000d849574 |
fscrypt: fix race allowing rename() and link() of ciphertext dentries
commit 968dd6d0c6d6b6a989c6ddb9e2584a031b83e7b5 upstream. Close some race conditions where fscrypt allowed rename() and link() on ciphertext dentries that had been looked up just prior to the key being concurrently added. It's better to return -ENOKEY in this case. This avoids doing the nonsensical thing of encrypting the names a second time when searching for the actual on-disk dir entries. It also guarantees that DCACHE_ENCRYPTED_NAME dentries are never rename()d, so the dcache won't have support all possible combinations of moving DCACHE_ENCRYPTED_NAME around during __d_move(). Signed-off-by: Eric Biggers <ebiggers@google.com> Signed-off-by: Theodore Ts'o <tytso@mit.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> |
||
|
|
1ae161d27b |
fscrypt: clean up and improve dentry revalidation
commit 6cc248684d3d23bbd073ae2fa73d3416c0558909 upstream. Make various improvements to fscrypt dentry revalidation: - Don't try to handle the case where the per-directory key is removed, as this can't happen without the inode (and dentries) being evicted. - Flag ciphertext dentries rather than plaintext dentries, since it's ciphertext dentries that need the special handling. - Avoid doing unnecessary work for non-ciphertext dentries. - When revalidating ciphertext dentries, try to set up the directory's i_crypt_info to make sure the key is really still absent, rather than invalidating all negative dentries as the previous code did. An old comment suggested we can't do this for locking reasons, but AFAICT this comment was outdated and it actually works fine. Signed-off-by: Eric Biggers <ebiggers@google.com> Signed-off-by: Theodore Ts'o <tytso@mit.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> |
||
|
|
705ac26aed |
fscrypt: return -EXDEV for incompatible rename or link into encrypted dir
commit f5e55e777cc93eae1416f0fa4908e8846b6d7825 upstream. Currently, trying to rename or link a regular file, directory, or symlink into an encrypted directory fails with EPERM when the source file is unencrypted or is encrypted with a different encryption policy, and is on the same mountpoint. It is correct for the operation to fail, but the choice of EPERM breaks tools like 'mv' that know to copy rather than rename if they see EXDEV, but don't know what to do with EPERM. Our original motivation for EPERM was to encourage users to securely handle their data. Encrypting files by "moving" them into an encrypted directory can be insecure because the unencrypted data may remain in free space on disk, where it can later be recovered by an attacker. It's much better to encrypt the data from the start, or at least try to securely delete the source data e.g. using the 'shred' program. However, the current behavior hasn't been effective at achieving its goal because users tend to be confused, hack around it, and complain; see e.g. https://github.com/google/fscrypt/issues/76. And in some cases it's actually inconsistent or unnecessary. For example, 'mv'-ing files between differently encrypted directories doesn't work even in cases where it can be secure, such as when in userspace the same passphrase protects both directories. Yet, you *can* already 'mv' unencrypted files into an encrypted directory if the source files are on a different mountpoint, even though doing so is often insecure. There are probably better ways to teach users to securely handle their files. For example, the 'fscrypt' userspace tool could provide a command that migrates unencrypted files into an encrypted directory, acting like 'shred' on the source files and providing appropriate warnings depending on the type of the source filesystem and disk. Receiving errors on unimportant files might also force some users to disable encryption, thus making the behavior counterproductive. It's desirable to make encryption as unobtrusive as possible. Therefore, change the error code from EPERM to EXDEV so that tools looking for EXDEV will fall back to a copy. This, of course, doesn't prevent users from still doing the right things to securely manage their files. Note that this also matches the behavior when a file is renamed between two project quota hierarchies; so there's precedent for using EXDEV for things other than mountpoints. xfstests generic/398 will require an update with this change. [Rewritten from an earlier patch series by Michael Halcrow.] Cc: Michael Halcrow <mhalcrow@google.com> Cc: Joe Richey <joerichey@google.com> Signed-off-by: Eric Biggers <ebiggers@google.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> |
||
|
|
4da740c10d |
Revert "ANDROID: fscrypt: add key removal notifier chain"
This reverts commit 98261f39e992543a404353ba2d8f36cb739f329f because it was only needed for sdcardfs, which has now been removed. Bug: 157700134 Bug: 142275883 Change-Id: Iaf22521ef47d48ce9c9c0604a8b2412e3b8c1faa Signed-off-by: Eric Biggers <ebiggers@google.com> |
||
|
|
0764ced2f0 |
Merge remote-tracking branch 'aosp/upstream-f2fs-stable-linux-4.19.y' into android-4.19-stable
* aosp/upstream-f2fs-stable-linux-4.19.y:
fscrypt: remove stale definition
fs-verity: remove unnecessary extern keywords
fs-verity: fix all kerneldoc warnings
fscrypt: add support for IV_INO_LBLK_32 policies
fscrypt: make test_dummy_encryption use v2 by default
fscrypt: support test_dummy_encryption=v2
fscrypt: add fscrypt_add_test_dummy_key()
linux/parser.h: add include guards
fscrypt: remove unnecessary extern keywords
fscrypt: name all function parameters
fscrypt: fix all kerneldoc warnings
Conflicts:
fs/crypto/fscrypt_private.h
fs/crypto/keyring.c
fs/crypto/keysetup.c
fs/ext4/ext4.h
fs/ext4/super.c
fs/f2fs/f2fs.h
fs/f2fs/super.c
include/linux/fscrypt.h
Resolved the conflicts as per the corresponding android-mainline change,
I7198edbca759839aceeec2598e7a81305756c4d7.
Bug: 154167995
Test: kvm-xfstests -c ext4,f2fs,ext4/encrypt,f2fs/encrypt \
-g encrypt -g verity -g casefold
kvm-xfstests -c ext4,f2fs,ext4/encrypt,f2fs/encrypt \
-g encrypt -g verity -g casefold -m inlinecrypt
Change-Id: Id12839f7948374575f9d15eee6a9c6a9382eacf3
Signed-off-by: Eric Biggers <ebiggers@google.com>
|
||
|
|
2aedb8ff69 |
fscrypt: remove stale definition
Fixes wrong merge resolution only in f2fs-stable. Signed-off-by: Jaegeuk Kim <jaegeuk@google.com> |
||
|
|
3325bdad51 |
fscrypt: support test_dummy_encryption=v2
v1 encryption policies are deprecated in favor of v2, and some new
features (e.g. encryption+casefolding) are only being added for v2.
Therefore, the "test_dummy_encryption" mount option (which is used for
encryption I/O testing with xfstests) needs to support v2 policies.
To do this, extend its syntax to be "test_dummy_encryption=v1" or
"test_dummy_encryption=v2". The existing "test_dummy_encryption" (no
argument) also continues to be accepted, to specify the default setting
-- currently v1, but the next patch changes it to v2.
To cleanly support both v1 and v2 while also making it easy to support
specifying other encryption settings in the future (say, accepting
"$contents_mode:$filenames_mode:v2"), make ext4 and f2fs maintain a
pointer to the dummy fscrypt_context rather than using mount flags.
To avoid concurrency issues, don't allow test_dummy_encryption to be set
or changed during a remount. (The former restriction is new, but
xfstests doesn't run into it, so no one should notice.)
Tested with 'gce-xfstests -c {ext4,f2fs}/encrypt -g auto'. On ext4,
there are two regressions, both of which are test bugs: ext4/023 and
ext4/028 fail because they set an xattr and expect it to be stored
inline, but the increase in size of the fscrypt_context from
24 to 40 bytes causes this xattr to be spilled into an external block.
Link: https://lore.kernel.org/r/20200512233251.118314-4-ebiggers@kernel.org
Acked-by: Jaegeuk Kim <jaegeuk@kernel.org>
Reviewed-by: Theodore Ts'o <tytso@mit.edu>
Signed-off-by: Eric Biggers <ebiggers@google.com>
|
||
|
|
bece9b9243 |
fscrypt: remove unnecessary extern keywords
Remove the unnecessary 'extern' keywords from function declarations. This makes it so that we don't have a mix of both styles, so it won't be ambiguous what to use in new fscrypt patches. This also makes the code shorter and matches the 'checkpatch --strict' expectation. Link: https://lore.kernel.org/r/20200511191358.53096-4-ebiggers@kernel.org Signed-off-by: Eric Biggers <ebiggers@google.com> |
||
|
|
612381d5bb |
fscrypt: name all function parameters
Name all the function parameters. This makes it so that we don't have a mix of both styles, so it won't be ambiguous what to use in new fscrypt patches. This also matches the checkpatch expectation. Link: https://lore.kernel.org/r/20200511191358.53096-3-ebiggers@kernel.org Signed-off-by: Eric Biggers <ebiggers@google.com> |
||
|
|
4c82d08cea |
fscrypt: fix all kerneldoc warnings
Fix all kerneldoc warnings in fs/crypto/ and include/linux/fscrypt.h.
Most of these were due to missing documentation for function parameters.
Detected with:
scripts/kernel-doc -v -none fs/crypto/*.{c,h} include/linux/fscrypt.h
This cleanup makes it possible to check new patches for kerneldoc
warnings without having to filter out all the existing ones.
For consistency, also adjust some function "brief descriptions" to
include the parentheses and to wrap at 80 characters. (The latter
matches the checkpatch expectation.)
Link: https://lore.kernel.org/r/20200511191358.53096-2-ebiggers@kernel.org
Signed-off-by: Eric Biggers <ebiggers@google.com>
|
||
|
|
cfc3461a04 |
ANDROID: fscrypt: handle direct I/O with IV_INO_LBLK_32
With the existing fscrypt IV generation methods, each file's data blocks
have contiguous DUNs. Therefore the direct I/O code "just worked"
because it only submits logically contiguous bios. But with
IV_INO_LBLK_32, the direct I/O code breaks because the DUN can wrap from
0xffffffff to 0. We can't submit bios across such boundaries.
This is especially difficult to handle when block_size != PAGE_SIZE,
since in that case the DUN can wrap in the middle of a page. Punt on
this case for now and just handle block_size == PAGE_SIZE.
Add and use a new function fscrypt_dio_supported() to check whether a
direct I/O request is unsupported due to encryption constraints.
Then, update fs/direct-io.c (used by f2fs, and by ext4 in kernel v5.4
and earlier) and fs/iomap/direct-io.c (used by ext4 in kernel v5.5 and
later) to avoid submitting I/O across a DUN discontinuity.
(This is needed in ACK now because ACK already supports direct I/O with
inline crypto. I'll be sending this upstream along with the encrypted
direct I/O support itself once its prerequisites are closer to landing.)
(cherry picked from android-mainline commit
8d6c90c9d68b985fa809626d12f8c9aff3c9dcb1)
Conflicts:
fs/ext4/file.c
fs/iomap/direct-io.c
(Dropped the iomap changes because in kernel v5.4 and earlier,
ext4 doesn't use iomap for direct I/O)
Test: For now, just manually tested direct I/O on ext4 and f2fs in the
DUN discontinuity case.
Bug: 144046242
Change-Id: I0c0b0b20a73ade35c3660cc6f9c09d49d3853ba5
Signed-off-by: Eric Biggers <ebiggers@google.com>
|
||
|
|
ecf91c963d |
fscrypt: add FS_IOC_GET_ENCRYPTION_NONCE ioctl
Add an ioctl FS_IOC_GET_ENCRYPTION_NONCE which retrieves the nonce from an encrypted file or directory. The nonce is the 16-byte random value stored in the inode's encryption xattr. It is normally used together with the master key to derive the inode's actual encryption key. The nonces are needed by automated tests that verify the correctness of the ciphertext on-disk. Except for the IV_INO_LBLK_64 case, there's no way to replicate a file's ciphertext without knowing that file's nonce. The nonces aren't secret, and the existing ciphertext verification tests in xfstests retrieve them from disk using debugfs or dump.f2fs. But in environments that lack these debugging tools, getting the nonces by manually parsing the filesystem structure would be very hard. To make this important type of testing much easier, let's just add an ioctl that retrieves the nonce. Link: https://lore.kernel.org/r/20200314205052.93294-2-ebiggers@kernel.org Reviewed-by: Theodore Ts'o <tytso@mit.edu> Signed-off-by: Eric Biggers <ebiggers@google.com> |
||
|
|
4182a31c77 |
UPSTREAM: fscrypt: add FS_IOC_GET_ENCRYPTION_NONCE ioctl
Add an ioctl FS_IOC_GET_ENCRYPTION_NONCE which retrieves the nonce from an encrypted file or directory. The nonce is the 16-byte random value stored in the inode's encryption xattr. It is normally used together with the master key to derive the inode's actual encryption key. The nonces are needed by automated tests that verify the correctness of the ciphertext on-disk. Except for the IV_INO_LBLK_64 case, there's no way to replicate a file's ciphertext without knowing that file's nonce. The nonces aren't secret, and the existing ciphertext verification tests in xfstests retrieve them from disk using debugfs or dump.f2fs. But in environments that lack these debugging tools, getting the nonces by manually parsing the filesystem structure would be very hard. To make this important type of testing much easier, let's just add an ioctl that retrieves the nonce. Link: https://lore.kernel.org/r/20200314205052.93294-2-ebiggers@kernel.org Reviewed-by: Theodore Ts'o <tytso@mit.edu> (cherry picked from commit e98ad464750c0894bc560d10503dae8ff90ccdac) Bug: 151100202 Change-Id: Ieef2c57b9257ae38eb2e5c1a018ca6f325bb62dd Signed-off-by: Eric Biggers <ebiggers@google.com> |
||
|
|
af2b6eaa10 |
FROMLIST: fscrypt: Have filesystems handle their d_ops
This shifts the responsibility of setting up dentry operations from fscrypt to the individual filesystems, allowing them to have their own operations while still setting fscrypt's d_revalidate as appropriate. Also added helper function to libfs to unify ext4 and f2fs implementations. Signed-off-by: Daniel Rosenberg <drosen@google.com> Test: Boots, /data/media is case insensitive Bug: 138322712 Link: https://lore.kernel.org/linux-f2fs-devel/20200208013552.241832-1-drosen@google.com/T/#t Change-Id: Iaf77f8c5961ecf22e22478701ab0b7fe2025225d |
||
|
|
b60858fe82 |
Merge remote-tracking branch 'aosp/upstream-f2fs-stable-linux-4.19.y' into android-4.19
* aosp/upstream-f2fs-stable-linux-4.19.y:
fs-verity: use u64_to_user_ptr()
fs-verity: use mempool for hash requests
fs-verity: implement readahead of Merkle tree pages
fs-verity: implement readahead for FS_IOC_ENABLE_VERITY
fscrypt: improve format of no-key names
ubifs: allow both hash and disk name to be provided in no-key names
ubifs: don't trigger assertion on invalid no-key filename
fscrypt: clarify what is meant by a per-file key
fscrypt: derive dirhash key for casefolded directories
fscrypt: don't allow v1 policies with casefolding
fscrypt: add "fscrypt_" prefix to fname_encrypt()
fscrypt: don't print name of busy file when removing key
fscrypt: document gfp_flags for bounce page allocation
fscrypt: optimize fscrypt_zeroout_range()
fscrypt: remove redundant bi_status check
fscrypt: Allow modular crypto algorithms
fscrypt: include <linux/ioctl.h> in UAPI header
fscrypt: don't check for ENOKEY from fscrypt_get_encryption_info()
fscrypt: remove fscrypt_is_direct_key_policy()
fscrypt: move fscrypt_valid_enc_modes() to policy.c
fscrypt: check for appropriate use of DIRECT_KEY flag earlier
fscrypt: split up fscrypt_supported_policy() by policy version
fscrypt: introduce fscrypt_needs_contents_encryption()
fscrypt: move fscrypt_d_revalidate() to fname.c
fscrypt: constify inode parameter to filename encryption functions
fscrypt: constify struct fscrypt_hkdf parameter to fscrypt_hkdf_expand()
fscrypt: verify that the crypto_skcipher has the correct ivsize
fscrypt: use crypto_skcipher_driver_name()
fscrypt: support passing a keyring key to FS_IOC_ADD_ENCRYPTION_KEY
keys: Export lookup_user_key to external users
Conflicts:
fs/crypto/Kconfig
fs/crypto/bio.c
fs/crypto/fname.c
fs/crypto/fscrypt_private.h
fs/crypto/keyring.c
fs/crypto/keysetup.c
fs/ubifs/dir.c
include/uapi/linux/fscrypt.h
Resolved the conflicts as per the corresponding android-mainline change,
Ib1e6b9eda8fb5dcfc6bdc8fa89d93f72b088c5f6.
Bug: 148667616
Change-Id: I5f8b846f0cd4d5403d8c61b9e12acb4581fac6f7
Signed-off-by: Eric Biggers <ebiggers@google.com>
|
||
|
|
86eb43f574 |
fscrypt: improve format of no-key names
When an encrypted directory is listed without the key, the filesystem must show "no-key names" that uniquely identify directory entries, are at most 255 (NAME_MAX) bytes long, and don't contain '/' or '\0'. Currently, for short names the no-key name is the base64 encoding of the ciphertext filename, while for long names it's the base64 encoding of the ciphertext filename's dirhash and second-to-last 16-byte block. This format has the following problems: - Since it doesn't always include the dirhash, it's incompatible with directories that will use a secret-keyed dirhash over the plaintext filenames. In this case, the dirhash won't be computable from the ciphertext name without the key, so it instead must be retrieved from the directory entry and always included in the no-key name. Casefolded encrypted directories will use this type of dirhash. - It's ambiguous: it's possible to craft two filenames that map to the same no-key name, since the method used to abbreviate long filenames doesn't use a proper cryptographic hash function. Solve both these problems by switching to a new no-key name format that is the base64 encoding of a variable-length structure that contains the dirhash, up to 149 bytes of the ciphertext filename, and (if any bytes remain) the SHA-256 of the remaining bytes of the ciphertext filename. This ensures that each no-key name contains everything needed to find the directory entry again, contains only legal characters, doesn't exceed NAME_MAX, is unambiguous unless there's a SHA-256 collision, and that we only take the performance hit of SHA-256 on very long filenames. Note: this change does *not* address the existing issue where users can modify the 'dirhash' part of a no-key name and the filesystem may still accept the name. Signed-off-by: Daniel Rosenberg <drosen@google.com> [EB: improved comments and commit message, fixed checking return value of base64_decode(), check for SHA-256 error, continue to set disk_name for short names to keep matching simpler, and many other cleanups] Link: https://lore.kernel.org/r/20200120223201.241390-7-ebiggers@kernel.org Signed-off-by: Eric Biggers <ebiggers@google.com> |
||
|
|
7495f91bb5 |
fscrypt: derive dirhash key for casefolded directories
When we allow indexed directories to use both encryption and casefolding, for the dirhash we can't just hash the ciphertext filenames that are stored on-disk (as is done currently) because the dirhash must be case insensitive, but the stored names are case-preserving. Nor can we hash the plaintext names with an unkeyed hash (or a hash keyed with a value stored on-disk like ext4's s_hash_seed), since that would leak information about the names that encryption is meant to protect. Instead, if we can accept a dirhash that's only computable when the fscrypt key is available, we can hash the plaintext names with a keyed hash using a secret key derived from the directory's fscrypt master key. We'll use SipHash-2-4 for this purpose. Prepare for this by deriving a SipHash key for each casefolded encrypted directory. Make sure to handle deriving the key not only when setting up the directory's fscrypt_info, but also in the case where the casefold flag is enabled after the fscrypt_info was already set up. (We could just always derive the key regardless of casefolding, but that would introduce unnecessary overhead for people not using casefolding.) Signed-off-by: Daniel Rosenberg <drosen@google.com> [EB: improved commit message, updated fscrypt.rst, squashed with change that avoids unnecessarily deriving the key, and many other cleanups] Link: https://lore.kernel.org/r/20200120223201.241390-3-ebiggers@kernel.org Signed-off-by: Eric Biggers <ebiggers@google.com> |
||
|
|
f4951340a1 |
fscrypt: don't allow v1 policies with casefolding
Casefolded encrypted directories will use a new dirhash method that requires a secret key. If the directory uses a v2 encryption policy, it's easy to derive this key from the master key using HKDF. However, v1 encryption policies don't provide a way to derive additional keys. Therefore, don't allow casefolding on directories that use a v1 policy. Specifically, make it so that trying to enable casefolding on a directory that has a v1 policy fails, trying to set a v1 policy on a casefolded directory fails, and trying to open a casefolded directory that has a v1 policy (if one somehow exists on-disk) fails. Signed-off-by: Daniel Rosenberg <drosen@google.com> [EB: improved commit message, updated fscrypt.rst, and other cleanups] Link: https://lore.kernel.org/r/20200120223201.241390-2-ebiggers@kernel.org Signed-off-by: Eric Biggers <ebiggers@google.com> |
||
|
|
3597e506e5 |
fscrypt: introduce fscrypt_needs_contents_encryption()
Add a function fscrypt_needs_contents_encryption() which takes an inode and returns true if it's an encrypted regular file and the kernel was built with fscrypt support. This will allow replacing duplicated checks of IS_ENCRYPTED() && S_ISREG() on the I/O paths in ext4 and f2fs, while also optimizing out unneeded code when !CONFIG_FS_ENCRYPTION. Link: https://lore.kernel.org/r/20191209205021.231767-1-ebiggers@kernel.org Signed-off-by: Eric Biggers <ebiggers@google.com> |
||
|
|
bac335ab74 |
fscrypt: constify inode parameter to filename encryption functions
Constify the struct inode parameter to fscrypt_fname_disk_to_usr() and the other filename encryption functions so that users don't have to pass in a non-const inode when they are dealing with a const one, as in [1]. [1] https://lkml.kernel.org/linux-ext4/20191203051049.44573-6-drosen@google.com/ Cc: Daniel Rosenberg <drosen@google.com> Link: https://lore.kernel.org/r/20191215213947.9521-1-ebiggers@kernel.org Signed-off-by: Eric Biggers <ebiggers@google.com> |
||
|
|
b32863f17f |
ANDROID: dm: add dm-default-key target for metadata encryption
Add a device-mapper target "dm-default-key" which assigns an encryption key to bios that aren't for the contents of an encrypted file. This ensures that all blocks on-disk will be encrypted with some key, without the performance hit of file contents being encrypted twice when fscrypt (File-Based Encryption) is used. It is only appropriate to use dm-default-key when key configuration is tightly controlled, like it is in Android, such that all fscrypt keys are at least as hard to compromise as the default key. Compared to the original version of dm-default-key, this has been modified to use the new vendor-independent inline encryption framework (which works even when no inline encryption hardware is present), the table syntax has been changed to match dm-crypt, and support for specifying Adiantum encryption has been added. These changes also mean that dm-default-key now always explicitly specifies the DUN (the IV). Also, to handle f2fs moving blocks of encrypted files around without the key, and to handle ext4 and f2fs filesystems mounted without '-o inlinecrypt', the mapping logic is no longer "set a key on the bio if it doesn't have one already", but rather "set a key on the bio unless the bio has the bi_skip_dm_default_key flag set". Filesystems set this flag on *all* bios for encrypted file contents, regardless of whether they are encrypting/decrypting the file using inline encryption or the traditional filesystem-layer encryption, or moving the raw data. For the bi_skip_dm_default_key flag, a new field in struct bio is used rather than a bit in bi_opf so that fscrypt_set_bio_crypt_ctx() can set the flag, minimizing the changes needed to filesystems. (bi_opf is usually overwritten after fscrypt_set_bio_crypt_ctx() is called.) Bug: 137270441 Bug: 147814592 Change-Id: I69c9cd1e968ccf990e4ad96e5115b662237f5095 Signed-off-by: Eric Biggers <ebiggers@google.com> |
||
|
|
b01c73ea71 |
BACKPORT: FROMLIST: Update Inline Encryption from v5 to v6 of patch series
Changes v5 => v6: - Blk-crypto's kernel crypto API fallback is no longer restricted to 8-byte DUNs. It's also now separately configurable from blk-crypto, and can be disabled entirely, while still allowing the kernel to use inline encryption hardware. Further, struct bio_crypt_ctx takes up less space, and no longer contains the information needed by the crypto API fallback - the fallback allocates the required memory when necessary. - Blk-crypto now supports all file content encryption modes supported by fscrypt. - Fixed bio merging logic in blk-merge.c - Fscrypt now supports inline encryption with the direct key policy, since blk-crypto now has support for larger DUNs. - Keyslot manager now uses a hashtable to lookup which keyslot contains any particular key (thanks Eric!) - Fscrypt support for inline encryption now handles filesystems with multiple underlying block devices (thanks Eric!) - Numerous cleanups Bug: 137270441 Test: refer to I26376479ee38259b8c35732cb3a1d7e15f9b05a3 Change-Id: I13e2e327e0b4784b394cb1e7cf32a04856d95f01 Link: https://lore.kernel.org/linux-block/20191218145136.172774-1-satyat@google.com/ Signed-off-by: Satya Tangirala <satyat@google.com> |
||
|
|
d679fad505 |
fscrypt: add support for IV_INO_LBLK_64 policies
Inline encryption hardware compliant with the UFS v2.1 standard or with
the upcoming version of the eMMC standard has the following properties:
(1) Per I/O request, the encryption key is specified by a previously
loaded keyslot. There might be only a small number of keyslots.
(2) Per I/O request, the starting IV is specified by a 64-bit "data unit
number" (DUN). IV bits 64-127 are assumed to be 0. The hardware
automatically increments the DUN for each "data unit" of
configurable size in the request, e.g. for each filesystem block.
Property (1) makes it inefficient to use the traditional fscrypt
per-file keys. Property (2) precludes the use of the existing
DIRECT_KEY fscrypt policy flag, which needs at least 192 IV bits.
Therefore, add a new fscrypt policy flag IV_INO_LBLK_64 which causes the
encryption to modified as follows:
- The encryption keys are derived from the master key, encryption mode
number, and filesystem UUID.
- The IVs are chosen as (inode_number << 32) | file_logical_block_num.
For filenames encryption, file_logical_block_num is 0.
Since the file nonces aren't used in the key derivation, many files may
share the same encryption key. This is much more efficient on the
target hardware. Including the inode number in the IVs and mixing the
filesystem UUID into the keys ensures that data in different files is
nevertheless still encrypted differently.
Additionally, limiting the inode and block numbers to 32 bits and
placing the block number in the low bits maintains compatibility with
the 64-bit DUN convention (property (2) above).
Since this scheme assumes that inode numbers are stable (which may
preclude filesystem shrinking) and that inode and file logical block
numbers are at most 32-bit, IV_INO_LBLK_64 will only be allowed on
filesystems that meet these constraints. These are acceptable
limitations for the cases where this format would actually be used.
Note that IV_INO_LBLK_64 is an on-disk format, not an implementation.
This patch just adds support for it using the existing filesystem layer
encryption. A later patch will add support for inline encryption.
Reviewed-by: Paul Crowley <paulcrowley@google.com>
Co-developed-by: Satya Tangirala <satyat@google.com>
Signed-off-by: Satya Tangirala <satyat@google.com>
Signed-off-by: Eric Biggers <ebiggers@google.com>
|
||
|
|
51ee7a19e8 |
fscrypt: remove struct fscrypt_ctx
Now that ext4 and f2fs implement their own post-read workflow that supports both fscrypt and fsverity, the fscrypt-only workflow based around struct fscrypt_ctx is no longer used. So remove the unused code. This is based on a patch from Chandan Rajendra's "Consolidate FS read I/O callbacks code" patchset, but rebased onto the latest kernel, folded __fscrypt_decrypt_bio() into fscrypt_decrypt_bio(), cleaned up fscrypt_initialize(), and updated the commit message. Originally-from: Chandan Rajendra <chandan@linux.ibm.com> Signed-off-by: Eric Biggers <ebiggers@google.com> |
||
|
|
0797369594 |
BACKPORT: FROMLIST: fscrypt: add inline encryption support
Add support for inline encryption to fs/crypto/. With "inline encryption", the block layer handles the decryption/encryption as part of the bio, instead of the filesystem doing the crypto itself via Linux's crypto API. This model is needed in order to take advantage of the inline encryption hardware present on most modern mobile SoCs. To use inline encryption, the filesystem needs to be mounted with '-o inlinecrypt'. The contents of any AES-256-XTS encrypted files will then be encrypted using blk-crypto, instead of using the traditional filesystem-layer crypto. fscrypt still provides the key and IV to use, and the actual ciphertext on-disk is still the same; therefore it's testable using the existing fscrypt ciphertext verification tests. Note that since blk-crypto has a fallack to Linux's crypto API, this feature is usable and testable even without actual inline encryption hardware. Per-filesystem changes will be needed to set encryption contexts when submitting bios and to implement the 'inlinecrypt' mount option. This patch just adds the common code. Bug: 137270441 Test: tested as series; see I26aac0ac7845a9064f28bb1421eb2522828a6dec Change-Id: I238b5484f3798dd4d829be5535234b53951db0ea Co-developed-by: Eric Biggers <ebiggers@google.com> Signed-off-by: Eric Biggers <ebiggers@google.com> Signed-off-by: Satya Tangirala <satyat@google.com> Link: https://patchwork.kernel.org/patch/11214761/ |
||
|
|
94231712cf |
BACKPORT: FROMLIST: fscrypt: add support for IV_INO_LBLK_64 policies
Inline encryption hardware compliant with the UFS v2.1 standard or with
the upcoming version of the eMMC standard has the following properties:
(1) Per I/O request, the encryption key is specified by a previously
loaded keyslot. There might be only a small number of keyslots.
(2) Per I/O request, the starting IV is specified by a 64-bit "data unit
number" (DUN). IV bits 64-127 are assumed to be 0. The hardware
automatically increments the DUN for each "data unit" of
configurable size in the request, e.g. for each filesystem block.
Property (1) makes it inefficient to use the traditional fscrypt
per-file keys. Property (2) precludes the use of the existing
DIRECT_KEY fscrypt policy flag, which needs at least 192 IV bits.
Therefore, add a new fscrypt policy flag IV_INO_LBLK_64 which causes the
encryption to modified as follows:
- The encryption keys are derived from the master key, encryption mode
number, and filesystem UUID.
- The IVs are chosen as (inode_number << 32) | file_logical_block_num.
For filenames encryption, file_logical_block_num is 0.
Since the file nonces aren't used in the key derivation, many files may
share the same encryption key. This is much more efficient on the
target hardware. Including the inode number in the IVs and mixing the
filesystem UUID into the keys ensures that data in different files is
nevertheless still encrypted differently.
Additionally, limiting the inode and block numbers to 32 bits and
placing the block number in the low bits maintains compatibility with
the 64-bit DUN convention (property (2) above).
Since this scheme assumes that inode numbers are stable (which may
preclude filesystem shrinking) and that inode and file logical block
numbers are at most 32-bit, IV_INO_LBLK_64 will only be allowed on
filesystems that meet these constraints. These are acceptable
limitations for the cases where this format would actually be used.
Note that IV_INO_LBLK_64 is an on-disk format, not an implementation.
This patch just adds support for it using the existing filesystem layer
encryption. A later patch will add support for inline encryption.
Co-developed-by: Satya Tangirala <satyat@google.com>
Signed-off-by: Satya Tangirala <satyat@google.com>
Signed-off-by: Eric Biggers <ebiggers@google.com>
Change-Id: Iedecd7fa1ce8eefffdec57257e27e679938b0ad7
Signed-off-by: Satya Tangirala <satyat@google.com>
Link: https://patchwork.kernel.org/patch/11210909/
|
||
|
|
97c9fb779b |
FROMLIST: fscrypt: remove struct fscrypt_ctx
Now that ext4 and f2fs implement their own post-read workflow that supports both fscrypt and fsverity, the fscrypt-only workflow based around struct fscrypt_ctx is no longer used. So remove the unused code. This is based on a patch from Chandan Rajendra's "Consolidate FS read I/O callbacks code" patchset, but rebased onto the latest kernel, folded __fscrypt_decrypt_bio() into fscrypt_decrypt_bio(), cleaned up fscrypt_initialize(), and updated the commit message. Change-Id: I21d126db69eea53c3e6dcec8710fa06ae35f980d Originally-from: Chandan Rajendra <chandan@linux.ibm.com> Signed-off-by: Eric Biggers <ebiggers@google.com> Signed-off-by: Satya Tangirala <satyat@google.com> Link: https://patchwork.kernel.org/patch/11182387/ |
||
|
|
4932f53723 |
ANDROID: fscrypt: add key removal notifier chain
Add a notifier chain so that sdcardfs can evict its dentries when an fscrypt key is about to be removed. This is needed for the FS_IOC_REMOVE_ENCRYPTION_KEY ioctl to properly "lock" the encrypted files underneath sdcardfs when an Android user is stopped. This is meant to be a temporary patch carried as part of the sdcardfs patchset until either we stop using sdcardfs, we get sdcardfs upstream, or we find a way to provide what sdcardfs needs while also benefitting a user upstream. Bug: 120446149 Bug: 142275883 Test: see I83b451a2bc40c72fcd01d24aa5c34ad8de427534 Change-Id: Iec79775a71057d05a371d77da4a6541cb8e09cb7 Signed-off-by: Eric Biggers <ebiggers@google.com> |
||
|
|
080389cb51 |
fscrypt: add FS_IOC_REMOVE_ENCRYPTION_KEY_ALL_USERS ioctl
Add a root-only variant of the FS_IOC_REMOVE_ENCRYPTION_KEY ioctl which removes all users' claims of the key, not just the current user's claim. I.e., it always removes the key itself, no matter how many users have added it. This is useful for forcing a directory to be locked, without having to figure out which user ID(s) the key was added under. This is planned to be used by a command like 'sudo fscrypt lock DIR --all-users' in the fscrypt userspace tool (http://github.com/google/fscrypt). Reviewed-by: Theodore Ts'o <tytso@mit.edu> Signed-off-by: Eric Biggers <ebiggers@google.com> |
||
|
|
73ce50dc2d |
fscrypt: v2 encryption policy support
Add a new fscrypt policy version, "v2". It has the following changes
from the original policy version, which we call "v1" (*):
- Master keys (the user-provided encryption keys) are only ever used as
input to HKDF-SHA512. This is more flexible and less error-prone, and
it avoids the quirks and limitations of the AES-128-ECB based KDF.
Three classes of cryptographically isolated subkeys are defined:
- Per-file keys, like used in v1 policies except for the new KDF.
- Per-mode keys. These implement the semantics of the DIRECT_KEY
flag, which for v1 policies made the master key be used directly.
These are also planned to be used for inline encryption when
support for it is added.
- Key identifiers (see below).
- Each master key is identified by a 16-byte master_key_identifier,
which is derived from the key itself using HKDF-SHA512. This prevents
users from associating the wrong key with an encrypted file or
directory. This was easily possible with v1 policies, which
identified the key by an arbitrary 8-byte master_key_descriptor.
- The key must be provided in the filesystem-level keyring, not in a
process-subscribed keyring.
The following UAPI additions are made:
- The existing ioctl FS_IOC_SET_ENCRYPTION_POLICY can now be passed a
fscrypt_policy_v2 to set a v2 encryption policy. It's disambiguated
from fscrypt_policy/fscrypt_policy_v1 by the version code prefix.
- A new ioctl FS_IOC_GET_ENCRYPTION_POLICY_EX is added. It allows
getting the v1 or v2 encryption policy of an encrypted file or
directory. The existing FS_IOC_GET_ENCRYPTION_POLICY ioctl could not
be used because it did not have a way for userspace to indicate which
policy structure is expected. The new ioctl includes a size field, so
it is extensible to future fscrypt policy versions.
- The ioctls FS_IOC_ADD_ENCRYPTION_KEY, FS_IOC_REMOVE_ENCRYPTION_KEY,
and FS_IOC_GET_ENCRYPTION_KEY_STATUS now support managing keys for v2
encryption policies. Such keys are kept logically separate from keys
for v1 encryption policies, and are identified by 'identifier' rather
than by 'descriptor'. The 'identifier' need not be provided when
adding a key, since the kernel will calculate it anyway.
This patch temporarily keeps adding/removing v2 policy keys behind the
same permission check done for adding/removing v1 policy keys:
capable(CAP_SYS_ADMIN). However, the next patch will carefully take
advantage of the cryptographically secure master_key_identifier to allow
non-root users to add/remove v2 policy keys, thus providing a full
replacement for v1 policies.
(*) Actually, in the API fscrypt_policy::version is 0 while on-disk
fscrypt_context::format is 1. But I believe it makes the most sense
to advance both to '2' to have them be in sync, and to consider the
numbering to start at 1 except for the API quirk.
Reviewed-by: Paul Crowley <paulcrowley@google.com>
Reviewed-by: Theodore Ts'o <tytso@mit.edu>
Signed-off-by: Eric Biggers <ebiggers@google.com>
|
||
|
|
dbfc6584b3 |
fscrypt: add FS_IOC_GET_ENCRYPTION_KEY_STATUS ioctl
Add a new fscrypt ioctl, FS_IOC_GET_ENCRYPTION_KEY_STATUS. Given a key specified by 'struct fscrypt_key_specifier' (the same way a key is specified for the other fscrypt key management ioctls), it returns status information in a 'struct fscrypt_get_key_status_arg'. The main motivation for this is that applications need to be able to check whether an encrypted directory is "unlocked" or not, so that they can add the key if it is not, and avoid adding the key (which may involve prompting the user for a passphrase) if it already is. It's possible to use some workarounds such as checking whether opening a regular file fails with ENOKEY, or checking whether the filenames "look like gibberish" or not. However, no workaround is usable in all cases. Like the other key management ioctls, the keyrings syscalls may seem at first to be a good fit for this. Unfortunately, they are not. Even if we exposed the keyring ID of the ->s_master_keys keyring and gave everyone Search permission on it (note: currently the keyrings permission system would also allow everyone to "invalidate" the keyring too), the fscrypt keys have an additional state that doesn't map cleanly to the keyrings API: the secret can be removed, but we can be still tracking the files that were using the key, and the removal can be re-attempted or the secret added again. After later patches, some applications will also need a way to determine whether a key was added by the current user vs. by some other user. Reserved fields are included in fscrypt_get_key_status_arg for this and other future extensions. Reviewed-by: Theodore Ts'o <tytso@mit.edu> Signed-off-by: Eric Biggers <ebiggers@google.com> |
||
|
|
cacc84e003 |
fscrypt: add FS_IOC_REMOVE_ENCRYPTION_KEY ioctl
Add a new fscrypt ioctl, FS_IOC_REMOVE_ENCRYPTION_KEY. This ioctl
removes an encryption key that was added by FS_IOC_ADD_ENCRYPTION_KEY.
It wipes the secret key itself, then "locks" the encrypted files and
directories that had been unlocked using that key -- implemented by
evicting the relevant dentries and inodes from the VFS caches.
The problem this solves is that many fscrypt users want the ability to
remove encryption keys, causing the corresponding encrypted directories
to appear "locked" (presented in ciphertext form) again. Moreover,
users want removing an encryption key to *really* remove it, in the
sense that the removed keys cannot be recovered even if kernel memory is
compromised, e.g. by the exploit of a kernel security vulnerability or
by a physical attack. This is desirable after a user logs out of the
system, for example. In many cases users even already assume this to be
the case and are surprised to hear when it's not.
It is not sufficient to simply unlink the master key from the keyring
(or to revoke or invalidate it), since the actual encryption transform
objects are still pinned in memory by their inodes. Therefore, to
really remove a key we must also evict the relevant inodes.
Currently one workaround is to run 'sync && echo 2 >
/proc/sys/vm/drop_caches'. But, that evicts all unused inodes in the
system rather than just the inodes associated with the key being
removed, causing severe performance problems. Moreover, it requires
root privileges, so regular users can't "lock" their encrypted files.
Another workaround, used in Chromium OS kernels, is to add a new
VFS-level ioctl FS_IOC_DROP_CACHE which is a more restricted version of
drop_caches that operates on a single super_block. It does:
shrink_dcache_sb(sb);
invalidate_inodes(sb, false);
But it's still a hack. Yet, the major users of filesystem encryption
want this feature badly enough that they are actually using these hacks.
To properly solve the problem, start maintaining a list of the inodes
which have been "unlocked" using each master key. Originally this
wasn't possible because the kernel didn't keep track of in-use master
keys at all. But, with the ->s_master_keys keyring it is now possible.
Then, add an ioctl FS_IOC_REMOVE_ENCRYPTION_KEY. It finds the specified
master key in ->s_master_keys, then wipes the secret key itself, which
prevents any additional inodes from being unlocked with the key. Then,
it syncs the filesystem and evicts the inodes in the key's list. The
normal inode eviction code will free and wipe the per-file keys (in
->i_crypt_info). Note that freeing ->i_crypt_info without evicting the
inodes was also considered, but would have been racy.
Some inodes may still be in use when a master key is removed, and we
can't simply revoke random file descriptors, mmap's, etc. Thus, the
ioctl simply skips in-use inodes, and returns -EBUSY to indicate that
some inodes weren't evicted. The master key *secret* is still removed,
but the fscrypt_master_key struct remains to keep track of the remaining
inodes. Userspace can then retry the ioctl to evict the remaining
inodes. Alternatively, if userspace adds the key again, the refreshed
secret will be associated with the existing list of inodes so they
remain correctly tracked for future key removals.
The ioctl doesn't wipe pagecache pages. Thus, we tolerate that after a
kernel compromise some portions of plaintext file contents may still be
recoverable from memory. This can be solved by enabling page poisoning
system-wide, which security conscious users may choose to do. But it's
very difficult to solve otherwise, e.g. note that plaintext file
contents may have been read in other places than pagecache pages.
Like FS_IOC_ADD_ENCRYPTION_KEY, FS_IOC_REMOVE_ENCRYPTION_KEY is
initially restricted to privileged users only. This is sufficient for
some use cases, but not all. A later patch will relax this restriction,
but it will require introducing key hashes, among other changes.
Reviewed-by: Theodore Ts'o <tytso@mit.edu>
Signed-off-by: Eric Biggers <ebiggers@google.com>
|
||
|
|
9846255919 |
fscrypt: add FS_IOC_ADD_ENCRYPTION_KEY ioctl
Add a new fscrypt ioctl, FS_IOC_ADD_ENCRYPTION_KEY. This ioctl adds an
encryption key to the filesystem's fscrypt keyring ->s_master_keys,
making any files encrypted with that key appear "unlocked".
Why we need this
~~~~~~~~~~~~~~~~
The main problem is that the "locked/unlocked" (ciphertext/plaintext)
status of encrypted files is global, but the fscrypt keys are not.
fscrypt only looks for keys in the keyring(s) the process accessing the
filesystem is subscribed to: the thread keyring, process keyring, and
session keyring, where the session keyring may contain the user keyring.
Therefore, userspace has to put fscrypt keys in the keyrings for
individual users or sessions. But this means that when a process with a
different keyring tries to access encrypted files, whether they appear
"unlocked" or not is nondeterministic. This is because it depends on
whether the files are currently present in the inode cache.
Fixing this by consistently providing each process its own view of the
filesystem depending on whether it has the key or not isn't feasible due
to how the VFS caches work. Furthermore, while sometimes users expect
this behavior, it is misguided for two reasons. First, it would be an
OS-level access control mechanism largely redundant with existing access
control mechanisms such as UNIX file permissions, ACLs, LSMs, etc.
Encryption is actually for protecting the data at rest.
Second, almost all users of fscrypt actually do need the keys to be
global. The largest users of fscrypt, Android and Chromium OS, achieve
this by having PID 1 create a "session keyring" that is inherited by
every process. This works, but it isn't scalable because it prevents
session keyrings from being used for any other purpose.
On general-purpose Linux distros, the 'fscrypt' userspace tool [1] can't
similarly abuse the session keyring, so to make 'sudo' work on all
systems it has to link all the user keyrings into root's user keyring
[2]. This is ugly and raises security concerns. Moreover it can't make
the keys available to system services, such as sshd trying to access the
user's '~/.ssh' directory (see [3], [4]) or NetworkManager trying to
read certificates from the user's home directory (see [5]); or to Docker
containers (see [6], [7]).
By having an API to add a key to the *filesystem* we'll be able to fix
the above bugs, remove userspace workarounds, and clearly express the
intended semantics: the locked/unlocked status of an encrypted directory
is global, and encryption is orthogonal to OS-level access control.
Why not use the add_key() syscall
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
We use an ioctl for this API rather than the existing add_key() system
call because the ioctl gives us the flexibility needed to implement
fscrypt-specific semantics that will be introduced in later patches:
- Supporting key removal with the semantics such that the secret is
removed immediately and any unused inodes using the key are evicted;
also, the eviction of any in-use inodes can be retried.
- Calculating a key-dependent cryptographic identifier and returning it
to userspace.
- Allowing keys to be added and removed by non-root users, but only keys
for v2 encryption policies; and to prevent denial-of-service attacks,
users can only remove keys they themselves have added, and a key is
only really removed after all users who added it have removed it.
Trying to shoehorn these semantics into the keyrings syscalls would be
very difficult, whereas the ioctls make things much easier.
However, to reuse code the implementation still uses the keyrings
service internally. Thus we get lockless RCU-mode key lookups without
having to re-implement it, and the keys automatically show up in
/proc/keys for debugging purposes.
References:
[1] https://github.com/google/fscrypt
[2] https://goo.gl/55cCrI#heading=h.vf09isp98isb
[3] https://github.com/google/fscrypt/issues/111#issuecomment-444347939
[4] https://github.com/google/fscrypt/issues/116
[5] https://bugs.launchpad.net/ubuntu/+source/fscrypt/+bug/1770715
[6] https://github.com/google/fscrypt/issues/128
[7] https://askubuntu.com/questions/1130306/cannot-run-docker-on-an-encrypted-filesystem
Reviewed-by: Theodore Ts'o <tytso@mit.edu>
Signed-off-by: Eric Biggers <ebiggers@google.com>
|
||
|
|
c677e5771b |
fscrypt: rename keyinfo.c to keysetup.c
Rename keyinfo.c to keysetup.c since this better describes what the file does (sets up the key), and it matches the new file keysetup_v1.c. Reviewed-by: Theodore Ts'o <tytso@mit.edu> Signed-off-by: Eric Biggers <ebiggers@google.com> |
||
|
|
a48b7adcd9 |
fs, fscrypt: move uapi definitions to new header <linux/fscrypt.h>
More fscrypt definitions are being added, and we shouldn't use a disproportionate amount of space in <linux/fs.h> for fscrypt stuff. So move the fscrypt definitions to a new header <linux/fscrypt.h>. For source compatibility with existing userspace programs, <linux/fs.h> still includes the new header. Reviewed-by: Theodore Ts'o <tytso@mit.edu> Signed-off-by: Eric Biggers <ebiggers@google.com> |
||
|
|
8780629b7e |
fscrypt: support decrypting multiple filesystem blocks per page
Rename fscrypt_decrypt_page() to fscrypt_decrypt_pagecache_blocks() and redefine its behavior to decrypt all filesystem blocks in the given region of the given page, rather than assuming that the region consists of just one filesystem block. Also remove the 'inode' and 'lblk_num' parameters, since they can be retrieved from the page as it's already assumed to be a pagecache page. This is in preparation for allowing encryption on ext4 filesystems with blocksize != PAGE_SIZE. This is based on work by Chandan Rajendra. Reviewed-by: Chandan Rajendra <chandan@linux.ibm.com> Signed-off-by: Eric Biggers <ebiggers@google.com> |
||
|
|
4582236bb4 |
fscrypt: introduce fscrypt_decrypt_block_inplace()
Currently fscrypt_decrypt_page() does one of two logically distinct things depending on whether FS_CFLG_OWN_PAGES is set in the filesystem's fscrypt_operations: decrypt a pagecache page in-place, or decrypt a filesystem block in-place in any page. Currently these happen to share the same implementation, but this conflates the notion of blocks and pages. It also makes it so that all callers have to provide inode and lblk_num, when fscrypt could determine these itself for pagecache pages. Therefore, move the FS_CFLG_OWN_PAGES behavior into a new function fscrypt_decrypt_block_inplace(). This mirrors fscrypt_encrypt_block_inplace(). This is in preparation for allowing encryption on ext4 filesystems with blocksize != PAGE_SIZE. Reviewed-by: Chandan Rajendra <chandan@linux.ibm.com> Signed-off-by: Eric Biggers <ebiggers@google.com> |
||
|
|
fd0e18f34d |
fscrypt: support encrypting multiple filesystem blocks per page
Rename fscrypt_encrypt_page() to fscrypt_encrypt_pagecache_blocks() and redefine its behavior to encrypt all filesystem blocks from the given region of the given page, rather than assuming that the region consists of just one filesystem block. Also remove the 'inode' and 'lblk_num' parameters, since they can be retrieved from the page as it's already assumed to be a pagecache page. This is in preparation for allowing encryption on ext4 filesystems with blocksize != PAGE_SIZE. This is based on work by Chandan Rajendra. Reviewed-by: Chandan Rajendra <chandan@linux.ibm.com> Signed-off-by: Eric Biggers <ebiggers@google.com> |
||
|
|
ce7b7a207b |
fscrypt: introduce fscrypt_encrypt_block_inplace()
fscrypt_encrypt_page() behaves very differently depending on whether the filesystem set FS_CFLG_OWN_PAGES in its fscrypt_operations. This makes the function difficult to understand and document. It also makes it so that all callers have to provide inode and lblk_num, when fscrypt could determine these itself for pagecache pages. Therefore, move the FS_CFLG_OWN_PAGES behavior into a new function fscrypt_encrypt_block_inplace(). This is in preparation for allowing encryption on ext4 filesystems with blocksize != PAGE_SIZE. Reviewed-by: Chandan Rajendra <chandan@linux.ibm.com> Signed-off-by: Eric Biggers <ebiggers@google.com> |
||
|
|
d568cccb4b |
fscrypt: remove the "write" part of struct fscrypt_ctx
Now that fscrypt_ctx is not used for writes, remove the 'w' fields. Reviewed-by: Chandan Rajendra <chandan@linux.ibm.com> Signed-off-by: Eric Biggers <ebiggers@google.com> |