Commit Graph

1001834 Commits

Author SHA1 Message Date
Hemant Kumar
43c4cab006 usb: gadget: Fix double free of device descriptor pointers
Upon driver unbind usb_free_all_descriptors() function frees all
speed descriptor pointers without setting them to NULL. In case
gadget speed changes (i.e from super speed plus to super speed)
after driver unbind only upto super speed descriptor pointers get
populated. Super speed plus desc still holds the stale (already
freed) pointer. Fix this issue by setting all descriptor pointers
to NULL after freeing them in usb_free_all_descriptors().

Fixes: f5c61225cf ("usb: gadget: Update function for SuperSpeedPlus")
cc: stable@vger.kernel.org
Reviewed-by: Peter Chen <peter.chen@kernel.org>
Signed-off-by: Hemant Kumar <hemantk@codeaurora.org>
Signed-off-by: Wesley Cheng <wcheng@codeaurora.org>
Link: https://lore.kernel.org/r/1619034452-17334-1-git-send-email-wcheng@codeaurora.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2021-04-22 08:57:48 +02:00
Badhri Jagan Sridharan
374157ff88 usb: typec: tcpm: Fix error while calculating PPS out values
"usb: typec: tcpm: Address incorrect values of tcpm psy for pps supply"
introduced a regression for req_out_volt and req_op_curr calculation.

req_out_volt should consider the newly calculated max voltage instead
of previously accepted max voltage by the port partner. Likewise,
req_op_curr should consider the newly calculated max current instead
of previously accepted max current by the port partner.

Fixes: e3a0720224 ("usb: typec: tcpm: Address incorrect values of tcpm psy for pps supply")
Reviewed-by: Guenter Roeck <linux@roeck-us.net>
Signed-off-by: Badhri Jagan Sridharan <badhri@google.com>
Link: https://lore.kernel.org/r/20210415050121.1928298-1-badhri@google.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2021-04-22 08:57:34 +02:00
Matti Vaittinen
a943d76352 devm-helpers: Fix devm_delayed_work_autocancel() kerneldoc
The kerneldoc for devm_delayed_work_autocancel() contains invalid
parameter description.

Fix the parameter description. And while at it - make it more obvous that
this function operates on delayed_work. That helps differentiating with
resource-managed INIT_WORK description (which should follow in near future)

Fixes: 0341ce5443 ("workqueue: Add resource managed version of delayed work init")
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Matti Vaittinen <matti.vaittinen@fi.rohmeurope.com>
Link: https://lore.kernel.org/r/db3a8b4b8899fdf109a0cc760807de12d3b4f09b.1619028482.git.matti.vaittinen@fi.rohmeurope.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2021-04-22 08:20:15 +02:00
Andy Shevchenko
482715ff06 pinctrl: core: Show pin numbers for the controllers with base = 0
The commit f1b206cf7c ("pinctrl: core: print gpio in pins debugfs file")
enabled GPIO pin number and label in debugfs for pin controller. However,
it limited that feature to the chips where base is positive number. This,
in particular, excluded chips where base is 0 for the historical or backward
compatibility reasons. Refactor the code to include the latter as well.

Fixes: f1b206cf7c ("pinctrl: core: print gpio in pins debugfs file")
Cc: Drew Fustini <drew@beagleboard.org>
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Tested-by: Drew Fustini <drew@beagleboard.org>
Reviewed-by: Drew Fustini <drew@beagleboard.org>
Link: https://lore.kernel.org/r/20210415130356.15885-1-andriy.shevchenko@linux.intel.com
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
2021-04-22 02:13:42 +02:00
James Bottomley
60dc5f1bcf KEYS: trusted: fix TPM trusted keys for generic framework
The generic framework patch broke the current TPM trusted keys because
it doesn't correctly remove the values consumed by the generic parser
before passing them on to the implementation specific parser.  Fix
this by having the generic parser return the string minus the consumed
tokens.

Additionally, there may be no tokens left for the implementation
specific parser, so make it handle the NULL case correctly and finally
fix a TPM 1.2 specific check for no keyhandle.

Fixes: 5d0682be31 ("KEYS: trusted: Add generic trusted keys framework")
Tested-by: Sumit Garg <sumit.garg@linaro.org>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2021-04-21 16:30:06 -07:00
James Bottomley
9d5171eab4 KEYS: trusted: Fix TPM reservation for seal/unseal
The original patch 8c657a0590 ("KEYS: trusted: Reserve TPM for seal
and unseal operations") was correct on the mailing list:

https://lore.kernel.org/linux-integrity/20210128235621.127925-4-jarkko@kernel.org/

But somehow got rebased so that the tpm_try_get_ops() in
tpm2_seal_trusted() got lost.  This causes an imbalanced put of the
TPM ops and causes oopses on TIS based hardware.

This fix puts back the lost tpm_try_get_ops()

Fixes: 8c657a0590 ("KEYS: trusted: Reserve TPM for seal and unseal operations")
Reported-by: Mimi Zohar <zohar@linux.ibm.com>
Acked-by: Mimi Zohar <zohar@linux.ibm.com>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2021-04-21 16:28:20 -07:00
Dan Carpenter
37bd59d3ce platform/x86: intel_pmc_core: Uninitialized data in pmc_core_lpm_latch_mode_write()
The simple_write_to_buffer() can return success if even a single byte
is copied from user space.  In this case it can result in using
uninitalized data if the buf[] array is not fully initialized.  Really
we should only succeed if the whole buffer is copied.

Just using copy_from_user() is simpler and more appropriate.

Fixes: 8074a79fad ("platform/x86: intel_pmc_core: Add option to set/clear LPM mode")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Link: https://lore.kernel.org/r/YIBCf+G9Ef8wrGJw@mwanda
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2021-04-21 21:32:31 +02:00
Linus Torvalds
16fc44d638 MMC host:
- meson-gx: Replace WARN_ONCE with dev_warn_once for non-optimal sg-alignment
 -----BEGIN PGP SIGNATURE-----
 
 iQJLBAABCgA1FiEEugLDXPmKSktSkQsV/iaEJXNYjCkFAmCAIHoXHHVsZi5oYW5z
 c29uQGxpbmFyby5vcmcACgkQ/iaEJXNYjClsBg/7B6BjIC+eWA2I3MiwLrhHzV83
 wz/YcRUGitGAI+K5nCmtiEGJ0rDZA9Y5/suQ7xSigied0YaThdM7jcbjFXMEdZgl
 ut/Fr1R9YZXjHPixDnX5nLF8gdbLFuVJD9Sv3zSQBtb9g7uJL2uS/Z9MFQVND9C5
 Qa2TgJ+MkW8GemBuZWLnU9LQc3/zm1iMSQTR1vMzU1Pr1YRcN7/JZZ5eEp6IC3pw
 GLfal5ebENfzYrOA7aJkIMMNLF6M7FDtwxT+Js7xIJxKLO2bqo5TXYve9jgoqngd
 TGRvcgMIJ38FBtCFUHgiVrWhekEmpF4hXYwP9SGgehM3lFHFD9stegS1gsrq4Zw4
 dgg+YPrlMrXgzxs7qdhXaPlgk+9g7Byql93fDfEZ2Z250WG2YWlLi3qEZqgeYftW
 J6OFOdzzDdUdxJ6f5+KNAj0ATcGQnnkETJdQf6r4F1IMYoC+mTGONiv07xS7Ojyx
 uNWYN1BikkH9l4GdFcbe+2Op5SwtA8NOfjGBEtHR9lCtgjBk4eSJN7Jdn4CR+Giq
 4gPJe4fuHDeqF/+dDAJXKn60m8Lbs4zdHBlPcjSa6TbHAJGZqzU0t98hIbvrPula
 b+VRWVoy23xTSvSEA5YEhQI/n4eC6gS5j4Y1T732sZa0dgzDjyMvr1T/EYLux5lY
 cDxn7eEaJ8/8yh8IXHI=
 =jPnb
 -----END PGP SIGNATURE-----

Merge tag 'mmc-v5.12-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/ulfh/mmc

Pull MMC fix from Ulf Hansson:
 "Replace WARN_ONCE with dev_warn_once for non-optimal sg-alignment in
  the meson-gx host driver"

* tag 'mmc-v5.12-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/ulfh/mmc:
  mmc: meson-gx: replace WARN_ONCE with dev_warn_once about scatterlist size alignment in block mode
2021-04-21 10:22:54 -07:00
Christoph Hellwig
68e6582e8f block: return -EBUSY when there are open partitions in blkdev_reread_part
The switch to go through blkdev_get_by_dev means we now ignore the
return value from bdev_disk_changed in __blkdev_get.  Add a manual
check to restore the old semantics.

Fixes: 4601b4b130 ("block: reopen the device in blkdev_reread_part")
Reported-by: Karel Zak <kzak@redhat.com>
Signed-off-by: Christoph Hellwig <hch@lst.de>
Link: https://lore.kernel.org/r/20210421160502.447418-1-hch@lst.de
Signed-off-by: Jens Axboe <axboe@kernel.dk>
2021-04-21 10:49:37 -06:00
Jiansong Chen
24d034528e drm/amdgpu: fix GCR_GENERAL_CNTL offset for dimgrey_cavefish
dimgrey_cavefish has similar gc_10_3 ip with sienna_cichlid,
so follow its registers offset setting.

Signed-off-by: Jiansong Chen <Jiansong.Chen@amd.com>
Reviewed-by: Tao Zhou <tao.zhou1@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Cc: stable@vger.kernel.org
2021-04-21 11:19:26 -04:00
Simon Ser
9ebb6bc012 amd/display: allow non-linear multi-planar formats
Accept non-linear buffers which use a multi-planar format, as long
as they don't use DCC.

Tested on GFX9 with NV12.

Signed-off-by: Simon Ser <contact@emersion.fr>
Cc: Alex Deucher <alexander.deucher@amd.com>
Cc: Harry Wentland <hwentlan@amd.com>
Cc: Nicholas Kazlauskas <nicholas.kazlauskas@amd.com>
Cc: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Cc: stable@vger.kernel.org
2021-04-21 11:18:10 -04:00
Qingqing Zhuo
6d638b3ffd drm/amd/display: Update modifier list for gfx10_3
[Why]
Current list supports modifiers that have DCC_MAX_COMPRESSED_BLOCK
set to AMD_FMT_MOD_DCC_BLOCK_128B, while AMD_FMT_MOD_DCC_BLOCK_64B
is used instead by userspace.

[How]
Replace AMD_FMT_MOD_DCC_BLOCK_128B with AMD_FMT_MOD_DCC_BLOCK_64B
for modifiers with DCC supported.

Fixes: faa37f54ce ("drm/amd/display: Expose modifiers")
Signed-off-by: Qingqing Zhuo <qingqing.zhuo@amd.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Tested-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Cc: stable@vger.kernel.org
2021-04-21 11:13:13 -04:00
Philip Yang
d42a5b639d drm/amdgpu: reserve fence slot to update page table
Forgot to reserve a fence slot to use sdma to update page table, cause
below kernel BUG backtrace to handle vm retry fault while application is
exiting.

[  133.048143] kernel BUG at /home/yangp/git/compute_staging/kernel/drivers/dma-buf/dma-resv.c:281!
[  133.048487] Workqueue: events amdgpu_irq_handle_ih1 [amdgpu]
[  133.048506] RIP: 0010:dma_resv_add_shared_fence+0x204/0x280
[  133.048672]  amdgpu_vm_sdma_commit+0x134/0x220 [amdgpu]
[  133.048788]  amdgpu_vm_bo_update_range+0x220/0x250 [amdgpu]
[  133.048905]  amdgpu_vm_handle_fault+0x202/0x370 [amdgpu]
[  133.049031]  gmc_v9_0_process_interrupt+0x1ab/0x310 [amdgpu]
[  133.049165]  ? kgd2kfd_interrupt+0x9a/0x180 [amdgpu]
[  133.049289]  ? amdgpu_irq_dispatch+0xb6/0x240 [amdgpu]
[  133.049408]  amdgpu_irq_dispatch+0xb6/0x240 [amdgpu]
[  133.049534]  amdgpu_ih_process+0x9b/0x1c0 [amdgpu]
[  133.049657]  amdgpu_irq_handle_ih1+0x21/0x60 [amdgpu]
[  133.049669]  process_one_work+0x29f/0x640
[  133.049678]  worker_thread+0x39/0x3f0
[  133.049685]  ? process_one_work+0x640/0x640

Signed-off-by: Philip Yang <Philip.Yang@amd.com>
Signed-off-by: Felix Kuehling <Felix.Kuehling@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Cc: stable@vger.kernel.org # 5.11.x
2021-04-21 11:10:35 -04:00
Tony Lindgren
ddd8d94ca3 gpio: omap: Save and restore sysconfig
As we are using cpu_pm to save and restore context, we must also save and
restore the GPIO sysconfig register. This is needed because we are not
calling PM runtime functions at all with cpu_pm.

We need to save the sysconfig on idle as it's value can get reconfigured by
PM runtime and can be different from the init time value. Device specific
flags like "ti,no-idle-on-init" can affect the init value.

Fixes: b764a5863f ("gpio: omap: Remove custom PM calls and use cpu_pm instead")
Cc: Aaro Koskinen <aaro.koskinen@iki.fi>
Cc: Adam Ford <aford173@gmail.com>
Cc: Andreas Kemnade <andreas@kemnade.info>
Cc: Grygorii Strashko <grygorii.strashko@ti.com>
Cc: Peter Ujfalusi <peter.ujfalusi@gmail.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Acked-by: Grygorii Strashko <grygorii.strashko@ti.com>
Signed-off-by: Bartosz Golaszewski <bgolaszewski@baylibre.com>
2021-04-21 16:43:51 +02:00
Arnd Bergmann
f75bf693c9 platform/x86: intel_pmc_core: add ACPI dependency
The driver now fails to build without ACPI:

drivers/platform/x86/intel_pmc_core.c: In function 'pmc_core_get_tgl_lpm_reqs':
drivers/platform/x86/intel_pmc_core.c:617:41: error: invalid use of undefined type 'struct acpi_device'
  617 |         out_obj = acpi_evaluate_dsm(adev->handle, &s0ix_dsm_guid, 0,

This could probably be made optional, but it won't be used without
ACPI in practice, so just add a Kconfig dependency.

Fixes: 428131364f ("platform/x86: intel_pmc_core: Get LPM requirements for Tiger Lake")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Link: https://lore.kernel.org/r/20210421134957.3329062-1-arnd@kernel.org
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2021-04-21 16:11:44 +02:00
Kan Liang
9d480158ee perf/x86/intel/uncore: Remove uncore extra PCI dev HSWEP_PCI_PCU_3
There may be a kernel panic on the Haswell server and the Broadwell
server, if the snbep_pci2phy_map_init() return error.

The uncore_extra_pci_dev[HSWEP_PCI_PCU_3] is used in the cpu_init() to
detect the existence of the SBOX, which is a MSR type of PMON unit.
The uncore_extra_pci_dev is allocated in the uncore_pci_init(). If the
snbep_pci2phy_map_init() returns error, perf doesn't initialize the
PCI type of the PMON units, so the uncore_extra_pci_dev will not be
allocated. But perf may continue initializing the MSR type of PMON
units. A null dereference kernel panic will be triggered.

The sockets in a Haswell server or a Broadwell server are identical.
Only need to detect the existence of the SBOX once.
Current perf probes all available PCU devices and stores them into the
uncore_extra_pci_dev. It's unnecessary.
Use the pci_get_device() to replace the uncore_extra_pci_dev. Only
detect the existence of the SBOX on the first available PCU device once.

Factor out hswep_has_limit_sbox(), since the Haswell server and the
Broadwell server uses the same way to detect the existence of the SBOX.

Add some macros to replace the magic number.

Fixes: 5306c31c57 ("perf/x86/uncore/hsw-ep: Handle systems with only two SBOXes")
Reported-by: Steve Wahl <steve.wahl@hpe.com>
Signed-off-by: Kan Liang <kan.liang@linux.intel.com>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Tested-by: Steve Wahl <steve.wahl@hpe.com>
Link: https://lkml.kernel.org/r/1618521764-100923-1-git-send-email-kan.liang@linux.intel.com
2021-04-21 13:55:39 +02:00
Joseph Salisbury
753ed9c95c drivers: hv: Create a consistent pattern for checking Hyper-V hypercall status
There is not a consistent pattern for checking Hyper-V hypercall status.
Existing code uses a number of variants.  The variants work, but a consistent
pattern would improve the readability of the code, and be more conformant
to what the Hyper-V TLFS says about hypercall status.

Implemented new helper functions hv_result(), hv_result_success(), and
hv_repcomp().  Changed the places where hv_do_hypercall() and related variants
are used to use the helper functions.

Signed-off-by: Joseph Salisbury <joseph.salisbury@microsoft.com>
Reviewed-by: Michael Kelley <mikelley@microsoft.com>
Link: https://lore.kernel.org/r/1618620183-9967-2-git-send-email-joseph.salisbury@linux.microsoft.com
Signed-off-by: Wei Liu <wei.liu@kernel.org>
2021-04-21 09:49:19 +00:00
Joseph Salisbury
6523592cee x86/hyperv: Move hv_do_rep_hypercall to asm-generic
This patch makes no functional changes.  It simply moves hv_do_rep_hypercall()
out of arch/x86/include/asm/mshyperv.h and into asm-generic/mshyperv.h

hv_do_rep_hypercall() is architecture independent, so it makes sense that it
should be in the architecture independent mshyperv.h, not in the x86-specific
mshyperv.h.

This is done in preperation for a follow up patch which creates a consistent
pattern for checking Hyper-V hypercall status.

Signed-off-by: Joseph Salisbury <joseph.salisbury@microsoft.com>
Reviewed-by: Michael Kelley <mikelley@microsoft.com>
Link: https://lore.kernel.org/r/1618620183-9967-1-git-send-email-joseph.salisbury@linux.microsoft.com
Signed-off-by: Wei Liu <wei.liu@kernel.org>
2021-04-21 09:49:19 +00:00
Linus Torvalds
1fe5501ba1 tracing: Fix tp_printk command line and trace events
Masami added a wrapper to be able to unhash trace event pointers
 as they are only read by root anyway, and they can also be extracted
 by the raw trace data buffers. But this wrapper utilized the iterator
 to have a temporary buffer to manipulate the text with.
 
 tp_printk is a kernel command line option that will send the trace
 output of a trace event to the console on boot up (useful when the
 system crashes before finishing the boot). But the code used the same
 wrapper that Masami added, and its iterator did not have a buffer,
 and this caused the system to crash.
 
 Have the wrapper just print the trace event normally if the iterator
 has no temporary buffer.
 -----BEGIN PGP SIGNATURE-----
 
 iIoEABYIADIWIQRRSw7ePDh/lE+zeZMp5XQQmuv6qgUCYH8exRQccm9zdGVkdEBn
 b29kbWlzLm9yZwAKCRAp5XQQmuv6qlvdAP436vts0GOM8UM0y9IAPNrSG5OSvjNe
 v5C5UOpnIxjlrgEArBtLLDaByLSBDQj+Vx0LmDW5uMOps49mo3A35TcIEAM=
 =GfL1
 -----END PGP SIGNATURE-----

Merge tag 'trace-v5.12-rc8' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace

Pull tracing fix from Steven Rostedt:
 "Fix tp_printk command line and trace events

  Masami added a wrapper to be able to unhash trace event pointers as
  they are only read by root anyway, and they can also be extracted by
  the raw trace data buffers. But this wrapper utilized the iterator to
  have a temporary buffer to manipulate the text with.

  tp_printk is a kernel command line option that will send the trace
  output of a trace event to the console on boot up (useful when the
  system crashes before finishing the boot). But the code used the same
  wrapper that Masami added, and its iterator did not have a buffer, and
  this caused the system to crash.

  Have the wrapper just print the trace event normally if the iterator
  has no temporary buffer"

* tag 'trace-v5.12-rc8' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace:
  tracing: Fix checking event hash pointer logic when tp_printk is enabled
2021-04-20 14:38:35 -07:00
Serge E. Hallyn
db2e718a47 capabilities: require CAP_SETFCAP to map uid 0
cap_setfcap is required to create file capabilities.

Since commit 8db6c34f1d ("Introduce v3 namespaced file capabilities"),
a process running as uid 0 but without cap_setfcap is able to work
around this as follows: unshare a new user namespace which maps parent
uid 0 into the child namespace.

While this task will not have new capabilities against the parent
namespace, there is a loophole due to the way namespaced file
capabilities are represented as xattrs.  File capabilities valid in
userns 1 are distinguished from file capabilities valid in userns 2 by
the kuid which underlies uid 0.  Therefore the restricted root process
can unshare a new self-mapping namespace, add a namespaced file
capability onto a file, then use that file capability in the parent
namespace.

To prevent that, do not allow mapping parent uid 0 if the process which
opened the uid_map file does not have CAP_SETFCAP, which is the
capability for setting file capabilities.

As a further wrinkle: a task can unshare its user namespace, then open
its uid_map file itself, and map (only) its own uid.  In this case we do
not have the credential from before unshare, which was potentially more
restricted.  So, when creating a user namespace, we record whether the
creator had CAP_SETFCAP.  Then we can use that during map_write().

With this patch:

1. Unprivileged user can still unshare -Ur

   ubuntu@caps:~$ unshare -Ur
   root@caps:~# logout

2. Root user can still unshare -Ur

   ubuntu@caps:~$ sudo bash
   root@caps:/home/ubuntu# unshare -Ur
   root@caps:/home/ubuntu# logout

3. Root user without CAP_SETFCAP cannot unshare -Ur:

   root@caps:/home/ubuntu# /sbin/capsh --drop=cap_setfcap --
   root@caps:/home/ubuntu# /sbin/setcap cap_setfcap=p /sbin/setcap
   unable to set CAP_SETFCAP effective capability: Operation not permitted
   root@caps:/home/ubuntu# unshare -Ur
   unshare: write failed /proc/self/uid_map: Operation not permitted

Note: an alternative solution would be to allow uid 0 mappings by
processes without CAP_SETFCAP, but to prevent such a namespace from
writing any file capabilities.  This approach can be seen at [1].

Background history: commit 95ebabde38 ("capabilities: Don't allow
writing ambiguous v3 file capabilities") tried to fix the issue by
preventing v3 fscaps to be written to disk when the root uid would map
to the same uid in nested user namespaces.  This led to regressions for
various workloads.  For example, see [2].  Ultimately this is a valid
use-case we have to support meaning we had to revert this change in
3b0c2d3eaa ("Revert 95ebabde38 ("capabilities: Don't allow writing
ambiguous v3 file capabilities")").

Link: https://git.kernel.org/pub/scm/linux/kernel/git/sergeh/linux.git/log/?h=2021-04-15/setfcap-nsfscaps-v4 [1]
Link: https://github.com/containers/buildah/issues/3071 [2]
Signed-off-by: Serge Hallyn <serge@hallyn.com>
Reviewed-by: Andrew G. Morgan <morgan@kernel.org>
Tested-by: Christian Brauner <christian.brauner@ubuntu.com>
Reviewed-by: Christian Brauner <christian.brauner@ubuntu.com>
Tested-by: Giuseppe Scrivano <gscrivan@redhat.com>
Cc: Eric Biederman <ebiederm@xmission.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2021-04-20 14:28:33 -07:00
Michael Kelley
aa5b7d11c7 video: hyperv_fb: Add ratelimit on error message
Due to a full ring buffer, the driver may be unable to send updates to
the Hyper-V host.  But outputing the error message can make the problem
worse because console output is also typically written to the frame
buffer.  As a result, in some circumstances the error message is output
continuously.

Break the cycle by rate limiting the error message.  Also output
the error code for additional diagnosability.

Signed-off-by: Michael Kelley <mikelley@microsoft.com>
Link: https://lore.kernel.org/r/1618933459-10585-1-git-send-email-mikelley@microsoft.com
Signed-off-by: Wei Liu <wei.liu@kernel.org>
2021-04-20 19:48:15 +00:00
Michael Kelley
77db0ec8b7 Drivers: hv: vmbus: Increase wait time for VMbus unload
When running in Azure, disks may be connected to a Linux VM with
read/write caching enabled. If a VM panics and issues a VMbus
UNLOAD request to Hyper-V, the response is delayed until all dirty
data in the disk cache is flushed.  In extreme cases, this flushing
can take 10's of seconds, depending on the disk speed and the amount
of dirty data. If kdump is configured for the VM, the current 10 second
timeout in vmbus_wait_for_unload() may be exceeded, and the UNLOAD
complete message may arrive well after the kdump kernel is already
running, causing problems.  Note that no problem occurs if kdump is
not enabled because Hyper-V waits for the cache flush before doing
a reboot through the BIOS/UEFI code.

Fix this problem by increasing the timeout in vmbus_wait_for_unload()
to 100 seconds. Also output periodic messages so that if anyone is
watching the serial console, they won't think the VM is completely
hung.

Fixes: 911e1987ef ("Drivers: hv: vmbus: Add timeout to vmbus_wait_for_unload")
Signed-off-by: Michael Kelley <mikelley@microsoft.com>
Reviewed-by: Vitaly Kuznetsov <vkuznets@redhat.com>
Link: https://lore.kernel.org/r/1618894089-126662-1-git-send-email-mikelley@microsoft.com
Signed-off-by: Wei Liu <wei.liu@kernel.org>
2021-04-20 19:41:33 +00:00
Andrea Parri (Microsoft)
8c2d5e0640 Drivers: hv: vmbus: Initialize unload_event statically
If a malicious or compromised Hyper-V sends a spurious message of type
CHANNELMSG_UNLOAD_RESPONSE, the function vmbus_unload_response() will
call complete() on an uninitialized event, and cause an oops.

Reported-by: Michael Kelley <mikelley@microsoft.com>
Signed-off-by: Andrea Parri (Microsoft) <parri.andrea@gmail.com>
Reviewed-by: Michael Kelley <mikelley@microsoft.com>
Link: https://lore.kernel.org/r/20210420014350.2002-1-parri.andrea@gmail.com
Signed-off-by: Wei Liu <wei.liu@kernel.org>
2021-04-20 19:40:17 +00:00
Zhen Lei
f2211881e7 perf data: Fix error return code in perf_data__create_dir()
Although 'ret' has been initialized to -1, but it will be reassigned by
the "ret = open(...)" statement in the for loop. So that, the value of
'ret' is unknown when asprintf() failed.

Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Zhen Lei <thunder.leizhen@huawei.com>
Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Mark Rutland <mark.rutland@arm.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Link: http://lore.kernel.org/lkml/20210415083417.3740-1-thunder.leizhen@huawei.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
2021-04-20 14:46:48 -03:00
Mike Galbraith
5849cdf8c1 x86/crash: Fix crash_setup_memmap_entries() out-of-bounds access
Commit in Fixes: added support for kexec-ing a kernel on panic using a
new system call. As part of it, it does prepare a memory map for the new
kernel.

However, while doing so, it wrongly accesses memory it has not
allocated: it accesses the first element of the cmem->ranges[] array in
memmap_exclude_ranges() but it has not allocated the memory for it in
crash_setup_memmap_entries(). As KASAN reports:

  BUG: KASAN: vmalloc-out-of-bounds in crash_setup_memmap_entries+0x17e/0x3a0
  Write of size 8 at addr ffffc90000426008 by task kexec/1187

  (gdb) list *crash_setup_memmap_entries+0x17e
  0xffffffff8107cafe is in crash_setup_memmap_entries (arch/x86/kernel/crash.c:322).
  317                                      unsigned long long mend)
  318     {
  319             unsigned long start, end;
  320
  321             cmem->ranges[0].start = mstart;
  322             cmem->ranges[0].end = mend;
  323             cmem->nr_ranges = 1;
  324
  325             /* Exclude elf header region */
  326             start = image->arch.elf_load_addr;
  (gdb)

Make sure the ranges array becomes a single element allocated.

 [ bp: Write a proper commit message. ]

Fixes: dd5f726076 ("kexec: support for kexec on panic using new system call")
Signed-off-by: Mike Galbraith <efault@gmx.de>
Signed-off-by: Borislav Petkov <bp@suse.de>
Reviewed-by: Dave Young <dyoung@redhat.com>
Cc: <stable@vger.kernel.org>
Link: https://lkml.kernel.org/r/725fa3dc1da2737f0f6188a1a9701bead257ea9d.camel@gmx.de
2021-04-20 17:32:46 +02:00
Dan Carpenter
366f0a30c8 platform/surface: aggregator: fix a bit test
The "funcs" variable is a u64.  If "func" is more than 31 then the
BIT() shift will wrap instead of testing the high bits.

Fixes: c167b9c7e3 ("platform/surface: Add Surface Aggregator subsystem")
Reported-by: kernel test robot <lkp@intel.com>
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Reviewed-by: Maximilian Luz <luzmaximilian@gmail.com>
Link: https://lore.kernel.org/r/YH6UUhJhGk3mk13b@mwanda
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2021-04-20 17:28:42 +02:00
Hans de Goede
dd5566d6d8 platform/x86: intel_pmc_core: Fix "unsigned 'ret' is never less than zero" smatch warning
Change the type of ret form a size_t to a ssize_t, matching the prototype
of simple_write_to_buffer(), fixing this warning reported by smatch:

drivers/platform/x86/intel_pmc_core.c:1369 pmc_core_lpm_latch_mode_write() warn: unsigned 'ret' is never less than zero.

Fixes: 8074a79fad ("platform/x86: intel_pmc_core: Add option to set/clear LPM mode")
Cc: David E. Box <david.e.box@linux.intel.com>
Reported-by: kernel test robot <lkp@intel.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Link: https://lore.kernel.org/r/20210419143109.30612-1-hdegoede@redhat.com
2021-04-20 17:01:48 +02:00
Steven Rostedt (VMware)
0e1e71d349 tracing: Fix checking event hash pointer logic when tp_printk is enabled
Pointers in events that are printed are unhashed if the flags allow it,
and the logic to do so is called before processing the event output from
the raw ring buffer. In most cases, this is done when a user reads one of
the trace files.

But if tp_printk is added on the kernel command line, this logic is done
for trace events when they are triggered, and their output goes out via
printk. The unhash logic (and even the validation of the output) did not
support the tp_printk output, and would crash.

Link: https://lore.kernel.org/linux-tegra/9835d9f1-8d3a-3440-c53f-516c2606ad07@nvidia.com/

Fixes: efbbdaa22b ("tracing: Show real address for trace event arguments")
Reported-by: Jon Hunter <jonathanh@nvidia.com>
Tested-by: Jon Hunter <jonathanh@nvidia.com>
Signed-off-by: Steven Rostedt (VMware) <rostedt@goodmis.org>
2021-04-20 10:56:58 -04:00
Rodrigo Vivi
2d292995bb Merge tag 'gvt-fixes-2021-04-20' of https://github.com/intel/gvt-linux into drm-intel-fixes
gvt-fixes-2021-04-20

- Fix cmd parser regression on BDW (Zhenyu)

Signed-off-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
From: Zhenyu Wang <zhenyuw@linux.intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20210420023312.GL1551@zhen-hp.sh.intel.com
2021-04-20 09:41:32 -04:00
Arnd Bergmann
d028b508c1 BMC device tree updates for 5.13, round two
- Fixes to the first pull request for Rainier
 
  - Small changes for Rainier, EthanolX and Tiogapass
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCAAdFiEE+nHMAt9PCBDH63wBa3ZZB4FHcJ4FAmB4/7QACgkQa3ZZB4FH
 cJ6K0Q//aIMOK9lM1hVVHO8IkytxR03XF0yQX1pTCZf6h5y9pwuwkGi1Ahi7hNjk
 T/PHMJQ74nDc/uGJVLxNdbyEokUv8sKjhMup7nuzqpr46wuYlAnI8V1gnYwJ3OtN
 MsbUMP0NkVqxVZ7rtclzgCuDqU4C4fs7OAingEykNWhGWUHZCKyv0qwGyztUmpQx
 O+WpJxn0YrvFMotW3ruru/kEWki6R08kAF9K/gM402xKIwgypsOGhhUbl8lPHmO5
 AmjQv8YtZriJHIBL+QDUa2w8IlX89JgXipLUHgVIb99yn78wKjC6cse/GtIt2vrO
 JoDQujW/cz/RyIk4b8V3RefrrqPer/YeoapsgikfaWOSvmJ0+f/zsvgWM+sZ7UAq
 eR9R1YODoZVwNujyxFOiVgflJbzm3SMoBmSs/QnJKbIMtZ3+FQW0poFcI4UTkwMk
 ne8RcDsHdB5JAwgQ5HuAO7YRVbCxoFYhBe8OkFFA/Adito01y/vneVDR2R5UpNHH
 WOfzvACT0xVEOHSgAKGt2CjsTSdC4DrGzNyDQ2Y3VggdD+UUKeKlceYRlvgWSmRO
 9KUAFsSX4hBP8OOxI21N/UJ1m5w8jnWmYdbp2jZRv9rg7lWg+NSSIMr8oSy7KvNJ
 jf5eie2ZbIDZmvwS7v/vcdFN292vyQjkRmmMlhIbaOz/Ay8avFg=
 =lEfd
 -----END PGP SIGNATURE-----

Merge tag 'bmc-5.13-devicetree-2' of git://git.kernel.org/pub/scm/linux/kernel/git/joel/bmc into arm/dt

BMC device tree updates for 5.13, round two

 - Fixes to the first pull request for Rainier

 - Small changes for Rainier, EthanolX and Tiogapass

* tag 'bmc-5.13-devicetree-2' of git://git.kernel.org/pub/scm/linux/kernel/git/joel/bmc:
  ARM: dts: aspeed: tiogapass: add hotplug controller
  ARM: dts: aspeed: amd-ethanolx: Enable all used I2C busses
  ARM: dts: aspeed: Rainier: Update to pass 2 hardware
  ARM: dts: aspeed: Rainier 1S4U: Fix fan nodes
  ARM: dts: aspeed: Rainier: Fix humidity sensor bus address
  ARM: dts: aspeed: Rainier: Fix PCA9552 on bus 8

Link: https://lore.kernel.org/r/CACPK8XeJdHmxyJn43Ju5hmxJ7+rJgHmx=ANFaL17YUmp+gOtJg@mail.gmail.com
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2021-04-20 11:20:56 +02:00
Ingo Molnar
27743f01e3 x86/platform/uv: Remove dead !CONFIG_KEXEC_CORE code
The !CONFIG_KEXEC_CORE code in arch/x86/platform/uv/uv_nmi.c was unused, untested
and didn't even build for 7 years. Since we fixed this by requiring X86_UV to
depend on CONFIG_KEXEC_CORE, remove the (now) dead code.

Also move the uv_nmi_kexec_failed definition back up to where the other file-scope
global variables are defined.

Signed-off-by: Ingo Molnar <mingo@kernel.org>
Cc: Mike Travis <travis@sgi.com>
Cc: linux-kernel@vger.kernel.org
2021-04-20 10:08:34 +02:00
Ingo Molnar
c2209ea556 x86/platform/uv: Fix !KEXEC build failure
When KEXEC is disabled, the UV build fails:

  arch/x86/platform/uv/uv_nmi.c:875:14: error: ‘uv_nmi_kexec_failed’ undeclared (first use in this function)

Since uv_nmi_kexec_failed is only defined in the KEXEC_CORE #ifdef branch,
this code cannot ever have been build tested:

	if (main)
		pr_err("UV: NMI kdump: KEXEC not supported in this kernel\n");
	atomic_set(&uv_nmi_kexec_failed, 1);

Nor is this use possible in uv_handle_nmi():

                atomic_set(&uv_nmi_kexec_failed, 0);

These bugs were introduced in this commit:

    d0a9964e98: ("x86/platform/uv: Implement simple dump failover if kdump fails")

Which added the uv_nmi_kexec_failed assignments to !KEXEC code, while making the
definition KEXEC-only - apparently without testing the !KEXEC case.

Instead of complicating the #ifdef maze, simplify the code by requiring X86_UV
to depend on KEXEC_CORE. This pattern is present in other architectures as well.

( We'll remove the untested, 7 years old !KEXEC complications from the file in a
  separate commit. )

Fixes: d0a9964e98: ("x86/platform/uv: Implement simple dump failover if kdump fails")
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Cc: Mike Travis <travis@sgi.com>
Cc: linux-kernel@vger.kernel.org
2021-04-20 10:08:23 +02:00
Linus Torvalds
7af0814097 Revert "gcov: clang: fix clang-11+ build"
This reverts commit 04c53de57c.

Nathan Chancellor points out that it should not have been merged into
mainline by itself. It was a fix for "gcov: use kvmalloc()", which is
still in -mm/-next. Merging it alone has broken the build.

Link: https://github.com/ClangBuiltLinux/continuous-integration2/runs/2384465683?check_suite_focus=true
Reported-by: Nathan Chancellor <nathan@kernel.org>
Cc: Johannes Berg <johannes.berg@intel.com>
Cc: Nick Desaulniers <ndesaulniers@google.com>
Cc: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2021-04-19 15:08:49 -07:00
Imre Deak
d2b9935d65 drm/i915: Fix modesetting in case of unexpected AUX timeouts
In case AUX failures happen unexpectedly during a modeset, the driver
should still complete the modeset. In particular the driver should
perform the link training sequence steps even in case of an AUX failure,
as this sequence also includes port initialization steps. Not doing that
can leave the port/pipe in a broken state and lead for instance to a
flip done timeout.

Fix this by continuing with link training (in a no-LTTPR mode) if the
DPRX DPCD readout failed for some reason at the beginning of link
training. After a successful connector detection we already have the
DPCD read out and cached, so the failed repeated read for it should not
cause a problem. Note that a partial AUX read could in theory partly
overwrite the cached DPCD (and return error) but this overwrite should
not happen if the returned values are corrupted (due to a timeout or
some other IO error).

Kudos to Ville to root cause the problem.

Fixes: 7dffbdedb9 ("drm/i915: Disable LTTPR support when the DPCD rev < 1.4")
References: https://gitlab.freedesktop.org/drm/intel/-/issues/3308
Cc: stable@vger.kernel.org # 5.11
Cc: Ville Syrjälä <ville.syrjala@linux.intel.com>
Signed-off-by: Imre Deak <imre.deak@intel.com>
Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20210412232413.2755054-1-imre.deak@intel.com
(cherry picked from commit e42e7e5859)
Signed-off-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
[adjusted Fixes: tag]
2021-04-19 14:12:17 -04:00
Zhouyi Zhou
0c89d87d1d preempt/dynamic: Fix typo in macro conditional statement
Commit 40607ee97e ("preempt/dynamic: Provide irqentry_exit_cond_resched()
static call") tried to provide irqentry_exit_cond_resched() static call
in irqentry_exit, but has a typo in macro conditional statement.

Fixes: 40607ee97e ("preempt/dynamic: Provide irqentry_exit_cond_resched() static call")
Signed-off-by: Zhouyi Zhou <zhouzhouyi@gmail.com>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Link: https://lkml.kernel.org/r/20210410073523.5493-1-zhouzhouyi@gmail.com
2021-04-19 20:02:57 +02:00
Arnd Bergmann
028a1e9684 Qualcomm ARM defconfig updates for 5.13
This enables all the hardware support currently available for the
 Qualcomm SDX55 platform in the qcom_defconfig. Due to (current) size
 limitations these changes are not done in the multi-platform config.
 -----BEGIN PGP SIGNATURE-----
 
 iQJPBAABCAA5FiEEBd4DzF816k8JZtUlCx85Pw2ZrcUFAmB9n+kbHGJqb3JuLmFu
 ZGVyc3NvbkBsaW5hcm8ub3JnAAoJEAsfOT8Nma3F8qkQAL0syIPATWbDK7pjhFde
 LNF4DuiFYCHgZGUmypYgBsFrVhP6hk0FtWGzxA9GhCi8Ycje7Go3VpA6dcGMP73y
 jfz8ZeXAEu/HHtYcqibB/yVxrs6FUhd5wHdoaqHTaXLgBmCnJ3gqvziqH/xafy4Q
 6cYqjtzW03ylizPkEb8qJy8Ilx+NTFRHIKj4QvvFohwkce4RCjoc1xBd8weDbuBY
 LY9hewyq0U0X9CPTcxoMhtbVPkURU53/rASkznr5uF1v0nnu+KnbN/N9f1xSz8yq
 7kTgJDzUha9QAj65GqqmilVogEnsxjXds+FciJZ2qJCr0NGnQj01ULSCy7X+hBdb
 s2FmnP4n5vGzUOnYkdsK80El8YG84Nb1lw3MJAe3fRIEMPy6Zw/H6KJf0k79a5wi
 M6EvniqWg/XWyiSIX2SGW4IXvP3sPgNEMMOi95P1M9mLzExtbqvwZluL5PmiGK8x
 o9eVu4nl0ZHaEQhItl6uKN9xFn+qzM6gRueQMZ9WSot851UAwmOQBZvjHe3Y1TVQ
 fKQfeKaa5KsSifKTZ+LB2nfZpl2BTfLR7pDPva9i6kNt/stSwAhUgjvzPyTpIQAF
 qHrJdE5BkSjfeTgyGhBkEK7YPsvCHHk4RlgS6Ry9Wr+tGcw/NEe4qaqQgO6V5Jty
 o3wQtL4EjqTCjq1uHT2m6DHF
 =9z1j
 -----END PGP SIGNATURE-----

Merge tag 'qcom-defconfig-for-5.13' of git://git.kernel.org/pub/scm/linux/kernel/git/qcom/linux into arm/defconfig

Qualcomm ARM defconfig updates for 5.13

This enables all the hardware support currently available for the
Qualcomm SDX55 platform in the qcom_defconfig. Due to (current) size
limitations these changes are not done in the multi-platform config.

* tag 'qcom-defconfig-for-5.13' of git://git.kernel.org/pub/scm/linux/kernel/git/qcom/linux:
  ARM: configs: qcom_defconfig: Reduce CMA size to 64MB
  ARM: configs: qcom_defconfig: Enable GLINK SMEM driver
  ARM: configs: qcom_defconfig: Enable SDX55 interconnect driver
  ARM: configs: qcom_defconfig: Enable Q6V5_PAS remoteproc driver
  ARM: configs: qcom_defconfig: Enable CPUFreq support
  ARM: configs: qcom_defconfig: Enable SDX55 A7 PLL and APCS clock driver
  ARM: configs: qcom_defconfig: Enable APCS IPC mailbox driver

Link: https://lore.kernel.org/r/20210419152143.861934-1-bjorn.andersson@linaro.org
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2021-04-19 17:39:12 +02:00
Arnd Bergmann
a85a8d52bf Even more Qualcomm ARM64 updates for v5.13
This contains three audio related fixes for the sc7180 Trogdor devices.
 -----BEGIN PGP SIGNATURE-----
 
 iQJPBAABCAA5FiEEBd4DzF816k8JZtUlCx85Pw2ZrcUFAmB9npMbHGJqb3JuLmFu
 ZGVyc3NvbkBsaW5hcm8ub3JnAAoJEAsfOT8Nma3Fn0QQAJXtkbYx09JwzQ8gOfl0
 jPt8iyJuqW+HxpyCKmsHzpwj+kpCSi54XJIfyfFSfvSnIZM4viJ4nTpMsYw9OpYi
 QPsx5nnUahIvJcwPz5RJ+E7EFfhD0wDXy4QtQF0a3bDgZ+2Y+1EPWcV/lP6qoXkW
 ds/dsz/JsuqAAjjydPjSeFfqI6yxWelwCz52Zj0uSqjVJR90EjSj6JmIF9FTMHHM
 RuXK6MinvKLeDn2sxNYy+uVu7XuEKMU5y/YzDkPgq+h8NVwYWMAmMRhjhICfWH5G
 rBHSiFLNxqz8X5/Hb+R4AS4sBfhTZ92YcJT9HAYCrlI3yRwNw4CtUaQQud25SC0g
 mdQsMqffDGCedJcHijCURVTUHXVjgahOO1p321zS7R2JJpYz8jP3ZSC81pCwTPK1
 9dtMGEQNXdThUuVoh8iDjCSK0y6zCb21eEU50g/rkkWyIab6xZTa2ZZATRCzTW2z
 8+2bnfaLCHKor5b6iXd6cDFQU/ihx1oxoRSb6av34+r7uo7Yh+FJsNUjl9w2FLSJ
 aRmOBDWoi5uf5/+XpfXD/OKJYCtS8aZ9sxJpfAjLviv9R2FcOMmu1pCJ1os7g1zR
 HmROEwMf0pgtOMshQLutxgid4cvI1neml/lR8FrgqSBhL11oSWDQtzV9Jvyi+aVk
 psSIbQyNcQQL6n2CbRwPt3wb
 =LhLX
 -----END PGP SIGNATURE-----

Merge tag 'qcom-arm64-for-5.13-3' of git://git.kernel.org/pub/scm/linux/kernel/git/qcom/linux into arm/dt

Even more Qualcomm ARM64 updates for v5.13

This contains three audio related fixes for the sc7180 Trogdor devices.

* tag 'qcom-arm64-for-5.13-3' of git://git.kernel.org/pub/scm/linux/kernel/git/qcom/linux:
  arm64: dts: qcom: sc7180: Update iommu property for simultaneous playback
  arm64: dts: qcom: sc7180: pompom: Add "dmic_clk_en" + sound model
  arm64: dts: qcom: sc7180: coachz: Add "dmic_clk_en"

Link: https://lore.kernel.org/r/20210419151637.861409-1-bjorn.andersson@linaro.org
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2021-04-19 17:37:38 +02:00
Arnd Bergmann
6417554e3d More Qualcomm DTS updates for 5.13
This adds CPUfreq, interconnect providers, IPC, remoteproc and IPA to
 the SDX55 platform and then adds board files for the Telit FN980 TLB and
 Thundercomm TurboX T55.
 -----BEGIN PGP SIGNATURE-----
 
 iQJPBAABCAA5FiEEBd4DzF816k8JZtUlCx85Pw2ZrcUFAmB9l7UbHGJqb3JuLmFu
 ZGVyc3NvbkBsaW5hcm8ub3JnAAoJEAsfOT8Nma3F7AcQANfA0up7/3fv7nEsKk58
 53bkx48h8I6OdalXpejqZmIJjd9muuGPVJJfiZcQ3tn0r7ePnFgRHmUTXgfBJNPt
 xS9ZdsRH5o3897uc9AQB6j7oiALfbiUWLrrrBeLLrU4LIoBBsHcoZI0HORaXClaE
 gaBJdCVHSrasLLOkqYxLSquP3jwj4BEnmiXx1kuA4Y9BPuMaACby6083FtIHIg74
 JQ2tZNGle+bs/0qPvPJg/AGKOwH15NO4TW/Z5trErI62gBqSGe3RzIG2V4nvN7kr
 FvmAwYG+mvqIyUv5FybMU5xyb3GSqEA66zsm9927oJdGL31CKV3RmjKy1+Mpfqhd
 erD5ZzWCfidIow9QDZGyRMigFaGwWvkdBUPSnuuOVIYJVgYY/pvV5ErC4CgBAWm8
 EYvtvv87oEyJPA7hjAvIdqybn4FfTxqffDON+ZEcVo2CvotxXjEvffWFxY8+pJre
 tbLhhNYIKz/0IYBbCkMOvcTCbgRePEBdZPCDgPM3ktBCqoBhAwQ37PsZ/z6l+QHe
 /YM4+AYrtcKNOjOBvYTEgX9ZHMcmWpviYcFoFu2sM/Lmb5e5/5zWj7umQfoUMNqs
 JL8XKjnNUnoXMVd61keXoeGHSPQNeb/qYeZWkdzJ7E/MUCSV4WlDS9mhB2vCp6yq
 3nxzk7vZo4fdaAC3YORj3NmU
 =f0HR
 -----END PGP SIGNATURE-----

Merge tag 'qcom-dts-for-5.13-2' of git://git.kernel.org/pub/scm/linux/kernel/git/qcom/linux into arm/dt

More Qualcomm DTS updates for 5.13

This adds CPUfreq, interconnect providers, IPC, remoteproc and IPA to
the SDX55 platform and then adds board files for the Telit FN980 TLB and
Thundercomm TurboX T55.

* tag 'qcom-dts-for-5.13-2' of git://git.kernel.org/pub/scm/linux/kernel/git/qcom/linux:
  ARM: dts: qcom: sdx55: add IPA information
  ARM: dts: qcom: sdx55: Add basic devicetree support for Thundercomm T55
  dt-bindings: arm: qcom: Add binding for Thundercomm T55 kit
  ARM: dts: qcom: sdx55: Add basic devicetree support for Telit FN980 TLB
  dt-bindings: arm: qcom: Add binding for Telit FN980 TLB board
  ARM: dts: qcom: sdx55: Add Modem remoteproc node
  ARM: dts: qcom: Fix node name for NAND controller node
  ARM: dts: qcom: sdx55: Add interconnect nodes
  ARM: dts: qcom: sdx55: Add SCM node
  dt-bindings: firmware: scm: Add compatible for SDX55
  ARM: dts: qcom: sdx55: Add IMEM and PIL info region
  ARM: dts: qcom: sdx55: Add modem SMP2P node
  ARM: dts: qcom: sdx55: Add CPUFreq support
  ARM: dts: qcom: sdx55: Add support for APCS block
  ARM: dts: qcom: sdx55: Add support for A7 PLL clock

Link: https://lore.kernel.org/r/20210419150956.860423-1-bjorn.andersson@linaro.org
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2021-04-19 17:15:50 +02:00
V Sujith Kumar Reddy
1b86cc7330 arm64: dts: qcom: sc7180: Update iommu property for simultaneous playback
Update iommu property in lpass cpu node for supporting
simultaneous playback on headset and speaker.

Reviewed-by: Stephen Boyd <swboyd@chromium.org>
Signed-off-by: V Sujith Kumar Reddy <vsujithk@codeaurora.org>
Signed-off-by: Srinivasa Rao Mandadapu <srivasam@codeaurora.org>
Link: https://lore.kernel.org/r/20210406163330.11996-1-srivasam@codeaurora.org
Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
2021-04-19 10:13:30 -05:00
Douglas Anderson
108ec20b8c arm64: dts: qcom: sc7180: pompom: Add "dmic_clk_en" + sound model
Match what's downstream for this board.

Reviewed-by: Matthias Kaehlcke <mka@chromium.org>
Reviewed-by: Stephen Boyd <swboyd@chromium.org>
Cc: Srinivasa Rao Mandadapu <srivasam@codeaurora.org>
Cc: Ajit Pandey <ajitp@codeaurora.org>
Cc: Judy Hsiao <judyhsiao@chromium.org>
Cc: Cheng-Yi Chiang <cychiang@chromium.org>
Cc: Stephen Boyd <swboyd@chromium.org>
Cc: Matthias Kaehlcke <mka@chromium.org>
Signed-off-by: Douglas Anderson <dianders@chromium.org>
Link: https://lore.kernel.org/r/20210315133924.v2.2.If218189eff613a6c48ba12d75fad992377d8f181@changeid
Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
2021-04-19 10:13:30 -05:00
Douglas Anderson
a4c5ba1df1 arm64: dts: qcom: sc7180: coachz: Add "dmic_clk_en"
This was present downstream. Add upstream too. NOTE: upstream I
managed to get some sort of halfway state and got one pinctrl entry in
the coachz-r1 device tree. Remove that as part of this since it's now
in the dtsi.

Reviewed-by: Matthias Kaehlcke <mka@chromium.org>
Reviewed-by: Stephen Boyd <swboyd@chromium.org>
Cc: Srinivasa Rao Mandadapu <srivasam@codeaurora.org>
Cc: Ajit Pandey <ajitp@codeaurora.org>
Cc: Judy Hsiao <judyhsiao@chromium.org>
Cc: Cheng-Yi Chiang <cychiang@chromium.org>
Cc: Stephen Boyd <swboyd@chromium.org>
Cc: Matthias Kaehlcke <mka@chromium.org>
Signed-off-by: Douglas Anderson <dianders@chromium.org>
Link: https://lore.kernel.org/r/20210315133924.v2.1.I601a051cad7cfd0923e55b69ef7e5748910a6096@changeid
Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
2021-04-19 10:13:15 -05:00
Daniel Palmer
3060a15cca ARM: dts: mstar: Add a dts for M5Stack UnitV2
M5Stack are releasing a new widget based on the
SigmaStar SSD202D. We have some support for the
SSD202D so lets add a dts for it.

Signed-off-by: Daniel Palmer <daniel@0x0f.com>
Link: https://m5stack-store.myshopify.com/products/unitv2-ai-camera-gc2145
Link: https://lore.kernel.org/r/20210417011015.2105280-4-daniel@0x0f.com'
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2021-04-19 17:02:23 +02:00
Daniel Palmer
c5208ff7f6 dt-bindings: arm: mstar: Add compatible for M5Stack UnitV2
Add a compatible for the M5Stack UnitV2 that is based on the
SigmaStar SSD202D (inifinity2m).

Signed-off-by: Daniel Palmer <daniel@0x0f.com>
Link: https://lore.kernel.org/r/20210417011015.2105280-3-daniel@0x0f.com'
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2021-04-19 17:02:23 +02:00
Daniel Palmer
f8d6fb74bb dt-bindings: vendor-prefixes: Add vendor prefix for M5Stack
M5Stack make various modules for STEM, Makers, IoT.
Their UnitV2 is based on a SigmaStar SSD202D SoC which
we already have some minimal support for so add a
prefix in preparation for UnitV2 board support.

Signed-off-by: Daniel Palmer <daniel@0x0f.com>
Link: https://m5stack.com/
Link: https://lore.kernel.org/r/20210417011015.2105280-2-daniel@0x0f.com'
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2021-04-19 17:02:23 +02:00
Matthias Brugger
f538437b31 arm64: dts: mt8183: fix dtbs_check warning
Fix unit names to make dtbs_check happy.

Signed-off-by: Matthias Brugger <matthias.bgg@gmail.com>
Reviewed-by: Enric Balletbo i Serra <enric.balletbo@collabora.com>
Link: https://lore.kernel.org/r/20210414144643.17435-2-matthias.bgg@kernel.org
Link: https://lore.kernel.org/r/20210416143923.23406-3-matthias.bgg@kernel.org'
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2021-04-19 17:01:53 +02:00
Matthias Brugger
f9929b452a arm64: dts: mt8183-pumpkin: fix dtbs_check warning
Fix unit names to make dtbs_check happy.

Signed-off-by: Matthias Brugger <matthias.bgg@gmail.com>
Reviewed-by: Enric Balletbo i Serra <enric.balletbo@collabora.com>
Link: https://lore.kernel.org/r/20210414144643.17435-1-matthias.bgg@kernel.org
Link: https://lore.kernel.org/r/20210416143923.23406-2-matthias.bgg@kernel.org'
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2021-04-19 17:01:53 +02:00
Arnd Bergmann
8c0bd213de Memory controller drivers for v5.13, part two
1. Renesas RPC: fix possible NULL pointer.
 2. Exynos5422 DMC: add proper error checking for clk_prepare.
 3. Mediatek SMI: use device-links instead of explicit PM runtime calls.
 -----BEGIN PGP SIGNATURE-----
 
 iQJEBAABCgAuFiEE3dJiKD0RGyM7briowTdm5oaLg9cFAmB34vIQHGtyemtAa2Vy
 bmVsLm9yZwAKCRDBN2bmhouD180kD/9YhYZxnUoOb7cFzJNrtc/Pnbo/ggcENfpx
 nddzzhK1MKZ5rhXrXCkILrOBo4twhDD/nmebav+ogVukreV9PinUlu1iPbOlZdyC
 LAqbbIBuYVa3T0NxpCISx7+CURvQeD08osuEvlRfm7vZS1S9XHIa5B8GcNbGqnCy
 CpDbvjImLkRKZ/3U0AYWnmOkP3BuppNUdvH2wt4D73A+B+rcAjeaoAQsnmREukuT
 Bch8xwyZuiFO4UMS91Ndd97ERuEBQFjs2/Ff6awKse7QcLuJVaBCqJ1y10pnavoG
 NMAsb7ThojGZE6xcIioZJ9lsO5rF2oYSSTW9xmg/n//uAVhT0ZZqmx4u0SVRsKJ+
 ShQ/5+uLgrG2A8ujrNO31yYFwipVLOfgFGsS5D3k9YEuiHEQ1taNUkq2TWjU+DIR
 0LrJ4W6eWbbTqS9OT/V45NMy/rBudGsLN9orTEPDBMMkCyotHZ7LTTMcFO+BkKvC
 +eatA1ILJoCarm/yRv7+aRpOo9HQZ2zZbvSOpeHc5rgOOWbyBOx0uRWUWahNhDll
 uMGsAfYMuAYUFiSHK1P3bc6VUzQua570HpEPpe2n5TD1O0gwRLXjYoyIwgLnZ9ar
 xhUBfeNN8YIEW3hhnaD33mAMGqjFfMcJx1bINelgjtZ5zG22H79XfNkpdhm9JCEQ
 FbJTKUDvhQ==
 =OtAm
 -----END PGP SIGNATURE-----

Merge tag 'memory-controller-drv-5.13-2' of git://git.kernel.org/pub/scm/linux/kernel/git/krzk/linux-mem-ctrl into arm/drivers

Memory controller drivers for v5.13, part two

1. Renesas RPC: fix possible NULL pointer.
2. Exynos5422 DMC: add proper error checking for clk_prepare.
3. Mediatek SMI: use device-links instead of explicit PM runtime calls.

* tag 'memory-controller-drv-5.13-2' of git://git.kernel.org/pub/scm/linux/kernel/git/krzk/linux-mem-ctrl:
  memory: mtk-smi: Add device-link between smi-larb and smi-common
  memory: samsung: exynos5422-dmc: handle clk_set_parent() failure
  memory: renesas-rpc-if: fix possible NULL pointer dereference of resource

Link: https://lore.kernel.org/r/20210415065514.7385-1-krzysztof.kozlowski@canonical.com
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2021-04-19 16:32:34 +02:00
Maciej W. Rozycki
0ef3439cd8 x86/build: Disable HIGHMEM64G selection for M486SX
Fix a regression caused by making the 486SX separately selectable in
Kconfig, for which the HIGHMEM64G setting has not been updated and
therefore has become exposed as a user-selectable option for the M486SX
configuration setting unlike with original M486 and all the other
settings that choose non-PAE-enabled processors:

  High Memory Support
  > 1. off (NOHIGHMEM)
    2. 4GB (HIGHMEM4G)
    3. 64GB (HIGHMEM64G)
  choice[1-3?]:

With the fix in place the setting is now correctly removed:

  High Memory Support
  > 1. off (NOHIGHMEM)
    2. 4GB (HIGHMEM4G)
  choice[1-2?]:

 [ bp: Massage commit message. ]

Fixes: 87d6021b81 ("x86/math-emu: Limit MATH_EMULATION to 486SX compatibles")
Signed-off-by: Maciej W. Rozycki <macro@orcam.me.uk>
Signed-off-by: Borislav Petkov <bp@suse.de>
Cc: stable@vger.kernel.org # v5.5+
Link: https://lkml.kernel.org/r/alpine.DEB.2.21.2104141221340.44318@angie.orcam.me.uk
2021-04-19 14:02:12 +02:00
Wan Jiabing
34e5269bf9 m68k: sun3x: Remove unneeded semicolon
Fix the following coccicheck warning:

./arch/m68k/include/asm/sun3xflop.h:109:2-3: Unneeded semicolon

Signed-off-by: Wan Jiabing <wanjiabing@vivo.com>
Link: https://lore.kernel.org/r/20210415031450.23379-1-wanjiabing@vivo.com
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
2021-04-19 12:11:55 +02:00
Hans de Goede
8d01cf643b platform/x86: touchscreen_dmi: Add info for the Teclast Tbook 11 tablet
Add touchscreen info for the Teclast Tbook 11 tablet. This includes info
for getting the firmware directly from the UEFI, so that the user does
not need to manually install the firmware in /lib/firmware/silead.

This change will make the touchscreen on these devices work OOTB,
without requiring any manual setup.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Link: https://lore.kernel.org/r/20210417173105.4134-1-hdegoede@redhat.com
2021-04-19 10:46:06 +02:00