Re: [Dri-devel] Kernel back-merge ...
On Thu, 25 Sep 2003, Dave Airlie wrote: If Linus thinks your patch goes far enough for him.. I actually usually don't much like whitespace changes, and the one I sent was purely in response to the fact that there already was a lot of whitespace changes in the i810 driver. Don't worry too much about it. The i810 whitespace fixes were fine - it just became obvious that when they fixed something like if(x) to if (x) they still left strange mixes of spaces and tabs on the same line. All my whitespace changes was _literally_ from just editing the DRI CVS merge diff (any lines added) before applying to the kernel tree. I'll happily take more whitespace fixes, I just ask that as long as you play around with whitespace you don't do any other changes. A big whitespace diff that also has a subtle semantic change embedded in it is just too painful. Linus --- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf ___ Dri-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/dri-devel
Re: [Dri-devel] Kernel back-merge ...
On Thu, 2003-09-25 at 22:58, Linus Torvalds wrote: On Thu, 25 Sep 2003, Dave Airlie wrote: If Linus thinks your patch goes far enough for him.. I actually usually don't much like whitespace changes, and the one I sent was purely in response to the fact that there already was a lot of whitespace changes in the i810 driver. Don't worry too much about it. The i810 whitespace fixes were fine - it just became obvious that when they fixed something like if(x) to if (x) they still left strange mixes of spaces and tabs on the same line. All my whitespace changes was _literally_ from just editing the DRI CVS merge diff (any lines added) before applying to the kernel tree. I'll happily take more whitespace fixes, I just ask that as long as you play around with whitespace you don't do any other changes. A big whitespace diff that also has a subtle semantic change embedded in it is just too painful. To me, if I was going to fix part of the whitespace in i810, I might as well fix all of the issues of the same type. diff -bu said that one was non-functional changes. Sorry about the SiS diff. I had done it all in separate stages in my perforce tree, but I didn't commit it to CVS until the work was all done. I probably should have done a two-stage commit there, I just didn't think this project cared about that. If you wanted to review the SiS stuff (which I would love for anyone to do), I have a diff of most of it. The big whitespace cleanup came after a bit of initial porting work, which involved axing a bit of dead code and using some os-independence macros. This should cover the functional changes that came after that: http://people.freebsd.org/~anholt/dri/files/sisdrm-functional.diff -- Eric Anholt[EMAIL PROTECTED] http://people.freebsd.org/~anholt/ [EMAIL PROTECTED] --- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf ___ Dri-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/dri-devel
[Dri-devel] Kernel back-merge ...
Ok, I've merged the current DRI CVS tree from freedesktop.org into the kernel, and as a result I now have another (pretty obvious) diff for back-merging into DRI. I hope somebody with commit access will do this. The merge has three parts: - a real fix for an i830_irq.c misfeature, where the DRI code initializes counters and a wait-queue _after_ having enabled interrupts. Yeah, there shouldn't be any events pending since the thing should be quiescent and we just cleared the interrupt sources, but it's still not good practice. So move the clearing to the pre-irq-install. - Update the Kconfig file for the SiS driver to the new realities of not needing the SISFB driver to compile. This is probably not an issue for anybody who compiles the out-of-kernel version, since they won't be using the kernel configurator, but it's an easier merge, and it's obviously correct. - whitespace fixes. The DRI tree had a number of whitespace fixes to the i810 driver that I merged into the kernel - but whenever I merged a whitespace change I made sure to merge the _proper_ whitespace. No mixed space/tab crud at the beginning of lines. As a result, I now have a pure whitespace diff that I try to push back into the DRI tree. All of these should be totally obvious patches, but they may apply with some offset because I edited out the other parts of the merge. Can somebody apply them or indicate why they shouldn't be applied. [ The whitespace noise should be fine, since there should be no issues with merging this back into XF86 - since all development to the files involved happens either in the kernel tree or in the DRI tree. So it shouldn't cause any merge issues down the line - it only helps merging with the kernel. I obviously don't know what the merge issues are for the *BSD versions.. ] Ok? Linus --- diff --- ### ### Fix counter and waitqueue setup to happen _before_ interrupts can come in. ### diff -u dri-kernel/i830_irq.c v2.5/linux/drivers/char/drm/i830_irq.c --- dri-kernel/i830_irq.c 2003-07-29 03:11:48.0 -0700 +++ v2.5/linux/drivers/char/drm/i830_irq.c 2003-09-25 08:57:07.551573782 -0700 @@ -186,6 +185,9 @@ I830_WRITE16( I830REG_HWSTAM, 0x ); I830_WRITE16( I830REG_INT_MASK_R, 0x0 ); I830_WRITE16( I830REG_INT_ENABLE_R, 0x0 ); + atomic_set(dev_priv-irq_received, 0); + atomic_set(dev_priv-irq_emitted, 0); + init_waitqueue_head(dev_priv-irq_queue); } void DRM(driver_irq_postinstall)( drm_device_t *dev ) { @@ -193,9 +195,6 @@ (drm_i830_private_t *)dev-dev_private; I830_WRITE16( I830REG_INT_ENABLE_R, 0x2 ); - atomic_set(dev_priv-irq_received, 0); - atomic_set(dev_priv-irq_emitted, 0); - init_waitqueue_head(dev_priv-irq_queue); } void DRM(driver_irq_uninstall)( drm_device_t *dev ) { ### ### Fix Kconfig file for SiS driver - it now works without SISFB ### diff -u dri-kernel/Kconfig v2.5/linux/drivers/char/drm/Kconfig --- dri-kernel/Kconfig 2003-08-15 03:31:54.0 -0700 +++ v2.5/linux/drivers/char/drm/Kconfig 2003-09-25 08:30:36.172304441 -0700 @@ -75,9 +75,9 @@ config DRM_SIS tristate SiS video cards - depends on DRM AGP FB_SIS + depends on DRM AGP help Choose this option if you have a SiS 630 or compatibel video chipset. If M is selected the module will be called sis. AGP - and SiS FB support is required for this driver to work. + support is required for this driver to work. ### ### Various whitespace fixes: don't mix spaces and tabs ### at the beginning of lines ### diff -u dri-kernel/i810_dma.c v2.5/linux/drivers/char/drm/i810_dma.c --- dri-kernel/i810_dma.c 2003-08-14 18:05:24.0 -0700 +++ v2.5/linux/drivers/char/drm/i810_dma.c 2003-09-24 17:10:18.0 -0700 @@ -90,7 +83,7 @@ /* In use is already a pointer */ used = cmpxchg(buf_priv-in_use, I810_BUF_FREE, I810_BUF_CLIENT); - if (used == I810_BUF_FREE) { + if (used == I810_BUF_FREE) { return buf; } } @@ -108,7 +101,7 @@ /* In use is already a pointer */ used = cmpxchg(buf_priv-in_use, I810_BUF_CLIENT, I810_BUF_FREE); - if (used != I810_BUF_CLIENT) { + if (used != I810_BUF_CLIENT) { DRM_ERROR(Freeing buffer thats not in use : %d\n, buf-idx); return -EINVAL; } @@ -194,7 +187,7 @@ return -EINVAL; down_write(current-mm-mmap_sem); - retcode = DO_MUNMAP(current-mm, + retcode = do_munmap(current-mm, (unsigned long)buf_priv-virtual, (size_t) buf-total); up_write(current-mm-mmap_sem); @@ -252,7 +245,7 @@ drm_i810_private_t
Re: [Dri-devel] Kernel back-merge ...
[ Following up to myself. Damn, I hate when that happens. It's a sign of early senility when you start talking to yourself, and it happens all too often for me ; ] One chunk of the whitespace fixes wasn't whitespace, it was due to the 2.6.x tree not having some of the backwards compatibility crud. So before applying that part, just edit out the one chunk that changes DO_MUNMAP to do_munmap and apply the rest (that chunk appended here for clarity). Sorry for missing that on editing the patch. My bad. Linus On Thu, 25 Sep 2003, Linus Torvalds wrote: ### ### Various whitespace fixes: don't mix spaces and tabs ### at the beginning of lines ### diff -u dri-kernel/i810_dma.c v2.5/linux/drivers/char/drm/i810_dma.c --- dri-kernel/i810_dma.c 2003-08-14 18:05:24.0 -0700 +++ v2.5/linux/drivers/char/drm/i810_dma.c2003-09-24 17:10:18.0 -0700 @@ -194,7 +187,7 @@ return -EINVAL; down_write(current-mm-mmap_sem); - retcode = DO_MUNMAP(current-mm, + retcode = do_munmap(current-mm, (unsigned long)buf_priv-virtual, (size_t) buf-total); up_write(current-mm-mmap_sem); --- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf ___ Dri-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/dri-devel
Re: [Dri-devel] Kernel back-merge ...
On Thu, 2003-09-25 at 10:44, Linus Torvalds wrote: Ok, I've merged the current DRI CVS tree from freedesktop.org into the kernel, and as a result I now have another (pretty obvious) diff for back-merging into DRI. I hope somebody with commit access will do this. The merge has three parts: - a real fix for an i830_irq.c misfeature, where the DRI code initializes counters and a wait-queue _after_ having enabled interrupts. Yeah, there shouldn't be any events pending since the thing should be quiescent and we just cleared the interrupt sources, but it's still not good practice. So move the clearing to the pre-irq-install. - Update the Kconfig file for the SiS driver to the new realities of not needing the SISFB driver to compile. This is probably not an issue for anybody who compiles the out-of-kernel version, since they won't be using the kernel configurator, but it's an easier merge, and it's obviously correct. - whitespace fixes. The DRI tree had a number of whitespace fixes to the i810 driver that I merged into the kernel - but whenever I merged a whitespace change I made sure to merge the _proper_ whitespace. No mixed space/tab crud at the beginning of lines. As a result, I now have a pure whitespace diff that I try to push back into the DRI tree. All of these should be totally obvious patches, but they may apply with some offset because I edited out the other parts of the merge. Can somebody apply them or indicate why they shouldn't be applied. [ The whitespace noise should be fine, since there should be no issues with merging this back into XF86 - since all development to the files involved happens either in the kernel tree or in the DRI tree. So it shouldn't cause any merge issues down the line - it only helps merging with the kernel. I obviously don't know what the merge issues are for the *BSD versions.. ] I applied the radeon.h and the Kconfig patches (redone, since whitespace got mangled in the email). I've posted a more agressive whitespace cleanup of i810_dma.c. I don't want to commit such a big whitespace diff without the i810 maintainer's approval. http://people.freebsd.org/~anholt/dri/files/i810-whitespace.diff Keith, what's the status of the new i830 stuff? Is it going to be merged to trunk soon, or should we put things in trunk in the meantime (I'm thinking of this i830 fix, the BSD fixes you've made)? -- Eric Anholt[EMAIL PROTECTED] http://people.freebsd.org/~anholt/ [EMAIL PROTECTED] --- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf ___ Dri-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/dri-devel
Re: [Dri-devel] Kernel back-merge ...
On Thu, 25 Sep 2003, Eric Anholt wrote: I applied the radeon.h and the Kconfig patches (redone, since whitespace got mangled in the email). Hmm.. It's not mangled here - I just verified by applying the whole patch as it came in off the dri-devel list (as opposed to what I sent out) to the DRI tree. So you must have some whitespace problems on your end. Linus --- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf ___ Dri-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/dri-devel
Re: [Dri-devel] Kernel back-merge ...
I applied the radeon.h and the Kconfig patches (redone, since whitespace got mangled in the email). I've posted a more agressive whitespace cleanup of i810_dma.c. I don't want to commit such a big whitespace diff without the i810 maintainer's approval. http://people.freebsd.org/~anholt/dri/files/i810-whitespace.diff Well it looks fine to me... I'd prefer someone to else to patch it, as it was me who messed up some of the merging last time (*must reconfigure editor properly.. and maybe run Lindent*)... If Linus thinks your patch goes far enough for him.. Dave. Keith, what's the status of the new i830 stuff? Is it going to be merged to trunk soon, or should we put things in trunk in the meantime (I'm thinking of this i830 fix, the BSD fixes you've made)? -- David Airlie, Software Engineer http://www.skynet.ie/~airlied / [EMAIL PROTECTED] pam_smb / Linux DECstation / Linux VAX / ILUG person --- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf ___ Dri-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/dri-devel