Lines Matching refs:dev

126 	struct device		*dev;  member
198 dev_dbg(controller->dev, "invalid state for %ld,us %d\n", in spi_qup_set_state()
480 dev_warn(qup->dev, "cannot set RUN state\n"); in spi_qup_do_dma()
550 dev_warn(qup->dev, "cannot set RUN state\n"); in spi_qup_do_pio()
556 dev_warn(qup->dev, "cannot set PAUSE state\n"); in spi_qup_do_pio()
565 dev_warn(qup->dev, "cannot set RUN state\n"); in spi_qup_do_pio()
606 dev_warn(controller->dev, "OUTPUT_OVER_RUN\n"); in spi_qup_qup_irq()
608 dev_warn(controller->dev, "INPUT_UNDER_RUN\n"); in spi_qup_qup_irq()
610 dev_warn(controller->dev, "OUTPUT_UNDER_RUN\n"); in spi_qup_qup_irq()
612 dev_warn(controller->dev, "INPUT_OVER_RUN\n"); in spi_qup_qup_irq()
619 dev_warn(controller->dev, "CLK_OVER_RUN\n"); in spi_qup_qup_irq()
621 dev_warn(controller->dev, "CLK_UNDER_RUN\n"); in spi_qup_qup_irq()
665 dev_err(controller->dev, "too big size for loopback %d > %d\n", in spi_qup_io_prep()
672 dev_err(controller->dev, "fail to set frequency %d", in spi_qup_io_prep()
708 dev_err(controller->dev, "cannot set RESET state\n"); in spi_qup_io_config()
760 dev_err(controller->dev, "unknown mode = %d\n", in spi_qup_io_config()
929 struct device *dev = spi->dev; in spi_qup_init_dma() local
933 host->dma_rx = dma_request_chan(dev, "rx"); in spi_qup_init_dma()
937 host->dma_tx = dma_request_chan(dev, "tx"); in spi_qup_init_dma()
956 dev_err(dev, "failed to configure RX channel\n"); in spi_qup_init_dma()
962 dev_err(dev, "failed to configure TX channel\n"); in spi_qup_init_dma()
999 struct device *dev; in spi_qup_probe() local
1004 dev = &pdev->dev; in spi_qup_probe()
1013 cclk = devm_clk_get(dev, "core"); in spi_qup_probe()
1017 iclk = devm_clk_get(dev, "iface"); in spi_qup_probe()
1022 if (of_property_read_u32(dev->of_node, "spi-max-frequency", &max_freq)) in spi_qup_probe()
1026 dev_err(dev, "invalid clock frequency %d\n", max_freq); in spi_qup_probe()
1030 host = spi_alloc_host(dev, sizeof(struct spi_qup)); in spi_qup_probe()
1032 dev_err(dev, "cannot allocate host\n"); in spi_qup_probe()
1037 if (of_property_read_u32(dev->of_node, "num-cs", &num_cs) || in spi_qup_probe()
1050 host->dev.of_node = pdev->dev.of_node; in spi_qup_probe()
1059 controller->dev = dev; in spi_qup_probe()
1071 controller->qup_v1 = (uintptr_t)of_device_get_match_data(dev); in spi_qup_probe()
1081 dev_err(dev, "cannot enable core clock\n"); in spi_qup_probe()
1088 dev_err(dev, "cannot enable iface clock\n"); in spi_qup_probe()
1112 dev_info(dev, "IN:block:%d, fifo:%d, OUT:block:%d, fifo:%d\n", in spi_qup_probe()
1120 dev_err(dev, "cannot set RESET state\n"); in spi_qup_probe()
1142 ret = devm_request_irq(dev, irq, spi_qup_qup_irq, in spi_qup_probe()
1147 pm_runtime_set_autosuspend_delay(dev, MSEC_PER_SEC); in spi_qup_probe()
1148 pm_runtime_use_autosuspend(dev); in spi_qup_probe()
1149 pm_runtime_set_active(dev); in spi_qup_probe()
1150 pm_runtime_enable(dev); in spi_qup_probe()
1152 ret = devm_spi_register_controller(dev, host); in spi_qup_probe()
1159 pm_runtime_disable(&pdev->dev); in spi_qup_probe()
1273 struct spi_controller *host = dev_get_drvdata(&pdev->dev); in spi_qup_remove()
1277 ret = pm_runtime_get_sync(&pdev->dev); in spi_qup_remove()
1282 dev_warn(&pdev->dev, "failed to reset controller (%pe)\n", in spi_qup_remove()
1288 dev_warn(&pdev->dev, "failed to resume, skip hw disable (%pe)\n", in spi_qup_remove()
1294 pm_runtime_put_noidle(&pdev->dev); in spi_qup_remove()
1295 pm_runtime_disable(&pdev->dev); in spi_qup_remove()