~ubuntu-mainline/ubuntu-mainline/+git/linux-upstream:linux-5.6.y

Last commit made on 2020-06-17
Get this branch:
git clone -b linux-5.6.y https://git.launchpad.net/~ubuntu-mainline/ubuntu-mainline/+git/linux-upstream
Members of Ubuntu Mainline can upload to this branch. Log in for directions.

Branch merges

Branch information

Recent commits

61aba37... by Greg Kroah-Hartman <email address hidden>

Linux 5.6.19

91f304e... by Marc Zyngier <email address hidden>

KVM: arm64: Save the host's PtrAuth keys in non-preemptible context

commit ef3e40a7ea8dbe2abd0a345032cd7d5023b9684f upstream.

When using the PtrAuth feature in a guest, we need to save the host's
keys before allowing the guest to program them. For that, we dump
them in a per-CPU data structure (the so called host context).

But both call sites that do this are in preemptible context,
which may end up in disaster should the vcpu thread get preempted
before reentering the guest.

Instead, save the keys eagerly on each vcpu_load(). This has an
increased overhead, but is at least safe.

Cc: <email address hidden>
Reviewed-by: Mark Rutland <email address hidden>
Signed-off-by: Marc Zyngier <email address hidden>
Signed-off-by: Greg Kroah-Hartman <email address hidden>

1e311a1... by Marc Zyngier <email address hidden>

KVM: arm64: Synchronize sysreg state on injecting an AArch32 exception

commit 0370964dd3ff7d3d406f292cb443a927952cbd05 upstream.

On a VHE system, the EL1 state is left in the CPU most of the time,
and only syncronized back to memory when vcpu_put() is called (most
of the time on preemption).

Which means that when injecting an exception, we'd better have a way
to either:
(1) write directly to the EL1 sysregs
(2) synchronize the state back to memory, and do the changes there

For an AArch64, we already do (1), so we are safe. Unfortunately,
doing the same thing for AArch32 would be pretty invasive. Instead,
we can easily implement (2) by calling the put/load architectural
backends, and keep preemption disabled. We can then reload the
state back into EL1.

Cc: <email address hidden>
Reported-by: James Morse <email address hidden>
Signed-off-by: Marc Zyngier <email address hidden>
Signed-off-by: Greg Kroah-Hartman <email address hidden>

a688d4d... by Mattia Dongili <email address hidden>

platform/x86: sony-laptop: Make resuming thermal profile safer

commit 476d60b1b4c8a2b14a53ef9b772058f35e604661 upstream.

The thermal handle object may fail initialization when the module is
loaded in the first place. Avoid attempting to use it on resume then.

Fixes: 6d232b29cfce ("ACPICA: Dispatcher: always generate buffer objects for ASL create_field() operator")
Reported-by: Dominik Mierzejewski <email address hidden>
Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=207491
Signed-off-by: Mattia Dongili <email address hidden>
Signed-off-by: Andy Shevchenko <email address hidden>
Signed-off-by: Greg Kroah-Hartman <email address hidden>

4417492... by Mattia Dongili <email address hidden>

platform/x86: sony-laptop: SNC calls should handle BUFFER types

commit 47828d22539f76c8c9dcf2a55f18ea3a8039d8ef upstream.

After commit 6d232b29cfce ("ACPICA: Dispatcher: always generate buffer
objects for ASL create_field() operator") ACPICA creates buffers even
when new fields are small enough to fit into an integer.
Many SNC calls counted on the old behaviour.
Since sony-laptop already handles the INTEGER/BUFFER case in
sony_nc_buffer_call, switch sony_nc_int_call to use its more generic
function instead.

Fixes: 6d232b29cfce ("ACPICA: Dispatcher: always generate buffer objects for ASL create_field() operator")
Reported-by: Dominik Mierzejewski <email address hidden>
Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=207491
Reported-by: William Bader <email address hidden>
Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=1830150
Signed-off-by: Mattia Dongili <email address hidden>
Signed-off-by: Andy Shevchenko <email address hidden>
Signed-off-by: Greg Kroah-Hartman <email address hidden>

2bdc48d... by Jürgen Groß

xen/pvcalls-back: test for errors when calling backend_connect()

commit c8d70a29d6bbc956013f3401f92a4431a9385a3c upstream.

backend_connect() can fail, so switch the device to connected only if
no error occurred.

Fixes: 0a9c75c2c7258f2 ("xen/pvcalls: xenbus state handling")
Cc: <email address hidden>
Signed-off-by: Juergen Gross <email address hidden>
Link: https://<email address hidden>
Reviewed-by: Stefano Stabellini <email address hidden>
Signed-off-by: Boris Ostrovsky <email address hidden>
Signed-off-by: Greg Kroah-Hartman <email address hidden>

d8dae47... by Jiri Kosina <email address hidden>

block/floppy: fix contended case in floppy_queue_rq()

commit 263c61581a38d0a5ad1f5f4a9143b27d68caeffd upstream.

Since the switch of floppy driver to blk-mq, the contended (fdc_busy) case
in floppy_queue_rq() is not handled correctly.

In case we reach floppy_queue_rq() with fdc_busy set (i.e. with the floppy
locked due to another request still being in-flight), we put the request
on the list of requests and return BLK_STS_OK to the block core, without
actually scheduling delayed work / doing further processing of the
request. This means that processing of this request is postponed until
another request comes and passess uncontended.

Which in some cases might actually never happen and we keep waiting
indefinitely. The simple testcase is

 for i in `seq 1 2000`; do echo -en $i '\r'; blkid --info /dev/fd0 2> /dev/null; done

run in quemu. That reliably causes blkid eventually indefinitely hanging
in __floppy_read_block_0() waiting for completion, as the BIO callback
never happens, and no further IO is ever submitted on the (non-existent)
floppy device. This was observed reliably on qemu-emulated device.

Fix that by not queuing the request in the contended case, and return
BLK_STS_RESOURCE instead, so that blk core handles the request
rescheduling and let it pass properly non-contended later.

Fixes: a9f38e1dec107a ("floppy: convert to blk-mq")
Cc: <email address hidden>
Tested-by: Libor Pechacek <email address hidden>
Signed-off-by: Jiri Kosina <email address hidden>
Signed-off-by: Jens Axboe <email address hidden>
Signed-off-by: Greg Kroah-Hartman <email address hidden>

84d71e4... by Ulf Hansson

mmc: sdio: Fix several potential memory leaks in mmc_sdio_init_card()

commit a94a59f43749b4f8cd81b8be87c95f9ef898d19d upstream.

Over the years, the code in mmc_sdio_init_card() has grown to become quite
messy. Unfortunate this has also lead to that several paths are leaking
memory in form of an allocated struct mmc_card, which includes additional
data, such as initialized struct device for example.

Unfortunate, it's a too complex task find each offending commit. Therefore,
this change fixes all memory leaks at once.

Cc: <email address hidden>
Signed-off-by: Ulf Hansson <email address hidden>
Link: https://<email address hidden>
Signed-off-by: Greg Kroah-Hartman <email address hidden>

e0f61e3... by Ulf Hansson

mmc: sdio: Fix potential NULL pointer error in mmc_sdio_init_card()

commit f04086c225da11ad16d7f9a2fbca6483ab16dded upstream.

During some scenarios mmc_sdio_init_card() runs a retry path for the UHS-I
specific initialization, which leads to removal of the previously allocated
card. A new card is then re-allocated while retrying.

However, in one of the corresponding error paths we may end up to remove an
already removed card, which likely leads to a NULL pointer exception. So,
let's fix this.

Fixes: 5fc3d80ef496 ("mmc: sdio: don't use rocr to check if the card could support UHS mode")
Cc: <email address hidden>
Signed-off-by: Ulf Hansson <email address hidden>
Link: https://<email address hidden>
Signed-off-by: Greg Kroah-Hartman <email address hidden>

380b60c... by Ludovic Desroches <email address hidden>

ARM: dts: at91: sama5d2_ptc_ek: fix sdmmc0 node description

commit a1af7f36c70369b971ee1cf679dd68368dad23f0 upstream.

Remove non-removable and mmc-ddr-1_8v properties from the sdmmc0
node which come probably from an unchecked copy/paste.

Signed-off-by: Ludovic Desroches <email address hidden>
Fixes:42ed535595ec "ARM: dts: at91: introduce the sama5d2 ptc ek board"
Cc: <email address hidden> # 4.19 and later
Link: https://<email address hidden>
Signed-off-by: Alexandre Belloni <email address hidden>
Signed-off-by: Greg Kroah-Hartman <email address hidden>