Re: [PATCH] DRM fixed compilation errors and warnings for 2.6.26

2008-07-20 Thread nagaraj s k
Hi Daniel,

Thanks for correcting me, i will work on this and try sending the patch soon
with the mentioned changes.

On Sun, Jul 20, 2008 at 12:05 AM, Daniel Stone <[EMAIL PROTECTED]> wrote:

> On Sat, Jul 19, 2008 at 11:16:58PM +0530, nagaraj s k wrote:
> > @@ -69,7 +69,7 @@ void *drm_realloc(void *oldpt, size_t ol
> >  {
> >  void *pt;
> >
> > -if (!(pt = kmalloc(size, GFP_KERNEL)))
> > +if (!(pt == kmalloc(size, GFP_KERNEL)))
> >  return NULL;
> >  if (oldpt && oldsize) {
> >  memcpy(pt, oldpt, oldsize);
>
> Er, this is absolutely not an error.  You'll note that pt is
> uninitialised, and the odds of a specific piece of uninitialised memory
> pointing to exactly the location kmalloc returns are ... rather low.
>
> It could be rewritten for clarity as:
> pt = kmalloc(size, GFP_KERNEL);
> if (!pt)
>return NULL;
>
> But your patch means the function can practically never actually work.
>
> Cheers,
> Daniel
>
> -BEGIN PGP SIGNATURE-
> Version: GnuPG v1.4.9 (GNU/Linux)
>
> iEYEARECAAYFAkiCM9UACgkQUVYB1rKAgJROuwCeLTSHMG6JQsPYPM+uYHEuGv1L
> 8rMAn21162gICH7wp60D07yYo3PBVM3p
> =ZRpc
> -END PGP SIGNATURE-
>
>
-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/--
___
Dri-devel mailing list
Dri-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dri-devel


Texture compression patents

2008-07-20 Thread Corbin Simpson
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Howdy. I was just going through the r3xx/r5xx bugs, and I noticed that
lots of problems are related to certain texture compression features
being dependent on out-of-tree code. I also noticed that, at least on
R400+ Radeons, we actually have hardware support for such compression,
and I thought that was the case on certain nVidia chipsets, too.

My question is, does anybody know the status on S3TC/DXTC/etc., and if
it's still owned by S3/VIA, and if they might be interested in opening it?

...Oh, I guess that's three questions. :3

~ C.
-BEGIN PGP SIGNATURE-
Version: GnuPG v2.0.9 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEARECAAYFAkiDdscACgkQeCCY8PC5utCuMACgkUhXmqtUqlG53bpYzEAU3rYa
5gIAn3yrrPLVjBrrDQ4TFmo2BHZVn84y
=EJnv
-END PGP SIGNATURE-

-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
--
___
Dri-devel mailing list
Dri-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dri-devel


Re: [PATCH] drm & i915 vblank fixes

2008-07-20 Thread Michel Dänzer
On Sat, 2008-07-19 at 12:54 -0400, Robert Noland wrote:
>  
> One other issue that I spotted while testing is that we initialize
> vblank_disable_allowed to 0.  The only place that it ever becomes true
> is in post modeset.  So, for me... vblanks were never getting disabled.

Yes, that's the intention behind vblank_disable_allowed. :) It's to
prevent the interrupt from getting disabled until the display driver
calls the modeset ioctl, to prevent problems caused by the hardware
frame counter resetting to 0 with 'old' display drivers (meaning ones
that don't know to call the modeset ioctl).


> I'm still (or again) sometimes getting the error about get_vblank_count
> being called on disabled pipe that I need to try and chase down.

I think that's because the 3D driver is trying to sync to a pipe that
the display driver 'disabled'.


-- 
Earthling Michel Dänzer   |  http://tungstengraphics.com
Libre software enthusiast |  Debian, X and DRI developer


-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
--
___
Dri-devel mailing list
Dri-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dri-devel


Re: [PATCH] DRM fixed compilation errors and warnings for 2.6.26

2008-07-20 Thread Bruno Prémont
On Sat, 19 July 2008 "nagaraj s k" <[EMAIL PROTECTED]> wrote:
> Hi ALL,
> 
> Sorry about repetitive mails, i forgot to add the main mail list,
> getting used to the procedure to send patches.
> 
> This is my second submission (looks like first mail lost in the
> malling list 10 days earlier). I did my best to follow the guidelines
> put forth for newbies. Please feel free for any comments and
> suggestions.Currently working on 2.6.26.I have applied this patch to
> my existing kernel and all looks fine, also checked for white space.
> 
> Fixed few simple compilation errors like logical assignment
> operators,white space between pointer variables
>  and cleaned up to few warnings.
> 
> Signed-off-by: Nagaraj SK <[EMAIL PROTECTED]>
>  ___
> 
> --- linux-2.6.26/drivers/char/drm/drm_memory.c2008-07-14
> 03:21:29.0 +0530
> +++ linux-staging/drivers/char/drm/drm_memory.c2008-07-20
> 00:22:51.0 +0530
> @@ -69,7 +69,7 @@ void *drm_realloc(void *oldpt, size_t ol
>  {
>  void *pt;
> 
> -if (!(pt = kmalloc(size, GFP_KERNEL)))
> +if (!(pt == kmalloc(size, GFP_KERNEL)))
>  return NULL;
>  if (oldpt && oldsize) {
>  memcpy(pt, oldpt, oldsize);

The original code is correct, your change causes memory leak and
drm_realloc() to return NULL in nearly all cases (and Oops if
kmalloc fails and uninitialized pt happens to be NULL).

The original code checks if kmalloc worked and returns NULL if not.
Note the () around the assignment, the original code block means:

void *pt;

pt = kmalloc(size, GFP_KERNEL);
if (!pt)
return NULL;

Bruno

-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
--
___
Dri-devel mailing list
Dri-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dri-devel


[Bug 10985] backlight doesn't come on after resume with i915 video

2008-07-20 Thread bugme-daemon
http://bugzilla.kernel.org/show_bug.cgi?id=10985





--- Comment #34 from [EMAIL PROTECTED]  2008-07-20 03:28 ---
(In reply to comment #32)
> Jon, can you try the drm tree?  It's working well on my 855 test machine and 
> is
> easier for me to test/generate diffs against.

Sure. Actually this is easier for me too. I've tried that tree (HEAD
7cfdba2b30), the backlight does not come on. Would the register dumps be
useful?


-- 
Configure bugmail: http://bugzilla.kernel.org/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug, or are watching the assignee.

-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
--
___
Dri-devel mailing list
Dri-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dri-devel


Re: [RFC] DRM developer guide

2008-07-20 Thread Maarten Maathuis
On 6/23/08, Jesse Barnes <[EMAIL PROTECTED]> wrote:
> On Sunday, June 22, 2008 6:55 am Pekka Paalanen wrote:
>  > On Thu, 19 Jun 2008 15:13:51 -0700
>  >
>  > Jesse Barnes <[EMAIL PROTECTED]> wrote:
>  > > In a shameless attempt to capitalize on the recent enthusiasm for
>  > > documenting things, I've put together a skeletal DRM developer guide.
>  >
>  > Yay! \o/
>  >
>  > > The attached PDF was generated from the attached DocBook template, and
>  > > references Linux kernel doc comments in the sources.  Unfortunately, the
>  > > current DRM has a mix of Linux kernel doc and doxygen documentation, and
>  > > only some of the very recent stuff is actually accurate and usable.
>  >
>  > Btw. which should be used in DRM, Linux kernel doc or doxygen? Without the
>  > bsd directory the answer would be obvious to me.
>
>
> I don't know... that's one of my questions too. :)  Linux stuff tends to use
>  kernel doc/DocBook, but it looks like the original DRI stuff was in doxygen.
>  I like the look of kernel doc a bit better, but I don't know much about the
>  tool capabilities.
>
>
>  > I have only a couple minor comments as a newbie.
>  >
>  > Driver initialization:
>  > - talks about struct drm_device, then the example has struct drm_driver.
>  > Is there a difference?
>
>
> Yes, I'll clarify that.
>
>
>  > - proper indenting of sample code missing, makes the drm_driver example
>  > a bit awkward to read
>
>
> I'll try to fix that up, I'm still wrestling with DocBook.
>
>
>  > VBlank event handling:
>  > - the last paragraph "...vblank functions into no-ops." seems
>  > contradicting the previous paragraph.
>
>
> That section needs more work (along with the rest), I'll try to add more
>  detail.
>
>
>  > I'm very much looking forward to the next revision with more
>  > goodies. :-)
>
>
> Cool, thanks for checking it out.
>
>  I'd definitely encourage people to try porting current drivers to the new 
> mode
>  setting & memory management interfaces; I think it would encourage a lot of
>  questions, and the answers could go straight into the doc, which should help
>  everyone.
>
>  Thanks,
>
> Jesse
>
>
>  -
>  Check out the new SourceForge.net Marketplace.
>  It's the best place to buy or sell services for
>  just about anything Open Source.
>  http://sourceforge.net/services/buy/index.php
>  --
>  ___
>  Dri-devel mailing list
>  Dri-devel@lists.sourceforge.net
>  https://lists.sourceforge.net/lists/listinfo/dri-devel
>

Has it been considered to put this up somewhere for autogeneration?

I'm not very familiar with these documentation schemes, but i imagine
it's a matter of putting appropriately styled comments in code and
they'll appear?

It would be a shame if this got lost in the drift of time.

Maarten.

-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
--
___
Dri-devel mailing list
Dri-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dri-devel