lkml.org 
[lkml]   [1999]   [Jul]   [1]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Warnings compiling 2.3.9 on Alpha
Matthias Welwarsky wrote:

> Cannot quite decide whether it's lethal or not. Seems that there are
> typecasts from a pointer (64bit) to an int (32bit). A quick look shows
> that the TryLockPage/UnlockPage seem to be the cause...

Ok, looking a little more closer it seems that its the following
assignment:

#define TryLockPage(page) \
({ int _ret = test_and_set_bit(PG_locked, &(page)->flags); \
if (!_ret) page->owner = (int)current; _ret; })
^^^^^^^^^^^^^^^^^^^^^^^^^^
#define UnlockPage(page) do { \
if (page->owner != (int)current) { ...
^^^^^^^^^^^^^^^^^^^^^^^^^^^

"page->owner" is an int while current is a pointer variable. Intellism
again :-( Is there a reason why "page->owner" cannot be a pointer type
variable?

Gruss,
Matze

--
Two OS engineers facing a petri net chart:
"dead lock in four moves!"

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:52    [W:0.024 / U:0.876 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site