Branch: refs/heads/next
  Home:   https://github.com/siemens/jailhouse
  Commit: a86bb16d73446463345b95522d6a416849020ca3
      
https://github.com/siemens/jailhouse/commit/a86bb16d73446463345b95522d6a416849020ca3
  Author: Jan Kiszka <[email protected]>
  Date:   2016-12-05 (Mon, 05 Dec 2016)

  Changed paths:
    M hypervisor/ivshmem.c

  Log Message:
  -----------
  core: ivshmem: Rework device creation and destruction

Moving device from slot 1 to slot 0 in case the first slot becomes free
had a bug: it didn't update the pointer from pci_device to the
ivshmem_endpoint.

Instead of fixing this, let's take the chance and redesign the
management: Thanks to earlier preparation steps, we can now keep the
device in its original slot. We just need to check during creation which
slot is free (device pointer is NULL) and use that. Now ivpos of an
endpoint always equals the array index in ivshmem_data.eps that the
endpoint uses.

Finally, we can significantly simplify the code by folding ivshmem_find
and ivshmem_connect/disconnect_cell into their callers.

Signed-off-by: Jan Kiszka <[email protected]>


  Commit: a403c2b650a6f9d3f51b37bc21c0bbbae8a48dba
      
https://github.com/siemens/jailhouse/commit/a403c2b650a6f9d3f51b37bc21c0bbbae8a48dba
  Author: Jan Kiszka <[email protected]>
  Date:   2016-12-06 (Tue, 06 Dec 2016)

  Changed paths:
    M hypervisor/arch/arm-common/ivshmem.c
    M hypervisor/arch/x86/ivshmem.c
    M hypervisor/include/jailhouse/ivshmem.h
    M hypervisor/ivshmem.c

  Log Message:
  -----------
  core: ivshmem: Factor out ivshmem_remote_interrupt

The check for the remote being present before sending it an interrupt is
actually generic. Factor this out and change the arch-specific callback
to only trigger the interrupt on the destination device.

Signed-off-by: Jan Kiszka <[email protected]>


  Commit: 433f2a4994792dc7ab8757a90a32db9bce695876
      
https://github.com/siemens/jailhouse/commit/433f2a4994792dc7ab8757a90a32db9bce695876
  Author: Jan Kiszka <[email protected]>
  Date:   2016-12-06 (Tue, 06 Dec 2016)

  Changed paths:
    M hypervisor/include/jailhouse/ivshmem.h
    M hypervisor/ivshmem.c

  Log Message:
  -----------
  core: ivshmem: Synchronize remote device access with device destruction

In case of an ivshmem link between two non-root cells, one can go down
while the other is running. That is different from root to non-root
links, because the non-root cell always leaves first, and the root cell
is stopped meanwhile. We have to avoid the, after destroying one peer,
the other will still send interrupts to the former peer.

The simplest way to achieve this is using a spinlock around
dereferencing the remote pointer of an ivshmem endpoint and sending out
the interrupt to the peer on one side and around the clearing of the
remote pointer during destruction. The latter will ensure that the
sender is either already done with the transmission or will see NULL as
remote, thus will not send any message anymore. This resolves the race
between flushing pending interrupts from the destructed cell and sending
new ones from the former peer cell.

Spinlocks come with memory barrier semantics, so we can remove the
explicit barriers.

Now that we have the lock, we can also synchronize the rstate readout of
the remaining peer with device destruction to ensure that no other CPU
will consider the device alive after ivshmem_exit returned.

Signed-off-by: Jan Kiszka <[email protected]>


  Commit: 32db3212da9c7ce159af03a0a2d0994114104ed1
      
https://github.com/siemens/jailhouse/commit/32db3212da9c7ce159af03a0a2d0994114104ed1
  Author: Henning Schild <[email protected]>
  Date:   2016-12-06 (Tue, 06 Dec 2016)

  Changed paths:
    M inmates/demos/x86/ivshmem-demo.c
    M inmates/lib/x86/inmate.h

  Log Message:
  -----------
  inmates: x86: match pci device class in ivshmem-demo

Match the device class and "protocol" while probing and skip unknow
devices.

Signed-off-by: Henning Schild <[email protected]>
Signed-off-by: Jan Kiszka <[email protected]>


  Commit: 61d5fbf93b8274a618617738e6066085d46112b1
      
https://github.com/siemens/jailhouse/commit/61d5fbf93b8274a618617738e6066085d46112b1
  Author: Jan Kiszka <[email protected]>
  Date:   2016-12-06 (Tue, 06 Dec 2016)

  Changed paths:
    M hypervisor/ivshmem.c

  Log Message:
  -----------
  core: ivshmem: Use local variable for PCI device info

Shortens some existing and upcoming long lines.

Signed-off-by: Jan Kiszka <[email protected]>


  Commit: bc7f2907b0ec4c2cc3815f36965167fc882e724d
      
https://github.com/siemens/jailhouse/commit/bc7f2907b0ec4c2cc3815f36965167fc882e724d
  Author: Henning Schild <[email protected]>
  Date:   2016-12-06 (Tue, 06 Dec 2016)

  Changed paths:
    M Documentation/inter-cell-communication.txt
    M hypervisor/ivshmem.c

  Log Message:
  -----------
  core: ivshmem: match device class to connect

Since 3e970ab533c4 we can specify a protocol to run on the ivshmem channel.
This patch considers a protocol mismatch between the two endpoints a
configuration error and does not connect them to each other.

Signed-off-by: Henning Schild <[email protected]>
[Jan: rebased]
Signed-off-by: Jan Kiszka <[email protected]>


Compare: 
https://github.com/siemens/jailhouse/compare/2b8e1fc8b066...bc7f2907b0ec

-- 
You received this message because you are subscribed to the Google Groups 
"Jailhouse" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to