[PATCH 03/14] dix: introduce gpu screens.

Keith Packard keithp at keithp.com
Wed Jun 20 13:20:42 PDT 2012


Dave Airlie <airlied at gmail.com> writes:

> +int
> +AddGPUScreen(Bool (*pfnInit) (ScreenPtr /*pScreen */ ,
> +                              int /*argc */ ,
> +                              char **      /*argv */
> +                              ),
> +             int argc, char **argv)
> +{
> +    int i;
> +    ScreenPtr pScreen;
> +    Bool ret;
> +
> +    i = screenInfo.numGPUScreens;
> +    if (i == MAXSCREENS)
> +        return -1;
> +
> +    pScreen = (ScreenPtr) calloc(1, sizeof(ScreenRec));
> +    if (!pScreen)
> +        return -1;
> +
> +    ret = init_screen(pScreen, i, TRUE);
> +    if (ret) {
> +        free(pScreen);
> +        return ret;
> +    }

(same complaint as last patch -- init_screen returns int, not Bool)

>      ScreenPtr screens[MAXSCREENS];
> +    int numGPUScreens;
> +    ScreenPtr gpuscreens[MAXSCREENS];

These should probably be different constants.

-- 
keith.packard at intel.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 827 bytes
Desc: not available
URL: <http://lists.x.org/archives/xorg-devel/attachments/20120620/f973a78f/attachment.pgp>


More information about the xorg-devel mailing list