Skip to content

Commit

Permalink
Merge tag 'lts-v5.4.61-yocto-200907T010133Z' into lts2019/preempt-rt
Browse files Browse the repository at this point in the history
Creating tag for lts-v5.4.61-yocto-200907T010133Z

* tag 'lts-v5.4.61-yocto-200907T010133Z':
  ASoC: codec: tlv3204: Enable TDM audio support
  ASoC: Intel: KMB: Enable DMA transfer mode
  ASoC: Intel: KMB: Enable TDM mode
  tcc: l3 psram region size could become zero after exclude l2 inclusive regions
  tcc: update tcc range end_address.
  Change pr_info to pr_debug in vpusmm_session_ptr2vpu
  Linux 5.4.61
  KVM: arm64: Only reschedule if MMU_NOTIFIER_RANGE_BLOCKABLE is not set
  KVM: Pass MMU notifier range flags to kvm_unmap_hva_range()
  xen: don't reschedule in preemption off sections
  mm/hugetlb: fix calculation of adjust_range_if_pmd_sharing_possible
  do_epoll_ctl(): clean the failure exits up a bit
  epoll: Keep a reference on files added to the check list
  efi: add missed destroy_workqueue when efisubsys_init fails
  powerpc/pseries: Do not initiate shutdown when system is running on UPS
  net: dsa: b53: check for timeout
  hv_netvsc: Fix the queue_mapping in netvsc_vf_xmit()
  net: gemini: Fix missing free_netdev() in error path of gemini_ethernet_port_probe()
  net: ena: Prevent reset after device destruction
  bonding: fix active-backup failover for current ARP slave
  ARM64: vdso32: Install vdso32 from vdso_install
  afs: Fix NULL deref in afs_dynroot_depopulate()
  RDMA/bnxt_re: Do not add user qps to flushlist
  Fix build error when CONFIG_ACPI is not set/enabled:
  efi: avoid error message when booting under Xen
  kconfig: qconf: fix signal connection to invalid slots
  kconfig: qconf: do not limit the pop-up menu to the first row
  Revert "scsi: qla2xxx: Disable T10-DIF feature with FC-NVMe during probe"
  kvm: x86: Toggling CR4.PKE does not load PDPTEs in PAE mode
  kvm: x86: Toggling CR4.SMAP does not load PDPTEs in PAE mode
  vfio/type1: Add proper error unwind for vfio_iommu_replay()
  ASoC: intel: Fix memleak in sst_media_open
  ASoC: msm8916-wcd-analog: fix register Interrupt offset
  s390/ptrace: fix storage key handling
  s390/runtime_instrumentation: fix storage key handling
  bonding: fix a potential double-unregister
  can: j1939: add rxtimer for multipacket broadcast session
  can: j1939: abort multipacket broadcast session when timeout occurs
  can: j1939: cancel rxtimer on multipacket broadcast session complete
  can: j1939: fix support for multipacket broadcast message
  bonding: show saner speed for broadcast mode
  net: fec: correct the error path for regulator disable in probe
  i40e: Fix crash during removing i40e driver
  i40e: Set RX_ONLY mode for unicast promiscuous on VLAN
  can: j1939: transport: add j1939_session_skb_find_by_offset() function
  can: j1939: transport: j1939_simple_recv(): ignore local J1939 messages send not by J1939 stack
  can: j1939: fix kernel-infoleak in j1939_sk_sock2sockaddr_can()
  bpf: sock_ops sk access may stomp registers when dst_reg = src_reg
  ASoC: q6routing: add dummy register read/write function
  ASoC: q6afe-dai: mark all widgets registers as SND_SOC_NOPM
  spi: stm32: fixes suspend/resume management
  netfilter: nf_tables: nft_exthdr: the presence return value should be little-endian
  ext4: don't allow overlapping system zones
  ext4: fix potential negative array index in do_split()
  fs/signalfd.c: fix inconsistent return codes for signalfd4
  alpha: fix annotation of io{read,write}{16,32}be()
  xfs: Fix UBSAN null-ptr-deref in xfs_sysfs_init
  tools/testing/selftests/cgroup/cgroup_util.c: cg_read_strcmp: fix null pointer dereference
  media: camss: fix memory leaks on error handling paths in probe
  virtio_ring: Avoid loop when vq is broken in virtqueue_poll
  scsi: libfc: Free skb in fc_disc_gpn_id_resp() for valid cases
  cpufreq: intel_pstate: Fix cpuinfo_max_freq when MSR_TURBO_RATIO_LIMIT is 0
  swiotlb-xen: use vmalloc_to_page on vmalloc virt addresses
  ceph: fix use-after-free for fsc->mdsc
  jffs2: fix UAF problem
  drm/ttm: fix offset in VMAs with a pg_offs in ttm_bo_vm_access
  xfs: fix inode quota reservation checks
  svcrdma: Fix another Receive buffer leak
  m68knommu: fix overwriting of bits in ColdFire V3 cache control
  MIPS: Fix unable to reserve memory for Crash kernel
  Input: psmouse - add a newline when printing 'proto' by sysfs
  media: vpss: clean up resources in init
  rtc: goldfish: Enable interrupt in set_alarm() when necessary
  media: budget-core: Improve exception handling in budget_register()
  scsi: target: tcmu: Fix crash in tcmu_flush_dcache_range on ARM
  scsi: ufs: Add DELAY_BEFORE_LPM quirk for Micron devices
  opp: Enable resources again if they were disabled earlier
  kthread: Do not preempt current task if it is going to call schedule()
  drm/amd/display: fix pow() crashing when given base 0
  drm/amd/display: Fix EDID parsing after resume from suspend
  drm/amdgpu/display: use GFP_ATOMIC in dcn20_validate_bandwidth_internal
  scsi: zfcp: Fix use-after-free in request timeout handlers
  jbd2: add the missing unlock_buffer() in the error path of jbd2_write_superblock()
  ext4: fix checking of directory entry validity for inline directories
  RDMA/hfi1: Correct an interlock issue for TID RDMA WRITE request
  mm, page_alloc: fix core hung in free_pcppages_bulk()
  mm: include CMA pages in lowmem_reserve at boot
  uprobes: __replace_page() avoid BUG in munlock_vma_page()
  kernel/relay.c: fix memleak on destroy relay channel
  romfs: fix uninitialized memory leak in romfs_dev_read()
  spi: Prevent adding devices below an unregistering controller
  can: j1939: socket: j1939_sk_bind(): make sure ml_priv is allocated
  can: j1939: transport: j1939_session_tx_dat(): fix use-after-free read in j1939_tp_txtimer()
  ALSA: hda/realtek: Add quirk for Samsung Galaxy Book Ion
  ALSA: hda/realtek: Add quirk for Samsung Galaxy Flex Book
  btrfs: add wrapper for transaction abort predicate
  btrfs: return EROFS for BTRFS_FS_STATE_ERROR cases
  btrfs: don't show full path of bind mounts in subvol=
  btrfs: export helpers for subvolume name/id resolution
  bcache: avoid nr_stripes overflow in bcache_device_init()
  khugepaged: adjust VM_BUG_ON_MM() in __khugepaged_enter()
  khugepaged: khugepaged_test_exit() check mmget_still_valid()
  perf probe: Fix memory leakage when the probe point is not found
  gfs2: Never call gfs2_block_zero_range with an open transaction
  gfs2: Improve mmap write vs. punch_hole consistency
  drm/vgem: Replace opencoded version of drm_gem_dumb_map_offset()
  kbuild: support LLVM=1 to switch the default tools to Clang/LLVM
  kbuild: replace AS=clang with LLVM_IAS=1
  kbuild: remove AS variable
  kbuild: remove PYTHON2 variable
  x86/boot: kbuild: allow readelf executable to be specified
  net: wan: wanxl: use $(M68KCC) instead of $(M68KAS) for rebuilding firmware
  net: wan: wanxl: use allow to pass CROSS_COMPILE_M68k for rebuilding firmware
  Documentation/llvm: fix the name of llvm-size
  Documentation/llvm: add documentation on building w/ Clang/LLVM
  Linux 5.4.60
  drm/amd/display: dchubbub p-state warning during surface planes switch
  drm/amdgpu: Fix bug where DPM is not enabled after hibernate and resume
  drm: fix drm_dp_mst_port refcount leaks in drm_dp_mst_allocate_vcpi
  drm: Added orientation quirk for ASUS tablet model T103HAF
  drm/panfrost: Use kvfree() to free bo->sgts
  arm64: dts: marvell: espressobin: add ethernet alias
  khugepaged: retract_page_tables() remember to test exit
  sh: landisk: Add missing initialization of sh_io_port_base
  perf/x86/rapl: Fix missing psys sysfs attributes
  tools build feature: Quote CC and CXX for their arguments
  perf bench mem: Always memset source before memcpy
  ALSA: echoaudio: Fix potential Oops in snd_echo_resume()
  crypto: algif_aead - fix uninitialized ctx->init
  mfd: dln2: Run event handler loop under spinlock
  i2c: iproc: fix race between client unreg and isr
  test_kmod: avoid potential double free in trigger_config_run_type()
  fs/ufs: avoid potential u32 multiplication overflow
  fs/minix: remove expected error message in block_to_path()
  fs/minix: fix block limit check for V1 filesystems
  fs/minix: set s_maxbytes correctly
  nfs: Fix getxattr kernel panic and memory overflow
  net: qcom/emac: add missed clk_disable_unprepare in error path of emac_clks_phase1_init
  drm/vmwgfx: Fix two list_for_each loop exit tests
  drm/vmwgfx: Use correct vmw_legacy_display_unit pointer
  recordmcount: Fix build failure on non arm64
  Input: sentelic - fix error return when fsp_reg_write fails
  x86/tsr: Fix tsc frequency enumeration bug on Lightning Mountain SoC
  md-cluster: Fix potential error pointer dereference in resize_bitmaps()
  watchdog: initialize device before misc_register
  nfs: nfs_file_write() should check for writeback errors
  scsi: lpfc: nvmet: Avoid hang / use-after-free again when destroying targetport
  openrisc: Fix oops caused when dumping stack
  libnvdimm/security: ensure sysfs poll thread woke up and fetch updated attr
  libnvdimm/security: fix a typo
  clk: bcm2835: Do not use prediv with bcm2711's PLLs
  ubifs: Fix wrong orphan node deletion in ubifs_jnl_update|rename
  nfs: ensure correct writeback errors are returned on close()
  i2c: rcar: avoid race when unregistering slave
  tools build feature: Use CC and CXX from parent
  pwm: bcm-iproc: handle clk_get_rate() return
  clk: clk-atlas6: fix return value check in atlas6_clk_init()
  clk: qcom: gcc-sdm660: Fix up gcc_mss_mnoc_bimc_axi_clk
  i2c: rcar: slave: only send STOP event when we have been addressed
  iommu/vt-d: Enforce PASID devTLB field mask
  clk: qcom: clk-alpha-pll: remove unused/incorrect PLL_CAL_VAL
  clk: qcom: gcc: fix sm8150 GPU and NPU clocks
  iommu/omap: Check for failure of a call to omap_iommu_dump_ctx
  selftests/powerpc: ptrace-pkey: Don't update expected UAMOR value
  selftests/powerpc: ptrace-pkey: Update the test to mark an invalid pkey correctly
  selftests/powerpc: ptrace-pkey: Rename variables to make it easier to follow code
  clk: actions: Fix h_clk for Actions S500 SoC
  dm rq: don't call blk_mq_queue_stopped() in dm_stop_queue()
  gpu: ipu-v3: image-convert: Wait for all EOFs before completing a tile
  gpu: ipu-v3: image-convert: Combine rotate/no-rotate irq handlers
  crypto: caam - Remove broken arc4 support
  mmc: renesas_sdhi_internal_dmac: clean up the code for dma complete
  RDMA/counter: Allow manually bind QPs with different pids to same counter
  RDMA/counter: Only bind user QPs in auto mode
  devres: keep both device name and resource name in pretty name
  crypto: af_alg - Fix regression on empty requests
  USB: serial: ftdi_sio: clean up receive processing
  USB: serial: ftdi_sio: make process-packet buffer unsigned
  selftests/bpf: test_progs use another shell exit on non-actions
  selftests/bpf: Test_progs indicate to shell on non-actions
  IB/uverbs: Set IOVA on IB MR in uverbs layer
  media: rockchip: rga: Only set output CSC mode for RGB input
  media: rockchip: rga: Introduce color fmt macros and refactor CSC mode logic
  RDMA/ipoib: Fix ABBA deadlock with ipoib_reap_ah()
  RDMA/ipoib: Return void from ipoib_ib_dev_stop()
  platform/chrome: cros_ec_ishtp: Fix a double-unlock issue
  mtd: rawnand: fsl_upm: Remove unused mtd var
  octeontx2-af: change (struct qmem)->entry_sz from u8 to u16
  mfd: arizona: Ensure 32k clock is put on driver unbind and error
  crypto: algif_aead - Only wake up when ctx->more is zero
  pinctrl: ingenic: Properly detect GPIO direction when configured for IRQ
  orangefs: get rid of knob code...
  drm/imx: imx-ldb: Disable both channels for split mode in enc->disable()
  remoteproc: qcom_q6v5_mss: Validate modem blob firmware size before load
  remoteproc: qcom_q6v5_mss: Validate MBA firmware size before load
  remoteproc: qcom: q6v5: Update running state before requesting stop
  perf intel-pt: Fix duplicate branch after CBR
  perf intel-pt: Fix FUP packet state
  module: Correctly truncate sysfs sections output
  pseries: Fix 64 bit logical memory block panic
  ceph: handle zero-length feature mask in session messages
  ceph: set sec_context xattr on symlink creation
  watchdog: f71808e_wdt: clear watchdog timeout occurred flag
  watchdog: f71808e_wdt: remove use of wrong watchdog_info option
  watchdog: f71808e_wdt: indicate WDIOF_CARDRESET support in watchdog_info.options
  tracing: Move pipe reference to trace array instead of current_tracer
  tracing: Use trace_sched_process_free() instead of exit() for pid tracing
  tracing/hwlat: Honor the tracing_cpumask
  kprobes: Fix NULL pointer dereference at kprobe_ftrace_handler
  ftrace: Setup correct FTRACE_FL_REGS flags for module
  mm/memory_hotplug: fix unpaired mem_hotplug_begin/done
  mm/page_counter.c: fix protection usage propagation
  ocfs2: change slot number type s16 to u16
  khugepaged: collapse_pte_mapped_thp() protect the pmd lock
  khugepaged: collapse_pte_mapped_thp() flush the right range
  ext2: fix missing percpu_counter_inc
  MIPS: qi_lb60: Fix routing to audio amplifier
  MIPS: CPU#0 is not hotpluggable
  driver core: Avoid binding drivers to dead devices
  mac80211: fix misplaced while instead of if
  bcache: fix overflow in offset_to_stripe()
  bcache: allocate meta data pages as compound pages
  md/raid5: Fix Force reconstruct-write io stuck in degraded raid5
  net/compat: Add missing sock updates for SCM_RIGHTS
  net: stmmac: dwmac1000: provide multicast filter fallback
  net: ethernet: stmmac: Disable hardware multicast filter
  media: vsp1: dl: Fix NULL pointer dereference on unbind
  pinctrl: ingenic: Enhance support for IRQ_TYPE_EDGE_BOTH
  powerpc: Fix circular dependency between percpu.h and mmu.h
  powerpc: Allow 4224 bytes of stack expansion for the signal frame
  powerpc/ptdump: Fix build failure in hashpagetable.c
  cifs: Fix leak when handling lease break for cached root fid
  xtensa: fix xtensa_pmu_setup prototype
  xtensa: add missing exclusive access state management
  iio: dac: ad5592r: fix unbalanced mutex unlocks in ad5592r_read_raw()
  dt-bindings: iio: io-channel-mux: Fix compatible string in example code
  arm64: perf: Correct the event index in sysfs
  btrfs: fix return value mixup in btrfs_get_extent
  btrfs: make sure SB_I_VERSION doesn't get unset by remount
  btrfs: fix memory leaks after failure to lookup checksums during inode logging
  btrfs: inode: fix NULL pointer dereference if inode doesn't need compression
  btrfs: only search for left_info if there is no right_info in try_merge_free_space
  btrfs: fix messages after changing compression level by remount
  btrfs: fix race between page release and a fast fsync
  btrfs: don't WARN if we abort a transaction with EROFS
  btrfs: sysfs: use NOFS for device creation
  btrfs: avoid possible signal interruption of btrfs_drop_snapshot() on relocation tree
  btrfs: add missing check for nocow and compression inode flags
  btrfs: relocation: review the call sites which can be interrupted by signal
  btrfs: move the chunk_mutex in btrfs_read_chunk_tree
  btrfs: open device without device_list_mutex
  btrfs: don't traverse into the seed devices in show_devname
  btrfs: remove no longer needed use of log_writers for the log root tree
  btrfs: stop incremening log_batch for the log root tree when syncing log
  btrfs: ref-verify: fix memory leak in add_block_entry
  btrfs: don't allocate anonymous block device for user invisible roots
  btrfs: free anon block device right after subvolume deletion
  btrfs: allow use of global block reserve for balance item deletion
  PCI: qcom: Add support for tx term offset for rev 2.1.0
  PCI: qcom: Define some PARF params needed for ipq8064 SoC
  PCI: Add device even if driver attach failed
  PCI: Mark AMD Navi10 GPU rev 0x00 ATS as broken
  PCI: hotplug: ACPI: Fix context refcounting in acpiphp_grab_context()
  genirq/PM: Always unlock IRQ descriptor in rearm_wake_irq()
  genirq/affinity: Make affinity setting if activated opt-in
  smb3: warn on confusing error scenario with sec=krb5
  • Loading branch information
ranjan-dutta committed Sep 14, 2020
2 parents 3747758 + fb165c2 commit 24d1b58
Show file tree
Hide file tree
Showing 264 changed files with 2,482 additions and 1,203 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ controller state. The mux controller state is described in

Example:
mux: mux-controller {
compatible = "mux-gpio";
compatible = "gpio-mux";
#mux-control-cells = <0>;

mux-gpios = <&pioA 0 GPIO_ACTIVE_HIGH>,
Expand Down
1 change: 1 addition & 0 deletions Documentation/kbuild/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ Kernel Build System

issues
reproducible-builds
llvm

.. only:: subproject and html

Expand Down
5 changes: 5 additions & 0 deletions Documentation/kbuild/kbuild.rst
Original file line number Diff line number Diff line change
Expand Up @@ -262,3 +262,8 @@ KBUILD_BUILD_USER, KBUILD_BUILD_HOST
These two variables allow to override the user@host string displayed during
boot and in /proc/version. The default value is the output of the commands
whoami and host, respectively.

LLVM
----
If this variable is set to 1, Kbuild will use Clang and LLVM utilities instead
of GCC and GNU binutils to build the kernel.
87 changes: 87 additions & 0 deletions Documentation/kbuild/llvm.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,87 @@
==============================
Building Linux with Clang/LLVM
==============================

This document covers how to build the Linux kernel with Clang and LLVM
utilities.

About
-----

The Linux kernel has always traditionally been compiled with GNU toolchains
such as GCC and binutils. Ongoing work has allowed for `Clang
<https://clang.llvm.org/>`_ and `LLVM <https://llvm.org/>`_ utilities to be
used as viable substitutes. Distributions such as `Android
<https://www.android.com/>`_, `ChromeOS
<https://www.chromium.org/chromium-os>`_, and `OpenMandriva
<https://www.openmandriva.org/>`_ use Clang built kernels. `LLVM is a
collection of toolchain components implemented in terms of C++ objects
<https://www.aosabook.org/en/llvm.html>`_. Clang is a front-end to LLVM that
supports C and the GNU C extensions required by the kernel, and is pronounced
"klang," not "see-lang."

Clang
-----

The compiler used can be swapped out via `CC=` command line argument to `make`.
`CC=` should be set when selecting a config and during a build.

make CC=clang defconfig

make CC=clang

Cross Compiling
---------------

A single Clang compiler binary will typically contain all supported backends,
which can help simplify cross compiling.

ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- make CC=clang

`CROSS_COMPILE` is not used to prefix the Clang compiler binary, instead
`CROSS_COMPILE` is used to set a command line flag: `--target <triple>`. For
example:

clang --target aarch64-linux-gnu foo.c

LLVM Utilities
--------------

LLVM has substitutes for GNU binutils utilities. Kbuild supports `LLVM=1`
to enable them.

make LLVM=1

They can be enabled individually. The full list of the parameters:

make CC=clang LD=ld.lld AR=llvm-ar NM=llvm-nm STRIP=llvm-strip \\
OBJCOPY=llvm-objcopy OBJDUMP=llvm-objdump OBJSIZE=llvm-size \\
READELF=llvm-readelf HOSTCC=clang HOSTCXX=clang++ HOSTAR=llvm-ar \\
HOSTLD=ld.lld

Currently, the integrated assembler is disabled by default. You can pass
`LLVM_IAS=1` to enable it.

Getting Help
------------

- `Website <https://clangbuiltlinux.github.io/>`_
- `Mailing List <https://groups.google.com/forum/#!forum/clang-built-linux>`_: <clang-built-linux@googlegroups.com>
- `Issue Tracker <https://github.com/ClangBuiltLinux/linux/issues>`_
- IRC: #clangbuiltlinux on chat.freenode.net
- `Telegram <https://t.me/ClangBuiltLinux>`_: @ClangBuiltLinux
- `Wiki <https://github.com/ClangBuiltLinux/linux/wiki>`_
- `Beginner Bugs <https://github.com/ClangBuiltLinux/linux/issues?q=is%3Aopen+is%3Aissue+label%3A%22good+first+issue%22>`_

Getting LLVM
-------------

- http://releases.llvm.org/download.html
- https://github.com/llvm/llvm-project
- https://llvm.org/docs/GettingStarted.html
- https://llvm.org/docs/CMake.html
- https://apt.llvm.org/
- https://www.archlinux.org/packages/extra/x86_64/llvm/
- https://github.com/ClangBuiltLinux/tc-build
- https://github.com/ClangBuiltLinux/linux/wiki/Building-Clang-from-source
- https://android.googlesource.com/platform/prebuilts/clang/host/linux-x86/
1 change: 1 addition & 0 deletions MAINTAINERS
Original file line number Diff line number Diff line change
Expand Up @@ -4040,6 +4040,7 @@ B: https://github.com/ClangBuiltLinux/linux/issues
C: irc://chat.freenode.net/clangbuiltlinux
S: Supported
K: \b(?i:clang|llvm)\b
F: Documentation/kbuild/llvm.rst

CLEANCACHE API
M: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Expand Down
40 changes: 28 additions & 12 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# SPDX-License-Identifier: GPL-2.0
VERSION = 5
PATCHLEVEL = 4
SUBLEVEL = 59
SUBLEVEL = 61
EXTRAVERSION =
NAME = Kleptomaniac Octopus

Expand Down Expand Up @@ -394,8 +394,13 @@ HOST_LFS_CFLAGS := $(shell getconf LFS_CFLAGS 2>/dev/null)
HOST_LFS_LDFLAGS := $(shell getconf LFS_LDFLAGS 2>/dev/null)
HOST_LFS_LIBS := $(shell getconf LFS_LIBS 2>/dev/null)

HOSTCC = gcc
HOSTCXX = g++
ifneq ($(LLVM),)
HOSTCC = clang
HOSTCXX = clang++
else
HOSTCC = gcc
HOSTCXX = g++
endif
KBUILD_HOSTCFLAGS := -Wall -Wmissing-prototypes -Wstrict-prototypes -O2 \
-fomit-frame-pointer -std=gnu89 $(HOST_LFS_CFLAGS) \
$(HOSTCFLAGS)
Expand All @@ -404,16 +409,28 @@ KBUILD_HOSTLDFLAGS := $(HOST_LFS_LDFLAGS) $(HOSTLDFLAGS)
KBUILD_HOSTLDLIBS := $(HOST_LFS_LIBS) $(HOSTLDLIBS)

# Make variables (CC, etc...)
AS = $(CROSS_COMPILE)as
LD = $(CROSS_COMPILE)ld
CC = $(CROSS_COMPILE)gcc
CPP = $(CC) -E
ifneq ($(LLVM),)
CC = clang
LD = ld.lld
AR = llvm-ar
NM = llvm-nm
OBJCOPY = llvm-objcopy
OBJDUMP = llvm-objdump
READELF = llvm-readelf
OBJSIZE = llvm-size
STRIP = llvm-strip
else
CC = $(CROSS_COMPILE)gcc
LD = $(CROSS_COMPILE)ld
AR = $(CROSS_COMPILE)ar
NM = $(CROSS_COMPILE)nm
STRIP = $(CROSS_COMPILE)strip
OBJCOPY = $(CROSS_COMPILE)objcopy
OBJDUMP = $(CROSS_COMPILE)objdump
READELF = $(CROSS_COMPILE)readelf
OBJSIZE = $(CROSS_COMPILE)size
STRIP = $(CROSS_COMPILE)strip
endif
PAHOLE = pahole
LEX = flex
YACC = bison
Expand All @@ -422,7 +439,6 @@ INSTALLKERNEL := installkernel
DEPMOD = /sbin/depmod
PERL = perl
PYTHON = python
PYTHON2 = python2
PYTHON3 = python3
CHECK = sparse
BASH = bash
Expand Down Expand Up @@ -471,9 +487,9 @@ KBUILD_LDFLAGS :=
GCC_PLUGINS_CFLAGS :=
CLANG_FLAGS :=

export ARCH SRCARCH CONFIG_SHELL BASH HOSTCC KBUILD_HOSTCFLAGS CROSS_COMPILE AS LD CC
export CPP AR NM STRIP OBJCOPY OBJDUMP OBJSIZE PAHOLE LEX YACC AWK INSTALLKERNEL
export PERL PYTHON PYTHON2 PYTHON3 CHECK CHECKFLAGS MAKE UTS_MACHINE HOSTCXX
export ARCH SRCARCH CONFIG_SHELL BASH HOSTCC KBUILD_HOSTCFLAGS CROSS_COMPILE LD CC
export CPP AR NM STRIP OBJCOPY OBJDUMP OBJSIZE READELF PAHOLE LEX YACC AWK INSTALLKERNEL
export PERL PYTHON PYTHON3 CHECK CHECKFLAGS MAKE UTS_MACHINE HOSTCXX
export KBUILD_HOSTCXXFLAGS KBUILD_HOSTLDFLAGS KBUILD_HOSTLDLIBS LDFLAGS_MODULE

export KBUILD_CPPFLAGS NOSTDINC_FLAGS LINUXINCLUDE OBJCOPYFLAGS KBUILD_LDFLAGS
Expand Down Expand Up @@ -534,7 +550,7 @@ endif
ifneq ($(GCC_TOOLCHAIN),)
CLANG_FLAGS += --gcc-toolchain=$(GCC_TOOLCHAIN)
endif
ifeq ($(shell $(AS) --version 2>&1 | head -n 1 | grep clang),)
ifneq ($(LLVM_IAS),1)
CLANG_FLAGS += -no-integrated-as
endif
CLANG_FLAGS += -Werror=unknown-warning-option
Expand Down
8 changes: 4 additions & 4 deletions arch/alpha/include/asm/io.h
Original file line number Diff line number Diff line change
Expand Up @@ -502,10 +502,10 @@ extern inline void writeq(u64 b, volatile void __iomem *addr)
}
#endif

#define ioread16be(p) be16_to_cpu(ioread16(p))
#define ioread32be(p) be32_to_cpu(ioread32(p))
#define iowrite16be(v,p) iowrite16(cpu_to_be16(v), (p))
#define iowrite32be(v,p) iowrite32(cpu_to_be32(v), (p))
#define ioread16be(p) swab16(ioread16(p))
#define ioread32be(p) swab32(ioread32(p))
#define iowrite16be(v,p) iowrite16(swab16(v), (p))
#define iowrite32be(v,p) iowrite32(swab32(v), (p))

#define inb_p inb
#define inw_p inw
Expand Down
2 changes: 1 addition & 1 deletion arch/arm/include/asm/kvm_host.h
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,7 @@ int __kvm_arm_vcpu_set_events(struct kvm_vcpu *vcpu,

#define KVM_ARCH_WANT_MMU_NOTIFIER
int kvm_unmap_hva_range(struct kvm *kvm,
unsigned long start, unsigned long end);
unsigned long start, unsigned long end, unsigned flags);
int kvm_set_spte_hva(struct kvm *kvm, unsigned long hva, pte_t pte);

unsigned long kvm_arm_num_regs(struct kvm_vcpu *vcpu);
Expand Down
1 change: 1 addition & 0 deletions arch/arm64/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -146,6 +146,7 @@ zinstall install:
PHONY += vdso_install
vdso_install:
$(Q)$(MAKE) $(build)=arch/arm64/kernel/vdso $@
$(Q)$(MAKE) $(build)=arch/arm64/kernel/vdso32 $@

# We use MRPROPER_FILES and CLEAN_FILES now
archclean:
Expand Down
6 changes: 6 additions & 0 deletions arch/arm64/boot/dts/marvell/armada-3720-espressobin.dts
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,12 @@
model = "Globalscale Marvell ESPRESSOBin Board";
compatible = "globalscale,espressobin", "marvell,armada3720", "marvell,armada3710";

aliases {
ethernet0 = &eth0;
serial0 = &uart0;
serial1 = &uart1;
};

chosen {
stdout-path = "serial0:115200n8";
};
Expand Down
2 changes: 1 addition & 1 deletion arch/arm64/include/asm/kvm_host.h
Original file line number Diff line number Diff line change
Expand Up @@ -427,7 +427,7 @@ int __kvm_arm_vcpu_set_events(struct kvm_vcpu *vcpu,

#define KVM_ARCH_WANT_MMU_NOTIFIER
int kvm_unmap_hva_range(struct kvm *kvm,
unsigned long start, unsigned long end);
unsigned long start, unsigned long end, unsigned flags);
int kvm_set_spte_hva(struct kvm *kvm, unsigned long hva, pte_t pte);
int kvm_age_hva(struct kvm *kvm, unsigned long start, unsigned long end);
int kvm_test_age_hva(struct kvm *kvm, unsigned long hva);
Expand Down
13 changes: 8 additions & 5 deletions arch/arm64/kernel/perf_event.c
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ armv8pmu_events_sysfs_show(struct device *dev,

pmu_attr = container_of(attr, struct perf_pmu_events_attr, attr);

return sprintf(page, "event=0x%03llx\n", pmu_attr->id);
return sprintf(page, "event=0x%04llx\n", pmu_attr->id);
}

#define ARMV8_EVENT_ATTR(name, config) \
Expand Down Expand Up @@ -303,10 +303,13 @@ armv8pmu_event_attr_is_visible(struct kobject *kobj,
test_bit(pmu_attr->id, cpu_pmu->pmceid_bitmap))
return attr->mode;

pmu_attr->id -= ARMV8_PMUV3_EXT_COMMON_EVENT_BASE;
if (pmu_attr->id < ARMV8_PMUV3_MAX_COMMON_EVENTS &&
test_bit(pmu_attr->id, cpu_pmu->pmceid_ext_bitmap))
return attr->mode;
if (pmu_attr->id >= ARMV8_PMUV3_EXT_COMMON_EVENT_BASE) {
u64 id = pmu_attr->id - ARMV8_PMUV3_EXT_COMMON_EVENT_BASE;

if (id < ARMV8_PMUV3_MAX_COMMON_EVENTS &&
test_bit(id, cpu_pmu->pmceid_ext_bitmap))
return attr->mode;
}

return 0;
}
Expand Down
2 changes: 1 addition & 1 deletion arch/arm64/kernel/vdso32/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ quiet_cmd_vdsosym = VDSOSYM $@
cmd_vdsosym = $(NM) $< | $(gen-vdsosym) | LC_ALL=C sort > $@

# Install commands for the unstripped file
quiet_cmd_vdso_install = INSTALL $@
quiet_cmd_vdso_install = INSTALL32 $@
cmd_vdso_install = cp $(obj)/$@.dbg $(MODLIB)/vdso/vdso32.so

vdso.so: $(obj)/vdso.so.dbg
Expand Down
6 changes: 3 additions & 3 deletions arch/m68k/include/asm/m53xxacr.h
Original file line number Diff line number Diff line change
Expand Up @@ -89,9 +89,9 @@
* coherency though in all cases. And for copyback caches we will need
* to push cached data as well.
*/
#define CACHE_INIT CACR_CINVA
#define CACHE_INVALIDATE CACR_CINVA
#define CACHE_INVALIDATED CACR_CINVA
#define CACHE_INIT (CACHE_MODE + CACR_CINVA - CACR_EC)
#define CACHE_INVALIDATE (CACHE_MODE + CACR_CINVA)
#define CACHE_INVALIDATED (CACHE_MODE + CACR_CINVA)

#define ACR0_MODE ((CONFIG_RAMBASE & 0xff000000) + \
(0x000f0000) + \
Expand Down
2 changes: 1 addition & 1 deletion arch/mips/boot/dts/ingenic/qi_lb60.dts
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@
"Speaker", "OUTL",
"Speaker", "OUTR",
"INL", "LOUT",
"INL", "ROUT";
"INR", "ROUT";

simple-audio-card,aux-devs = <&amp>;

Expand Down
2 changes: 1 addition & 1 deletion arch/mips/include/asm/kvm_host.h
Original file line number Diff line number Diff line change
Expand Up @@ -939,7 +939,7 @@ enum kvm_mips_fault_result kvm_trap_emul_gva_fault(struct kvm_vcpu *vcpu,

#define KVM_ARCH_WANT_MMU_NOTIFIER
int kvm_unmap_hva_range(struct kvm *kvm,
unsigned long start, unsigned long end);
unsigned long start, unsigned long end, unsigned flags);
int kvm_set_spte_hva(struct kvm *kvm, unsigned long hva, pte_t pte);
int kvm_age_hva(struct kvm *kvm, unsigned long start, unsigned long end);
int kvm_test_age_hva(struct kvm *kvm, unsigned long hva);
Expand Down
2 changes: 1 addition & 1 deletion arch/mips/kernel/setup.c
Original file line number Diff line number Diff line change
Expand Up @@ -494,7 +494,7 @@ static void __init mips_parse_crashkernel(void)
if (ret != 0 || crash_size <= 0)
return;

if (!memblock_find_in_range(crash_base, crash_base + crash_size, crash_size, 0)) {
if (!memblock_find_in_range(crash_base, crash_base + crash_size, crash_size, 1)) {
pr_warn("Invalid memory region reserved for crash kernel\n");
return;
}
Expand Down
2 changes: 1 addition & 1 deletion arch/mips/kernel/topology.c
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ static int __init topology_init(void)
for_each_present_cpu(i) {
struct cpu *c = &per_cpu(cpu_devices, i);

c->hotpluggable = 1;
c->hotpluggable = !!i;
ret = register_cpu(c, i);
if (ret)
printk(KERN_WARNING "topology_init: register_cpu %d "
Expand Down
3 changes: 2 additions & 1 deletion arch/mips/kvm/mmu.c
Original file line number Diff line number Diff line change
Expand Up @@ -512,7 +512,8 @@ static int kvm_unmap_hva_handler(struct kvm *kvm, gfn_t gfn, gfn_t gfn_end,
return 1;
}

int kvm_unmap_hva_range(struct kvm *kvm, unsigned long start, unsigned long end)
int kvm_unmap_hva_range(struct kvm *kvm, unsigned long start, unsigned long end,
unsigned flags)
{
handle_hva_to_gpa(kvm, start, end, &kvm_unmap_hva_handler, NULL);

Expand Down
18 changes: 16 additions & 2 deletions arch/openrisc/kernel/stacktrace.c
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
#include <linux/export.h>
#include <linux/sched.h>
#include <linux/sched/debug.h>
#include <linux/sched/task_stack.h>
#include <linux/stacktrace.h>

#include <asm/processor.h>
Expand Down Expand Up @@ -68,12 +69,25 @@ void save_stack_trace_tsk(struct task_struct *tsk, struct stack_trace *trace)
{
unsigned long *sp = NULL;

if (!try_get_task_stack(tsk))
return;

if (tsk == current)
sp = (unsigned long *) &sp;
else
sp = (unsigned long *) KSTK_ESP(tsk);
else {
unsigned long ksp;

/* Locate stack from kernel context */
ksp = task_thread_info(tsk)->ksp;
ksp += STACK_FRAME_OVERHEAD; /* redzone */
ksp += sizeof(struct pt_regs);

sp = (unsigned long *) ksp;
}

unwind_stack(trace, sp, save_stack_address_nosched);

put_task_stack(tsk);
}
EXPORT_SYMBOL_GPL(save_stack_trace_tsk);

Expand Down

0 comments on commit 24d1b58

Please sign in to comment.