Commit Graph

66 Commits

Author SHA1 Message Date
Christoph Hellwig
c5095805e9 BACKPORT: sysctl: pass kernel pointers to ->proc_handler
Instead of having all the sysctl handlers deal with user pointers, which
is rather hairy in terms of the BPF interaction, copy the input to and
from  userspace in common code.  This also means that the strings are
always NUL-terminated by the common code, making the API a little bit
safer.

As most handler just pass through the data to one of the common handlers
a lot of the changes are mechnical.

Change-Id: Ic71fd778e4cea58adc51d634d9e53c1f9f90cdf2
Signed-off-by: Christoph Hellwig <hch@lst.de>
Acked-by: Andrey Ignatov <rdna@fb.com>
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
2025-09-08 17:26:43 +03:00
Wilson Sung
e3167a4609 Merge android-4.19-stable (4.19.294) into android-msm-pixel-4.19-lts
Merge 4.19.294 into android-4.19-stable
Linux 4.19.294
    Revert "ARM: ep93xx: fix missing-prototype warnings"
    Revert "MIPS: Alchemy: fix dbdma2"
    Merge 4.19.293 into android-4.19-stable
Linux 4.19.293
    dma-buf/sw_sync: Avoid recursive lock during fence signal
  * clk: Fix undefined reference to `clk_rate_exclusive_{get,put}'
      include/linux/clk.h
  * scsi: core: raid_class: Remove raid_component_add()
      include/linux/raid_class.h
    scsi: snic: Fix double free in snic_tgt_create()
    irqchip/mips-gic: Don't touch vl_map if a local interrupt is not routable
  * rtnetlink: Reject negative ifindexes in RTM_NEWLINK
      net/core/rtnetlink.c
  * netfilter: nf_queue: fix socket leak
      net/netfilter/nf_queue.c
  * sched/rt: pick_next_rt_entity(): check list_entry
      kernel/sched/rt.c
  * mmc: block: Fix in_flight[issue_type] value error
      drivers/mmc/core/block.c
    x86/fpu: Set X86_FEATURE_OSXSAVE feature after enabling OSXSAVE in CR4
    PCI: acpiphp: Use pci_assign_unassigned_bridge_resources() only for non-root bus
    media: vcodec: Fix potential array out-of-bounds in encoder queue_setup
  * lib/clz_ctz.c: Fix __clzdi2() and __ctzdi2() for 32-bit kernels
      lib/clz_ctz.c
    batman-adv: Fix batadv_v_ogm_aggr_send memory leak
    batman-adv: Fix TT global entry leak when client roamed back
    batman-adv: Do not get eth header before batadv_check_management_packet
    batman-adv: Don't increase MTU when set by user
    batman-adv: Trigger events for auto adjusted MTU
    nfsd: Fix race to FREE_STATEID and cl_revoked
    ibmveth: Use dcbf rather than dcbfl
    ipvs: fix racy memcpy in proc_do_sync_threshold
    ipvs: Improve robustness to the ipvs sysctl
  * bonding: fix macvlan over alb bond support
      drivers/net/bonding/bond_alb.c
      include/net/bonding.h
  * net: remove bond_slave_has_mac_rcu()
      include/net/bonding.h
  * net/sched: fix a qdisc modification with ambiguous command request
      net/sched/sch_api.c
    igb: Avoid starting unnecessary workqueues
    dccp: annotate data-races in dccp_poll()
  * sock: annotate data-races around prot->memory_pressure
      include/net/sock.h
      net/sctp/socket.c
  * tracing: Fix memleak due to race between current_tracer and trace
      kernel/trace/trace.c
    drm/amd/display: check TG is non-null before checking if enabled
    drm/amd/display: do not wait for mpc idle if tg is disabled
  * regmap: Account for register length in SMBus I/O limits
      drivers/base/regmap/regmap-i2c.c
    dm integrity: reduce vmalloc space footprint on 32-bit architectures
    dm integrity: increase RECALC_SECTORS to improve recalculate speed
    powerpc: Fail build if using recordmcount with binutils v2.37
    powerpc: remove leftover code of old GCC version checks
    powerpc/32: add stack protector support
    fbdev: fix potential OOB read in fast_imageblit()
    fbdev: Fix sys_imageblit() for arbitrary image widths
    fbdev: Improve performance of sys_imageblit()
    tty: serial: fsl_lpuart: add earlycon for imx8ulp platform
    Revert "tty: serial: fsl_lpuart: drop earlycon entry for i.MX8QXP"
    MIPS: cpu-features: Use boot_cpu_type for CPU type based features
    MIPS: cpu-features: Enable octeon_cache by cpu_type
    fs: dlm: fix mismatch of plock results from userspace
    fs: dlm: use dlm_plock_info for do_unlock_close
    fs: dlm: change plock interrupted message to debug again
    fs: dlm: add pid to debug log
    dlm: replace usage of found with dedicated list iterator variable
    dlm: improve plock logging if interrupted
    PCI: acpiphp: Reassign resources on bridge if necessary
    net: phy: broadcom: stub c45 read/write for 54810
  * net: xfrm: Amend XFRMA_SEC_CTX nla_policy structure
      net/xfrm/xfrm_user.c
  * net: fix the RTO timer retransmitting skb every 1ms if linear option is enabled
      net/ipv4/tcp_timer.c
    virtio-net: set queues after driver_ok
  * af_unix: Fix null-ptr-deref in unix_stream_sendpage().
      net/unix/af_unix.c
  * netfilter: set default timeout to 3 secs for sctp shutdown send and recv state
      net/netfilter/nf_conntrack_proto_sctp.c
    test_firmware: prevent race conditions by a correct implementation of locking
    mmc: wbsd: fix double mmc_free_host() in wbsd_init()
    cifs: Release folio lock on fscache read hit.
  * ALSA: usb-audio: Add support for Mythware XA001AU capture and playback interfaces.
      sound/usb/quirks-table.h
    serial: 8250: Fix oops for port->pm on uart_change_pm()
    ASoC: meson: axg-tdm-formatter: fix channel slot allocation
    ASoC: rt5665: add missed regulator_bulk_disable
  * net: do not allow gso_size to be set to GSO_BY_FRAGS
      include/linux/virtio_net.h
  * sock: Fix misuse of sk_under_memory_pressure()
      include/net/sock.h
      net/core/sock.c
    i40e: fix misleading debug logs
    team: Fix incorrect deletion of ETH_P_8021AD protocol vid from slaves
    netfilter: nft_dynset: disallow object maps
    selftests: mirror_gre_changes: Tighten up the TTL test match
  * xfrm: add NULL check in xfrm_update_ae_params
      net/xfrm/xfrm_user.c
  * ip_vti: fix potential slab-use-after-free in decode_session6
      net/ipv4/ip_vti.c
  * ip6_vti: fix slab-use-after-free in decode_session6
      net/ipv6/ip6_vti.c
  * xfrm: fix slab-use-after-free in decode_session6
      net/xfrm/xfrm_interface_core.c
  * xfrm: interface: rename xfrm_interface.c to xfrm_interface_core.c
      net/xfrm/Makefile
  * net: af_key: fix sadb_x_filter validation
      net/key/af_key.c
  * net: xfrm: Fix xfrm_address_filter OOB read
      net/xfrm/xfrm_user.c
    btrfs: fix BUG_ON condition in btrfs_cancel_balance
    powerpc/rtas_flash: allow user copy to flash block cache objects
    fbdev: mmp: fix value check in mmphw_probe()
    virtio-mmio: don't break lifecycle of vm_dev
    virtio-mmio: Use to_virtio_mmio_device() to simply code
    virtio-mmio: convert to devm_platform_ioremap_resource
    nfsd: Remove incorrect check in nfsd4_validate_stateid
    nfsd4: kill warnings on testing stateids with mismatched clientids
    block: fix signed int overflow in Amiga partition support
    mmc: sunxi: fix deferred probing
    mmc: bcm2835: fix deferred probing
  * mmc: Remove dev_err() usage after platform_get_irq()
      drivers/mmc/host/sdhci-msm.c
    mmc: tmio: move tmio_mmc_set_clock() to platform hook
    mmc: tmio: replace tmio_mmc_clk_stop() calls with tmio_mmc_set_clock()
    mmc: meson-gx: remove redundant mmc_request_done() call from irq context
    mmc: meson-gx: remove useless lock
  * USB: dwc3: qcom: fix NULL-deref on suspend
      drivers/usb/dwc3/dwc3-qcom.c
  * usb: dwc3: qcom: Add helper functions to enable,disable wake irqs
      drivers/usb/dwc3/dwc3-qcom.c
    irqchip/mips-gic: Use raw spinlock for gic_lock
    irqchip/mips-gic: Get rid of the reliance on irq_cpu_online()
    x86/topology: Fix erroneous smp_num_siblings on Intel Hybrid platforms
    powerpc/64s/radix: Fix soft dirty tracking
    powerpc: Move page table dump files in a dedicated subdirectory
    powerpc/mm: dump block address translation on book3s/32
    powerpc/mm: dump segment registers on book3s/32
    powerpc/mm: Move pgtable_t into platform headers
    powerpc/mm: move platform specific mmu-xxx.h in platform directories
    iio: addac: stx104: Fix race condition when converting analog-to-digital
    iio: addac: stx104: Fix race condition for stx104_write_raw()
    iio: adc: stx104: Implement and utilize register structures
    iio: adc: stx104: Utilize iomap interface
  * iio: add addac subdirectory
      drivers/iio/Kconfig
      drivers/iio/Makefile
      drivers/iio/addac/Kconfig
      drivers/iio/addac/Makefile
  * IMA: allow/fix UML builds
      security/integrity/ima/Kconfig
    drm/amdgpu: Fix potential fence use-after-free v2
  * Bluetooth: L2CAP: Fix use-after-free
      net/bluetooth/l2cap_core.c
    pcmcia: rsrc_nonstatic: Fix memory leak in nonstatic_release_resource_db()
    gfs2: Fix possible data races in gfs2_show_options()
    media: platform: mediatek: vpu: fix NULL ptr dereference
  * media: v4l2-mem2mem: add lock to protect parameter num_rdy
      include/media/v4l2-mem2mem.h
    FS: JFS: Check for read-only mounted filesystem in txBegin
    FS: JFS: Fix null-ptr-deref Read in txBegin
    MIPS: dec: prom: Address -Warray-bounds warning
    fs: jfs: Fix UBSAN: array-index-out-of-bounds in dbAllocDmapLev
    udf: Fix uninitialized array access for some pathnames
  * HID: add quirk for 03f0:464a HP Elite Presenter Mouse
      drivers/hid/hid-ids.h
      drivers/hid/hid-quirks.c
  * quota: fix warning in dqgrab()
      fs/quota/dquot.c
  * quota: Properly disable quotas when add_dquot_ref() fails
      fs/quota/dquot.c
    ALSA: emu10k1: roll up loops in DSP setup code for Audigy
    drm/radeon: Fix integer overflow in radeon_cs_parser_init
    selftests: forwarding: tc_flower: Relax success criterion
  * lib/mpi: Eliminate unused umul_ppmm definitions for MIPS
      lib/mpi/longlong.h
    Merge 4.19.292 into android-4.19-stable
  * Revert "posix-timers: Ensure timer ID search-loop limit is valid"
      include/linux/sched/signal.h
      kernel/time/posix-timers.c
    Merge 4.19.291 into android-4.19-stable
    Merge 4.19.290 into android-4.19-stable
    UPSTREAM: media: usb: siano: Fix warning due to null work_func_t function pointer
  * UPSTREAM: Bluetooth: L2CAP: Fix use-after-free in l2cap_sock_ready_cb
      net/bluetooth/l2cap_sock.c
    UPSTREAM: net/sched: cls_route: No longer copy tcf_result on update to avoid use-after-free
  * UPSTREAM: net/sched: cls_u32: No longer copy tcf_result on update to avoid use-after-free
      net/sched/cls_u32.c
Linux 4.19.292
  * sch_netem: fix issues in netem_change() vs get_dist_table()
      net/sched/sch_netem.c
    alpha: remove __init annotation from exported page_is_ram()
    scsi: core: Fix possible memory leak if device_add() fails
    scsi: snic: Fix possible memory leak if device_add() fails
    scsi: 53c700: Check that command slot is not NULL
    scsi: storvsc: Fix handling of virtual Fibre Channel timeouts
  * scsi: core: Fix legacy /proc parsing buffer overflow
      drivers/scsi/scsi_proc.c
  * netfilter: nf_tables: report use refcount overflow
      include/net/netfilter/nf_tables.h
  * netfilter: nf_tables: bogus EBUSY when deleting flowtable after flush
      include/net/netfilter/nf_tables.h
    btrfs: don't stop integrity writeback too early
    ibmvnic: Handle DMA unmapping of login buffs in release functions
  * wifi: cfg80211: fix sband iftype data lookup for AP_VLAN
      include/net/cfg80211.h
    IB/hfi1: Fix possible panic during hotplug remove
  * drivers: net: prevent tun_build_skb() to exceed the packet size limit
      drivers/net/tun.c
    dccp: fix data-race around dp->dccps_mss_cache
  * bonding: Fix incorrect deletion of ETH_P_8021AD protocol vid from slaves
      drivers/net/bonding/bond_main.c
  * net/packet: annotate data-races around tp->status
      net/packet/af_packet.c
    mISDN: Update parameter type of dsp_cmx_send()
    drm/nouveau/disp: Revert a NULL check inside nouveau_connector_get_modes
    x86: Move gds_ucode_mitigated() declaration to header
    x86/mm: Fix VDSO and VVAR placement on 5-level paging machines
    x86/cpu/amd: Enable Zenbleed fix for AMD Custom APU 0405
  * usb: dwc3: Properly handle processing of pending events
      drivers/usb/dwc3/gadget.c
    usb-storage: alauda: Fix uninit-value in alauda_check_media()
  * binder: fix memory leak in binder_init()
      drivers/android/binder.c
      drivers/android/binder_alloc.c
      drivers/android/binder_alloc.h
    iio: cros_ec: Fix the allocation size for cros_ec_command
    nilfs2: fix use-after-free of nilfs_root in dirtying inodes via iput
    radix tree test suite: fix incorrect allocation size for pthreads
    drm/nouveau/gr: enable memory loads on helper invocation on all channels
    dmaengine: pl330: Return DMA_PAUSED when transaction is paused
  * ipv6: adjust ndisc_is_useropt() to also return true for PIO
      net/ipv6/ndisc.c
    mmc: moxart: read scr register without changing byte order
    sparc: fix up arch_cpu_finalize_init() build breakage.
  * UPSTREAM: net/sched: cls_fw: Fix improper refcount update leads to use-after-free
      net/sched/cls_fw.c
Linux 4.19.291
  * drm/edid: fix objtool warning in drm_cvt_modes()
      drivers/gpu/drm/drm_edid.c
    arm64: dts: stratix10: fix incorrect I2C property for SCL signal
  * drivers core: Use sysfs_emit and sysfs_emit_at for show(device *...) functions
      drivers/base/arch_topology.c
      drivers/base/cacheinfo.c
      drivers/base/core.c
      drivers/base/cpu.c
      drivers/base/firmware_loader/fallback.c
      drivers/base/platform.c
      drivers/base/power/sysfs.c
      drivers/base/soc.c
    ARM: dts: nxp/imx6sll: fix wrong property name in usbphy node
    ARM: dts: imx6sll: fixup of operating points
    ARM: dts: imx: add usb alias
    ARM: dts: imx6sll: Make ssi node name same as other platforms
  * PM: sleep: wakeirq: fix wake irq arming
      drivers/base/power/power.h
      drivers/base/power/wakeirq.c
  * PM / wakeirq: support enabling wake-up irq after runtime_suspend called
      drivers/base/power/power.h
      drivers/base/power/runtime.c
      drivers/base/power/wakeirq.c
      include/linux/pm_wakeirq.h
    powerpc/mm/altmap: Fix altmap boundary check
    mtd: rawnand: omap_elm: Fix incorrect type in assignment
    test_firmware: return ENOMEM instead of ENOSPC on failed memory allocation
    test_firmware: fix a memory leak with reqs buffer
    ext2: Drop fragment support
  * net: usbnet: Fix WARNING in usbnet_start_xmit/usb_submit_urb
      drivers/net/usb/usbnet.c
  * Bluetooth: L2CAP: Fix use-after-free in l2cap_sock_ready_cb
      net/bluetooth/l2cap_sock.c
    fs/sysv: Null check to prevent null-ptr-deref bug
  * USB: zaurus: Add ID for A-300/B-500/C-700
      drivers/net/usb/cdc_ether.c
      drivers/net/usb/zaurus.c
    libceph: fix potential hang in ceph_osdc_notify()
    scsi: zfcp: Defer fc_rport blocking until after ADISC response
  * tcp_metrics: fix data-race in tcpm_suck_dst() vs fastopen
      net/ipv4/tcp_metrics.c
  * tcp_metrics: annotate data-races around tm->tcpm_net
      net/ipv4/tcp_metrics.c
  * tcp_metrics: annotate data-races around tm->tcpm_vals[]
      net/ipv4/tcp_metrics.c
  * tcp_metrics: annotate data-races around tm->tcpm_lock
      net/ipv4/tcp_metrics.c
  * tcp_metrics: annotate data-races around tm->tcpm_stamp
      net/ipv4/tcp_metrics.c
  * tcp_metrics: fix addr_same() helper
      net/ipv4/tcp_metrics.c
    ip6mr: Fix skb_under_panic in ip6mr_cache_report()
    net/sched: cls_route: No longer copy tcf_result on update to avoid use-after-free
  * net/sched: cls_u32: No longer copy tcf_result on update to avoid use-after-free
      net/sched/cls_u32.c
  * net: add missing data-race annotation for sk_ll_usec
      net/core/sock.c
  * net: add missing data-race annotations around sk->sk_peek_off
      net/core/sock.c
      net/unix/af_unix.c
  * net: sched: cls_u32: Fix match key mis-addressing
      net/sched/cls_u32.c
    perf test uprobe_from_different_cu: Skip if there is no gcc
    net/mlx5e: fix return value check in mlx5e_ipsec_remove_trailer()
    KVM: s390: fix sthyi error handling
  * word-at-a-time: use the same return type for has_zero regardless of endianness
      include/asm-generic/word-at-a-time.h
  * loop: Select I/O scheduler 'none' from inside add_disk()
      drivers/block/loop.c
  * perf: Fix function pointer case
      kernel/events/core.c
  * net/sched: cls_u32: Fix reference counter leak leading to overflow
      net/sched/cls_u32.c
    ASoC: cs42l51: fix driver to properly autoload with automatic module loading
    net/sched: sch_qfq: account for stab overhead in qfq_enqueue
  * net/sched: cls_fw: Fix improper refcount update leads to use-after-free
      net/sched/cls_fw.c
    drm/client: Fix memory leak in drm_client_target_cloned
    dm cache policy smq: ensure IO doesn't prevent cleaner policy progress
    ASoC: wm8904: Fill the cache for WM8904_ADC_TEST_0 register
    s390/dasd: fix hanging device after quiesce/resume
    virtio-net: fix race between set queues and probe
    serial: 8250_dw: Preserve original value of DLF register
  * serial: 8250_dw: split Synopsys DesignWare 8250 common functions
      drivers/tty/serial/8250/Kconfig
    irq-bcm6345-l1: Do not assume a fixed block to cpu mapping
    tpm_tis: Explicitly check for error code
    btrfs: check for commit error at btrfs_attach_transaction_barrier()
    hwmon: (nct7802) Fix for temp6 (PECI1) processed even if PECI1 disabled
    staging: ks7010: potential buffer overflow in ks_wlan_set_encode_ext()
    Documentation: security-bugs.rst: clarify CVE handling
    Documentation: security-bugs.rst: update preferences when dealing with the linux-distros group
    usb: xhci-mtk: set the dma max_seg_size
  * USB: quirks: add quirk for Focusrite Scarlett
      drivers/usb/core/quirks.c
    usb: ohci-at91: Fix the unhandle interrupt when resume
  * usb: dwc3: don't reset device side if dwc3 was configured as host-only
      drivers/usb/dwc3/core.c
    usb: dwc3: pci: skip BYT GPIO lookup table for hardwired phy
  * Revert "usb: dwc3: core: Enable AutoRetry feature in the controller"
      drivers/usb/dwc3/core.c
      drivers/usb/dwc3/core.h
    can: gs_usb: gs_can_close(): add missing set of CAN state to CAN_STATE_STOPPED
    USB: serial: simple: sort driver entries
    USB: serial: simple: add Kaufmann RKS+CAN VCP
    USB: serial: option: add Quectel EC200A module support
    USB: serial: option: support Quectel EM060K_128
  * tracing: Fix warning in trace_buffered_event_disable()
      kernel/trace/trace_events.c
  * ring-buffer: Fix wrong stat of cpu_buffer->read
      kernel/trace/ring_buffer.c
    ata: pata_ns87415: mark ns87560_tf_read static
    dm raid: fix missing reconfig_mutex unlock in raid_ctr() error paths
  * block: Fix a source code comment in include/uapi/linux/blkzoned.h
      include/uapi/linux/blkzoned.h
    ASoC: fsl_spdif: Silence output on stop
    drm/msm: Fix IS_ERR_OR_NULL() vs NULL check in a5xx_submit_in_rb()
    RDMA/mlx4: Make check for invalid flags stricter
    benet: fix return value check in be_lancer_xmit_workarounds()
    net/sched: mqprio: Add length check for TCA_MQPRIO_{MAX/MIN}_RATE64
    net/sched: mqprio: add extack to mqprio_parse_nlattr()
    net/sched: mqprio: refactor nlattr parsing to a separate function
    platform/x86: msi-laptop: Fix rfkill out-of-sync on MSI Wind U100
    team: reset team's flags when down link is P2P device
  * bonding: reset bond's flags when down link is P2P device
      drivers/net/bonding/bond_main.c
  * tcp: Reduce chance of collisions in inet6_hashfn().
      include/net/ipv6.h
  * ipv6 addrconf: fix bug where deleting a mngtmpaddr can create a new temporary address
      net/ipv6/addrconf.c
    ethernet: atheros: fix return value check in atl1e_tso_csum()
    phy: hisilicon: Fix an out of bounds check in hisi_inno_phy_probe()
    i40e: Fix an NULL vs IS_ERR() bug for debugfs_create_dir()
  * ext4: fix to check return value of freeze_bdev() in ext4_shutdown()
      fs/ext4/ioctl.c
    scsi: qla2xxx: Array index may go out of bound
    scsi: qla2xxx: Fix inconsistent format argument type in qla_os.c
    ftrace: Fix possible warning on checking all pages used in ftrace_process_locs()
    ftrace: Store the order of pages allocated in ftrace_page
    ftrace: Check if pages were allocated before calling free_pages()
  * ftrace: Add information on number of page groups allocated
      kernel/trace/trace.c
      kernel/trace/trace.h
    fs: dlm: interrupt posix locks only when process is killed
    dlm: rearrange async condition return
    dlm: cleanup plock_op vs plock_xop
    PCI/ASPM: Avoid link retraining race
    PCI/ASPM: Factor out pcie_wait_for_retrain()
    PCI/ASPM: Return 0 or -ETIMEDOUT from pcie_retrain_link()
    PCI: Rework pcie_retrain_link() wait loop
  * ext4: Fix reusing stale buffer heads from last failed mounting
      fs/ext4/super.c
  * ext4: rename journal_dev to s_journal_dev inside ext4_sb_info
      fs/ext4/ext4.h
      fs/ext4/fsmap.c
      fs/ext4/super.c
    btrfs: fix extent buffer leak after tree mod log failure at split_node()
    bcache: Fix __bch_btree_node_alloc to make the failure behavior consistent
    bcache: remove 'int n' from parameter list of bch_bucket_alloc_set()
    bcache: use MAX_CACHES_PER_SET instead of magic number 8 in __bch_bucket_alloc_set
    gpio: tps68470: Make tps68470_gpio_output() always set the initial value
    tracing/histograms: Return an error if we fail to add histogram to hist_vars list
  * tcp: annotate data-races around fastopenq.max_qlen
      include/linux/tcp.h
      net/ipv4/tcp.c
      net/ipv4/tcp_fastopen.c
  * tcp: annotate data-races around tp->notsent_lowat
      include/net/tcp.h
      net/ipv4/tcp.c
  * tcp: annotate data-races around rskq_defer_accept
      net/ipv4/tcp.c
  * tcp: annotate data-races around tp->linger2
      net/ipv4/tcp.c
  * net: Replace the limit of TCP_LINGER2 with TCP_FIN_TIMEOUT_MAX
      include/net/tcp.h
      net/ipv4/tcp.c
    netfilter: nf_tables: can't schedule in nft_chain_validate
    netfilter: nf_tables: fix spurious set element insertion failure
  * llc: Don't drop packet from non-root netns.
      net/llc/llc_input.c
    fbdev: au1200fb: Fix missing IRQ check in au1200fb_drv_probe
  * Revert "tcp: avoid the lookup process failing to get sk in ehash table"
      net/ipv4/inet_hashtables.c
      net/ipv4/inet_timewait_sock.c
    net:ipv6: check return value of pskb_trim()
    net: ethernet: ti: cpsw_ale: Fix cpsw_ale_get_field()/cpsw_ale_set_field()
    pinctrl: amd: Use amd_pinconf_set() for all config options
    fbdev: imxfb: warn about invalid left/right margin
    spi: bcm63xx: fix max prepend length
    igb: Fix igb_down hung on surprise removal
    wifi: iwlwifi: mvm: avoid baid size integer overflow
  * wifi: wext-core: Fix -Wstringop-overflow warning in ioctl_standard_iw_point()
      net/wireless/wext-core.c
  * bpf: Address KCSAN report on bpf_lru_list
      kernel/bpf/bpf_lru_list.c
      kernel/bpf/bpf_lru_list.h
  * sched/fair: Don't balance task to its current running CPU
      kernel/sched/fair.c
  * posix-timers: Ensure timer ID search-loop limit is valid
      include/linux/sched/signal.h
      kernel/time/posix-timers.c
    md/raid10: prevent soft lockup while flush writes
    md: fix data corruption for raid456 when reshape restart while grow up
    nbd: Add the maximum limit of allocated index in nbd_dev_add
    debugobjects: Recheck debug_objects_enabled before reporting
  * ext4: correct inline offset when handling xattrs in inode body
      fs/ext4/xattr.c
    can: bcm: Fix UAF in bcm_proc_show()
  * fuse: revalidate: don't invalidate if interrupted
      fs/fuse/dir.c
    perf probe: Add test for regression introduced by switch to die_get_decl_file()
    tracing/histograms: Add histograms to hist_vars if they have referenced variables
  * drm/atomic: Fix potential use-after-free in nonblocking commits
      drivers/gpu/drm/drm_atomic.c
    scsi: qla2xxx: Pointer may be dereferenced
    scsi: qla2xxx: Check valid rport returned by fc_bsg_to_rport()
    scsi: qla2xxx: Fix potential NULL pointer dereference
    scsi: qla2xxx: Wait for io return on terminate rport
    xtensa: ISS: fix call to split_if_spec
  * ring-buffer: Fix deadloop issue on reading trace_pipe
      kernel/trace/ring_buffer.c
    tty: serial: samsung_tty: Fix a memory leak in s3c24xx_serial_getclk() when iterating clk
    tty: serial: samsung_tty: Fix a memory leak in s3c24xx_serial_getclk() in case of error
  * Revert "8250: add support for ASIX devices with a FIFO bug"
      include/linux/serial_8250.h
    meson saradc: fix clock divider mask length
    ceph: don't let check_caps skip sending responses for revoke msgs
    hwrng: imx-rngc - fix the timeout for init and self check
    serial: atmel: don't enable IRQs prematurely
    fs: dlm: return positive pid value for F_GETLK
    md/raid0: add discard support for the 'original' layout
    misc: pci_endpoint_test: Re-init completion for every test
    misc: pci_endpoint_test: Free IRQs before removing the device
    PCI: rockchip: Use u32 variable to access 32-bit registers
    PCI: rockchip: Fix legacy IRQ generation for RK3399 PCIe endpoint core
    PCI: rockchip: Add poll and timeout to wait for PHY PLLs to be locked
    PCI: rockchip: Write PCI Device ID to correct register
    PCI: rockchip: Assert PCI Configuration Enable bit after probe
    PCI: qcom: Disable write access to read only registers for IP v2.3.3
  * PCI: Add function 1 DMA alias quirk for Marvell 88SE9235
      drivers/pci/quirks.c
  * PCI/PM: Avoid putting EloPOS E2/S2/H2 PCIe Ports in D3cold
      drivers/pci/pci.c
    jfs: jfs_dmap: Validate db_l2nbperpage while mounting
  * ext4: only update i_reserved_data_blocks on successful block allocation
      fs/ext4/indirect.c
      fs/ext4/inode.c
  * ext4: fix wrong unit use in ext4_mb_clear_bb
      fs/ext4/mballoc.c
    perf intel-pt: Fix CYC timestamps after standalone CBR
    SUNRPC: Fix UAF in svc_tcp_listen_data_ready()
    net: bcmgenet: Ensure MDIO unregistration has clocks enabled
    tpm: tpm_vtpm_proxy: fix a race condition in /dev/vtpmx creation
    pinctrl: amd: Only use special debounce behavior for GPIO 0
    pinctrl: amd: Detect internal GPIO0 debounce handling
    pinctrl: amd: Fix mistake in handling clearing pins at startup
  * net/sched: make psched_mtu() RTNL-less safe
      include/net/pkt_sched.h
    wifi: airo: avoid uninitialized warning in airo_get_rate()
  * ipv6/addrconf: fix a potential refcount underflow for idev
      net/ipv6/addrconf.c
    NTB: ntb_tool: Add check for devm_kcalloc
    NTB: ntb_transport: fix possible memory leak while device_register() fails
    ntb: intel: Fix error handling in intel_ntb_pci_driver_init()
    NTB: amd: Fix error handling in amd_ntb_pci_driver_init()
    ntb: idt: Fix error handling in idt_pci_driver_init()
  * udp6: fix udp6_ehashfn() typo
      net/ipv6/udp.c
  * icmp6: Fix null-ptr-deref of ip6_null_entry->rt6i_idev in icmp6_dev().
      net/ipv6/icmp.c
  * vrf: Increment Icmp6InMsgs on the original netdev
      include/net/addrconf.h
      net/ipv6/icmp.c
      net/ipv6/reassembly.c
    net: mvneta: fix txq_map in case of txq_number==1
  * workqueue: clean up WORK_* constant types, clarify masking
      include/linux/workqueue.h
      kernel/workqueue.c
    net: lan743x: Don't sleep in atomic context
    netfilter: nf_tables: prevent OOB access in nft_byteorder_eval
  * netfilter: conntrack: Avoid nf_ct_helper_hash uses after free
      net/netfilter/nf_conntrack_helper.c
    netfilter: nf_tables: fix scheduling-while-atomic splat
    netfilter: nf_tables: unbind non-anonymous set if rule construction fails
  * netfilter: nf_tables: reject unbound anonymous set before commit phase
      include/net/netfilter/nf_tables.h
  * netfilter: nf_tables: add NFT_TRANS_PREPARE_ERROR to deal with bound set/chain
      include/net/netfilter/nf_tables.h
    netfilter: nf_tables: incorrect error path handling with NFT_MSG_NEWRULE
  * netfilter: nf_tables: use net_generic infra for transaction data
      include/net/netfilter/nf_tables.h
      include/net/netns/nftables.h
  * netfilter: add helper function to set up the nfnetlink header and use it
      include/linux/netfilter/nfnetlink.h
      net/netfilter/nf_conntrack_netlink.c
      net/netfilter/nfnetlink_log.c
      net/netfilter/nfnetlink_queue.c
    netfilter: nftables: add helper function to set the base sequence number
    netfilter: nf_tables: add rescheduling points during loop detection walks
    netfilter: nf_tables: fix nat hook table deletion
    spi: spi-fsl-spi: allow changing bits_per_word while CS is still active
    spi: spi-fsl-spi: relax message sanity checking a little
    spi: spi-fsl-spi: remove always-true conditional in fsl_spi_do_one_msg
    ARM: orion5x: fix d2net gpio initialization
    btrfs: fix race when deleting quota root from the dirty cow roots list
    jffs2: reduce stack usage in jffs2_build_xattr_subsystem()
  * integrity: Fix possible multiple allocation in integrity_inode_get()
      security/integrity/iint.c
    bcache: Remove unnecessary NULL point check in node allocations
    mmc: core: disable TRIM on Micron MTFC4GACAJCN-1M
    mmc: core: disable TRIM on Kingston EMMC04G-M627
    NFSD: add encoding of op_recall flag for write delegation
  * ALSA: jack: Fix mutex call in snd_jack_report()
      sound/core/jack.c
    i2c: xiic: Don't try to handle more interrupt events after error
    i2c: xiic: Defer xiic_wakeup() and __xiic_start_xfer() in xiic_process()
    sh: dma: Fix DMA channel offset calculation
    net/sched: act_pedit: Add size check for TCA_PEDIT_PARMS_EX
  * tcp: annotate data races in __tcp_oow_rate_limited()
      net/ipv4/tcp_input.c
  * net: bridge: keep ports without IFF_UNICAST_FLT in BR_PROMISC mode
      net/bridge/br_if.c
    powerpc: allow PPC_EARLY_DEBUG_CPM only when SERIAL_CPM=y
  * f2fs: fix error path handling in truncate_dnode()
      fs/f2fs/node.c
    mailbox: ti-msgmgr: Fill non-message tx data fields with 0x0
    spi: bcm-qspi: return error if neither hif_mspi nor mspi is available
    Add MODULE_FIRMWARE() for FIRMWARE_TG357766.
  * sctp: fix potential deadlock on &net->sctp.addr_wq_lock
      net/sctp/socket.c
    rtc: st-lpc: Release some resources in st_rtc_probe() in case of error
    mfd: stmpe: Only disable the regulators if they are enabled
    mfd: intel-lpss: Add missing check for platform_get_resource
    KVM: s390: fix KVM_S390_GET_CMMA_BITS for GFNs in memslot holes
    mfd: rt5033: Drop rt5033-battery sub-device
    usb: phy: phy-tahvo: fix memory leak in tahvo_usb_probe()
  * extcon: Fix kernel doc of property capability fields to avoid warnings
      drivers/extcon/extcon.c
  * extcon: Fix kernel doc of property fields to avoid warnings
      drivers/extcon/extcon.c
    media: usb: siano: Fix warning due to null work_func_t function pointer
  * media: videodev2.h: Fix struct v4l2_input tuner index comment
      include/uapi/linux/videodev2.h
    media: usb: Check az6007_read() return value
    sh: j2: Use ioremap() to translate device tree address into kernel memory
    w1: fix loop in w1_fini()
  * block: change all __u32 annotations to __be32 in affs_hardblocks.h
      include/uapi/linux/affs_hardblocks.h
    USB: serial: option: add LARA-R6 01B PIDs
    ARC: define ASM_NL and __ALIGN(_STR) outside #ifdef __ASSEMBLY__ guard
    ARCv2: entry: rewrite to enable use of double load/stores LDD/STD
    ARCv2: entry: avoid a branch
    ARCv2: entry: push out the Z flag unclobber from common EXCEPTION_PROLOGUE
    ARCv2: entry: comments about hardware auto-save on taken interrupts
  * modpost: fix section mismatch message for R_ARM_{PC24,CALL,JUMP24}
      scripts/mod/modpost.c
  * modpost: fix section mismatch message for R_ARM_ABS32
      scripts/mod/modpost.c
    crypto: nx - fix build warnings when DEBUG_FS is not enabled
    hwrng: virtio - Fix race on data_avail and actual data
    hwrng: virtio - always add a pending request
    hwrng: virtio - don't waste entropy
    hwrng: virtio - don't wait on cleanup
    hwrng: virtio - add an internal buffer
    pinctrl: at91-pio4: check return value of devm_kasprintf()
    perf dwarf-aux: Fix off-by-one in die_get_varname()
    pinctrl: cherryview: Return correct value if pin in push-pull mode
  * PCI: Add pci_clear_master() stub for non-CONFIG_PCI
      include/linux/pci.h
    scsi: 3w-xxxx: Add error handling for initialization failure in tw_probe()
    ALSA: ac97: Fix possible NULL dereference in snd_ac97_mixer
    drm/radeon: fix possible division-by-zero errors
    fbdev: omapfb: lcd_mipid: Fix an error handling path in mipid_spi_probe()
    arm64: dts: renesas: ulcb-kf: Remove flow control for SCIF1
    IB/hfi1: Fix sdma.h tx->num_descs off-by-one errors
  * soc/fsl/qe: fix usb.c build errors
      drivers/soc/fsl/qe/Kconfig
    ASoC: es8316: Increment max value for ALC Capture Target Volume control
    ARM: ep93xx: fix missing-prototype warnings
    drm/panel: simple: fix active size for Ampire AM-480272H3TMQW-T01H
    Input: adxl34x - do not hardcode interrupt trigger type
    ARM: dts: BCM5301X: Drop "clock-names" from the SPI node
    Input: drv260x - sleep between polling GO bit
    radeon: avoid double free in ci_dpm_init()
  * netlink: Add __sock_i_ino() for __netlink_diag_dump().
      include/net/sock.h
      net/core/sock.c
    ipvlan: Fix return value of ipvlan_queue_xmit()
    netfilter: nf_conntrack_sip: fix the ct_sip_parse_numerical_param() return value.
  * lib/ts_bm: reset initial match offset for every block of text
      lib/ts_bm.c
    gtp: Fix use-after-free in __gtp_encap_destroy().
  * netlink: do not hard code device address lenth in fdb dumps
      net/core/rtnetlink.c
  * netlink: fix potential deadlock in netlink_set_err()
      net/netlink/af_netlink.c
    wifi: ath9k: convert msecs to jiffies where needed
    wifi: ath9k: Fix possible stall on ath9k_txq_list_has_key()
    memstick r592: make memstick_debug_get_tpc_name() static
    kexec: fix a memory leak in crash_shrink_memory()
    watchdog/perf: more properly prevent false positives with turbo modes
  * watchdog/perf: define dummy watchdog_update_hrtimer_threshold() on correct config
      include/linux/nmi.h
    wifi: rsi: Do not set MMC_PM_KEEP_POWER in shutdown
    wifi: ath9k: don't allow to overwrite ENDPOINT0 attributes
    wifi: ray_cs: Fix an error handling path in ray_probe()
    wifi: ray_cs: Drop useless status variable in parse_addr()
    wifi: ray_cs: Utilize strnlen() in parse_addr()
    wifi: wl3501_cs: Fix an error handling path in wl3501_probe()
    wl3501_cs: use eth_hw_addr_set()
  * net: create netdev->dev_addr assignment helpers
      include/linux/etherdevice.h
      include/linux/netdevice.h
    wl3501_cs: Fix misspelling and provide missing documentation
    wl3501_cs: Remove unnecessary NULL check
    wl3501_cs: Fix a bunch of formatting issues related to function docs
    wifi: atmel: Fix an error handling path in atmel_probe()
    wifi: orinoco: Fix an error handling path in orinoco_cs_probe()
    wifi: orinoco: Fix an error handling path in spectrum_cs_probe()
    nfc: llcp: fix possible use of uninitialized variable in nfc_llcp_send_connect()
  * nfc: constify several pointers to u8, char and sk_buff
      include/net/nfc/nfc.h
    wifi: mwifiex: Fix the size of a memory allocation in mwifiex_ret_802_11_scan()
    samples/bpf: Fix buffer overflow in tcp_basertt
    wifi: ath9k: avoid referencing uninit memory in ath9k_wmi_ctrl_rx
    wifi: ath9k: fix AR9003 mac hardware hang check register offset calculation
    evm: Complete description of evm_inode_setattr()
    ARM: 9303/1: kprobes: avoid missing-declaration warnings
  * PM: domains: fix integer overflow issues in genpd_parse_state()
      drivers/base/power/domain.c
    clocksource/drivers/cadence-ttc: Fix memory leak in ttc_timer_probe
    clocksource/drivers/cadence-ttc: Use ttc driver as platform driver
  * clocksource/drivers: Unify the names to timer-* format
      drivers/clocksource/Makefile
    irqchip/jcore-aic: Fix missing allocation of IRQ descriptors
    irqchip/jcore-aic: Kill use of irq_create_strict_mappings()
    md/raid10: fix io loss while replacement replace rdev
    md/raid10: fix wrong setting of max_corr_read_errors
    md/raid10: fix overflow of md/safe_mode_delay
    md/raid10: check slab-out-of-bounds in md_bitmap_get_counter
  * treewide: Remove uninitialized_var() usage
      drivers/clk/clk-gate.c
      drivers/gpu/drm/drm_edid.c
      drivers/md/dm-io.c
      drivers/md/dm-ioctl.c
      drivers/md/dm-snap-persistent.c
      drivers/md/dm-table.c
      fs/fat/dir.c
      fs/fuse/control.c
      fs/fuse/file.c
      fs/overlayfs/copy_up.c
      kernel/async.c
      kernel/audit.c
      kernel/events/core.c
      kernel/events/uprobes.c
      kernel/exit.c
      kernel/futex.c
      kernel/trace/ring_buffer.c
      lib/radix-tree.c
      mm/memcontrol.c
      mm/percpu.c
      mm/slub.c
      mm/swap.c
      net/ipv4/netfilter/nf_socket_ipv4.c
      net/ipv6/ip6_flowlabel.c
      net/ipv6/netfilter/nf_socket_ipv6.c
      net/netfilter/nf_conntrack_ftp.c
      net/netfilter/nfnetlink_log.c
      net/netfilter/nfnetlink_queue.c
      net/sched/cls_flow.c
      sound/core/control_compat.c
      sound/usb/endpoint.c
    drm/amdgpu: Validate VM ioctl flags.
    scripts/tags.sh: Resolve gtags empty index generation
  * drm/edid: Fix uninitialized variable in drm_cvt_modes()
      drivers/gpu/drm/drm_edid.c
    fbdev: imsttfb: Fix use after free bug in imsttfb_probe
    video: imsttfb: check for ioremap() failures
    x86/smp: Use dedicated cache-line for mwait_play_dead()
    gfs2: Don't deref jdesc in evict
Linux 4.19.290
    x86: fix backwards merge of GDS/SRSO bit
    xen/netback: Fix buffer overrun triggered by unusual packet
    Documentation/x86: Fix backwards on/off logic about YMM support
    x86/xen: Fix secondary processors' FPU initialization
    KVM: Add GDS_NO support to KVM
    x86/speculation: Add Kconfig option for GDS
    x86/speculation: Add force option to GDS mitigation
  * x86/speculation: Add Gather Data Sampling mitigation
      drivers/base/cpu.c
    x86/fpu: Move FPU initialization into arch_cpu_finalize_init()
    x86/fpu: Mark init functions __init
    x86/fpu: Remove cpuinfo argument from init functions
  * init, x86: Move mem_encrypt_init() into arch_cpu_finalize_init()
      init/main.c
  * init: Invoke arch_cpu_finalize_init() earlier
      init/main.c
  * init: Remove check_bugs() leftovers
      init/main.c
    um/cpu: Switch to arch_cpu_finalize_init()
    sparc/cpu: Switch to arch_cpu_finalize_init()
    sh/cpu: Switch to arch_cpu_finalize_init()
    mips/cpu: Switch to arch_cpu_finalize_init()
    m68k/cpu: Switch to arch_cpu_finalize_init()
    ia64/cpu: Switch to arch_cpu_finalize_init()
    ARM: cpu: Switch to arch_cpu_finalize_init()
    x86/cpu: Switch to arch_cpu_finalize_init()
  * init: Provide arch_cpu_finalize_init()
      arch/Kconfig
      include/linux/cpu.h
      init/main.c
    Merge 4.19.289 into android-4.19-stable
Linux 4.19.289
    x86/cpu/amd: Add a Zenbleed fix
    x86/cpu/amd: Move the errata checking functionality up
    x86/microcode/AMD: Load late on both threads too
    Merge 4.19.288 into android-4.19-stable
Linux 4.19.288
    i2c: imx-lpi2c: fix type char overflow issue when calculating the clock cycle
    x86/apic: Fix kernel panic when booting with intremap=off and x2apic_phys
    drm/radeon: fix race condition UAF in radeon_gem_set_domain_ioctl
    drm/exynos: fix race condition UAF in exynos_g2d_exec_ioctl
    drm/exynos: vidi: fix a wrong error return
    ASoC: nau8824: Add quirk to active-high jack-detect
    s390/cio: unregister device when the only path is gone
    usb: gadget: udc: fix NULL dereference in remove()
    nfcsim.c: Fix error checking for debugfs_create_dir
    media: cec: core: don't set last_initiator if tx in progress
  * arm64: Add missing Set/Way CMO encodings
      arch/arm64/include/asm/sysreg.h
  * HID: wacom: Add error check to wacom_parse_and_register()
      drivers/hid/wacom_sys.c
    scsi: target: iscsi: Prevent login threads from racing between each other
  * sch_netem: acquire qdisc lock in netem_change()
      net/sched/sch_netem.c
    netfilter: nfnetlink_osf: fix module autoload
    netfilter: nf_tables: disallow element updates of bound anonymous sets
    be2net: Extend xmit workaround to BE3 chip
    mmc: usdhi60rol0: fix deferred probing
    mmc: sdhci-acpi: fix deferred probing
    mmc: omap_hsmmc: fix deferred probing
    mmc: omap: fix deferred probing
    mmc: mvsdio: fix deferred probing
    mmc: mvsdio: convert to devm_platform_ioremap_resource
    mmc: mtk-sd: fix deferred probing
    net: qca_spi: Avoid high load if QCA7000 is not available
    xfrm: Linearize the skb after offloading if needed.
    ieee802154: hwsim: Fix possible memory leaks
  * rcu: Upgrade rcu_swap_protected() to rcu_replace_pointer()
      include/linux/rcupdate.h
    nilfs2: prevent general protection fault in nilfs_clear_dirty_page()
  * cgroup: Do not corrupt task iteration when rebinding subsystem
      kernel/cgroup/cgroup.c
    PCI: hv: Fix a race condition bug in hv_pci_query_relations()
    Drivers: hv: vmbus: Fix vmbus_wait_for_unload() to scan present CPUs
    nilfs2: fix buffer corruption due to concurrent device reads
    ipmi: move message error checking to avoid deadlock
  * ipmi: Make the smi watcher be disabled immediately when not needed
      include/linux/ipmi_smi.h
    x86/purgatory: remove PGO flags
    nilfs2: reject devices with insufficient block count
    serial: lantiq: add missing interrupt ack
    serial: lantiq: Do not swap register read/writes
    serial: lantiq: Use readl/writel instead of ltq_r32/ltq_w32
    serial: lantiq: Change ltq_w32_mask to asc_update_bits
    Merge 4.19.287 into android-4.19-stable
Linux 4.19.287
  * mmc: block: ensure error propagation for non-blk
      drivers/mmc/core/block.c
    powerpc: Fix defconfig choice logic when cross compiling
    drm/nouveau/kms: Fix NULL pointer dereference in nouveau_connector_detect_depth
  * neighbour: delete neigh_lookup_nodev as not used
      include/net/neighbour.h
      net/core/neighbour.c
  * net: Remove unused inline function dst_hold_and_use()
      include/net/dst.h
  * neighbour: Remove unused inline function neigh_key_eq16()
      include/net/neighbour.h
    selftests/ptp: Fix timestamp printf format for PTP_SYS_OFFSET
  * net: tipc: resize nlattr array to correct size
      net/tipc/bearer.c
    net: lapbether: only support ethernet devices
    drm/nouveau: add nv_encoder pointer check for NULL
    drm/nouveau/kms: Don't change EDID when it hasn't actually changed
    drm/nouveau/dp: check for NULL nv_connector->native_mode
    igb: fix nvm.ops.read() error handling
  * sctp: fix an error code in sctp_sf_eat_auth()
      net/sctp/sm_statefuns.c
    IB/isert: Fix incorrect release of isert connection
    IB/isert: Fix possible list corruption in CMA handler
    IB/isert: Fix dead lock in ib_isert
    IB/uverbs: Fix to consider event queue closing also upon non-blocking mode
    RDMA/rxe: Fix the use-before-initialization error of resp_pkts
    RDMA/rxe: Removed unused name from rxe_task struct
    RDMA/rxe: Remove the unused variable obj
  * ping6: Fix send to link-local addresses with VRF.
      net/ipv6/ping.c
  * netfilter: nfnetlink: skip error delivery on batch in case of ENOMEM
      net/netfilter/nfnetlink.c
  * usb: gadget: f_ncm: Fix NTP-32 support
      drivers/usb/gadget/function/f_ncm.c
  * usb: gadget: f_ncm: Add OS descriptor support
      drivers/usb/gadget/function/f_ncm.c
      drivers/usb/gadget/function/u_ncm.h
  * usb: dwc3: gadget: Reset num TRBs before giving back the request
      drivers/usb/dwc3/gadget.c
    USB: serial: option: add Quectel EM061KGL series
  * Remove DECnet support from kernel
      include/linux/netdevice.h
      include/linux/netfilter.h
      include/linux/netfilter_defs.h
      include/net/netns/netfilter.h
      include/uapi/linux/netlink.h
      net/Kconfig
      net/Makefile
      net/core/dev.c
      net/core/neighbour.c
      net/netfilter/core.c
    net: usb: qmi_wwan: add support for Compal RXM-G1
    RDMA/uverbs: Restrict usage of privileged QKEYs
    nouveau: fix client work fence deletion race
    powerpc/purgatory: remove PGO flags
    kexec: support purgatories with .text.hot sections
    nilfs2: fix possible out-of-bounds segment allocation in resize ioctl
    nilfs2: fix incomplete buffer cleanup in nilfs_btnode_abort_change_key()
    nios2: dts: Fix tse_mac "max-frame-size" property
    ocfs2: check new file size on fallocate call
    ocfs2: fix use-after-free when unmounting read-only filesystem
    xen/blkfront: Only check REQ_FUA for writes
    mips: Move initrd_start check after initrd address sanitisation.
    MIPS: Alchemy: fix dbdma2
    parisc: Improve cache flushing for PCXL in arch_sync_dma_for_cpu()
  * power: supply: Fix logic checking if system is running from battery
      drivers/power/supply/power_supply_core.c
    irqchip/meson-gpio: Mark OF related data as maybe unused
  * regulator: Fix error checking for debugfs_create_dir
      drivers/regulator/core.c
  * power: supply: Ratelimit no data debug output
      drivers/power/supply/power_supply_sysfs.c
    ARM: dts: vexpress: add missing cache properties
    power: supply: bq27xxx: Use mod_delayed_work() instead of cancel() + schedule()
    power: supply: ab8500: Fix external_power_changed race
    Merge "Merge 4.19.286 into android-4.19-stable" into android-4.19-stable
  * Revert "tcp: deny tcp_disconnect() when threads are waiting"
      include/net/sock.h
      net/ipv4/af_inet.c
      net/ipv4/inet_connection_sock.c
      net/ipv4/tcp.c
    Merge "Merge 4.19.285 into android-4.19-stable" into android-4.19-stable
    Merge 4.19.286 into android-4.19-stable
  * Revert "tcp: deny tcp_disconnect() when threads are waiting"
      include/net/sock.h
      net/ipv4/af_inet.c
      net/ipv4/inet_connection_sock.c
      net/ipv4/tcp.c
  * ANDROID: GKI: update ABI xml for incrementalfs.ko
      android/abi_gki_aarch64.xml
    Merge 4.19.285 into android-4.19-stable
Linux 4.19.286
    Revert "staging: rtl8192e: Replace macro RTL_PCI_DEVICE with PCI_DEVICE"
    btrfs: unset reloc control if transaction commit fails in prepare_to_relocate()
    btrfs: check return value of btrfs_commit_transaction in relocation
  * ext4: only check dquot_initialize_needed() when debugging
      fs/ext4/xattr.c
    i2c: sprd: Delete i2c adapter in .remove's error path
    pinctrl: meson-axg: add missing GPIOA_18 gpio group
  * Bluetooth: Fix use-after-free in hci_remove_ltk/hci_remove_irk
      net/bluetooth/hci_core.c
    ceph: fix use-after-free bug for inodes when flushing capsnaps
    drm/amdgpu: fix xclk freq on CHIP_STONEY
    Input: psmouse - fix OOB access in Elantech protocol
  * Input: xpad - delete a Razer DeathAdder mouse VID/PID entry
      drivers/input/joystick/xpad.c
    batman-adv: Broken sync while rescheduling delayed work
  * lib: cpu_rmap: Fix potential use-after-free in irq_cpu_rmap_release()
      lib/cpu_rmap.c
  * net: sched: fix possible refcount leak in tc_chain_tmplt_add()
      net/sched/cls_api.c
  * net: sched: move rtm_tca_policy declaration to include file
      include/net/pkt_sched.h
      net/sched/cls_api.c
  * rfs: annotate lockless accesses to RFS sock flow table
      include/linux/netdevice.h
      net/core/dev.c
  * rfs: annotate lockless accesses to sk->sk_rxhash
      include/net/sock.h
  * Bluetooth: L2CAP: Add missing checks for invalid DCID
      net/bluetooth/l2cap_core.c
  * Bluetooth: Fix l2cap_disconnect_req deadlock
      net/bluetooth/l2cap_core.c
    net: dsa: lan9303: allow vid != 0 in port_fdb_{add|del} methods
    spi: qup: Request DMA before enabling clocks
    i40e: fix build warnings in i40e_alloc.h
    i40iw: fix build warning in i40iw_manage_apbvt()
  * UPSTREAM: net: cdc_ncm: Deal with too low values of dwNtbOutMaxSize
      drivers/net/usb/cdc_ncm.c
  * UPSTREAM: cdc_ncm: Fix the build warning
      drivers/net/usb/cdc_ncm.c
  * UPSTREAM: cdc_ncm: Implement the 32-bit version of NCM Transfer Block
      drivers/net/usb/cdc_ncm.c
      include/linux/usb/cdc_ncm.h
  * Revert "tcp: reduce POLLOUT events caused by TCP_NOTSENT_LOWAT"
      include/net/sock.h
      include/net/tcp.h
      net/core/stream.c
  * Revert "tcp: return EPOLLOUT from tcp_poll only when notsent_bytes is half the limit"
      net/ipv4/tcp.c
  * Revert "tcp: factor out __tcp_close() helper"
      include/net/tcp.h
      net/ipv4/tcp.c
  * Revert "tcp: add annotations around sk->sk_shutdown accesses"
      net/ipv4/af_inet.c
      net/ipv4/tcp.c
      net/ipv4/tcp_input.c
  * ANDROID: fix abi break in 4.19.284 for cpuhotplug.h
      include/linux/cpuhotplug.h
    Merge "Merge 4.19.284 into android-4.19-stable" into android-4.19-stable
    UPSTREAM: mailbox: mailbox-test: fix a locking issue in mbox_test_message_write()
    UPSTREAM: mailbox: mailbox-test: Fix potential double-free in mbox_test_message_write()
Linux 4.19.285
    wifi: rtlwifi: 8192de: correct checking of IQK reload
  * scsi: dpt_i2o: Do not process completions with invalid addresses
      drivers/scsi/Kconfig
    scsi: dpt_i2o: Remove broken pass-through ioctl (I2OUSERCMD)
  * regmap: Account for register length when chunking
      drivers/base/regmap/regmap.c
    fbcon: Fix null-ptr-deref in soft_cursor
  * ext4: add lockdep annotations for i_data_sem for ea_inode's
      fs/ext4/ext4.h
      fs/ext4/xattr.c
  * selinux: don't use make's grouped targets feature yet
      security/selinux/Makefile
    tty: serial: fsl_lpuart: use UARTCTRL_TXINV to send break instead of UARTCTRL_SBK
    mmc: vub300: fix invalid response handling
    rsi: Remove unnecessary boolean condition
    regulator: da905{2,5}: Remove unnecessary array check
    hwmon: (scmi) Remove redundant pointer check
    wifi: rtlwifi: remove always-true condition pointed out by GCC 12
    lib/dynamic_debug.c: use address-of operator on section symbols
  * kernel/extable.c: use address-of operator on section symbols
      kernel/extable.c
    eth: sun: cassini: remove dead code
  * gcc-12: disable '-Wdangling-pointer' warning for now
      Makefile
    ACPI: thermal: drop an always true check
    x86/boot: Wrap literal addresses in absolute_pointer()
    ata: libata-scsi: Use correct device no in ata_find_dev()
    scsi: stex: Fix gcc 13 warnings
  * usb: gadget: f_fs: Add unbind event before functionfs_unbind
      drivers/usb/gadget/function/f_fs.c
    net: usb: qmi_wwan: Set DTR quirk for BroadMobi BM818
  * iio: dac: build ad5758 driver when AD5758 is selected
      drivers/iio/dac/Makefile
    iio: dac: mcp4725: Fix i2c_master_send() return value handling
  * HID: wacom: avoid integer overflow in wacom_intuos_inout()
      drivers/hid/wacom_wac.c
  * HID: google: add jewel USB id
      drivers/hid/hid-ids.h
    iio: adc: mxs-lradc: fix the order of two cleanup operations
    mailbox: mailbox-test: fix a locking issue in mbox_test_message_write()
    atm: hide unused procfs functions
    ALSA: oss: avoid missing-prototype warnings
  * netfilter: conntrack: define variables exp_nat_nla_policy and any_addr with CONFIG_NF_NAT
      net/netfilter/nf_conntrack_netlink.c
    wifi: b43: fix incorrect __packed annotation
  * scsi: core: Decrease scsi_device's iorequest_cnt if dispatch failed
      drivers/scsi/scsi_lib.c
  * arm64/mm: mark private VM_FAULT_X defines as vm_fault_t
      arch/arm64/mm/fault.c
    ARM: dts: stm32: add pin map for CAN controller on stm32f7
    wifi: rtl8xxxu: fix authentication timeout due to incorrect RCR value
    media: dvb-core: Fix use-after-free due to race condition at dvb_ca_en50221
    media: dvb-core: Fix kernel WARNING for blocking operation in wait_event*()
  * media: dvb-core: Fix use-after-free due on race condition at dvb_net
      include/media/dvb_net.h
    media: mn88443x: fix !CONFIG_OF error by drop of_match_ptr from ID table
    media: ttusb-dec: fix memory leak in ttusb_dec_exit_dvb()
    media: dvb_ca_en50221: fix a size write bug
    media: netup_unidvb: fix irq init by register it at the end of probe
    media: dvb-usb: dw2102: fix uninit-value in su3000_read_mac_address
    media: dvb-usb: digitv: fix null-ptr-deref in digitv_i2c_xfer()
    media: dvb-usb-v2: rtl28xxu: fix null-ptr-deref in rtl28xxu_i2c_xfer
    media: dvb-usb-v2: ce6230: fix null-ptr-deref in ce6230_i2c_master_xfer()
    media: dvb-usb-v2: ec168: fix null-ptr-deref in ec168_i2c_xfer()
    media: dvb-usb: az6027: fix three null-ptr-deref in az6027_i2c_xfer()
  * media: dvb_demux: fix a bug for the continuity counter
      drivers/media/dvb-core/dvb_demux.c
    ASoC: ssm2602: Add workaround for playback distortions
  * xfrm: Check if_id in inbound policy/secpath match
      net/xfrm/xfrm_policy.c
    ASoC: dwc: limit the number of overrun messages
    nbd: Fix debugfs_create_dir error checking
    fbdev: stifb: Fix info entry in sti_struct on error path
    fbdev: modedb: Add 1920x1080 at 60 Hz video mode
    media: rcar-vin: Select correct interrupt mode for V4L2_FIELD_ALTERNATE
    ARM: 9295/1: unwind:fix unwind abort for uleb128 case
    mailbox: mailbox-test: Fix potential double-free in mbox_test_message_write()
    watchdog: menz069_wdt: fix watchdog initialisation
    net: dsa: mv88e6xxx: Increase wait after reset deactivation
    net/sched: flower: fix possible OOB write in fl_set_geneve_opt()
  * udp6: Fix race condition in udp6_sendmsg & connect
      net/core/sock.c
  * net/netlink: fix NETLINK_LIST_MEMBERSHIPS length report
      net/netlink/af_netlink.c
  * ocfs2/dlm: move BITS_TO_BYTES() to bitops.h for wider use
      include/linux/bitops.h
  * net: sched: fix NULL pointer dereference in mq_attach
      net/sched/sch_api.c
  * net/sched: Prohibit regrafting ingress or clsact Qdiscs
      net/sched/sch_api.c
  * net/sched: Reserve TC_H_INGRESS (TC_H_CLSACT) for ingress (clsact) Qdiscs
      net/sched/sch_api.c
      net/sched/sch_ingress.c
  * net/sched: sch_clsact: Only create under TC_H_CLSACT
      net/sched/sch_ingress.c
  * net/sched: sch_ingress: Only create under TC_H_INGRESS
      net/sched/sch_ingress.c
  * tcp: Return user_mss for TCP_MAXSEG in CLOSE/LISTEN state if user_mss set
      net/ipv4/tcp.c
  * tcp: deny tcp_disconnect() when threads are waiting
      include/net/sock.h
      net/ipv4/af_inet.c
      net/ipv4/inet_connection_sock.c
      net/ipv4/tcp.c
  * af_packet: do not use READ_ONCE() in packet_bind()
      net/packet/af_packet.c
    amd-xgbe: fix the false linkup in xgbe_phy_status
  * af_packet: Fix data-races of pkt_sk(sk)->num.
      net/packet/af_packet.c
    netrom: fix info-leak in nr_write_internal()
    net/mlx5: fw_tracer, Fix event handling
    dmaengine: pl330: rename _start to prevent build error
  * netfilter: ctnetlink: Support offloaded conntrack entry deletion
      net/netfilter/nf_conntrack_netlink.c
  * ipv{4,6}/raw: fix output xfrm lookup wrt protocol
      include/net/ip.h
      include/uapi/linux/in.h
      net/ipv4/ip_sockglue.c
      net/ipv4/raw.c
      net/ipv6/raw.c
  * bluetooth: Add cmd validity checks at the start of hci_sock_ioctl()
      net/bluetooth/hci_sock.c
  * cdc_ncm: Fix the build warning
      drivers/net/usb/cdc_ncm.c
    power: supply: bq24190: Call power_supply_changed() after updating input current
  * power: supply: core: Refactor power_supply_set_input_current_limit_from_supplier()
      drivers/power/supply/power_supply_core.c
      include/linux/power_supply.h
    power: supply: bq27xxx: After charger plug in/out wait 0.5s for things to stabilize
  * net: cdc_ncm: Deal with too low values of dwNtbOutMaxSize
      drivers/net/usb/cdc_ncm.c
  * cdc_ncm: Implement the 32-bit version of NCM Transfer Block
      drivers/net/usb/cdc_ncm.c
      include/linux/usb/cdc_ncm.h
    Merge 4.19.284 into android-4.19-stable
    UPSTREAM: efi: rt-wrapper: Add missing include
  * BACKPORT: arm64: efi: Execute runtime services from a dedicated stack
      arch/arm64/include/asm/efi.h
  * Revert "uapi/linux/const.h: prefer ISO-friendly __typeof__"
      include/uapi/linux/const.h
    Merge "Merge 4.19.283 into android-4.19-stable" into android-4.19-stable
Linux 4.19.284
  * drivers: depend on HAS_IOMEM for devm_platform_ioremap_resource()
      drivers/base/platform.c
    3c589_cs: Fix an error handling path in tc589_probe()
    forcedeth: Fix an error handling path in nv_probe()
  * ASoC: Intel: Skylake: Fix declaration of enum skl_ch_cfg
      include/uapi/sound/skl-tplg-interface.h
    x86/show_trace_log_lvl: Ensure stack pointer is aligned, again
    xen/pvcalls-back: fix double frees with pvcalls_new_active_socket()
  * coresight: Fix signedness bug in tmc_etr_buf_insert_barrier_packet()
      drivers/hwtracing/coresight/coresight-tmc-etr.c
    power: supply: sbs-charger: Fix INHIBITED bit for Status reg
  * power: supply: bq27xxx: Fix poll_interval handling and races on remove
      include/linux/power/bq27xxx_battery.h
    power: supply: bq27xxx: Fix I2C IRQ race on remove
    power: supply: bq27xxx: Fix bq27xxx_battery_update() race condition
  * power: supply: leds: Fix blink to LED on transition
      drivers/power/supply/power_supply_leds.c
  * ipv6: Fix out-of-bounds access in ipv6_find_tlv()
      net/ipv6/exthdrs_core.c
  * bpf: Fix mask generation for 32-bit narrow loads of 64-bit fields
      kernel/bpf/verifier.c
  * net: fix skb leak in __skb_tstamp_tx()
      net/core/skbuff.c
    media: radio-shark: Add endpoint checks
    USB: sisusbvga: Add endpoint checks
  * USB: core: Add routines for endpoint checks in old drivers
      drivers/usb/core/usb.c
      include/linux/usb.h
  * udplite: Fix NULL pointer dereference in __sk_mem_raise_allocated().
      net/ipv4/udplite.c
      net/ipv6/udplite.c
    ALSA: hda/realtek - Fix inverted bass GPIO pin on Acer 8951G
    ALSA: hda/realtek - Fixed one of HP ALC671 platform Headset Mic supported
    parisc: Fix flush_dcache_page() for usage from irq context
    selftests/memfd: Fix unknown type name build failure
    x86/mm: Avoid incomplete Global INVLPG flushes
    btrfs: use nofs when cleaning up aborted transactions
    parisc: Allow to reboot machine after system halt
    m68k: Move signal frame following exception on 68020/030
    ALSA: hda/ca0132: add quirk for EVGA X299 DARK
    spi: fsl-cpm: Use 16 bit mode for large transfers with even size
    spi: fsl-spi: Re-organise transfer bits_per_word adaptation
    spi: spi-fsl-spi: automatically adapt bits-per-word in cpu mode
    s390/qdio: fix do_sqbs() inline assembly constraint
    s390/qdio: get rid of register asm
    vc_screen: reload load of struct vc_data pointer in vcs_write() to avoid UAF
    vc_screen: rewrite vcs_size to accept vc, not inode
  * usb: gadget: u_ether: Fix host MAC address case
      drivers/usb/gadget/function/u_ether.c
  * usb: gadget: u_ether: Convert prints to device prints
      drivers/usb/gadget/function/u_ether.c
  * lib/string_helpers: Introduce string_upper() and string_lower() helpers
      include/linux/string_helpers.h
    ALSA: hda/realtek: Add a quirk for HP EliteDesk 805
    ALSA: hda/realtek - ALC897 headset MIC no sound
    ALSA: hda/realtek - Add headset Mic support for Lenovo ALC897 platform
    ALSA: hda/realtek: Fix the mic type detection issue for ASUS G551JW
    ALSA: hda/realtek - The front Mic on a HP machine doesn't work
    ALSA: hda/realtek - Enable the headset of Acer N50-600 with ALC662
    ALSA: hda/realtek - Enable headset mic of Acer X2660G with ALC662
    ALSA: hda/realtek - Add Headset Mic supported for HP cPC
    ALSA: hda/realtek - More constifications
    Add Acer Aspire Ethos 8951G model quirk
  * HID: wacom: Force pen out of prox if no events have been received in a while
      drivers/hid/wacom.h
      drivers/hid/wacom_sys.c
      drivers/hid/wacom_wac.c
    netfilter: nf_tables: do not allow RULE_ID to refer to another chain
    netfilter: nf_tables: validate NFTA_SET_ELEM_OBJREF based on NFT_SET_OBJECT flag
    netfilter: nf_tables: stricter validation of element data
  * netfilter: nf_tables: allow up to 64 bytes in the set element data area
      include/net/netfilter/nf_tables.h
    netfilter: nf_tables: add nft_setelem_parse_key()
    netfilter: nf_tables: validate registers coming from userspace.
  * netfilter: nftables: statify nft_parse_register()
      include/net/netfilter/nf_tables.h
  * netfilter: nftables: add nft_parse_register_store() and use it
      include/net/netfilter/nf_tables.h
      include/net/netfilter/nf_tables_core.h
      include/net/netfilter/nft_fib.h
  * netfilter: nftables: add nft_parse_register_load() and use it
      include/net/netfilter/nf_tables.h
      include/net/netfilter/nf_tables_core.h
      include/net/netfilter/nft_masq.h
      include/net/netfilter/nft_redir.h
    nilfs2: fix use-after-free bug of nilfs_root in nilfs_evict_inode()
    tpm/tpm_tis: Disable interrupts for more Lenovo devices
    ceph: force updating the msg pointer in non-split case
    serial: Add support for Advantech PCI-1611U card
  * statfs: enforce statfs[64] structure initialization
      fs/statfs.c
    ALSA: hda: Add NVIDIA codec IDs a3 through a7 to patch table
    ALSA: hda: Fix Oops by 9.1 surround channel names
    usb: typec: altmodes/displayport: fix pin_assignment_show
  * usb-storage: fix deadlock when a scsi command timeouts more than once
      drivers/usb/storage/scsiglue.c
    vlan: fix a potential uninit-value in vlan_dev_hard_start_xmit()
    igb: fix bit_shift to be in [1..8] range
    cassini: Fix a memory leak in the error handling path of cas_init_one()
    net: bcmgenet: Restore phy_stop() depending upon suspend/close
    net: bcmgenet: Remove phy_stop() from bcmgenet_netif_stop()
    net: nsh: Use correct mac_offset to unwind gso skb in nsh_gso_segment()
    drm/exynos: fix g2d_open/close helper function definitions
    media: netup_unidvb: fix use-after-free at del_timer()
    erspan: get the proto with the md version for collect_md
  * ip_gre, ip6_gre: Fix race condition on o_seqno in collect_md mode
      include/net/ip6_tunnel.h
      include/net/ip_tunnels.h
    ip6_gre: Make o_seqno start from 0 in native mode
    ip6_gre: Fix skb_under_panic in __gre6_xmit()
    serial: arc_uart: fix of_iomap leak in `arc_serial_probe`
  * drivers: provide devm_platform_ioremap_resource()
      drivers/base/platform.c
      include/linux/platform_device.h
    vsock: avoid to close connected socket after the timeout
    net: fec: Better handle pm_runtime_get() failing in .remove()
  * af_key: Reject optional tunnel/BEET mode templates in outbound policies
      net/key/af_key.c
    cpupower: Make TSC read per CPU for Mperf monitor
    btrfs: fix space cache inconsistency after error loading it from disk
    btrfs: replace calls to btrfs_find_free_ino with btrfs_find_free_objectid
    mfd: dln2: Fix memory leak in dln2_probe()
    phy: st: miphy28lp: use _poll_timeout functions for waits
  * Input: xpad - add constants for GIP interface numbers
      drivers/input/joystick/xpad.c
    clk: tegra20: fix gcc-7 constant overflow warning
    recordmcount: Fix memory leaks in the uwrite function
  * sched: Fix KCSAN noinstr violation
      include/linux/sched/task_stack.h
    mcb-pci: Reallocate memory region to avoid memory overlapping
    serial: 8250: Reinit port->pm on port specific driver unbind
    usb: typec: tcpm: fix multiple times discover svids error
  * HID: wacom: generic: Set battery quirk only when we see battery data
      drivers/hid/wacom_wac.c
    spi: spi-imx: fix MX51_ECSPI_* macros when cs > 3
    HID: logitech-hidpp: Reconcile USB and Unifying serials
    HID: logitech-hidpp: Don't use the USB serial for USB devices
    staging: rtl8192e: Replace macro RTL_PCI_DEVICE with PCI_DEVICE
  * Bluetooth: L2CAP: fix "bad unlock balance" in l2cap_disconnect_rsp
      net/bluetooth/l2cap_core.c
    wifi: iwlwifi: dvm: Fix memcpy: detected field-spanning write backtrace
  * f2fs: fix to drop all dirty pages during umount() if cp_error is set
      fs/f2fs/checkpoint.c
      fs/f2fs/data.c
  * ext4: Fix best extent lstart adjustment logic in ext4_mb_new_inode_pa()
      fs/ext4/mballoc.c
  * ext4: set goal start correctly in ext4_mb_normalize_request
      fs/ext4/mballoc.c
    gfs2: Fix inode height consistency check
    scsi: message: mptlan: Fix use after free bug in mptlan_remove() due to race condition
  * lib: cpu_rmap: Avoid use after free on rmap->obj array entries
      lib/cpu_rmap.c
  * net: Catch invalid index in XPS mapping
      net/core/dev.c
    net: pasemi: Fix return type of pasemi_mac_start_tx()
    ext2: Check block size validity during mount
    wifi: brcmfmac: cfg80211: Pass the PMK in binary instead of hex
    ACPICA: ACPICA: check null return of ACPI_ALLOCATE_ZEROED in acpi_db_display_objects
    ACPICA: Avoid undefined behavior: applying zero offset to null pointer
    drm/tegra: Avoid potential 32-bit integer overflow
    ACPI: EC: Fix oops when removing custom query handlers
  * firmware: arm_sdei: Fix sleep from invalid context BUG
      include/linux/cpuhotplug.h
    memstick: r592: Fix UAF bug in r592_remove due to race condition
  * regmap: cache: Return error in cache sync operations for REGCACHE_NONE
      drivers/base/regmap/regcache.c
    drm/amd/display: Use DC_LOG_DC in the trasform pixel function
    fs: hfsplus: remove WARN_ON() from hfsplus_cat_{read,write}_inode()
  * af_unix: Fix data races around sk->sk_shutdown.
      net/unix/af_unix.c
  * af_unix: Fix a data race of sk->sk_receive_queue->qlen.
      net/unix/af_unix.c
  * net: datagram: fix data-races in datagram_poll()
      net/core/datagram.c
    ipvlan:Fix out-of-bounds caused by unclear skb->cb
  * tcp: add annotations around sk->sk_shutdown accesses
      net/ipv4/af_inet.c
      net/ipv4/tcp.c
      net/ipv4/tcp_input.c
  * tcp: factor out __tcp_close() helper
      include/net/tcp.h
      net/ipv4/tcp.c
  * tcp: return EPOLLOUT from tcp_poll only when notsent_bytes is half the limit
      net/ipv4/tcp.c
  * tcp: reduce POLLOUT events caused by TCP_NOTSENT_LOWAT
      include/net/sock.h
      include/net/tcp.h
      net/core/stream.c
  * net: annotate sk->sk_err write from do_recvmmsg()
      net/socket.c
  * netlink: annotate accesses to nlk->cb_running
      net/netlink/af_netlink.c
  * net: Fix load-tearing on sk->sk_stamp in sock_recv_cmsgs().
      include/net/sock.h
  * UPSTREAM: ext4: avoid a potential slab-out-of-bounds in ext4_group_desc_csum
      fs/ext4/super.c
    Merge 4.19.283 into android-4.19-stable
  * UPSTREAM: ext4: fix invalid free tracking in ext4_xattr_move_to_block()
      fs/ext4/xattr.c
Linux 4.19.283
  * mm/page_alloc: fix potential deadlock on zonelist_update_seq seqlock
      mm/page_alloc.c
  * printk: declare printk_deferred_{enter,safe}() in include/linux/printk.h
      include/linux/printk.h
    PCI: pciehp: Fix AB-BA deadlock between reset_lock and device_lock
    PCI: pciehp: Use down_read/write_nested(reset_lock) to fix lockdep errors
    drbd: correctly submit flush bio on barrier
    serial: 8250: Fix serial8250_tx_empty() race with DMA Tx
  * tty: Prevent writing chars during tcsetattr TCSADRAIN/FLUSH
      drivers/tty/tty_io.c
      drivers/tty/tty_ioctl.c
      include/linux/tty.h
  * ext4: fix invalid free tracking in ext4_xattr_move_to_block()
      fs/ext4/xattr.c
  * ext4: remove a BUG_ON in ext4_mb_release_group_pa()
      fs/ext4/mballoc.c
  * ext4: bail out of ext4_xattr_ibody_get() fails for any reason
      fs/ext4/inline.c
  * ext4: add bounds checking in get_max_inline_xattr_value_size()
      fs/ext4/inline.c
  * ext4: improve error recovery code paths in __ext4_remount()
      fs/ext4/super.c
  * ext4: avoid a potential slab-out-of-bounds in ext4_group_desc_csum
      fs/ext4/super.c
  * ext4: fix WARNING in mb_find_extent
      fs/ext4/balloc.c
  * HID: wacom: Set a default resolution for older tablets
      drivers/hid/wacom_wac.c
    drm/panel: otm8009a: Set backlight parent to panel device
    ARM: dts: s5pv210: correct MIPI CSIS clock name
    ARM: dts: exynos: fix WM8960 clock name in Itop Elite
    sh: nmi_debug: fix return value of __setup handler
    sh: init: use OF_EARLY_FLATTREE for early init
    sh: math-emu: fix macro redefined warning
    platform/x86: touchscreen_dmi: Add info for the Dexp Ursus KX210i
    cifs: fix pcchunk length type in smb2_copychunk_range
    btrfs: print-tree: parent bytenr must be aligned to sector size
    btrfs: fix btrfs_prev_leaf() to not return the same key twice
    perf symbols: Fix return incorrect build_id size in elf_read_build_id()
    perf map: Delete two variable initialisations before null pointer checks in sort__sym_from_cmp()
    perf vendor events power9: Remove UTF-8 characters from JSON files
    virtio_net: suppress cpu stall when free_unused_bufs
    virtio_net: split free_unused_bufs()
    ALSA: caiaq: input: Add error handling for unsupported input methods in `snd_usb_caiaq_input_init`
    drm/amdgpu: add a missing lock for AMDGPU_SCHED
  * drm/amdgpu: Add command to override the context priority.
      include/uapi/drm/amdgpu_drm.h
    drm/amdgpu: Put enable gfx off feature to a delay thread
    drm/amdgpu: Add amdgpu_gfx_off_ctrl function
  * af_packet: Don't send zero-byte data in packet_sendmsg_spkt().
      net/packet/af_packet.c
    rxrpc: Fix hard call timeout units
  * net/sched: act_mirred: Add carrier check
      net/sched/act_mirred.c
  * writeback: fix call of incorrect macro
      fs/fs-writeback.c
    net: dsa: mv88e6xxx: add mv88e6321 rsvd2cpu
    net: dsa: mv88e6xxx: Add missing watchdog ops for 6320 family
  * sit: update dev->needed_headroom in ipip6_tunnel_bind_dev()
      net/ipv6/sit.c
    relayfs: fix out-of-bounds access in relay_file_read
    kernel/relay.c: fix read_pos error when multiple readers
  * dm verity: fix error handling for check_at_most_once on FEC
      drivers/md/dm-verity-target.c
  * dm verity: skip redundant verity_handle_err() on I/O errors
      drivers/md/dm-verity-target.c
    ipmi: fix SSIF not responding under certain cond.
    ipmi_ssif: Rename idle state and check
  * ipmi: Fix how the lower layers are told to watch for messages
      include/linux/ipmi_smi.h
    ipmi: Fix SSIF flag requests
  * tick/nohz: Fix cpu_is_hotpluggable() by checking with nohz subsystem
      drivers/base/cpu.c
      include/linux/tick.h
      kernel/time/tick-sched.c
  * nohz: Add TICK_DEP_BIT_RCU
      include/linux/tick.h
      include/trace/events/timer.h
      kernel/time/tick-sched.c
  * netfilter: nf_tables: deactivate anonymous set from preparation phase
      include/net/netfilter/nf_tables.h
    debugobject: Ensure pool refill (again)
    perf auxtrace: Fix address filter entire kernel size
  * dm ioctl: fix nested locking in table_clear() to remove deadlock concern
      drivers/md/dm-ioctl.c
    dm flakey: fix a crash with invalid table line
    dm integrity: call kmem_cache_destroy() in dm_integrity_init() error path
    s390/dasd: fix hanging blockdevice after request requeue
  * btrfs: scrub: reject unsupported scrub flags
      include/uapi/linux/btrfs.h
    clk: rockchip: rk3399: allow clk_cifout to force clk_cifout_src to reparent
    wifi: rtl8xxxu: RTL8192EU always needs full init
    md/raid10: fix null-ptr-deref in raid10_sync_request
    nilfs2: fix infinite loop in nilfs_mdt_get_block()
    nilfs2: do not write dirty data after degenerating to read-only
    parisc: Fix argument pointer in real64_call_asm()
    dmaengine: at_xdmac: do not enable all cyclic channels
    phy: tegra: xusb: Add missing tegra_xusb_port_unregister for usb2_port and ulpi_port
    pwm: mtk-disp: Disable shadow registers before setting backlight values
    pwm: mtk-disp: Adjust the clocks to avoid them mismatch
    pwm: mtk-disp: Don't check the return code of pwmchip_remove()
    openrisc: Properly store r31 to pt_regs on unhandled exceptions
    RDMA/mlx5: Use correct device num_ports when modify DC
  * SUNRPC: remove the maximum number of retries in call_bind_status
      include/linux/sunrpc/sched.h
    NFSv4.1: Always send a RECLAIM_COMPLETE after establishing lease
    IB/hfi1: Fix SDMA mmu_rb_node not being evicted in LRU order
  * clk: add missing of_node_put() in "assigned-clocks" property parsing
      drivers/clk/clk-conf.c
    power: supply: generic-adc-battery: fix unit scaling
    RDMA/mlx4: Prevent shift wrapping in set_user_sq_size()
    RDMA/rdmavt: Delete unnecessary NULL check
  * perf/core: Fix hardlockup failure caused by perf throttle
      kernel/events/core.c
    powerpc/rtas: use memmove for potentially overlapping buffer copy
  * macintosh: via-pmu-led: requires ATA to be set
      drivers/macintosh/Kconfig
    powerpc/sysdev/tsi108: fix resource printk format warnings
    powerpc/wii: fix resource printk format warnings
    powerpc/mpc512x: fix resource printk format warning
    macintosh/windfarm_smu_sat: Add missing of_node_put()
  * spmi: Add a check for remove callback when removing a SPMI driver
      drivers/spmi/spmi.c
    staging: rtl8192e: Fix W_DISABLE# does not work after stop/start
    serial: 8250: Add missing wakeup event reporting
    tty: serial: fsl_lpuart: adjust buffer length to the intended size
    usb: chipidea: fix missing goto in `ci_hdrc_probe`
    sh: sq: Fix incorrect element size for allocating bitmap buffer
  * uapi/linux/const.h: prefer ISO-friendly __typeof__
      include/uapi/linux/const.h
    spi: cadence-quadspi: fix suspend-resume implementations
    mtd: spi-nor: cadence-quadspi: Handle probe deferral while requesting DMA channel
    mtd: spi-nor: cadence-quadspi: Don't initialize rx_dma_complete on failure
    mtd: spi-nor: cadence-quadspi: Make driver independent of flash geometry
    ia64: salinfo: placate defined-but-not-used warning
    ia64: mm/contig: fix section mismatch warning/error
  * of: Fix modalias string generation
      drivers/of/device.c
    vmci_host: fix a race condition in vmci_host_poll() causing GPF
    spi: fsl-spi: Fix CPM/QE mode Litte Endian
    spi: qup: Don't skip cleanup in remove's error path
    spi: qup: fix PM reference leak in spi_qup_remove()
  * linux/vt_buffer.h: allow either builtin or modular for macros
      include/linux/vt_buffer.h
    usb: gadget: udc: renesas_usb3: Fix use after free bug in renesas_usb3_remove due to race condition
    fpga: bridge: fix kernel-doc parameter description
    usb: host: xhci-rcar: remove leftover quirk handling
  * pstore: Revert pmsg_lock back to a normal mutex
      fs/pstore/pmsg.c
  * tcp/udp: Fix memleaks of sk and zerocopy skbs with TX timestamp.
      net/core/skbuff.c
    net: amd: Fix link leak when verifying config failed
  * netlink: Use copy_to_user() for optval in netlink_getsockopt().
      net/netlink/af_netlink.c
    Revert "Bluetooth: btsdio: fix use after free bug in btsdio_remove due to unfinished work"
  * ipv4: Fix potential uninit variable access bug in __ip_make_skb()
      net/ipv4/ip_output.c
  * netfilter: nf_tables: don't write table validation state without mutex
      include/linux/netfilter/nfnetlink.h
      net/netfilter/nfnetlink.c
    ixgbe: Enable setting RSS table to default values
    ixgbe: Allow flow hash to be set via ethtool
    wifi: iwlwifi: mvm: check firmware response size
    wifi: iwlwifi: make the loop for card preparation effective
    md/raid10: fix memleak of md thread
    md: update the optimal I/O size on reshape
    md/raid10: fix memleak for 'conf->bio_split'
    md/raid10: fix leak of 'r10bio->remaining' for recovery
  * crypto: drbg - Only fail when jent is unavailable in FIPS mode
      crypto/drbg.c
  * crypto: drbg - make drbg_prepare_hrng() handle jent instantiation errors
      crypto/drbg.c
    bpftool: Fix bug for long instructions in program CFG dumps
    wifi: rtlwifi: fix incorrect error codes in rtl_debugfs_set_write_reg()
    wifi: rtlwifi: fix incorrect error codes in rtl_debugfs_set_write_rfreg()
    rtlwifi: Replace RT_TRACE with rtl_dbg
    rtlwifi: Start changing RT_TRACE into rtl_dbg
    rtlwifi: rtl_pci: Fix memory leak when hardware init fails
    scsi: megaraid: Fix mega_cmd_done() CMDID_INT_CMDS
    scsi: target: iscsit: Fix TAS handling during conn cleanup
  * net/packet: convert po->auxdata to an atomic flag
      net/packet/af_packet.c
      net/packet/internal.h
  * net/packet: convert po->origdev to an atomic flag
      net/packet/af_packet.c
      net/packet/internal.h
    vlan: partially enable SIOCSHWTSTAMP in container
  * scm: fix MSG_CTRUNC setting condition for SO_PASSSEC
      include/net/scm.h
    tools: bpftool: Remove invalid \' json escape
    wifi: ath6kl: reduce WARN to dev_dbg() in callback
    wifi: ath5k: fix an off by one check in ath5k_eeprom_read_freq_list()
    wifi: ath9k: hif_usb: fix memory leak of remain_skbs
    wifi: ath6kl: minor fix for allocation size
    debugobject: Prevent init race with static objects
    debugobjects: Move printk out of db->lock critical sections
    debugobjects: Add percpu free pools
  * arm64: kgdb: Set PSTATE.SS to 1 to re-enable single-step
      arch/arm64/include/asm/debug-monitors.h
      arch/arm64/kernel/debug-monitors.c
    x86/ioapic: Don't return 0 from arch_dynirq_lower_bound()
    media: rc: gpio-ir-recv: Fix support for wake-up
    media: rcar_fdp1: Fix refcount leak in probe and remove function
    media: rcar_fdp1: Fix the correct variable assignments
    media: saa7134: fix use after free bug in saa7134_finidev due to race condition
    media: dm1105: Fix use after free bug in dm1105_remove due to race condition
    x86/apic: Fix atomic update of offset in reserve_eilvt_offset()
    drm/msm/adreno: drop bogus pm_runtime_set_active()
    drm/msm/adreno: Defer enabling runpm until hw_init()
  * firmware: qcom_scm: Clear download bit during reboot
      drivers/firmware/qcom_scm.c
    media: av7110: prevent underflow in write_ts_to_decoder()
  * media: uapi: add MEDIA_BUS_FMT_METADATA_FIXED media bus format.
      include/uapi/linux/media-bus-format.h
    media: bdisp: Add missing check for create_workqueue
    ARM: dts: qcom: ipq4019: Fix the PCI I/O port range
    EDAC/skx: Fix overflows on the DRAM row address mapping arrays
    EDAC, skx: Move debugfs node under EDAC's hierarchy
  * drm/probe-helper: Cancel previous job before starting new one
      drivers/gpu/drm/drm_probe_helper.c
    drm/vgem: add missing mutex_destroy
    drm/rockchip: Drop unbalanced obj unref
  * selinux: ensure av_permissions.h is built when needed
      security/selinux/Makefile
  * selinux: fix Makefile dependencies of flask.h
      security/selinux/Makefile
    ubifs: Free memory for tmpfile name
    ubi: Fix return value overwrite issue in try_write_vid_and_data()
    ubifs: Fix memleak when insert_old_idx() failed
    Revert "ubifs: dirty_cow_znode: Fix memleak in error handling path"
    i2c: omap: Fix standard mode false ACK readings
    KVM: nVMX: Emulate NOPs in L2, and PAUSE if it's not intercepted
    reiserfs: Add security prefix to xattr name in reiserfs_security_write()
  * ring-buffer: Sync IRQ works before buffer destruction
      kernel/trace/ring_buffer.c
    pwm: meson: Fix axg ao mux parents
    MIPS: fw: Allow firmware to pass a empty env
  * xhci: fix debugfs register accesses while suspended
      drivers/usb/host/xhci-debugfs.c
  * debugfs: regset32: Add Runtime PM support
      fs/debugfs/file.c
      include/linux/debugfs.h
    staging: iio: resolver: ads1210: fix config mode
    perf sched: Cast PTHREAD_STACK_MIN to int as it may turn into sysconf(__SC_THREAD_STACK_MIN_VALUE)
  * USB: dwc3: fix runtime pm imbalance on unbind
      drivers/usb/dwc3/core.c
    stmmac: debugfs entry name is not be changed when udev rename device name.
    ASoC: Intel: bytcr_rt5640: Add quirk for the Acer Iconia One 7 B1-750
    iio: adc: palmas_gpadc: fix NULL dereference on rmmod
    USB: serial: option: add UNISOC vendor and TOZED LT70C product
  * bluetooth: Perform careful capability checks in hci_sock_ioctl()
      net/bluetooth/hci_sock.c
    wifi: brcmfmac: slab-out-of-bounds read in brcmf_get_assoc_ies()
  * ANDROID: incremental fs: Evict inodes before freeing mount data
      fs/incfs/main.c
      fs/incfs/vfs.c
  * Revert "Revert "mm/rmap: Fix anon_vma->degree ambiguity leading to double-reuse""
      android/abi_gki_aarch64.xml
      include/linux/rmap.h
      mm/rmap.c

Bug: 299241959
Change-Id: Ib8c4ff87b1b0b720abce0f5fcdf1a51f01a472a9
Signed-off-by: Wilson Sung <wilsonsung@google.com>
Signed-off-by: ChangYan Lee <changyan@google.com>
2023-10-17 05:00:19 +00:00
Douglas Anderson
a8ffe81954 watchdog/perf: define dummy watchdog_update_hrtimer_threshold() on correct config
[ Upstream commit 5e008df11c55228a86a1bae692cc2002503572c9 ]

Patch series "watchdog/hardlockup: Add the buddy hardlockup detector", v5.

This patch series adds the "buddy" hardlockup detector.  In brief, the
buddy hardlockup detector can detect hardlockups without arch-level
support by having CPUs checkup on a "buddy" CPU periodically.

Given the new design of this patch series, testing all combinations is
fairly difficult. I've attempted to make sure that all combinations of
CONFIG_ options are good, but it wouldn't surprise me if I missed
something. I apologize in advance and I'll do my best to fix any
problems that are found.

This patch (of 18):

The real watchdog_update_hrtimer_threshold() is defined in
kernel/watchdog_hld.c.  That file is included if
CONFIG_HARDLOCKUP_DETECTOR_PERF and the function is defined in that file
if CONFIG_HARDLOCKUP_CHECK_TIMESTAMP.

The dummy version of the function in "nmi.h" didn't get that quite right.
While this doesn't appear to be a huge deal, it's nice to make it
consistent.

It doesn't break builds because CHECK_TIMESTAMP is only defined by x86 so
others don't get a double definition, and x86 uses perf lockup detector,
so it gets the out of line version.

Link: https://lkml.kernel.org/r/20230519101840.v5.18.Ia44852044cdcb074f387e80df6b45e892965d4a1@changeid
Link: https://lkml.kernel.org/r/20230519101840.v5.1.I8cbb2f4fa740528fcfade4f5439b6cdcdd059251@changeid
Fixes: 7edaeb6841 ("kernel/watchdog: Prevent false positives with turbo modes")
Signed-off-by: Douglas Anderson <dianders@chromium.org>
Reviewed-by: Nicholas Piggin <npiggin@gmail.com>
Reviewed-by: Petr Mladek <pmladek@suse.com>
Cc: Andi Kleen <ak@linux.intel.com>
Cc: Catalin Marinas <catalin.marinas@arm.com>
Cc: Chen-Yu Tsai <wens@csie.org>
Cc: Christophe Leroy <christophe.leroy@csgroup.eu>
Cc: Daniel Thompson <daniel.thompson@linaro.org>
Cc: "David S. Miller" <davem@davemloft.net>
Cc: Guenter Roeck <groeck@chromium.org>
Cc: Ian Rogers <irogers@google.com>
Cc: Lecopzer Chen <lecopzer.chen@mediatek.com>
Cc: Marc Zyngier <maz@kernel.org>
Cc: Mark Rutland <mark.rutland@arm.com>
Cc: Masayoshi Mizuma <msys.mizuma@gmail.com>
Cc: Matthias Kaehlcke <mka@chromium.org>
Cc: Michael Ellerman <mpe@ellerman.id.au>
Cc: Pingfan Liu <kernelfans@gmail.com>
Cc: Randy Dunlap <rdunlap@infradead.org>
Cc: "Ravi V. Shankar" <ravi.v.shankar@intel.com>
Cc: Ricardo Neri <ricardo.neri@intel.com>
Cc: Stephane Eranian <eranian@google.com>
Cc: Stephen Boyd <swboyd@chromium.org>
Cc: Sumit Garg <sumit.garg@linaro.org>
Cc: Tzung-Bi Shih <tzungbi@chromium.org>
Cc: Will Deacon <will@kernel.org>
Cc: Colin Cross <ccross@android.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2023-08-11 11:45:06 +02:00
Lucas Wei
2119f07e02 Merge android-4.19-stable (4.19.261) into android-msm-pixel-4.19-lts
Merge 4.19.261 into android-4.19-stable
Linux 4.19.261
    clk: iproc: Do not rely on node name for correct PLL setup
    selftests: Fix the if conditions of in test_extra_filter()
    nvme: Fix IOC_PR_CLEAR and IOC_PR_RELEASE ioctls for nvme devices
    nvme: add new line after variable declatation
  * usbnet: Fix memory leak in usbnet_disconnect()
      drivers/net/usb/usbnet.c
    Input: melfas_mip4 - fix return value check in mip4_probe()
    Revert "drm: bridge: analogix/dp: add panel prepare/unprepare in suspend/resume time"
    soc: sunxi: sram: Fix debugfs info for A64 SRAM C
    soc: sunxi: sram: Fix probe function ordering issues
    soc: sunxi: sram: Prevent the driver from being unbound
    soc: sunxi: sram: Actually claim SRAM regions
    ima: Free the entire rule if it fails to parse
    ima: Free the entire rule when deleting a list of rules
    ima: Have the LSM free its audit rule
  * mm/migrate_device.c: flush TLB while holding PTL
      mm/migrate.c
  * mm: prevent page_frag_alloc() from corrupting the memory
      mm/page_alloc.c
  * mm/page_alloc: fix race condition between build_all_zonelists and page allocation
      mm/page_alloc.c
    mmc: moxart: fix 4-bit bus width and remove 8-bit bus width
    libata: add ATA_HORKAGE_NOLPM for Pioneer BDR-207M and BDR-205
    ntfs: fix BUG_ON in ntfs_lookup_inode_by_name()
    ARM: dts: integrator: Tag PCI host with device_type
    net: usb: qmi_wwan: Add new usb-id for Dell branded EM7455
    uas: ignore UAS for Thinkplus chips
    usb-storage: Add Hiksemi USB3-FW to IGNORE_UAS
    uas: add no-uas quirk for Hiksemi usb_disk
    Merge 4.19.260 into android-4.19-stable
Linux 4.19.260
  * ext4: make directory inode spreading reflect flexbg size
      fs/ext4/ialloc.c
    usb: dwc3: pci: Allow Elkhart Lake to utilize DSM method for PM functionality
  * workqueue: don't skip lockdep work dependency in cancel_work_sync()
      kernel/workqueue.c
    drm/rockchip: Fix return type of cdn_dp_connector_mode_valid
    drm/amd/display: Limit user regamma to a valid value
    Drivers: hv: Never allocate anything besides framebuffer from framebuffer memory region
    s390/dasd: fix Oops in dasd_alias_get_start_dev due to missing pavgroup
    serial: tegra: Use uart_xmit_advance(), fixes icount.tx accounting
  * serial: Create uart_xmit_advance()
      include/linux/serial_core.h
    net: sunhme: Fix packet reception for len < RX_COPY_THRESHOLD
    perf kcore_copy: Do not check /proc/modules is unchanged
    perf jit: Include program header in ELF files
    can: gs_usb: gs_can_open(): fix race dev->can.state condition
  * netfilter: ebtables: fix memory leak when blob is malformed
      net/bridge/netfilter/ebtables.c
  * of: mdio: Add of_node_put() when breaking out of for_each_xx
      drivers/of/of_mdio.c
    i40e: Fix set max_tx_rate when it is lower than 1 Mbps
    i40e: Fix VF set max MTU size
    MIPS: lantiq: export clk_get_io() for lantiq_wdt.ko
    net: team: Unsync device addresses on ndo_stop
    ipvlan: Fix out-of-bound bugs caused by unset skb->mac_header
    iavf: Fix cached head and tail value for iavf_get_tx_pending
  * netfilter: nf_conntrack_irc: Tighten matching on DCC message
      net/netfilter/nf_conntrack_irc.c
    netfilter: nf_conntrack_sip: fix ct_sip_walk_headers
    arm64: dts: rockchip: Remove 'enable-active-low' from rk3399-puma
    arm64: dts: rockchip: Set RK3399-Gru PCLK_EDP to 24 MHz
  * mm/slub: fix to return errno if kmalloc() fails
      mm/slub.c
    efi: libstub: check Shim mode using MokSBStateRT
    ALSA: hda/realtek: Enable 4-speaker output Dell Precision 5530 laptop
    ALSA: hda: add Intel 5 Series / 3400 PCI DID
    ALSA: hda/tegra: set depop delay for tegra
    USB: serial: option: add Quectel RM520N
    USB: serial: option: add Quectel BG95 0x0203 composition
  * USB: core: Fix RST error in hub.c
      drivers/usb/core/hub.c
    wifi: mac80211: Fix UAF in ieee80211_scan_rx()
    usb: dwc3: pci: add support for the Intel Alder Lake-S
    usb: dwc3: pci: add support for the Intel Jasper Lake
    usb: dwc3: pci: add support for the Intel Tiger Lake PCH -H variant
    usb: dwc3: pci: add support for TigerLake Devices
    usb: dwc3: pci: Add Support for Intel Elkhart Lake Devices
    ALSA: hda/sigmatel: Fix unused variable warning for beep power change
    video: fbdev: pxa3xx-gcu: Fix integer overflow in pxa3xx_gcu_write
  * mksysmap: Fix the mismatch of 'L0' symbols in System.map
      scripts/mksysmap
    MIPS: OCTEON: irq: Fix octeon_irq_force_ciu_mapping()
    net: usb: qmi_wwan: add Quectel RM520N
    ALSA: hda/sigmatel: Keep power up while beep is enabled
    rxrpc: Fix local destruction being repeated
    regulator: pfuze100: Fix the global-out-of-bounds access in pfuze100_regulator_probe()
    ASoC: nau8824: Fix semaphore unbalance at error paths
    cifs: don't send down the destination address to sendmsg for a SOCK_STREAM
    mvpp2: no need to check return value of debugfs_create functions
    nvmet: fix a use-after-free
    parisc: ccio-dma: Add missing iounmap in error path in ccio_probe()
    drm/meson: Correct OSD1 global alpha value
    gpio: mpc8xxx: Fix support for IRQ_TYPE_LEVEL_LOW flow_type in mpc85xx
  * of: fdt: fix off-by-one error in unflatten_dt_nodes()
      drivers/of/fdt.c
    Merge 4.19.259 into android-4.19-stable
  * Revert "xhci: Add grace period after xHC start to prevent premature runtime suspend."
      drivers/usb/host/xhci-hub.c
      drivers/usb/host/xhci.c
      drivers/usb/host/xhci.h
  * Revert "USB: core: Prevent nested device-reset calls"
      drivers/usb/core/hub.c
      include/linux/usb.h
    Merge 4.19.258 into android-4.19-stable
  * Revert "mm/rmap: Fix anon_vma->degree ambiguity leading to double-reuse"
      include/linux/rmap.h
      mm/rmap.c
  * Revert "sched/deadline: Fix priority inheritance with multiple scheduling classes"
      include/linux/sched.h
      kernel/sched/core.c
      kernel/sched/deadline.c
  * Revert "kernel/sched: Remove dl_boosted flag comment"
      include/linux/sched.h
    Merge 4.19.257 into android-4.19-stable
  * Revert "fs: check FMODE_LSEEK to control internal pipe splicing"
      fs/splice.c
    Merge 4.19.256 into android-4.19-stable
Linux 4.19.259
  * tracefs: Only clobber mode/uid/gid on remount if asked
      fs/tracefs/inode.c
    net: dp83822: disable rx error interrupt
  * mm: Fix TLB flush for not-first PFNMAP mappings in unmap_region()
      mm/mmap.c
    usb: storage: Add ASUS <0x0b05:0x1932> to IGNORE_UAS
    platform/x86: acer-wmi: Acer Aspire One AOD270/Packard Bell Dot keymap fixes
  * perf/arm_pmu_platform: fix tests for platform_get_irq() failure
      drivers/perf/arm_pmu_platform.c
    Input: iforce - add support for Boeder Force Feedback Wheel
    ieee802154: cc2520: add rc code in cc2520_tx()
    tg3: Disable tg3 device on system reboot to avoid triggering AER
    HID: ishtp-hid-clientHID: ishtp-hid-client: Fix comment typo
    drm/msm/rd: Fix FIFO-full deadlock
Linux 4.19.258
    SUNRPC: use _bh spinlocking on ->transport_lock
    MIPS: loongson32: ls1c: Fix hang during startup
    x86/nospec: Fix i386 RSB stuffing
  * usb: dwc3: qcom: fix use-after-free on runtime-PM wakeup
      drivers/usb/dwc3/dwc3-qcom.c
      drivers/usb/dwc3/host.c
    USB: serial: ch341: fix disabled rx timer on older devices
    USB: serial: ch341: fix lost character on LCR updates
  * usb: dwc3: fix PHY disable sequence
      drivers/usb/dwc3/core.c
    sch_sfb: Also store skb len before calling child enqueue
  * tcp: fix early ETIMEDOUT after spurious non-SACK RTO
      net/ipv4/tcp_input.c
    RDMA/mlx5: Set local port to one when accessing counters
  * ipv6: sr: fix out-of-bounds read when setting HMAC data.
      net/ipv6/seg6.c
    i40e: Fix kernel crash during module removal
  * tipc: fix shift wrapping bug in map_get()
      net/tipc/monitor.c
    sch_sfb: Don't assume the skb is still around after enqueueing to child
  * netfilter: nf_conntrack_irc: Fix forged IP logic
      net/netfilter/nf_conntrack_irc.c
    netfilter: br_netfilter: Drop dst references before setting.
    soc: brcmstb: pm-arm: Fix refcount leak and __iomem leak bugs
    scsi: mpt3sas: Fix use-after-free warning
  * debugfs: add debugfs_lookup_and_remove()
      fs/debugfs/inode.c
      include/linux/debugfs.h
    kprobes: Prohibit probes in gate area
  * ALSA: usb-audio: Fix an out-of-bounds bug in __snd_usb_parse_audio_interface()
      sound/usb/stream.c
    ALSA: aloop: Fix random zeros in capture data when using jiffies timer
    ALSA: emu10k1: Fix out of bounds access in snd_emu10k1_pcm_channel_alloc()
    drm/amdgpu: mmVM_L2_CNTL3 register not initialized correctly
    fbdev: chipsfb: Add missing pci_disable_device() in chipsfb_pci_init()
  * arm64: cacheinfo: Fix incorrect assignment of signed error value to unsigned fw_level
      arch/arm64/kernel/cacheinfo.c
    parisc: Add runtime check to prevent PA2.0 kernels on PA1.x machines
    parisc: ccio-dma: Handle kmalloc failure in ccio_init_resources()
    drm/radeon: add a force flush to delay work when radeon
    drm/amdgpu: Check num_gfx_rings for gfx v9_0 rb setup.
    ALSA: seq: Fix data-race at module auto-loading
    ALSA: seq: oss: Fix data-race for max_midi_devs access
    net: mac802154: Fix a condition in the receive path
    wifi: mac80211: Don't finalize CSA in IBSS mode if state is disconnected
  * usb: gadget: mass_storage: Fix cdrom data transfers on MAC-OS
      drivers/usb/gadget/function/storage_common.c
  * USB: core: Prevent nested device-reset calls
      drivers/usb/core/hub.c
      include/linux/usb.h
    s390: fix nospec table alignments
    s390/hugetlb: fix prepare_hugepage_range() check for 2 GB hugepages
  * usb-storage: Add ignore-residue quirk for NXP PN7462AU
      drivers/usb/storage/unusual_devs.h
    USB: cdc-acm: Add Icom PMR F3400 support (0c26:0020)
    usb: dwc2: fix wrong order of phy_power_on and phy_init
  * usb: typec: altmodes/displayport: correct pin assignment for UFP receptacles
      include/linux/usb/typec_dp.h
    USB: serial: option: add support for Cinterion MV32-WA/WB RmNet mode
    USB: serial: option: add Quectel EM060K modem
    USB: serial: option: add support for OPPO R11 diag port
    USB: serial: cp210x: add Decagon UCA device id
  * xhci: Add grace period after xHC start to prevent premature runtime suspend.
      drivers/usb/host/xhci-hub.c
      drivers/usb/host/xhci.c
      drivers/usb/host/xhci.h
    thunderbolt: Use the actual buffer in tb_async_error()
    hwmon: (gpio-fan) Fix array out of bounds access
    Input: rk805-pwrkey - fix module autoloading
  * clk: core: Fix runtime PM sequence in clk_core_unprepare()
      drivers/clk/clk.c
  * Revert "clk: core: Honor CLK_OPS_PARENT_ENABLE for clk gate ops"
      drivers/clk/clk.c
  * clk: core: Honor CLK_OPS_PARENT_ENABLE for clk gate ops
      drivers/clk/clk.c
    drm/i915/reg: Fix spelling mistake "Unsupport" -> "Unsupported"
  * binder: fix UAF of ref->proc caused by race condition
      drivers/android/binder.c
    USB: serial: ftdi_sio: add Omron CS1W-CIF31 device id
    vt: Clear selection before changing the font
    staging: rtl8712: fix use after free bugs
    serial: fsl_lpuart: RS485 RTS polariy is inverse
    net/smc: Remove redundant refcount increase
    Revert "sch_cake: Return __NET_XMIT_STOLEN when consuming enqueued skb"
  * tcp: annotate data-race around challenge_timestamp
      net/ipv4/tcp_input.c
    sch_cake: Return __NET_XMIT_STOLEN when consuming enqueued skb
    kcm: fix strp_init() order and cleanup
    ethernet: rocker: fix sleep in atomic context bug in neigh_timer_handler
  * Revert "xhci: turn off port power in shutdown"
      drivers/usb/host/xhci-hub.c
      drivers/usb/host/xhci.c
      drivers/usb/host/xhci.h
    wifi: cfg80211: debugfs: fix return type in ht40allow_map_read()
    ieee802154/adf7242: defer destroy_workqueue call
  * platform/x86: pmc_atom: Fix SLP_TYPx bitfield mask
      include/linux/platform_data/x86/pmc_atom.h
    drm/msm/dsi: Fix number of regulators for msm8996_dsi_cfg
    drm/msm/dsi: fix the inconsistent indenting
    net: dp83822: disable false carrier interrupt
    Revert "mm: kmemleak: take a full lowmem check in kmemleak_*_phys()"
  * fs: only do a memory barrier for the first set_buffer_uptodate()
      include/linux/buffer_head.h
    wifi: iwlegacy: 4965: corrected fix for potential off-by-one overflow in il4965_rs_fill_link_cmd()
    efi: capsule-loader: Fix use-after-free in efi_capsule_write
  * driver core: Don't probe devices after bus_type.match() probe deferral
      drivers/base/dd.c
    Merge 08e84df974 ("selftests: timers: clocksource-switch: fix passing errors from child") into android-mainline
    Merge 247f293432 ("drm/msm/mdp5: Fix global state lock backoff") into android-mainline
  * Revert "USB: HCD: Fix URB giveback issue in tasklet function"
      drivers/usb/core/hcd.c
      include/linux/usb/hcd.h
    Merge 9408f5a443 ("USB: HCD: Fix URB giveback issue in tasklet function") into android-mainline
    Merge 4cb392956a ("MIPS: cpuinfo: Fix a warning for CONFIG_CPUMASK_OFFSTACK") into android-mainline
Linux 4.19.257
  * net: neigh: don't call kfree_skb() under spin_lock_irqsave()
      net/core/neighbour.c
    kprobes: don't call disarm_kprobe() for disabled kprobes
  * netfilter: conntrack: NF_CONNTRACK_PROCFS should no longer default to y
      net/netfilter/Kconfig
    s390/hypfs: avoid error message under KVM
  * neigh: fix possible DoS due to net iface start/stop loop
      net/core/neighbour.c
    drm/amd/display: clear optc underflow before turn off odm clock
  * mm/rmap: Fix anon_vma->degree ambiguity leading to double-reuse
      include/linux/rmap.h
      mm/rmap.c
    ftrace: Fix NULL pointer dereference in is_ftrace_trampoline when ftrace is dead
    fbdev: fb_pm2fb: Avoid potential divide by zero error
    HID: hidraw: fix memory leak in hidraw_release()
    media: pvrusb2: fix memory leak in pvr_probe
    HID: steam: Prevent NULL pointer dereference in steam_{recv,send}_report
  * Bluetooth: L2CAP: Fix build errors in some archs
      net/bluetooth/l2cap_core.c
  * kbuild: Fix include path in scripts/Makefile.modpost
      scripts/Makefile.modpost
    x86/bugs: Add "unknown" reporting for MMIO Stale Data
    s390/mm: do not trigger write fault when vma does not allow VM_WRITE
    selftests/bpf: Fix test_align verifier log patterns
    bpf: Fix the off-by-two error in range markings
  * arm64: map FDT as RW for early_init_dt_scan()
      arch/arm64/include/asm/mmu.h
      arch/arm64/kernel/kaslr.c
      arch/arm64/kernel/setup.c
      arch/arm64/mm/mmu.c
  * mm: Force TLB flush for PFNMAP mappings before unlink_file_vma()
      mm/mmap.c
    scsi: storvsc: Remove WQ_MEM_RECLAIM from storvsc_error_wq
    md: call __md_stop_writes in md_stop
  * mm/hugetlb: fix hugetlb not supporting softdirty tracking
      mm/mmap.c
    s390: fix double free of GS and RI CBs on fork() failure
  * asm-generic: sections: refactor memory_intersects
      include/asm-generic/sections.h
  * loop: Check for overflow while configuring loop
      drivers/block/loop.c
    x86/unwind/orc: Unwind ftrace trampolines with correct ORC entry
    btrfs: check if root is readonly while setting security xattr
    ixgbe: stop resetting SYSTIME in ixgbe_ptp_start_cyclecounter
  * net: Fix a data-race around sysctl_somaxconn.
      net/socket.c
  * net: Fix a data-race around netdev_budget_usecs.
      net/core/dev.c
  * net: Fix a data-race around netdev_budget.
      net/core/dev.c
  * net: Fix a data-race around sysctl_net_busy_read.
      net/core/sock.c
  * net: Fix a data-race around sysctl_net_busy_poll.
      include/net/busy_poll.h
  * net: Fix a data-race around sysctl_tstamp_allow_data.
      net/core/skbuff.c
  * ratelimit: Fix data-races in ___ratelimit().
      lib/ratelimit.c
  * net: Fix data-races around netdev_tstamp_prequeue.
      net/core/dev.c
  * net: Fix data-races around weight_p and dev_weight_[rt]x_bias.
      net/core/dev.c
      net/core/sysctl_net_core.c
      net/sched/sch_generic.c
    netfilter: nft_tunnel: restrict it to netdev family
    netfilter: nft_osf: restrict osf to ipv4, ipv6 and inet families
    netfilter: nft_payload: do not truncate csum_offset and csum_type
    netfilter: nft_payload: report ERANGE for too long offset and length
  * netfilter: ebtables: reject blobs that don't provide all entry points
      include/linux/netfilter_bridge/ebtables.h
      net/bridge/netfilter/ebtable_broute.c
      net/bridge/netfilter/ebtables.c
    net: ipvtap - add __init/__exit annotations to module init/exit funcs
  * bonding: 802.3ad: fix no transmission of LACPDUs
      drivers/net/bonding/bond_3ad.c
    rose: check NULL rose_loopback_neigh->loopback
  * af_key: Do not call xfrm_probe_algs in parallel
      net/key/af_key.c
  * xfrm: fix refcount leak in __xfrm_policy_check()
      net/xfrm/xfrm_policy.c
  * kernel/sched: Remove dl_boosted flag comment
      include/linux/sched.h
  * sched/deadline: Fix priority inheritance with multiple scheduling classes
      include/linux/sched.h
      kernel/sched/core.c
      kernel/sched/deadline.c
  * sched/deadline: Fix stale throttling on de-/boosted tasks
      kernel/sched/deadline.c
  * sched/deadline: Unthrottle PI boosted threads while enqueuing
      kernel/sched/deadline.c
    pinctrl: amd: Don't save/restore interrupt status and wake status bits
  * kernel/sys_ni: add compat entry for fadvise64_64
      kernel/sys_ni.c
    parisc: Fix exception handler for fldw and fstw instructions
  * audit: fix potential double free on error path from fsnotify_add_inode_mark
      kernel/audit_fsnotify.c
Linux 4.19.256
    btrfs: raid56: don't trust any cached sector in __raid56_parity_recover()
    btrfs: only write the sectors in the vertical stripe which has data stripes
  * tracing/probes: Have kprobes and uprobes use $COMM too
      kernel/trace/trace_probe.c
    tee: add overflow check in register_shm_helper()
    MIPS: tlbex: Explicitly compare _PAGE_NO_EXEC against 0
    video: fbdev: i740fb: Check the argument of i740_calc_vclk()
    powerpc/64: Init jump labels before parse_early_param()
    smb3: check xattr value length earlier
  * f2fs: fix to avoid use f2fs_bug_on() in f2fs_new_node_page()
      fs/f2fs/node.c
  * ALSA: timer: Use deferred fasync helper
      sound/core/timer.c
  * ALSA: core: Add async signal helpers
      include/sound/core.h
      sound/core/misc.c
  * watchdog: export lockup_detector_reconfigure
      include/linux/nmi.h
    RISC-V: Add fast call path of crash_kexec()
    riscv: mmap with PROT_WRITE but no PROT_READ is invalid
    mips: cavium-octeon: Fix missing of_node_put() in octeon2_usb_clocks_start
    vfio: Clear the caps->buf to NULL after free
    tty: serial: Fix refcount leak bug in ucc_uart.c
  * lib/list_debug.c: Detect uninitialized lists
      lib/list_debug.c
  * ext4: avoid resizing to a partial cluster size
      fs/ext4/resize.c
  * ext4: avoid remove directory when directory is corrupted
      fs/ext4/namei.c
    drivers:md:fix a potential use-after-free bug
    dmaengine: sprd: Cleanup in .remove() after pm_runtime_get_sync() failed
    cxl: Fix a memory leak in an error handling path
    gadgetfs: ep_io - wait until IRQ finishes
    clk: qcom: ipq8074: dont disable gcc_sleep_clk_src
    vboxguest: Do not use devm for irq
    usb: renesas: Fix refcount leak bug
    usb: host: ohci-ppc-of: Fix refcount leak bug
    irqchip/tegra: Fix overflow implicit truncation warnings
  * PCI: Add ACS quirk for Broadcom BCM5750x NICs
      drivers/pci/quirks.c
    drm/meson: Fix refcount bugs in meson_vpu_has_available_connectors()
  * locking/atomic: Make test_and_*_bit() ordered on failure
      include/asm-generic/bitops/atomic.h
  * gcc-plugins: Undefine LATENT_ENTROPY_PLUGIN when plugin disabled for a file
      scripts/Makefile.gcc-plugins
    igb: Add lock to avoid data race
    fec: Fix timer capture timing in `fec_ptp_enable_pps()`
    i40e: Fix to stop tx_timeout recovery if GLOBR fails
    powerpc/pci: Fix get_phb_number() locking
    netfilter: nf_tables: really skip inactive sets when allocating name
    nios2: add force_successful_syscall_return()
    nios2: restarts apply only to the first sigframe we build...
    nios2: fix syscall restart checks
    nios2: traced syscall does need to check the syscall number
    nios2: don't leave NULLs in sys_call_table[]
    nios2: page fault et.al. are *not* restartable syscalls...
    atm: idt77252: fix use-after-free bugs caused by tst_timer
    xen/xenbus: fix return type in xenbus_file_read()
    NTB: ntb_tool: uninitialized heap data in tool_fn_write()
    tools build: Switch to new openssl API for test-libcrypto
    vsock: Set socket state back to SS_UNCONNECTED in vsock_connect_timeout()
    vsock: Fix memory leak in vsock_connect()
    geneve: do not use RT_TOS for IPv6 flowlabel
    ACPI: property: Return type of acpi_add_nondev_subnodes() should be bool
    pinctrl: qcom: msm8916: Allow CAMSS GP clocks to be muxed
    pinctrl: nomadik: Fix refcount leak in nmk_pinctrl_dt_subnode_to_map
    SUNRPC: Reinitialise the backchannel request buffers before reuse
    NFSv4/pnfs: Fix a use-after-free bug in open
    NFSv4.1: RECLAIM_COMPLETE must handle EACCES
    NFSv4: Fix races in the legacy idmapper upcall
    apparmor: Fix memleak in aa_simple_write_to_buffer()
    apparmor: fix reference count leak in aa_pivotroot()
    apparmor: fix overlapping attachment computation
    apparmor: fix aa_label_asxprint return check
    apparmor: Fix failed mount permission check error message
    apparmor: fix absroot causing audited secids to begin with =
    apparmor: fix quiet_denied for file rules
    can: ems_usb: fix clang's -Wunaligned-access warning
  * tracing: Have filter accept "common_cpu" to be consistent
      kernel/trace/trace_events.c
    btrfs: fix lost error handling when looking up extended ref on log replay
    mmc: pxamci: Fix an error handling path in pxamci_probe()
    mmc: pxamci: Fix another error handling path in pxamci_probe()
    ata: libata-eh: Add missing command name
    rds: add missing barrier to release_refill
  * ALSA: info: Fix llseek return value when using callback
      sound/core/info.c
    powerpc/ptdump: Fix display of RW pages on FSL_BOOK3E
    powerpc/mm: Split dump_pagelinuxtables flag_array table
    firmware: arm_scpi: Ensure scpi_info is not assigned if the probe fails
    net_sched: cls_route: disallow handle of 0
    net/9p: Initialize the iounit field during fid creation
  * Bluetooth: L2CAP: Fix l2cap_global_chan_by_psm regression
      net/bluetooth/l2cap_core.c
  * Revert "net: usb: ax88179_178a needs FLAG_SEND_ZLP"
      drivers/net/usb/ax88179_178a.c
  * scsi: sg: Allow waiting for commands to complete on removed device
      drivers/scsi/sg.c
  * tcp: fix over estimation in sk_forced_mem_schedule()
      net/ipv4/tcp_output.c
    KVM: x86: Avoid theoretical NULL pointer dereference in kvm_irq_delivery_to_apic_fast()
    KVM: x86: Check lapic_in_kernel() before attempting to set a SynIC irq
  * KVM: Add infrastructure and macro to mark VM as bugged
      include/linux/kvm_host.h
    btrfs: reject log replay if there is unsupported RO compat flag
    net_sched: cls_route: remove from list when handle is 0
  * ACPI: CPPC: Do not prevent CPPC from working in the future
      include/acpi/cppc_acpi.h
    dm writecache: set a default MAX_WRITEBACK_JOBS
    dm raid: fix address sanitizer warning in raid_status
    dm raid: fix address sanitizer warning in raid_resume
    intel_th: pci: Add Meteor Lake-P support
    intel_th: pci: Add Raptor Lake-S PCH support
    intel_th: pci: Add Raptor Lake-S CPU support
  * ext4: correct the misjudgment in ext4_iget_extra_inode
      fs/ext4/inode.c
  * ext4: correct max_inline_xattr_value_size computing
      fs/ext4/inline.c
  * ext4: fix extent status tree race in writeback error recovery path
      fs/ext4/inode.c
  * ext4: update s_overhead_clusters in the superblock during an on-line resize
      fs/ext4/resize.c
  * ext4: fix use-after-free in ext4_xattr_set_entry
      fs/ext4/xattr.c
  * ext4: make sure ext4_append() always allocates new block
      fs/ext4/namei.c
  * ext4: add EXT4_INODE_HAS_XATTR_SPACE macro in xattr.h
      fs/ext4/xattr.h
  * spmi: trace: fix stack-out-of-bound access in SPMI tracing functions
      include/trace/events/spmi.h
    x86/olpc: fix 'logical not is only applied to the left hand side'
    scsi: zfcp: Fix missing auto port scan and thus missing target ports
    video: fbdev: s3fb: Check the size of screen before memset_io()
    video: fbdev: arkfb: Check the size of screen before memset_io()
    video: fbdev: vt8623fb: Check the size of screen before memset_io()
    tools/thermal: Fix possible path truncations
    video: fbdev: arkfb: Fix a divide-by-zero bug in ark_set_pixclock()
    x86/numa: Use cpumask_available instead of hardcoded NULL check
    scripts/faddr2line: Fix vmlinux detection on arm64
    genelf: Use HAVE_LIBCRYPTO_SUPPORT, not the never defined HAVE_LIBCRYPTO
    powerpc/pci: Fix PHB numbering when using opal-phbid
    kprobes: Forbid probing on trampoline and BPF code areas
    powerpc/cell/axon_msi: Fix refcount leak in setup_msi_msg_address
    powerpc/xive: Fix refcount leak in xive_get_max_prio
    powerpc/spufs: Fix refcount leak in spufs_init_isolated_loader
    powerpc/pci: Prefer PCI domain assignment via DT 'linux,pci-domain' and alias
    powerpc/32: Do not allow selection of e5500 or e6500 CPUs on PPC32
    video: fbdev: sis: fix typos in SiS_GetModeID()
    video: fbdev: amba-clcd: Fix refcount leak bugs
    ASoC: qcom: q6dsp: Fix an off-by-one in q6adm_alloc_copp()
    s390/zcore: fix race when reading from hardware system area
    iommu/arm-smmu: qcom_iommu: Add of_node_put() when breaking out of loop
  * mfd: t7l66xb: Drop platform disable callback
      include/linux/mfd/t7l66xb.h
  * kfifo: fix kfifo_to_user() return type
      include/linux/kfifo.h
    rpmsg: qcom_smd: Fix refcount leak in qcom_smd_parse_edge
    iommu/exynos: Handle failed IOMMU device registration properly
    tty: n_gsm: fix missing corner cases in gsmld_poll()
    tty: n_gsm: fix DM command
    tty: n_gsm: fix wrong T1 retry count handling
    vfio/ccw: Do not change FSM state in subchannel event
    remoteproc: qcom: wcnss: Fix handling of IRQs
    tty: n_gsm: fix race condition in gsmld_write()
    tty: n_gsm: fix packet re-transmission without open control channel
    tty: n_gsm: fix non flow control frames during mux flow off
  * profiling: fix shift too large makes kernel panic
      kernel/profile.c
    serial: 8250_dw: Store LSR into lsr_saved_flags in dw8250_tx_wait_empty()
    ASoC: mediatek: mt8173-rt5650: Fix refcount leak in mt8173_rt5650_dev_probe
    ASoC: codecs: da7210: add check for i2c_add_driver
    ASoC: mt6797-mt6351: Fix refcount leak in mt6797_mt6351_dev_probe
    ASoC: mediatek: mt8173: Fix refcount leak in mt8173_rt5650_rt5676_dev_probe
  * jbd2: fix assertion 'jh->b_frozen_data == NULL' failure when journal aborted
      fs/jbd2/transaction.c
  * ext4: recover csum seed of tmp_inode after migrating to extents
      fs/ext4/migrate.c
    null_blk: fix ida error handling in null_add_dev()
    RDMA/rxe: Fix error unwind in rxe_create_qp()
  * mm/mmap.c: fix missing call to vm_unacct_memory in mmap_region
      mm/mmap.c
    platform/olpc: Fix uninitialized data in debugfs write
    USB: serial: fix tty-port initialized comments
    HID: alps: Declare U1_UNICORN_LEGACY support
    mmc: cavium-thunderx: Add of_node_put() when breaking out of loop
    mmc: cavium-octeon: Add of_node_put() when breaking out of loop
  * gpio: gpiolib-of: Fix refcount bugs in of_mm_gpiochip_add_data()
      drivers/gpio/gpiolib-of.c
    RDMA/hfi1: fix potential memory leak in setup_base_ctxt()
  * usb: gadget: udc: amd5536 depends on HAS_DMA
      drivers/usb/gadget/udc/Kconfig
    scsi: smartpqi: Fix DMA direction for RAID requests
    mmc: sdhci-of-at91: fix set_uhs_signaling rewriting of MC1R
    memstick/ms_block: Fix a memory leak
    memstick/ms_block: Fix some incorrect memory allocation
    mmc: sdhci-of-esdhc: Fix refcount leak in esdhc_signal_voltage_switch
    staging: rtl8192u: Fix sleep in atomic context bug in dm_fsync_timer_callback
    soundwire: bus_type: fix remove and shutdown support
    clk: qcom: ipq8074: set BRANCH_HALT_DELAY flag for UBI clocks
    clk: qcom: ipq8074: fix NSS port frequency tables
    misc: rtsx: Fix an error handling path in rtsx_pci_probe()
    usb: ohci-nxp: Fix refcount leak in ohci_hcd_nxp_probe
    usb: host: Fix refcount leak in ehci_hcd_ppc_of_probe
    fpga: altera-pr-ip: fix unsigned comparison with less than zero
    mtd: st_spi_fsm: Add a clk_disable_unprepare() in .probe()'s error path
    mtd: sm_ftl: Fix deadlock caused by cancel_work_sync in sm_release
    HID: cp2112: prevent a buffer overflow in cp2112_xfer()
    mtd: maps: Fix refcount leak in ap_flash_init
    mtd: maps: Fix refcount leak in of_flash_probe_versatile
    clk: renesas: r9a06g032: Fix UART clkgrp bitsel
    dccp: put dccp_qpolicy_full() and dccp_qpolicy_push() in the same lock
    net: rose: fix netdev reference changes
    netdevsim: Avoid allocation warnings triggered from user space
    net/mlx5e: Fix the value of MLX5E_MAX_RQ_NUM_MTTS
    wifi: libertas: Fix possible refcount leak in if_usb_probe()
    wifi: wil6210: debugfs: fix uninitialized variable use in `wil_write_file_wmi()`
    i2c: mux-gpmux: Add of_node_put() when breaking out of loop
    i2c: cadence: Support PEC for SMBus block read
    Bluetooth: hci_intel: Add check for platform_driver_register
    can: pch_can: pch_can_error(): initialize errc before using it
  * can: error: specify the values of data[5..7] of CAN error frames
      include/uapi/linux/can/error.h
    can: usb_8dev: do not report txerr and rxerr during bus-off
    can: kvaser_usb_leaf: do not report txerr and rxerr during bus-off
    can: kvaser_usb_hydra: do not report txerr and rxerr during bus-off
    can: sun4i_can: do not report txerr and rxerr during bus-off
    can: hi311x: do not report txerr and rxerr during bus-off
    can: sja1000: do not report txerr and rxerr during bus-off
    can: rcar_can: do not report txerr and rxerr during bus-off
    can: pch_can: do not report txerr and rxerr during bus-off
    wifi: p54: add missing parentheses in p54_flush()
    wifi: p54: Fix an error handling path in p54spi_probe()
    selftests: timers: clocksource-switch: fix passing errors from child
    wifi: wil6210: debugfs: fix info leak in wil_write_file_wmi()
    selftests: timers: valid-adjtimex: build fix for newer toolchains
  * fs: check FMODE_LSEEK to control internal pipe splicing
      fs/splice.c
    libbpf: Fix the name of a reused map
  * tcp: make retransmitted SKB fit into the send window
      net/ipv4/tcp_output.c
    mediatek: mt76: mac80211: Fix missing of_node_put() in mt76_led_init()
    media: platform: mtk-mdp: Fix mdp_ipi_comm structure alignment
    crypto: hisilicon - Kunpeng916 crypto driver don't sleep when in softirq
    drm/msm/mdp5: Fix global state lock backoff
    drm: bridge: sii8620: fix possible off-by-one
    drm/mediatek: dpi: Remove output format of YUV
    drm/rockchip: vop: Don't crash for invalid duplicate_state()
    drm/vc4: dsi: Correct DSI divider calculations
    media: hdpvr: fix error value returns in hdpvr_read
    drm: bridge: adv7511: Add check for mipi_dsi_driver_register
    wifi: iwlegacy: 4965: fix potential off-by-one overflow in il4965_rs_fill_link_cmd()
    ath9k: fix use-after-free in ath9k_hif_usb_rx_cb
    media: tw686x: Register the irq at the end of probe
  * i2c: Fix a potential use after free
      drivers/i2c/i2c-core-base.c
    drm/mediatek: Add pull-down MIPI operation in mtk_dsi_poweroff function
    drm/radeon: fix potential buffer overflow in ni_set_mc_special_registers()
    wifi: rtlwifi: fix error codes in rtl_debugfs_set_write_h2c()
    ath10k: do not enforce interrupt trigger type
  * dm: return early from dm_pr_call() if DM device is suspended
      drivers/md/dm.c
    thermal/tools/tmon: Include pthread and time headers in tmon.h
  * nohz/full, sched/rt: Fix missed tick-reenabling bug in dequeue_task_rt()
      kernel/sched/rt.c
  * regulator: of: Fix refcount leak bug in of_get_regulation_constraints()
      drivers/regulator/of_regulator.c
    arm64: dts: qcom: msm8916: Fix typo in pronto remoteproc node
    bus: hisi_lpc: fix missing platform_device_put() in hisi_lpc_acpi_probe()
    ARM: dts: qcom: pm8841: add required thermal-sensor-cells
    cpufreq: zynq: Fix refcount leak in zynq_get_revision
    ARM: OMAP2+: Fix refcount leak in omap3xxx_prm_late_init
    soc: fsl: guts: machine variable might be unset
    ARM: dts: ast2500-evb: fix board compatible
    x86/pmem: Fix platform-device leak in error path
    ARM: bcm: Fix refcount leak in bcm_kona_smc_init
    meson-mx-socinfo: Fix refcount leak in meson_mx_socinfo_init
    ARM: findbit: fix overflowing offset
  * selinux: Add boundary check in put_entry()
      security/selinux/ss/policydb.h
    PM: hibernate: defer device probing when resuming from hibernation
    arm64: dts: qcom: ipq8074: fix NAND node name
    ACPI: LPSS: Fix missing check in register_device_clock()
    ACPI: PM: save NVS memory for Lenovo G40-45
    ACPI: EC: Remove duplicate ThinkPad X1 Carbon 6th entry from DMI quirks
    ARM: OMAP2+: display: Fix refcount leak bug
    ARM: dts: imx6ul: fix qspi node compatible
    ARM: dts: imx6ul: fix lcdif node compatible
    ARM: dts: imx6ul: change operating-points to uint32-matrix
    ARM: dts: imx6ul: add missing properties for sram
    ext2: Add more validity checks for inode counts
  * USB: HCD: Fix URB giveback issue in tasklet function
      drivers/usb/core/hcd.c
      include/linux/usb/hcd.h
  * arm64: fix oops in concurrently setting insn_emulation sysctls
      arch/arm64/kernel/armv8_deprecated.c
  * arm64: Do not forget syscall when starting a new thread.
      arch/arm64/include/asm/processor.h
    netfilter: nf_tables: fix null deref due to zeroed list head
    netfilter: nf_tables: do not allow SET_ID to refer to another table
    MIPS: cpuinfo: Fix a warning for CONFIG_CPUMASK_OFFSTACK
    powerpc/powernv: Avoid crashing if rng is NULL
    powerpc/fsl-pci: Fix Class Code of PCIe Root Port
  * PCI: Add defines for normal and subtractive PCI bridges
      include/linux/pci_ids.h
    ia64, processor: fix -Wincompatible-pointer-types in ia64_get_irr()
    md-raid10: fix KASAN warning
    serial: mvebu-uart: uart2 error bits clearing
  * fuse: limit nsec
      fs/fuse/inode.c
    iio: light: isl29028: Fix the warning in isl29028_remove()
  * bpf: Verifer, adjust_scalar_min_max_vals to always call update_reg_bounds()
      kernel/bpf/verifier.c
    drm/amdgpu: Check BO's requested pinning domains against its preferred_domains
    drm/nouveau: fix another off-by-one in nvbios_addr
    parisc: Fix device names in /proc/iomem
  * ovl: drop WARN_ON() dentry is NULL in ovl_encode_fh()
      fs/overlayfs/export.c
  * usbnet: Fix linkwatch use-after-free on disconnect
      drivers/net/usb/usbnet.c
    fbcon: Fix boundary checks for fbcon=vc:n1-n2 parameters
  * thermal: sysfs: Fix cooling_device_stats_setup() error code path
      drivers/thermal/thermal_sysfs.c
  * fs: Add missing umask strip in vfs_tmpfile
      fs/namei.c
  * vfs: Check the truncate maximum size in inode_newsize_ok()
      fs/attr.c
    tty: vt: initialize unicode screen buffer
    ALSA: hda/cirrus - support for iMac 12,1 model
    ALSA: hda/conexant: Add quirk for LENOVO 20149 Notebook model
    KVM: x86: Set error code to segment selector on LLDT/LTR non-canonical #GP
    KVM: x86: Mark TSS busy during LTR emulation _after_ all fault checks
    KVM: SVM: Don't BUG if userspace injects an interrupt with GIF=0
  * HID: wacom: Don't register pad_input for touch switch
      drivers/hid/wacom_sys.c
      drivers/hid/wacom_wac.c
  * add barriers to buffer_uptodate and set_buffer_uptodate
      include/linux/buffer_head.h
    wifi: mac80211_hwsim: use 32-bit skb cookie
    wifi: mac80211_hwsim: add back erroneously removed cast
    wifi: mac80211_hwsim: fix race condition in pending packet
    ALSA: bcd2000: Fix a UAF bug on the error path of probing
    x86: link vdso and boot with -z noexecstack --no-warn-rwx-segments
  * Makefile: link with -z noexecstack --no-warn-rwx-segments
      Makefile

Bug: 251722136
Change-Id: I935d6876eac3ce17f7ca54c64b4ce94b9331e481
Signed-off-by: Lucas Wei <lucaswei@google.com>
2022-10-26 14:55:01 +08:00
Laurent Dufour
81c95bebde watchdog: export lockup_detector_reconfigure
[ Upstream commit 7c56a8733d0a2a4be2438a7512566e5ce552fccf ]

In some circumstances it may be interesting to reconfigure the watchdog
from inside the kernel.

On PowerPC, this may helpful before and after a LPAR migration (LPM) is
initiated, because it implies some latencies, watchdog, and especially NMI
watchdog is expected to be triggered during this operation. Reconfiguring
the watchdog with a factor, would prevent it to happen too frequently
during LPM.

Rename lockup_detector_reconfigure() as __lockup_detector_reconfigure() and
create a new function lockup_detector_reconfigure() calling
__lockup_detector_reconfigure() under the protection of watchdog_mutex.

Signed-off-by: Laurent Dufour <ldufour@linux.ibm.com>
[mpe: Squash in build fix from Laurent, reported by Sachin]
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/20220713154729.80789-3-ldufour@linux.ibm.com
Signed-off-by: Sasha Levin <sashal@kernel.org>
2022-08-25 11:15:46 +02:00
Olav Haugan
267538c2ae watchdog: Add support for cpu isolation
Open up interface to allow external subsystem to enable and disable hard
lockup detector.

Change-Id: I42b82e7c7869be1df0837c86d3d97aafb4b064bb
Signed-off-by: Olav Haugan <ohaugan@codeaurora.org>
[markivx: Forward port to 4.14 and moved sched.h diff to nmi.h]
Signed-off-by: Vikram Mulukutla <markivx@codeaurora.org>
[satyap@codeaurora.org: Port to 4.19 and fix merge conflicts]
Signed-off-by: Satya Durga Srinivasu Prabhala <satyap@codeaurora.org>
2019-01-02 11:32:56 -08:00
Mathieu Malaterre
cb7c993f48 watchdog/core: Add missing prototypes for weak functions
commit 81bd415c91eb966118d773dddf254aebf3022411 upstream.

The split out of the hard lockup detector exposed two new weak functions,
but no prototypes for them, which triggers the build warning:

  kernel/watchdog.c:109:12: warning: no previous prototype for ‘watchdog_nmi_enable’ [-Wmissing-prototypes]
  kernel/watchdog.c:115:13: warning: no previous prototype for ‘watchdog_nmi_disable’ [-Wmissing-prototypes]

Add the prototypes.

Fixes: 73ce0511c4 ("kernel/watchdog.c: move hardlockup detector to separate file")
Signed-off-by: Mathieu Malaterre <malat@debian.org>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Cc: Babu Moger <babu.moger@oracle.com>
Cc: stable@vger.kernel.org
Link: https://lkml.kernel.org/r/20180606194232.17653-1-malat@debian.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-11-21 09:19:20 +01:00
Peter Zijlstra
aef92a8bed watchdog/softlockup: Fix the SOFTLOCKUP_DETECTOR=n build
I got confused by all the various CONFIG options here about and
conflated CONFIG_LOCKUP_DETECTOR and CONFIG_SOFTLOCKUP_DETECTOR.

This results in a build failure for:

   CONFIG_LOCKUP_DETECTOR=y && CONFIG_SOFTLOCKUP_DETECTOR=n

As reported by Abdul.

Reported-and-tested-by: Abdul Haleem <abdhalee@linux.vnet.ibm.com>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: linux-next <linux-next@vger.kernel.org>
Cc: linuxppc-dev <linuxppc-dev@lists.ozlabs.org>
Cc: mpe <mpe@ellerman.id.au>
Cc: sachinp <sachinp@linux.vnet.ibm.com>
Cc: stephen Rothwell <sfr@canb.auug.org.au>
Fixes: 9cf57731b6 ("watchdog/softlockup: Replace "watchdog/%u" threads with cpu_stop_work")
Link: http://lkml.kernel.org/r/20180710114210.GI2476@hirez.programming.kicks-ass.net
Signed-off-by: Ingo Molnar <mingo@kernel.org>
2018-07-10 17:56:22 +02:00
Peter Zijlstra
9cf57731b6 watchdog/softlockup: Replace "watchdog/%u" threads with cpu_stop_work
Oleg suggested to replace the "watchdog/%u" threads with
cpu_stop_work. That removes one thread per CPU while at the same time
fixes softlockup vs SCHED_DEADLINE.

But more importantly, it does away with the single
smpboot_update_cpumask_percpu_thread() user, which allows
cleanups/shrinkage of the smpboot interface.

Suggested-by: Oleg Nesterov <oleg@redhat.com>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: linux-kernel@vger.kernel.org
Signed-off-by: Ingo Molnar <mingo@kernel.org>
2018-07-03 09:20:43 +02:00
Greg Kroah-Hartman
b24413180f License cleanup: add SPDX GPL-2.0 license identifier to files with no license
Many source files in the tree are missing licensing information, which
makes it harder for compliance tools to determine the correct license.

By default all files without license information are under the default
license of the kernel, which is GPL version 2.

Update the files which contain no license information with the 'GPL-2.0'
SPDX license identifier.  The SPDX identifier is a legally binding
shorthand, which can be used instead of the full boiler plate text.

This patch is based on work done by Thomas Gleixner and Kate Stewart and
Philippe Ombredanne.

How this work was done:

Patches were generated and checked against linux-4.14-rc6 for a subset of
the use cases:
 - file had no licensing information it it.
 - file was a */uapi/* one with no licensing information in it,
 - file was a */uapi/* one with existing licensing information,

Further patches will be generated in subsequent months to fix up cases
where non-standard license headers were used, and references to license
had to be inferred by heuristics based on keywords.

The analysis to determine which SPDX License Identifier to be applied to
a file was done in a spreadsheet of side by side results from of the
output of two independent scanners (ScanCode & Windriver) producing SPDX
tag:value files created by Philippe Ombredanne.  Philippe prepared the
base worksheet, and did an initial spot review of a few 1000 files.

The 4.13 kernel was the starting point of the analysis with 60,537 files
assessed.  Kate Stewart did a file by file comparison of the scanner
results in the spreadsheet to determine which SPDX license identifier(s)
to be applied to the file. She confirmed any determination that was not
immediately clear with lawyers working with the Linux Foundation.

Criteria used to select files for SPDX license identifier tagging was:
 - Files considered eligible had to be source code files.
 - Make and config files were included as candidates if they contained >5
   lines of source
 - File already had some variant of a license header in it (even if <5
   lines).

All documentation files were explicitly excluded.

The following heuristics were used to determine which SPDX license
identifiers to apply.

 - when both scanners couldn't find any license traces, file was
   considered to have no license information in it, and the top level
   COPYING file license applied.

   For non */uapi/* files that summary was:

   SPDX license identifier                            # files
   ---------------------------------------------------|-------
   GPL-2.0                                              11139

   and resulted in the first patch in this series.

   If that file was a */uapi/* path one, it was "GPL-2.0 WITH
   Linux-syscall-note" otherwise it was "GPL-2.0".  Results of that was:

   SPDX license identifier                            # files
   ---------------------------------------------------|-------
   GPL-2.0 WITH Linux-syscall-note                        930

   and resulted in the second patch in this series.

 - if a file had some form of licensing information in it, and was one
   of the */uapi/* ones, it was denoted with the Linux-syscall-note if
   any GPL family license was found in the file or had no licensing in
   it (per prior point).  Results summary:

   SPDX license identifier                            # files
   ---------------------------------------------------|------
   GPL-2.0 WITH Linux-syscall-note                       270
   GPL-2.0+ WITH Linux-syscall-note                      169
   ((GPL-2.0 WITH Linux-syscall-note) OR BSD-2-Clause)    21
   ((GPL-2.0 WITH Linux-syscall-note) OR BSD-3-Clause)    17
   LGPL-2.1+ WITH Linux-syscall-note                      15
   GPL-1.0+ WITH Linux-syscall-note                       14
   ((GPL-2.0+ WITH Linux-syscall-note) OR BSD-3-Clause)    5
   LGPL-2.0+ WITH Linux-syscall-note                       4
   LGPL-2.1 WITH Linux-syscall-note                        3
   ((GPL-2.0 WITH Linux-syscall-note) OR MIT)              3
   ((GPL-2.0 WITH Linux-syscall-note) AND MIT)             1

   and that resulted in the third patch in this series.

 - when the two scanners agreed on the detected license(s), that became
   the concluded license(s).

 - when there was disagreement between the two scanners (one detected a
   license but the other didn't, or they both detected different
   licenses) a manual inspection of the file occurred.

 - In most cases a manual inspection of the information in the file
   resulted in a clear resolution of the license that should apply (and
   which scanner probably needed to revisit its heuristics).

 - When it was not immediately clear, the license identifier was
   confirmed with lawyers working with the Linux Foundation.

 - If there was any question as to the appropriate license identifier,
   the file was flagged for further research and to be revisited later
   in time.

In total, over 70 hours of logged manual review was done on the
spreadsheet to determine the SPDX license identifiers to apply to the
source files by Kate, Philippe, Thomas and, in some cases, confirmation
by lawyers working with the Linux Foundation.

Kate also obtained a third independent scan of the 4.13 code base from
FOSSology, and compared selected files where the other two scanners
disagreed against that SPDX file, to see if there was new insights.  The
Windriver scanner is based on an older version of FOSSology in part, so
they are related.

Thomas did random spot checks in about 500 files from the spreadsheets
for the uapi headers and agreed with SPDX license identifier in the
files he inspected. For the non-uapi files Thomas did random spot checks
in about 15000 files.

In initial set of patches against 4.14-rc6, 3 files were found to have
copy/paste license identifier errors, and have been fixed to reflect the
correct identifier.

Additionally Philippe spent 10 hours this week doing a detailed manual
inspection and review of the 12,461 patched files from the initial patch
version early this week with:
 - a full scancode scan run, collecting the matched texts, detected
   license ids and scores
 - reviewing anything where there was a license detected (about 500+
   files) to ensure that the applied SPDX license was correct
 - reviewing anything where there was no detection but the patch license
   was not GPL-2.0 WITH Linux-syscall-note to ensure that the applied
   SPDX license was correct

This produced a worksheet with 20 files needing minor correction.  This
worksheet was then exported into 3 different .csv files for the
different types of files to be modified.

These .csv files were then reviewed by Greg.  Thomas wrote a script to
parse the csv files and add the proper SPDX tag to the file, in the
format that the file expected.  This script was further refined by Greg
based on the output to detect more types of files automatically and to
distinguish between header and source .c files (which need different
comment types.)  Finally Greg ran the script using the .csv files to
generate the patches.

Reviewed-by: Kate Stewart <kstewart@linuxfoundation.org>
Reviewed-by: Philippe Ombredanne <pombredanne@nexb.com>
Reviewed-by: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-11-02 11:10:55 +01:00
Thomas Gleixner
34ddaa3e5c powerpc/watchdog: Make use of watchdog_nmi_probe()
The rework of the core hotplug code triggers the WARN_ON in start_wd_cpu()
on powerpc because it is called multiple times for the boot CPU.

The first call is via:

  start_wd_on_cpu+0x80/0x2f0
  watchdog_nmi_reconfigure+0x124/0x170
  softlockup_reconfigure_threads+0x110/0x130
  lockup_detector_init+0xbc/0xe0
  kernel_init_freeable+0x18c/0x37c
  kernel_init+0x2c/0x160
  ret_from_kernel_thread+0x5c/0xbc

And then again via the CPU hotplug registration:

  start_wd_on_cpu+0x80/0x2f0
  cpuhp_invoke_callback+0x194/0x620
  cpuhp_thread_fun+0x7c/0x1b0
  smpboot_thread_fn+0x290/0x2a0
  kthread+0x168/0x1b0
  ret_from_kernel_thread+0x5c/0xbc

This can be avoided by setting up the cpu hotplug state with nocalls and
move the initialization to the watchdog_nmi_probe() function. That
initializes the hotplug callbacks without invoking the callback and the
following core initialization function then configures the watchdog for the
online CPUs (in this case CPU0) via softlockup_reconfigure_threads().

Reported-and-tested-by: Michael Ellerman <mpe@ellerman.id.au>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Acked-by: Michael Ellerman <mpe@ellerman.id.au>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Nicholas Piggin <npiggin@gmail.com>
Cc: linuxppc-dev@lists.ozlabs.org
2017-10-04 10:53:54 +02:00
Thomas Gleixner
6b9dc4806b watchdog/core, powerpc: Replace watchdog_nmi_reconfigure()
The recent cleanup of the watchdog code split watchdog_nmi_reconfigure()
into two stages. One to stop the NMI and one to restart it after
reconfiguration. That was done by adding a boolean 'run' argument to the
code, which is functionally correct but not necessarily a piece of art.

Replace it by two explicit functions: watchdog_nmi_stop() and
watchdog_nmi_start().

Fixes: 6592ad2fcc ("watchdog/core, powerpc: Make watchdog_nmi_reconfigure() two stage")
Requested-by: Linus 'Nursing his pet-peeve' Torvalds <torvalds@linuxfoundation.org>
Signed-off-by: Thomas 'Mopping up garbage' Gleixner <tglx@linutronix.de>
Acked-by: Michael Ellerman <mpe@ellerman.id.au>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Don Zickus <dzickus@redhat.com>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Nicholas Piggin <npiggin@gmail.com>
Cc: linuxppc-dev@lists.ozlabs.org
Link: http://lkml.kernel.org/r/alpine.DEB.2.20.1710021957480.2114@nanos
2017-10-04 10:53:53 +02:00
Thomas Gleixner
2a1b8ee4f5 watchdog/hardlockup/perf: Implement CPU enable replacement
watchdog_nmi_enable() is an unparseable mess, Provide a clean perf specific
implementation, which will be used when the existing setup/teardown mess is
replaced.

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Reviewed-by: Don Zickus <dzickus@redhat.com>
Cc: Andrew Morton <akpm@linux-foundation.org>
Cc: Borislav Petkov <bp@alien8.de>
Cc: Chris Metcalf <cmetcalf@mellanox.com>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Nicholas Piggin <npiggin@gmail.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Sebastian Siewior <bigeasy@linutronix.de>
Cc: Ulrich Obergfell <uobergfe@redhat.com>
Link: http://lkml.kernel.org/r/20170912194148.180215498@linutronix.de
Signed-off-by: Ingo Molnar <mingo@kernel.org>
2017-09-14 11:41:08 +02:00
Thomas Gleixner
178b9f7a36 watchdog/hardlockup/perf: Implement init time perf validation
The watchdog tries to create perf events even after it figured out that
perf is not functional or the requested event is not supported.

That's braindead as this can be done once at init time and if not supported
the NMI watchdog can be turned off unconditonally.

Implement the perf hardlockup detector functionality for that. This creates
a new event create function, which will replace the unholy mess of the
existing one in later patches.

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Reviewed-by: Don Zickus <dzickus@redhat.com>
Cc: Andrew Morton <akpm@linux-foundation.org>
Cc: Borislav Petkov <bp@alien8.de>
Cc: Chris Metcalf <cmetcalf@mellanox.com>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Nicholas Piggin <npiggin@gmail.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Sebastian Siewior <bigeasy@linutronix.de>
Cc: Ulrich Obergfell <uobergfe@redhat.com>
Link: http://lkml.kernel.org/r/20170912194148.019090547@linutronix.de
Signed-off-by: Ingo Molnar <mingo@kernel.org>
2017-09-14 11:41:08 +02:00
Thomas Gleixner
6592ad2fcc watchdog/core, powerpc: Make watchdog_nmi_reconfigure() two stage
Both the perf reconfiguration and the powerpc watchdog_nmi_reconfigure()
need to be done in two steps.

     1) Stop all NMIs
     2) Read the new parameters and start NMIs

Right now watchdog_nmi_reconfigure() is a combination of both. To allow a
clean reconfiguration add a 'run' argument and split the functionality in
powerpc.

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Reviewed-by: Don Zickus <dzickus@redhat.com>
Cc: Andrew Morton <akpm@linux-foundation.org>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Borislav Petkov <bp@alien8.de>
Cc: Chris Metcalf <cmetcalf@mellanox.com>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Michael Ellerman <mpe@ellerman.id.au>
Cc: Nicholas Piggin <npiggin@gmail.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Sebastian Siewior <bigeasy@linutronix.de>
Cc: Ulrich Obergfell <uobergfe@redhat.com>
Cc: linuxppc-dev@lists.ozlabs.org
Link: http://lkml.kernel.org/r/20170912194147.862865570@linutronix.de
Signed-off-by: Ingo Molnar <mingo@kernel.org>
2017-09-14 11:41:07 +02:00
Thomas Gleixner
7feeb9cd4f watchdog/sysctl: Clean up sysctl variable name space
Reflect that these variables are user interface related and remove the
whitespace damage in the sysctl table while at it.

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Reviewed-by: Don Zickus <dzickus@redhat.com>
Cc: Andrew Morton <akpm@linux-foundation.org>
Cc: Borislav Petkov <bp@alien8.de>
Cc: Chris Metcalf <cmetcalf@mellanox.com>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Nicholas Piggin <npiggin@gmail.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Sebastian Siewior <bigeasy@linutronix.de>
Cc: Ulrich Obergfell <uobergfe@redhat.com>
Link: http://lkml.kernel.org/r/20170912194147.783210221@linutronix.de
Signed-off-by: Ingo Molnar <mingo@kernel.org>
2017-09-14 11:41:07 +02:00
Thomas Gleixner
51d4052b01 watchdog/sysctl: Get rid of the #ifdeffery
The sysctl of the nmi_watchdog file prevents writes by setting:

    min = max = 0

if none of the users is enabled. That involves ifdeffery and is competely
non obvious.

If none of the facilities is enabeld, then the file can simply be made read
only. Move the ifdeffery into the header and use a constant for file
permissions.

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Reviewed-by: Don Zickus <dzickus@redhat.com>
Cc: Andrew Morton <akpm@linux-foundation.org>
Cc: Borislav Petkov <bp@alien8.de>
Cc: Chris Metcalf <cmetcalf@mellanox.com>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Nicholas Piggin <npiggin@gmail.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Sebastian Siewior <bigeasy@linutronix.de>
Cc: Ulrich Obergfell <uobergfe@redhat.com>
Link: http://lkml.kernel.org/r/20170912194147.706073616@linutronix.de
Signed-off-by: Ingo Molnar <mingo@kernel.org>
2017-09-14 11:41:07 +02:00
Thomas Gleixner
3b371b5936 watchdog/core: Clean up header mess
Having the same #ifdef in various places does not make it more
readable. Collect stuff into one place.

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Reviewed-by: Don Zickus <dzickus@redhat.com>
Cc: Andrew Morton <akpm@linux-foundation.org>
Cc: Borislav Petkov <bp@alien8.de>
Cc: Chris Metcalf <cmetcalf@mellanox.com>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Nicholas Piggin <npiggin@gmail.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Sebastian Siewior <bigeasy@linutronix.de>
Cc: Ulrich Obergfell <uobergfe@redhat.com>
Link: http://lkml.kernel.org/r/20170912194147.627096864@linutronix.de
Signed-off-by: Ingo Molnar <mingo@kernel.org>
2017-09-14 11:41:07 +02:00
Thomas Gleixner
01f0a02701 watchdog/core: Remove the park_in_progress obfuscation
Commit:

  b94f51183b ("kernel/watchdog: prevent false hardlockup on overloaded system")

tries to fix the following issue:

proc_write()
   set_sample_period()    <--- New sample period becoms visible
			  <----- Broken starts
   proc_watchdog_update()
     watchdog_enable_all_cpus()		watchdog_hrtimer_fn()
     update_watchdog_all_cpus()		   restart_timer(sample_period)
        watchdog_park_threads()

					thread->park()
					  disable_nmi()
			  <----- Broken ends

The reason why this is broken is that the update of the watchdog threshold
becomes immediately effective and visible for the hrtimer function which
uses that value to rearm the timer. But the NMI/perf side still uses the
old value up to the point where it is disabled. If the rate has been
lowered then the NMI can run fast enough to 'detect' a hard lockup because
the timer has not fired due to the longer period.

The patch 'fixed' this by adding a variable:

proc_write()
   set_sample_period()
					<----- Broken starts
   proc_watchdog_update()
     watchdog_enable_all_cpus()		watchdog_hrtimer_fn()
     update_watchdog_all_cpus()		   restart_timer(sample_period)
         watchdog_park_threads()
	  park_in_progress = 1
					<----- Broken ends
				        nmi_watchdog()
					  if (park_in_progress)
					     return;

The only effect of this variable was to make the window where the breakage
can hit small enough that it was not longer observable in testing. From a
correctness point of view it is a pointless bandaid which merily papers
over the root cause: the unsychronized update of the variable.

Looking deeper into the related code pathes unearthed similar problems in
the watchdog_start()/stop() functions.

 watchdog_start()
	perf_nmi_event_start()
	hrtimer_start()

 watchdog_stop()
	hrtimer_cancel()
	perf_nmi_event_stop()

In both cases the call order is wrong because if the tasks gets preempted
or the VM gets scheduled out long enough after the first call, then there is
a chance that the next NMI will see a stale hrtimer interrupt count and
trigger a false positive hard lockup splat.

Get rid of park_in_progress so the code can be gradually deobfuscated and
pruned from several layers of duct tape papering over the root cause,
which has been either ignored or not understood at all.

Once this is removed the underlying problem will be fixed by rewriting the
proc interface to do a proper synchronized update.

Address the start/stop() ordering problem as well by reverting the call
order, so this part is at least correct now.

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Reviewed-by: Don Zickus <dzickus@redhat.com>
Cc: Andrew Morton <akpm@linux-foundation.org>
Cc: Borislav Petkov <bp@alien8.de>
Cc: Chris Metcalf <cmetcalf@mellanox.com>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Nicholas Piggin <npiggin@gmail.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Sebastian Siewior <bigeasy@linutronix.de>
Cc: Ulrich Obergfell <uobergfe@redhat.com>
Link: http://lkml.kernel.org/r/alpine.DEB.2.20.1709052038270.2393@nanos
Signed-off-by: Ingo Molnar <mingo@kernel.org>
2017-09-14 11:41:05 +02:00
Thomas Gleixner
941154bd69 watchdog/hardlockup/perf: Prevent CPU hotplug deadlock
The following deadlock is possible in the watchdog hotplug code:

  cpus_write_lock()
    ...
      takedown_cpu()
        smpboot_park_threads()
          smpboot_park_thread()
            kthread_park()
              ->park() := watchdog_disable()
                watchdog_nmi_disable()
                  perf_event_release_kernel();
                    put_event()
                      _free_event()
                        ->destroy() := hw_perf_event_destroy()
                          x86_release_hardware()
                            release_ds_buffers()
                              get_online_cpus()

when a per cpu watchdog perf event is destroyed which drops the last
reference to the PMU hardware. The cleanup code there invokes
get_online_cpus() which instantly deadlocks because the hotplug percpu
rwsem is write locked.

To solve this add a deferring mechanism:

  cpus_write_lock()
			   kthread_park()
			    watchdog_nmi_disable(deferred)
			      perf_event_disable(event);
			      move_event_to_deferred(event);
			   ....
  cpus_write_unlock()
  cleaup_deferred_events()
    perf_event_release_kernel()

This is still properly serialized against concurrent hotplug via the
cpu_add_remove_lock, which is held by the task which initiated the hotplug
event.

This is also used to handle event destruction when the watchdog threads are
parked via other mechanisms than CPU hotplug.

Analyzed-by: Peter Zijlstra <peterz@infradead.org>

Reported-by: Borislav Petkov <bp@alien8.de>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Reviewed-by: Don Zickus <dzickus@redhat.com>
Cc: Andrew Morton <akpm@linux-foundation.org>
Cc: Chris Metcalf <cmetcalf@mellanox.com>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Nicholas Piggin <npiggin@gmail.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Sebastian Siewior <bigeasy@linutronix.de>
Cc: Ulrich Obergfell <uobergfe@redhat.com>
Link: http://lkml.kernel.org/r/20170912194146.884469246@linutronix.de
Signed-off-by: Ingo Molnar <mingo@kernel.org>
2017-09-14 11:41:05 +02:00
Thomas Gleixner
5490125d77 watchdog/core: Remove broken suspend/resume interfaces
This interface has several issues:

 - It's causing recursive locking of the hotplug lock.

 - It's complete overkill to teardown all threads and then recreate them

The same can be achieved with the simple hardlockup_detector_perf_stop /
restart() interfaces. The abuse from the busy looping poweroff() loop of
PARISC has been solved as well.

Remove the cruft.

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Reviewed-by: Don Zickus <dzickus@redhat.com>
Cc: Andrew Morton <akpm@linux-foundation.org>
Cc: Borislav Petkov <bp@alien8.de>
Cc: Chris Metcalf <cmetcalf@mellanox.com>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Nicholas Piggin <npiggin@gmail.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Sebastian Siewior <bigeasy@linutronix.de>
Cc: Ulrich Obergfell <uobergfe@redhat.com>
Link: http://lkml.kernel.org/r/20170912194146.487537732@linutronix.de
Signed-off-by: Ingo Molnar <mingo@kernel.org>
2017-09-14 11:41:04 +02:00
Thomas Gleixner
6554fd8cf0 watchdog/core: Provide interface to stop from poweroff()
PARISC has a a busy looping power off routine. If the watchdog is enabled
the watchdog timer will still fire, but the thread is not running, which
causes the softlockup watchdog to trigger.

Provide a interface which allows to turn the watchdog off.

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Reviewed-by: Don Zickus <dzickus@redhat.com>
Cc: Andrew Morton <akpm@linux-foundation.org>
Cc: Borislav Petkov <bp@alien8.de>
Cc: Chris Metcalf <cmetcalf@mellanox.com>
Cc: Helge Deller <deller@gmx.de>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Nicholas Piggin <npiggin@gmail.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Sebastian Siewior <bigeasy@linutronix.de>
Cc: Ulrich Obergfell <uobergfe@redhat.com>
Cc: linux-parisc@vger.kernel.org
Link: http://lkml.kernel.org/r/20170912194146.327343752@linutronix.de
Signed-off-by: Ingo Molnar <mingo@kernel.org>
2017-09-14 11:41:03 +02:00
Peter Zijlstra
d0b6e0a8ef watchdog/hardlockup: Provide interface to stop/restart perf events
Provide an interface to stop and restart perf NMI watchdog events on all
CPUs. This is only usable during init and especially for handling the perf
HT bug on Intel machines. It's safe to use it this way as nothing can
start/stop the NMI watchdog in parallel.

Signed-off-by: Peter Zijlstra <peterz@infradead.org>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Reviewed-by: Don Zickus <dzickus@redhat.com>
Cc: Andrew Morton <akpm@linux-foundation.org>
Cc: Borislav Petkov <bp@alien8.de>
Cc: Chris Metcalf <cmetcalf@mellanox.com>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Nicholas Piggin <npiggin@gmail.com>
Cc: Sebastian Siewior <bigeasy@linutronix.de>
Cc: Ulrich Obergfell <uobergfe@redhat.com>
Link: http://lkml.kernel.org/r/20170912194146.167649596@linutronix.de
Signed-off-by: Ingo Molnar <mingo@kernel.org>
2017-09-14 11:41:03 +02:00
Thomas Gleixner
7edaeb6841 kernel/watchdog: Prevent false positives with turbo modes
The hardlockup detector on x86 uses a performance counter based on unhalted
CPU cycles and a periodic hrtimer. The hrtimer period is about 2/5 of the
performance counter period, so the hrtimer should fire 2-3 times before the
performance counter NMI fires. The NMI code checks whether the hrtimer
fired since the last invocation. If not, it assumess a hard lockup.

The calculation of those periods is based on the nominal CPU
frequency. Turbo modes increase the CPU clock frequency and therefore
shorten the period of the perf/NMI watchdog. With extreme Turbo-modes (3x
nominal frequency) the perf/NMI period is shorter than the hrtimer period
which leads to false positives.

A simple fix would be to shorten the hrtimer period, but that comes with
the side effect of more frequent hrtimer and softlockup thread wakeups,
which is not desired.

Implement a low pass filter, which checks the perf/NMI period against
kernel time. If the perf/NMI fires before 4/5 of the watchdog period has
elapsed then the event is ignored and postponed to the next perf/NMI.

That solves the problem and avoids the overhead of shorter hrtimer periods
and more frequent softlockup thread wakeups.

Fixes: 58687acba5 ("lockup_detector: Combine nmi_watchdog and softlockup detector")
Reported-and-tested-by: Kan Liang <Kan.liang@intel.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Cc: dzickus@redhat.com
Cc: prarit@redhat.com
Cc: ak@linux.intel.com
Cc: babu.moger@oracle.com
Cc: peterz@infradead.org
Cc: eranian@google.com
Cc: acme@redhat.com
Cc: stable@vger.kernel.org
Cc: atomlin@redhat.com
Cc: akpm@linux-foundation.org
Cc: torvalds@linux-foundation.org
Link: http://lkml.kernel.org/r/alpine.DEB.2.20.1708150931310.1886@nanos
2017-08-18 12:35:02 +02:00
Nicholas Piggin
05a4a95279 kernel/watchdog: split up config options
Split SOFTLOCKUP_DETECTOR from LOCKUP_DETECTOR, and split
HARDLOCKUP_DETECTOR_PERF from HARDLOCKUP_DETECTOR.

LOCKUP_DETECTOR implies the general boot, sysctl, and programming
interfaces for the lockup detectors.

An architecture that wants to use a hard lockup detector must define
HAVE_HARDLOCKUP_DETECTOR_PERF or HAVE_HARDLOCKUP_DETECTOR_ARCH.

Alternatively an arch can define HAVE_NMI_WATCHDOG, which provides the
minimum arch_touch_nmi_watchdog, and it otherwise does its own thing and
does not implement the LOCKUP_DETECTOR interfaces.

sparc is unusual in that it has started to implement some of the
interfaces, but not fully yet.  It should probably be converted to a full
HAVE_HARDLOCKUP_DETECTOR_ARCH.

[npiggin@gmail.com: fix]
  Link: http://lkml.kernel.org/r/20170617223522.66c0ad88@roar.ozlabs.ibm.com
Link: http://lkml.kernel.org/r/20170616065715.18390-4-npiggin@gmail.com
Signed-off-by: Nicholas Piggin <npiggin@gmail.com>
Reviewed-by: Don Zickus <dzickus@redhat.com>
Reviewed-by: Babu Moger <babu.moger@oracle.com>
Tested-by: Babu Moger <babu.moger@oracle.com>	[sparc]
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Michael Ellerman <mpe@ellerman.id.au>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2017-07-12 16:26:02 -07:00
Nicholas Piggin
f2e0cff85e kernel/watchdog: introduce arch_touch_nmi_watchdog()
For architectures that define HAVE_NMI_WATCHDOG, instead of having them
provide the complete touch_nmi_watchdog() function, just have them
provide arch_touch_nmi_watchdog().

This gives the generic code more flexibility in implementing this
function, and arch implementations don't miss out on touching the
softlockup watchdog or other generic details.

Link: http://lkml.kernel.org/r/20170616065715.18390-3-npiggin@gmail.com
Signed-off-by: Nicholas Piggin <npiggin@gmail.com>
Reviewed-by: Don Zickus <dzickus@redhat.com>
Reviewed-by: Babu Moger <babu.moger@oracle.com>
Tested-by: Babu Moger <babu.moger@oracle.com>	[sparc]
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Michael Ellerman <mpe@ellerman.id.au>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2017-07-12 16:26:02 -07:00
Nicholas Piggin
24bb44612c kernel/watchdog: remove unused declaration
Patch series "Improve watchdog config for arch watchdogs", v4.

A series to make the hardlockup watchdog more easily replaceable by arch
code.  The last patch provides some justification for why we want to do
this (existing sparc watchdog is another that could benefit).

This patch (of 5):

Remove unused declaration.

Link: http://lkml.kernel.org/r/20170616065715.18390-2-npiggin@gmail.com
Signed-off-by: Nicholas Piggin <npiggin@gmail.com>
Reviewed-by: Don Zickus <dzickus@redhat.com>
Reviewed-by: Babu Moger <babu.moger@oracle.com>
Tested-by: Babu Moger <babu.moger@oracle.com>	[sparc]
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Michael Ellerman <mpe@ellerman.id.au>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2017-07-12 16:26:02 -07:00
Ingo Molnar
d151b27d3f sched/headers: Move softlockup detector watchdog methods to <linux/nmi.h>
These methods don't belong into <linux/sched.h>, they are neither directly
related to task_struct or are scheduler functionality.

Put them next to the other watchdog methods in <linux/nmi.h>.

( Arguably that header's name is a misnomer, and this patch makes it
  more so - but it should be renamed in another patch. )

Acked-by: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Mike Galbraith <efault@gmx.de>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: linux-kernel@vger.kernel.org
Signed-off-by: Ingo Molnar <mingo@kernel.org>
2017-03-03 01:43:38 +01:00
Don Zickus
b94f51183b kernel/watchdog: prevent false hardlockup on overloaded system
On an overloaded system, it is possible that a change in the watchdog
threshold can be delayed long enough to trigger a false positive.

This can easily be achieved by having a cpu spinning indefinitely on a
task, while another cpu updates watchdog threshold.

What happens is while trying to park the watchdog threads, the hrtimers
on the other cpus trigger and reprogram themselves with the new slower
watchdog threshold.  Meanwhile, the nmi watchdog is still programmed
with the old faster threshold.

Because the one cpu is blocked, it prevents the thread parking on the
other cpus from completing, which is needed to shutdown the nmi watchdog
and reprogram it correctly.  As a result, a false positive from the nmi
watchdog is reported.

Fix this by setting a park_in_progress flag to block all lockups until
the parking is complete.

Fix provided by Ulrich Obergfell.

[akpm@linux-foundation.org: s/park_in_progress/watchdog_park_in_progress/]
Link: http://lkml.kernel.org/r/1481041033-192236-1-git-send-email-dzickus@redhat.com
Signed-off-by: Don Zickus <dzickus@redhat.com>
Reviewed-by: Aaron Tomlin <atomlin@redhat.com>
Cc: Ulrich Obergfell <uobergfe@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2017-01-24 16:26:14 -08:00
Babu Moger
249e52e355 kernel/watchdog.c: move shared definitions to nmi.h
Patch series "Clean up watchdog handlers", v2.

This is an attempt to cleanup watchdog handlers.  Right now,
kernel/watchdog.c implements both softlockup and hardlockup detectors.
Softlockup code is generic.  Hardlockup code is arch specific.  Some
architectures don't use hardlockup detectors.  They use their own
watchdog detectors.  To make both these combination work, we have
numerous #ifdefs in kernel/watchdog.c.

We are trying here to make these handlers independent of each other.
Also provide an interface for architectures to implement their own
handlers.  watchdog_nmi_enable and watchdog_nmi_disable will be defined
as weak such that architectures can override its definitions.

Thanks to Don Zickus for his suggestions.
Here are our previous discussions
http://www.spinics.net/lists/sparclinux/msg16543.html
http://www.spinics.net/lists/sparclinux/msg16441.html

This patch (of 3):

Move shared macros and definitions to nmi.h so that watchdog.c, new file
watchdog_hld.c or any other architecture specific handler can use those
definitions.

Link: http://lkml.kernel.org/r/1478034826-43888-2-git-send-email-babu.moger@oracle.com
Signed-off-by: Babu Moger <babu.moger@oracle.com>
Acked-by: Don Zickus <dzickus@redhat.com>
Cc: Ingo Molnar <mingo@kernel.org>
Cc: Jiri Kosina <jkosina@suse.cz>
Cc: Andi Kleen <andi@firstfloor.org>
Cc: Yaowei Bai <baiyaowei@cmss.chinamobile.com>
Cc: Aaron Tomlin <atomlin@redhat.com>
Cc: Ulrich Obergfell <uobergfe@redhat.com>
Cc: Tejun Heo <tj@kernel.org>
Cc: Hidehiro Kawai <hidehiro.kawai.ez@hitachi.com>
Cc: Josh Hunt <johunt@akamai.com>
Cc: "David S. Miller" <davem@davemloft.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2016-12-14 16:04:08 -08:00
Chris Metcalf
9a01c3ed5c nmi_backtrace: add more trigger_*_cpu_backtrace() methods
Patch series "improvements to the nmi_backtrace code" v9.

This patch series modifies the trigger_xxx_backtrace() NMI-based remote
backtracing code to make it more flexible, and makes a few small
improvements along the way.

The motivation comes from the task isolation code, where there are
scenarios where we want to be able to diagnose a case where some cpu is
about to interrupt a task-isolated cpu.  It can be helpful to see both
where the interrupting cpu is, and also an approximation of where the
cpu that is being interrupted is.  The nmi_backtrace framework allows us
to discover the stack of the interrupted cpu.

I've tested that the change works as desired on tile, and build-tested
x86, arm, mips, and sparc64.  For x86 I confirmed that the generic
cpuidle stuff as well as the architecture-specific routines are in the
new cpuidle section.  For arm, mips, and sparc I just build-tested it
and made sure the generic cpuidle routines were in the new cpuidle
section, but I didn't attempt to figure out which the platform-specific
idle routines might be.  That might be more usefully done by someone
with platform experience in follow-up patches.

This patch (of 4):

Currently you can only request a backtrace of either all cpus, or all
cpus but yourself.  It can also be helpful to request a remote backtrace
of a single cpu, and since we want that, the logical extension is to
support a cpumask as the underlying primitive.

This change modifies the existing lib/nmi_backtrace.c code to take a
cpumask as its basic primitive, and modifies the linux/nmi.h code to use
the new "cpumask" method instead.

The existing clients of nmi_backtrace (arm and x86) are converted to
using the new cpumask approach in this change.

The other users of the backtracing API (sparc64 and mips) are converted
to use the cpumask approach rather than the all/allbutself approach.
The mips code ignored the "include_self" boolean but with this change it
will now also dump a local backtrace if requested.

Link: http://lkml.kernel.org/r/1472487169-14923-2-git-send-email-cmetcalf@mellanox.com
Signed-off-by: Chris Metcalf <cmetcalf@mellanox.com>
Tested-by: Daniel Thompson <daniel.thompson@linaro.org> [arm]
Reviewed-by: Aaron Tomlin <atomlin@redhat.com>
Reviewed-by: Petr Mladek <pmladek@suse.com>
Cc: "Rafael J. Wysocki" <rjw@rjwysocki.net>
Cc: Russell King <linux@arm.linux.org.uk>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Ingo Molnar <mingo@elte.hu>
Cc: Ralf Baechle <ralf@linux-mips.org>
Cc: David Miller <davem@davemloft.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2016-10-07 18:46:30 -07:00
Yaowei Bai
f09e3f4fe4 x86/apic: Remove declaration of unused hw_nmi_is_cpu_stuck
Commit 10f9014912 ("x86: Cleanup hw_nmi.c cruft") removed unused
code in the hw_nmi.c file because of the redesign of the hardlockup
watchdog but left declaration of hw_nmi_is_cpu_stuck in linux/nmi.h,
so remvoe it.

Signed-off-by: Yaowei Bai <baiyaowei@cmss.chinamobile.com>
Link: http://lkml.kernel.org/r/1458697210-3027-1-git-send-email-baiyaowei@cmss.chinamobile.com
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
2016-03-23 12:34:17 +01:00
Jiri Kosina
55537871ef kernel/watchdog.c: perform all-CPU backtrace in case of hard lockup
In many cases of hardlockup reports, it's actually not possible to know
why it triggered, because the CPU that got stuck is usually waiting on a
resource (with IRQs disabled) in posession of some other CPU is holding.

IOW, we are often looking at the stacktrace of the victim and not the
actual offender.

Introduce sysctl / cmdline parameter that makes it possible to have
hardlockup detector perform all-CPU backtrace.

Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Reviewed-by: Aaron Tomlin <atomlin@redhat.com>
Cc: Ulrich Obergfell <uobergfe@redhat.com>
Acked-by: Don Zickus <dzickus@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2015-11-05 19:34:48 -08:00
Linus Torvalds
6f0a2fc1fe Merge branch 'nmi' of git://ftp.arm.linux.org.uk/~rmk/linux-arm
Pull NMI backtrace update from Russell King:
 "These changes convert the x86 NMI handling to be a library
  implementation which other architectures can make use of.  Thomas
  Gleixner has reviewed and tested these changes, and wishes me to send
  these rather than taking them through the tip tree.

  The final patch in the set adds an initial implementation using this
  infrastructure to ARM, even though it doesn't send the IPI at "NMI"
  level.  Patches are in progress to add the ARM equivalent of NMI, but
  we still need the IRQ-level fallback for systems where the "NMI" isn't
  available due to secure firmware denying access to it"

* 'nmi' of git://ftp.arm.linux.org.uk/~rmk/linux-arm:
  ARM: add basic support for on-demand backtrace of other CPUs
  nmi: x86: convert to generic nmi handler
  nmi: create generic NMI backtrace implementation
2015-09-08 12:28:10 -07:00
Ulrich Obergfell
ec6a90661a watchdog: rename watchdog_suspend() and watchdog_resume()
Rename watchdog_suspend() to lockup_detector_suspend() and
watchdog_resume() to lockup_detector_resume() to avoid confusion with the
watchdog subsystem and to be consistent with the existing name
lockup_detector_init().

Also provide comment blocks to explain the watchdog_running and
watchdog_suspended variables and their relationship.

Signed-off-by: Ulrich Obergfell <uobergfe@redhat.com>
Reviewed-by: Aaron Tomlin <atomlin@redhat.com>
Cc: Guenter Roeck <linux@roeck-us.net>
Cc: Don Zickus <dzickus@redhat.com>
Cc: Ulrich Obergfell <uobergfe@redhat.com>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Michal Hocko <mhocko@suse.cz>
Cc: Stephane Eranian <eranian@google.com>
Cc: Chris Metcalf <cmetcalf@ezchip.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Ingo Molnar <mingo@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2015-09-04 16:54:41 -07:00
Ulrich Obergfell
999bbe49ea watchdog: use suspend/resume interface in fixup_ht_bug()
Remove watchdog_nmi_disable_all() and watchdog_nmi_enable_all() since
these functions are no longer needed.  If a subsystem has a need to
deactivate the watchdog temporarily, it should utilize the
watchdog_suspend() and watchdog_resume() functions.

[akpm@linux-foundation.org: fix build with CONFIG_LOCKUP_DETECTOR=m]
Signed-off-by: Ulrich Obergfell <uobergfe@redhat.com>
Reviewed-by: Aaron Tomlin <atomlin@redhat.com>
Cc: Guenter Roeck <linux@roeck-us.net>
Cc: Don Zickus <dzickus@redhat.com>
Cc: Ulrich Obergfell <uobergfe@redhat.com>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Michal Hocko <mhocko@suse.cz>
Cc: Stephane Eranian <eranian@google.com>
Cc: Chris Metcalf <cmetcalf@ezchip.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Ingo Molnar <mingo@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2015-09-04 16:54:41 -07:00
Ulrich Obergfell
8c073d27d7 watchdog: introduce watchdog_suspend() and watchdog_resume()
This interface can be utilized to deactivate the hard and soft lockup
detector temporarily.  Callers are expected to minimize the duration of
deactivation.  Multiple deactivations are allowed to occur in parallel but
should be rare in practice.

[akpm@linux-foundation.org: remove unneeded static initialization]
Signed-off-by: Ulrich Obergfell <uobergfe@redhat.com>
Reviewed-by: Aaron Tomlin <atomlin@redhat.com>
Cc: Guenter Roeck <linux@roeck-us.net>
Cc: Don Zickus <dzickus@redhat.com>
Cc: Ulrich Obergfell <uobergfe@redhat.com>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Michal Hocko <mhocko@suse.cz>
Cc: Stephane Eranian <eranian@google.com>
Cc: Chris Metcalf <cmetcalf@ezchip.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Ingo Molnar <mingo@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2015-09-04 16:54:41 -07:00
Guenter Roeck
aacfbe6a97 kernel/watchdog: move NMI function header declarations from watchdog.h to nmi.h
The kernel's NMI watchdog has nothing to do with the watchdog subsystem.
Its header declarations should be in linux/nmi.h, not linux/watchdog.h.

The code provided two sets of dummy functions if HARDLOCKUP_DETECTOR is
not configured, one in the include file and one in kernel/watchdog.c.
Remove the dummy functions from kernel/watchdog.c and use those from the
include file.

Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Cc: Stephane Eranian <eranian@google.com>
Cc: Peter Zijlstra (Intel) <peterz@infradead.org>
Cc: Ingo Molnar <mingo@kernel.org>
Cc: Don Zickus <dzickus@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2015-09-04 16:54:41 -07:00
Russell King
b2c0b2cbb2 nmi: create generic NMI backtrace implementation
x86s NMI backtrace implementation (for arch_trigger_all_cpu_backtrace())
is fairly generic in nature - the only architecture specific bits are
the act of raising the NMI to other CPUs, and reporting the status of
the NMI handler.

These are fairly simple to factor out, and produce a generic
implementation which can be shared between ARM and x86.

Reviewed-by: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2015-07-17 12:23:17 +01:00
Chris Metcalf
fe4ba3c343 watchdog: add watchdog_cpumask sysctl to assist nohz
Change the default behavior of watchdog so it only runs on the
housekeeping cores when nohz_full is enabled at build and boot time.
Allow modifying the set of cores the watchdog is currently running on
with a new kernel.watchdog_cpumask sysctl.

In the current system, the watchdog subsystem runs a periodic timer that
schedules the watchdog kthread to run.  However, nohz_full cores are
designed to allow userspace application code running on those cores to
have 100% access to the CPU.  So the watchdog system prevents the
nohz_full application code from being able to run the way it wants to,
thus the motivation to suppress the watchdog on nohz_full cores, which
this patchset provides by default.

However, if we disable the watchdog globally, then the housekeeping
cores can't benefit from the watchdog functionality.  So we allow
disabling it only on some cores.  See Documentation/lockup-watchdogs.txt
for more information.

[jhubbard@nvidia.com: fix a watchdog crash in some configurations]
Signed-off-by: Chris Metcalf <cmetcalf@ezchip.com>
Acked-by: Don Zickus <dzickus@redhat.com>
Cc: Ingo Molnar <mingo@kernel.org>
Cc: Ulrich Obergfell <uobergfe@redhat.com>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Signed-off-by: John Hubbard <jhubbard@nvidia.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2015-06-24 17:49:40 -07:00
Ulrich Obergfell
692297d8f9 watchdog: introduce the hardlockup_detector_disable() function
Have kvm_guest_init() use hardlockup_detector_disable() instead of
watchdog_enable_hardlockup_detector(false).

Remove the watchdog_hardlockup_detector_is_enabled() and the
watchdog_enable_hardlockup_detector() function which are no longer needed.

Signed-off-by: Ulrich Obergfell <uobergfe@redhat.com>
Signed-off-by: Don Zickus <dzickus@redhat.com>
Cc: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2015-04-14 16:48:59 -07:00
Ulrich Obergfell
195daf665a watchdog: enable the new user interface of the watchdog mechanism
With the current user interface of the watchdog mechanism it is only
possible to disable or enable both lockup detectors at the same time.
This series introduces new kernel parameters and changes the semantics of
some existing kernel parameters, so that the hard lockup detector and the
soft lockup detector can be disabled or enabled individually.  With this
series applied, the user interface is as follows.

- parameters in /proc/sys/kernel

  . soft_watchdog
    This is a new parameter to control and examine the run state of
    the soft lockup detector.

  . nmi_watchdog
    The semantics of this parameter have changed. It can now be used
    to control and examine the run state of the hard lockup detector.

  . watchdog
    This parameter is still available to control the run state of both
    lockup detectors at the same time. If this parameter is examined,
    it shows the logical OR of soft_watchdog and nmi_watchdog.

  . watchdog_thresh
    The semantics of this parameter are not affected by the patch.

- kernel command line parameters

  . nosoftlockup
    The semantics of this parameter have changed. It can now be used
    to disable the soft lockup detector at boot time.

  . nmi_watchdog=0 or nmi_watchdog=1
    Disable or enable the hard lockup detector at boot time. The patch
    introduces '=1' as a new option.

  . nowatchdog
    The semantics of this parameter are not affected by the patch. It
    is still available to disable both lockup detectors at boot time.

Also, remove the proc_dowatchdog() function which is no longer needed.

[dzickus@redhat.com: wrote changelog]
[dzickus@redhat.com: update documentation for kernel params and sysctl]
Signed-off-by: Ulrich Obergfell <uobergfe@redhat.com>
Signed-off-by: Don Zickus <dzickus@redhat.com>
Cc: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2015-04-14 16:48:59 -07:00
Ulrich Obergfell
83a80a3907 watchdog: introduce separate handlers for parameters in /proc/sys/kernel
Separate handlers for each watchdog parameter in /proc/sys/kernel replace
the proc_dowatchdog() function.  Three of those handlers merely call
proc_watchdog_common() with one different argument.

Signed-off-by: Ulrich Obergfell <uobergfe@redhat.com>
Signed-off-by: Don Zickus <dzickus@redhat.com>
Cc: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2015-04-14 16:48:59 -07:00
Ulrich Obergfell
84d56e66b9 watchdog: new definitions and variables, initialization
The hardlockup and softockup had always been tied together.  Due to the
request of KVM folks, they had a need to have one enabled but not the
other.  Internally rework the code to split things apart more cleanly.

There is a bunch of churn here, but the end result should be code that
should be easier to maintain and fix without knowing the internals of what
is going on.

This patch (of 9):

Introduce new definitions and variables to separate the user interface in
/proc/sys/kernel from the internal run state of the lockup detectors.  The
internal run state is represented by two bits in a new variable that is
named 'watchdog_enabled'.  This helps simplify the code, for example:

- In order to check if any of the two lockup detectors is enabled,
  it is sufficient to check if 'watchdog_enabled' is not zero.

- In order to enable/disable one or both lockup detectors,
  it is sufficient to set/clear one or both bits in 'watchdog_enabled'.

- Concurrent updates of 'watchdog_enabled' need not be synchronized via
  a spinlock or a mutex. Updates can either be atomic or concurrency can
  be detected by using 'cmpxchg'.

Signed-off-by: Ulrich Obergfell <uobergfe@redhat.com>
Signed-off-by: Don Zickus <dzickus@redhat.com>
Cc: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2015-04-14 16:48:58 -07:00
Ulrich Obergfell
6e7458a6f0 kernel/watchdog.c: control hard lockup detection default
In some cases we don't want hard lockup detection enabled by default.
An example is when running as a guest.  Introduce

  watchdog_enable_hardlockup_detector(bool)

allowing those cases to disable hard lockup detection.  This must be
executed early by the boot processor from e.g.  smp_prepare_boot_cpu, in
order to allow kernel command line arguments to override it, as well as
to avoid hard lockup detection being enabled before we've had a chance
to indicate that it's unwanted.  In summary,

  initial boot:					default=enabled
  smp_prepare_boot_cpu
    watchdog_enable_hardlockup_detector(false):	default=disabled
  cmdline has 'nmi_watchdog=1':			default=enabled

The running kernel still has the ability to enable/disable at any time
with /proc/sys/kernel/nmi_watchdog us usual.  However even when the
default has been overridden /proc/sys/kernel/nmi_watchdog will initially
show '1'.  To truly turn it on one must disable/enable it, i.e.

  echo 0 > /proc/sys/kernel/nmi_watchdog
  echo 1 > /proc/sys/kernel/nmi_watchdog

This patch will be immediately useful for KVM with the next patch of this
series.  Other hypervisor guest types may find it useful as well.

[akpm@linux-foundation.org: fix build]
[dzickus@redhat.com: fix compile issues on sparc]
Signed-off-by: Ulrich Obergfell <uobergfe@redhat.com>
Signed-off-by: Andrew Jones <drjones@redhat.com>
Signed-off-by: Don Zickus <dzickus@redhat.com>
Signed-off-by: Don Zickus <dzickus@redhat.com>
Cc: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2014-10-14 02:18:27 +02:00
Tomasz Nowicki
44a69f6195 acpi, apei, ghes: Make NMI error notification to be GHES architecture extension.
Currently APEI depends on x86 architecture. It is because of NMI hardware
error notification of GHES which is currently supported by x86 only.
However, many other APEI features can be still used perfectly by other
architectures.

This commit adds two symbols:
1. HAVE_ACPI_APEI for those archs which support APEI.
2. HAVE_ACPI_APEI_NMI which is used for NMI code isolation in ghes.c
   file. NMI related data and functions are grouped so they can be wrapped
   inside one #ifdef section. Appropriate function stubs are provided for
   !NMI case.

Note there is no functional changes for x86 due to hard selected
HAVE_ACPI_APEI and HAVE_ACPI_APEI_NMI symbols.

Signed-off-by: Tomasz Nowicki <tomasz.nowicki@linaro.org>
Acked-by: Borislav Petkov <bp@suse.de>
Signed-off-by: Tony Luck <tony.luck@intel.com>
2014-07-22 15:05:06 -07:00
Aaron Tomlin
ed235875e2 kernel/watchdog.c: print traces for all cpus on lockup detection
A 'softlockup' is defined as a bug that causes the kernel to loop in
kernel mode for more than a predefined period to time, without giving
other tasks a chance to run.

Currently, upon detection of this condition by the per-cpu watchdog
task, debug information (including a stack trace) is sent to the system
log.

On some occasions, we have observed that the "victim" rather than the
actual "culprit" (i.e.  the owner/holder of the contended resource) is
reported to the user.  Often this information has proven to be
insufficient to assist debugging efforts.

To avoid loss of useful debug information, for architectures which
support NMI, this patch makes it possible to improve soft lockup
reporting.  This is accomplished by issuing an NMI to each cpu to obtain
a stack trace.

If NMI is not supported we just revert back to the old method.  A sysctl
and boot-time parameter is available to toggle this feature.

[dzickus@redhat.com: add CONFIG_SMP in certain areas]
[akpm@linux-foundation.org: additional CONFIG_SMP=n optimisations]
[mq@suse.cz: fix warning]
Signed-off-by: Aaron Tomlin <atomlin@redhat.com>
Signed-off-by: Don Zickus <dzickus@redhat.com>
Cc: David S. Miller <davem@davemloft.net>
Cc: Mateusz Guzik <mguzik@redhat.com>
Cc: Oleg Nesterov <oleg@redhat.com>
Signed-off-by: Jan Moskyto Matejka <mq@suse.cz>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2014-06-23 16:47:44 -07:00
Aaron Tomlin
f3aca3d095 nmi: provide the option to issue an NMI back trace to every cpu but current
Sometimes it is preferred not to use the trigger_all_cpu_backtrace()
routine when one wants to avoid capturing a back trace for current.  For
instance if one was previously captured recently.

This patch provides a new routine namely
trigger_allbutself_cpu_backtrace() which offers the flexibility to issue
an NMI to every cpu but current and capture a back trace accordingly.

Patch x86 and sparc to support new routine.

[dzickus@redhat.com: add stub in #else clause]
[dzickus@redhat.com: don't print message in single processor case, wrap with get/put_cpu based on Oleg's suggestion]
[sfr@canb.auug.org.au: undo C99ism]
Signed-off-by: Aaron Tomlin <atomlin@redhat.com>
Signed-off-by: Don Zickus <dzickus@redhat.com>
Acked-by: David S. Miller <davem@davemloft.net>
Cc: Mateusz Guzik <mguzik@redhat.com>
Cc: Oleg Nesterov <oleg@redhat.com>
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2014-06-23 16:47:44 -07:00
Frederic Weisbecker
3c00ea82c7 watchdog: Rename confusing state variable
We have two very conflicting state variable names in the
watchdog:

* watchdog_enabled: This one reflects the user interface. It's
set to 1 by default and can be overriden with boot options
or sysctl/procfs interface.

* watchdog_disabled: This is the internal toggle state that
tells if watchdog threads, timers and NMI events are currently
running or not. This state mostly depends on the user settings.
It's a convenient state latch.

Now we really need to find clearer names because those
are just too confusing to encourage deep review.

watchdog_enabled now becomes watchdog_user_enabled to reflect
its purpose as an interface.

watchdog_disabled becomes watchdog_running to suggest its
role as a pure internal state.

Signed-off-by: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Srivatsa S. Bhat <srivatsa.bhat@linux.vnet.ibm.com>
Cc: Anish Singh <anish198519851985@gmail.com>
Cc: Steven Rostedt <rostedt@goodmis.org>
Cc: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
Cc: Ingo Molnar <mingo@kernel.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Borislav Petkov <bp@alien8.de>
Cc: Li Zhong <zhong@linux.vnet.ibm.com>
Cc: Don Zickus <dzickus@redhat.com>
2013-06-20 15:41:18 +02:00
Cong Wang
d314d74c69 nmi watchdog: do not use cpp symbol in Kconfig
ARCH_HAS_NMI_WATCHDOG is a macro defined by arch, but config
HARDLOCKUP_DETECTOR depends on it.  This is wrong, ARCH_HAS_NMI_WATCHDOG
has to be a Kconfig config, and arch's need it should select it
explicitly.

Signed-off-by: WANG Cong <xiyou.wangcong@gmail.com>
Acked-by: Don Zickus <dzickus@redhat.com>
Acked-by: Mike Frysinger <vapier@gentoo.org>
Cc: David Howells <dhowells@redhat.com>
Cc: David Miller <davem@davemloft.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2012-03-23 16:58:31 -07:00