diff options
author | Enrico Weigelt, metux IT consult <info@metux.net> | 2024-05-08 16:04:16 +0200 |
---|---|---|
committer | Enrico Weigelt, metux IT consult <info@metux.net> | 2024-05-08 16:04:16 +0200 |
commit | e7329f46343ce750e9ee8ae333047a4452d551fc (patch) | |
tree | 257a97adff1a390c11f79476bcb600302820db29 /src/mga_driver.c | |
parent | 0d0ae3fd54746ed9bed8ca96269e182187176dc8 (diff) |
use XNFcallocarray() instead of xnfcalloc macro
xnfcalloc is just an alias for XNFcallocarray() that doesn't seem to serve
any practical purpose, so it can go away once all drivers stopped using it.
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
Part-of: <https://gitlab.freedesktop.org/xorg/driver/xf86-video-mga/-/merge_requests/9>
Diffstat (limited to 'src/mga_driver.c')
-rw-r--r-- | src/mga_driver.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/mga_driver.c b/src/mga_driver.c index f4b8f12..e3bb9dd 100644 --- a/src/mga_driver.c +++ b/src/mga_driver.c @@ -666,7 +666,7 @@ MGAGetRec(ScrnInfoPtr pScrn) if (pScrn->driverPrivate != NULL) return TRUE; - pScrn->driverPrivate = xnfcalloc(sizeof(MGARec), 1); + pScrn->driverPrivate = XNFcallocarray(sizeof(MGARec), 1); /* Initialise it */ MGAPTR(pScrn)->Dac = DacInit; @@ -767,7 +767,7 @@ MGAPciProbe(DriverPtr drv, int entity_num, struct pci_device * dev, MGAEntityIndex = xf86AllocateEntityPrivateIndex(); pPriv = xf86GetEntityPrivate(pScrn->entityList[0], MGAEntityIndex); if (!pPriv->ptr) { - pPriv->ptr = xnfcalloc(sizeof(MGAEntRec), 1); + pPriv->ptr = XNFcallocarray(sizeof(MGAEntRec), 1); pMgaEnt = pPriv->ptr; pMgaEnt->lastInstance = -1; } else { @@ -987,7 +987,7 @@ MGAProbe(DriverPtr drv, int flags) MGAEntityIndex = xf86AllocateEntityPrivateIndex(); pPriv = xf86GetEntityPrivate(pScrn->entityList[0], MGAEntityIndex); if (!pPriv->ptr) { - pPriv->ptr = xnfcalloc(sizeof(MGAEntRec), 1); + pPriv->ptr = XNFcallocarray(sizeof(MGAEntRec), 1); pMgaEnt = pPriv->ptr; pMgaEnt->lastInstance = -1; } else { @@ -2340,7 +2340,7 @@ MGAPreInit(ScrnInfoPtr pScrn, int flags) * Setup the ClockRanges, which describe what clock ranges are available, * and what sort of modes they can be used for. */ - clockRanges = xnfcalloc(sizeof(ClockRange), 1); + clockRanges = XNFcallocarray(sizeof(ClockRange), 1); clockRanges->next = NULL; clockRanges->minClock = pMga->MinClock; clockRanges->maxClock = pMga->MaxClock; |