drm/xe: Drop unused param from xe_device_create()

We never used or need anything from the struct pci_device_id there.
And while around, add simple kernel-doc for this function.

Signed-off-by: Michal Wajdeczko <michal.wajdeczko@intel.com>
Reviewed-by: Raag Jadav <raag.jadav@intel.com>
Reviewed-by: Gustavo Sousa <gustavo.sousa@intel.com>
Link: https://patch.msgid.link/20260526195452.20545-3-michal.wajdeczko@intel.com
This commit is contained in:
Michal Wajdeczko 2026-05-26 21:54:47 +02:00
parent e20b4833f4
commit 8a09097b11
3 changed files with 11 additions and 5 deletions

View File

@ -475,8 +475,15 @@ static void xe_device_destroy(struct drm_device *dev, void *dummy)
ttm_device_fini(&xe->ttm);
}
struct xe_device *xe_device_create(struct pci_dev *pdev,
const struct pci_device_id *ent)
/**
* xe_device_create() - Create a new &xe_device instance
* @pdev: the parent &pci_dev
*
* Allocate and initialize a device managed Xe device structure.
*
* Return: pointer to new &xe_device on success, or ERR_PTR on failure.
*/
struct xe_device *xe_device_create(struct pci_dev *pdev)
{
const struct drm_driver *driver = &regular_driver;
struct xe_device *xe;

View File

@ -43,8 +43,7 @@ static inline struct xe_device *ttm_to_xe_device(struct ttm_device *ttm)
return container_of(ttm, struct xe_device, ttm);
}
struct xe_device *xe_device_create(struct pci_dev *pdev,
const struct pci_device_id *ent);
struct xe_device *xe_device_create(struct pci_dev *pdev);
int xe_device_probe_early(struct xe_device *xe);
int xe_device_probe(struct xe_device *xe);
void xe_device_remove(struct xe_device *xe);

View File

@ -1093,7 +1093,7 @@ static int xe_pci_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
if (err)
return err;
xe = xe_device_create(pdev, ent);
xe = xe_device_create(pdev);
if (IS_ERR(xe))
return PTR_ERR(xe);