From: Mikael Pettersson <mikpe@csd.uu.se>
To: marcelo.tosatti@cyclades.com
Cc: linux-kernel@vger.kernel.org
Subject: [PATCH][2.4.23] fix some DRM43 warnings
Date: Tue, 2 Dec 2003 17:21:21 +0100 [thread overview]
Message-ID: <16332.48129.638814.999930@alkaid.it.uu.se> (raw)
[Resend. Was ignored for 2.4.23-pre :-(]
This patch fixes three sources of warnings in the new 4.3 DRM code:
- drm_os_linux.h has a #warning on broken list_entry usage.
The patch backports a fix from the 2.6 code.
- radeon_drv.h has a #warning PCI posting bug.
The #warning refers to an obsolete and unused macro.
Simply remove it. It's also gone from the 2.6 code.
- drm_agpsupport.h generates a gcc warning on an assignment
used as a truth value.
The patch backports a fix from the 2.6 code.
These changes are well-tested: they have been in 2.6 for ages,
and I've been running them in 2.4.23-pre/rc for months.
Please apply.
/Mikael
diff -ruN linux-2.4.23/drivers/char/drm/drm_agpsupport.h linux-2.4.23.drm43-fixes/drivers/char/drm/drm_agpsupport.h
--- linux-2.4.23/drivers/char/drm/drm_agpsupport.h 2003-11-29 00:28:11.000000000 +0100
+++ linux-2.4.23.drm43-fixes/drivers/char/drm/drm_agpsupport.h 2003-11-29 00:33:29.000000000 +0100
@@ -79,7 +79,7 @@
return -EBUSY;
if(!drm_agp->acquire)
return -EINVAL;
- if (retcode = drm_agp->acquire())
+ if ((retcode = drm_agp->acquire()))
return retcode;
dev->agp->acquired = 1;
return 0;
diff -ruN linux-2.4.23/drivers/char/drm/drm_os_linux.h linux-2.4.23.drm43-fixes/drivers/char/drm/drm_os_linux.h
--- linux-2.4.23/drivers/char/drm/drm_os_linux.h 2003-11-29 00:28:11.000000000 +0100
+++ linux-2.4.23.drm43-fixes/drivers/char/drm/drm_os_linux.h 2003-11-29 00:33:29.000000000 +0100
@@ -13,12 +13,10 @@
return -EFAULT
-#warning the author of this code needs to read up on list_entry
#define DRM_GETSAREA() \
do { \
- struct list_head *list; \
- list_for_each( list, &dev->maplist->head ) { \
- drm_map_list_t *entry = (drm_map_list_t *)list; \
+ drm_map_list_t *entry; \
+ list_for_each_entry( entry, &dev->maplist->head, head ) { \
if ( entry->map && \
entry->map->type == _DRM_SHM && \
(entry->map->flags & _DRM_CONTAINS_LOCK) ) { \
diff -ruN linux-2.4.23/drivers/char/drm/radeon_drv.h linux-2.4.23.drm43-fixes/drivers/char/drm/radeon_drv.h
--- linux-2.4.23/drivers/char/drm/radeon_drv.h 2003-11-29 00:28:11.000000000 +0100
+++ linux-2.4.23.drm43-fixes/drivers/char/drm/radeon_drv.h 2003-11-29 00:33:29.000000000 +0100
@@ -839,14 +839,6 @@
* Ring control
*/
-#if defined(__powerpc__)
-#define radeon_flush_write_combine() (void) GET_RING_HEAD( &dev_priv->ring )
-#else
-#define radeon_flush_write_combine() wmb()
-#warning PCI posting bug
-#endif
-
-
#define RADEON_VERBOSE 0
#define RING_LOCALS int write, _nr; unsigned int mask; u32 *ring;
reply other threads:[~2003-12-02 16:21 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=16332.48129.638814.999930@alkaid.it.uu.se \
--to=mikpe@csd.uu.se \
--cc=linux-kernel@vger.kernel.org \
--cc=marcelo.tosatti@cyclades.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®