diff mbox

[libdrm,2/5] xf86drm: implement drmParseSubsystemType for OpenBSD

Message ID 20161126004034.53376-2-jsg@jsg.id.au (mailing list archive)
State New, archived
Headers show

Commit Message

Jonathan Gray Nov. 26, 2016, 12:40 a.m. UTC
Implement drmParseSubsystemType for OpenBSD by always returning
DRM_BUS_PCI.  No non-pci drm drivers are in the kernel and this is
unlikely to change anytime soon as the existing ones aren't permissively
licensed.

Signed-off-by: Jonathan Gray <jsg@jsg.id.au>
---
 xf86drm.c | 2 ++
 1 file changed, 2 insertions(+)

Comments

Emil Velikov Nov. 29, 2016, 7:46 p.m. UTC | #1
On 26 November 2016 at 00:40, Jonathan Gray <jsg@jsg.id.au> wrote:
> Implement drmParseSubsystemType for OpenBSD by always returning
> DRM_BUS_PCI.  No non-pci drm drivers are in the kernel and this is
> unlikely to change anytime soon as the existing ones aren't permissively
> licensed.
>
A few noticeable X11 MIT style licensed drivers include qxl, vgem and
virtio. Two of which PCI ones and vgem in it's own unique category ;-)

There was a question about re-licensing [some] drivers a few years ago
at XDC in France. IIRC devs were fine with it, yet it doesn't seem
like things changed much.
Have you/fellow BSD developers considered reaching out [as a group] to
interested drivers/developers ? Pardon if I've already
mentioned/already asked about this.

Thanks
Emil
Jonathan Gray Nov. 30, 2016, 12:23 a.m. UTC | #2
On Tue, Nov 29, 2016 at 07:46:31PM +0000, Emil Velikov wrote:
> On 26 November 2016 at 00:40, Jonathan Gray <jsg@jsg.id.au> wrote:
> > Implement drmParseSubsystemType for OpenBSD by always returning
> > DRM_BUS_PCI.  No non-pci drm drivers are in the kernel and this is
> > unlikely to change anytime soon as the existing ones aren't permissively
> > licensed.
> >
> A few noticeable X11 MIT style licensed drivers include qxl, vgem and
> virtio. Two of which PCI ones and vgem in it's own unique category ;-)
> 
> There was a question about re-licensing [some] drivers a few years ago
> at XDC in France. IIRC devs were fine with it, yet it doesn't seem
> like things changed much.
> Have you/fellow BSD developers considered reaching out [as a group] to
> interested drivers/developers ? Pardon if I've already
> mentioned/already asked about this.
> 
> Thanks
> Emil

There is no particular driver, cirrus, gma500 etc might be nice but
really what limited spare time we have that involves drm is dealt
dealing with the constant churn of i915.
Emil Velikov Nov. 30, 2016, 4:23 p.m. UTC | #3
On 30 November 2016 at 00:23, Jonathan Gray <jsg@jsg.id.au> wrote:
> On Tue, Nov 29, 2016 at 07:46:31PM +0000, Emil Velikov wrote:
>> On 26 November 2016 at 00:40, Jonathan Gray <jsg@jsg.id.au> wrote:
>> > Implement drmParseSubsystemType for OpenBSD by always returning
>> > DRM_BUS_PCI.  No non-pci drm drivers are in the kernel and this is
>> > unlikely to change anytime soon as the existing ones aren't permissively
>> > licensed.
>> >
>> A few noticeable X11 MIT style licensed drivers include qxl, vgem and
>> virtio. Two of which PCI ones and vgem in it's own unique category ;-)
>>
>> There was a question about re-licensing [some] drivers a few years ago
>> at XDC in France. IIRC devs were fine with it, yet it doesn't seem
>> like things changed much.
>> Have you/fellow BSD developers considered reaching out [as a group] to
>> interested drivers/developers ? Pardon if I've already
>> mentioned/already asked about this.
>>
>> Thanks
>> Emil
>
> There is no particular driver, cirrus, gma500 etc might be nice but
> really what limited spare time we have that involves drm is dealt
> dealing with the constant churn of i915.
Ack. AFAICT keeping track is a slightly different ball-game, which
does eat a lot of time.

<offtopic>
Consider reusing/sharing of the kernel compat layer that FreeBSD and
others did. If you haven't already.

As one starts incrementally picking each [git] commit it should be
easier to track regressions and pick fixes.
</offtopic>

-Emil
diff mbox

Patch

diff --git a/xf86drm.c b/xf86drm.c
index 216220c..b355c83 100644
--- a/xf86drm.c
+++ b/xf86drm.c
@@ -2872,6 +2872,8 @@  static int drmParseSubsystemType(int maj, int min)
         return DRM_BUS_PCI;
 
     return -EINVAL;
+#elif defined(__OpenBSD__)
+	return DRM_BUS_PCI;
 #else
 #warning "Missing implementation of drmParseSubsystemType"
     return -EINVAL;