dde_linux: support of GSIs in new usb_host_drv

This commit is contained in:
Stefan Kalkowski 2018-09-10 16:11:52 +02:00 committed by Christian Helmuth
parent abe1b98486
commit 76e9645787
5 changed files with 17 additions and 8 deletions

View File

@ -139,7 +139,7 @@ append config {
</route>
</start>
<start name="usb_hid_drv" caps="120">
<start name="usb_hid_drv" caps="140">
<resource name="RAM" quantum="11M"/>
<provides><service name="Input"/></provides>
<config use_report="yes" capslock_led="rom" numlock_led="rom" scrlock_led="rom"/>

View File

@ -931,11 +931,6 @@ void *idr_get_next(struct idr *idp, int *nextid)
return NULL;
}
void idr_remove(struct idr *idp, int id)
{
TRACE_AND_STOP;
}
unsigned int jiffies_to_usecs(const unsigned long j)
{
TRACE_AND_STOP;
@ -985,7 +980,7 @@ void pci_clear_mwi(struct pci_dev *dev)
void pci_free_irq_vectors(struct pci_dev *dev)
{
TRACE_AND_STOP;
TRACE;
}
int pci_reset_function_locked(struct pci_dev *dev)

View File

@ -784,6 +784,12 @@ int idr_alloc(struct idr *idp, void *ptr, int start, int end, gfp_t gfp_mask)
}
void idr_remove(struct idr *idp, int id)
{
if (id > 0) id_allocator.free(id);
}
int object_is_on_stack(const void *obj)
{
Genode::Thread::Stack_info info = Genode::Thread::mystack();

View File

@ -16,6 +16,7 @@
#include <base/entrypoint.h>
#include <base/lock.h>
#include <base/signal.h>
#include <irq_session/client.h>
#include <util/misc_math.h>
#include <lx_emul.h>
@ -180,6 +181,11 @@ int request_irq(unsigned int irq, irq_handler_t handler, unsigned long flags,
{
for (Lx::Pci_dev *pci_dev = Lx::pci_dev_registry()->first(); pci_dev; pci_dev = pci_dev->next())
if (pci_dev->irq == irq) {
{
Genode::Irq_session_client is(pci_dev->client().irq(0));
if ((is.info().type != Genode::Irq_session::Info::MSI)
&& !flags) return 1;
}
Lx::Irq::irq().request_irq(pci_dev->client(), handler, dev);
return 0;
}

View File

@ -20,5 +20,7 @@ SRC_CC += spec/x86/platform.cc
CC_OPT += -DCONFIG_PCI=1
CC_OPT += -DCONFIG_USB_PCI=1
CC_OPT += -DCONFIG_USB_EHCI_PCI=1
CC_OPT += -DCONFIG_USB_EHCI_HCD=1
CC_OPT += -DCONFIG_USB_OHCI_HCD=1
CC_OPT += -DCONFIG_USB_UHCI_HCD=1
CC_OPT += -DCONFIG_USB_XHCI_HCD=1