Commit Graph

1000339 Commits

Author SHA1 Message Date
Greg Kroah-Hartman
c4c6deb418 Merge a85f165e1f ("Merge tag 'drm-fixes-2021-04-10' of git://anongit.freedesktop.org/drm/drm") into android-mainline
Steps on the way to 5.12-rc7

Signed-off-by Greg Kroah-Hartman <gregkh@google.com>

Change-Id: I86e8380de6b93c9aa5106339f46657bf198321a0
2021-04-19 10:52:19 +02:00
Greg Kroah-Hartman
44ef0c2e4b Merge 60144b23c9 ("Merge tag 'selinux-pr-20210409' of git://git.kernel.org/pub/scm/linux/kernel/git/pcmoore/selinux") into android-mainline
Steps on the way to 5.12-rc7

Signed-off-by Greg Kroah-Hartman <gregkh@google.com>

Change-Id: Ia4b9f3dfdd7f6b6a93b5348fe6fc343248b4b0b2
2021-04-19 10:52:19 +02:00
Greg Kroah-Hartman
0aa448d00e Merge 189fefc7a4 ("Merge tag 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mst/vhost") into android-mainline
Steps on the way to 5.12-rc7

Signed-off-by Greg Kroah-Hartman <gregkh@google.com>

Change-Id: Ie85ea5e3c0cfe8d6ad87605bf0db4e5d8cfd4822
2021-04-19 10:52:18 +02:00
Greg Kroah-Hartman
e0e75381a9 Merge 3766fcf5d3 ("Merge tag 'rproc-v5.12-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/andersson/remoteproc") into android-mainline
Steps on the way to 5.12-rc7

Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Change-Id: I302e2016323ce85121734080a023642763058009
2021-04-19 10:41:44 +02:00
Greg Kroah-Hartman
0a449035f4 Merge 0b76088799 ("Merge tag 'for-linus-5.12b-rc7-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/xen/tip") into android-mainline
Steps on the way to 5.12-rc7

Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Change-Id: I4f745a7d8ee0ea79e22183002dbfd963f7d98375
2021-04-19 10:39:49 +02:00
Greg Kroah-Hartman
0e89e162ad Merge ccd6c35c72 ("Merge tag 'acpi-5.12-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm") into android-mainline
Steps on the way to 5.12-rc7

Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Change-Id: I8bf01b27a68a38a8d798bd9adda05fbfab5ae729
2021-04-19 10:37:49 +02:00
Greg Kroah-Hartman
36828bd1b2 Merge 17e7124aad ("Merge tag '5.12-rc6-smb3' of git://git.samba.org/sfrench/cifs-2.6") into android-mainline
Steps on the way to 5.12-rc7

Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Change-Id: Idc7308c02ab6cc94b365c8df35aa59891278e0b4
2021-04-19 10:34:16 +02:00
Greg Kroah-Hartman
aafb306e2a Merge 4fa56ad0d1 ("Merge tag 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/rdma/rdma") into android-mainline
Steps on the way to 5.12-rc7

Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Change-Id: I96f60597a6ea639868a2ebe7d43765b82630bd4d
2021-04-18 15:21:27 +02:00
Greg Kroah-Hartman
61d8d6c40d Merge e0a472fffe ("Merge tag 'sound-5.12-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound") into android-mainline
Steps on the way to 5.12-rc7

Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Change-Id: Ic42a738b12fd24a07ee69b247c59331632343238
2021-04-18 15:20:08 +02:00
Greg Kroah-Hartman
51586c6a6b Merge d381b05e86 ("Merge tag 'for-linus' of git://git.kernel.org/pub/scm/virt/kvm/kvm") into android-mainline
Steps on the way to 5.12-rc7

Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Change-Id: I7c94b4ef3ad349373d55fe360c83d6079531a74c
2021-04-18 15:19:02 +02:00
Greg Kroah-Hartman
f5b32d823d Merge 4ea51e0e37 ("Merge tag 'for-linus-2021-04-08' of git://git.kernel.org/pub/scm/linux/kernel/git/brauner/linux") into android-mainline
Steps on the way to 5.12-rc7

Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Change-Id: I3e01d8950c38d7ac8a734159c288daaa92966732
2021-04-18 15:18:16 +02:00
Greg Kroah-Hartman
8581d64e45 Merge 035d80695f ("Merge branch 'fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs") into android-mainline
Steps on the way to 5.12-rc7

Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Change-Id: I3cd7beb6b194b27eea8150334a61470007be61b2
2021-04-18 15:17:16 +02:00
Greg Kroah-Hartman
4adef261ac Merge 454859c552 ("Merge tag 'arc-5.12-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/vgupta/arc") into android-mainline
Steps on the way to 5.12-rc7

Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Change-Id: Iebe0a4f28bb8b1794a526c29c4dfb3edd8905a6e
2021-04-18 15:16:20 +02:00
Greg Kroah-Hartman
261c19f15a Merge 3a22981230 ("Merge tag 'arm-fixes-5.11-2' of git://git.kernel.org/pub/scm/linux/kernel/git/soc/soc") into android-mainline
Steps on the way to 5.12-rc7

Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Change-Id: I195f167cc8dbc2b650042342796ee69a176dc7c9
2021-04-18 15:15:14 +02:00
Greg Kroah-Hartman
c613b0a6ba Merge dbaa5d1c25 ("Merge branch 'parisc-5.12-3' of git://git.kernel.org/pub/scm/linux/kernel/git/deller/parisc-linux") into android-mainline
Steps on the way to 5.12-rc7

Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Change-Id: I9e32448117e299253703400e1c1dd2bad48bee5a
2021-04-18 15:14:32 +02:00
Greg Kroah-Hartman
8b1455531f Merge 5ba091db93 ("Merge tag 'platform-drivers-x86-v5.12-3' of git://git.kernel.org/pub/scm/linux/kernel/git/pdx86/platform-drivers-x86") into android-mainline
Steps on the way to 5.12-rc7

Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Change-Id: Ib49d869702643e6575d8624a8d00e4c016cd04ae
2021-04-18 15:13:06 +02:00
Greg Kroah-Hartman
aca56965ab Merge e3bb2f4f96 ("Merge tag 'regulator-fix-v5.12-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator") into android-mainline
Steps on the way to 5.12-rc7

Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Change-Id: I660b6221f2c87cad8487a2fa14db52fc7784f05f
2021-04-18 15:12:05 +02:00
Alexander Potapenko
6405f4f64d ANDROID: gki_defconfig: reduce KFENCE pool size
CONFIG_KFENCE_NUM_OBJECTS controls the constant memory overhead that
KFENCE introduces for its memory pool. By default it is 255 objects
(2Mb extra memory), but since concerns have been raised that low-memory
devices may not afford that, we are lowering the number of objects
to 63 (512Kb extra memory).

So far we haven't seen Android devices allocate more than 50 KFENCE
objects. Should the kernel exhaust the pool, KFENCE will stop allocating
new objects and fall back to SLAB/SLUB until one of the objects is
freed.

An immediate consequence of reducing the pool size is that a freed
KFENCE object will be reused 4x times faster, effectively reducing the
probability of detecting a use-after-free. Since KFENCE is a best-effort
error detection tool, not a use-after-free mitigation mechanism, we
believe this should not be problematic.

Bug: 181822795
Test: run KFENCE on an Android device
Signed-off-by: Alexander Potapenko <glider@google.com>
Change-Id: I88fca80eea8b382115de03dbb104fd305b35476f
2021-04-16 16:44:57 +00:00
Carlos Llamas
dc7b23f23c ANDROID: Incremental fs: fix u64 integer cast to pointer
Compiler (arm-linux-gnueabihf-gcc 8.3.0) complains about an invalid cast
of an __aligned_u64 integer to a pointer on 32-bit architectures. Using
u64_to_user_ptr() for the cast fixes the following warning:

fs/incfs/pseudo_files.c: In function ‘ioctl_create_file’:
fs/incfs/pseudo_files.c:656:10: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast]
  656 |          (u8 __user *)args.signature_info,
      |          ^

Bug: 183339614
Fixes: bc6a70e849 (ANDROID: Incremental fs: Remove signature checks from kernel)
Reported-by: kernelci.org bot <bot@kernelci.org>
Signed-off-by: Carlos Llamas <cmllamas@google.com>
Change-Id: I98a987fb83c160740796c0b4b3fdd7551880e12a
2021-04-16 00:34:51 +00:00
Carlos Llamas
d83b0684e1 ANDROID: Incremental fs: fix minor printk format warning
Use the correct printk specifier [%zu] for size_t variable.
This fixes the following warning:

fs/incfs/format.c: In function ‘incfs_read_next_metadata_record’:
./include/linux/kern_levels.h:5:18: warning: format ‘%ld’ expects argument of type ‘long int’, but argument 2 has type ‘size_t’ {aka ‘unsigned int’} [-Wformat=]
fs/incfs/format.c:669:3: note: in expansion of macro ‘pr_warn’
  669 |   pr_warn("incfs: The record is too large. Size: %ld",
      |   ^~~~~~~

Bug: 183339614
Fixes: c6819dd778 (ANDROID: Initial commit of Incremental FS)
Reported-by: kernelci.org bot <bot@kernelci.org>
Signed-off-by: Carlos Llamas <cmllamas@google.com>
Change-Id: Ia784a9ced9fb6bc76e2f1baa495b3ccf568e3b1d
2021-04-15 15:18:35 +00:00
Elliot Berman
ee1b16e80d ANDROID: Kbuild: Add support for KBUILD_MIXED_TREE
When KBUILD_MIXED_TREE points to the output folder of another kernel's
build output, Kbuild can compile a complete kernel tree's modules
against that other kernel tree's vmlinux. This is useful when two
kernel trees exist: a "Generic Kernel Image" tree and a "device kernel"
tree.  Both trees are complete kernel source trees, and the "Generic
Kernel Image" should provide the kernel Image and device kernel tree
provides device driver modules.

To accomplish this, references to vmlinux.symvers in the device kernel
should point to the generic kernel's vmlinux.symvers and the device
kernel should skip compilation of built-in files.

Bug: 178469391
Change-Id: I614f3e87519236c4e2c5da74937cb0ecd98a278a
Signed-off-by: Elliot Berman <eberman@codeaurora.org>
2021-04-14 10:36:22 +00:00
Gyeongtaek Lee
5d40bb284f ANDROID: Kconfig.gki Add SND_SOC_TOPOLOGY
Enable hidden config SND_SOC_TOPOLOGY need by SND_SOC=m

Bug: 153682187
Change-Id: I47dabfaa6f0d138f78fbc1c9fc0d4ac3c7c73986
Signed-off-by: Gyeongtaek Lee <gt82.lee@samsung.com>
2021-04-13 20:21:35 +00:00
Paul Lawrence
30f7628830 ANDROID: Incremental fs: stat should return actual used blocks
Test: incfs_test passes
Bug: 182182100
Signed-off-by: Paul Lawrence <paullawrence@google.com>
Change-Id: I4c9e5f111fbb659798ef79bc20d8a65b64b44ded
2021-04-13 19:43:44 +00:00
Alistair Delva
d9d3fe628e Revert "ANDROID: AVB error handler to invalidate vbmeta partition."
This driver is not used and can cause problems if used on modern
devices. Remove it.

This reverts commit 6115619831.

Bug: 185178770
Signed-off-by: Alistair Delva <adelva@google.com>
Change-Id: I1d5acb96dda765a1e3ea0cf62a3bf4b2a78892ea
2021-04-13 17:59:49 +00:00
Paul Lawrence
d434336cff ANDROID: Incremental fs: Add FS_IOC_READ_VERITY_METADATA
Bug: 180942327
Test: incfs_test passes
Signed-off-by: Paul Lawrence <paullawrence@google.com>
Change-Id: I6d6532496c072145f22bcf9ff4499ec3f52e94b5
2021-04-13 15:22:56 +00:00
A. Cody Schuffelen
2869b8c844 FROMGIT: virt_wifi: Return micros for BSS TSF values
cfg80211_inform_bss expects to receive a TSF value, but is given the
time since boot in nanoseconds. TSF values are expected to be at
microsecond scale rather than nanosecond scale.

Bug: 181840234
Test: atest CtsWifiTestCases:android.net.wifi.cts.ScanResultTest#testScanResultTimeStamp -- --abi x86_64
Signed-off-by: A. Cody Schuffelen <schuffelen@google.com>
Link: https://lore.kernel.org/r/20210318200419.1421034-1-schuffelen@google.com
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
(cherry picked from commit b57aa17f07
https: //git.kernel.org/pub/scm/linux/kernel/git/netdev/net.git master)
Change-Id: Icafc24ad303357926cbe955ffa12e28e0bf31e6f
2021-04-12 20:18:22 -07:00
Carlos Llamas
1dccea76da ANDROID: power_supply: inline empty power_supply_get_by_phandle_array()
The static empty definition of power_supply_get_by_phandle_array(), used
when CONFIG_OF is not set, is missing an inline keyword. This generates
multiple compiler warnings and adds function-call overhead. This patch
inlines the definition to address such issues.

Fixes:
./include/linux/power_supply.h:405:12: warning: ‘power_supply_get_by_phandle_array’ defined but not used [-Wunused-function]
  405 | static int power_supply_get_by_phandle_array(struct device_node *np,
      |            ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Bug: 183339614
Fixes: dea1a925f6 (ANDROID: power_supply: Add a helper function to retrieve psy array from phandle)
Reported-by: kernelci.org bot <bot@kernelci.org>
Signed-off-by: Carlos Llamas <cmllamas@google.com>
Change-Id: I6ad919673d0f649d7701c573196c11795663182d
2021-04-13 00:54:41 +00:00
Elliot Berman
dbbf3a1d16 ANDROID: build.config: Add vmlinux.symvers and modules.builtin to DIST_DIR
Copy vmlinux.symvers and modules.builtin to the DIST_DIR for mixed tree
builds. These files are used by the device kernel to modpost against the
GKI kernel.

These 3 new files add ~300 KB to the DIST_DIR

Bug: 178469391
Change-Id: Ic21a524aac05eafe18925982e860b0be9e6d8728
Signed-off-by: Elliot Berman <eberman@codeaurora.org>
2021-04-12 11:31:31 -07:00
Linus Torvalds
a85f165e1f Merge tag 'drm-fixes-2021-04-10' of git://anongit.freedesktop.org/drm/drm
Pull drm fixes from Dave Airlie:
 "Was relatively quiet this week, but still a few pulls came in, pretty
  much small fixes across the board, a couple of regression fixes in the
  amdgpu/radeon code, msm has a few minor fixes across the board, a
  panel regression fix also.

  amdgpu:
   - DCN3 fix
   - Fix CAC setting regression for TOPAZ
   - Fix ttm regression

  radeon:
   - Fix ttm regression

  msm:
   - a5xx/a6xx timestamp fix
   - microcode version check
   - fail path fix
   - block programming fix
   - error removal fix

  i915:
   - Fix invalid access to ACPI _DSM objects

  xen:
   - Fix use-after-free in xen
   - minor duplicate defintion cleanup

  vc4:
   - Reduce fifo threshold on hvs4 to fix a fifo full error
   - minor redunantant assignment cleanup

  panel:
   - Disable TE support for Droid4 and N950"

* tag 'drm-fixes-2021-04-10' of git://anongit.freedesktop.org/drm/drm:
  drm/vc4: crtc: Reduce PV fifo threshold on hvs4
  drm/vc4: plane: Remove redundant assignment
  drm/amdgpu/smu7: fix CAC setting on TOPAZ
  drm/radeon: Fix size overflow
  drm/amdgpu: Fix size overflow
  drm/i915: Fix invalid access to ACPI _DSM objects
  drm/amd/display: Add missing mask for DCN3
  drm/panel: panel-dsi-cm: disable TE for now
  drm/msm/disp/dpu1: program 3d_merge only if block is attached
  drm/msm: a6xx: fix version check for the A650 SQE microcode
  drm/msm: Fix a5xx/a6xx timestamps
  drm/msm: Fix removal of valid error case when checking speed_bin
  drm/msm: Set drvdata to NULL when msm_drm_init() fails
  drivers: gpu: drm: xen_drm_front_drm_info is declared twice
  gpu/xen: Fix a use after free in xen_drm_drv_init
2021-04-09 12:56:10 -07:00
Dave Airlie
bd119f4712 Merge tag 'drm-intel-fixes-2021-04-09' of git://anongit.freedesktop.org/drm/drm-intel into drm-fixes
- Fix invalid access to ACPI _DSM objects (Takashi)

Signed-off-by: Dave Airlie <airlied@redhat.com>

From: Rodrigo Vivi <rodrigo.vivi@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/YHAW6NInrybUoat6@intel.com
2021-04-10 05:18:35 +10:00
Dave Airlie
d416bd0bf7 Merge tag 'drm-misc-fixes-2021-04-09' of git://anongit.freedesktop.org/drm/drm-misc into drm-fixes
drm-misc-fixes for v5.12-rc7:
- Fix use-after-free in xen.
- Reduce fifo threshold on hvs4 to fix a fifo full error.
- Disable TE support for Droid4 and N950.
- Small compiler fixes.

Signed-off-by: Dave Airlie <airlied@redhat.com>

From: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/e7647dd9-60c3-9dfd-a377-89d717212e13@linux.intel.com
2021-04-10 05:18:10 +10:00
Linus Torvalds
60144b23c9 Merge tag 'selinux-pr-20210409' of git://git.kernel.org/pub/scm/linux/kernel/git/pcmoore/selinux
Pull selinux fixes from Paul Moore:
 "Three SELinux fixes.

  These fix known problems relating to (re)loading SELinux policy or
  changing the policy booleans, and pass our test suite without problem"

* tag 'selinux-pr-20210409' of git://git.kernel.org/pub/scm/linux/kernel/git/pcmoore/selinux:
  selinux: fix race between old and new sidtab
  selinux: fix cond_list corruption when changing booleans
  selinux: make nslot handling in avtab more robust
2021-04-09 11:51:06 -07:00
Alistair Delva
34bddd1701 ANDROID: Build LZ4 ramdisk for rockpi4
Removes an unnecessary difference between GKI.

Bug: 183963484
Change-Id: I4e6e1755b7bf29e842d88829b14fce5b2e0ac120
Signed-off-by: Alistair Delva <adelva@google.com>
2021-04-09 18:15:40 +00:00
Alistair Delva
198ea0e261 ANDROID: Add virtio-rng to rockpi4 qemu modules
This enables the crng to initialize a bit more quickly, which is useful
for testing net tests.

Bug: 183963484
Change-Id: I05bed1a5e22006842c69e74f624c2cb7a435cfdd
Signed-off-by: Alistair Delva <adelva@google.com>
2021-04-09 18:15:34 +00:00
Alistair Delva
1b068ee5f9 ANDROID: rockpi4: Update with probed drivers
Optimize the drivers list for those that are defined in DT, but also
probed on a real device. Sort the modules into groups so we know why
they are pulled in.

Bug: 183963484
Signed-off-by: Alistair Delva <adelva@google.com>
Change-Id: I6edef7df561b46154857ba21424a925eec0e8acf
2021-04-09 18:15:01 +00:00
Linus Torvalds
189fefc7a4 Merge tag 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mst/vhost
Pull vdpa/mlx5 fixes from Michael Tsirkin:
 "Last minute fixes.

  These all look like something we are better off having
  than not ..."

* tag 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mst/vhost:
  vdpa/mlx5: Fix suspend/resume index restoration
  vdpa/mlx5: Fix wrong use of bit numbers
  vdpa/mlx5: Retrieve BAR address suitable any function
  vdpa/mlx5: Use the correct dma device when registering memory
  vdpa/mlx5: should exclude header length and fcs from mtu
2021-04-09 10:09:51 -07:00
Linus Torvalds
3766fcf5d3 Merge tag 'rproc-v5.12-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/andersson/remoteproc
Pull remoteproc fixes from Bjorn Andersson:
 "This fixes an issue with firmware loading on the TI K3 PRU, fixes
  compatibility with GNU binutils for the same and resolves link error
  due to a 64-bit division in the Qualcomm PIL info.

  It also recognizes Mathieu Poirier as co-maintainer of the remoteproc
  and rpmsg subsystems"

* tag 'rproc-v5.12-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/andersson/remoteproc:
  remoteproc: pru: Fix firmware loading crashes on K3 SoCs
  remoteproc: pru: Fix loading of GNU Binutils ELF
  MAINTAINERS: Add co-maintainer for remoteproc/RPMSG subsystems
  remoteproc: qcom: pil_info: avoid 64-bit division
2021-04-09 10:05:25 -07:00
Linus Torvalds
0b76088799 Merge tag 'for-linus-5.12b-rc7-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/xen/tip
Pull xen fix from Juergen Gross:
 "A single fix of a 5.12 patch for the rather uncommon problem of
  running as a Xen guest with a real time kernel config"

* tag 'for-linus-5.12b-rc7-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/xen/tip:
  xen/evtchn: Change irq_info lock to raw_spinlock_t
2021-04-09 09:58:42 -07:00
Linus Torvalds
ccd6c35c72 Merge tag 'acpi-5.12-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm
Pull ACPI fix from Rafael Wysocki:
 "Fix a build issue introduced by a previous fix in the ACPI processor
  driver (Vitaly Kuznetsov)"

* tag 'acpi-5.12-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm:
  ACPI: processor: Fix build when CONFIG_ACPI_PROCESSOR=m
2021-04-09 09:25:31 -07:00
Eli Cohen
bc04d93ea3 vdpa/mlx5: Fix suspend/resume index restoration
When we suspend the VM, the VDPA interface will be reset. When the VM is
resumed again, clear_virtqueues() will clear the available and used
indices resulting in hardware virqtqueue objects becoming out of sync.
We can avoid this function alltogether since qemu will clear them if
required, e.g. when the VM went through a reboot.

Moreover, since the hw available and used indices should always be
identical on query and should be restored to the same value same value
for virtqueues that complete in order, we set the single value provided
by set_vq_state(). In get_vq_state() we return the value of hardware
used index.

Fixes: b35ccebe3e ("vdpa/mlx5: Restore the hardware used index after change map")
Fixes: 1a86b377aa ("vdpa/mlx5: Add VDPA driver for supported mlx5 devices")
Signed-off-by: Eli Cohen <elic@nvidia.com>
Link: https://lore.kernel.org/r/20210408091047.4269-6-elic@nvidia.com
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Acked-by: Jason Wang <jasowang@redhat.com>
2021-04-09 12:08:28 -04:00
Eli Cohen
4b454a8241 vdpa/mlx5: Fix wrong use of bit numbers
VIRTIO_F_VERSION_1 is a bit number. Use BIT_ULL() with mask
conditionals.

Also, in mlx5_vdpa_is_little_endian() use BIT_ULL for consistency with
the rest of the code.

Fixes: 1a86b377aa ("vdpa/mlx5: Add VDPA driver for supported mlx5 devices")
Signed-off-by: Eli Cohen <elic@nvidia.com>
Link: https://lore.kernel.org/r/20210408091047.4269-5-elic@nvidia.com
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Acked-by: Jason Wang <jasowang@redhat.com>
2021-04-09 12:08:27 -04:00
Eli Cohen
b2ae0a2db8 vdpa/mlx5: Retrieve BAR address suitable any function
struct mlx5_core_dev has a bar_addr field that contains the correct bar
address for the function regardless of whether it is pci function or sub
function. Use it.

Fixes: 1958fc2f07 ("net/mlx5: SF, Add auxiliary device driver")
Signed-off-by: Eli Cohen <elic@nvidia.com>
Reviewed-by: Parav Pandit <parav@nvidia.com>
Link: https://lore.kernel.org/r/20210408091047.4269-4-elic@nvidia.com
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Acked-by: Jason Wang <jasowang@redhat.com>
2021-04-09 12:08:27 -04:00
Eli Cohen
d13a15d544 vdpa/mlx5: Use the correct dma device when registering memory
In cases where the vdpa instance uses a SF (sub function), the DMA
device is the parent device. Use a function to retrieve the correct DMA
device.

Fixes: 1958fc2f07 ("net/mlx5: SF, Add auxiliary device driver")
Signed-off-by: Eli Cohen <elic@nvidia.com>
Reviewed-by: Parav Pandit <parav@nvidia.com>
Link: https://lore.kernel.org/r/20210408091047.4269-3-elic@nvidia.com
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Acked-by: Jason Wang <jasowang@redhat.com>
2021-04-09 12:08:27 -04:00
Si-Wei Liu
d084d996aa vdpa/mlx5: should exclude header length and fcs from mtu
When feature VIRTIO_NET_F_MTU is negotiated on mlx5_vdpa,
22 extra bytes worth of MTU length is shown in guest.
This is because the mlx5_query_port_max_mtu API returns
the "hardware" MTU value, which does not just contain the
 Ethernet payload, but includes extra lengths starting
from the Ethernet header up to the FCS altogether.

Fix the MTU so packets won't get dropped silently.

Fixes: 1a86b377aa ("vdpa/mlx5: Add VDPA driver for supported mlx5 devices")
Signed-off-by: Si-Wei Liu <si-wei.liu@oracle.com>
Acked-by: Jason Wang <jasowang@redhat.com>
Acked-by: Eli Cohen <elic@nvidia.com>
Link: https://lore.kernel.org/r/20210408091047.4269-2-elic@nvidia.com
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
2021-04-09 12:08:27 -04:00
Hans de Goede
895915226a Bluetooth: btusb: Revert Fix the autosuspend enable and disable
drivers/usb/core/hub.c: usb_new_device() contains the following:

        /* By default, forbid autosuspend for all devices.  It will be
         * allowed for hubs during binding.
         */
        usb_disable_autosuspend(udev);

So for anything which is not a hub, such as btusb devices, autosuspend is
disabled by default and we must call usb_enable_autosuspend(udev) to
enable it.

This means that the "Fix the autosuspend enable and disable" commit,
which drops the usb_enable_autosuspend() call when the enable_autosuspend
module option is true, is completely wrong, revert it.

This reverts commit 7bd9fb058d.

Cc: Hui Wang <hui.wang@canonical.com>
Fixes: 7bd9fb058d ("Bluetooth: btusb: Fix the autosuspend enable and disable")
Acked-by: Hui Wang <hui.wang@canonical.com>
Acked-by: Marcel Holtmann <marcel@holtmann.org>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2021-04-09 09:08:02 -07:00
Michael Hoyle
0041f84975 ANDROID: Add GKI_HIDDEN_MM_CONFIGS to support ballooning.
Bug: 183227346
Signed-off-by: Michael Hoyle <mikehoyle@google.com>
Change-Id: I67ab3cd12ee5925a941af2509ec1eef1fac07b86
2021-04-09 15:38:31 +00:00
Linus Torvalds
17e7124aad Merge tag '5.12-rc6-smb3' of git://git.samba.org/sfrench/cifs-2.6
Pull cifs fixes from Steve French:
 "Three cifs/smb3 fixes, two for stable: a reconnect fix and a fix for
  display of devnames with special characters"

* tag '5.12-rc6-smb3' of git://git.samba.org/sfrench/cifs-2.6:
  cifs: escape spaces in share names
  fs: cifs: Remove unnecessary struct declaration
  cifs: On cifs_reconnect, resolve the hostname again.
2021-04-08 18:57:47 -07:00
Dave Airlie
2e99cd7a31 Merge tag 'drm-msm-fixes-2021-04-02' of https://gitlab.freedesktop.org/drm/msm into drm-fixes
some more minor fixes:
- a5xx/a6xx timestamp fix
- microcode version check
- fail path fix
- block programming fix
- error removal fix.

Signed-off-by: Dave Airlie <airlied@redhat.com>
From: Rob Clark <robdclark@gmail.com>
Link: https://patchwork.freedesktop.org/patch/msgid/CAF6AEGsMj7Nv3vVaVWMxPy8Y=Z_SnZmVKhKgKDxDYTr9rGN_+w@mail.gmail.com
2021-04-09 10:33:38 +10:00
Linus Torvalds
4fa56ad0d1 Merge tag 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/rdma/rdma
Pull rdma fixes from Jason Gunthorpe:
 "Nothing very exciting here, just a few small bug fixes. No red flags
  for this release have shown up.

   - Regression from the last pull request in cxgb4 related to the ipv6
     fixes

   - KASAN crasher in rtrs

   - oops in hfi1 related to a buggy BIOS

   - Userspace could oops qedr's XRC support

   - Uninitialized memory when parsing a LS_NLA_TYPE_DGID netlink
     message"

* tag 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/rdma/rdma:
  RDMA/addr: Be strict with gid size
  RDMA/qedr: Fix kernel panic when trying to access recv_cq
  IB/hfi1: Fix probe time panic when AIP is enabled with a buggy BIOS
  RDMA/cxgb4: check for ipv6 address properly while destroying listener
  RDMA/rtrs-clt: Close rtrs client conn before destroying rtrs clt session files
2021-04-08 15:51:11 -07:00
Leon Romanovsky
d1c803a9cc RDMA/addr: Be strict with gid size
The nla_len() is less than or equal to 16.  If it's less than 16 then end
of the "gid" buffer is uninitialized.

Fixes: ae43f82867 ("IB/core: Add IP to GID netlink offload")
Link: https://lore.kernel.org/r/20210405074434.264221-1-leon@kernel.org
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Mark Bloch <mbloch@nvidia.com>
Signed-off-by: Leon Romanovsky <leonro@nvidia.com>
Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
2021-04-08 16:14:56 -03:00