Lines Matching refs:rc
198 int rc;
204 rc = -t4vf_query_params(sc, nitems(param), param, val);
205 if (rc != 0) {
207 "failed to query parameters (pre_init): %d.\n", rc);
208 return (rc);
233 int rc;
236 rc = -t4vf_get_sge_params(sc);
237 if (rc != 0) {
239 "unable to retrieve adapter SGE parameters: %d\n", rc);
240 return (rc);
243 rc = -t4vf_get_rss_glb_config(sc);
244 if (rc != 0) {
246 "unable to retrieve adapter RSS parameters: %d\n", rc);
247 return (rc);
261 rc = -t4vf_get_vfres(sc);
262 if (rc != 0) {
264 "unable to get virtual interface resources: %d\n", rc);
265 return (rc);
283 rc = -t4vf_query_params(sc, 1, ¶m, &val);
284 if (rc == 0)
289 rc = t4_verify_chip_settings(sc);
290 if (rc != 0)
291 return (rc);
324 int itype, iq_avail, navail, rc;
444 rc = pci_alloc_msix(sc->dev, &navail);
446 rc = pci_alloc_msi(sc->dev, &navail);
447 if (rc != 0) {
450 itype, rc, iaq->nirq, navail);
451 return (rc);
463 rc = pci_alloc_msix(sc->dev, &navail);
465 rc = pci_alloc_msi(sc->dev, &navail);
466 if (rc != 0)
469 itype, rc, iaq->nirq, navail);
470 return (rc);
485 int rc = 0, i, j, rqidx, tqidx, n, p, pmask;
512 rc = t4_map_bars_0_and_4(sc);
513 if (rc != 0)
516 rc = -t4vf_prep_adapter(sc);
517 if (rc != 0)
522 rc = ENOTSUP;
540 rc = make_dev_s(&mda, &sc->cdev, "%s", device_get_nameunit(dev));
541 if (rc != 0)
543 rc);
548 rc = ENOTSUP;
563 rc = -t4vf_fw_reset(sc);
564 if (rc != 0) {
565 device_printf(dev, "FW reset failed: %d\n", rc);
578 rc = get_params__pre_init(sc);
579 if (rc != 0)
581 rc = get_params__post_init(sc);
582 if (rc != 0)
585 rc = set_params__post_init(sc);
586 if (rc != 0)
589 rc = t4_map_bar_2(sc);
590 if (rc != 0)
593 rc = t4_create_dma_tag(sc);
594 if (rc != 0)
641 rc = -t4_port_init(sc, sc->mbox, sc->pf, 0, i);
642 if (rc != 0) {
644 i, rc);
655 rc = t4vf_get_vf_mac(sc, p, &n, mac);
656 if (rc == 0 && n == 1)
675 rc = ENXIO;
685 rc = cfg_itype_and_nqueues(sc, &iaq);
686 if (rc != 0)
746 rc = t4_setup_intr_handlers(sc);
747 if (rc != 0) {
749 "failed to setup interrupt handlers: %d\n", rc);
753 rc = bus_generic_attach(dev);
754 if (rc != 0) {
756 "failed to attach all child ports: %d\n", rc);
767 if (rc != 0)
772 return (rc);
798 int rc;
801 rc = priv_check(td, PRIV_DRIVER);
802 if (rc != 0)
803 return (rc);
850 rc = copyout(buf, regs->data, reglen);
905 rc = t4_set_sched_class(sc, (struct t4_sched_params *)data);
908 rc = t4_set_sched_queue(sc, (struct t4_sched_queue *)data);
911 rc = ENOTTY;
914 return (rc);