Hi

On Fri, Jan 31, 2014 at 9:58 PM, Tom Stellard <t...@stellard.net> wrote:
> On Thu, Jan 30, 2014 at 10:16:41PM +0000, Emil Velikov wrote:
>> On 27/01/14 16:13, Tom Stellard wrote:
>> > From: Tom Stellard <thomas.stell...@amd.com>
>> >
>> > v2:
>> >    - Add missing call to pipe_loader_drm_release()
>> >    - Fix render node macros
>> >    - Drop render-node configure option
>> > ---
>> >
>> > For reference, version 1 of this patch:
>> > http://lists.freedesktop.org/archives/mesa-dev/2013-October/047296.html
>> >
>> >  .../auxiliary/pipe-loader/pipe_loader_drm.c        | 80 
>> > +++++++++++++++++++++-
>> >  1 file changed, 77 insertions(+), 3 deletions(-)
>> >
>> > diff --git a/src/gallium/auxiliary/pipe-loader/pipe_loader_drm.c 
>> > b/src/gallium/auxiliary/pipe-loader/pipe_loader_drm.c
>> > index 9484db8..7a1af91 100644
>> > --- a/src/gallium/auxiliary/pipe-loader/pipe_loader_drm.c
>> > +++ b/src/gallium/auxiliary/pipe-loader/pipe_loader_drm.c
>> > @@ -49,6 +49,11 @@
>> >  #include "util/u_dl.h"
>> >  #include "util/u_debug.h"
>> >
>> > +#define DRM_RENDER_NODE_DEV_NAME_FORMAT "%s/renderD%d"
>> > +#define DRM_RENDER_NODE_MAX_NODES 63
>> > +#define DRM_RENDER_NODE_MIN_MINOR 128
>> > +#define DRM_RENDER_NODE_MAX_MINOR (DRM_RENDER_NODE_MIN_MINOR + 
>> > DRM_RENDER_NODE_MAX_NODES)
>> > +
>> Hello gents,
>> Slightly silly question here, so plese be gentle. Shouldn't the above
>> defines come from a libdrm header ?
>>
>> Similar to the following (from xf86drm.h)
>>
>> #define DRM_DIR_NAME  "/dev/dri"
>> #define DRM_DEV_NAME  "%s/card%d"
>> #define DRM_CONTROL_DEV_NAME  "%s/controlD%d"
>>
>> -Emil
>
> I'm not sure about this, maybe David has an opinion.

You should use libudev to search for device-nodes. Everything else I
don't really care about. If you want to hard-code the minors, feel
free to do that. So I don't mind adding it to libdrm, but I'd also be
fine if everyone does it themselves. It's a kernel API so it will
never change. And it's not really magic to do that..

Thanks
David
_______________________________________________
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/mesa-dev

Reply via email to