本文整理汇总了C++中resource_list_print_type函数的典型用法代码示例。如果您正苦于以下问题:C++ resource_list_print_type函数的具体用法?C++ resource_list_print_type怎么用?C++ resource_list_print_type使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了resource_list_print_type函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: pxa_smi_print_child
static int
pxa_smi_print_child(device_t dev, device_t child)
{
struct smi_ivars *smid;
int retval;
smid = (struct smi_ivars *)device_get_ivars(child);
if (smid == NULL) {
device_printf(dev, "unknown device: %s\n",
device_get_nameunit(child));
return (0);
}
retval = 0;
retval += bus_print_child_header(dev, child);
retval += resource_list_print_type(&smid->smid_resources, "at mem",
SYS_RES_MEMORY, "%#lx");
retval += resource_list_print_type(&smid->smid_resources, "irq",
SYS_RES_IRQ, "%ld");
retval += bus_print_child_footer(dev, child);
return (retval);
}
示例2: pinctrl_print_res
static int
pinctrl_print_res(struct pinctrl_devinfo *di)
{
int rv;
rv = 0;
rv += resource_list_print_type(&di->rl, "mem", SYS_RES_MEMORY, "%#jx");
rv += resource_list_print_type(&di->rl, "irq", SYS_RES_IRQ, "%jd");
return (rv);
}
示例3: simplebus_print_res
static int
simplebus_print_res(struct simplebus_devinfo *di)
{
int rv;
rv = 0;
rv += resource_list_print_type(&di->rl, "mem", SYS_RES_MEMORY, "%#lx");
rv += resource_list_print_type(&di->rl, "irq", SYS_RES_IRQ, "%ld");
return (rv);
}
示例4: lebuffer_print_res
static int
lebuffer_print_res(struct lebuffer_devinfo *ldi)
{
int rv;
rv = 0;
rv += resource_list_print_type(&ldi->ldi_rl, "mem", SYS_RES_MEMORY,
"%#lx");
rv += resource_list_print_type(&ldi->ldi_rl, "irq", SYS_RES_IRQ, "%ld");
return (rv);
}
示例5: dma_print_res
static int
dma_print_res(struct dma_devinfo *ddi)
{
int rv;
rv = 0;
rv += resource_list_print_type(&ddi->ddi_rl, "mem", SYS_RES_MEMORY,
"%#lx");
rv += resource_list_print_type(&ddi->ddi_rl, "irq", SYS_RES_IRQ, "%ld");
return (rv);
}
示例6: ebus_print_res
static int
ebus_print_res(struct ebus_devinfo *edi)
{
int retval;
retval = 0;
retval += resource_list_print_type(&edi->edi_rl, "addr", SYS_RES_MEMORY,
"%#lx");
retval += resource_list_print_type(&edi->edi_rl, "irq", SYS_RES_IRQ,
"%ld");
return (retval);
}
示例7: wiibus_print_child
static int
wiibus_print_child(device_t dev, device_t child)
{
struct wiibus_devinfo *dinfo = device_get_ivars(child);
int retval = 0;
retval += bus_print_child_header(dev, child);
retval += resource_list_print_type(&dinfo->di_resources, "mem",
SYS_RES_MEMORY, "%#lx");
retval += resource_list_print_type(&dinfo->di_resources, "irq",
SYS_RES_IRQ, "%ld");
retval += bus_print_child_footer(dev, child);
return (retval);
}
示例8: apb_print_all_resources
static int
apb_print_all_resources(device_t dev)
{
struct apb_ivar *ndev = DEVTOAPB(dev);
struct resource_list *rl = &ndev->resources;
int retval = 0;
if (STAILQ_FIRST(rl))
retval += printf(" at");
retval += resource_list_print_type(rl, "mem", SYS_RES_MEMORY, "%#jx");
retval += resource_list_print_type(rl, "irq", SYS_RES_IRQ, "%jd");
return (retval);
}
示例9: obio_print_all_resources
static int
obio_print_all_resources(device_t dev)
{
struct obio_ivar *ivar = device_get_ivars(dev);
struct resource_list *rl = &ivar->resources;
int retval = 0;
if (STAILQ_FIRST(rl))
retval += printf(" at");
retval += resource_list_print_type(rl, "mem", SYS_RES_MEMORY, "%#jx");
retval += resource_list_print_type(rl, "irq", SYS_RES_IRQ, "%jd");
return (retval);
}
示例10: sbus_print_child
static int
sbus_print_child(device_t dev, device_t child)
{
struct sbus_devinfo *dinfo;
struct resource_list *rl;
int rv;
dinfo = device_get_ivars(child);
rl = &dinfo->sdi_rl;
rv = bus_print_child_header(dev, child);
rv += resource_list_print_type(rl, "mem", SYS_RES_MEMORY, "%#lx");
rv += resource_list_print_type(rl, "irq", SYS_RES_IRQ, "%ld");
rv += bus_print_child_footer(dev, child);
return (rv);
}
示例11: nexus_print_all_resources
static int
nexus_print_all_resources(device_t dev)
{
struct nexus_device *ndev = DEVTONX(dev);
struct resource_list *rl = &ndev->nx_resources;
int retval = 0;
if (SLIST_FIRST(rl) || ndev->nx_pcibus != -1)
retval += kprintf(" at");
retval += resource_list_print_type(rl, "port", SYS_RES_IOPORT, "%#lx");
retval += resource_list_print_type(rl, "iomem", SYS_RES_MEMORY, "%#lx");
retval += resource_list_print_type(rl, "irq", SYS_RES_IRQ, "%ld");
return retval;
}
示例12: print_all_resources
static int
print_all_resources(device_t dev)
{
struct canbus_device *cbdev =
(struct canbus_device *)device_get_ivars(dev);
struct resource_list *rl = &cbdev->cbdev_resources;
int retval = 0;
if (STAILQ_FIRST(rl))
retval += printf(" at");
retval += resource_list_print_type(rl, "port", SYS_RES_IOPORT, "%#lx");
retval += resource_list_print_type(rl, "iomem", SYS_RES_MEMORY, "%#lx");
retval += resource_list_print_type(rl, "irq", SYS_RES_IRQ, "%ld");
return retval;
}
示例13: lbc_print_child
static int
lbc_print_child(device_t dev, device_t child)
{
struct lbc_devinfo *di;
struct resource_list *rl;
int rv;
di = device_get_ivars(child);
rl = &di->di_res;
rv = 0;
rv += bus_print_child_header(dev, child);
rv += resource_list_print_type(rl, "mem", SYS_RES_MEMORY, "%#jx");
rv += resource_list_print_type(rl, "irq", SYS_RES_IRQ, "%jd");
rv += bus_print_child_footer(dev, child);
return (rv);
}
示例14: nexus_print_child
static int
nexus_print_child(device_t bus, device_t child)
{
struct nexus_device *ndev = DEVTONX(child);
struct resource_list *rl = &ndev->nx_resources;
int retval = 0;
retval += bus_print_child_header(bus, child);
retval += resource_list_print_type(rl, "port", SYS_RES_IOPORT, "%#lx");
retval += resource_list_print_type(rl, "iomem", SYS_RES_MEMORY, "%#lx");
retval += resource_list_print_type(rl, "irq", SYS_RES_IRQ, "%ld");
if (ndev->nx_pcibus != -1)
retval += printf(" pcibus %d", ndev->nx_pcibus);
if (device_get_flags(child))
retval += printf(" flags %#x", device_get_flags(child));
retval += printf(" on motherboard\n"); /* XXX "motherboard", ick */
return (retval);
}
示例15: unin_chip_probe_nomatch
static void
unin_chip_probe_nomatch(device_t dev, device_t child)
{
struct unin_chip_devinfo *dinfo;
struct resource_list *rl;
const char *type;
if (bootverbose) {
dinfo = device_get_ivars(child);
rl = &dinfo->udi_resources;
if ((type = ofw_bus_get_type(child)) == NULL)
type = "(unknown)";
device_printf(dev, "<%s, %s>", type, ofw_bus_get_name(child));
resource_list_print_type(rl, "mem", SYS_RES_MEMORY, "%#lx");
resource_list_print_type(rl, "irq", SYS_RES_IRQ, "%ld");
printf(" (no driver attached)\n");
}
}