[RFC libdrm] Add NVIDIA Tegra support

2012-12-05 Thread Arto Merilainen
On 12/04/2012 05:13 PM, Thierry Reding wrote: > +int drm_tegra_open(const char *path, struct drm_tegra **devicep) > +{ > + struct drm_tegra *device; > + int err; > + > + if (!path || !devicep) > + return -EINVAL; > + > + device = calloc(1, sizeof(*device)); > +

[RFC libdrm] Add NVIDIA Tegra support

2012-12-05 Thread Thierry Reding
On Wed, Dec 05, 2012 at 09:39:11AM +0200, Arto Merilainen wrote: > On 12/04/2012 05:13 PM, Thierry Reding wrote: > >+int drm_tegra_open(const char *path, struct drm_tegra **devicep) > >+{ > >+ struct drm_tegra *device; > >+ int err; > >+ > >+ if (!path || !devicep) > >+

Re: [RFC libdrm] Add NVIDIA Tegra support

2012-12-05 Thread Arto Merilainen
On 12/04/2012 05:13 PM, Thierry Reding wrote: +int drm_tegra_open(const char *path, struct drm_tegra **devicep) +{ + struct drm_tegra *device; + int err; + + if (!path || !devicep) + return -EINVAL; + + device = calloc(1, sizeof(*device)); + if (!device

Re: [RFC libdrm] Add NVIDIA Tegra support

2012-12-04 Thread Thierry Reding
On Wed, Dec 05, 2012 at 09:39:11AM +0200, Arto Merilainen wrote: > On 12/04/2012 05:13 PM, Thierry Reding wrote: > >+int drm_tegra_open(const char *path, struct drm_tegra **devicep) > >+{ > >+ struct drm_tegra *device; > >+ int err; > >+ > >+ if (!path || !devicep) > >+

[RFC libdrm] Add NVIDIA Tegra support

2012-12-04 Thread Thierry Reding
On Tue, Dec 04, 2012 at 09:28:25AM -0600, Rob Clark wrote: > On Tue, Dec 4, 2012 at 9:13 AM, Thierry Reding > wrote: > > +int drm_tegra_bo_new(struct drm_tegra *device, uint32_t flags, uint32_t > > size, > > +struct drm_tegra_bo **bop) > > +{ > > + struct drm_tegra_gem_c

[RFC libdrm] Add NVIDIA Tegra support

2012-12-04 Thread Thierry Reding
Add the libdrm_tegra helper library to encapsulate Tegra-specific interfaces to the DRM. Furthermore, Tegra is added to the list of supported chips in the modetest and vbltest programs. Signed-off-by: Thierry Reding --- Makefile.am | 6 +- configure.ac | 15 ++- in

[RFC libdrm] Add NVIDIA Tegra support

2012-12-04 Thread Thierry Reding
Hi, I mentioned in a reply to Terje's patch series for 2D acceleration that I had prototyped some libdrm support a few weeks back. I've spent a bit of time cleaning it up and decided to post it for early review. There's really not much interesting code here. A basic API is provided along with two

[RFC libdrm] Add NVIDIA Tegra support

2012-12-04 Thread Rob Clark
On Tue, Dec 4, 2012 at 9:13 AM, Thierry Reding wrote: > +int drm_tegra_bo_new(struct drm_tegra *device, uint32_t flags, uint32_t size, > +struct drm_tegra_bo **bop) > +{ > + struct drm_tegra_gem_create args; > + struct drm_tegra_bo *bo; > + struct tegra_bo *pr

Re: [RFC libdrm] Add NVIDIA Tegra support

2012-12-04 Thread Thierry Reding
On Tue, Dec 04, 2012 at 09:28:25AM -0600, Rob Clark wrote: > On Tue, Dec 4, 2012 at 9:13 AM, Thierry Reding > wrote: > > +int drm_tegra_bo_new(struct drm_tegra *device, uint32_t flags, uint32_t > > size, > > +struct drm_tegra_bo **bop) > > +{ > > + struct drm_tegra_gem_c

Re: [RFC libdrm] Add NVIDIA Tegra support

2012-12-04 Thread Rob Clark
On Tue, Dec 4, 2012 at 9:13 AM, Thierry Reding wrote: > +int drm_tegra_bo_new(struct drm_tegra *device, uint32_t flags, uint32_t size, > +struct drm_tegra_bo **bop) > +{ > + struct drm_tegra_gem_create args; > + struct drm_tegra_bo *bo; > + struct tegra_bo *pr

[RFC libdrm] Add NVIDIA Tegra support

2012-12-04 Thread Thierry Reding
Add the libdrm_tegra helper library to encapsulate Tegra-specific interfaces to the DRM. Furthermore, Tegra is added to the list of supported chips in the modetest and vbltest programs. Signed-off-by: Thierry Reding --- Makefile.am | 6 +- configure.ac | 15 ++- in

[RFC libdrm] Add NVIDIA Tegra support

2012-12-04 Thread Thierry Reding
Hi, I mentioned in a reply to Terje's patch series for 2D acceleration that I had prototyped some libdrm support a few weeks back. I've spent a bit of time cleaning it up and decided to post it for early review. There's really not much interesting code here. A basic API is provided along with two