lkml.org 
[lkml]   [1999]   [Aug]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: 2.3.13-pre4 tweeks
<!doctype html public "-//w3c//dtd html 4.0 transitional//en">
<html>
Richard Henderson wrote:
<blockquote TYPE=CITE>On Wed, Aug 04, 1999 at 08:04:23AM -0400, Peter Rival
wrote:</blockquote>
&lt;snip>
<blockquote TYPE=CITE>> smp.c:48: section attribute not allowed for `bits'
<p>... I didn't build an smp kernel.&nbsp; Doh!&nbsp; Yes, I use __cacheline_aligned
<br>on a structure element, which means the section attribute needs to
<br>come off the definition.</blockquote>

<p><br>Okay...easy enough.&nbsp; Now the next fun part:&nbsp; (don't worry
- it gets better ;)
<p><tt>make -C&nbsp; arch/alpha/kernel</tt>
<br><tt>make[1]: Entering directory `/usr/src/linux/arch/alpha/kernel'</tt>
<br><tt>gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes
-O2 -fomit-frame-pointer -fno-strict-aliasing -D__SMP__ -pipe -mno-fp-regs
-ffixed-8&nbsp;&nbsp; -c -o smp.o smp.c</tt>
<br><tt>smp.c: In function `flush_tlb_mm':</tt>
<br><tt>smp.c:874: structure has no member named `count'</tt>
<br><tt>smp.c: In function `flush_tlb_page':</tt>
<br><tt>smp.c:906: structure has no member named `count'</tt>
<br><tt>make[1]: *** [smp.o] Error 1</tt>
<br><tt>make[1]: Leaving directory `/usr/src/linux/arch/alpha/kernel'</tt>
<br><tt>make: *** [_dir_arch/alpha/kernel] Error 2</tt>
<p>Which is caused by code such as this:<tt></tt>
<p><tt>void</tt>
<br><tt>flush_tlb_mm(struct mm_struct *mm)</tt>
<br><tt>{</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; if (mm == current->mm)
{</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
flush_tlb_current(mm);</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
if (atomic_read(&amp;mm->mm_count) == 1)</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
return;</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; } else</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
flush_tlb_other(mm);</tt><tt></tt>
<p><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; if (smp_call_function(ipi_flush_tlb_mm,
mm, 1, 1)) {</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
printk(KERN_CRIT "flush_tlb_mm: timed out\n");</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }</tt>
<br><tt>}</tt>
<br><tt></tt>&nbsp;
<p>Looks like it hasn't been updated for the new <tt>struct mm_struct</tt>
implementation yet.&nbsp; I _think_ it's supposed to look something like
this, but I'm not sure:
<p><tt>void</tt>
<br><tt>flush_tlb_mm(struct mm_struct *mm)</tt>
<br><tt>{</tt>
<br><tt>&nbsp;&nbsp;&nbsp; if (mm == current->active_mm &amp;&amp;</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; atomic_read(&amp;mm->mm_users)
== 1 &amp;&amp;</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; (mm->cpu_vm_mask ==
(1UL &lt;&lt; smp_processor_id())))</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
goto local_flush_tlb;</tt><tt></tt>
<p><tt>&nbsp;&nbsp;&nbsp; if (smp_call_function(ipi_flush_tlb_mm, mm, 1,
1)) {</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
printk(KERN_CRIT "flush_tlb_mm: timed out\n");</tt>
<br><tt>&nbsp;&nbsp;&nbsp; }</tt><tt></tt>
<p><tt>local_flush_tlb:</tt>
<br><tt>&nbsp;&nbsp;&nbsp; flush_tlb_other(mm);</tt>
<br><tt>}</tt>
<p>(This was mostly stolen from the sparc64 version...I'm still digesting
Linus' message about how this new task schtuff works...I hate not being
able to work on Linux full time...*groan*)
<p>I'd imagine the code is mostly the same type of transition for <tt>flush_tlb_page</tt>,
but I'm not positive.
<p>&nbsp;- Pete
<p>P.S.&nbsp; Should&nbsp; I mention that a mikasa (at least) wedges after
the "freeing initial memory" message under pre-4 plus this diff, or just
keep that to myself? ;)</html>
\
 
 \ /
  Last update: 2005-03-22 13:53    [W:0.041 / U:0.816 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site