Age | Commit message (Collapse) | Author |
|
|
|
|
|
|
|
ago.
|
|
if you disable the device.
noticed by deraadt@.
|
|
useful, and driver shouldn't need to know about ``ticks''.
|
|
duplicated code. Also, switch the dma_lock to a rwlock (it never should
have been a spinlock) and move it and some other accounting data into
the dma structure, not the main softc.
Finally, the funcitons in drm_dma are tiny, move them in with the rest
of the dma_bufs api in drm_bufs and remove the file.
|
|
equivalent.
|
|
auth list. now we only need the one tree. Makes things a little neater,
and smaller.
|
|
their arguments for a while. Actually go through the code and remove the
extraneous arguments. Makes things easier to read.
|
|
removes the custom code in there, so shrinks the kernel by a few bytes.
Convert other code to deal with data structure changes.
|
|
|
|
The next few commits will convert calls to drm_pci_alloc (which I hate)
over to this new api, and convert other handrolled stuff over too.
First part of my cleaning up bus_dma useage in drm.
|
|
Found by LLVM/Clang Static Analyzer.
ok oga@
|
|
small functions in it. Move them to main driver file.
|
|
one (not particlarly large) function in it.
|
|
|
|
push cliprects into the kernel anymore so no op the ioctls. The only
consumer of this information died a couple of months ago.
When i've got removal of these calls from userland upstream i'm going to
remove them from the interface entirely.
|
|
ok oga@
|
|
ok oga@
|
|
|
|
dma_bufs; allow the driver to provide the size and not have the private
data pointer. only radeon only needs this so far, but intel with GEM
also needs it.
Postclose was only used for freeing said private data, so this allows me
to remove the postclose callback and rename preclose to close.
|
|
|
|
setup the drm_attach_args with the needed information.
require interface version 1.1 libdrm has been requesting it for ages),
which means that we can set the busid string at attach time. (generated in
drm_attach_pci), also pass in the interrupt line and bst.
Now we don't need dev->pa at all, so remove it, finally.
|
|
other way round. More dev->pa reduction
|
|
the ioctl handler.
|
|
|
|
size.
kill (empty) drm_mem_{un,}init() while here.
|
|
just put a vblank_pipes argument to the driver structure which tells us
how many to set up
this means that intel doesn't lose all vblank count on vtswitch (it
disables the interrupt there), i've heard of a few uvm_faults where this
happens as well as things just going wrong.
This was suggested by Keith Packard who provided a different diff for
drm.git.
|
|
using the drm_maps interface (this was done for inteldrm a few days
ago). All drivers now ignore the mmio_offset argument that the init
ioctl takes.
This clears up the code and makes sure that drm_ioremap_core() doesn't
need the vga_pci_map inteface anymore, so we don't have to pass in the
vga softc anymore. We also get to kill the drm_resource_{start,length}
linux-alike functions since we just calculate all the requisite offsets
at startup and cache those we need. This now means that technically the
only driver that needs the vga_pci_map api is inteldrm (due to sharing
with intagp issues), though this diff doesn't convert them over.
|
|
so just inline it there.
also remove dev->pci_vendor and dev->pci_device, and insert pci_device
into the one place any of them are needed (inteldrm's interface can give
this info to the X driver. to remove that you'd need to fix X too).
|
|
vga1 at pci0
inteldrm0 at vga1
to
vga1 at pci0
inteldrm0 at vga1
drm0 at inteldrm0
i.e. a similar scheme to audio(4) where the interface attaches on top of
the wildly different drivers. This helps to clean up the code a lot
(more is coming) and help me start to move drm to being essentially bus
independent, which will help in the future.
|
|
the attach function. First step towards splitting drm off as it's own
(bus independant) device, as it should be.
|
|
|
|
on rather old xservers. Said old xservers haven't been around in quite a
long time so just remove them.
Since the only function left in drm_fops.c is a small helper function,
just move it to drm_drv.c and nuke the redundant file.
no one objected when I said I was going to do this.
|
|
in the callback structure, just use a bunch of ORed together bits. This
has been annoying me for ages.
|
|
Before it was based on a static array with flags. Instead, let the
driver provide an ioctl callback, which deals with things appropriately.
Makes the code a bit easier to read, and also drops just over 5k on an
amd64 kernel build with all drm drivers enabled.
Tested by a few.
|
|
was the i915 vblank swap ioctl, which just went kaput.
|
|
won't be). It doesn't need to block interrupts anymore so switch to
IPL_NONE.
|
|
Prompted by deraadt, kettenis@.
|
|
|
|
them wrong in several cases that i've noticed and Merging when needed is
still fairly simple, anyway. This shaves another 500 bytes from an amd64
kernel due to not having to flip the sign on some things. It also stops
my eyes bleeding.
Tested by a few along with the last diff that went in.
|
|
filling in a pre-allocated one on each attach.
Makes the code a bunch nicer, shrinks a kernel by about 1.5k on amd64,
helps with my sanity, and paves way for later changes.
Tested by a few for a couple of weeks now.
|
|
held a lock over all driver ioctls in order to be ``mpsafe''. Stop lying
to ourselves for a start. This code is not fully mpsafe, and should not
pretend to be so. Put the locking around where it should, and rely on
biglock for the rest. This will need to be fixed, but avoids some of the
horrible that we have right now.
Tested by many over a long time and several iterations.
|
|
directly. While i'm here, factor out some common functionality into a
separate function, and kill some typedefs (man this code is full of
them...). Shaves another 450 bytes off the kernel.
Tested by ckuethe and Paul de Weerd, thanks.
|
|
|
|
userland asks for these stats, and we stopped recording anything
interesting a while back.
|
|
|
|
should shrink the kernel somewhat. For some strange reason I was unaware
of this api when I pulled in these changes.
tested by myself and Paul de Weerd, thanks!
|
|
|