[Mesa-dev] [PATCH v2] pipe-loader: fix build of dynamic pipe-drivers
Jan Vesely
jan.vesely at rutgers.edu
Wed Aug 2 17:57:06 UTC 2017
The patch still causes segfaults because you pass NULL at
core/device.cpp:45
yet unconditionally access the pointer at pipe_loader.c:130
Jan
On Wed, 2017-08-02 at 18:44 +0200, Nicolai Hähnle wrote:
> Thanks! I'll take that as a Tested-by.
>
> On 02.08.2017 18:43, Andy Furniss wrote:
> > Building OK with this.
> >
> >
> > Nicolai Hähnle wrote:
> > > From: Nicolai Hähnle <nicolai.haehnle at amd.com>
> > >
> > > v2: add libxmlconfig.la to the dynamic pipe_radeonsi driver
> > >
> > > Fixes: bc7f41e11d3 ("gallium: add pipe_screen_config to screen_create
> > > functions")
> > > Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=102014
> > > --
> > > I believe this is the right place to add it; the error reported by
> > > Andy was missing driQueryOptionb, which makes sense since this is now
> > > used in si_pipe.c.
> > > ---
> > > src/gallium/targets/pipe-loader/Makefile.am | 1 +
> > > src/gallium/targets/pipe-loader/pipe_r300.c | 2 +-
> > > src/gallium/targets/pipe-loader/pipe_r600.c | 2 +-
> > > src/gallium/targets/pipe-loader/pipe_radeonsi.c | 4 ++--
> > > 4 files changed, 5 insertions(+), 4 deletions(-)
> > >
> > > diff --git a/src/gallium/targets/pipe-loader/Makefile.am
> > > b/src/gallium/targets/pipe-loader/Makefile.am
> > > index 400b198..db492c5 100644
> > > --- a/src/gallium/targets/pipe-loader/Makefile.am
> > > +++ b/src/gallium/targets/pipe-loader/Makefile.am
> > > @@ -146,6 +146,7 @@ pipe_radeonsi_la_LIBADD = \
> > > $(top_builddir)/src/gallium/drivers/radeon/libradeon.la \
> > > $(top_builddir)/src/gallium/drivers/radeonsi/libradeonsi.la \
> > > $(top_builddir)/src/amd/common/libamd_common.la \
> > > + $(top_builddir)/src/util/libxmlconfig.la \
> > > $(LIBDRM_LIBS) \
> > > $(RADEON_LIBS) \
> > > $(AMDGPU_LIBS)
> > > diff --git a/src/gallium/targets/pipe-loader/pipe_r300.c
> > > b/src/gallium/targets/pipe-loader/pipe_r300.c
> > > index 0dcc019..8aa1ba8 100644
> > > --- a/src/gallium/targets/pipe-loader/pipe_r300.c
> > > +++ b/src/gallium/targets/pipe-loader/pipe_r300.c
> > > @@ -9,7 +9,7 @@ create_screen(int fd, const struct pipe_screen_config
> > > *config)
> > > {
> > > struct radeon_winsys *sws;
> > > - sws = radeon_drm_winsys_create(fd, flags, r300_screen_create);
> > > + sws = radeon_drm_winsys_create(fd, config, r300_screen_create);
> > > return sws ? debug_screen_wrap(sws->screen) : NULL;
> > > }
> > > diff --git a/src/gallium/targets/pipe-loader/pipe_r600.c
> > > b/src/gallium/targets/pipe-loader/pipe_r600.c
> > > index 0eedde7..a6051aa 100644
> > > --- a/src/gallium/targets/pipe-loader/pipe_r600.c
> > > +++ b/src/gallium/targets/pipe-loader/pipe_r600.c
> > > @@ -9,7 +9,7 @@ create_screen(int fd, const struct pipe_screen_config
> > > *config)
> > > {
> > > struct radeon_winsys *rw;
> > > - rw = radeon_drm_winsys_create(fd, flags, r600_screen_create);
> > > + rw = radeon_drm_winsys_create(fd, config, r600_screen_create);
> > > return rw ? debug_screen_wrap(rw->screen) : NULL;
> > > }
> > > diff --git a/src/gallium/targets/pipe-loader/pipe_radeonsi.c
> > > b/src/gallium/targets/pipe-loader/pipe_radeonsi.c
> > > index 2d33d0e..2defc52 100644
> > > --- a/src/gallium/targets/pipe-loader/pipe_radeonsi.c
> > > +++ b/src/gallium/targets/pipe-loader/pipe_radeonsi.c
> > > @@ -12,10 +12,10 @@ create_screen(int fd, const struct
> > > pipe_screen_config *config)
> > > struct radeon_winsys *rw;
> > > /* First, try amdgpu. */
> > > - rw = amdgpu_winsys_create(fd, flags, radeonsi_screen_create);
> > > + rw = amdgpu_winsys_create(fd, config, radeonsi_screen_create);
> > > if (!rw)
> > > - rw = radeon_drm_winsys_create(fd, flags, radeonsi_screen_create);
> > > + rw = radeon_drm_winsys_create(fd, config, radeonsi_screen_create);
> > > return rw ? debug_screen_wrap(rw->screen) : NULL;
> > > }
> > >
>
> _______________________________________________
> mesa-dev mailing list
> mesa-dev at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/mesa-dev
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: This is a digitally signed message part
URL: <https://lists.freedesktop.org/archives/mesa-dev/attachments/20170802/b5bb5f62/attachment-0001.sig>
More information about the mesa-dev
mailing list