65fea56f17cd614bc8908264df980a62e1931468vboxsync/*
65fea56f17cd614bc8908264df980a62e1931468vboxsync * Copyright (c) 2009 Tiago Vignatti
65fea56f17cd614bc8908264df980a62e1931468vboxsync *
65fea56f17cd614bc8908264df980a62e1931468vboxsync * Permission is hereby granted, free of charge, to any person
65fea56f17cd614bc8908264df980a62e1931468vboxsync * obtaining a copy of this software and associated documentation
65fea56f17cd614bc8908264df980a62e1931468vboxsync * files (the "Software"), to deal in the Software without
65fea56f17cd614bc8908264df980a62e1931468vboxsync * restriction, including without limitation the rights to use,
65fea56f17cd614bc8908264df980a62e1931468vboxsync * copy, modify, merge, publish, distribute, sublicense, and/or sell
65fea56f17cd614bc8908264df980a62e1931468vboxsync * copies of the Software, and to permit persons to whom the
65fea56f17cd614bc8908264df980a62e1931468vboxsync * Software is furnished to do so, subject to the following
65fea56f17cd614bc8908264df980a62e1931468vboxsync * conditions:
65fea56f17cd614bc8908264df980a62e1931468vboxsync *
65fea56f17cd614bc8908264df980a62e1931468vboxsync * The above copyright notice and this permission notice shall be
65fea56f17cd614bc8908264df980a62e1931468vboxsync * included in all copies or substantial portions of the Software.
65fea56f17cd614bc8908264df980a62e1931468vboxsync *
65fea56f17cd614bc8908264df980a62e1931468vboxsync * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
65fea56f17cd614bc8908264df980a62e1931468vboxsync * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
65fea56f17cd614bc8908264df980a62e1931468vboxsync * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
65fea56f17cd614bc8908264df980a62e1931468vboxsync * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
65fea56f17cd614bc8908264df980a62e1931468vboxsync * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
65fea56f17cd614bc8908264df980a62e1931468vboxsync * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
65fea56f17cd614bc8908264df980a62e1931468vboxsync * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
65fea56f17cd614bc8908264df980a62e1931468vboxsync * OTHER DEALINGS IN THE SOFTWARE.
65fea56f17cd614bc8908264df980a62e1931468vboxsync */
65fea56f17cd614bc8908264df980a62e1931468vboxsync
65fea56f17cd614bc8908264df980a62e1931468vboxsync#ifndef __XF86VGAARBITER_H
65fea56f17cd614bc8908264df980a62e1931468vboxsync#define __XF86VGAARBITER_H
65fea56f17cd614bc8908264df980a62e1931468vboxsync
65fea56f17cd614bc8908264df980a62e1931468vboxsync#include "screenint.h"
65fea56f17cd614bc8908264df980a62e1931468vboxsync#include "misc.h"
65fea56f17cd614bc8908264df980a62e1931468vboxsync#include "xf86.h"
65fea56f17cd614bc8908264df980a62e1931468vboxsync
65fea56f17cd614bc8908264df980a62e1931468vboxsync/* Functions */
65fea56f17cd614bc8908264df980a62e1931468vboxsyncextern void xf86VGAarbiterInit(void);
65fea56f17cd614bc8908264df980a62e1931468vboxsyncextern void xf86VGAarbiterFini(void);
65fea56f17cd614bc8908264df980a62e1931468vboxsyncvoid xf86VGAarbiterScrnInit(ScrnInfoPtr pScrn);
65fea56f17cd614bc8908264df980a62e1931468vboxsyncextern Bool xf86VGAarbiterWrapFunctions(void);
65fea56f17cd614bc8908264df980a62e1931468vboxsyncextern void xf86VGAarbiterLock(ScrnInfoPtr pScrn);
65fea56f17cd614bc8908264df980a62e1931468vboxsyncextern void xf86VGAarbiterUnlock(ScrnInfoPtr pScrn);
65fea56f17cd614bc8908264df980a62e1931468vboxsync
65fea56f17cd614bc8908264df980a62e1931468vboxsync/* allow a driver to remove itself from arbiter - really should be
65fea56f17cd614bc8908264df980a62e1931468vboxsync * done in the kernel though */
65fea56f17cd614bc8908264df980a62e1931468vboxsyncextern _X_EXPORT void xf86VGAarbiterDeviceDecodes(ScrnInfoPtr pScrn, int rsrc);
65fea56f17cd614bc8908264df980a62e1931468vboxsync
65fea56f17cd614bc8908264df980a62e1931468vboxsync/* DRI and arbiter are really not possible together,
65fea56f17cd614bc8908264df980a62e1931468vboxsync * you really want to remove the card from arbitration if you can */
65fea56f17cd614bc8908264df980a62e1931468vboxsyncextern _X_EXPORT Bool xf86VGAarbiterAllowDRI(ScreenPtr pScreen);
65fea56f17cd614bc8908264df980a62e1931468vboxsync
65fea56f17cd614bc8908264df980a62e1931468vboxsync#endif /* __XF86VGAARBITER_H */