Linux MIPS Architecture development
 help / color / mirror / Atom feed
* 2.4.18: pgtable.h compile fix
@ 2002-06-23 12:58 Guido Guenther
  2002-06-24  8:11 ` Ralf Baechle
  2002-06-24  8:30 ` Maciej W. Rozycki
  0 siblings, 2 replies; 7+ messages in thread
From: Guido Guenther @ 2002-06-23 12:58 UTC (permalink / raw)
  To: linux-mips

Hi,
I need the following to make head.S compile again for IP22 on the 
current linux_2_4 branch:

Index: include/asm-mips/pgtable.h
===================================================================
RCS file: /cvs/linux/include/asm-mips/pgtable.h,v
retrieving revision 1.63.2.12
diff -u -r1.63.2.12 pgtable.h
--- include/asm-mips/pgtable.h	2002/05/28 09:49:40	1.63.2.12
+++ include/asm-mips/pgtable.h	2002/06/23 12:48:50
@@ -13,6 +13,8 @@
 #include <asm/addrspace.h>
 #include <asm/page.h>
 
+#ifndef _LANGUAGE_ASSEMBLY
+
 #include <linux/linkage.h>
 #include <asm/cachectl.h>
 #include <asm/fixmap.h>
@@ -78,6 +80,7 @@
 extern int add_temporary_entry(unsigned long entrylo0, unsigned long entrylo1,
 			       unsigned long entryhi, unsigned long pagemask);
 
+#endif /* !defined (_LANGUAGE_ASSEMBLY) */
 
 /* Basically we have the same two-level (which is the logical three level
  * Linux page table layout folded) page tables as the i386.  Some day
@@ -167,6 +170,8 @@
 #define __S110	PAGE_SHARED
 #define __S111	PAGE_SHARED
 
+#if !defined (_LANGUAGE_ASSEMBLY)
+
 #ifdef CONFIG_64BIT_PHYS_ADDR
 #define pte_ERROR(e) \
 	printk("%s:%d: bad pte %016Lx.\n", __FILE__, __LINE__, pte_val(e))
@@ -472,6 +477,8 @@
 #define kern_addr_valid(addr)	(1)
 
 #include <asm-generic/pgtable.h>
+
+#endif /* !defined (_LANGUAGE_ASSEMBLY) */
 
 /*
  * We provide our own get_unmapped area to cope with the virtual aliasing

Is there a reason why the "_LANGUAGE_ASSEMBLY" ifdefs were removed?
Mips64 still has these #ifdefs though.
Regards, 
 -- Guido

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: 2.4.18: pgtable.h compile fix
  2002-06-23 12:58 2.4.18: pgtable.h compile fix Guido Guenther
@ 2002-06-24  8:11 ` Ralf Baechle
  2002-06-26 13:23   ` Guido Guenther
  2002-06-24  8:30 ` Maciej W. Rozycki
  1 sibling, 1 reply; 7+ messages in thread
From: Ralf Baechle @ 2002-06-24  8:11 UTC (permalink / raw)
  To: Guido Guenther; +Cc: linux-mips

On Sun, Jun 23, 2002 at 02:58:11PM +0200, Guido Guenther wrote:

> Hi,
> I need the following to make head.S compile again for IP22 on the 
> current linux_2_4 branch:

> Is there a reason why the "_LANGUAGE_ASSEMBLY" ifdefs were removed?
> Mips64 still has these #ifdefs though.

The necessity for these was believed to be removed.  What are you trying
to do when you run into this problem?

  Ralf

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: 2.4.18: pgtable.h compile fix
  2002-06-23 12:58 2.4.18: pgtable.h compile fix Guido Guenther
  2002-06-24  8:11 ` Ralf Baechle
@ 2002-06-24  8:30 ` Maciej W. Rozycki
  2002-06-24 13:33   ` Ralf Baechle
  1 sibling, 1 reply; 7+ messages in thread
From: Maciej W. Rozycki @ 2002-06-24  8:30 UTC (permalink / raw)
  To: Guido Guenther; +Cc: linux-mips

On Sun, 23 Jun 2002, Guido Guenther wrote:

> Is there a reason why the "_LANGUAGE_ASSEMBLY" ifdefs were removed?
> Mips64 still has these #ifdefs though.

 MIPS64 lags behind a bit due to less interest/testing.  Note that you
should use "__ASSEMBLY__" to guard assembly-unsafe parts of headers.

-- 
+  Maciej W. Rozycki, Technical University of Gdansk, Poland   +
+--------------------------------------------------------------+
+        e-mail: macro@ds2.pg.gda.pl, PGP key available        +

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: 2.4.18: pgtable.h compile fix
  2002-06-24  8:30 ` Maciej W. Rozycki
@ 2002-06-24 13:33   ` Ralf Baechle
  2002-06-24 15:54     ` Maciej W. Rozycki
  0 siblings, 1 reply; 7+ messages in thread
From: Ralf Baechle @ 2002-06-24 13:33 UTC (permalink / raw)
  To: Maciej W. Rozycki; +Cc: Guido Guenther, linux-mips

On Mon, Jun 24, 2002 at 10:30:22AM +0200, Maciej W. Rozycki wrote:

>  MIPS64 lags behind a bit due to less interest/testing.  Note that you
> should use "__ASSEMBLY__" to guard assembly-unsafe parts of headers.

_LANGUAGE_ASSEMBLY is the traditional MIPS cpp symbol to indicate assembler
source code.

  Ralf

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: 2.4.18: pgtable.h compile fix
  2002-06-24 13:33   ` Ralf Baechle
@ 2002-06-24 15:54     ` Maciej W. Rozycki
  2002-06-25  8:54       ` Ralf Baechle
  0 siblings, 1 reply; 7+ messages in thread
From: Maciej W. Rozycki @ 2002-06-24 15:54 UTC (permalink / raw)
  To: Ralf Baechle; +Cc: Guido Guenther, linux-mips

On Mon, 24 Jun 2002, Ralf Baechle wrote:

> >  MIPS64 lags behind a bit due to less interest/testing.  Note that you
> > should use "__ASSEMBLY__" to guard assembly-unsafe parts of headers.
> 
> _LANGUAGE_ASSEMBLY is the traditional MIPS cpp symbol to indicate assembler
> source code.

 Well, but the rest of the kernel uses "__ASSEMBLY__", that's defined in
the top-level Makefile.  What's the point in being different? 

 Also it doesn't seem to work for me -- the rules in specs look broken:

$ mipsel-linux-gcc -E -dM -xassembler-with-cpp /dev/null | grep LANGUAGE
#define __LANGUAGE_C 1
#define _LANGUAGE_C 1
#define LANGUAGE_C 1

thus it cannot be considered reliable.

-- 
+  Maciej W. Rozycki, Technical University of Gdansk, Poland   +
+--------------------------------------------------------------+
+        e-mail: macro@ds2.pg.gda.pl, PGP key available        +

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: 2.4.18: pgtable.h compile fix
  2002-06-24 15:54     ` Maciej W. Rozycki
@ 2002-06-25  8:54       ` Ralf Baechle
  0 siblings, 0 replies; 7+ messages in thread
From: Ralf Baechle @ 2002-06-25  8:54 UTC (permalink / raw)
  To: Maciej W. Rozycki; +Cc: Guido Guenther, linux-mips

On Mon, Jun 24, 2002 at 05:54:28PM +0200, Maciej W. Rozycki wrote:

> > >  MIPS64 lags behind a bit due to less interest/testing.  Note that you
> > > should use "__ASSEMBLY__" to guard assembly-unsafe parts of headers.
> > 
> > _LANGUAGE_ASSEMBLY is the traditional MIPS cpp symbol to indicate assembler
> > source code.
> 
>  Well, but the rest of the kernel uses "__ASSEMBLY__", that's defined in
> the top-level Makefile.  What's the point in being different? 
> 
>  Also it doesn't seem to work for me -- the rules in specs look broken:
> 
> $ mipsel-linux-gcc -E -dM -xassembler-with-cpp /dev/null | grep LANGUAGE
> #define __LANGUAGE_C 1
> #define _LANGUAGE_C 1
> #define LANGUAGE_C 1
> 
> thus it cannot be considered reliable.

The machanism guesses the language based on the source file name extension:

[ralf@dea tmp]$ echo -n > c.c && mips-linux-gcc -E -dM -xassembler-with-cpp c.c | grep LANG
#define __LANGUAGE_C 1 
#define _LANGUAGE_C 1 
#define LANGUAGE_C 1 
[ralf@dea tmp]$ echo -n > c.S && mips-linux-gcc -E -dM c.S | grep LANG
#define LANGUAGE_ASSEMBLY 1 
#define _LANGUAGE_ASSEMBLY 1 
#define __LANGUAGE_ASSEMBLY 1 
[ralf@dea tmp]$

Buggy?  Yes ...

  Ralf

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: 2.4.18: pgtable.h compile fix
  2002-06-24  8:11 ` Ralf Baechle
@ 2002-06-26 13:23   ` Guido Guenther
  0 siblings, 0 replies; 7+ messages in thread
From: Guido Guenther @ 2002-06-26 13:23 UTC (permalink / raw)
  To: Ralf Baechle; +Cc: linux-mips

On Mon, Jun 24, 2002 at 10:11:23AM +0200, Ralf Baechle wrote:
> On Sun, Jun 23, 2002 at 02:58:11PM +0200, Guido Guenther wrote:
> 
> > Hi,
> > I need the following to make head.S compile again for IP22 on the 
> > current linux_2_4 branch:
> 
> > Is there a reason why the "_LANGUAGE_ASSEMBLY" ifdefs were removed?
> > Mips64 still has these #ifdefs though.
> 
> The necessity for these was believed to be removed.  What are you trying
> to do when you run into this problem?
CVS bit me and messed up head.S which included pgtable.h instead of
pgtable-bits.h. Works fine now.
Thanks,
 -- Guido

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2002-06-26 13:20 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-06-23 12:58 2.4.18: pgtable.h compile fix Guido Guenther
2002-06-24  8:11 ` Ralf Baechle
2002-06-26 13:23   ` Guido Guenther
2002-06-24  8:30 ` Maciej W. Rozycki
2002-06-24 13:33   ` Ralf Baechle
2002-06-24 15:54     ` Maciej W. Rozycki
2002-06-25  8:54       ` Ralf Baechle

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox