<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux-dev/drivers/xen/xen-pciback, branch master</title>
<subtitle>Linux kernel development work - see feature branches</subtitle>
<id>https://git.zx2c4.com/linux-dev/atom/drivers/xen/xen-pciback?h=master</id>
<link rel='self' href='https://git.zx2c4.com/linux-dev/atom/drivers/xen/xen-pciback?h=master'/>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/'/>
<updated>2022-10-06T05:35:14Z</updated>
<entry>
<title>xen/xenbus: Fix spelling mistake "hardward" -&gt; "hardware"</title>
<updated>2022-10-06T05:35:14Z</updated>
<author>
<name>Colin Ian King</name>
<email>colin.i.king@gmail.com</email>
</author>
<published>2022-10-04T16:06:39Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=06c62f8cbb1f660a4147b0d8cbe65cf2cfc1aa5a'/>
<id>urn:sha1:06c62f8cbb1f660a4147b0d8cbe65cf2cfc1aa5a</id>
<content type='text'>
There is a spelling mistake in the module description. Fix it.

Signed-off-by: Colin Ian King &lt;colin.i.king@gmail.com&gt;
Reviewed-by: Juergen Gross &lt;jgross@suse.com&gt;
Link: https://lore.kernel.org/r/20221004160639.154421-1-colin.i.king@gmail.com
Signed-off-by: Juergen Gross &lt;jgross@suse.com&gt;
</content>
</entry>
<entry>
<title>xen/pciback: Fix comment typo</title>
<updated>2022-08-12T10:19:50Z</updated>
<author>
<name>Jason Wang</name>
<email>wangborong@cdjrlc.com</email>
</author>
<published>2022-08-11T12:09:18Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=ced3c74271bfedfb8e517c01b4dd7b9aad7020b0'/>
<id>urn:sha1:ced3c74271bfedfb8e517c01b4dd7b9aad7020b0</id>
<content type='text'>
The double `the' is duplicated in the comment, remove one.

Signed-off-by: Jason Wang &lt;wangborong@cdjrlc.com&gt;
Reviewed-by: Juergen Gross &lt;jgross@suse.com&gt;
Link: https://lore.kernel.org/r/20220811120918.17961-1-wangborong@cdjrlc.com
Signed-off-by: Juergen Gross &lt;jgross@suse.com&gt;
</content>
</entry>
<entry>
<title>xen-pciback: allow compiling on other archs than x86</title>
<updated>2021-11-02T13:03:43Z</updated>
<author>
<name>Oleksandr Andrushchenko</name>
<email>oleksandr_andrushchenko@epam.com</email>
</author>
<published>2021-10-28T14:36:20Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=a67efff28832a597f46a0097916833937aa3983e'/>
<id>urn:sha1:a67efff28832a597f46a0097916833937aa3983e</id>
<content type='text'>
Xen-pciback driver was designed to be built for x86 only. But it
can also be used by other architectures, e.g. Arm.

Currently PCI backend implements multiple functionalities at a time,
such as:
1. It is used as a database for assignable PCI devices, e.g. xl
   pci-assignable-{add|remove|list} manipulates that list. So, whenever
   the toolstack needs to know which PCI devices can be passed through
   it reads that from the relevant sysfs entries of the pciback.
2. It is used to hold the unbound PCI devices list, e.g. when passing
   through a PCI device it needs to be unbound from the relevant device
   driver and bound to pciback (strictly speaking it is not required
   that the device is bound to pciback, but pciback is again used as a
   database of the passed through PCI devices, so we can re-bind the
   devices back to their original drivers when guest domain shuts down)
3. Device reset for the devices being passed through
4. Para-virtualised use-cases support

The para-virtualised part of the driver is not always needed as some
architectures, e.g. Arm or x86 PVH Dom0, are not using backend-frontend
model for PCI device passthrough.

For such use-cases make the very first step in splitting the
xen-pciback driver into two parts: Xen PCI stub and PCI PV backend
drivers.

For that add new configuration options CONFIG_XEN_PCI_STUB and
CONFIG_XEN_PCIDEV_STUB, so the driver can be limited in its
functionality, e.g. no support for para-virtualised scenario.
x86 platform will continue using CONFIG_XEN_PCIDEV_BACKEND for the
fully featured backend driver.

Signed-off-by: Oleksandr Andrushchenko &lt;oleksandr_andrushchenko@epam.com&gt;
Signed-off-by: Anastasiia Lukianenko &lt;anastasiia_lukianenko@epam.com&gt;
Reviewed-by: Stefano Stabellini &lt;sstabellini@kernel.org&gt;
Reviewed-by: Juergen Gross &lt;jgross@suse.com&gt;
Link: https://lore.kernel.org/r/20211028143620.144936-1-andr2000@gmail.com
Signed-off-by: Boris Ostrovsky &lt;boris.ostrovsky@oracle.com&gt;
</content>
</entry>
<entry>
<title>xen-pciback: Fix return in pm_ctrl_init()</title>
<updated>2021-11-02T12:45:44Z</updated>
<author>
<name>YueHaibing</name>
<email>yuehaibing@huawei.com</email>
</author>
<published>2021-10-08T07:44:17Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=4745ea2628bb43a7ec34b71763b5a56407b33990'/>
<id>urn:sha1:4745ea2628bb43a7ec34b71763b5a56407b33990</id>
<content type='text'>
Return NULL instead of passing to ERR_PTR while err is zero,
this fix smatch warnings:
drivers/xen/xen-pciback/conf_space_capability.c:163
 pm_ctrl_init() warn: passing zero to 'ERR_PTR'

Fixes: a92336a1176b ("xen/pciback: Drop two backends, squash and cleanup some code.")
Signed-off-by: YueHaibing &lt;yuehaibing@huawei.com&gt;
Reviewed-by: Juergen Gross &lt;jgross@suse.com&gt;
Link: https://lore.kernel.org/r/20211008074417.8260-1-yuehaibing@huawei.com
Signed-off-by: Boris Ostrovsky &lt;boris.ostrovsky@oracle.com&gt;
</content>
</entry>
<entry>
<title>xen-pciback: reconfigure also from backend watch handler</title>
<updated>2021-05-21T07:55:16Z</updated>
<author>
<name>Jan Beulich</name>
<email>jbeulich@suse.com</email>
</author>
<published>2021-05-18T16:14:07Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=c81d3d24602540f65256f98831d0a25599ea6b87'/>
<id>urn:sha1:c81d3d24602540f65256f98831d0a25599ea6b87</id>
<content type='text'>
When multiple PCI devices get assigned to a guest right at boot, libxl
incrementally populates the backend tree. The writes for the first of
the devices trigger the backend watch. In turn xen_pcibk_setup_backend()
will set the XenBus state to Initialised, at which point no further
reconfigures would happen unless a device got hotplugged. Arrange for
reconfigure to also get triggered from the backend watch handler.

Signed-off-by: Jan Beulich &lt;jbeulich@suse.com&gt;
Cc: stable@vger.kernel.org
Reviewed-by: Boris Ostrovsky &lt;boris.ostrovsky@oracle.com&gt;
Link: https://lore.kernel.org/r/2337cbd6-94b9-4187-9862-c03ea12e0c61@suse.com
Signed-off-by: Juergen Gross &lt;jgross@suse.com&gt;
</content>
</entry>
<entry>
<title>xen-pciback: redo VF placement in the virtual topology</title>
<updated>2021-05-21T07:55:13Z</updated>
<author>
<name>Jan Beulich</name>
<email>jbeulich@suse.com</email>
</author>
<published>2021-05-18T16:13:42Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=4ba50e7c423c29639878c00573288869aa627068'/>
<id>urn:sha1:4ba50e7c423c29639878c00573288869aa627068</id>
<content type='text'>
The commit referenced below was incomplete: It merely affected what
would get written to the vdev-&lt;N&gt; xenstore node. The guest would still
find the function at the original function number as long as
__xen_pcibk_get_pci_dev() wouldn't be in sync. The same goes for AER wrt
__xen_pcibk_get_pcifront_dev().

Undo overriding the function to zero and instead make sure that VFs at
function zero remain alone in their slot. This has the added benefit of
improving overall capacity, considering that there's only a total of 32
slots available right now (PCI segment and bus can both only ever be
zero at present).

Fixes: 8a5248fe10b1 ("xen PV passthru: assign SR-IOV virtual functions to separate virtual slots")
Signed-off-by: Jan Beulich &lt;jbeulich@suse.com&gt;
Cc: stable@vger.kernel.org
Reviewed-by: Boris Ostrovsky &lt;boris.ostrovsky@oracle.com&gt;
Link: https://lore.kernel.org/r/8def783b-404c-3452-196d-3f3fd4d72c9e@suse.com
Signed-off-by: Juergen Gross &lt;jgross@suse.com&gt;
</content>
</entry>
<entry>
<title>xen-pciback: simplify vpci's find hook</title>
<updated>2021-04-23T07:53:24Z</updated>
<author>
<name>Jan Beulich</name>
<email>jbeulich@suse.com</email>
</author>
<published>2021-04-07T14:37:58Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=a929e124060c448b367f56b28a0c118876147b1f'/>
<id>urn:sha1:a929e124060c448b367f56b28a0c118876147b1f</id>
<content type='text'>
There's no point in comparing SBDF - we can simply compare the struct
pci_dev pointers. If they weren't the same for a given device, we'd have
bigger problems from having stored a stale pointer.

Signed-off-by: Jan Beulich &lt;jbeulich@suse.com&gt;
Reviewed-by: Boris Ostrovsky &lt;boris.ostrovsky@oracle.com&gt;

Link: https://lore.kernel.org/r/158273a2-d1b9-3545-b25d-affca867376c@suse.com
Signed-off-by: Juergen Gross &lt;jgross@suse.com&gt;
</content>
</entry>
<entry>
<title>xen/pciback: Fix incorrect type warnings</title>
<updated>2021-04-23T07:27:12Z</updated>
<author>
<name>Muhammad Usama Anjum</name>
<email>musamaanjum@gmail.com</email>
</author>
<published>2021-03-26T18:14:42Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=28738fab6a424f58aea4b122ee96ee078ea1de93'/>
<id>urn:sha1:28738fab6a424f58aea4b122ee96ee078ea1de93</id>
<content type='text'>
Correct enum pci_channel_io_normal should be used instead of putting
integer value 1.

Fix following smatch warnings:
drivers/xen/xen-pciback/pci_stub.c:805:40: warning: incorrect type in argument 2 (different base types)
drivers/xen/xen-pciback/pci_stub.c:805:40:    expected restricted pci_channel_state_t [usertype] state
drivers/xen/xen-pciback/pci_stub.c:805:40:    got int
drivers/xen/xen-pciback/pci_stub.c:862:40: warning: incorrect type in argument 2 (different base types)
drivers/xen/xen-pciback/pci_stub.c:862:40:    expected restricted pci_channel_state_t [usertype] state
drivers/xen/xen-pciback/pci_stub.c:862:40:    got int
drivers/xen/xen-pciback/pci_stub.c:973:31: warning: incorrect type in argument 2 (different base types)
drivers/xen/xen-pciback/pci_stub.c:973:31:    expected restricted pci_channel_state_t [usertype] state
drivers/xen/xen-pciback/pci_stub.c:973:31:    got int

Signed-off-by: Muhammad Usama Anjum &lt;musamaanjum@gmail.com&gt;
Reviewed-by: Juergen Gross &lt;jgross@suse.com&gt;
Link: https://lore.kernel.org/r/20210326181442.GA1735905@LEGION
Signed-off-by: Juergen Gross &lt;jgross@suse.com&gt;
</content>
</entry>
<entry>
<title>xen/events: link interdomain events to associated xenbus device</title>
<updated>2021-02-11T22:47:00Z</updated>
<author>
<name>Juergen Gross</name>
<email>jgross@suse.com</email>
</author>
<published>2021-02-11T10:16:13Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=f2fa0e5e9f31dd90741f1151043ca1eaa4086690'/>
<id>urn:sha1:f2fa0e5e9f31dd90741f1151043ca1eaa4086690</id>
<content type='text'>
In order to support the possibility of per-device event channel
settings (e.g. lateeoi spurious event thresholds) add a xenbus device
pointer to struct irq_info() and modify the related event channel
binding interfaces to take the pointer to the xenbus device as a
parameter instead of the domain id of the other side.

While at it remove the stale prototype of bind_evtchn_to_irq_lateeoi().

Signed-off-by: Juergen Gross &lt;jgross@suse.com&gt;
Reviewed-by: Boris Ostrovsky &lt;boris.ostrovsky@oracle.com&gt;
Reviewed-by: Wei Liu &lt;wei.liu@kernel.org&gt;
Reviewed-by: Paul Durrant &lt;paul@xen.org&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>xen/xenbus: Add 'will_handle' callback support in xenbus_watch_path()</title>
<updated>2020-12-14T09:04:18Z</updated>
<author>
<name>SeongJae Park</name>
<email>sjpark@amazon.de</email>
</author>
<published>2020-12-14T09:04:18Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=2e85d32b1c865bec703ce0c962221a5e955c52c2'/>
<id>urn:sha1:2e85d32b1c865bec703ce0c962221a5e955c52c2</id>
<content type='text'>
Some code does not directly make 'xenbus_watch' object and call
'register_xenbus_watch()' but use 'xenbus_watch_path()' instead.  This
commit adds support of 'will_handle' callback in the
'xenbus_watch_path()' and it's wrapper, 'xenbus_watch_pathfmt()'.

This is part of XSA-349

Cc: stable@vger.kernel.org
Signed-off-by: SeongJae Park &lt;sjpark@amazon.de&gt;
Reported-by: Michael Kurth &lt;mku@amazon.de&gt;
Reported-by: Pawel Wieczorkiewicz &lt;wipawel@amazon.de&gt;
Reviewed-by: Juergen Gross &lt;jgross@suse.com&gt;
Signed-off-by: Juergen Gross &lt;jgross@suse.com&gt;
</content>
</entry>
</feed>
