Lines Matching refs:pdev

96 static int mdpy_fb_probe(struct pci_dev *pdev,  in mdpy_fb_probe()  argument
104 ret = pci_enable_device(pdev); in mdpy_fb_probe()
108 ret = pci_request_regions(pdev, "mdpy-fb"); in mdpy_fb_probe()
112 pci_read_config_dword(pdev, MDPY_FORMAT_OFFSET, &format); in mdpy_fb_probe()
113 pci_read_config_dword(pdev, MDPY_WIDTH_OFFSET, &width); in mdpy_fb_probe()
114 pci_read_config_dword(pdev, MDPY_HEIGHT_OFFSET, &height); in mdpy_fb_probe()
116 pci_err(pdev, "format mismatch (0x%x != 0x%x)\n", in mdpy_fb_probe()
122 pci_err(pdev, "width (%d) out of range\n", width); in mdpy_fb_probe()
127 pci_err(pdev, "height (%d) out of range\n", height); in mdpy_fb_probe()
131 pci_info(pdev, "mdpy found: %dx%d framebuffer\n", in mdpy_fb_probe()
134 info = framebuffer_alloc(sizeof(struct mdpy_fb_par), &pdev->dev); in mdpy_fb_probe()
139 pci_set_drvdata(pdev, info); in mdpy_fb_probe()
143 info->fix.smem_start = pci_resource_start(pdev, 0); in mdpy_fb_probe()
144 info->fix.smem_len = pci_resource_len(pdev, 0); in mdpy_fb_probe()
157 pci_err(pdev, "ioremap(pcibar) failed\n"); in mdpy_fb_probe()
167 pci_err(pdev, "mdpy-fb device register failed: %d\n", ret); in mdpy_fb_probe()
171 pci_info(pdev, "fb%d registered\n", info->node); in mdpy_fb_probe()
181 pci_release_regions(pdev); in mdpy_fb_probe()
184 pci_disable_device(pdev); in mdpy_fb_probe()
189 static void mdpy_fb_remove(struct pci_dev *pdev) in mdpy_fb_remove() argument
191 struct fb_info *info = pci_get_drvdata(pdev); in mdpy_fb_remove()
196 pci_release_regions(pdev); in mdpy_fb_remove()
197 pci_disable_device(pdev); in mdpy_fb_remove()